blob: 26da08030e323faf89b93bd744b18ddc65bdad6f [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002# From configure.in Revision: 72871 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004# Generated by GNU Autoconf 2.63 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,
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009# 2002, 2003, 2004, 2005, 2006, 2007, 2008 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=:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021 # Pre-4.2 versions of Zsh do 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
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000043as_nl='
44'
45export as_nl
46# Printing a long string crashes Solaris 7 /usr/bin/printf.
47as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
48as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
49as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
50if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
51 as_echo='printf %s\n'
52 as_echo_n='printf %s'
53else
54 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
55 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
56 as_echo_n='/usr/ucb/echo -n'
57 else
58 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
59 as_echo_n_body='eval
60 arg=$1;
61 case $arg in
62 *"$as_nl"*)
63 expr "X$arg" : "X\\(.*\\)$as_nl";
64 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
65 esac;
66 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
67 '
68 export as_echo_n_body
69 as_echo_n='sh -c $as_echo_n_body as_echo'
70 fi
71 export as_echo_body
72 as_echo='sh -c $as_echo_body as_echo'
73fi
74
Martin v. Löwis11437992002-04-12 09:54:03 +000075# The user is always right.
76if test "${PATH_SEPARATOR+set}" != set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000077 PATH_SEPARATOR=:
78 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
79 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
80 PATH_SEPARATOR=';'
81 }
Martin v. Löwis11437992002-04-12 09:54:03 +000082fi
83
Martin v. Löwiseba40652007-08-30 20:10:57 +000084# Support unset when possible.
85if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
86 as_unset=unset
87else
88 as_unset=false
89fi
Martin v. Löwis11437992002-04-12 09:54:03 +000090
Martin v. Löwiseba40652007-08-30 20:10:57 +000091
92# IFS
93# We need space, tab and new line, in precisely that order. Quoting is
94# there to prevent editors from complaining about space-tab.
95# (If _AS_PATH_WALK were called with IFS unset, it would disable word
96# splitting by setting IFS to empty value.)
Martin v. Löwiseba40652007-08-30 20:10:57 +000097IFS=" "" $as_nl"
98
99# Find who we are. Look in the path if we contain no directory separator.
100case $0 in
101 *[\\/]* ) as_myself=$0 ;;
102 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +0000103for as_dir in $PATH
104do
105 IFS=$as_save_IFS
106 test -z "$as_dir" && as_dir=.
107 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
108done
Martin v. Löwiseba40652007-08-30 20:10:57 +0000109IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +0000110
Martin v. Löwiseba40652007-08-30 20:10:57 +0000111 ;;
112esac
113# We did not find ourselves, most probably we were run as `sh COMMAND'
114# in which case we are not to be found in the path.
115if test "x$as_myself" = x; then
116 as_myself=$0
117fi
118if test ! -f "$as_myself"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000119 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +0000120 { (exit 1); exit 1; }
121fi
122
123# Work around bugs in pre-3.0 UWIN ksh.
124for as_var in ENV MAIL MAILPATH
125do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
126done
127PS1='$ '
128PS2='> '
129PS4='+ '
130
131# NLS nuisances.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000132LC_ALL=C
133export LC_ALL
134LANGUAGE=C
135export LANGUAGE
Martin v. Löwiseba40652007-08-30 20:10:57 +0000136
137# Required to use basename.
138if expr a : '\(a\)' >/dev/null 2>&1 &&
139 test "X`expr 00001 : '.*\(...\)'`" = X001; then
140 as_expr=expr
141else
142 as_expr=false
143fi
144
145if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
146 as_basename=basename
147else
148 as_basename=false
149fi
150
151
152# Name of the executable.
153as_me=`$as_basename -- "$0" ||
154$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
155 X"$0" : 'X\(//\)$' \| \
156 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000157$as_echo X/"$0" |
Martin v. Löwiseba40652007-08-30 20:10:57 +0000158 sed '/^.*\/\([^/][^/]*\)\/*$/{
159 s//\1/
160 q
161 }
162 /^X\/\(\/\/\)$/{
163 s//\1/
164 q
165 }
166 /^X\/\(\/\).*/{
167 s//\1/
168 q
169 }
170 s/.*/./; q'`
171
172# CDPATH.
173$as_unset CDPATH
174
175
176if test "x$CONFIG_SHELL" = x; then
177 if (eval ":") 2>/dev/null; then
178 as_have_required=yes
179else
180 as_have_required=no
181fi
182
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000183 if test $as_have_required = yes && (eval ":
Martin v. Löwiseba40652007-08-30 20:10:57 +0000184(as_func_return () {
185 (exit \$1)
186}
187as_func_success () {
188 as_func_return 0
189}
190as_func_failure () {
191 as_func_return 1
192}
193as_func_ret_success () {
194 return 0
195}
196as_func_ret_failure () {
197 return 1
198}
199
200exitcode=0
201if as_func_success; then
202 :
203else
204 exitcode=1
205 echo as_func_success failed.
206fi
207
208if as_func_failure; then
209 exitcode=1
210 echo as_func_failure succeeded.
211fi
212
213if as_func_ret_success; then
214 :
215else
216 exitcode=1
217 echo as_func_ret_success failed.
218fi
219
220if as_func_ret_failure; then
221 exitcode=1
222 echo as_func_ret_failure succeeded.
223fi
224
225if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
226 :
227else
228 exitcode=1
229 echo positional parameters were not saved.
230fi
231
232test \$exitcode = 0) || { (exit 1); exit 1; }
233
234(
235 as_lineno_1=\$LINENO
236 as_lineno_2=\$LINENO
237 test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
238 test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
239") 2> /dev/null; then
240 :
241else
242 as_candidate_shells=
Martin v. Löwis11437992002-04-12 09:54:03 +0000243 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
244for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
245do
246 IFS=$as_save_IFS
247 test -z "$as_dir" && as_dir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000248 case $as_dir in
Martin v. Löwis11437992002-04-12 09:54:03 +0000249 /*)
Martin v. Löwiseba40652007-08-30 20:10:57 +0000250 for as_base in sh bash ksh sh5; do
251 as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
252 done;;
253 esac
254done
255IFS=$as_save_IFS
256
257
258 for as_shell in $as_candidate_shells $SHELL; do
259 # Try only shells that exist, to save several forks.
260 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
261 { ("$as_shell") 2> /dev/null <<\_ASEOF
262if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
263 emulate sh
264 NULLCMD=:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000265 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
Martin v. Löwiseba40652007-08-30 20:10:57 +0000266 # is contrary to our usage. Disable this feature.
267 alias -g '${1+"$@"}'='"$@"'
268 setopt NO_GLOB_SUBST
269else
270 case `(set -o) 2>/dev/null` in
271 *posix*) set -o posix ;;
272esac
273
274fi
275
276
277:
278_ASEOF
279}; then
280 CONFIG_SHELL=$as_shell
281 as_have_required=yes
282 if { "$as_shell" 2> /dev/null <<\_ASEOF
283if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
284 emulate sh
285 NULLCMD=:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000286 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
Martin v. Löwiseba40652007-08-30 20:10:57 +0000287 # is contrary to our usage. Disable this feature.
288 alias -g '${1+"$@"}'='"$@"'
289 setopt NO_GLOB_SUBST
290else
291 case `(set -o) 2>/dev/null` in
292 *posix*) set -o posix ;;
293esac
294
295fi
296
297
298:
299(as_func_return () {
300 (exit $1)
301}
302as_func_success () {
303 as_func_return 0
304}
305as_func_failure () {
306 as_func_return 1
307}
308as_func_ret_success () {
309 return 0
310}
311as_func_ret_failure () {
312 return 1
313}
314
315exitcode=0
316if as_func_success; then
317 :
318else
319 exitcode=1
320 echo as_func_success failed.
321fi
322
323if as_func_failure; then
324 exitcode=1
325 echo as_func_failure succeeded.
326fi
327
328if as_func_ret_success; then
329 :
330else
331 exitcode=1
332 echo as_func_ret_success failed.
333fi
334
335if as_func_ret_failure; then
336 exitcode=1
337 echo as_func_ret_failure succeeded.
338fi
339
340if ( set x; as_func_ret_success y && test x = "$1" ); then
341 :
342else
343 exitcode=1
344 echo positional parameters were not saved.
345fi
346
347test $exitcode = 0) || { (exit 1); exit 1; }
348
349(
Skip Montanaro89e975f2007-08-22 19:05:21 +0000350 as_lineno_1=$LINENO
351 as_lineno_2=$LINENO
Skip Montanaro89e975f2007-08-22 19:05:21 +0000352 test "x$as_lineno_1" != "x$as_lineno_2" &&
Martin v. Löwiseba40652007-08-30 20:10:57 +0000353 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
354
355_ASEOF
356}; then
357 break
358fi
359
360fi
361
362 done
363
364 if test "x$CONFIG_SHELL" != x; then
365 for as_var in BASH_ENV ENV
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000366 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
367 done
368 export CONFIG_SHELL
369 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
Martin v. Löwiseba40652007-08-30 20:10:57 +0000370fi
371
372
373 if test $as_have_required = no; then
374 echo This script requires a shell more modern than all the
375 echo shells that I found on your system. Please install a
376 echo modern shell, or manually run the script under such a
377 echo shell if you do have one.
378 { (exit 1); exit 1; }
379fi
380
381
382fi
383
384fi
385
386
387
388(eval "as_func_return () {
389 (exit \$1)
390}
391as_func_success () {
392 as_func_return 0
393}
394as_func_failure () {
395 as_func_return 1
396}
397as_func_ret_success () {
398 return 0
399}
400as_func_ret_failure () {
401 return 1
402}
403
404exitcode=0
405if as_func_success; then
406 :
407else
408 exitcode=1
409 echo as_func_success failed.
410fi
411
412if as_func_failure; then
413 exitcode=1
414 echo as_func_failure succeeded.
415fi
416
417if as_func_ret_success; then
418 :
419else
420 exitcode=1
421 echo as_func_ret_success failed.
422fi
423
424if as_func_ret_failure; then
425 exitcode=1
426 echo as_func_ret_failure succeeded.
427fi
428
429if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
430 :
431else
432 exitcode=1
433 echo positional parameters were not saved.
434fi
435
436test \$exitcode = 0") || {
437 echo No shell found that supports shell functions.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000438 echo Please tell bug-autoconf@gnu.org about your system,
439 echo including any error possibly output before this message.
440 echo This can help us improve future autoconf versions.
441 echo Configuration will now proceed without shell functions.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000442}
443
444
445
446 as_lineno_1=$LINENO
447 as_lineno_2=$LINENO
448 test "x$as_lineno_1" != "x$as_lineno_2" &&
449 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
Martin v. Löwis11437992002-04-12 09:54:03 +0000450
451 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
452 # uniformly replaced by the line number. The first 'sed' inserts a
Martin v. Löwiseba40652007-08-30 20:10:57 +0000453 # line-number line after each line using $LINENO; the second 'sed'
454 # does the real work. The second script uses 'N' to pair each
455 # line-number line with the line containing $LINENO, and appends
456 # trailing '-' during substitution so that $LINENO is not a special
457 # case at line end.
Martin v. Löwis11437992002-04-12 09:54:03 +0000458 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
Martin v. Löwiseba40652007-08-30 20:10:57 +0000459 # scripts with optimization help from Paolo Bonzini. Blame Lee
460 # E. McMahon (1931-1989) for sed's syntax. :-)
461 sed -n '
462 p
463 /[$]LINENO/=
464 ' <$as_myself |
Martin v. Löwis11437992002-04-12 09:54:03 +0000465 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +0000466 s/[$]LINENO.*/&-/
467 t lineno
468 b
469 :lineno
Martin v. Löwis11437992002-04-12 09:54:03 +0000470 N
Martin v. Löwiseba40652007-08-30 20:10:57 +0000471 :loop
472 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
Martin v. Löwis11437992002-04-12 09:54:03 +0000473 t loop
Martin v. Löwiseba40652007-08-30 20:10:57 +0000474 s/-\n.*//
Martin v. Löwis11437992002-04-12 09:54:03 +0000475 ' >$as_me.lineno &&
Martin v. Löwiseba40652007-08-30 20:10:57 +0000476 chmod +x "$as_me.lineno" ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000477 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000478 { (exit 1); exit 1; }; }
479
480 # Don't try to exec as it changes $[0], causing all sort of problems
481 # (the dirname of $[0] is not the place where we might find the
Martin v. Löwiseba40652007-08-30 20:10:57 +0000482 # original and so on. Autoconf is especially sensitive to this).
483 . "./$as_me.lineno"
Martin v. Löwis11437992002-04-12 09:54:03 +0000484 # Exit status is that of the last command.
485 exit
486}
487
488
Martin v. Löwiseba40652007-08-30 20:10:57 +0000489if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
490 as_dirname=dirname
491else
492 as_dirname=false
493fi
494
495ECHO_C= ECHO_N= ECHO_T=
496case `echo -n x` in
497-n*)
498 case `echo 'x\c'` in
499 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
500 *) ECHO_C='\c';;
501 esac;;
502*)
503 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +0000504esac
Martin v. Löwiseba40652007-08-30 20:10:57 +0000505if expr a : '\(a\)' >/dev/null 2>&1 &&
506 test "X`expr 00001 : '.*\(...\)'`" = X001; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000507 as_expr=expr
508else
509 as_expr=false
510fi
511
512rm -f conf$$ conf$$.exe conf$$.file
Martin v. Löwiseba40652007-08-30 20:10:57 +0000513if test -d conf$$.dir; then
514 rm -f conf$$.dir/conf$$.file
515else
516 rm -f conf$$.dir
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000517 mkdir conf$$.dir 2>/dev/null
Martin v. Löwiseba40652007-08-30 20:10:57 +0000518fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000519if (echo >conf$$.file) 2>/dev/null; then
520 if ln -s conf$$.file conf$$ 2>/dev/null; then
521 as_ln_s='ln -s'
522 # ... but there are two gotchas:
523 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
524 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
525 # In both cases, we have to default to `cp -p'.
526 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
527 as_ln_s='cp -p'
528 elif ln conf$$.file conf$$ 2>/dev/null; then
529 as_ln_s=ln
530 else
Martin v. Löwis11437992002-04-12 09:54:03 +0000531 as_ln_s='cp -p'
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000532 fi
Martin v. Löwis11437992002-04-12 09:54:03 +0000533else
534 as_ln_s='cp -p'
535fi
Martin v. Löwiseba40652007-08-30 20:10:57 +0000536rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
537rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +0000538
Skip Montanaro6dead952003-09-25 14:50:04 +0000539if mkdir -p . 2>/dev/null; then
540 as_mkdir_p=:
541else
Skip Montanarof0d5f792004-08-15 14:08:23 +0000542 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +0000543 as_mkdir_p=false
544fi
545
Martin v. Löwiseba40652007-08-30 20:10:57 +0000546if test -x / >/dev/null 2>&1; then
547 as_test_x='test -x'
548else
549 if ls -dL / >/dev/null 2>&1; then
550 as_ls_L_option=L
551 else
552 as_ls_L_option=
553 fi
554 as_test_x='
555 eval sh -c '\''
556 if test -d "$1"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000557 test -d "$1/.";
Martin v. Löwiseba40652007-08-30 20:10:57 +0000558 else
559 case $1 in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000560 -*)set "./$1";;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000561 esac;
562 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
563 ???[sx]*):;;*)false;;esac;fi
564 '\'' sh
565 '
566fi
567as_executable_p=$as_test_x
Martin v. Löwis11437992002-04-12 09:54:03 +0000568
569# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000570as_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 +0000571
572# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000573as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +0000574
575
Martin v. Löwis11437992002-04-12 09:54:03 +0000576
Martin v. Löwiseba40652007-08-30 20:10:57 +0000577exec 7<&0 </dev/null 6>&1
Martin v. Löwis11437992002-04-12 09:54:03 +0000578
579# Name of the host.
580# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
581# so uname gets run too.
582ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
583
Martin v. Löwis11437992002-04-12 09:54:03 +0000584#
585# Initializations.
586#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000587ac_default_prefix=/usr/local
Martin v. Löwiseba40652007-08-30 20:10:57 +0000588ac_clean_files=
Skip Montanaro6dead952003-09-25 14:50:04 +0000589ac_config_libobj_dir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000590LIBOBJS=
Martin v. Löwis11437992002-04-12 09:54:03 +0000591cross_compiling=no
592subdirs=
593MFLAGS=
594MAKEFLAGS=
595SHELL=${CONFIG_SHELL-/bin/sh}
596
Martin v. Löwis11437992002-04-12 09:54:03 +0000597# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000598PACKAGE_NAME='python'
599PACKAGE_TARNAME='python'
Martin v. Löwis174440b2008-10-03 08:59:41 +0000600PACKAGE_VERSION='2.7'
601PACKAGE_STRING='python 2.7'
Georg Brandl464432d2009-05-20 18:24:08 +0000602PACKAGE_BUGREPORT='http://bugs.python.org/'
Martin v. Löwis11437992002-04-12 09:54:03 +0000603
604ac_unique_file="Include/object.h"
605# Factoring default headers for most tests.
606ac_includes_default="\
607#include <stdio.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +0000608#ifdef HAVE_SYS_TYPES_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000609# include <sys/types.h>
610#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000611#ifdef HAVE_SYS_STAT_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000612# include <sys/stat.h>
613#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000614#ifdef STDC_HEADERS
Martin v. Löwis11437992002-04-12 09:54:03 +0000615# include <stdlib.h>
616# include <stddef.h>
617#else
Martin v. Löwiseba40652007-08-30 20:10:57 +0000618# ifdef HAVE_STDLIB_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000619# include <stdlib.h>
620# endif
621#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000622#ifdef HAVE_STRING_H
623# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000624# include <memory.h>
625# endif
626# include <string.h>
627#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000628#ifdef HAVE_STRINGS_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000629# include <strings.h>
630#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000631#ifdef HAVE_INTTYPES_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000632# include <inttypes.h>
Martin v. Löwis11437992002-04-12 09:54:03 +0000633#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000634#ifdef HAVE_STDINT_H
635# include <stdint.h>
636#endif
637#ifdef HAVE_UNISTD_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000638# include <unistd.h>
639#endif"
640
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000641ac_subst_vars='LTLIBOBJS
Martin v. Löwiseba40652007-08-30 20:10:57 +0000642SRCDIRS
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000643THREADHEADERS
644UNICODE_OBJS
645LIBC
646LIBM
647HAVE_GETHOSTBYNAME
648HAVE_GETHOSTBYNAME_R
649HAVE_GETHOSTBYNAME_R_3_ARG
650HAVE_GETHOSTBYNAME_R_5_ARG
651HAVE_GETHOSTBYNAME_R_6_ARG
652LIBOBJS
653TRUE
654MACHDEP_OBJS
655DYNLOADFILE
656DLINCLDIR
657THREADOBJ
658LDLAST
659USE_THREAD_MODULE
660SIGNAL_OBJS
661USE_SIGNAL_MODULE
662SHLIBS
663CFLAGSFORSHARED
664LINKFORSHARED
665CCSHARED
666BLDSHARED
667LDSHARED
668SO
669LIBTOOL_CRUFT
670OTHER_LIBTOOL_OPT
671UNIVERSAL_ARCH_FLAGS
672BASECFLAGS
673OPT
674LN
675INSTALL_DATA
676INSTALL_SCRIPT
677INSTALL_PROGRAM
678SVNVERSION
679ARFLAGS
680AR
681RANLIB
682GNULD
683LINKCC
684RUNSHARED
685INSTSONAME
686LDLIBRARYDIR
687BLDLIBRARY
688DLLLIBRARY
689LDLIBRARY
690LIBRARY
691BUILDEXEEXT
692EGREP
693GREP
694CPP
695MAINCC
696CXX
697OBJEXT
698EXEEXT
699ac_ct_CC
700CPPFLAGS
701LDFLAGS
702CFLAGS
703CC
704EXPORT_MACOSX_DEPLOYMENT_TARGET
705CONFIGURE_MACOSX_DEPLOYMENT_TARGET
706EXTRAMACHDEPPATH
707EXTRAPLATDIR
708SGI_ABI
709MACHDEP
710FRAMEWORKUNIXTOOLSPREFIX
711FRAMEWORKALTINSTALLLAST
712FRAMEWORKALTINSTALLFIRST
713FRAMEWORKINSTALLLAST
714FRAMEWORKINSTALLFIRST
715PYTHONFRAMEWORKINSTALLDIR
716PYTHONFRAMEWORKPREFIX
717PYTHONFRAMEWORKDIR
718PYTHONFRAMEWORKIDENTIFIER
719PYTHONFRAMEWORK
720ARCH_RUN_32BIT
721UNIVERSALSDK
722CONFIG_ARGS
723SOVERSION
724VERSION
725target_alias
726host_alias
727build_alias
728LIBS
729ECHO_T
730ECHO_N
731ECHO_C
732DEFS
733mandir
734localedir
735libdir
736psdir
737pdfdir
738dvidir
739htmldir
740infodir
741docdir
742oldincludedir
743includedir
744localstatedir
745sharedstatedir
746sysconfdir
747datadir
748datarootdir
749libexecdir
750sbindir
751bindir
752program_transform_name
753prefix
754exec_prefix
755PACKAGE_BUGREPORT
756PACKAGE_STRING
757PACKAGE_VERSION
758PACKAGE_TARNAME
759PACKAGE_NAME
760PATH_SEPARATOR
761SHELL'
Skip Montanaro6dead952003-09-25 14:50:04 +0000762ac_subst_files=''
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000763ac_user_opts='
764enable_option_checking
765enable_universalsdk
766with_universal_archs
767with_framework_name
768enable_framework
769with_gcc
770with_cxx_main
771with_suffix
772enable_shared
773enable_profiling
774with_pydebug
775enable_toolbox_glue
776with_libs
777with_system_ffi
778with_dbmliborder
779with_signal_module
780with_dec_threads
781with_threads
782with_thread
783with_pth
784enable_ipv6
785with_doc_strings
786with_tsc
787with_pymalloc
788with_wctype_functions
789with_fpectl
790with_libm
791with_libc
792enable_big_digits
793enable_unicode
794'
Martin v. Löwiseba40652007-08-30 20:10:57 +0000795 ac_precious_vars='build_alias
796host_alias
797target_alias
798CC
799CFLAGS
800LDFLAGS
801LIBS
802CPPFLAGS
803CPP'
804
Guido van Rossum627b2d71993-12-24 10:39:16 +0000805
Guido van Rossum7f43da71994-08-01 12:15:30 +0000806# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000807ac_init_help=
808ac_init_version=false
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000809ac_unrecognized_opts=
810ac_unrecognized_sep=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000811# The variables have the same names as the options, with
812# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000813cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000814exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000815no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000816no_recursion=
817prefix=NONE
818program_prefix=NONE
819program_suffix=NONE
820program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000821silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000822site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000823srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000824verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000825x_includes=NONE
826x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000827
828# Installation directory options.
829# These are left unexpanded so users can "make install exec_prefix=/foo"
830# and all the variables that are supposed to be based on exec_prefix
831# by default will actually change.
832# Use braces instead of parens because sh, perl, etc. also accept them.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000833# (The list follows the same order as the GNU Coding Standards.)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000834bindir='${exec_prefix}/bin'
835sbindir='${exec_prefix}/sbin'
836libexecdir='${exec_prefix}/libexec'
Martin v. Löwiseba40652007-08-30 20:10:57 +0000837datarootdir='${prefix}/share'
838datadir='${datarootdir}'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000839sysconfdir='${prefix}/etc'
840sharedstatedir='${prefix}/com'
841localstatedir='${prefix}/var'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000842includedir='${prefix}/include'
843oldincludedir='/usr/include'
Martin v. Löwiseba40652007-08-30 20:10:57 +0000844docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
845infodir='${datarootdir}/info'
846htmldir='${docdir}'
847dvidir='${docdir}'
848pdfdir='${docdir}'
849psdir='${docdir}'
850libdir='${exec_prefix}/lib'
851localedir='${datarootdir}/locale'
852mandir='${datarootdir}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000853
Guido van Rossum7f43da71994-08-01 12:15:30 +0000854ac_prev=
Martin v. Löwiseba40652007-08-30 20:10:57 +0000855ac_dashdash=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000856for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000857do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000858 # If the previous option needs an argument, assign it.
859 if test -n "$ac_prev"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +0000860 eval $ac_prev=\$ac_option
Guido van Rossum7f43da71994-08-01 12:15:30 +0000861 ac_prev=
862 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000863 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000864
Martin v. Löwiseba40652007-08-30 20:10:57 +0000865 case $ac_option in
866 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
867 *) ac_optarg=yes ;;
868 esac
Guido van Rossum7f43da71994-08-01 12:15:30 +0000869
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000870 # Accept the important Cygnus configure options, so we can diagnose typos.
871
Martin v. Löwiseba40652007-08-30 20:10:57 +0000872 case $ac_dashdash$ac_option in
873 --)
874 ac_dashdash=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000875
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000876 -bindir | --bindir | --bindi | --bind | --bin | --bi)
877 ac_prev=bindir ;;
878 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000879 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000880
881 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000882 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000883 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000884 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000885
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000886 -cache-file | --cache-file | --cache-fil | --cache-fi \
887 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
888 ac_prev=cache_file ;;
889 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
890 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000891 cache_file=$ac_optarg ;;
892
893 --config-cache | -C)
894 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000895
Martin v. Löwiseba40652007-08-30 20:10:57 +0000896 -datadir | --datadir | --datadi | --datad)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000897 ac_prev=datadir ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000898 -datadir=* | --datadir=* | --datadi=* | --datad=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000899 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000900
Martin v. Löwiseba40652007-08-30 20:10:57 +0000901 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
902 | --dataroo | --dataro | --datar)
903 ac_prev=datarootdir ;;
904 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
905 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
906 datarootdir=$ac_optarg ;;
907
Guido van Rossum7f43da71994-08-01 12:15:30 +0000908 -disable-* | --disable-*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000909 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000910 # Reject names that are not valid shell variable names.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000911 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
912 { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000913 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000914 ac_useropt_orig=$ac_useropt
915 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
916 case $ac_user_opts in
917 *"
918"enable_$ac_useropt"
919"*) ;;
920 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
921 ac_unrecognized_sep=', ';;
922 esac
923 eval enable_$ac_useropt=no ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000924
925 -docdir | --docdir | --docdi | --doc | --do)
926 ac_prev=docdir ;;
927 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
928 docdir=$ac_optarg ;;
929
930 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
931 ac_prev=dvidir ;;
932 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
933 dvidir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000934
935 -enable-* | --enable-*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000936 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000937 # Reject names that are not valid shell variable names.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000938 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
939 { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000940 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000941 ac_useropt_orig=$ac_useropt
942 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
943 case $ac_user_opts in
944 *"
945"enable_$ac_useropt"
946"*) ;;
947 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
948 ac_unrecognized_sep=', ';;
949 esac
950 eval enable_$ac_useropt=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000951
Guido van Rossum7f43da71994-08-01 12:15:30 +0000952 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
953 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
954 | --exec | --exe | --ex)
955 ac_prev=exec_prefix ;;
956 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
957 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
958 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000959 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000960
961 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000962 # Obsolete; use --with-gas.
963 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000964
Martin v. Löwis11437992002-04-12 09:54:03 +0000965 -help | --help | --hel | --he | -h)
966 ac_init_help=long ;;
967 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
968 ac_init_help=recursive ;;
969 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
970 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000971
972 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +0000973 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000974 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000975 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000976
Martin v. Löwiseba40652007-08-30 20:10:57 +0000977 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
978 ac_prev=htmldir ;;
979 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
980 | --ht=*)
981 htmldir=$ac_optarg ;;
982
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000983 -includedir | --includedir | --includedi | --included | --include \
984 | --includ | --inclu | --incl | --inc)
985 ac_prev=includedir ;;
986 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
987 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000988 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000989
990 -infodir | --infodir | --infodi | --infod | --info | --inf)
991 ac_prev=infodir ;;
992 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000993 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000994
995 -libdir | --libdir | --libdi | --libd)
996 ac_prev=libdir ;;
997 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000998 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000999
1000 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1001 | --libexe | --libex | --libe)
1002 ac_prev=libexecdir ;;
1003 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1004 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001005 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001006
Martin v. Löwiseba40652007-08-30 20:10:57 +00001007 -localedir | --localedir | --localedi | --localed | --locale)
1008 ac_prev=localedir ;;
1009 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1010 localedir=$ac_optarg ;;
1011
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001012 -localstatedir | --localstatedir | --localstatedi | --localstated \
Martin v. Löwiseba40652007-08-30 20:10:57 +00001013 | --localstate | --localstat | --localsta | --localst | --locals)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001014 ac_prev=localstatedir ;;
1015 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
Martin v. Löwiseba40652007-08-30 20:10:57 +00001016 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001017 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001018
1019 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1020 ac_prev=mandir ;;
1021 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001022 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001023
Guido van Rossum7f43da71994-08-01 12:15:30 +00001024 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001025 # Obsolete; use --without-fp.
1026 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001027
1028 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +00001029 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +00001030 no_create=yes ;;
1031
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001032 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1033 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1034 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001035
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001036 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1037 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1038 | --oldin | --oldi | --old | --ol | --o)
1039 ac_prev=oldincludedir ;;
1040 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1041 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1042 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001043 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001044
Guido van Rossum7f43da71994-08-01 12:15:30 +00001045 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1046 ac_prev=prefix ;;
1047 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001048 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001049
1050 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1051 | --program-pre | --program-pr | --program-p)
1052 ac_prev=program_prefix ;;
1053 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1054 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001055 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001056
1057 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1058 | --program-suf | --program-su | --program-s)
1059 ac_prev=program_suffix ;;
1060 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1061 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001062 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001063
1064 -program-transform-name | --program-transform-name \
1065 | --program-transform-nam | --program-transform-na \
1066 | --program-transform-n | --program-transform- \
1067 | --program-transform | --program-transfor \
1068 | --program-transfo | --program-transf \
1069 | --program-trans | --program-tran \
1070 | --progr-tra | --program-tr | --program-t)
1071 ac_prev=program_transform_name ;;
1072 -program-transform-name=* | --program-transform-name=* \
1073 | --program-transform-nam=* | --program-transform-na=* \
1074 | --program-transform-n=* | --program-transform-=* \
1075 | --program-transform=* | --program-transfor=* \
1076 | --program-transfo=* | --program-transf=* \
1077 | --program-trans=* | --program-tran=* \
1078 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001079 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001080
Martin v. Löwiseba40652007-08-30 20:10:57 +00001081 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1082 ac_prev=pdfdir ;;
1083 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1084 pdfdir=$ac_optarg ;;
1085
1086 -psdir | --psdir | --psdi | --psd | --ps)
1087 ac_prev=psdir ;;
1088 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1089 psdir=$ac_optarg ;;
1090
Guido van Rossum7f43da71994-08-01 12:15:30 +00001091 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1092 | -silent | --silent | --silen | --sile | --sil)
1093 silent=yes ;;
1094
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001095 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1096 ac_prev=sbindir ;;
1097 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1098 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001099 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001100
1101 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1102 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1103 | --sharedst | --shareds | --shared | --share | --shar \
1104 | --sha | --sh)
1105 ac_prev=sharedstatedir ;;
1106 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1107 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1108 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1109 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001110 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001111
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001112 -site | --site | --sit)
1113 ac_prev=site ;;
1114 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001115 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001116
Guido van Rossum7f43da71994-08-01 12:15:30 +00001117 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1118 ac_prev=srcdir ;;
1119 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001120 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001121
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001122 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1123 | --syscon | --sysco | --sysc | --sys | --sy)
1124 ac_prev=sysconfdir ;;
1125 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1126 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001127 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001128
Guido van Rossum7f43da71994-08-01 12:15:30 +00001129 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +00001130 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001131 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001133
1134 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1135 verbose=yes ;;
1136
Martin v. Löwis11437992002-04-12 09:54:03 +00001137 -version | --version | --versio | --versi | --vers | -V)
1138 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001139
1140 -with-* | --with-*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001141 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001142 # Reject names that are not valid shell variable names.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001143 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1144 { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001145 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001146 ac_useropt_orig=$ac_useropt
1147 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1148 case $ac_user_opts in
1149 *"
1150"with_$ac_useropt"
1151"*) ;;
1152 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1153 ac_unrecognized_sep=', ';;
1154 esac
1155 eval with_$ac_useropt=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001156
1157 -without-* | --without-*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001158 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001159 # Reject names that are not valid shell variable names.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001160 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1161 { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001162 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001163 ac_useropt_orig=$ac_useropt
1164 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1165 case $ac_user_opts in
1166 *"
1167"with_$ac_useropt"
1168"*) ;;
1169 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1170 ac_unrecognized_sep=', ';;
1171 esac
1172 eval with_$ac_useropt=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001173
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001174 --x)
1175 # Obsolete; use --with-x.
1176 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001177
1178 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1179 | --x-incl | --x-inc | --x-in | --x-i)
1180 ac_prev=x_includes ;;
1181 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1182 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001183 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001184
1185 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1186 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1187 ac_prev=x_libraries ;;
1188 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1189 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001190 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001191
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001192 -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
Martin v. Löwis11437992002-04-12 09:54:03 +00001193Try \`$0 --help' for more information." >&2
1194 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001195 ;;
1196
Martin v. Löwis11437992002-04-12 09:54:03 +00001197 *=*)
1198 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1199 # Reject names that are not valid shell variable names.
1200 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001201 { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001202 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00001203 eval $ac_envvar=\$ac_optarg
Martin v. Löwis11437992002-04-12 09:54:03 +00001204 export $ac_envvar ;;
1205
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001206 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001207 # FIXME: should be removed in autoconf 3.0.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001208 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001209 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001210 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001211 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
Guido van Rossum7f43da71994-08-01 12:15:30 +00001212 ;;
1213
1214 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +00001215done
1216
Guido van Rossum7f43da71994-08-01 12:15:30 +00001217if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001218 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001219 { $as_echo "$as_me: error: missing argument to $ac_option" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001220 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001221fi
1222
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001223if test -n "$ac_unrecognized_opts"; then
1224 case $enable_option_checking in
1225 no) ;;
1226 fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1227 { (exit 1); exit 1; }; } ;;
1228 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1229 esac
1230fi
1231
1232# Check all directory arguments for consistency.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001233for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1234 datadir sysconfdir sharedstatedir localstatedir includedir \
1235 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1236 libdir localedir mandir
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001237do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001238 eval ac_val=\$$ac_var
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001239 # Remove trailing slashes.
1240 case $ac_val in
1241 */ )
1242 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1243 eval $ac_var=\$ac_val;;
1244 esac
1245 # Be sure to have absolute directory names.
Martin v. Löwis11437992002-04-12 09:54:03 +00001246 case $ac_val in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001247 [\\/$]* | ?:[\\/]* ) continue;;
1248 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001249 esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001250 { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001251 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001252done
Guido van Rossum627b2d71993-12-24 10:39:16 +00001253
Martin v. Löwis11437992002-04-12 09:54:03 +00001254# There might be people who depend on the old broken behavior: `$host'
1255# used to hold the argument of --host etc.
1256# FIXME: To remove some day.
1257build=$build_alias
1258host=$host_alias
1259target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +00001260
Martin v. Löwis11437992002-04-12 09:54:03 +00001261# FIXME: To remove some day.
1262if test "x$host_alias" != x; then
1263 if test "x$build_alias" = x; then
1264 cross_compiling=maybe
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001265 $as_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 +00001266 If a cross compiler is detected then cross compile mode will be used." >&2
1267 elif test "x$build_alias" != "x$host_alias"; then
1268 cross_compiling=yes
1269 fi
1270fi
1271
1272ac_tool_prefix=
1273test -n "$host_alias" && ac_tool_prefix=$host_alias-
1274
1275test "$silent" = yes && exec 6>/dev/null
1276
Guido van Rossum627b2d71993-12-24 10:39:16 +00001277
Martin v. Löwiseba40652007-08-30 20:10:57 +00001278ac_pwd=`pwd` && test -n "$ac_pwd" &&
1279ac_ls_di=`ls -di .` &&
1280ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001281 { $as_echo "$as_me: error: working directory cannot be determined" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001282 { (exit 1); exit 1; }; }
1283test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001284 { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001285 { (exit 1); exit 1; }; }
1286
1287
Guido van Rossum627b2d71993-12-24 10:39:16 +00001288# Find the source files, if location was not specified.
1289if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00001290 ac_srcdir_defaulted=yes
Martin v. Löwiseba40652007-08-30 20:10:57 +00001291 # Try the directory containing this script, then the parent directory.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001292 ac_confdir=`$as_dirname -- "$as_myself" ||
1293$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1294 X"$as_myself" : 'X\(//\)[^/]' \| \
1295 X"$as_myself" : 'X\(//\)$' \| \
1296 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1297$as_echo X"$as_myself" |
Martin v. Löwiseba40652007-08-30 20:10:57 +00001298 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1299 s//\1/
1300 q
1301 }
1302 /^X\(\/\/\)[^/].*/{
1303 s//\1/
1304 q
1305 }
1306 /^X\(\/\/\)$/{
1307 s//\1/
1308 q
1309 }
1310 /^X\(\/\).*/{
1311 s//\1/
1312 q
1313 }
1314 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001315 srcdir=$ac_confdir
Martin v. Löwiseba40652007-08-30 20:10:57 +00001316 if test ! -r "$srcdir/$ac_unique_file"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001317 srcdir=..
1318 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001319else
1320 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001321fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001322if test ! -r "$srcdir/$ac_unique_file"; then
1323 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001324 { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001325 { (exit 1); exit 1; }; }
Brett Cannon19fab762007-06-02 03:02:29 +00001326fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001327ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1328ac_abs_confdir=`(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001329 cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
Skip Montanaro89e975f2007-08-22 19:05:21 +00001330 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00001331 pwd)`
1332# When building in place, set srcdir=.
1333if test "$ac_abs_confdir" = "$ac_pwd"; then
1334 srcdir=.
1335fi
1336# Remove unnecessary trailing slashes from srcdir.
1337# Double slashes in file names in object file debugging info
1338# mess up M-x gdb in Emacs.
1339case $srcdir in
1340*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1341esac
1342for ac_var in $ac_precious_vars; do
1343 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1344 eval ac_env_${ac_var}_value=\$${ac_var}
1345 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1346 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1347done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001348
Martin v. Löwis11437992002-04-12 09:54:03 +00001349#
1350# Report the --help message.
1351#
1352if test "$ac_init_help" = "long"; then
1353 # Omit some internal or obsolete options to make the list less imposing.
1354 # This message is too long to be a string in the A/UX 3.1 sh.
1355 cat <<_ACEOF
Martin v. Löwis174440b2008-10-03 08:59:41 +00001356\`configure' configures python 2.7 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +00001357
1358Usage: $0 [OPTION]... [VAR=VALUE]...
1359
1360To assign environment variables (e.g., CC, CFLAGS...), specify them as
1361VAR=VALUE. See below for descriptions of some of the useful variables.
1362
1363Defaults for the options are specified in brackets.
1364
1365Configuration:
1366 -h, --help display this help and exit
1367 --help=short display options specific to this package
1368 --help=recursive display the short help of all the included packages
1369 -V, --version display version information and exit
1370 -q, --quiet, --silent do not print \`checking...' messages
1371 --cache-file=FILE cache test results in FILE [disabled]
1372 -C, --config-cache alias for \`--cache-file=config.cache'
1373 -n, --no-create do not create output files
1374 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1375
Martin v. Löwis11437992002-04-12 09:54:03 +00001376Installation directories:
1377 --prefix=PREFIX install architecture-independent files in PREFIX
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001378 [$ac_default_prefix]
Martin v. Löwis11437992002-04-12 09:54:03 +00001379 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001380 [PREFIX]
Martin v. Löwis11437992002-04-12 09:54:03 +00001381
1382By default, \`make install' will install all the files in
1383\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1384an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1385for instance \`--prefix=\$HOME'.
1386
1387For better control, use the options below.
1388
1389Fine tuning of the installation directories:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001390 --bindir=DIR user executables [EPREFIX/bin]
1391 --sbindir=DIR system admin executables [EPREFIX/sbin]
1392 --libexecdir=DIR program executables [EPREFIX/libexec]
1393 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1394 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1395 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1396 --libdir=DIR object code libraries [EPREFIX/lib]
1397 --includedir=DIR C header files [PREFIX/include]
1398 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1399 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1400 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1401 --infodir=DIR info documentation [DATAROOTDIR/info]
1402 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1403 --mandir=DIR man documentation [DATAROOTDIR/man]
1404 --docdir=DIR documentation root [DATAROOTDIR/doc/python]
1405 --htmldir=DIR html documentation [DOCDIR]
1406 --dvidir=DIR dvi documentation [DOCDIR]
1407 --pdfdir=DIR pdf documentation [DOCDIR]
1408 --psdir=DIR ps documentation [DOCDIR]
Martin v. Löwis11437992002-04-12 09:54:03 +00001409_ACEOF
1410
1411 cat <<\_ACEOF
1412_ACEOF
1413fi
1414
1415if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +00001416 case $ac_init_help in
Martin v. Löwis174440b2008-10-03 08:59:41 +00001417 short | recursive ) echo "Configuration of python 2.7:";;
Martin v. Löwis88afe662002-10-26 13:47:44 +00001418 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001419 cat <<\_ACEOF
1420
1421Optional Features:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001422 --disable-option-checking ignore unrecognized --enable/--with options
Martin v. Löwis11437992002-04-12 09:54:03 +00001423 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1424 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Brett Cannon91a1dec2008-02-13 19:15:44 +00001425 --enable-universalsdk[=SDKDIR]
Brett Cannon9a8bb0e2008-02-03 02:07:55 +00001426 Build against Mac OS X 10.4u SDK (ppc/i386)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001427 --enable-framework[=INSTALLDIR]
1428 Build (MacOSX|Darwin) framework
1429 --enable-shared disable/enable building shared python library
Skip Montanaro56f6a4f2004-06-18 02:47:22 +00001430 --enable-profiling enable C-level code profiling
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001431 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
1432 --enable-ipv6 Enable ipv6 (with ipv4) support
1433 --disable-ipv6 Disable ipv6 support
Mark Dickinsonefc82f72009-03-20 15:51:55 +00001434 --enable-big-digits[=BITS]
1435 use big digits for Python longs [BITS=30]
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001436 --enable-unicode[=ucs[24]]
1437 Enable Unicode strings (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +00001438
1439Optional Packages:
1440 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1441 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001442 --with-universal-archs=ARCH
1443 select architectures for universal build ("32-bit",
1444 "64-bit" or "all")
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00001445 --with-framework-name=FRAMEWORK
1446 specify an alternate name of the framework built
1447 with --enable-framework
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001448 --without-gcc never use gcc
Martin v. Löwis0f48d982006-04-14 14:34:26 +00001449 --with-cxx-main=<compiler>
1450 compile main() and link python executable with C++
1451 compiler
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001452 --with-suffix=.exe set executable suffix
1453 --with-pydebug build with Py_DEBUG defined
1454 --with-libs='lib1 ...' link against additional libs
Martin v. Löwis9176fc12006-04-11 11:12:43 +00001455 --with-system-ffi build _ctypes module using an installed ffi library
Benjamin Peterson867475c2009-04-29 20:36:25 +00001456 --with-dbmliborder=db1:db2:...
1457 order to check db backends for dbm. Valid value is a
1458 colon separated string with the backend names
1459 `ndbm', `gdbm' and `bdb'.
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001460 --with-signal-module disable/enable signal module
1461 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
1462 --with(out)-threads[=DIRECTORY]
1463 disable/enable thread support
1464 --with(out)-thread[=DIRECTORY]
1465 deprecated; use --with(out)-threads
1466 --with-pth use GNU pth threading libraries
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001467 --with(out)-doc-strings disable/enable documentation strings
Martin v. Löwisf30d60e2004-06-08 08:17:44 +00001468 --with(out)-tsc enable/disable timestamp counter profile
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001469 --with(out)-pymalloc disable/enable specialized mallocs
1470 --with-wctype-functions use wctype.h functions
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001471 --with-fpectl enable SIGFPE catching
1472 --with-libm=STRING math library
1473 --with-libc=STRING C library
Martin v. Löwis11437992002-04-12 09:54:03 +00001474
1475Some influential environment variables:
1476 CC C compiler command
1477 CFLAGS C compiler flags
1478 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1479 nonstandard directory <lib dir>
Martin v. Löwiseba40652007-08-30 20:10:57 +00001480 LIBS libraries to pass to the linker, e.g. -l<library>
1481 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1482 you have headers in a nonstandard directory <include dir>
Martin v. Löwis11437992002-04-12 09:54:03 +00001483 CPP C preprocessor
1484
1485Use these variables to override the choices made by `configure' or to help
1486it to find libraries and programs with nonstandard names/locations.
1487
Georg Brandl464432d2009-05-20 18:24:08 +00001488Report bugs to <http://bugs.python.org/>.
Martin v. Löwis11437992002-04-12 09:54:03 +00001489_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001490ac_status=$?
Martin v. Löwis11437992002-04-12 09:54:03 +00001491fi
1492
1493if test "$ac_init_help" = "recursive"; then
1494 # If there are subdirs, report their specific --help.
Martin v. Löwis11437992002-04-12 09:54:03 +00001495 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001496 test -d "$ac_dir" ||
1497 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1498 continue
Martin v. Löwis11437992002-04-12 09:54:03 +00001499 ac_builddir=.
1500
Martin v. Löwiseba40652007-08-30 20:10:57 +00001501case "$ac_dir" in
1502.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1503*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001504 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001505 # A ".." for each directory in $ac_dir_suffix.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001506 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001507 case $ac_top_builddir_sub in
1508 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1509 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1510 esac ;;
1511esac
1512ac_abs_top_builddir=$ac_pwd
1513ac_abs_builddir=$ac_pwd$ac_dir_suffix
1514# for backward compatibility:
1515ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +00001516
1517case $srcdir in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001518 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +00001519 ac_srcdir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001520 ac_top_srcdir=$ac_top_builddir_sub
1521 ac_abs_top_srcdir=$ac_pwd ;;
1522 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +00001523 ac_srcdir=$srcdir$ac_dir_suffix;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001524 ac_top_srcdir=$srcdir
1525 ac_abs_top_srcdir=$srcdir ;;
1526 *) # Relative name.
1527 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1528 ac_top_srcdir=$ac_top_build_prefix$srcdir
1529 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001530esac
Martin v. Löwiseba40652007-08-30 20:10:57 +00001531ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +00001532
Martin v. Löwiseba40652007-08-30 20:10:57 +00001533 cd "$ac_dir" || { ac_status=$?; continue; }
1534 # Check for guested configure.
1535 if test -f "$ac_srcdir/configure.gnu"; then
1536 echo &&
1537 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1538 elif test -f "$ac_srcdir/configure"; then
1539 echo &&
1540 $SHELL "$ac_srcdir/configure" --help=recursive
Martin v. Löwis11437992002-04-12 09:54:03 +00001541 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001542 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001543 fi || ac_status=$?
1544 cd "$ac_pwd" || { ac_status=$?; break; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001545 done
1546fi
1547
Martin v. Löwiseba40652007-08-30 20:10:57 +00001548test -n "$ac_init_help" && exit $ac_status
Martin v. Löwis11437992002-04-12 09:54:03 +00001549if $ac_init_version; then
1550 cat <<\_ACEOF
Martin v. Löwis174440b2008-10-03 08:59:41 +00001551python configure 2.7
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001552generated by GNU Autoconf 2.63
Martin v. Löwis11437992002-04-12 09:54:03 +00001553
Martin v. Löwiseba40652007-08-30 20:10:57 +00001554Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015552002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +00001556This configure script is free software; the Free Software Foundation
1557gives unlimited permission to copy, distribute and modify it.
1558_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001559 exit
Martin v. Löwis11437992002-04-12 09:54:03 +00001560fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001561cat >config.log <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +00001562This file contains any messages produced by compilers while
1563running configure, to aid debugging if configure makes a mistake.
1564
Martin v. Löwis174440b2008-10-03 08:59:41 +00001565It was created by python $as_me 2.7, which was
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001566generated by GNU Autoconf 2.63. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +00001567
1568 $ $0 $@
1569
1570_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001571exec 5>>config.log
Martin v. Löwis11437992002-04-12 09:54:03 +00001572{
1573cat <<_ASUNAME
1574## --------- ##
1575## Platform. ##
1576## --------- ##
1577
1578hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1579uname -m = `(uname -m) 2>/dev/null || echo unknown`
1580uname -r = `(uname -r) 2>/dev/null || echo unknown`
1581uname -s = `(uname -s) 2>/dev/null || echo unknown`
1582uname -v = `(uname -v) 2>/dev/null || echo unknown`
1583
1584/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1585/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1586
1587/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1588/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1589/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001590/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
Martin v. Löwis11437992002-04-12 09:54:03 +00001591/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1592/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1593/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1594
1595_ASUNAME
1596
1597as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1598for as_dir in $PATH
1599do
1600 IFS=$as_save_IFS
1601 test -z "$as_dir" && as_dir=.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001602 $as_echo "PATH: $as_dir"
Martin v. Löwis11437992002-04-12 09:54:03 +00001603done
Martin v. Löwiseba40652007-08-30 20:10:57 +00001604IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00001605
1606} >&5
1607
1608cat >&5 <<_ACEOF
1609
1610
1611## ----------- ##
1612## Core tests. ##
1613## ----------- ##
1614
1615_ACEOF
1616
1617
1618# Keep a trace of the command line.
1619# Strip out --no-create and --no-recursion so they do not pile up.
Skip Montanaro6dead952003-09-25 14:50:04 +00001620# Strip out --silent because we don't want to record it for future runs.
Martin v. Löwis11437992002-04-12 09:54:03 +00001621# Also quote any args containing shell meta-characters.
Skip Montanaro6dead952003-09-25 14:50:04 +00001622# Make two passes to allow for proper duplicate-argument suppression.
Martin v. Löwis11437992002-04-12 09:54:03 +00001623ac_configure_args=
Skip Montanaro6dead952003-09-25 14:50:04 +00001624ac_configure_args0=
1625ac_configure_args1=
Skip Montanaro6dead952003-09-25 14:50:04 +00001626ac_must_keep_next=false
1627for ac_pass in 1 2
Martin v. Löwis11437992002-04-12 09:54:03 +00001628do
Skip Montanaro6dead952003-09-25 14:50:04 +00001629 for ac_arg
1630 do
1631 case $ac_arg in
1632 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1633 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1634 | -silent | --silent | --silen | --sile | --sil)
1635 continue ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001636 *\'*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001637 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00001638 esac
1639 case $ac_pass in
1640 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1641 2)
1642 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1643 if test $ac_must_keep_next = true; then
Skip Montanarof0d5f792004-08-15 14:08:23 +00001644 ac_must_keep_next=false # Got value, back to normal.
Skip Montanaro6dead952003-09-25 14:50:04 +00001645 else
Skip Montanarof0d5f792004-08-15 14:08:23 +00001646 case $ac_arg in
1647 *=* | --config-cache | -C | -disable-* | --disable-* \
1648 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1649 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1650 | -with-* | --with-* | -without-* | --without-* | --x)
1651 case "$ac_configure_args0 " in
1652 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1653 esac
1654 ;;
1655 -* ) ac_must_keep_next=true ;;
1656 esac
Skip Montanaro6dead952003-09-25 14:50:04 +00001657 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001658 ac_configure_args="$ac_configure_args '$ac_arg'"
Skip Montanaro6dead952003-09-25 14:50:04 +00001659 ;;
1660 esac
1661 done
Martin v. Löwis11437992002-04-12 09:54:03 +00001662done
Skip Montanaro6dead952003-09-25 14:50:04 +00001663$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1664$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 +00001665
1666# When interrupted or exit'd, cleanup temporary files, and complete
1667# config.log. We remove comments because anyway the quotes in there
1668# would cause problems or look ugly.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001669# WARNING: Use '\'' to represent an apostrophe within the trap.
1670# 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 +00001671trap 'exit_status=$?
1672 # Save into config.log some information that might help in debugging.
1673 {
1674 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00001675
Martin v. Löwis11437992002-04-12 09:54:03 +00001676 cat <<\_ASBOX
1677## ---------------- ##
1678## Cache variables. ##
1679## ---------------- ##
1680_ASBOX
1681 echo
1682 # The following way of writing the cache mishandles newlines in values,
Martin v. Löwiseba40652007-08-30 20:10:57 +00001683(
1684 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1685 eval ac_val=\$$ac_var
1686 case $ac_val in #(
1687 *${as_nl}*)
1688 case $ac_var in #(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001689 *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1690$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001691 esac
1692 case $ac_var in #(
1693 _ | IFS | as_nl) ;; #(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001694 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
Martin v. Löwiseba40652007-08-30 20:10:57 +00001695 *) $as_unset $ac_var ;;
1696 esac ;;
1697 esac
1698 done
Martin v. Löwis11437992002-04-12 09:54:03 +00001699 (set) 2>&1 |
Martin v. Löwiseba40652007-08-30 20:10:57 +00001700 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1701 *${as_nl}ac_space=\ *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001702 sed -n \
Martin v. Löwiseba40652007-08-30 20:10:57 +00001703 "s/'\''/'\''\\\\'\'''\''/g;
1704 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1705 ;; #(
Skip Montanaro89e975f2007-08-22 19:05:21 +00001706 *)
Martin v. Löwiseba40652007-08-30 20:10:57 +00001707 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Skip Montanaro89e975f2007-08-22 19:05:21 +00001708 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001709 esac |
1710 sort
1711)
Martin v. Löwis11437992002-04-12 09:54:03 +00001712 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00001713
1714 cat <<\_ASBOX
1715## ----------------- ##
1716## Output variables. ##
1717## ----------------- ##
1718_ASBOX
1719 echo
1720 for ac_var in $ac_subst_vars
1721 do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001722 eval ac_val=\$$ac_var
1723 case $ac_val in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001724 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001725 esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001726 $as_echo "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00001727 done | sort
1728 echo
1729
1730 if test -n "$ac_subst_files"; then
1731 cat <<\_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00001732## ------------------- ##
1733## File substitutions. ##
1734## ------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00001735_ASBOX
1736 echo
1737 for ac_var in $ac_subst_files
1738 do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001739 eval ac_val=\$$ac_var
1740 case $ac_val in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001741 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001742 esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001743 $as_echo "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00001744 done | sort
1745 echo
1746 fi
1747
Martin v. Löwis11437992002-04-12 09:54:03 +00001748 if test -s confdefs.h; then
1749 cat <<\_ASBOX
1750## ----------- ##
1751## confdefs.h. ##
1752## ----------- ##
1753_ASBOX
1754 echo
Martin v. Löwiseba40652007-08-30 20:10:57 +00001755 cat confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00001756 echo
1757 fi
1758 test "$ac_signal" != 0 &&
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001759 $as_echo "$as_me: caught signal $ac_signal"
1760 $as_echo "$as_me: exit $exit_status"
Martin v. Löwis11437992002-04-12 09:54:03 +00001761 } >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00001762 rm -f core *.core core.conftest.* &&
1763 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
Martin v. Löwis11437992002-04-12 09:54:03 +00001764 exit $exit_status
Martin v. Löwiseba40652007-08-30 20:10:57 +00001765' 0
Martin v. Löwis11437992002-04-12 09:54:03 +00001766for ac_signal in 1 2 13 15; do
1767 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1768done
1769ac_signal=0
1770
1771# confdefs.h avoids OS command line length limits that DEFS can exceed.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001772rm -f -r conftest* confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00001773
1774# Predefined preprocessor variables.
1775
1776cat >>confdefs.h <<_ACEOF
1777#define PACKAGE_NAME "$PACKAGE_NAME"
1778_ACEOF
1779
1780
1781cat >>confdefs.h <<_ACEOF
1782#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1783_ACEOF
1784
1785
1786cat >>confdefs.h <<_ACEOF
1787#define PACKAGE_VERSION "$PACKAGE_VERSION"
1788_ACEOF
1789
1790
1791cat >>confdefs.h <<_ACEOF
1792#define PACKAGE_STRING "$PACKAGE_STRING"
1793_ACEOF
1794
1795
1796cat >>confdefs.h <<_ACEOF
1797#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1798_ACEOF
1799
1800
1801# Let the site file select an alternate cache file if it wants to.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001802# Prefer an explicitly selected file to automatically selected ones.
1803ac_site_file1=NONE
1804ac_site_file2=NONE
Martin v. Löwiseba40652007-08-30 20:10:57 +00001805if test -n "$CONFIG_SITE"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001806 ac_site_file1=$CONFIG_SITE
Martin v. Löwiseba40652007-08-30 20:10:57 +00001807elif test "x$prefix" != xNONE; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001808 ac_site_file1=$prefix/share/config.site
1809 ac_site_file2=$prefix/etc/config.site
Martin v. Löwiseba40652007-08-30 20:10:57 +00001810else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001811 ac_site_file1=$ac_default_prefix/share/config.site
1812 ac_site_file2=$ac_default_prefix/etc/config.site
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001813fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001814for ac_site_file in "$ac_site_file1" "$ac_site_file2"
Martin v. Löwiseba40652007-08-30 20:10:57 +00001815do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001816 test "x$ac_site_file" = xNONE && continue
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001817 if test -r "$ac_site_file"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001818 { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1819$as_echo "$as_me: loading site script $ac_site_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001820 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001821 . "$ac_site_file"
1822 fi
1823done
1824
1825if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001826 # Some versions of bash will fail to source /dev/null (special
1827 # files actually), so we avoid doing that.
1828 if test -f "$cache_file"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001829 { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1830$as_echo "$as_me: loading cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001831 case $cache_file in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001832 [\\/]* | ?:[\\/]* ) . "$cache_file";;
1833 *) . "./$cache_file";;
Martin v. Löwis11437992002-04-12 09:54:03 +00001834 esac
1835 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001836else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001837 { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1838$as_echo "$as_me: creating cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001839 >$cache_file
1840fi
1841
1842# Check that the precious variables saved in the cache have kept the same
1843# value.
1844ac_cache_corrupted=false
Martin v. Löwiseba40652007-08-30 20:10:57 +00001845for ac_var in $ac_precious_vars; do
Martin v. Löwis11437992002-04-12 09:54:03 +00001846 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1847 eval ac_new_set=\$ac_env_${ac_var}_set
Martin v. Löwiseba40652007-08-30 20:10:57 +00001848 eval ac_old_val=\$ac_cv_env_${ac_var}_value
1849 eval ac_new_val=\$ac_env_${ac_var}_value
Martin v. Löwis11437992002-04-12 09:54:03 +00001850 case $ac_old_set,$ac_new_set in
1851 set,)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001852 { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1853$as_echo "$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 +00001854 ac_cache_corrupted=: ;;
1855 ,set)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001856 { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1857$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001858 ac_cache_corrupted=: ;;
1859 ,);;
1860 *)
1861 if test "x$ac_old_val" != "x$ac_new_val"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001862 # differences in whitespace do not lead to failure.
1863 ac_old_val_w=`echo x $ac_old_val`
1864 ac_new_val_w=`echo x $ac_new_val`
1865 if test "$ac_old_val_w" != "$ac_new_val_w"; then
1866 { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1867$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1868 ac_cache_corrupted=:
1869 else
1870 { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1871$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1872 eval $ac_var=\$ac_old_val
1873 fi
1874 { $as_echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5
1875$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
1876 { $as_echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5
1877$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001878 fi;;
1879 esac
1880 # Pass precious variables to config.status.
1881 if test "$ac_new_set" = set; then
1882 case $ac_new_val in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001883 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001884 *) ac_arg=$ac_var=$ac_new_val ;;
1885 esac
1886 case " $ac_configure_args " in
1887 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1888 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1889 esac
1890 fi
1891done
1892if $ac_cache_corrupted; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00001893 { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1894$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1895 { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1896$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1897 { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1898$as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001899 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001900fi
1901
Martin v. Löwiseba40652007-08-30 20:10:57 +00001902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
Guido van Rossum7f43da71994-08-01 12:15:30 +00001926ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001927ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001928ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1929ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1930ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001931
Guido van Rossum627b2d71993-12-24 10:39:16 +00001932
Michael W. Hudson54241132001-12-07 15:38:26 +00001933
Martin v. Löwiseba40652007-08-30 20:10:57 +00001934ac_config_headers="$ac_config_headers pyconfig.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00001935
1936
Martin v. Löwis11437992002-04-12 09:54:03 +00001937
Georg Brandlbcd64a32009-03-31 21:45:18 +00001938if test "$prefix" != "/"; then
1939 prefix=`echo "$prefix" | sed -e 's/\/$//g'`
1940fi
1941
1942
Martin v. Löwis11437992002-04-12 09:54:03 +00001943
1944
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001945
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001946
Martin v. Löwis8316feb2003-06-14 07:48:07 +00001947# We don't use PACKAGE_ variables, and they cause conflicts
1948# with other autoconf-based packages that include Python.h
1949grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new
1950rm confdefs.h
1951mv confdefs.h.new confdefs.h
1952
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001953
Martin v. Löwis174440b2008-10-03 08:59:41 +00001954VERSION=2.7
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001955
Martin v. Löwis1142de32002-03-29 16:28:31 +00001956
1957SOVERSION=1.0
1958
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001959# The later defininition of _XOPEN_SOURCE disables certain features
1960# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1961
1962cat >>confdefs.h <<\_ACEOF
1963#define _GNU_SOURCE 1
1964_ACEOF
1965
1966
Martin v. Löwisbcd93962003-05-03 10:32:18 +00001967# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1968# certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable
1969# them.
1970
1971cat >>confdefs.h <<\_ACEOF
1972#define _NETBSD_SOURCE 1
1973_ACEOF
1974
1975
Andrew MacIntyreabccf412003-07-02 13:53:25 +00001976# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1977# certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable
1978# them.
1979
1980cat >>confdefs.h <<\_ACEOF
1981#define __BSD_VISIBLE 1
1982_ACEOF
1983
1984
Martin v. Löwisd6320502004-08-12 13:45:08 +00001985# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1986# u_int on Irix 5.3. Defining _BSD_TYPES brings it back.
1987
1988cat >>confdefs.h <<\_ACEOF
1989#define _BSD_TYPES 1
1990_ACEOF
1991
1992
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001993# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1994# certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable
1995# them.
1996
1997cat >>confdefs.h <<\_ACEOF
1998#define _DARWIN_C_SOURCE 1
1999_ACEOF
2000
2001
2002
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002003define_xopen_source=yes
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00002004
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00002005# Arguments passed to configure.
2006
2007CONFIG_ARGS="$ac_configure_args"
2008
Martin v. Löwiseba40652007-08-30 20:10:57 +00002009# Check whether --enable-universalsdk was given.
Ronald Oussoren988117f2006-04-29 11:31:35 +00002010if test "${enable_universalsdk+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002011 enableval=$enable_universalsdk;
Ronald Oussoren988117f2006-04-29 11:31:35 +00002012 case $enableval in
2013 yes)
2014 enableval=/Developer/SDKs/MacOSX10.4u.sdk
2015 ;;
2016 esac
2017 case $enableval in
2018 no)
2019 UNIVERSALSDK=
2020 enable_universalsdk=
2021 ;;
2022 *)
2023 UNIVERSALSDK=$enableval
2024 ;;
2025 esac
2026
2027else
2028
2029 UNIVERSALSDK=
2030 enable_universalsdk=
2031
Martin v. Löwiseba40652007-08-30 20:10:57 +00002032fi
Ronald Oussoren988117f2006-04-29 11:31:35 +00002033
2034
Martin v. Löwiseba40652007-08-30 20:10:57 +00002035
Benjamin Peterson0e6ea5d2008-07-16 20:17:04 +00002036ARCH_RUN_32BIT=
2037
2038
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002039UNIVERSAL_ARCHS="32-bit"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002040{ $as_echo "$as_me:$LINENO: checking for --with-universal-archs" >&5
2041$as_echo_n "checking for --with-universal-archs... " >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002042
2043# Check whether --with-universal-archs was given.
2044if test "${with_universal_archs+set}" = set; then
2045 withval=$with_universal_archs;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002046 { $as_echo "$as_me:$LINENO: result: $withval" >&5
2047$as_echo "$withval" >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002048 UNIVERSAL_ARCHS="$withval"
2049
2050else
2051
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002052 { $as_echo "$as_me:$LINENO: result: 32-bit" >&5
2053$as_echo "32-bit" >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002054
2055fi
2056
2057
2058
2059
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002060
2061# Check whether --with-framework-name was given.
2062if test "${with_framework_name+set}" = set; then
2063 withval=$with_framework_name;
2064 PYTHONFRAMEWORK=${withval}
2065 PYTHONFRAMEWORKDIR=${withval}.framework
2066 PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'`
2067
2068else
2069
2070 PYTHONFRAMEWORK=Python
2071 PYTHONFRAMEWORKDIR=Python.framework
2072 PYTHONFRAMEWORKIDENTIFIER=org.python.python
2073
2074fi
2075
Martin v. Löwiseba40652007-08-30 20:10:57 +00002076# Check whether --enable-framework was given.
Jack Jansene578a632001-08-15 01:27:14 +00002077if test "${enable_framework+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002078 enableval=$enable_framework;
Jack Jansene578a632001-08-15 01:27:14 +00002079 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00002080 yes)
Jack Jansene578a632001-08-15 01:27:14 +00002081 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00002082 esac
2083 case $enableval in
2084 no)
2085 PYTHONFRAMEWORK=
2086 PYTHONFRAMEWORKDIR=no-framework
2087 PYTHONFRAMEWORKPREFIX=
2088 PYTHONFRAMEWORKINSTALLDIR=
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002089 FRAMEWORKINSTALLFIRST=
2090 FRAMEWORKINSTALLLAST=
Ronald Oussoren5b787322006-06-06 19:50:24 +00002091 FRAMEWORKALTINSTALLFIRST=
2092 FRAMEWORKALTINSTALLLAST=
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00002093 if test "x${prefix}" = "xNONE"; then
2094 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
2095 else
2096 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
2097 fi
Jack Jansen127e56e2001-09-11 14:41:54 +00002098 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00002099 ;;
2100 *)
2101 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00002102 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002103 FRAMEWORKINSTALLFIRST="frameworkinstallstructure"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002104 FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure bininstall maninstall"
2105 if test "$UNIVERSAL_ARCHS" = "all"
2106 then
2107 FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps4way frameworkinstallunixtools4way"
Ronald Oussorenbb8cb0e2009-03-30 17:53:39 +00002108 FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps4way frameworkaltinstallunixtools4way"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002109 else
Ronald Oussorenbb8cb0e2009-03-30 17:53:39 +00002110 FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002111 FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools"
2112 fi
2113
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00002114 if test "x${prefix}" = "xNONE" ; then
2115 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
2116 else
2117 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
2118 fi
Jack Jansen127e56e2001-09-11 14:41:54 +00002119 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Ronald Oussoren836b0392006-05-14 19:56:34 +00002120
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002121 # Add files for Mac specific code to the list of output
Ronald Oussoren836b0392006-05-14 19:56:34 +00002122 # files:
Martin v. Löwiseba40652007-08-30 20:10:57 +00002123 ac_config_files="$ac_config_files Mac/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002124
Martin v. Löwiseba40652007-08-30 20:10:57 +00002125 ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002126
Martin v. Löwiseba40652007-08-30 20:10:57 +00002127 ac_config_files="$ac_config_files Mac/IDLE/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002128
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002129 ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist"
2130
2131 ac_config_files="$ac_config_files Mac/Resources/app/Info.plist"
2132
Jack Jansene578a632001-08-15 01:27:14 +00002133 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00002134
Guido van Rossum563e7081996-09-10 18:20:48 +00002135else
Martin v. Löwis11437992002-04-12 09:54:03 +00002136
Jack Jansene578a632001-08-15 01:27:14 +00002137 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00002138 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00002139 PYTHONFRAMEWORKPREFIX=
2140 PYTHONFRAMEWORKINSTALLDIR=
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002141 FRAMEWORKINSTALLFIRST=
2142 FRAMEWORKINSTALLLAST=
Ronald Oussoren5b787322006-06-06 19:50:24 +00002143 FRAMEWORKALTINSTALLFIRST=
2144 FRAMEWORKALTINSTALLLAST=
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00002145 if test "x${prefix}" = "xNONE" ; then
2146 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
2147 else
2148 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
2149 fi
Jack Jansene578a632001-08-15 01:27:14 +00002150 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002151
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002152 if test "$UNIVERSAL_ARCHS" = "all"
2153 then
2154 FRAMEWORKINSTALLLAST=update4wayuniversal
2155 FRAMEWORKALTINSTALLLAST=update4wayuniversal
2156 fi
2157
Martin v. Löwiseba40652007-08-30 20:10:57 +00002158fi
2159
Michael W. Hudson54241132001-12-07 15:38:26 +00002160
2161
2162
2163
Jack Jansene578a632001-08-15 01:27:14 +00002164
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002165
2166
Ronald Oussoren5b787322006-06-06 19:50:24 +00002167
2168
2169
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002170
Jack Jansene578a632001-08-15 01:27:14 +00002171##AC_ARG_WITH(dyld,
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00002172## AC_HELP_STRING(--with-dyld,
2173## Use (OpenStep|Rhapsody) dynamic linker))
Jack Jansene578a632001-08-15 01:27:14 +00002174##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002175# Set name for machine-dependent library files
2176
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002177{ $as_echo "$as_me:$LINENO: checking MACHDEP" >&5
2178$as_echo_n "checking MACHDEP... " >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002179if test -z "$MACHDEP"
2180then
Guido van Rossum563e7081996-09-10 18:20:48 +00002181 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00002182 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
2183 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00002184 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002185 else
Guido van Rossum563e7081996-09-10 18:20:48 +00002186 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002187 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00002188 ac_md_system=`echo $ac_sys_system |
2189 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
2190 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00002191 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00002192 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00002193
Guido van Rossum07397971997-04-29 21:49:50 +00002194 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00002195 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00002196 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00002197 atheos*) MACHDEP="atheos";;
Martin v. Löwisf3322282003-07-13 09:46:13 +00002198 irix646) MACHDEP="irix6";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00002199 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002200 esac
2201fi
Guido van Rossum91922671997-10-09 20:24:13 +00002202
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002203# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
2204# disable features if it is defined, without any means to access these
2205# features as extensions. For these systems, we skip the definition of
2206# _XOPEN_SOURCE. Before adding a system to the list to gain access to
2207# some feature, make sure there is no alternative way to access this
2208# feature. Also, when using wildcards, make sure you have verified the
2209# need for not defining _XOPEN_SOURCE on all systems matching the
2210# wildcard, and that the wildcard does not include future systems
2211# (which may remove their limitations).
2212case $ac_sys_system/$ac_sys_release in
2213 # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
2214 # even though select is a POSIX function. Reported by J. Ribbens.
Martin v. Löwis76bafc62003-10-03 13:47:44 +00002215 # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish.
Gregory P. Smithcc023f12008-09-07 05:15:58 +00002216 OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123])
Martin v. Löwiscb78de62007-12-29 18:49:21 +00002217 define_xopen_source=no
2218 # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
2219 # also defined. This can be overridden by defining _BSD_SOURCE
2220 # As this has a different meaning on Linux, only define it on OpenBSD
2221
2222cat >>confdefs.h <<\_ACEOF
2223#define _BSD_SOURCE 1
2224_ACEOF
2225
2226 ;;
Martin v. Löwis4d542ec2006-11-25 15:39:19 +00002227 # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of
2228 # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by
2229 # Marc Recht
Benjamin Petersoneac68f42008-11-16 17:54:55 +00002230 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 +00002231 define_xopen_source=no;;
Martin v. Löwisa9d71422003-03-28 18:43:31 +00002232 # On Solaris 2.6, sys/wait.h is inconsistent in the usage
2233 # of union __?sigval. Reported by Stuart Bishop.
2234 SunOS/5.6)
2235 define_xopen_source=no;;
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002236 # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
2237 # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
Jack Jansen6b08a402004-06-03 12:41:45 +00002238 # Reconfirmed for 7.1.4 by Martin v. Loewis.
Martin v. Löwis253d1f42004-05-07 19:14:14 +00002239 OpenUNIX/8.0.0| UnixWare/7.1.[0-4])
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002240 define_xopen_source=no;;
2241 # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
Martin v. Löwis53e73c32003-05-05 05:13:18 +00002242 # but used in struct sockaddr.sa_family. Reported by Tim Rice.
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002243 SCO_SV/3.2)
Martin v. Löwis53e73c32003-05-05 05:13:18 +00002244 define_xopen_source=no;;
Martin v. Löwisbb86d832008-11-04 20:40:09 +00002245 # On FreeBSD 4, the math functions C89 does not cover are never defined
2246 # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them.
2247 FreeBSD/4.*)
2248 define_xopen_source=no;;
2249 # On MacOS X 10.2, a bug in ncurses.h means that it craps out if
2250 # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which
2251 # identifies itself as Darwin/7.*
2252 # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
2253 # disables platform specific features beyond repair.
2254 # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
2255 # has no effect, don't bother defining them
2256 Darwin/[6789].*)
Anthony Baxter6169c6b2003-10-04 07:46:23 +00002257 define_xopen_source=no;;
Trent Mickc5625ba2004-08-25 23:59:39 +00002258 # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but
2259 # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined
2260 # or has another value. By not (re)defining it, the defaults come in place.
Martin v. Löwisc19c5a62003-11-18 20:00:44 +00002261 AIX/4)
2262 define_xopen_source=no;;
Trent Mickc5625ba2004-08-25 23:59:39 +00002263 AIX/5)
2264 if test `uname -r` -eq 1; then
2265 define_xopen_source=no
2266 fi
2267 ;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +00002268 # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from
2269 # defining NI_NUMERICHOST.
2270 QNX/6.3.2)
2271 define_xopen_source=no
2272 ;;
Martin v. Löwisa0588362006-04-04 06:03:50 +00002273
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002274esac
2275
2276if test $define_xopen_source = yes
2277then
Skip Montanarof0d5f792004-08-15 14:08:23 +00002278 # On Solaris w/ g++ it appears that _XOPEN_SOURCE has to be
2279 # defined precisely as g++ defines it
Martin v. Löwis7dece662005-11-26 11:38:24 +00002280 # Furthermore, on Solaris 10, XPG6 requires the use of a C99
2281 # compiler
Skip Montanarof0d5f792004-08-15 14:08:23 +00002282 case $ac_sys_system/$ac_sys_release in
Martin v. Löwis7dece662005-11-26 11:38:24 +00002283 SunOS/5.8|SunOS/5.9|SunOS/5.10)
Skip Montanarof0d5f792004-08-15 14:08:23 +00002284
2285cat >>confdefs.h <<\_ACEOF
2286#define _XOPEN_SOURCE 500
2287_ACEOF
2288
2289 ;;
2290 *)
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002291
2292cat >>confdefs.h <<\_ACEOF
2293#define _XOPEN_SOURCE 600
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002294_ACEOF
2295
Skip Montanarof0d5f792004-08-15 14:08:23 +00002296 ;;
2297 esac
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002298
2299 # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
2300 # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
2301 # several APIs are not declared. Since this is also needed in some
2302 # cases for HP-UX, we define it globally.
Martin v. Löwis7dece662005-11-26 11:38:24 +00002303 # except for Solaris 10, where it must not be defined,
2304 # as it implies XPG4.2
2305 case $ac_sys_system/$ac_sys_release in
2306 SunOS/5.10)
2307 ;;
2308 *)
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002309
2310cat >>confdefs.h <<\_ACEOF
2311#define _XOPEN_SOURCE_EXTENDED 1
2312_ACEOF
2313
Martin v. Löwis7dece662005-11-26 11:38:24 +00002314 ;;
2315 esac
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002316
Bob Ippolito7026a0a2005-03-28 23:23:47 +00002317
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002318cat >>confdefs.h <<\_ACEOF
2319#define _POSIX_C_SOURCE 200112L
2320_ACEOF
2321
2322
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002323fi
2324
Guido van Rossum91922671997-10-09 20:24:13 +00002325#
2326# SGI compilers allow the specification of the both the ABI and the
2327# ISA on the command line. Depending on the values of these switches,
2328# different and often incompatable code will be generated.
2329#
2330# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
2331# thus supply support for various ABI/ISA combinations. The MACHDEP
2332# variable is also adjusted.
2333#
2334
2335if test ! -z "$SGI_ABI"
2336then
2337 CC="cc $SGI_ABI"
2338 LDFLAGS="$SGI_ABI $LDFLAGS"
2339 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
2340fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002341{ $as_echo "$as_me:$LINENO: result: $MACHDEP" >&5
2342$as_echo "$MACHDEP" >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002343
Jack Jansen83f898c2002-12-30 22:23:40 +00002344# And add extra plat-mac for darwin
2345
Jack Jansen7b59b422003-03-17 15:44:10 +00002346
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002347{ $as_echo "$as_me:$LINENO: checking EXTRAPLATDIR" >&5
2348$as_echo_n "checking EXTRAPLATDIR... " >&6; }
Jack Jansen83f898c2002-12-30 22:23:40 +00002349if test -z "$EXTRAPLATDIR"
2350then
2351 case $MACHDEP in
Jack Jansen7b59b422003-03-17 15:44:10 +00002352 darwin)
2353 EXTRAPLATDIR="\$(PLATMACDIRS)"
2354 EXTRAMACHDEPPATH="\$(PLATMACPATH)"
2355 ;;
2356 *)
2357 EXTRAPLATDIR=""
2358 EXTRAMACHDEPPATH=""
2359 ;;
Jack Jansen83f898c2002-12-30 22:23:40 +00002360 esac
2361fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002362{ $as_echo "$as_me:$LINENO: result: $EXTRAPLATDIR" >&5
2363$as_echo "$EXTRAPLATDIR" >&6; }
Jack Jansen83f898c2002-12-30 22:23:40 +00002364
Jack Jansen6b08a402004-06-03 12:41:45 +00002365# Record the configure-time value of MACOSX_DEPLOYMENT_TARGET,
2366# it may influence the way we can build extensions, so distutils
2367# needs to check it
2368
Ronald Oussoren988117f2006-04-29 11:31:35 +00002369
Jack Jansen6b08a402004-06-03 12:41:45 +00002370CONFIGURE_MACOSX_DEPLOYMENT_TARGET=
Ronald Oussoren988117f2006-04-29 11:31:35 +00002371EXPORT_MACOSX_DEPLOYMENT_TARGET='#'
Jack Jansen6b08a402004-06-03 12:41:45 +00002372
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002373{ $as_echo "$as_me:$LINENO: checking machine type as reported by uname -m" >&5
2374$as_echo_n "checking machine type as reported by uname -m... " >&6; }
Mark Dickinson65134662008-04-25 16:11:04 +00002375ac_sys_machine=`uname -m`
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002376{ $as_echo "$as_me:$LINENO: result: $ac_sys_machine" >&5
2377$as_echo "$ac_sys_machine" >&6; }
Mark Dickinson65134662008-04-25 16:11:04 +00002378
Guido van Rossum627b2d71993-12-24 10:39:16 +00002379# checks for alternative programs
Skip Montanarodecc6a42003-01-01 20:07:49 +00002380
2381# compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just
2382# for debug/optimization stuff. BASECFLAGS is for flags that are required
2383# just to get things to compile and link. Users are free to override OPT
2384# when running configure or make. The build should not break if they do.
2385# BASECFLAGS should generally not be messed with, however.
2386
2387# XXX shouldn't some/most/all of this code be merged with the stuff later
2388# on that fiddles with OPT and BASECFLAGS?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002389{ $as_echo "$as_me:$LINENO: checking for --without-gcc" >&5
2390$as_echo_n "checking for --without-gcc... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002391
Martin v. Löwiseba40652007-08-30 20:10:57 +00002392# Check whether --with-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002393if test "${with_gcc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002394 withval=$with_gcc;
Guido van Rossum7f43da71994-08-01 12:15:30 +00002395 case $withval in
Mark Dickinson04b27232009-01-04 12:29:36 +00002396 no) CC=${CC:-cc}
Guido van Rossumda88dad1995-01-26 00:46:29 +00002397 without_gcc=yes;;
2398 yes) CC=gcc
2399 without_gcc=no;;
2400 *) CC=$withval
2401 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00002402 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00002403else
Martin v. Löwis11437992002-04-12 09:54:03 +00002404
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002405 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00002406 AIX*) CC=cc_r
2407 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002408 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002409 case $BE_HOST_CPU in
2410 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00002411 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002412 without_gcc=yes
Skip Montanarodecc6a42003-01-01 20:07:49 +00002413 BASECFLAGS="$BASECFLAGS -export pragma"
2414 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002415 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002416 ;;
2417 x86)
Fred Drake5790be12000-10-09 17:06:13 +00002418 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002419 without_gcc=no
Skip Montanarodecc6a42003-01-01 20:07:49 +00002420 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002421 ;;
2422 *)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002423 { { $as_echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
2424$as_echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002425 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002426 ;;
2427 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00002428 AR="\$(srcdir)/Modules/ar_beos"
2429 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002430 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00002431 Monterey*)
2432 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00002433 without_gcc=;;
2434 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00002435 esac
Martin v. Löwiseba40652007-08-30 20:10:57 +00002436fi
2437
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002438{ $as_echo "$as_me:$LINENO: result: $without_gcc" >&5
2439$as_echo "$without_gcc" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002440
Guido van Rossum8b131c51995-03-09 14:10:13 +00002441# If the user switches compilers, we can't believe the cache
2442if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
2443then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002444 { { $as_echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
Martin v. Löwis11437992002-04-12 09:54:03 +00002445(it is also a good idea to do 'make clean' before compiling)" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002446$as_echo "$as_me: error: cached CC is different -- throw away $cache_file
Martin v. Löwis11437992002-04-12 09:54:03 +00002447(it is also a good idea to do 'make clean' before compiling)" >&2;}
2448 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00002449fi
2450
Martin v. Löwis11437992002-04-12 09:54:03 +00002451ac_ext=c
2452ac_cpp='$CPP $CPPFLAGS'
2453ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2454ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2455ac_compiler_gnu=$ac_cv_c_compiler_gnu
2456if test -n "$ac_tool_prefix"; then
2457 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2458set dummy ${ac_tool_prefix}gcc; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002459{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2460$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002461if test "${ac_cv_prog_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002462 $as_echo_n "(cached) " >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002463else
2464 if test -n "$CC"; then
2465 ac_cv_prog_CC="$CC" # Let the user override the test.
2466else
Martin v. Löwis11437992002-04-12 09:54:03 +00002467as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2468for as_dir in $PATH
2469do
2470 IFS=$as_save_IFS
2471 test -z "$as_dir" && as_dir=.
2472 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002473 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 +00002474 ac_cv_prog_CC="${ac_tool_prefix}gcc"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002475 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002476 break 2
2477 fi
2478done
2479done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002480IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002481
Jack Jansendd19cf82001-12-06 22:36:17 +00002482fi
2483fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002484CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00002485if test -n "$CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002486 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2487$as_echo "$CC" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00002488else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002489 { $as_echo "$as_me:$LINENO: result: no" >&5
2490$as_echo "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002491fi
2492
Martin v. Löwiseba40652007-08-30 20:10:57 +00002493
Martin v. Löwis11437992002-04-12 09:54:03 +00002494fi
2495if test -z "$ac_cv_prog_CC"; then
2496 ac_ct_CC=$CC
2497 # Extract the first word of "gcc", so it can be a program name with args.
2498set dummy gcc; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002499{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2500$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002501if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002502 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002503else
2504 if test -n "$ac_ct_CC"; then
2505 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2506else
2507as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2508for as_dir in $PATH
2509do
2510 IFS=$as_save_IFS
2511 test -z "$as_dir" && as_dir=.
2512 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002513 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 +00002514 ac_cv_prog_ac_ct_CC="gcc"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002515 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002516 break 2
2517 fi
2518done
2519done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002520IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002521
2522fi
2523fi
2524ac_ct_CC=$ac_cv_prog_ac_ct_CC
2525if test -n "$ac_ct_CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002526 { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2527$as_echo "$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002528else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002529 { $as_echo "$as_me:$LINENO: result: no" >&5
2530$as_echo "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002531fi
2532
Martin v. Löwiseba40652007-08-30 20:10:57 +00002533 if test "x$ac_ct_CC" = x; then
2534 CC=""
2535 else
2536 case $cross_compiling:$ac_tool_warned in
2537yes:)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002538{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2539$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00002540ac_tool_warned=yes ;;
2541esac
2542 CC=$ac_ct_CC
2543 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002544else
2545 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00002546fi
2547
Jack Jansendd19cf82001-12-06 22:36:17 +00002548if test -z "$CC"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002549 if test -n "$ac_tool_prefix"; then
2550 # 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 +00002551set dummy ${ac_tool_prefix}cc; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002552{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2553$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002554if test "${ac_cv_prog_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002555 $as_echo_n "(cached) " >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00002556else
2557 if test -n "$CC"; then
2558 ac_cv_prog_CC="$CC" # Let the user override the test.
2559else
Martin v. Löwis11437992002-04-12 09:54:03 +00002560as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2561for as_dir in $PATH
2562do
2563 IFS=$as_save_IFS
2564 test -z "$as_dir" && as_dir=.
2565 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002566 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 +00002567 ac_cv_prog_CC="${ac_tool_prefix}cc"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002568 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002569 break 2
2570 fi
2571done
2572done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002573IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002574
2575fi
2576fi
2577CC=$ac_cv_prog_CC
2578if test -n "$CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002579 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2580$as_echo "$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002581else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002582 { $as_echo "$as_me:$LINENO: result: no" >&5
2583$as_echo "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002584fi
2585
Martin v. Löwiseba40652007-08-30 20:10:57 +00002586
Martin v. Löwis11437992002-04-12 09:54:03 +00002587 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002588fi
2589if test -z "$CC"; then
2590 # Extract the first word of "cc", so it can be a program name with args.
2591set dummy cc; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002592{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2593$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002594if test "${ac_cv_prog_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002595 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002596else
2597 if test -n "$CC"; then
2598 ac_cv_prog_CC="$CC" # Let the user override the test.
2599else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002600 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00002601as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2602for as_dir in $PATH
2603do
2604 IFS=$as_save_IFS
2605 test -z "$as_dir" && as_dir=.
2606 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002607 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 +00002608 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2609 ac_prog_rejected=yes
2610 continue
2611 fi
2612 ac_cv_prog_CC="cc"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002613 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002614 break 2
2615 fi
2616done
2617done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002618IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002619
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002620if test $ac_prog_rejected = yes; then
2621 # We found a bogon in the path, so make sure we never use it.
2622 set dummy $ac_cv_prog_CC
2623 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00002624 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002625 # We chose a different compiler from the bogus one.
2626 # However, it has the same basename, so the bogon will be chosen
2627 # first if we set CC to just the basename; use the full file name.
2628 shift
Skip Montanaro6dead952003-09-25 14:50:04 +00002629 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002630 fi
2631fi
2632fi
2633fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002634CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002635if test -n "$CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002636 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2637$as_echo "$CC" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002638else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002639 { $as_echo "$as_me:$LINENO: result: no" >&5
2640$as_echo "no" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002641fi
2642
Martin v. Löwiseba40652007-08-30 20:10:57 +00002643
Martin v. Löwis11437992002-04-12 09:54:03 +00002644fi
2645if test -z "$CC"; then
2646 if test -n "$ac_tool_prefix"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002647 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00002648 do
2649 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2650set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002651{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2652$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002653if test "${ac_cv_prog_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002654 $as_echo_n "(cached) " >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002655else
2656 if test -n "$CC"; then
2657 ac_cv_prog_CC="$CC" # Let the user override the test.
2658else
Martin v. Löwis11437992002-04-12 09:54:03 +00002659as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2660for as_dir in $PATH
2661do
2662 IFS=$as_save_IFS
2663 test -z "$as_dir" && as_dir=.
2664 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002665 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 +00002666 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002667 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002668 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00002669 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002670done
2671done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002672IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002673
2674fi
2675fi
2676CC=$ac_cv_prog_CC
2677if test -n "$CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002678 { $as_echo "$as_me:$LINENO: result: $CC" >&5
2679$as_echo "$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002680else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002681 { $as_echo "$as_me:$LINENO: result: no" >&5
2682$as_echo "no" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00002683fi
2684
Martin v. Löwiseba40652007-08-30 20:10:57 +00002685
Martin v. Löwis11437992002-04-12 09:54:03 +00002686 test -n "$CC" && break
2687 done
2688fi
2689if test -z "$CC"; then
2690 ac_ct_CC=$CC
Martin v. Löwiseba40652007-08-30 20:10:57 +00002691 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00002692do
2693 # Extract the first word of "$ac_prog", so it can be a program name with args.
2694set dummy $ac_prog; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002695{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2696$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002697if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002698 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002699else
2700 if test -n "$ac_ct_CC"; then
2701 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2702else
2703as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2704for as_dir in $PATH
2705do
2706 IFS=$as_save_IFS
2707 test -z "$as_dir" && as_dir=.
2708 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002709 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 +00002710 ac_cv_prog_ac_ct_CC="$ac_prog"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002711 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002712 break 2
2713 fi
2714done
2715done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002716IFS=$as_save_IFS
Jack Jansendd19cf82001-12-06 22:36:17 +00002717
Martin v. Löwis11437992002-04-12 09:54:03 +00002718fi
2719fi
2720ac_ct_CC=$ac_cv_prog_ac_ct_CC
2721if test -n "$ac_ct_CC"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002722 { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2723$as_echo "$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002724else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002725 { $as_echo "$as_me:$LINENO: result: no" >&5
2726$as_echo "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002727fi
Michael W. Hudson54241132001-12-07 15:38:26 +00002728
Martin v. Löwiseba40652007-08-30 20:10:57 +00002729
Martin v. Löwis11437992002-04-12 09:54:03 +00002730 test -n "$ac_ct_CC" && break
2731done
Michael W. Hudson54241132001-12-07 15:38:26 +00002732
Martin v. Löwiseba40652007-08-30 20:10:57 +00002733 if test "x$ac_ct_CC" = x; then
2734 CC=""
2735 else
2736 case $cross_compiling:$ac_tool_warned in
2737yes:)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002738{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2739$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00002740ac_tool_warned=yes ;;
2741esac
2742 CC=$ac_ct_CC
2743 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002744fi
2745
2746fi
2747
2748
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002749test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2750$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2751{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
Skip Montanaro6dead952003-09-25 14:50:04 +00002752See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002753$as_echo "$as_me: error: no acceptable C compiler found in \$PATH
Skip Montanaro6dead952003-09-25 14:50:04 +00002754See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002755 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002756
2757# Provide some information about the compiler.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002758$as_echo "$as_me:$LINENO: checking for C compiler version" >&5
2759set X $ac_compile
2760ac_compiler=$2
Martin v. Löwiseba40652007-08-30 20:10:57 +00002761{ (ac_try="$ac_compiler --version >&5"
2762case "(($ac_try" in
2763 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2764 *) ac_try_echo=$ac_try;;
2765esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002766eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2767$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002768 (eval "$ac_compiler --version >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002769 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002770 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002771 (exit $ac_status); }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002772{ (ac_try="$ac_compiler -v >&5"
2773case "(($ac_try" in
2774 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2775 *) ac_try_echo=$ac_try;;
2776esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002777eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2778$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002779 (eval "$ac_compiler -v >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002780 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002781 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002782 (exit $ac_status); }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002783{ (ac_try="$ac_compiler -V >&5"
2784case "(($ac_try" in
2785 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2786 *) ac_try_echo=$ac_try;;
2787esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002788eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2789$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002790 (eval "$ac_compiler -V >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002791 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002792 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002793 (exit $ac_status); }
2794
2795cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002796/* confdefs.h. */
2797_ACEOF
2798cat confdefs.h >>conftest.$ac_ext
2799cat >>conftest.$ac_ext <<_ACEOF
2800/* end confdefs.h. */
Jack Jansendd19cf82001-12-06 22:36:17 +00002801
Martin v. Löwis11437992002-04-12 09:54:03 +00002802int
2803main ()
2804{
2805
2806 ;
2807 return 0;
2808}
2809_ACEOF
2810ac_clean_files_save=$ac_clean_files
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002811ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
Martin v. Löwis11437992002-04-12 09:54:03 +00002812# Try to create an executable without -o first, disregard a.out.
2813# It will help us diagnose broken compilers, and finding out an intuition
2814# of exeext.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002815{ $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2816$as_echo_n "checking for C compiler default output file name... " >&6; }
2817ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2818
2819# The possible output files:
2820ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2821
Martin v. Löwiseba40652007-08-30 20:10:57 +00002822ac_rmfiles=
2823for ac_file in $ac_files
2824do
2825 case $ac_file in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002826 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00002827 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2828 esac
2829done
2830rm -f $ac_rmfiles
2831
2832if { (ac_try="$ac_link_default"
2833case "(($ac_try" in
2834 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2835 *) ac_try_echo=$ac_try;;
2836esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002837eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2838$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002839 (eval "$ac_link_default") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002840 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002841 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002842 (exit $ac_status); }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002843 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2844# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2845# in a Makefile. We should not override ac_cv_exeext if it was cached,
2846# so that the user can short-circuit this test for compilers unknown to
2847# Autoconf.
2848for ac_file in $ac_files ''
Skip Montanaro6dead952003-09-25 14:50:04 +00002849do
2850 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002851 case $ac_file in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002852 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002853 ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002854 [ab].out )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002855 # We found the default executable, but exeext='' is most
2856 # certainly right.
2857 break;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002858 *.* )
Martin v. Löwiseba40652007-08-30 20:10:57 +00002859 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2860 then :; else
2861 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2862 fi
2863 # We set ac_cv_exeext here because the later test for it is not
2864 # safe: cross compilers may not add the suffix if given an `-o'
2865 # argument, so we may need to know it at that point already.
2866 # Even if this section looks crufty: it has the advantage of
2867 # actually working.
Skip Montanarof0d5f792004-08-15 14:08:23 +00002868 break;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002869 * )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002870 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002871 esac
2872done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002873test "$ac_cv_exeext" = no && ac_cv_exeext=
2874
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002875else
Martin v. Löwiseba40652007-08-30 20:10:57 +00002876 ac_file=''
2877fi
2878
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002879{ $as_echo "$as_me:$LINENO: result: $ac_file" >&5
2880$as_echo "$ac_file" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002881if test -z "$ac_file"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002882 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00002883sed 's/^/| /' conftest.$ac_ext >&5
2884
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002885{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2886$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2887{ { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
Skip Montanaro6dead952003-09-25 14:50:04 +00002888See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002889$as_echo "$as_me: error: C compiler cannot create executables
Skip Montanaro6dead952003-09-25 14:50:04 +00002890See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002891 { (exit 77); exit 77; }; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002892fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002893
Martin v. Löwis11437992002-04-12 09:54:03 +00002894ac_exeext=$ac_cv_exeext
Michael W. Hudson54241132001-12-07 15:38:26 +00002895
Martin v. Löwiseba40652007-08-30 20:10:57 +00002896# Check that the compiler produces executables we can run. If not, either
Martin v. Löwis11437992002-04-12 09:54:03 +00002897# the compiler is broken, or we cross compile.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002898{ $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2899$as_echo_n "checking whether the C compiler works... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002900# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2901# If not cross compiling, check that we can run a simple program.
2902if test "$cross_compiling" != yes; then
2903 if { ac_try='./$ac_file'
Martin v. Löwiseba40652007-08-30 20:10:57 +00002904 { (case "(($ac_try" in
2905 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2906 *) ac_try_echo=$ac_try;;
2907esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002908eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2909$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002910 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002911 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002912 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002913 (exit $ac_status); }; }; then
2914 cross_compiling=no
2915 else
2916 if test "$cross_compiling" = maybe; then
2917 cross_compiling=yes
2918 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002919 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2920$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2921{ { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
Skip Montanaro6dead952003-09-25 14:50:04 +00002922If you meant to cross compile, use \`--host'.
2923See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002924$as_echo "$as_me: error: cannot run C compiled programs.
Skip Montanaro6dead952003-09-25 14:50:04 +00002925If you meant to cross compile, use \`--host'.
2926See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002927 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002928 fi
2929 fi
2930fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002931{ $as_echo "$as_me:$LINENO: result: yes" >&5
2932$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002933
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002934rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
Martin v. Löwis11437992002-04-12 09:54:03 +00002935ac_clean_files=$ac_clean_files_save
Martin v. Löwiseba40652007-08-30 20:10:57 +00002936# Check that the compiler produces executables we can run. If not, either
Martin v. Löwis11437992002-04-12 09:54:03 +00002937# the compiler is broken, or we cross compile.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002938{ $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2939$as_echo_n "checking whether we are cross compiling... " >&6; }
2940{ $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
2941$as_echo "$cross_compiling" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002942
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002943{ $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
2944$as_echo_n "checking for suffix of executables... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002945if { (ac_try="$ac_link"
2946case "(($ac_try" in
2947 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2948 *) ac_try_echo=$ac_try;;
2949esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002950eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
2951$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002952 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002953 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002954 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002955 (exit $ac_status); }; then
2956 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2957# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2958# work properly (i.e., refer to `conftest.exe'), while it won't with
2959# `rm'.
Skip Montanaro6dead952003-09-25 14:50:04 +00002960for ac_file in conftest.exe conftest conftest.*; do
2961 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002962 case $ac_file in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002963 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002964 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
Skip Montanarof0d5f792004-08-15 14:08:23 +00002965 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002966 * ) break;;
2967 esac
2968done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002969else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002970 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2971$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2972{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
Skip Montanaro6dead952003-09-25 14:50:04 +00002973See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002974$as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
Skip Montanaro6dead952003-09-25 14:50:04 +00002975See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002976 { (exit 1); exit 1; }; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002977fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002978
Martin v. Löwis11437992002-04-12 09:54:03 +00002979rm -f conftest$ac_cv_exeext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002980{ $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2981$as_echo "$ac_cv_exeext" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002982
2983rm -f conftest.$ac_ext
2984EXEEXT=$ac_cv_exeext
2985ac_exeext=$EXEEXT
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002986{ $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
2987$as_echo_n "checking for suffix of object files... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002988if test "${ac_cv_objext+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00002989 $as_echo_n "(cached) " >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002990else
Martin v. Löwis11437992002-04-12 09:54:03 +00002991 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002992/* confdefs.h. */
2993_ACEOF
2994cat confdefs.h >>conftest.$ac_ext
2995cat >>conftest.$ac_ext <<_ACEOF
2996/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002997
Martin v. Löwis11437992002-04-12 09:54:03 +00002998int
2999main ()
3000{
3001
3002 ;
3003 return 0;
3004}
3005_ACEOF
3006rm -f conftest.o conftest.obj
Martin v. Löwiseba40652007-08-30 20:10:57 +00003007if { (ac_try="$ac_compile"
3008case "(($ac_try" in
3009 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3010 *) ac_try_echo=$ac_try;;
3011esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003012eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3013$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003014 (eval "$ac_compile") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00003015 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003016 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00003017 (exit $ac_status); }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00003018 for ac_file in conftest.o conftest.obj conftest.*; do
3019 test -f "$ac_file" || continue;
Martin v. Löwis11437992002-04-12 09:54:03 +00003020 case $ac_file in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003021 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00003022 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3023 break;;
3024 esac
3025done
3026else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003027 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003028sed 's/^/| /' conftest.$ac_ext >&5
3029
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003030{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3031$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3032{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
Skip Montanaro6dead952003-09-25 14:50:04 +00003033See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003034$as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
Skip Montanaro6dead952003-09-25 14:50:04 +00003035See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003036 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003037fi
3038
3039rm -f conftest.$ac_cv_objext conftest.$ac_ext
3040fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003041{ $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3042$as_echo "$ac_cv_objext" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003043OBJEXT=$ac_cv_objext
3044ac_objext=$OBJEXT
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003045{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3046$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003047if test "${ac_cv_c_compiler_gnu+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003048 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00003049else
3050 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003051/* confdefs.h. */
3052_ACEOF
3053cat confdefs.h >>conftest.$ac_ext
3054cat >>conftest.$ac_ext <<_ACEOF
3055/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003056
Martin v. Löwis11437992002-04-12 09:54:03 +00003057int
3058main ()
3059{
3060#ifndef __GNUC__
3061 choke me
3062#endif
3063
3064 ;
3065 return 0;
3066}
3067_ACEOF
3068rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003069if { (ac_try="$ac_compile"
3070case "(($ac_try" in
3071 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3072 *) ac_try_echo=$ac_try;;
3073esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003074eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3075$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003076 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003077 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003078 grep -v '^ *+' conftest.er1 >conftest.err
3079 rm -f conftest.er1
3080 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003081 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003082 (exit $ac_status); } && {
3083 test -z "$ac_c_werror_flag" ||
3084 test ! -s conftest.err
3085 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003086 ac_compiler_gnu=yes
3087else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003088 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003089sed 's/^/| /' conftest.$ac_ext >&5
3090
Martin v. Löwiseba40652007-08-30 20:10:57 +00003091 ac_compiler_gnu=no
Martin v. Löwis11437992002-04-12 09:54:03 +00003092fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003093
3094rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00003095ac_cv_c_compiler_gnu=$ac_compiler_gnu
3096
3097fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003098{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3099$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3100if test $ac_compiler_gnu = yes; then
3101 GCC=yes
3102else
3103 GCC=
3104fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003105ac_test_CFLAGS=${CFLAGS+set}
3106ac_save_CFLAGS=$CFLAGS
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003107{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3108$as_echo_n "checking whether $CC accepts -g... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003109if test "${ac_cv_prog_cc_g+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003110 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00003111else
Martin v. Löwiseba40652007-08-30 20:10:57 +00003112 ac_save_c_werror_flag=$ac_c_werror_flag
3113 ac_c_werror_flag=yes
3114 ac_cv_prog_cc_g=no
3115 CFLAGS="-g"
3116 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003117/* confdefs.h. */
3118_ACEOF
3119cat confdefs.h >>conftest.$ac_ext
3120cat >>conftest.$ac_ext <<_ACEOF
3121/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003122
Martin v. Löwis11437992002-04-12 09:54:03 +00003123int
3124main ()
3125{
3126
3127 ;
3128 return 0;
3129}
3130_ACEOF
3131rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003132if { (ac_try="$ac_compile"
3133case "(($ac_try" in
3134 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3135 *) ac_try_echo=$ac_try;;
3136esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003137eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3138$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003139 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003140 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003141 grep -v '^ *+' conftest.er1 >conftest.err
3142 rm -f conftest.er1
3143 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003144 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003145 (exit $ac_status); } && {
3146 test -z "$ac_c_werror_flag" ||
3147 test ! -s conftest.err
3148 } && test -s conftest.$ac_objext; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003149 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003150else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003151 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003152sed 's/^/| /' conftest.$ac_ext >&5
3153
Martin v. Löwiseba40652007-08-30 20:10:57 +00003154 CFLAGS=""
3155 cat >conftest.$ac_ext <<_ACEOF
3156/* confdefs.h. */
3157_ACEOF
3158cat confdefs.h >>conftest.$ac_ext
3159cat >>conftest.$ac_ext <<_ACEOF
3160/* end confdefs.h. */
3161
3162int
3163main ()
3164{
3165
3166 ;
3167 return 0;
3168}
3169_ACEOF
3170rm -f conftest.$ac_objext
3171if { (ac_try="$ac_compile"
3172case "(($ac_try" in
3173 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3174 *) ac_try_echo=$ac_try;;
3175esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003176eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3177$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003178 (eval "$ac_compile") 2>conftest.er1
3179 ac_status=$?
3180 grep -v '^ *+' conftest.er1 >conftest.err
3181 rm -f conftest.er1
3182 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003183 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003184 (exit $ac_status); } && {
3185 test -z "$ac_c_werror_flag" ||
3186 test ! -s conftest.err
3187 } && test -s conftest.$ac_objext; then
3188 :
3189else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003190 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003191sed 's/^/| /' conftest.$ac_ext >&5
3192
3193 ac_c_werror_flag=$ac_save_c_werror_flag
3194 CFLAGS="-g"
3195 cat >conftest.$ac_ext <<_ACEOF
3196/* confdefs.h. */
3197_ACEOF
3198cat confdefs.h >>conftest.$ac_ext
3199cat >>conftest.$ac_ext <<_ACEOF
3200/* end confdefs.h. */
3201
3202int
3203main ()
3204{
3205
3206 ;
3207 return 0;
3208}
3209_ACEOF
3210rm -f conftest.$ac_objext
3211if { (ac_try="$ac_compile"
3212case "(($ac_try" in
3213 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3214 *) ac_try_echo=$ac_try;;
3215esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003216eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3217$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003218 (eval "$ac_compile") 2>conftest.er1
3219 ac_status=$?
3220 grep -v '^ *+' conftest.er1 >conftest.err
3221 rm -f conftest.er1
3222 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003223 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003224 (exit $ac_status); } && {
3225 test -z "$ac_c_werror_flag" ||
3226 test ! -s conftest.err
3227 } && test -s conftest.$ac_objext; then
3228 ac_cv_prog_cc_g=yes
3229else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003230 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003231sed 's/^/| /' conftest.$ac_ext >&5
3232
3233
Guido van Rossum627b2d71993-12-24 10:39:16 +00003234fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003235
3236rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003237fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003238
3239rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3240fi
3241
3242rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3243 ac_c_werror_flag=$ac_save_c_werror_flag
3244fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003245{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3246$as_echo "$ac_cv_prog_cc_g" >&6; }
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003247if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003248 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003249elif test $ac_cv_prog_cc_g = yes; then
3250 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003251 CFLAGS="-g -O2"
3252 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003253 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003254 fi
3255else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003256 if test "$GCC" = yes; then
3257 CFLAGS="-O2"
3258 else
3259 CFLAGS=
3260 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003261fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003262{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3263$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003264if test "${ac_cv_prog_cc_c89+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003265 $as_echo_n "(cached) " >&6
Skip Montanaro6dead952003-09-25 14:50:04 +00003266else
Martin v. Löwiseba40652007-08-30 20:10:57 +00003267 ac_cv_prog_cc_c89=no
Skip Montanaro6dead952003-09-25 14:50:04 +00003268ac_save_CC=$CC
3269cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003270/* confdefs.h. */
3271_ACEOF
3272cat confdefs.h >>conftest.$ac_ext
3273cat >>conftest.$ac_ext <<_ACEOF
3274/* end confdefs.h. */
3275#include <stdarg.h>
3276#include <stdio.h>
3277#include <sys/types.h>
3278#include <sys/stat.h>
3279/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3280struct buf { int x; };
3281FILE * (*rcsopen) (struct buf *, struct stat *, int);
3282static char *e (p, i)
3283 char **p;
3284 int i;
3285{
3286 return p[i];
3287}
3288static char *f (char * (*g) (char **, int), char **p, ...)
3289{
3290 char *s;
3291 va_list v;
3292 va_start (v,p);
3293 s = g (p, va_arg (v,int));
3294 va_end (v);
3295 return s;
3296}
Skip Montanarof0d5f792004-08-15 14:08:23 +00003297
3298/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3299 function prototypes and stuff, but not '\xHH' hex character constants.
3300 These don't provoke an error unfortunately, instead are silently treated
Martin v. Löwiseba40652007-08-30 20:10:57 +00003301 as 'x'. The following induces an error, until -std is added to get
Skip Montanarof0d5f792004-08-15 14:08:23 +00003302 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3303 array size at least. It's necessary to write '\x00'==0 to get something
Martin v. Löwiseba40652007-08-30 20:10:57 +00003304 that's true only with -std. */
Skip Montanarof0d5f792004-08-15 14:08:23 +00003305int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3306
Martin v. Löwiseba40652007-08-30 20:10:57 +00003307/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3308 inside strings and character constants. */
3309#define FOO(x) 'x'
3310int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3311
Skip Montanaro6dead952003-09-25 14:50:04 +00003312int test (int i, double x);
3313struct s1 {int (*f) (int a);};
3314struct s2 {int (*f) (double a);};
3315int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3316int argc;
3317char **argv;
3318int
3319main ()
3320{
3321return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3322 ;
3323 return 0;
3324}
3325_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003326for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3327 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
Skip Montanaro6dead952003-09-25 14:50:04 +00003328do
3329 CC="$ac_save_CC $ac_arg"
3330 rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003331if { (ac_try="$ac_compile"
3332case "(($ac_try" in
3333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3334 *) ac_try_echo=$ac_try;;
3335esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003336eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3337$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003338 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +00003339 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003340 grep -v '^ *+' conftest.er1 >conftest.err
3341 rm -f conftest.er1
3342 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003343 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003344 (exit $ac_status); } && {
3345 test -z "$ac_c_werror_flag" ||
3346 test ! -s conftest.err
3347 } && test -s conftest.$ac_objext; then
3348 ac_cv_prog_cc_c89=$ac_arg
Skip Montanaro6dead952003-09-25 14:50:04 +00003349else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003350 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003351sed 's/^/| /' conftest.$ac_ext >&5
3352
Martin v. Löwiseba40652007-08-30 20:10:57 +00003353
Skip Montanaro6dead952003-09-25 14:50:04 +00003354fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003355
3356rm -f core conftest.err conftest.$ac_objext
3357 test "x$ac_cv_prog_cc_c89" != "xno" && break
Skip Montanaro6dead952003-09-25 14:50:04 +00003358done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003359rm -f conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00003360CC=$ac_save_CC
3361
3362fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003363# AC_CACHE_VAL
3364case "x$ac_cv_prog_cc_c89" in
3365 x)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003366 { $as_echo "$as_me:$LINENO: result: none needed" >&5
3367$as_echo "none needed" >&6; } ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00003368 xno)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003369 { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3370$as_echo "unsupported" >&6; } ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00003371 *)
Martin v. Löwiseba40652007-08-30 20:10:57 +00003372 CC="$CC $ac_cv_prog_cc_c89"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003373 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3374$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00003375esac
3376
Skip Montanaro6dead952003-09-25 14:50:04 +00003377
Martin v. Löwis11437992002-04-12 09:54:03 +00003378ac_ext=c
3379ac_cpp='$CPP $CPPFLAGS'
3380ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3381ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3382ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003383
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003384
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003385
3386
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003387{ $as_echo "$as_me:$LINENO: checking for --with-cxx-main=<compiler>" >&5
3388$as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003389
Martin v. Löwiseba40652007-08-30 20:10:57 +00003390# Check whether --with-cxx_main was given.
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003391if test "${with_cxx_main+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00003392 withval=$with_cxx_main;
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003393
3394 case $withval in
3395 no) with_cxx_main=no
3396 MAINCC='$(CC)';;
3397 yes) with_cxx_main=yes
3398 MAINCC='$(CXX)';;
3399 *) with_cxx_main=yes
3400 MAINCC=$withval
3401 if test -z "$CXX"
3402 then
3403 CXX=$withval
3404 fi;;
3405 esac
3406else
3407
3408 with_cxx_main=no
3409 MAINCC='$(CC)'
3410
Martin v. Löwiseba40652007-08-30 20:10:57 +00003411fi
3412
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003413{ $as_echo "$as_me:$LINENO: result: $with_cxx_main" >&5
3414$as_echo "$with_cxx_main" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003415
3416preset_cxx="$CXX"
3417if test -z "$CXX"
3418then
3419 case "$CC" in
3420 gcc) # Extract the first word of "g++", so it can be a program name with args.
3421set dummy g++; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003422{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3423$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003424if test "${ac_cv_path_CXX+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003425 $as_echo_n "(cached) " >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003426else
3427 case $CXX in
3428 [\\/]* | ?:[\\/]*)
3429 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
3430 ;;
3431 *)
3432 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3433for as_dir in notfound
3434do
3435 IFS=$as_save_IFS
3436 test -z "$as_dir" && as_dir=.
3437 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003438 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 +00003439 ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003440 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003441 break 2
3442 fi
3443done
3444done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003445IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003446
3447 test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++"
3448 ;;
3449esac
3450fi
3451CXX=$ac_cv_path_CXX
Skip Montanaro89e975f2007-08-22 19:05:21 +00003452if test -n "$CXX"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003453 { $as_echo "$as_me:$LINENO: result: $CXX" >&5
3454$as_echo "$CXX" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003455else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003456 { $as_echo "$as_me:$LINENO: result: no" >&5
3457$as_echo "no" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003458fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003459
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003460 ;;
3461 cc) # Extract the first word of "c++", so it can be a program name with args.
3462set dummy c++; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003463{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3464$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003465if test "${ac_cv_path_CXX+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003466 $as_echo_n "(cached) " >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003467else
3468 case $CXX in
3469 [\\/]* | ?:[\\/]*)
3470 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
3471 ;;
3472 *)
3473 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3474for as_dir in notfound
3475do
3476 IFS=$as_save_IFS
3477 test -z "$as_dir" && as_dir=.
3478 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003479 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 +00003480 ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003481 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003482 break 2
3483 fi
3484done
3485done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003486IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003487
3488 test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++"
3489 ;;
3490esac
3491fi
3492CXX=$ac_cv_path_CXX
Skip Montanaro89e975f2007-08-22 19:05:21 +00003493if test -n "$CXX"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003494 { $as_echo "$as_me:$LINENO: result: $CXX" >&5
3495$as_echo "$CXX" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003496else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003497 { $as_echo "$as_me:$LINENO: result: no" >&5
3498$as_echo "no" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003499fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003500
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003501 ;;
3502 esac
3503 if test "$CXX" = "notfound"
3504 then
3505 CXX=""
3506 fi
3507fi
3508if test -z "$CXX"
3509then
3510 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
3511do
3512 # Extract the first word of "$ac_prog", so it can be a program name with args.
3513set dummy $ac_prog; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003514{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3515$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003516if test "${ac_cv_prog_CXX+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003517 $as_echo_n "(cached) " >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003518else
3519 if test -n "$CXX"; then
3520 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3521else
3522as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3523for as_dir in $PATH
3524do
3525 IFS=$as_save_IFS
3526 test -z "$as_dir" && as_dir=.
3527 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003528 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 +00003529 ac_cv_prog_CXX="$ac_prog"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003530 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003531 break 2
3532 fi
3533done
3534done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003535IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003536
3537fi
3538fi
3539CXX=$ac_cv_prog_CXX
3540if test -n "$CXX"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003541 { $as_echo "$as_me:$LINENO: result: $CXX" >&5
3542$as_echo "$CXX" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003543else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003544 { $as_echo "$as_me:$LINENO: result: no" >&5
3545$as_echo "no" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003546fi
3547
Martin v. Löwiseba40652007-08-30 20:10:57 +00003548
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003549 test -n "$CXX" && break
3550done
3551test -n "$CXX" || CXX="notfound"
3552
3553 if test "$CXX" = "notfound"
3554 then
3555 CXX=""
3556 fi
3557fi
3558if test "$preset_cxx" != "$CXX"
3559then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003560 { $as_echo "$as_me:$LINENO: WARNING:
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003561
3562 By default, distutils will build C++ extension modules with \"$CXX\".
3563 If this is not intended, then set CXX on the configure command line.
3564 " >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003565$as_echo "$as_me: WARNING:
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003566
3567 By default, distutils will build C++ extension modules with \"$CXX\".
3568 If this is not intended, then set CXX on the configure command line.
3569 " >&2;}
3570fi
3571
3572
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003573# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00003574
3575ac_ext=c
3576ac_cpp='$CPP $CPPFLAGS'
3577ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3578ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3579ac_compiler_gnu=$ac_cv_c_compiler_gnu
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003580{ $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3581$as_echo_n "checking how to run the C preprocessor... " >&6; }
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003582# On Suns, sometimes $CPP names a directory.
3583if test -n "$CPP" && test -d "$CPP"; then
3584 CPP=
3585fi
3586if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003587 if test "${ac_cv_prog_CPP+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003588 $as_echo_n "(cached) " >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003589else
Martin v. Löwis11437992002-04-12 09:54:03 +00003590 # Double quotes because CPP needs to be expanded
3591 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3592 do
3593 ac_preproc_ok=false
3594for ac_c_preproc_warn_flag in '' yes
3595do
3596 # Use a header file that comes with gcc, so configuring glibc
3597 # with a fresh cross-compiler works.
Skip Montanaro6dead952003-09-25 14:50:04 +00003598 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3599 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003600 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00003601 # not just through cpp. "Syntax error" is here to catch this case.
3602 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003603/* confdefs.h. */
3604_ACEOF
3605cat confdefs.h >>conftest.$ac_ext
3606cat >>conftest.$ac_ext <<_ACEOF
3607/* end confdefs.h. */
3608#ifdef __STDC__
3609# include <limits.h>
3610#else
3611# include <assert.h>
3612#endif
Skip Montanarof0d5f792004-08-15 14:08:23 +00003613 Syntax error
Martin v. Löwis11437992002-04-12 09:54:03 +00003614_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003615if { (ac_try="$ac_cpp conftest.$ac_ext"
3616case "(($ac_try" in
3617 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3618 *) ac_try_echo=$ac_try;;
3619esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003620eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3621$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003622 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003623 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003624 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003625 rm -f conftest.er1
3626 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003627 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003628 (exit $ac_status); } >/dev/null && {
3629 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3630 test ! -s conftest.err
3631 }; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003632 :
3633else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003634 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003635sed 's/^/| /' conftest.$ac_ext >&5
3636
Martin v. Löwis11437992002-04-12 09:54:03 +00003637 # Broken: fails on valid input.
3638continue
Jack Jansendd19cf82001-12-06 22:36:17 +00003639fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003640
Martin v. Löwis11437992002-04-12 09:54:03 +00003641rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00003642
Martin v. Löwiseba40652007-08-30 20:10:57 +00003643 # OK, works on sane cases. Now check whether nonexistent headers
Martin v. Löwis11437992002-04-12 09:54:03 +00003644 # can be detected and how.
3645 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003646/* confdefs.h. */
3647_ACEOF
3648cat confdefs.h >>conftest.$ac_ext
3649cat >>conftest.$ac_ext <<_ACEOF
3650/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003651#include <ac_nonexistent.h>
3652_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003653if { (ac_try="$ac_cpp conftest.$ac_ext"
3654case "(($ac_try" in
3655 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3656 *) ac_try_echo=$ac_try;;
3657esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003658eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3659$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003660 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003661 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003662 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003663 rm -f conftest.er1
3664 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003665 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003666 (exit $ac_status); } >/dev/null && {
3667 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3668 test ! -s conftest.err
3669 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003670 # Broken: success on invalid input.
3671continue
3672else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003673 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003674sed 's/^/| /' conftest.$ac_ext >&5
3675
Martin v. Löwis11437992002-04-12 09:54:03 +00003676 # Passes both tests.
3677ac_preproc_ok=:
3678break
3679fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003680
Martin v. Löwis11437992002-04-12 09:54:03 +00003681rm -f conftest.err conftest.$ac_ext
3682
3683done
3684# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3685rm -f conftest.err conftest.$ac_ext
3686if $ac_preproc_ok; then
3687 break
3688fi
3689
3690 done
3691 ac_cv_prog_CPP=$CPP
3692
3693fi
3694 CPP=$ac_cv_prog_CPP
3695else
3696 ac_cv_prog_CPP=$CPP
3697fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003698{ $as_echo "$as_me:$LINENO: result: $CPP" >&5
3699$as_echo "$CPP" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003700ac_preproc_ok=false
3701for ac_c_preproc_warn_flag in '' yes
3702do
3703 # Use a header file that comes with gcc, so configuring glibc
3704 # with a fresh cross-compiler works.
Skip Montanaro6dead952003-09-25 14:50:04 +00003705 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3706 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis11437992002-04-12 09:54:03 +00003707 # On the NeXT, cc -E runs the code through the compiler's parser,
3708 # not just through cpp. "Syntax error" is here to catch this case.
3709 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003710/* confdefs.h. */
3711_ACEOF
3712cat confdefs.h >>conftest.$ac_ext
3713cat >>conftest.$ac_ext <<_ACEOF
3714/* end confdefs.h. */
3715#ifdef __STDC__
3716# include <limits.h>
3717#else
3718# include <assert.h>
3719#endif
Skip Montanarof0d5f792004-08-15 14:08:23 +00003720 Syntax error
Martin v. Löwis11437992002-04-12 09:54:03 +00003721_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003722if { (ac_try="$ac_cpp conftest.$ac_ext"
3723case "(($ac_try" in
3724 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3725 *) ac_try_echo=$ac_try;;
3726esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003727eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3728$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003729 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003730 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003731 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003732 rm -f conftest.er1
3733 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003734 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003735 (exit $ac_status); } >/dev/null && {
3736 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3737 test ! -s conftest.err
3738 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003739 :
3740else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003741 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003742sed 's/^/| /' conftest.$ac_ext >&5
3743
Martin v. Löwis11437992002-04-12 09:54:03 +00003744 # Broken: fails on valid input.
3745continue
3746fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003747
Martin v. Löwis11437992002-04-12 09:54:03 +00003748rm -f conftest.err conftest.$ac_ext
3749
Martin v. Löwiseba40652007-08-30 20:10:57 +00003750 # OK, works on sane cases. Now check whether nonexistent headers
Martin v. Löwis11437992002-04-12 09:54:03 +00003751 # can be detected and how.
3752 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003753/* confdefs.h. */
3754_ACEOF
3755cat confdefs.h >>conftest.$ac_ext
3756cat >>conftest.$ac_ext <<_ACEOF
3757/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003758#include <ac_nonexistent.h>
3759_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003760if { (ac_try="$ac_cpp conftest.$ac_ext"
3761case "(($ac_try" in
3762 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3763 *) ac_try_echo=$ac_try;;
3764esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003765eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3766$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003767 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003768 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003769 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003770 rm -f conftest.er1
3771 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003772 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003773 (exit $ac_status); } >/dev/null && {
3774 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3775 test ! -s conftest.err
3776 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003777 # Broken: success on invalid input.
3778continue
3779else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003780 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003781sed 's/^/| /' conftest.$ac_ext >&5
3782
Martin v. Löwis11437992002-04-12 09:54:03 +00003783 # Passes both tests.
3784ac_preproc_ok=:
3785break
3786fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003787
Martin v. Löwis11437992002-04-12 09:54:03 +00003788rm -f conftest.err conftest.$ac_ext
3789
3790done
3791# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3792rm -f conftest.err conftest.$ac_ext
3793if $ac_preproc_ok; then
3794 :
3795else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003796 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3797$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3798{ { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
Skip Montanaro6dead952003-09-25 14:50:04 +00003799See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003800$as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
Skip Montanaro6dead952003-09-25 14:50:04 +00003801See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003802 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003803fi
3804
3805ac_ext=c
3806ac_cpp='$CPP $CPPFLAGS'
3807ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3808ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3809ac_compiler_gnu=$ac_cv_c_compiler_gnu
3810
3811
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003812{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
3813$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003814if test "${ac_cv_path_GREP+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003815 $as_echo_n "(cached) " >&6
Skip Montanaro6dead952003-09-25 14:50:04 +00003816else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003817 if test -z "$GREP"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00003818 ac_path_GREP_found=false
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003819 # Loop through the user's path and test for each of PROGNAME-LIST
3820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwiseba40652007-08-30 20:10:57 +00003821for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3822do
3823 IFS=$as_save_IFS
3824 test -z "$as_dir" && as_dir=.
3825 for ac_prog in grep ggrep; do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003826 for ac_exec_ext in '' $ac_executable_extensions; do
3827 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3828 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3829# Check for GNU ac_path_GREP and select it if it is found.
Martin v. Löwiseba40652007-08-30 20:10:57 +00003830 # Check for GNU $ac_path_GREP
3831case `"$ac_path_GREP" --version 2>&1` in
3832*GNU*)
3833 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3834*)
3835 ac_count=0
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003836 $as_echo_n 0123456789 >"conftest.in"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003837 while :
3838 do
3839 cat "conftest.in" "conftest.in" >"conftest.tmp"
3840 mv "conftest.tmp" "conftest.in"
3841 cp "conftest.in" "conftest.nl"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003842 $as_echo 'GREP' >> "conftest.nl"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003843 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3844 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3845 ac_count=`expr $ac_count + 1`
3846 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3847 # Best one so far, save it but keep looking for a better one
3848 ac_cv_path_GREP="$ac_path_GREP"
3849 ac_path_GREP_max=$ac_count
Skip Montanaro6dead952003-09-25 14:50:04 +00003850 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003851 # 10*(2^10) chars as input seems more than enough
3852 test $ac_count -gt 10 && break
3853 done
3854 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3855esac
3856
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003857 $ac_path_GREP_found && break 3
3858 done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003859 done
3860done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003861IFS=$as_save_IFS
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003862 if test -z "$ac_cv_path_GREP"; then
3863 { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3864$as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00003865 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003866 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003867else
3868 ac_cv_path_GREP=$GREP
3869fi
3870
Martin v. Löwiseba40652007-08-30 20:10:57 +00003871fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003872{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
3873$as_echo "$ac_cv_path_GREP" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003874 GREP="$ac_cv_path_GREP"
3875
3876
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003877{ $as_echo "$as_me:$LINENO: checking for egrep" >&5
3878$as_echo_n "checking for egrep... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003879if test "${ac_cv_path_EGREP+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003880 $as_echo_n "(cached) " >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +00003881else
3882 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3883 then ac_cv_path_EGREP="$GREP -E"
3884 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003885 if test -z "$EGREP"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00003886 ac_path_EGREP_found=false
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003887 # Loop through the user's path and test for each of PROGNAME-LIST
3888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwiseba40652007-08-30 20:10:57 +00003889for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3890do
3891 IFS=$as_save_IFS
3892 test -z "$as_dir" && as_dir=.
3893 for ac_prog in egrep; do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003894 for ac_exec_ext in '' $ac_executable_extensions; do
3895 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3896 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3897# Check for GNU ac_path_EGREP and select it if it is found.
Martin v. Löwiseba40652007-08-30 20:10:57 +00003898 # Check for GNU $ac_path_EGREP
3899case `"$ac_path_EGREP" --version 2>&1` in
3900*GNU*)
3901 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3902*)
3903 ac_count=0
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003904 $as_echo_n 0123456789 >"conftest.in"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003905 while :
3906 do
3907 cat "conftest.in" "conftest.in" >"conftest.tmp"
3908 mv "conftest.tmp" "conftest.in"
3909 cp "conftest.in" "conftest.nl"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003910 $as_echo 'EGREP' >> "conftest.nl"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003911 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3912 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3913 ac_count=`expr $ac_count + 1`
3914 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3915 # Best one so far, save it but keep looking for a better one
3916 ac_cv_path_EGREP="$ac_path_EGREP"
3917 ac_path_EGREP_max=$ac_count
3918 fi
3919 # 10*(2^10) chars as input seems more than enough
3920 test $ac_count -gt 10 && break
3921 done
3922 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3923esac
3924
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003925 $ac_path_EGREP_found && break 3
3926 done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003927 done
3928done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003929IFS=$as_save_IFS
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003930 if test -z "$ac_cv_path_EGREP"; then
3931 { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3932$as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00003933 { (exit 1); exit 1; }; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003934 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003935else
3936 ac_cv_path_EGREP=$EGREP
3937fi
3938
Martin v. Löwiseba40652007-08-30 20:10:57 +00003939 fi
3940fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003941{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
3942$as_echo "$ac_cv_path_EGREP" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003943 EGREP="$ac_cv_path_EGREP"
Skip Montanaro6dead952003-09-25 14:50:04 +00003944
3945
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003946{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3947$as_echo_n "checking for ANSI C header files... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003948if test "${ac_cv_header_stdc+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003949 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003950else
Martin v. Löwis11437992002-04-12 09:54:03 +00003951 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003952/* confdefs.h. */
3953_ACEOF
3954cat confdefs.h >>conftest.$ac_ext
3955cat >>conftest.$ac_ext <<_ACEOF
3956/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00003957#include <stdlib.h>
3958#include <stdarg.h>
3959#include <string.h>
3960#include <float.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003961
Skip Montanaro6dead952003-09-25 14:50:04 +00003962int
3963main ()
3964{
3965
3966 ;
3967 return 0;
3968}
Martin v. Löwis11437992002-04-12 09:54:03 +00003969_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003970rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003971if { (ac_try="$ac_compile"
3972case "(($ac_try" in
3973 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3974 *) ac_try_echo=$ac_try;;
3975esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003976eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3977$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003978 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003979 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003980 grep -v '^ *+' conftest.er1 >conftest.err
3981 rm -f conftest.er1
3982 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003983 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003984 (exit $ac_status); } && {
3985 test -z "$ac_c_werror_flag" ||
3986 test ! -s conftest.err
3987 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003988 ac_cv_header_stdc=yes
3989else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003990 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003991sed 's/^/| /' conftest.$ac_ext >&5
3992
Martin v. Löwiseba40652007-08-30 20:10:57 +00003993 ac_cv_header_stdc=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003994fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003995
3996rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003997
3998if test $ac_cv_header_stdc = yes; then
3999 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00004000 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00004001/* confdefs.h. */
4002_ACEOF
4003cat confdefs.h >>conftest.$ac_ext
4004cat >>conftest.$ac_ext <<_ACEOF
4005/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004006#include <string.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004007
4008_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004009if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00004010 $EGREP "memchr" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004011 :
4012else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004013 ac_cv_header_stdc=no
4014fi
4015rm -f conftest*
4016
4017fi
4018
4019if test $ac_cv_header_stdc = yes; then
4020 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00004021 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00004022/* confdefs.h. */
4023_ACEOF
4024cat confdefs.h >>conftest.$ac_ext
4025cat >>conftest.$ac_ext <<_ACEOF
4026/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004027#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004028
4029_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004030if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00004031 $EGREP "free" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004032 :
4033else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004034 ac_cv_header_stdc=no
4035fi
4036rm -f conftest*
4037
4038fi
4039
4040if test $ac_cv_header_stdc = yes; then
4041 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
Martin v. Löwis11437992002-04-12 09:54:03 +00004042 if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004043 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004044else
Martin v. Löwis11437992002-04-12 09:54:03 +00004045 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00004046/* confdefs.h. */
4047_ACEOF
4048cat confdefs.h >>conftest.$ac_ext
4049cat >>conftest.$ac_ext <<_ACEOF
4050/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00004051#include <ctype.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +00004052#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004053#if ((' ' & 0x0FF) == 0x020)
4054# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4055# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4056#else
Skip Montanaro6dead952003-09-25 14:50:04 +00004057# define ISLOWER(c) \
Skip Montanarof0d5f792004-08-15 14:08:23 +00004058 (('a' <= (c) && (c) <= 'i') \
4059 || ('j' <= (c) && (c) <= 'r') \
4060 || ('s' <= (c) && (c) <= 'z'))
Martin v. Löwis11437992002-04-12 09:54:03 +00004061# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4062#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00004063
Martin v. Löwis11437992002-04-12 09:54:03 +00004064#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4065int
4066main ()
4067{
4068 int i;
4069 for (i = 0; i < 256; i++)
4070 if (XOR (islower (i), ISLOWER (i))
Skip Montanarof0d5f792004-08-15 14:08:23 +00004071 || toupper (i) != TOUPPER (i))
Martin v. Löwiseba40652007-08-30 20:10:57 +00004072 return 2;
4073 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00004074}
4075_ACEOF
4076rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00004077if { (ac_try="$ac_link"
4078case "(($ac_try" in
4079 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4080 *) ac_try_echo=$ac_try;;
4081esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004082eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4083$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00004084 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004085 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004086 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004087 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00004088 { (case "(($ac_try" in
4089 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4090 *) ac_try_echo=$ac_try;;
4091esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004092eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4093$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00004094 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004095 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004096 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004097 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004098 :
4099else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004100 $as_echo "$as_me: program exited with status $ac_status" >&5
4101$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00004102sed 's/^/| /' conftest.$ac_ext >&5
4103
Martin v. Löwis11437992002-04-12 09:54:03 +00004104( exit $ac_status )
4105ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004106fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004107rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00004108rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4109fi
4110
4111
Michael W. Hudson54241132001-12-07 15:38:26 +00004112fi
4113fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004114{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4115$as_echo "$ac_cv_header_stdc" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004116if test $ac_cv_header_stdc = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004117
4118cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004119#define STDC_HEADERS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00004120_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004121
4122fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004123
Skip Montanarob9820a32004-01-17 00:16:12 +00004124# On IRIX 5.3, sys/types and inttypes.h are conflicting.
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
Skip Montanarof0d5f792004-08-15 14:08:23 +00004135 inttypes.h stdint.h unistd.h
Skip Montanarob9820a32004-01-17 00:16:12 +00004136do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004137as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4138{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
4139$as_echo_n "checking for $ac_header... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00004140if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004141 $as_echo_n "(cached) " >&6
Skip Montanarob9820a32004-01-17 00:16:12 +00004142else
4143 cat >conftest.$ac_ext <<_ACEOF
Skip Montanarob9820a32004-01-17 00:16:12 +00004144/* confdefs.h. */
4145_ACEOF
4146cat confdefs.h >>conftest.$ac_ext
4147cat >>conftest.$ac_ext <<_ACEOF
4148/* end confdefs.h. */
4149$ac_includes_default
4150
4151#include <$ac_header>
4152_ACEOF
4153rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00004154if { (ac_try="$ac_compile"
4155case "(($ac_try" in
4156 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4157 *) ac_try_echo=$ac_try;;
4158esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004159eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4160$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00004161 (eval "$ac_compile") 2>conftest.er1
Skip Montanarob9820a32004-01-17 00:16:12 +00004162 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00004163 grep -v '^ *+' conftest.er1 >conftest.err
4164 rm -f conftest.er1
4165 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004166 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00004167 (exit $ac_status); } && {
4168 test -z "$ac_c_werror_flag" ||
4169 test ! -s conftest.err
4170 } && test -s conftest.$ac_objext; then
Skip Montanarob9820a32004-01-17 00:16:12 +00004171 eval "$as_ac_Header=yes"
4172else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004173 $as_echo "$as_me: failed program was:" >&5
Skip Montanarob9820a32004-01-17 00:16:12 +00004174sed 's/^/| /' conftest.$ac_ext >&5
4175
Martin v. Löwiseba40652007-08-30 20:10:57 +00004176 eval "$as_ac_Header=no"
Skip Montanarob9820a32004-01-17 00:16:12 +00004177fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00004178
4179rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanarob9820a32004-01-17 00:16:12 +00004180fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004181ac_res=`eval 'as_val=${'$as_ac_Header'}
4182 $as_echo "$as_val"'`
4183 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
4184$as_echo "$ac_res" >&6; }
4185as_val=`eval 'as_val=${'$as_ac_Header'}
4186 $as_echo "$as_val"'`
4187 if test "x$as_val" = x""yes; then
Skip Montanarob9820a32004-01-17 00:16:12 +00004188 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004189#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
Skip Montanarob9820a32004-01-17 00:16:12 +00004190_ACEOF
4191
4192fi
4193
4194done
4195
4196
Martin v. Löwis11437992002-04-12 09:54:03 +00004197
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004198 if test "${ac_cv_header_minix_config_h+set}" = set; then
4199 { $as_echo "$as_me:$LINENO: checking for minix/config.h" >&5
4200$as_echo_n "checking for minix/config.h... " >&6; }
4201if test "${ac_cv_header_minix_config_h+set}" = set; then
4202 $as_echo_n "(cached) " >&6
4203fi
4204{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
4205$as_echo "$ac_cv_header_minix_config_h" >&6; }
4206else
4207 # Is the header compilable?
4208{ $as_echo "$as_me:$LINENO: checking minix/config.h usability" >&5
4209$as_echo_n "checking minix/config.h usability... " >&6; }
4210cat >conftest.$ac_ext <<_ACEOF
4211/* confdefs.h. */
4212_ACEOF
4213cat confdefs.h >>conftest.$ac_ext
4214cat >>conftest.$ac_ext <<_ACEOF
4215/* end confdefs.h. */
4216$ac_includes_default
4217#include <minix/config.h>
4218_ACEOF
4219rm -f conftest.$ac_objext
4220if { (ac_try="$ac_compile"
4221case "(($ac_try" in
4222 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4223 *) ac_try_echo=$ac_try;;
4224esac
4225eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4226$as_echo "$ac_try_echo") >&5
4227 (eval "$ac_compile") 2>conftest.er1
4228 ac_status=$?
4229 grep -v '^ *+' conftest.er1 >conftest.err
4230 rm -f conftest.er1
4231 cat conftest.err >&5
4232 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4233 (exit $ac_status); } && {
4234 test -z "$ac_c_werror_flag" ||
4235 test ! -s conftest.err
4236 } && test -s conftest.$ac_objext; then
4237 ac_header_compiler=yes
4238else
4239 $as_echo "$as_me: failed program was:" >&5
4240sed 's/^/| /' conftest.$ac_ext >&5
4241
4242 ac_header_compiler=no
4243fi
4244
4245rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4246{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4247$as_echo "$ac_header_compiler" >&6; }
4248
4249# Is the header present?
4250{ $as_echo "$as_me:$LINENO: checking minix/config.h presence" >&5
4251$as_echo_n "checking minix/config.h presence... " >&6; }
4252cat >conftest.$ac_ext <<_ACEOF
4253/* confdefs.h. */
4254_ACEOF
4255cat confdefs.h >>conftest.$ac_ext
4256cat >>conftest.$ac_ext <<_ACEOF
4257/* end confdefs.h. */
4258#include <minix/config.h>
4259_ACEOF
4260if { (ac_try="$ac_cpp conftest.$ac_ext"
4261case "(($ac_try" in
4262 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4263 *) ac_try_echo=$ac_try;;
4264esac
4265eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4266$as_echo "$ac_try_echo") >&5
4267 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4268 ac_status=$?
4269 grep -v '^ *+' conftest.er1 >conftest.err
4270 rm -f conftest.er1
4271 cat conftest.err >&5
4272 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4273 (exit $ac_status); } >/dev/null && {
4274 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4275 test ! -s conftest.err
4276 }; then
4277 ac_header_preproc=yes
4278else
4279 $as_echo "$as_me: failed program was:" >&5
4280sed 's/^/| /' conftest.$ac_ext >&5
4281
4282 ac_header_preproc=no
4283fi
4284
4285rm -f conftest.err conftest.$ac_ext
4286{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4287$as_echo "$ac_header_preproc" >&6; }
4288
4289# So? What about this header?
4290case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
4291 yes:no: )
4292 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
4293$as_echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
4294 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the compiler's result" >&5
4295$as_echo "$as_me: WARNING: minix/config.h: proceeding with the compiler's result" >&2;}
4296 ac_header_preproc=yes
4297 ;;
4298 no:yes:* )
4299 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
4300$as_echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
4301 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
4302$as_echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
4303 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: see the Autoconf documentation" >&5
4304$as_echo "$as_me: WARNING: minix/config.h: see the Autoconf documentation" >&2;}
4305 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&5
4306$as_echo "$as_me: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&2;}
4307 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
4308$as_echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;}
4309 { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: in the future, the compiler will take precedence" >&5
4310$as_echo "$as_me: WARNING: minix/config.h: in the future, the compiler will take precedence" >&2;}
4311 ( cat <<\_ASBOX
4312## -------------------------------------- ##
4313## Report this to http://bugs.python.org/ ##
4314## -------------------------------------- ##
4315_ASBOX
4316 ) | sed "s/^/$as_me: WARNING: /" >&2
4317 ;;
4318esac
4319{ $as_echo "$as_me:$LINENO: checking for minix/config.h" >&5
4320$as_echo_n "checking for minix/config.h... " >&6; }
4321if test "${ac_cv_header_minix_config_h+set}" = set; then
4322 $as_echo_n "(cached) " >&6
4323else
4324 ac_cv_header_minix_config_h=$ac_header_preproc
4325fi
4326{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
4327$as_echo "$ac_cv_header_minix_config_h" >&6; }
4328
4329fi
4330if test "x$ac_cv_header_minix_config_h" = x""yes; then
4331 MINIX=yes
4332else
4333 MINIX=
4334fi
4335
4336
4337 if test "$MINIX" = yes; then
4338
4339cat >>confdefs.h <<\_ACEOF
4340#define _POSIX_SOURCE 1
4341_ACEOF
4342
4343
4344cat >>confdefs.h <<\_ACEOF
4345#define _POSIX_1_SOURCE 2
4346_ACEOF
4347
4348
4349cat >>confdefs.h <<\_ACEOF
4350#define _MINIX 1
4351_ACEOF
4352
4353 fi
4354
4355
4356
4357 { $as_echo "$as_me:$LINENO: checking whether it is safe to define __EXTENSIONS__" >&5
4358$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4359if test "${ac_cv_safe_to_define___extensions__+set}" = set; then
4360 $as_echo_n "(cached) " >&6
4361else
4362 cat >conftest.$ac_ext <<_ACEOF
4363/* confdefs.h. */
4364_ACEOF
4365cat confdefs.h >>conftest.$ac_ext
4366cat >>conftest.$ac_ext <<_ACEOF
4367/* end confdefs.h. */
4368
4369# define __EXTENSIONS__ 1
4370 $ac_includes_default
4371int
4372main ()
4373{
4374
4375 ;
4376 return 0;
4377}
4378_ACEOF
4379rm -f conftest.$ac_objext
4380if { (ac_try="$ac_compile"
4381case "(($ac_try" in
4382 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4383 *) ac_try_echo=$ac_try;;
4384esac
4385eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4386$as_echo "$ac_try_echo") >&5
4387 (eval "$ac_compile") 2>conftest.er1
4388 ac_status=$?
4389 grep -v '^ *+' conftest.er1 >conftest.err
4390 rm -f conftest.er1
4391 cat conftest.err >&5
4392 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4393 (exit $ac_status); } && {
4394 test -z "$ac_c_werror_flag" ||
4395 test ! -s conftest.err
4396 } && test -s conftest.$ac_objext; then
4397 ac_cv_safe_to_define___extensions__=yes
4398else
4399 $as_echo "$as_me: failed program was:" >&5
4400sed 's/^/| /' conftest.$ac_ext >&5
4401
4402 ac_cv_safe_to_define___extensions__=no
4403fi
4404
4405rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4406fi
4407{ $as_echo "$as_me:$LINENO: result: $ac_cv_safe_to_define___extensions__" >&5
4408$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4409 test $ac_cv_safe_to_define___extensions__ = yes &&
4410 cat >>confdefs.h <<\_ACEOF
4411#define __EXTENSIONS__ 1
4412_ACEOF
4413
4414 cat >>confdefs.h <<\_ACEOF
4415#define _ALL_SOURCE 1
4416_ACEOF
4417
4418 cat >>confdefs.h <<\_ACEOF
4419#define _GNU_SOURCE 1
4420_ACEOF
4421
4422 cat >>confdefs.h <<\_ACEOF
4423#define _POSIX_PTHREAD_SEMANTICS 1
4424_ACEOF
4425
4426 cat >>confdefs.h <<\_ACEOF
4427#define _TANDEM_SOURCE 1
4428_ACEOF
4429
4430
4431
4432# Check for unsupported systems
4433case $ac_sys_system/$ac_sys_release in
4434atheos*|Linux*/1*)
4435 echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
4436 echo See README for details.
4437 exit 1;;
4438esac
4439
4440
4441{ $as_echo "$as_me:$LINENO: checking for --with-suffix" >&5
4442$as_echo_n "checking for --with-suffix... " >&6; }
4443
4444# Check whether --with-suffix was given.
4445if test "${with_suffix+set}" = set; then
4446 withval=$with_suffix;
4447 case $withval in
4448 no) EXEEXT=;;
4449 yes) EXEEXT=.exe;;
4450 *) EXEEXT=$withval;;
4451 esac
4452fi
4453
4454{ $as_echo "$as_me:$LINENO: result: $EXEEXT" >&5
4455$as_echo "$EXEEXT" >&6; }
4456
4457# Test whether we're running on a non-case-sensitive system, in which
4458# case we give a warning if no ext is given
4459
4460{ $as_echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
4461$as_echo_n "checking for case-insensitive build directory... " >&6; }
4462if test ! -d CaseSensitiveTestDir; then
4463mkdir CaseSensitiveTestDir
4464fi
4465
4466if test -d casesensitivetestdir
4467then
4468 { $as_echo "$as_me:$LINENO: result: yes" >&5
4469$as_echo "yes" >&6; }
4470 BUILDEXEEXT=.exe
4471else
4472 { $as_echo "$as_me:$LINENO: result: no" >&5
4473$as_echo "no" >&6; }
4474 BUILDEXEEXT=$EXEEXT
4475fi
4476rmdir CaseSensitiveTestDir
4477
4478case $MACHDEP in
4479bsdos*)
4480 case $CC in
4481 gcc) CC="$CC -D_HAVE_BSDI";;
4482 esac;;
4483esac
4484
4485case $ac_sys_system in
4486hp*|HP*)
4487 case $CC in
4488 cc|*/cc) CC="$CC -Ae";;
4489 esac;;
4490Monterey*)
4491 case $CC in
4492 cc) CC="$CC -Wl,-Bexport";;
4493 esac;;
4494SunOS*)
4495 # Some functions have a prototype only with that define, e.g. confstr
4496
4497cat >>confdefs.h <<\_ACEOF
4498#define __EXTENSIONS__ 1
4499_ACEOF
4500
4501 ;;
4502esac
4503
4504
4505
4506{ $as_echo "$as_me:$LINENO: checking LIBRARY" >&5
4507$as_echo_n "checking LIBRARY... " >&6; }
4508if test -z "$LIBRARY"
4509then
4510 LIBRARY='libpython$(VERSION).a'
4511fi
4512{ $as_echo "$as_me:$LINENO: result: $LIBRARY" >&5
4513$as_echo "$LIBRARY" >&6; }
4514
4515# LDLIBRARY is the name of the library to link against (as opposed to the
4516# name of the library into which to insert object files). BLDLIBRARY is also
4517# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
4518# is blank as the main program is not linked directly against LDLIBRARY.
4519# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
4520# systems without shared libraries, LDLIBRARY is the same as LIBRARY
4521# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
4522# DLLLIBRARY is the shared (i.e., DLL) library.
4523#
4524# RUNSHARED is used to run shared python without installed libraries
4525#
4526# INSTSONAME is the name of the shared library that will be use to install
4527# on the system - some systems like version suffix, others don't
4528
4529
4530
4531
4532
4533
4534LDLIBRARY="$LIBRARY"
4535BLDLIBRARY='$(LDLIBRARY)'
4536INSTSONAME='$(LDLIBRARY)'
4537DLLLIBRARY=''
4538LDLIBRARYDIR=''
4539RUNSHARED=''
4540
4541# LINKCC is the command that links the python executable -- default is $(CC).
4542# If CXX is set, and if it is needed to link a main function that was
4543# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
4544# python might then depend on the C++ runtime
4545# This is altered for AIX in order to build the export list before
4546# linking.
4547
4548{ $as_echo "$as_me:$LINENO: checking LINKCC" >&5
4549$as_echo_n "checking LINKCC... " >&6; }
4550if test -z "$LINKCC"
4551then
4552 LINKCC='$(PURIFY) $(MAINCC)'
4553 case $ac_sys_system in
4554 AIX*)
4555 exp_extra="\"\""
4556 if test $ac_sys_release -ge 5 -o \
4557 $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then
4558 exp_extra="."
4559 fi
4560 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";;
4561 Monterey64*)
4562 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
4563 QNX*)
4564 # qcc must be used because the other compilers do not
4565 # support -N.
4566 LINKCC=qcc;;
4567 esac
4568fi
4569{ $as_echo "$as_me:$LINENO: result: $LINKCC" >&5
4570$as_echo "$LINKCC" >&6; }
4571
4572# GNULD is set to "yes" if the GNU linker is used. If this goes wrong
4573# make sure we default having it set to "no": this is used by
4574# distutils.unixccompiler to know if it should add --enable-new-dtags
4575# to linker command lines, and failing to detect GNU ld simply results
4576# in the same bahaviour as before.
4577
4578{ $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
4579$as_echo_n "checking for GNU ld... " >&6; }
4580ac_prog=ld
4581if test "$GCC" = yes; then
4582 ac_prog=`$CC -print-prog-name=ld`
4583fi
4584case `"$ac_prog" -V 2>&1 < /dev/null` in
4585 *GNU*)
4586 GNULD=yes;;
4587 *)
4588 GNULD=no;;
4589esac
4590{ $as_echo "$as_me:$LINENO: result: $GNULD" >&5
4591$as_echo "$GNULD" >&6; }
4592
4593{ $as_echo "$as_me:$LINENO: checking for --enable-shared" >&5
4594$as_echo_n "checking for --enable-shared... " >&6; }
4595# Check whether --enable-shared was given.
4596if test "${enable_shared+set}" = set; then
4597 enableval=$enable_shared;
4598fi
4599
4600
4601if test -z "$enable_shared"
4602then
4603 case $ac_sys_system in
4604 CYGWIN* | atheos*)
4605 enable_shared="yes";;
4606 *)
4607 enable_shared="no";;
4608 esac
4609fi
4610{ $as_echo "$as_me:$LINENO: result: $enable_shared" >&5
4611$as_echo "$enable_shared" >&6; }
4612
4613{ $as_echo "$as_me:$LINENO: checking for --enable-profiling" >&5
4614$as_echo_n "checking for --enable-profiling... " >&6; }
4615# Check whether --enable-profiling was given.
4616if test "${enable_profiling+set}" = set; then
4617 enableval=$enable_profiling; ac_save_cc="$CC"
4618 CC="$CC -pg"
4619 if test "$cross_compiling" = yes; then
4620 ac_enable_profiling="no"
4621else
4622 cat >conftest.$ac_ext <<_ACEOF
4623/* confdefs.h. */
4624_ACEOF
4625cat confdefs.h >>conftest.$ac_ext
4626cat >>conftest.$ac_ext <<_ACEOF
4627/* end confdefs.h. */
4628int main() { return 0; }
4629_ACEOF
4630rm -f conftest$ac_exeext
4631if { (ac_try="$ac_link"
4632case "(($ac_try" in
4633 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4634 *) ac_try_echo=$ac_try;;
4635esac
4636eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4637$as_echo "$ac_try_echo") >&5
4638 (eval "$ac_link") 2>&5
4639 ac_status=$?
4640 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4641 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4642 { (case "(($ac_try" in
4643 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4644 *) ac_try_echo=$ac_try;;
4645esac
4646eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4647$as_echo "$ac_try_echo") >&5
4648 (eval "$ac_try") 2>&5
4649 ac_status=$?
4650 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4651 (exit $ac_status); }; }; then
4652 ac_enable_profiling="yes"
4653else
4654 $as_echo "$as_me: program exited with status $ac_status" >&5
4655$as_echo "$as_me: failed program was:" >&5
4656sed 's/^/| /' conftest.$ac_ext >&5
4657
4658( exit $ac_status )
4659ac_enable_profiling="no"
4660fi
4661rm -rf conftest.dSYM
4662rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4663fi
4664
4665
4666 CC="$ac_save_cc"
4667fi
4668
4669{ $as_echo "$as_me:$LINENO: result: $ac_enable_profiling" >&5
4670$as_echo "$ac_enable_profiling" >&6; }
4671
4672case "$ac_enable_profiling" in
4673 "yes")
4674 BASECFLAGS="-pg $BASECFLAGS"
4675 LDFLAGS="-pg $LDFLAGS"
4676 ;;
4677esac
4678
4679{ $as_echo "$as_me:$LINENO: checking LDLIBRARY" >&5
4680$as_echo_n "checking LDLIBRARY... " >&6; }
4681
4682# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
4683# library that we build, but we do not want to link against it (we
4684# will find it with a -framework option). For this reason there is an
4685# extra variable BLDLIBRARY against which Python and the extension
4686# modules are linked, BLDLIBRARY. This is normally the same as
4687# LDLIBRARY, but empty for MacOSX framework builds.
4688if test "$enable_framework"
4689then
4690 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
4691 RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH"
4692 BLDLIBRARY=''
4693else
4694 BLDLIBRARY='$(LDLIBRARY)'
4695fi
4696
4697# Other platforms follow
4698if test $enable_shared = "yes"; then
4699
4700cat >>confdefs.h <<\_ACEOF
4701#define Py_ENABLE_SHARED 1
4702_ACEOF
4703
4704 case $ac_sys_system in
4705 BeOS*)
4706 LDLIBRARY='libpython$(VERSION).so'
4707 ;;
4708 CYGWIN*)
4709 LDLIBRARY='libpython$(VERSION).dll.a'
4710 DLLLIBRARY='libpython$(VERSION).dll'
4711 ;;
4712 SunOS*)
4713 LDLIBRARY='libpython$(VERSION).so'
4714 BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)'
4715 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4716 INSTSONAME="$LDLIBRARY".$SOVERSION
4717 ;;
4718 Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
4719 LDLIBRARY='libpython$(VERSION).so'
4720 BLDLIBRARY='-L. -lpython$(VERSION)'
4721 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4722 case $ac_sys_system in
4723 FreeBSD*)
4724 SOVERSION=`echo $SOVERSION|cut -d "." -f 1`
4725 ;;
4726 esac
4727 INSTSONAME="$LDLIBRARY".$SOVERSION
4728 ;;
4729 hp*|HP*)
4730 case `uname -m` in
4731 ia64)
4732 LDLIBRARY='libpython$(VERSION).so'
4733 ;;
4734 *)
4735 LDLIBRARY='libpython$(VERSION).sl'
4736 ;;
4737 esac
4738 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
4739 RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH}
4740 ;;
4741 OSF*)
4742 LDLIBRARY='libpython$(VERSION).so'
4743 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
4744 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4745 ;;
4746 atheos*)
4747 LDLIBRARY='libpython$(VERSION).so'
4748 BLDLIBRARY='-L. -lpython$(VERSION)'
4749 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
4750 ;;
4751 Darwin*)
4752 LDLIBRARY='libpython$(VERSION).dylib'
4753 BLDLIBRARY='-L. -lpython$(VERSION)'
4754 RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}'
4755 ;;
4756
4757 esac
4758else # shared is disabled
4759 case $ac_sys_system in
4760 CYGWIN*)
4761 BLDLIBRARY='$(LIBRARY)'
4762 LDLIBRARY='libpython$(VERSION).dll.a'
4763 ;;
4764 esac
4765fi
4766
4767{ $as_echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
4768$as_echo "$LDLIBRARY" >&6; }
4769
4770if test -n "$ac_tool_prefix"; then
4771 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4772set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4773{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4774$as_echo_n "checking for $ac_word... " >&6; }
4775if test "${ac_cv_prog_RANLIB+set}" = set; then
4776 $as_echo_n "(cached) " >&6
4777else
4778 if test -n "$RANLIB"; then
4779 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4780else
4781as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4782for as_dir in $PATH
4783do
4784 IFS=$as_save_IFS
4785 test -z "$as_dir" && as_dir=.
4786 for ac_exec_ext in '' $ac_executable_extensions; do
4787 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4788 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4789 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4790 break 2
4791 fi
4792done
4793done
4794IFS=$as_save_IFS
4795
4796fi
4797fi
4798RANLIB=$ac_cv_prog_RANLIB
4799if test -n "$RANLIB"; then
4800 { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
4801$as_echo "$RANLIB" >&6; }
4802else
4803 { $as_echo "$as_me:$LINENO: result: no" >&5
4804$as_echo "no" >&6; }
4805fi
4806
4807
4808fi
4809if test -z "$ac_cv_prog_RANLIB"; then
4810 ac_ct_RANLIB=$RANLIB
4811 # Extract the first word of "ranlib", so it can be a program name with args.
4812set dummy ranlib; ac_word=$2
4813{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4814$as_echo_n "checking for $ac_word... " >&6; }
4815if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4816 $as_echo_n "(cached) " >&6
4817else
4818 if test -n "$ac_ct_RANLIB"; then
4819 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4820else
4821as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4822for as_dir in $PATH
4823do
4824 IFS=$as_save_IFS
4825 test -z "$as_dir" && as_dir=.
4826 for ac_exec_ext in '' $ac_executable_extensions; do
4827 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4828 ac_cv_prog_ac_ct_RANLIB="ranlib"
4829 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4830 break 2
4831 fi
4832done
4833done
4834IFS=$as_save_IFS
4835
4836fi
4837fi
4838ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4839if test -n "$ac_ct_RANLIB"; then
4840 { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4841$as_echo "$ac_ct_RANLIB" >&6; }
4842else
4843 { $as_echo "$as_me:$LINENO: result: no" >&5
4844$as_echo "no" >&6; }
4845fi
4846
4847 if test "x$ac_ct_RANLIB" = x; then
4848 RANLIB=":"
4849 else
4850 case $cross_compiling:$ac_tool_warned in
4851yes:)
4852{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
4853$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4854ac_tool_warned=yes ;;
4855esac
4856 RANLIB=$ac_ct_RANLIB
4857 fi
4858else
4859 RANLIB="$ac_cv_prog_RANLIB"
4860fi
4861
4862
4863for ac_prog in ar aal
4864do
4865 # Extract the first word of "$ac_prog", so it can be a program name with args.
4866set dummy $ac_prog; ac_word=$2
4867{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4868$as_echo_n "checking for $ac_word... " >&6; }
4869if test "${ac_cv_prog_AR+set}" = set; then
4870 $as_echo_n "(cached) " >&6
4871else
4872 if test -n "$AR"; then
4873 ac_cv_prog_AR="$AR" # Let the user override the test.
4874else
4875as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4876for as_dir in $PATH
4877do
4878 IFS=$as_save_IFS
4879 test -z "$as_dir" && as_dir=.
4880 for ac_exec_ext in '' $ac_executable_extensions; do
4881 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4882 ac_cv_prog_AR="$ac_prog"
4883 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4884 break 2
4885 fi
4886done
4887done
4888IFS=$as_save_IFS
4889
4890fi
4891fi
4892AR=$ac_cv_prog_AR
4893if test -n "$AR"; then
4894 { $as_echo "$as_me:$LINENO: result: $AR" >&5
4895$as_echo "$AR" >&6; }
4896else
4897 { $as_echo "$as_me:$LINENO: result: no" >&5
4898$as_echo "no" >&6; }
4899fi
4900
4901
4902 test -n "$AR" && break
4903done
4904test -n "$AR" || AR="ar"
4905
4906
4907# tweak ARFLAGS only if the user didn't set it on the command line
4908
4909if test -z "$ARFLAGS"
4910then
4911 ARFLAGS="rc"
4912fi
4913
4914
4915# Extract the first word of "svnversion", so it can be a program name with args.
4916set dummy svnversion; ac_word=$2
4917{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4918$as_echo_n "checking for $ac_word... " >&6; }
4919if test "${ac_cv_prog_SVNVERSION+set}" = set; then
4920 $as_echo_n "(cached) " >&6
4921else
4922 if test -n "$SVNVERSION"; then
4923 ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test.
4924else
4925as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4926for as_dir in $PATH
4927do
4928 IFS=$as_save_IFS
4929 test -z "$as_dir" && as_dir=.
4930 for ac_exec_ext in '' $ac_executable_extensions; do
4931 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4932 ac_cv_prog_SVNVERSION="found"
4933 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4934 break 2
4935 fi
4936done
4937done
4938IFS=$as_save_IFS
4939
4940 test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found"
4941fi
4942fi
4943SVNVERSION=$ac_cv_prog_SVNVERSION
4944if test -n "$SVNVERSION"; then
4945 { $as_echo "$as_me:$LINENO: result: $SVNVERSION" >&5
4946$as_echo "$SVNVERSION" >&6; }
4947else
4948 { $as_echo "$as_me:$LINENO: result: no" >&5
4949$as_echo "no" >&6; }
4950fi
4951
4952
4953if test $SVNVERSION = found
4954then
4955 SVNVERSION="svnversion \$(srcdir)"
4956else
4957 SVNVERSION="echo Unversioned directory"
4958fi
4959
4960case $MACHDEP in
4961bsdos*|hp*|HP*)
4962 # install -d does not work on BSDI or HP-UX
4963 if test -z "$INSTALL"
4964 then
4965 INSTALL="${srcdir}/install-sh -c"
4966 fi
4967esac
4968ac_aux_dir=
4969for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4970 if test -f "$ac_dir/install-sh"; then
4971 ac_aux_dir=$ac_dir
4972 ac_install_sh="$ac_aux_dir/install-sh -c"
4973 break
4974 elif test -f "$ac_dir/install.sh"; then
4975 ac_aux_dir=$ac_dir
4976 ac_install_sh="$ac_aux_dir/install.sh -c"
4977 break
4978 elif test -f "$ac_dir/shtool"; then
4979 ac_aux_dir=$ac_dir
4980 ac_install_sh="$ac_aux_dir/shtool install -c"
4981 break
4982 fi
4983done
4984if test -z "$ac_aux_dir"; then
4985 { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
4986$as_echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
4987 { (exit 1); exit 1; }; }
4988fi
4989
4990# These three variables are undocumented and unsupported,
4991# and are intended to be withdrawn in a future Autoconf release.
4992# They can cause serious problems if a builder's source tree is in a directory
4993# whose full name contains unusual characters.
4994ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4995ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4996ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4997
4998
4999# Find a good install program. We prefer a C program (faster),
5000# so one script is as good as another. But avoid the broken or
5001# incompatible versions:
5002# SysV /etc/install, /usr/sbin/install
5003# SunOS /usr/etc/install
5004# IRIX /sbin/install
5005# AIX /bin/install
5006# AmigaOS /C/install, which installs bootblocks on floppy discs
5007# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
5008# AFS /usr/afsws/bin/install, which mishandles nonexistent args
5009# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
5010# OS/2's system install, which has a completely different semantic
5011# ./install, which can be erroneously created by make from ./install.sh.
5012# Reject install programs that cannot install multiple files.
5013{ $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
5014$as_echo_n "checking for a BSD-compatible install... " >&6; }
5015if test -z "$INSTALL"; then
5016if test "${ac_cv_path_install+set}" = set; then
5017 $as_echo_n "(cached) " >&6
5018else
5019 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5020for as_dir in $PATH
5021do
5022 IFS=$as_save_IFS
5023 test -z "$as_dir" && as_dir=.
5024 # Account for people who put trailing slashes in PATH elements.
5025case $as_dir/ in
5026 ./ | .// | /cC/* | \
5027 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5028 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
5029 /usr/ucb/* ) ;;
5030 *)
5031 # OSF1 and SCO ODT 3.0 have their own names for install.
5032 # Don't use installbsd from OSF since it installs stuff as root
5033 # by default.
5034 for ac_prog in ginstall scoinst install; do
5035 for ac_exec_ext in '' $ac_executable_extensions; do
5036 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
5037 if test $ac_prog = install &&
5038 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5039 # AIX install. It has an incompatible calling convention.
5040 :
5041 elif test $ac_prog = install &&
5042 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5043 # program-specific install script used by HP pwplus--don't use.
5044 :
5045 else
5046 rm -rf conftest.one conftest.two conftest.dir
5047 echo one > conftest.one
5048 echo two > conftest.two
5049 mkdir conftest.dir
5050 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5051 test -s conftest.one && test -s conftest.two &&
5052 test -s conftest.dir/conftest.one &&
5053 test -s conftest.dir/conftest.two
5054 then
5055 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5056 break 3
5057 fi
5058 fi
5059 fi
5060 done
5061 done
5062 ;;
5063esac
5064
5065done
5066IFS=$as_save_IFS
5067
5068rm -rf conftest.one conftest.two conftest.dir
5069
5070fi
5071 if test "${ac_cv_path_install+set}" = set; then
5072 INSTALL=$ac_cv_path_install
5073 else
5074 # As a last resort, use the slow shell script. Don't cache a
5075 # value for INSTALL within a source directory, because that will
5076 # break other packages using the cache if that directory is
5077 # removed, or if the value is a relative name.
5078 INSTALL=$ac_install_sh
5079 fi
5080fi
5081{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
5082$as_echo "$INSTALL" >&6; }
5083
5084# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5085# It thinks the first close brace ends the variable substitution.
5086test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5087
5088test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5089
5090test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5091
5092
5093# Not every filesystem supports hard links
5094
5095if test -z "$LN" ; then
5096 case $ac_sys_system in
5097 BeOS*) LN="ln -s";;
5098 CYGWIN*) LN="ln -s";;
5099 atheos*) LN="ln -s";;
5100 *) LN=ln;;
5101 esac
5102fi
5103
5104# Check for --with-pydebug
5105{ $as_echo "$as_me:$LINENO: checking for --with-pydebug" >&5
5106$as_echo_n "checking for --with-pydebug... " >&6; }
5107
5108# Check whether --with-pydebug was given.
5109if test "${with_pydebug+set}" = set; then
5110 withval=$with_pydebug;
5111if test "$withval" != no
5112then
5113
5114cat >>confdefs.h <<\_ACEOF
5115#define Py_DEBUG 1
5116_ACEOF
5117
5118 { $as_echo "$as_me:$LINENO: result: yes" >&5
5119$as_echo "yes" >&6; };
5120 Py_DEBUG='true'
5121else { $as_echo "$as_me:$LINENO: result: no" >&5
5122$as_echo "no" >&6; }; Py_DEBUG='false'
5123fi
5124else
5125 { $as_echo "$as_me:$LINENO: result: no" >&5
5126$as_echo "no" >&6; }
5127fi
5128
5129
5130# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
5131# merged with this chunk of code?
5132
5133# Optimizer/debugger flags
5134# ------------------------
5135# (The following bit of code is complicated enough - please keep things
5136# indented properly. Just pretend you're editing Python code. ;-)
5137
5138# There are two parallel sets of case statements below, one that checks to
5139# see if OPT was set and one that does BASECFLAGS setting based upon
5140# compiler and platform. BASECFLAGS tweaks need to be made even if the
5141# user set OPT.
5142
5143# tweak OPT based on compiler and platform, only if the user didn't set
5144# it on the command line
5145
5146if test -z "$OPT"
5147then
5148 case $GCC in
5149 yes)
5150 if test "$CC" != 'g++' ; then
5151 STRICT_PROTO="-Wstrict-prototypes"
5152 fi
5153 # For gcc 4.x we need to use -fwrapv so lets check if its supported
5154 if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then
5155 WRAP="-fwrapv"
5156 fi
5157 case $ac_cv_prog_cc_g in
5158 yes)
5159 if test "$Py_DEBUG" = 'true' ; then
5160 # Optimization messes up debuggers, so turn it off for
5161 # debug builds.
5162 OPT="-g -Wall $STRICT_PROTO"
5163 else
5164 OPT="-g $WRAP -O3 -Wall $STRICT_PROTO"
5165 fi
5166 ;;
5167 *)
5168 OPT="-O3 -Wall $STRICT_PROTO"
5169 ;;
5170 esac
5171 case $ac_sys_system in
5172 SCO_SV*) OPT="$OPT -m486 -DSCO5"
5173 ;;
5174 esac
5175 ;;
5176
5177 *)
5178 OPT="-O"
5179 ;;
5180 esac
5181
5182 # The current (beta) Monterey compiler dies with optimizations
5183 # XXX what is Monterey? Does it still die w/ -O? Can we get rid of this?
5184 case $ac_sys_system in
5185 Monterey*)
5186 OPT=""
5187 ;;
5188 esac
5189
5190fi
5191
5192
5193
5194# The -arch flags for universal builds on OSX
5195UNIVERSAL_ARCH_FLAGS=
5196
5197
5198# tweak BASECFLAGS based on compiler and platform
5199case $GCC in
5200yes)
5201 # Python violates C99 rules, by casting between incompatible
5202 # pointer types. GCC may generate bad code as a result of that,
5203 # so use -fno-strict-aliasing if supported.
5204 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -fno-strict-aliasing" >&5
5205$as_echo_n "checking whether $CC accepts -fno-strict-aliasing... " >&6; }
5206 ac_save_cc="$CC"
5207 CC="$CC -fno-strict-aliasing"
5208 if test "$cross_compiling" = yes; then
5209 ac_cv_no_strict_aliasing_ok=no
5210else
5211 cat >conftest.$ac_ext <<_ACEOF
5212/* confdefs.h. */
5213_ACEOF
5214cat confdefs.h >>conftest.$ac_ext
5215cat >>conftest.$ac_ext <<_ACEOF
5216/* end confdefs.h. */
5217int main() { return 0; }
5218_ACEOF
5219rm -f conftest$ac_exeext
5220if { (ac_try="$ac_link"
5221case "(($ac_try" in
5222 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5223 *) ac_try_echo=$ac_try;;
5224esac
5225eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5226$as_echo "$ac_try_echo") >&5
5227 (eval "$ac_link") 2>&5
5228 ac_status=$?
5229 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5230 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5231 { (case "(($ac_try" in
5232 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5233 *) ac_try_echo=$ac_try;;
5234esac
5235eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5236$as_echo "$ac_try_echo") >&5
5237 (eval "$ac_try") 2>&5
5238 ac_status=$?
5239 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5240 (exit $ac_status); }; }; then
5241 ac_cv_no_strict_aliasing_ok=yes
5242else
5243 $as_echo "$as_me: program exited with status $ac_status" >&5
5244$as_echo "$as_me: failed program was:" >&5
5245sed 's/^/| /' conftest.$ac_ext >&5
5246
5247( exit $ac_status )
5248ac_cv_no_strict_aliasing_ok=no
5249fi
5250rm -rf conftest.dSYM
5251rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5252fi
5253
5254
5255 CC="$ac_save_cc"
5256 { $as_echo "$as_me:$LINENO: result: $ac_cv_no_strict_aliasing_ok" >&5
5257$as_echo "$ac_cv_no_strict_aliasing_ok" >&6; }
5258 if test $ac_cv_no_strict_aliasing_ok = yes
5259 then
5260 BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
5261 fi
5262
5263 # if using gcc on alpha, use -mieee to get (near) full IEEE 754
5264 # support. Without this, treatment of subnormals doesn't follow
5265 # the standard.
5266 case $ac_sys_machine in
5267 alpha*)
5268 BASECFLAGS="$BASECFLAGS -mieee"
5269 ;;
5270 esac
5271
5272 case $ac_sys_system in
5273 SCO_SV*)
5274 BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
5275 ;;
5276 # is there any other compiler on Darwin besides gcc?
5277 Darwin*)
5278 # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
5279 # used to be here, but non-Apple gcc doesn't accept them.
5280
5281
5282 if test "${enable_universalsdk}"; then
5283 UNIVERSAL_ARCH_FLAGS=""
5284 if test "$UNIVERSAL_ARCHS" = "32-bit" ; then
5285 UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386"
5286 ARCH_RUN_32BIT=""
5287
5288 elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then
5289 UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64"
5290
5291 elif test "$UNIVERSAL_ARCHS" = "all" ; then
5292 UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64"
5293 ARCH_RUN_32BIT="arch -i386 -ppc"
5294
5295 else
5296 { { $as_echo "$as_me:$LINENO: error: proper usage is --with-universalarch=32-bit|64-bit|all" >&5
5297$as_echo "$as_me: error: proper usage is --with-universalarch=32-bit|64-bit|all" >&2;}
5298 { (exit 1); exit 1; }; }
5299
5300 fi
5301
5302
5303 BASECFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${BASECFLAGS}"
5304 tgt=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
5305 if test "${UNIVERSALSDK}" != "/" -a "${tgt}" '>' '10.4' ; then
5306 CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
5307 fi
5308 fi
5309
5310 # Calculate the right deployment target for this build.
5311 #
5312 cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
5313 if test ${cur_target} '>' 10.2; then
5314 cur_target=10.3
5315 fi
5316 if test "${UNIVERSAL_ARCHS}" = "all"; then
5317 # Ensure that the default platform for a 4-way
5318 # universal build is OSX 10.5, that's the first
5319 # OS release where 4-way builds make sense.
5320 cur_target='10.5'
5321 fi
5322 CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
5323
5324 # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
5325 # environment with a value that is the same as what we'll use
5326 # in the Makefile to ensure that we'll get the same compiler
5327 # environment during configure and build time.
5328 MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
5329 export MACOSX_DEPLOYMENT_TARGET
5330 EXPORT_MACOSX_DEPLOYMENT_TARGET=''
5331
5332 ;;
5333 OSF*)
5334 BASECFLAGS="$BASECFLAGS -mieee"
5335 ;;
5336 esac
5337 ;;
5338
5339*)
5340 case $ac_sys_system in
5341 OpenUNIX*|UnixWare*)
5342 BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
5343 ;;
5344 OSF*)
5345 BASECFLAGS="$BASECFLAGS -ieee -std"
5346 ;;
5347 SCO_SV*)
5348 BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
5349 ;;
5350 esac
5351 ;;
5352esac
5353
5354if test "$Py_DEBUG" = 'true'; then
5355 :
5356else
5357 OPT="-DNDEBUG $OPT"
5358fi
5359
5360if test "$ac_arch_flags"
5361then
5362 BASECFLAGS="$BASECFLAGS $ac_arch_flags"
5363fi
5364
5365# disable check for icc since it seems to pass, but generates a warning
5366if test "$CC" = icc
5367then
5368 ac_cv_opt_olimit_ok=no
5369fi
5370
5371{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
5372$as_echo_n "checking whether $CC accepts -OPT:Olimit=0... " >&6; }
5373if test "${ac_cv_opt_olimit_ok+set}" = set; then
5374 $as_echo_n "(cached) " >&6
5375else
5376 ac_save_cc="$CC"
5377CC="$CC -OPT:Olimit=0"
5378if test "$cross_compiling" = yes; then
5379 ac_cv_opt_olimit_ok=no
5380else
5381 cat >conftest.$ac_ext <<_ACEOF
5382/* confdefs.h. */
5383_ACEOF
5384cat confdefs.h >>conftest.$ac_ext
5385cat >>conftest.$ac_ext <<_ACEOF
5386/* end confdefs.h. */
5387int main() { return 0; }
5388_ACEOF
5389rm -f conftest$ac_exeext
5390if { (ac_try="$ac_link"
5391case "(($ac_try" in
5392 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5393 *) ac_try_echo=$ac_try;;
5394esac
5395eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5396$as_echo "$ac_try_echo") >&5
5397 (eval "$ac_link") 2>&5
5398 ac_status=$?
5399 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5400 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5401 { (case "(($ac_try" in
5402 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5403 *) ac_try_echo=$ac_try;;
5404esac
5405eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5406$as_echo "$ac_try_echo") >&5
5407 (eval "$ac_try") 2>&5
5408 ac_status=$?
5409 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5410 (exit $ac_status); }; }; then
5411 ac_cv_opt_olimit_ok=yes
5412else
5413 $as_echo "$as_me: program exited with status $ac_status" >&5
5414$as_echo "$as_me: failed program was:" >&5
5415sed 's/^/| /' conftest.$ac_ext >&5
5416
5417( exit $ac_status )
5418ac_cv_opt_olimit_ok=no
5419fi
5420rm -rf conftest.dSYM
5421rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5422fi
5423
5424
5425CC="$ac_save_cc"
5426fi
5427
5428{ $as_echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
5429$as_echo "$ac_cv_opt_olimit_ok" >&6; }
5430if test $ac_cv_opt_olimit_ok = yes; then
5431 case $ac_sys_system in
5432 # XXX is this branch needed? On MacOSX 10.2.2 the result of the
5433 # olimit_ok test is "no". Is it "yes" in some other Darwin-esque
5434 # environment?
5435 Darwin*)
5436 ;;
5437 *)
5438 BASECFLAGS="$BASECFLAGS -OPT:Olimit=0"
5439 ;;
5440 esac
5441else
5442 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
5443$as_echo_n "checking whether $CC accepts -Olimit 1500... " >&6; }
5444 if test "${ac_cv_olimit_ok+set}" = set; then
5445 $as_echo_n "(cached) " >&6
5446else
5447 ac_save_cc="$CC"
5448 CC="$CC -Olimit 1500"
5449 if test "$cross_compiling" = yes; then
5450 ac_cv_olimit_ok=no
5451else
5452 cat >conftest.$ac_ext <<_ACEOF
5453/* confdefs.h. */
5454_ACEOF
5455cat confdefs.h >>conftest.$ac_ext
5456cat >>conftest.$ac_ext <<_ACEOF
5457/* end confdefs.h. */
5458int main() { return 0; }
5459_ACEOF
5460rm -f conftest$ac_exeext
5461if { (ac_try="$ac_link"
5462case "(($ac_try" in
5463 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5464 *) ac_try_echo=$ac_try;;
5465esac
5466eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5467$as_echo "$ac_try_echo") >&5
5468 (eval "$ac_link") 2>&5
5469 ac_status=$?
5470 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5471 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5472 { (case "(($ac_try" in
5473 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5474 *) ac_try_echo=$ac_try;;
5475esac
5476eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5477$as_echo "$ac_try_echo") >&5
5478 (eval "$ac_try") 2>&5
5479 ac_status=$?
5480 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5481 (exit $ac_status); }; }; then
5482 ac_cv_olimit_ok=yes
5483else
5484 $as_echo "$as_me: program exited with status $ac_status" >&5
5485$as_echo "$as_me: failed program was:" >&5
5486sed 's/^/| /' conftest.$ac_ext >&5
5487
5488( exit $ac_status )
5489ac_cv_olimit_ok=no
5490fi
5491rm -rf conftest.dSYM
5492rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5493fi
5494
5495
5496 CC="$ac_save_cc"
5497fi
5498
5499 { $as_echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
5500$as_echo "$ac_cv_olimit_ok" >&6; }
5501 if test $ac_cv_olimit_ok = yes; then
5502 BASECFLAGS="$BASECFLAGS -Olimit 1500"
5503 fi
5504fi
5505
5506# Check whether GCC supports PyArg_ParseTuple format
5507if test "$GCC" = "yes"
5508then
5509 { $as_echo "$as_me:$LINENO: checking whether gcc supports ParseTuple __format__" >&5
5510$as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; }
5511 save_CFLAGS=$CFLAGS
5512 CFLAGS="$CFLAGS -Werror"
5513 cat >conftest.$ac_ext <<_ACEOF
5514/* confdefs.h. */
5515_ACEOF
5516cat confdefs.h >>conftest.$ac_ext
5517cat >>conftest.$ac_ext <<_ACEOF
5518/* end confdefs.h. */
5519
5520 void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2)));
5521
5522int
5523main ()
5524{
5525
5526 ;
5527 return 0;
5528}
5529_ACEOF
5530rm -f conftest.$ac_objext
5531if { (ac_try="$ac_compile"
5532case "(($ac_try" in
5533 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5534 *) ac_try_echo=$ac_try;;
5535esac
5536eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5537$as_echo "$ac_try_echo") >&5
5538 (eval "$ac_compile") 2>conftest.er1
5539 ac_status=$?
5540 grep -v '^ *+' conftest.er1 >conftest.err
5541 rm -f conftest.er1
5542 cat conftest.err >&5
5543 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5544 (exit $ac_status); } && {
5545 test -z "$ac_c_werror_flag" ||
5546 test ! -s conftest.err
5547 } && test -s conftest.$ac_objext; then
5548
5549cat >>confdefs.h <<\_ACEOF
5550#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1
5551_ACEOF
5552
5553 { $as_echo "$as_me:$LINENO: result: yes" >&5
5554$as_echo "yes" >&6; }
5555else
5556 $as_echo "$as_me: failed program was:" >&5
5557sed 's/^/| /' conftest.$ac_ext >&5
5558
5559 { $as_echo "$as_me:$LINENO: result: no" >&5
5560$as_echo "no" >&6; }
5561
5562fi
5563
5564rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5565 CFLAGS=$save_CFLAGS
5566fi
5567
5568# On some compilers, pthreads are available without further options
5569# (e.g. MacOS X). On some of these systems, the compiler will not
5570# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
5571# So we have to see first whether pthreads are available without
5572# options before we can check whether -Kpthread improves anything.
5573{ $as_echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
5574$as_echo_n "checking whether pthreads are available without options... " >&6; }
5575if test "${ac_cv_pthread_is_default+set}" = set; then
5576 $as_echo_n "(cached) " >&6
5577else
5578 if test "$cross_compiling" = yes; then
5579 ac_cv_pthread_is_default=no
5580else
5581 cat >conftest.$ac_ext <<_ACEOF
5582/* confdefs.h. */
5583_ACEOF
5584cat confdefs.h >>conftest.$ac_ext
5585cat >>conftest.$ac_ext <<_ACEOF
5586/* end confdefs.h. */
5587
5588#include <pthread.h>
5589
5590void* routine(void* p){return NULL;}
5591
5592int main(){
5593 pthread_t p;
5594 if(pthread_create(&p,NULL,routine,NULL)!=0)
5595 return 1;
5596 (void)pthread_detach(p);
5597 return 0;
5598}
5599
5600_ACEOF
5601rm -f conftest$ac_exeext
5602if { (ac_try="$ac_link"
5603case "(($ac_try" in
5604 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5605 *) ac_try_echo=$ac_try;;
5606esac
5607eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5608$as_echo "$ac_try_echo") >&5
5609 (eval "$ac_link") 2>&5
5610 ac_status=$?
5611 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5612 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5613 { (case "(($ac_try" in
5614 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5615 *) ac_try_echo=$ac_try;;
5616esac
5617eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5618$as_echo "$ac_try_echo") >&5
5619 (eval "$ac_try") 2>&5
5620 ac_status=$?
5621 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5622 (exit $ac_status); }; }; then
5623
5624 ac_cv_pthread_is_default=yes
5625 ac_cv_kthread=no
5626 ac_cv_pthread=no
5627
5628else
5629 $as_echo "$as_me: program exited with status $ac_status" >&5
5630$as_echo "$as_me: failed program was:" >&5
5631sed 's/^/| /' conftest.$ac_ext >&5
5632
5633( exit $ac_status )
5634ac_cv_pthread_is_default=no
5635fi
5636rm -rf conftest.dSYM
5637rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5638fi
5639
5640
5641
5642fi
5643
5644{ $as_echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
5645$as_echo "$ac_cv_pthread_is_default" >&6; }
5646
5647
5648if test $ac_cv_pthread_is_default = yes
5649then
5650 ac_cv_kpthread=no
5651else
5652# -Kpthread, if available, provides the right #defines
5653# and linker options to make pthread_create available
5654# Some compilers won't report that they do not support -Kpthread,
5655# so we need to run a program to see whether it really made the
5656# function available.
5657{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
5658$as_echo_n "checking whether $CC accepts -Kpthread... " >&6; }
5659if test "${ac_cv_kpthread+set}" = set; then
5660 $as_echo_n "(cached) " >&6
5661else
5662 ac_save_cc="$CC"
5663CC="$CC -Kpthread"
5664if test "$cross_compiling" = yes; then
5665 ac_cv_kpthread=no
5666else
5667 cat >conftest.$ac_ext <<_ACEOF
5668/* confdefs.h. */
5669_ACEOF
5670cat confdefs.h >>conftest.$ac_ext
5671cat >>conftest.$ac_ext <<_ACEOF
5672/* end confdefs.h. */
5673
5674#include <pthread.h>
5675
5676void* routine(void* p){return NULL;}
5677
5678int main(){
5679 pthread_t p;
5680 if(pthread_create(&p,NULL,routine,NULL)!=0)
5681 return 1;
5682 (void)pthread_detach(p);
5683 return 0;
5684}
5685
5686_ACEOF
5687rm -f conftest$ac_exeext
5688if { (ac_try="$ac_link"
5689case "(($ac_try" in
5690 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5691 *) ac_try_echo=$ac_try;;
5692esac
5693eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5694$as_echo "$ac_try_echo") >&5
5695 (eval "$ac_link") 2>&5
5696 ac_status=$?
5697 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5698 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5699 { (case "(($ac_try" in
5700 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5701 *) ac_try_echo=$ac_try;;
5702esac
5703eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5704$as_echo "$ac_try_echo") >&5
5705 (eval "$ac_try") 2>&5
5706 ac_status=$?
5707 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5708 (exit $ac_status); }; }; then
5709 ac_cv_kpthread=yes
5710else
5711 $as_echo "$as_me: program exited with status $ac_status" >&5
5712$as_echo "$as_me: failed program was:" >&5
5713sed 's/^/| /' conftest.$ac_ext >&5
5714
5715( exit $ac_status )
5716ac_cv_kpthread=no
5717fi
5718rm -rf conftest.dSYM
5719rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5720fi
5721
5722
5723CC="$ac_save_cc"
5724fi
5725
5726{ $as_echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
5727$as_echo "$ac_cv_kpthread" >&6; }
5728fi
5729
5730if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no
5731then
5732# -Kthread, if available, provides the right #defines
5733# and linker options to make pthread_create available
5734# Some compilers won't report that they do not support -Kthread,
5735# so we need to run a program to see whether it really made the
5736# function available.
5737{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -Kthread" >&5
5738$as_echo_n "checking whether $CC accepts -Kthread... " >&6; }
5739if test "${ac_cv_kthread+set}" = set; then
5740 $as_echo_n "(cached) " >&6
5741else
5742 ac_save_cc="$CC"
5743CC="$CC -Kthread"
5744if test "$cross_compiling" = yes; then
5745 ac_cv_kthread=no
5746else
5747 cat >conftest.$ac_ext <<_ACEOF
5748/* confdefs.h. */
5749_ACEOF
5750cat confdefs.h >>conftest.$ac_ext
5751cat >>conftest.$ac_ext <<_ACEOF
5752/* end confdefs.h. */
5753
5754#include <pthread.h>
5755
5756void* routine(void* p){return NULL;}
5757
5758int main(){
5759 pthread_t p;
5760 if(pthread_create(&p,NULL,routine,NULL)!=0)
5761 return 1;
5762 (void)pthread_detach(p);
5763 return 0;
5764}
5765
5766_ACEOF
5767rm -f conftest$ac_exeext
5768if { (ac_try="$ac_link"
5769case "(($ac_try" in
5770 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5771 *) ac_try_echo=$ac_try;;
5772esac
5773eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5774$as_echo "$ac_try_echo") >&5
5775 (eval "$ac_link") 2>&5
5776 ac_status=$?
5777 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5778 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5779 { (case "(($ac_try" in
5780 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5781 *) ac_try_echo=$ac_try;;
5782esac
5783eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5784$as_echo "$ac_try_echo") >&5
5785 (eval "$ac_try") 2>&5
5786 ac_status=$?
5787 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5788 (exit $ac_status); }; }; then
5789 ac_cv_kthread=yes
5790else
5791 $as_echo "$as_me: program exited with status $ac_status" >&5
5792$as_echo "$as_me: failed program was:" >&5
5793sed 's/^/| /' conftest.$ac_ext >&5
5794
5795( exit $ac_status )
5796ac_cv_kthread=no
5797fi
5798rm -rf conftest.dSYM
5799rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5800fi
5801
5802
5803CC="$ac_save_cc"
5804fi
5805
5806{ $as_echo "$as_me:$LINENO: result: $ac_cv_kthread" >&5
5807$as_echo "$ac_cv_kthread" >&6; }
5808fi
5809
5810if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no
5811then
5812# -pthread, if available, provides the right #defines
5813# and linker options to make pthread_create available
5814# Some compilers won't report that they do not support -pthread,
5815# so we need to run a program to see whether it really made the
5816# function available.
5817{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -pthread" >&5
5818$as_echo_n "checking whether $CC accepts -pthread... " >&6; }
5819if test "${ac_cv_thread+set}" = set; then
5820 $as_echo_n "(cached) " >&6
5821else
5822 ac_save_cc="$CC"
5823CC="$CC -pthread"
5824if test "$cross_compiling" = yes; then
5825 ac_cv_pthread=no
5826else
5827 cat >conftest.$ac_ext <<_ACEOF
5828/* confdefs.h. */
5829_ACEOF
5830cat confdefs.h >>conftest.$ac_ext
5831cat >>conftest.$ac_ext <<_ACEOF
5832/* end confdefs.h. */
5833
5834#include <pthread.h>
5835
5836void* routine(void* p){return NULL;}
5837
5838int main(){
5839 pthread_t p;
5840 if(pthread_create(&p,NULL,routine,NULL)!=0)
5841 return 1;
5842 (void)pthread_detach(p);
5843 return 0;
5844}
5845
5846_ACEOF
5847rm -f conftest$ac_exeext
5848if { (ac_try="$ac_link"
5849case "(($ac_try" in
5850 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5851 *) ac_try_echo=$ac_try;;
5852esac
5853eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5854$as_echo "$ac_try_echo") >&5
5855 (eval "$ac_link") 2>&5
5856 ac_status=$?
5857 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5858 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5859 { (case "(($ac_try" in
5860 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5861 *) ac_try_echo=$ac_try;;
5862esac
5863eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5864$as_echo "$ac_try_echo") >&5
5865 (eval "$ac_try") 2>&5
5866 ac_status=$?
5867 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5868 (exit $ac_status); }; }; then
5869 ac_cv_pthread=yes
5870else
5871 $as_echo "$as_me: program exited with status $ac_status" >&5
5872$as_echo "$as_me: failed program was:" >&5
5873sed 's/^/| /' conftest.$ac_ext >&5
5874
5875( exit $ac_status )
5876ac_cv_pthread=no
5877fi
5878rm -rf conftest.dSYM
5879rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5880fi
5881
5882
5883CC="$ac_save_cc"
5884fi
5885
5886{ $as_echo "$as_me:$LINENO: result: $ac_cv_pthread" >&5
5887$as_echo "$ac_cv_pthread" >&6; }
5888fi
5889
5890# If we have set a CC compiler flag for thread support then
5891# check if it works for CXX, too.
5892ac_cv_cxx_thread=no
5893if test ! -z "$CXX"
5894then
5895{ $as_echo "$as_me:$LINENO: checking whether $CXX also accepts flags for thread support" >&5
5896$as_echo_n "checking whether $CXX also accepts flags for thread support... " >&6; }
5897ac_save_cxx="$CXX"
5898
5899if test "$ac_cv_kpthread" = "yes"
5900then
5901 CXX="$CXX -Kpthread"
5902 ac_cv_cxx_thread=yes
5903elif test "$ac_cv_kthread" = "yes"
5904then
5905 CXX="$CXX -Kthread"
5906 ac_cv_cxx_thread=yes
5907elif test "$ac_cv_pthread" = "yes"
5908then
5909 CXX="$CXX -pthread"
5910 ac_cv_cxx_thread=yes
5911fi
5912
5913if test $ac_cv_cxx_thread = yes
5914then
5915 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
5916 $CXX -c conftest.$ac_ext 2>&5
5917 if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
5918 && test -s conftest$ac_exeext && ./conftest$ac_exeext
5919 then
5920 ac_cv_cxx_thread=yes
5921 else
5922 ac_cv_cxx_thread=no
5923 fi
5924 rm -fr conftest*
5925fi
5926{ $as_echo "$as_me:$LINENO: result: $ac_cv_cxx_thread" >&5
5927$as_echo "$ac_cv_cxx_thread" >&6; }
5928fi
5929CXX="$ac_save_cxx"
5930
5931
5932# checks for header files
5933{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
5934$as_echo_n "checking for ANSI C header files... " >&6; }
5935if test "${ac_cv_header_stdc+set}" = set; then
5936 $as_echo_n "(cached) " >&6
5937else
5938 cat >conftest.$ac_ext <<_ACEOF
5939/* confdefs.h. */
5940_ACEOF
5941cat confdefs.h >>conftest.$ac_ext
5942cat >>conftest.$ac_ext <<_ACEOF
5943/* end confdefs.h. */
5944#include <stdlib.h>
5945#include <stdarg.h>
5946#include <string.h>
5947#include <float.h>
5948
5949int
5950main ()
5951{
5952
5953 ;
5954 return 0;
5955}
5956_ACEOF
5957rm -f conftest.$ac_objext
5958if { (ac_try="$ac_compile"
5959case "(($ac_try" in
5960 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5961 *) ac_try_echo=$ac_try;;
5962esac
5963eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5964$as_echo "$ac_try_echo") >&5
5965 (eval "$ac_compile") 2>conftest.er1
5966 ac_status=$?
5967 grep -v '^ *+' conftest.er1 >conftest.err
5968 rm -f conftest.er1
5969 cat conftest.err >&5
5970 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5971 (exit $ac_status); } && {
5972 test -z "$ac_c_werror_flag" ||
5973 test ! -s conftest.err
5974 } && test -s conftest.$ac_objext; then
5975 ac_cv_header_stdc=yes
5976else
5977 $as_echo "$as_me: failed program was:" >&5
5978sed 's/^/| /' conftest.$ac_ext >&5
5979
5980 ac_cv_header_stdc=no
5981fi
5982
5983rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5984
5985if test $ac_cv_header_stdc = yes; then
5986 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5987 cat >conftest.$ac_ext <<_ACEOF
5988/* confdefs.h. */
5989_ACEOF
5990cat confdefs.h >>conftest.$ac_ext
5991cat >>conftest.$ac_ext <<_ACEOF
5992/* end confdefs.h. */
5993#include <string.h>
5994
5995_ACEOF
5996if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5997 $EGREP "memchr" >/dev/null 2>&1; then
5998 :
5999else
6000 ac_cv_header_stdc=no
6001fi
6002rm -f conftest*
6003
6004fi
6005
6006if test $ac_cv_header_stdc = yes; then
6007 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6008 cat >conftest.$ac_ext <<_ACEOF
6009/* confdefs.h. */
6010_ACEOF
6011cat confdefs.h >>conftest.$ac_ext
6012cat >>conftest.$ac_ext <<_ACEOF
6013/* end confdefs.h. */
6014#include <stdlib.h>
6015
6016_ACEOF
6017if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6018 $EGREP "free" >/dev/null 2>&1; then
6019 :
6020else
6021 ac_cv_header_stdc=no
6022fi
6023rm -f conftest*
6024
6025fi
6026
6027if test $ac_cv_header_stdc = yes; then
6028 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6029 if test "$cross_compiling" = yes; then
6030 :
6031else
6032 cat >conftest.$ac_ext <<_ACEOF
6033/* confdefs.h. */
6034_ACEOF
6035cat confdefs.h >>conftest.$ac_ext
6036cat >>conftest.$ac_ext <<_ACEOF
6037/* end confdefs.h. */
6038#include <ctype.h>
6039#include <stdlib.h>
6040#if ((' ' & 0x0FF) == 0x020)
6041# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6042# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6043#else
6044# define ISLOWER(c) \
6045 (('a' <= (c) && (c) <= 'i') \
6046 || ('j' <= (c) && (c) <= 'r') \
6047 || ('s' <= (c) && (c) <= 'z'))
6048# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6049#endif
6050
6051#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6052int
6053main ()
6054{
6055 int i;
6056 for (i = 0; i < 256; i++)
6057 if (XOR (islower (i), ISLOWER (i))
6058 || toupper (i) != TOUPPER (i))
6059 return 2;
6060 return 0;
6061}
6062_ACEOF
6063rm -f conftest$ac_exeext
6064if { (ac_try="$ac_link"
6065case "(($ac_try" in
6066 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6067 *) ac_try_echo=$ac_try;;
6068esac
6069eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6070$as_echo "$ac_try_echo") >&5
6071 (eval "$ac_link") 2>&5
6072 ac_status=$?
6073 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6074 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6075 { (case "(($ac_try" in
6076 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6077 *) ac_try_echo=$ac_try;;
6078esac
6079eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6080$as_echo "$ac_try_echo") >&5
6081 (eval "$ac_try") 2>&5
6082 ac_status=$?
6083 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6084 (exit $ac_status); }; }; then
6085 :
6086else
6087 $as_echo "$as_me: program exited with status $ac_status" >&5
6088$as_echo "$as_me: failed program was:" >&5
6089sed 's/^/| /' conftest.$ac_ext >&5
6090
6091( exit $ac_status )
6092ac_cv_header_stdc=no
6093fi
6094rm -rf conftest.dSYM
6095rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6096fi
6097
6098
6099fi
6100fi
6101{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
6102$as_echo "$ac_cv_header_stdc" >&6; }
6103if test $ac_cv_header_stdc = yes; then
6104
6105cat >>confdefs.h <<\_ACEOF
6106#define STDC_HEADERS 1
6107_ACEOF
6108
6109fi
6110
6111
Martin v. Löwis11437992002-04-12 09:54:03 +00006112
6113
6114
6115
6116
6117
6118
6119
6120
6121
6122
6123
6124
6125
6126
6127
6128
6129
6130
6131
6132
6133
6134
6135
6136
6137
6138
6139
6140
6141
6142
6143
6144
6145
6146
Anthony Baxter8a560de2004-10-13 15:30:56 +00006147
Martin v. Löwisc3001752005-01-23 09:27:24 +00006148
Martin v. Löwis11017b12006-01-14 18:12:57 +00006149
Martin v. Löwis5f5d99c2006-05-16 07:05:37 +00006150
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00006151
6152
6153
6154
6155
6156
6157
6158
Martin v. Löwis40e9aed2006-10-02 15:20:37 +00006159
Christian Heimesfb2d25a2008-01-07 16:12:44 +00006160
Christian Heimes0e9ab5f2008-03-21 23:49:44 +00006161
6162
Neal Norwitz9fdfaaf2008-03-28 05:34:59 +00006163
Martin v. Löwis8c255e42008-05-23 15:06:50 +00006164
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00006165for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \
6166fcntl.h grp.h \
Neal Norwitz9fdfaaf2008-03-28 05:34:59 +00006167ieeefp.h io.h langinfo.h libintl.h ncurses.h poll.h process.h pthread.h \
Martin v. Löwis40e9aed2006-10-02 15:20:37 +00006168shadow.h signal.h stdint.h stropts.h termios.h thread.h \
Martin v. Löwis14e73b12003-01-01 09:51:12 +00006169unistd.h utime.h \
Christian Heimes0e9ab5f2008-03-21 23:49:44 +00006170sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \
6171sys/lock.h sys/mkdev.h sys/modem.h \
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00006172sys/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 +00006173sys/termio.h sys/time.h \
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00006174sys/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 +00006175sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \
Christian Heimesfb2d25a2008-01-07 16:12:44 +00006176bluetooth/bluetooth.h linux/tipc.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00006177do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006178as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
Martin v. Löwiseba40652007-08-30 20:10:57 +00006179if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006180 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6181$as_echo_n "checking for $ac_header... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006182if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006183 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00006184fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006185ac_res=`eval 'as_val=${'$as_ac_Header'}
6186 $as_echo "$as_val"'`
6187 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
6188$as_echo "$ac_res" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006189else
Martin v. Löwis11437992002-04-12 09:54:03 +00006190 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006191{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
6192$as_echo_n "checking $ac_header usability... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006193cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006194/* confdefs.h. */
6195_ACEOF
6196cat confdefs.h >>conftest.$ac_ext
6197cat >>conftest.$ac_ext <<_ACEOF
6198/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006199$ac_includes_default
6200#include <$ac_header>
6201_ACEOF
6202rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006203if { (ac_try="$ac_compile"
6204case "(($ac_try" in
6205 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6206 *) ac_try_echo=$ac_try;;
6207esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006208eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6209$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006210 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00006211 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006212 grep -v '^ *+' conftest.er1 >conftest.err
6213 rm -f conftest.er1
6214 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006215 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006216 (exit $ac_status); } && {
6217 test -z "$ac_c_werror_flag" ||
6218 test ! -s conftest.err
6219 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006220 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00006221else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006222 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006223sed 's/^/| /' conftest.$ac_ext >&5
6224
Martin v. Löwiseba40652007-08-30 20:10:57 +00006225 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +00006226fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006227
6228rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006229{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6230$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006231
6232# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006233{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
6234$as_echo_n "checking $ac_header presence... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006235cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006236/* confdefs.h. */
6237_ACEOF
6238cat confdefs.h >>conftest.$ac_ext
6239cat >>conftest.$ac_ext <<_ACEOF
6240/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006241#include <$ac_header>
6242_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006243if { (ac_try="$ac_cpp conftest.$ac_ext"
6244case "(($ac_try" in
6245 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6246 *) ac_try_echo=$ac_try;;
6247esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006248eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6249$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006250 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00006251 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00006252 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00006253 rm -f conftest.er1
6254 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006255 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006256 (exit $ac_status); } >/dev/null && {
6257 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6258 test ! -s conftest.err
6259 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006260 ac_header_preproc=yes
6261else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006262 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006263sed 's/^/| /' conftest.$ac_ext >&5
6264
Martin v. Löwis11437992002-04-12 09:54:03 +00006265 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00006266fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006267
Martin v. Löwis11437992002-04-12 09:54:03 +00006268rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006269{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6270$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006271
6272# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006273case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6274 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006275 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
6276$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
6277 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
6278$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00006279 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00006280 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00006281 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006282 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
6283$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
6284 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
6285$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
6286 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
6287$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
6288 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
6289$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
6290 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
6291$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
6292 { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
6293$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00006294 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00006295## -------------------------------------- ##
6296## Report this to http://bugs.python.org/ ##
6297## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00006298_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00006299 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00006300 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00006301esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006302{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6303$as_echo_n "checking for $ac_header... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006304if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006305 $as_echo_n "(cached) " >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00006306else
Skip Montanarof0d5f792004-08-15 14:08:23 +00006307 eval "$as_ac_Header=\$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006308fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006309ac_res=`eval 'as_val=${'$as_ac_Header'}
6310 $as_echo "$as_val"'`
6311 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
6312$as_echo "$ac_res" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006313
6314fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006315as_val=`eval 'as_val=${'$as_ac_Header'}
6316 $as_echo "$as_val"'`
6317 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006318 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006319#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +00006320_ACEOF
6321
6322fi
6323
Guido van Rossum627b2d71993-12-24 10:39:16 +00006324done
6325
Martin v. Löwis11437992002-04-12 09:54:03 +00006326
6327
6328
6329
6330
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006331ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00006332for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006333 as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
6334{ $as_echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
6335$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006336if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006337 $as_echo_n "(cached) " >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00006338else
Martin v. Löwis11437992002-04-12 09:54:03 +00006339 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006340/* confdefs.h. */
6341_ACEOF
6342cat confdefs.h >>conftest.$ac_ext
6343cat >>conftest.$ac_ext <<_ACEOF
6344/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006345#include <sys/types.h>
6346#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00006347
Martin v. Löwis11437992002-04-12 09:54:03 +00006348int
6349main ()
6350{
6351if ((DIR *) 0)
6352return 0;
6353 ;
6354 return 0;
6355}
6356_ACEOF
6357rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006358if { (ac_try="$ac_compile"
6359case "(($ac_try" in
6360 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6361 *) ac_try_echo=$ac_try;;
6362esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006363eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6364$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006365 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00006366 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006367 grep -v '^ *+' conftest.er1 >conftest.err
6368 rm -f conftest.er1
6369 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006370 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006371 (exit $ac_status); } && {
6372 test -z "$ac_c_werror_flag" ||
6373 test ! -s conftest.err
6374 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006375 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00006376else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006377 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006378sed 's/^/| /' conftest.$ac_ext >&5
6379
Martin v. Löwiseba40652007-08-30 20:10:57 +00006380 eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006381fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006382
6383rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00006384fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006385ac_res=`eval 'as_val=${'$as_ac_Header'}
6386 $as_echo "$as_val"'`
6387 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
6388$as_echo "$ac_res" >&6; }
6389as_val=`eval 'as_val=${'$as_ac_Header'}
6390 $as_echo "$as_val"'`
6391 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006392 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006393#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +00006394_ACEOF
6395
6396ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00006397fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006398
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006399done
6400# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
6401if test $ac_header_dirent = dirent.h; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006402 { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5
6403$as_echo_n "checking for library containing opendir... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006404if test "${ac_cv_search_opendir+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006405 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006406else
Martin v. Löwis11437992002-04-12 09:54:03 +00006407 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +00006408cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006409/* confdefs.h. */
6410_ACEOF
6411cat confdefs.h >>conftest.$ac_ext
6412cat >>conftest.$ac_ext <<_ACEOF
6413/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006414
Martin v. Löwiseba40652007-08-30 20:10:57 +00006415/* Override any GCC internal prototype to avoid an error.
6416 Use char because int might match the return type of a GCC
6417 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006418#ifdef __cplusplus
6419extern "C"
6420#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00006421char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00006422int
6423main ()
6424{
Martin v. Löwiseba40652007-08-30 20:10:57 +00006425return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00006426 ;
6427 return 0;
6428}
6429_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006430for ac_lib in '' dir; do
6431 if test -z "$ac_lib"; then
6432 ac_res="none required"
6433 else
6434 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +00006435 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +00006436 fi
6437 rm -f conftest.$ac_objext conftest$ac_exeext
6438if { (ac_try="$ac_link"
6439case "(($ac_try" in
6440 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6441 *) ac_try_echo=$ac_try;;
6442esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006443eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6444$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006445 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +00006446 ac_status=$?
6447 grep -v '^ *+' conftest.er1 >conftest.err
6448 rm -f conftest.er1
6449 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006450 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006451 (exit $ac_status); } && {
6452 test -z "$ac_c_werror_flag" ||
6453 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006454 } && test -s conftest$ac_exeext && {
6455 test "$cross_compiling" = yes ||
6456 $as_test_x conftest$ac_exeext
6457 }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00006458 ac_cv_search_opendir=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +00006459else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006460 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +00006461sed 's/^/| /' conftest.$ac_ext >&5
6462
Martin v. Löwiseba40652007-08-30 20:10:57 +00006463
Brett Cannon19fab762007-06-02 03:02:29 +00006464fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006465
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006466rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00006467rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6468 conftest$ac_exeext
6469 if test "${ac_cv_search_opendir+set}" = set; then
6470 break
Skip Montanaro89e975f2007-08-22 19:05:21 +00006471fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006472done
6473if test "${ac_cv_search_opendir+set}" = set; then
6474 :
6475else
6476 ac_cv_search_opendir=no
6477fi
6478rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00006479LIBS=$ac_func_search_save_LIBS
6480fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006481{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
6482$as_echo "$ac_cv_search_opendir" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006483ac_res=$ac_cv_search_opendir
6484if test "$ac_res" != no; then
6485 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00006486
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006487fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006488
Michael W. Hudson54241132001-12-07 15:38:26 +00006489else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006490 { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5
6491$as_echo_n "checking for library containing opendir... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006492if test "${ac_cv_search_opendir+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006493 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00006494else
6495 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +00006496cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006497/* confdefs.h. */
6498_ACEOF
6499cat confdefs.h >>conftest.$ac_ext
6500cat >>conftest.$ac_ext <<_ACEOF
6501/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006502
Martin v. Löwiseba40652007-08-30 20:10:57 +00006503/* Override any GCC internal prototype to avoid an error.
6504 Use char because int might match the return type of a GCC
6505 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006506#ifdef __cplusplus
6507extern "C"
6508#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00006509char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00006510int
6511main ()
6512{
Martin v. Löwiseba40652007-08-30 20:10:57 +00006513return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00006514 ;
6515 return 0;
6516}
6517_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006518for ac_lib in '' x; do
6519 if test -z "$ac_lib"; then
6520 ac_res="none required"
6521 else
6522 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +00006523 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +00006524 fi
6525 rm -f conftest.$ac_objext conftest$ac_exeext
6526if { (ac_try="$ac_link"
6527case "(($ac_try" in
6528 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6529 *) ac_try_echo=$ac_try;;
6530esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006531eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6532$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006533 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +00006534 ac_status=$?
6535 grep -v '^ *+' conftest.er1 >conftest.err
6536 rm -f conftest.er1
6537 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006538 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006539 (exit $ac_status); } && {
6540 test -z "$ac_c_werror_flag" ||
6541 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006542 } && test -s conftest$ac_exeext && {
6543 test "$cross_compiling" = yes ||
6544 $as_test_x conftest$ac_exeext
6545 }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00006546 ac_cv_search_opendir=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +00006547else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006548 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +00006549sed 's/^/| /' conftest.$ac_ext >&5
6550
Martin v. Löwiseba40652007-08-30 20:10:57 +00006551
Brett Cannon19fab762007-06-02 03:02:29 +00006552fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006553
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006554rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00006555rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6556 conftest$ac_exeext
6557 if test "${ac_cv_search_opendir+set}" = set; then
6558 break
Skip Montanaro89e975f2007-08-22 19:05:21 +00006559fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006560done
6561if test "${ac_cv_search_opendir+set}" = set; then
6562 :
6563else
6564 ac_cv_search_opendir=no
6565fi
6566rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00006567LIBS=$ac_func_search_save_LIBS
6568fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006569{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
6570$as_echo "$ac_cv_search_opendir" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006571ac_res=$ac_cv_search_opendir
6572if test "$ac_res" != no; then
6573 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00006574
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006575fi
6576
6577fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00006578
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006579{ $as_echo "$as_me:$LINENO: checking whether sys/types.h defines makedev" >&5
6580$as_echo_n "checking whether sys/types.h defines makedev... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006581if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006582 $as_echo_n "(cached) " >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006583else
6584 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006585/* confdefs.h. */
6586_ACEOF
6587cat confdefs.h >>conftest.$ac_ext
6588cat >>conftest.$ac_ext <<_ACEOF
6589/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006590#include <sys/types.h>
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006591int
6592main ()
6593{
6594return makedev(0, 0);
6595 ;
6596 return 0;
6597}
6598_ACEOF
6599rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006600if { (ac_try="$ac_link"
6601case "(($ac_try" in
6602 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6603 *) ac_try_echo=$ac_try;;
6604esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006605eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6606$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006607 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006608 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006609 grep -v '^ *+' conftest.er1 >conftest.err
6610 rm -f conftest.er1
6611 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006612 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006613 (exit $ac_status); } && {
6614 test -z "$ac_c_werror_flag" ||
6615 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006616 } && test -s conftest$ac_exeext && {
6617 test "$cross_compiling" = yes ||
6618 $as_test_x conftest$ac_exeext
6619 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006620 ac_cv_header_sys_types_h_makedev=yes
6621else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006622 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006623sed 's/^/| /' conftest.$ac_ext >&5
6624
Martin v. Löwiseba40652007-08-30 20:10:57 +00006625 ac_cv_header_sys_types_h_makedev=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006626fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006627
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006628rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00006629rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00006630 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006631
6632fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006633{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_types_h_makedev" >&5
6634$as_echo "$ac_cv_header_sys_types_h_makedev" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006635
6636if test $ac_cv_header_sys_types_h_makedev = no; then
6637if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006638 { $as_echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
6639$as_echo_n "checking for sys/mkdev.h... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006640if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006641 $as_echo_n "(cached) " >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006642fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006643{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
6644$as_echo "$ac_cv_header_sys_mkdev_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006645else
6646 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006647{ $as_echo "$as_me:$LINENO: checking sys/mkdev.h usability" >&5
6648$as_echo_n "checking sys/mkdev.h usability... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006649cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006650/* confdefs.h. */
6651_ACEOF
6652cat confdefs.h >>conftest.$ac_ext
6653cat >>conftest.$ac_ext <<_ACEOF
6654/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006655$ac_includes_default
6656#include <sys/mkdev.h>
6657_ACEOF
6658rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006659if { (ac_try="$ac_compile"
6660case "(($ac_try" in
6661 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6662 *) ac_try_echo=$ac_try;;
6663esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006664eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6665$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006666 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006667 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006668 grep -v '^ *+' conftest.er1 >conftest.err
6669 rm -f conftest.er1
6670 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006671 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006672 (exit $ac_status); } && {
6673 test -z "$ac_c_werror_flag" ||
6674 test ! -s conftest.err
6675 } && test -s conftest.$ac_objext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006676 ac_header_compiler=yes
6677else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006678 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006679sed 's/^/| /' conftest.$ac_ext >&5
6680
Martin v. Löwiseba40652007-08-30 20:10:57 +00006681 ac_header_compiler=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006682fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006683
6684rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006685{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6686$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006687
6688# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006689{ $as_echo "$as_me:$LINENO: checking sys/mkdev.h presence" >&5
6690$as_echo_n "checking sys/mkdev.h presence... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006691cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006692/* confdefs.h. */
6693_ACEOF
6694cat confdefs.h >>conftest.$ac_ext
6695cat >>conftest.$ac_ext <<_ACEOF
6696/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006697#include <sys/mkdev.h>
6698_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006699if { (ac_try="$ac_cpp conftest.$ac_ext"
6700case "(($ac_try" in
6701 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6702 *) ac_try_echo=$ac_try;;
6703esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006704eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6705$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006706 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006707 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00006708 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006709 rm -f conftest.er1
6710 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006711 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006712 (exit $ac_status); } >/dev/null && {
6713 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6714 test ! -s conftest.err
6715 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006716 ac_header_preproc=yes
6717else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006718 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006719sed 's/^/| /' conftest.$ac_ext >&5
6720
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006721 ac_header_preproc=no
6722fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006723
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006724rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006725{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6726$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006727
6728# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006729case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6730 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006731 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&5
6732$as_echo "$as_me: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
6733 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the compiler's result" >&5
6734$as_echo "$as_me: WARNING: sys/mkdev.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00006735 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00006736 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00006737 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006738 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: present but cannot be compiled" >&5
6739$as_echo "$as_me: WARNING: sys/mkdev.h: present but cannot be compiled" >&2;}
6740 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&5
6741$as_echo "$as_me: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&2;}
6742 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: see the Autoconf documentation" >&5
6743$as_echo "$as_me: WARNING: sys/mkdev.h: see the Autoconf documentation" >&2;}
6744 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: section \"Present But Cannot Be Compiled\"" >&5
6745$as_echo "$as_me: WARNING: sys/mkdev.h: section \"Present But Cannot Be Compiled\"" >&2;}
6746 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
6747$as_echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;}
6748 { $as_echo "$as_me:$LINENO: WARNING: sys/mkdev.h: in the future, the compiler will take precedence" >&5
6749$as_echo "$as_me: WARNING: sys/mkdev.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00006750 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00006751## -------------------------------------- ##
6752## Report this to http://bugs.python.org/ ##
6753## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00006754_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00006755 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00006756 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006757esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006758{ $as_echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
6759$as_echo_n "checking for sys/mkdev.h... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006760if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006761 $as_echo_n "(cached) " >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006762else
6763 ac_cv_header_sys_mkdev_h=$ac_header_preproc
6764fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006765{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
6766$as_echo "$ac_cv_header_sys_mkdev_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006767
6768fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006769if test "x$ac_cv_header_sys_mkdev_h" = x""yes; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006770
6771cat >>confdefs.h <<\_ACEOF
6772#define MAJOR_IN_MKDEV 1
6773_ACEOF
6774
6775fi
6776
6777
6778
6779 if test $ac_cv_header_sys_mkdev_h = no; then
6780 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006781 { $as_echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
6782$as_echo_n "checking for sys/sysmacros.h... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006783if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006784 $as_echo_n "(cached) " >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006785fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006786{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
6787$as_echo "$ac_cv_header_sys_sysmacros_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006788else
6789 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006790{ $as_echo "$as_me:$LINENO: checking sys/sysmacros.h usability" >&5
6791$as_echo_n "checking sys/sysmacros.h usability... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006792cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006793/* confdefs.h. */
6794_ACEOF
6795cat confdefs.h >>conftest.$ac_ext
6796cat >>conftest.$ac_ext <<_ACEOF
6797/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006798$ac_includes_default
6799#include <sys/sysmacros.h>
6800_ACEOF
6801rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006802if { (ac_try="$ac_compile"
6803case "(($ac_try" in
6804 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6805 *) ac_try_echo=$ac_try;;
6806esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006807eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6808$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006809 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006810 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006811 grep -v '^ *+' conftest.er1 >conftest.err
6812 rm -f conftest.er1
6813 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006814 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006815 (exit $ac_status); } && {
6816 test -z "$ac_c_werror_flag" ||
6817 test ! -s conftest.err
6818 } && test -s conftest.$ac_objext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006819 ac_header_compiler=yes
6820else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006821 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006822sed 's/^/| /' conftest.$ac_ext >&5
6823
Martin v. Löwiseba40652007-08-30 20:10:57 +00006824 ac_header_compiler=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006825fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006826
6827rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006828{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6829$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006830
6831# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006832{ $as_echo "$as_me:$LINENO: checking sys/sysmacros.h presence" >&5
6833$as_echo_n "checking sys/sysmacros.h presence... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006834cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006835/* confdefs.h. */
6836_ACEOF
6837cat confdefs.h >>conftest.$ac_ext
6838cat >>conftest.$ac_ext <<_ACEOF
6839/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006840#include <sys/sysmacros.h>
6841_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006842if { (ac_try="$ac_cpp conftest.$ac_ext"
6843case "(($ac_try" in
6844 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6845 *) ac_try_echo=$ac_try;;
6846esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006847eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6848$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006849 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006850 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00006851 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006852 rm -f conftest.er1
6853 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006854 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006855 (exit $ac_status); } >/dev/null && {
6856 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6857 test ! -s conftest.err
6858 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006859 ac_header_preproc=yes
6860else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006861 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006862sed 's/^/| /' conftest.$ac_ext >&5
6863
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006864 ac_header_preproc=no
6865fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006866
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006867rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006868{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6869$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006870
6871# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006872case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6873 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006874 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&5
6875$as_echo "$as_me: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
6876 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the compiler's result" >&5
6877$as_echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00006878 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00006879 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00006880 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006881 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: present but cannot be compiled" >&5
6882$as_echo "$as_me: WARNING: sys/sysmacros.h: present but cannot be compiled" >&2;}
6883 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&5
6884$as_echo "$as_me: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&2;}
6885 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: see the Autoconf documentation" >&5
6886$as_echo "$as_me: WARNING: sys/sysmacros.h: see the Autoconf documentation" >&2;}
6887 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: section \"Present But Cannot Be Compiled\"" >&5
6888$as_echo "$as_me: WARNING: sys/sysmacros.h: section \"Present But Cannot Be Compiled\"" >&2;}
6889 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
6890$as_echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;}
6891 { $as_echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: in the future, the compiler will take precedence" >&5
6892$as_echo "$as_me: WARNING: sys/sysmacros.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00006893 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00006894## -------------------------------------- ##
6895## Report this to http://bugs.python.org/ ##
6896## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00006897_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00006898 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00006899 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006900esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006901{ $as_echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
6902$as_echo_n "checking for sys/sysmacros.h... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006903if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006904 $as_echo_n "(cached) " >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006905else
6906 ac_cv_header_sys_sysmacros_h=$ac_header_preproc
6907fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006908{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
6909$as_echo "$ac_cv_header_sys_sysmacros_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006910
6911fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006912if test "x$ac_cv_header_sys_sysmacros_h" = x""yes; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006913
6914cat >>confdefs.h <<\_ACEOF
6915#define MAJOR_IN_SYSMACROS 1
6916_ACEOF
6917
6918fi
6919
6920
6921 fi
6922fi
6923
Michael W. Hudson54241132001-12-07 15:38:26 +00006924
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006925# On Solaris, term.h requires curses.h
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006926
6927for ac_header in term.h
6928do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006929as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6930{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6931$as_echo_n "checking for $ac_header... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006932if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006933 $as_echo_n "(cached) " >&6
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006934else
6935 cat >conftest.$ac_ext <<_ACEOF
6936/* confdefs.h. */
6937_ACEOF
6938cat confdefs.h >>conftest.$ac_ext
6939cat >>conftest.$ac_ext <<_ACEOF
6940/* end confdefs.h. */
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006941
Martin v. Löwis5d52e782004-09-18 10:07:03 +00006942#ifdef HAVE_CURSES_H
6943#include <curses.h>
6944#endif
6945
6946
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006947#include <$ac_header>
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006948_ACEOF
6949rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006950if { (ac_try="$ac_compile"
6951case "(($ac_try" in
6952 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6953 *) ac_try_echo=$ac_try;;
6954esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006955eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6956$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006957 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006958 ac_status=$?
6959 grep -v '^ *+' conftest.er1 >conftest.err
6960 rm -f conftest.er1
6961 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006962 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006963 (exit $ac_status); } && {
6964 test -z "$ac_c_werror_flag" ||
6965 test ! -s conftest.err
6966 } && test -s conftest.$ac_objext; then
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006967 eval "$as_ac_Header=yes"
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006968else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006969 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006970sed 's/^/| /' conftest.$ac_ext >&5
6971
Martin v. Löwiseba40652007-08-30 20:10:57 +00006972 eval "$as_ac_Header=no"
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006973fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006974
6975rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006976fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006977ac_res=`eval 'as_val=${'$as_ac_Header'}
6978 $as_echo "$as_val"'`
6979 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
6980$as_echo "$ac_res" >&6; }
6981as_val=`eval 'as_val=${'$as_ac_Header'}
6982 $as_echo "$as_val"'`
6983 if test "x$as_val" = x""yes; then
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006984 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006985#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006986_ACEOF
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006987
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006988fi
6989
6990done
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006991
6992
Martin v. Löwis11017b12006-01-14 18:12:57 +00006993# On Linux, netlink.h requires asm/types.h
6994
6995for ac_header in linux/netlink.h
6996do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006997as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6998{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
6999$as_echo_n "checking for $ac_header... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00007000if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007001 $as_echo_n "(cached) " >&6
Martin v. Löwis11017b12006-01-14 18:12:57 +00007002else
7003 cat >conftest.$ac_ext <<_ACEOF
7004/* confdefs.h. */
7005_ACEOF
7006cat confdefs.h >>conftest.$ac_ext
7007cat >>conftest.$ac_ext <<_ACEOF
7008/* end confdefs.h. */
7009
7010#ifdef HAVE_ASM_TYPES_H
7011#include <asm/types.h>
7012#endif
7013#ifdef HAVE_SYS_SOCKET_H
7014#include <sys/socket.h>
7015#endif
7016
7017
7018#include <$ac_header>
7019_ACEOF
7020rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007021if { (ac_try="$ac_compile"
7022case "(($ac_try" in
7023 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7024 *) ac_try_echo=$ac_try;;
7025esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007026eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7027$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007028 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11017b12006-01-14 18:12:57 +00007029 ac_status=$?
7030 grep -v '^ *+' conftest.er1 >conftest.err
7031 rm -f conftest.er1
7032 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007033 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007034 (exit $ac_status); } && {
7035 test -z "$ac_c_werror_flag" ||
7036 test ! -s conftest.err
7037 } && test -s conftest.$ac_objext; then
Martin v. Löwis11017b12006-01-14 18:12:57 +00007038 eval "$as_ac_Header=yes"
7039else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007040 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis11017b12006-01-14 18:12:57 +00007041sed 's/^/| /' conftest.$ac_ext >&5
7042
Martin v. Löwiseba40652007-08-30 20:10:57 +00007043 eval "$as_ac_Header=no"
Martin v. Löwis11017b12006-01-14 18:12:57 +00007044fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007045
7046rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11017b12006-01-14 18:12:57 +00007047fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007048ac_res=`eval 'as_val=${'$as_ac_Header'}
7049 $as_echo "$as_val"'`
7050 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
7051$as_echo "$ac_res" >&6; }
7052as_val=`eval 'as_val=${'$as_ac_Header'}
7053 $as_echo "$as_val"'`
7054 if test "x$as_val" = x""yes; then
Martin v. Löwis11017b12006-01-14 18:12:57 +00007055 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007056#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwis11017b12006-01-14 18:12:57 +00007057_ACEOF
7058
7059fi
7060
7061done
7062
7063
Guido van Rossum627b2d71993-12-24 10:39:16 +00007064# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00007065was_it_defined=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007066{ $as_echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
7067$as_echo_n "checking for clock_t in time.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007068cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007069/* confdefs.h. */
7070_ACEOF
7071cat confdefs.h >>conftest.$ac_ext
7072cat >>conftest.$ac_ext <<_ACEOF
7073/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007074#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007075
7076_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007077if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00007078 $EGREP "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00007079 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00007080else
Martin v. Löwis11437992002-04-12 09:54:03 +00007081
7082
7083cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007084#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00007085_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00007086
Martin v. Löwisc45929e2002-04-06 10:10:49 +00007087
Guido van Rossum627b2d71993-12-24 10:39:16 +00007088fi
7089rm -f conftest*
7090
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007091{ $as_echo "$as_me:$LINENO: result: $was_it_defined" >&5
7092$as_echo "$was_it_defined" >&6; }
Guido van Rossumda88dad1995-01-26 00:46:29 +00007093
Neal Norwitz11690112002-07-30 01:08:28 +00007094# Check whether using makedev requires defining _OSF_SOURCE
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007095{ $as_echo "$as_me:$LINENO: checking for makedev" >&5
7096$as_echo_n "checking for makedev... " >&6; }
Neal Norwitz11690112002-07-30 01:08:28 +00007097cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007098/* confdefs.h. */
7099_ACEOF
7100cat confdefs.h >>conftest.$ac_ext
7101cat >>conftest.$ac_ext <<_ACEOF
7102/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +00007103#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00007104int
7105main ()
7106{
7107 makedev(0, 0)
7108 ;
7109 return 0;
7110}
7111_ACEOF
7112rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007113if { (ac_try="$ac_link"
7114case "(($ac_try" in
7115 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7116 *) ac_try_echo=$ac_try;;
7117esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007118eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7119$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007120 (eval "$ac_link") 2>conftest.er1
Neal Norwitz11690112002-07-30 01:08:28 +00007121 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007122 grep -v '^ *+' conftest.er1 >conftest.err
7123 rm -f conftest.er1
7124 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007125 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007126 (exit $ac_status); } && {
7127 test -z "$ac_c_werror_flag" ||
7128 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007129 } && test -s conftest$ac_exeext && {
7130 test "$cross_compiling" = yes ||
7131 $as_test_x conftest$ac_exeext
7132 }; then
Neal Norwitz11690112002-07-30 01:08:28 +00007133 ac_cv_has_makedev=yes
7134else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007135 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007136sed 's/^/| /' conftest.$ac_ext >&5
7137
Martin v. Löwiseba40652007-08-30 20:10:57 +00007138 ac_cv_has_makedev=no
Neal Norwitz11690112002-07-30 01:08:28 +00007139fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007140
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007141rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00007142rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00007143 conftest$ac_exeext conftest.$ac_ext
Neal Norwitz11690112002-07-30 01:08:28 +00007144if test "$ac_cv_has_makedev" = "no"; then
7145 # we didn't link, try if _OSF_SOURCE will allow us to link
7146 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007147/* confdefs.h. */
7148_ACEOF
7149cat confdefs.h >>conftest.$ac_ext
7150cat >>conftest.$ac_ext <<_ACEOF
7151/* end confdefs.h. */
Neal Norwitz11690112002-07-30 01:08:28 +00007152
Neal Norwitz6eb37f02003-02-23 23:28:15 +00007153#define _OSF_SOURCE 1
7154#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00007155
Neal Norwitz11690112002-07-30 01:08:28 +00007156int
7157main ()
7158{
7159 makedev(0, 0)
7160 ;
7161 return 0;
7162}
7163_ACEOF
7164rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007165if { (ac_try="$ac_link"
7166case "(($ac_try" in
7167 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7168 *) ac_try_echo=$ac_try;;
7169esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007170eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7171$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007172 (eval "$ac_link") 2>conftest.er1
Neal Norwitz11690112002-07-30 01:08:28 +00007173 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007174 grep -v '^ *+' conftest.er1 >conftest.err
7175 rm -f conftest.er1
7176 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007177 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007178 (exit $ac_status); } && {
7179 test -z "$ac_c_werror_flag" ||
7180 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007181 } && test -s conftest$ac_exeext && {
7182 test "$cross_compiling" = yes ||
7183 $as_test_x conftest$ac_exeext
7184 }; then
Neal Norwitz11690112002-07-30 01:08:28 +00007185 ac_cv_has_makedev=yes
7186else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007187 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007188sed 's/^/| /' conftest.$ac_ext >&5
7189
Martin v. Löwiseba40652007-08-30 20:10:57 +00007190 ac_cv_has_makedev=no
Neal Norwitz11690112002-07-30 01:08:28 +00007191fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007192
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007193rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00007194rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00007195 conftest$ac_exeext conftest.$ac_ext
Neal Norwitz11690112002-07-30 01:08:28 +00007196 if test "$ac_cv_has_makedev" = "yes"; then
7197
7198cat >>confdefs.h <<\_ACEOF
7199#define _OSF_SOURCE 1
7200_ACEOF
7201
7202 fi
7203fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007204{ $as_echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
7205$as_echo "$ac_cv_has_makedev" >&6; }
Neal Norwitz11690112002-07-30 01:08:28 +00007206if test "$ac_cv_has_makedev" = "yes"; then
7207
7208cat >>confdefs.h <<\_ACEOF
7209#define HAVE_MAKEDEV 1
7210_ACEOF
7211
7212fi
7213
Martin v. Löwis399a6892002-10-04 10:22:02 +00007214# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
7215# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
7216# defined, but the compiler does not support pragma redefine_extname,
7217# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
7218# structures (such as rlimit64) without declaring them. As a
7219# work-around, disable LFS on such configurations
7220
7221use_lfs=yes
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007222{ $as_echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
7223$as_echo_n "checking Solaris LFS bug... " >&6; }
Martin v. Löwis399a6892002-10-04 10:22:02 +00007224cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007225/* confdefs.h. */
7226_ACEOF
7227cat confdefs.h >>conftest.$ac_ext
7228cat >>conftest.$ac_ext <<_ACEOF
7229/* end confdefs.h. */
Martin v. Löwis399a6892002-10-04 10:22:02 +00007230
7231#define _LARGEFILE_SOURCE 1
7232#define _FILE_OFFSET_BITS 64
7233#include <sys/resource.h>
7234
Martin v. Löwis399a6892002-10-04 10:22:02 +00007235int
7236main ()
7237{
7238struct rlimit foo;
7239 ;
7240 return 0;
7241}
7242_ACEOF
7243rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007244if { (ac_try="$ac_compile"
7245case "(($ac_try" in
7246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7247 *) ac_try_echo=$ac_try;;
7248esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007249eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7250$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007251 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis399a6892002-10-04 10:22:02 +00007252 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007253 grep -v '^ *+' conftest.er1 >conftest.err
7254 rm -f conftest.er1
7255 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007256 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007257 (exit $ac_status); } && {
7258 test -z "$ac_c_werror_flag" ||
7259 test ! -s conftest.err
7260 } && test -s conftest.$ac_objext; then
Martin v. Löwis399a6892002-10-04 10:22:02 +00007261 sol_lfs_bug=no
7262else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007263 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007264sed 's/^/| /' conftest.$ac_ext >&5
7265
Martin v. Löwiseba40652007-08-30 20:10:57 +00007266 sol_lfs_bug=yes
Martin v. Löwis399a6892002-10-04 10:22:02 +00007267fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007268
7269rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007270{ $as_echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
7271$as_echo "$sol_lfs_bug" >&6; }
Martin v. Löwis399a6892002-10-04 10:22:02 +00007272if test "$sol_lfs_bug" = "yes"; then
7273 use_lfs=no
7274fi
7275
7276if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00007277# Two defines needed to enable largefile support on various platforms
7278# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00007279
Martin v. Löwis11437992002-04-12 09:54:03 +00007280cat >>confdefs.h <<\_ACEOF
7281#define _LARGEFILE_SOURCE 1
7282_ACEOF
7283
7284
7285cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00007286#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00007287_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00007288
Martin v. Löwis399a6892002-10-04 10:22:02 +00007289fi
Michael W. Hudson54241132001-12-07 15:38:26 +00007290
Guido van Rossum84e7b241996-08-19 21:59:00 +00007291# Add some code to confdefs.h so that the test for off_t works on SCO
7292cat >> confdefs.h <<\EOF
7293#if defined(SCO_DS)
7294#undef _OFF_T
7295#endif
7296EOF
7297
Guido van Rossumef2255b2000-03-10 22:30:29 +00007298# Type availability checks
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007299{ $as_echo "$as_me:$LINENO: checking for mode_t" >&5
7300$as_echo_n "checking for mode_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007301if test "${ac_cv_type_mode_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007302 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007303else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007304 ac_cv_type_mode_t=no
7305cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007306/* confdefs.h. */
7307_ACEOF
7308cat confdefs.h >>conftest.$ac_ext
7309cat >>conftest.$ac_ext <<_ACEOF
7310/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007311$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007312int
7313main ()
7314{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007315if (sizeof (mode_t))
7316 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007317 ;
7318 return 0;
7319}
7320_ACEOF
7321rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007322if { (ac_try="$ac_compile"
7323case "(($ac_try" in
7324 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7325 *) ac_try_echo=$ac_try;;
7326esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007327eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7328$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007329 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007330 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007331 grep -v '^ *+' conftest.er1 >conftest.err
7332 rm -f conftest.er1
7333 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007334 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007335 (exit $ac_status); } && {
7336 test -z "$ac_c_werror_flag" ||
7337 test ! -s conftest.err
7338 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007339 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{
7349if (sizeof ((mode_t)))
7350 return 0;
7351 ;
7352 return 0;
7353}
7354_ACEOF
7355rm -f conftest.$ac_objext
7356if { (ac_try="$ac_compile"
7357case "(($ac_try" in
7358 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7359 *) ac_try_echo=$ac_try;;
7360esac
7361eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7362$as_echo "$ac_try_echo") >&5
7363 (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
7368 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7369 (exit $ac_status); } && {
7370 test -z "$ac_c_werror_flag" ||
7371 test ! -s conftest.err
7372 } && test -s conftest.$ac_objext; then
7373 :
Jack Jansendd19cf82001-12-06 22:36:17 +00007374else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007375 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007376sed 's/^/| /' conftest.$ac_ext >&5
7377
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007378 ac_cv_type_mode_t=yes
7379fi
7380
7381rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7382else
7383 $as_echo "$as_me: failed program was:" >&5
7384sed 's/^/| /' conftest.$ac_ext >&5
7385
7386
Jack Jansendd19cf82001-12-06 22:36:17 +00007387fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007388
7389rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00007390fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007391{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
7392$as_echo "$ac_cv_type_mode_t" >&6; }
7393if test "x$ac_cv_type_mode_t" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007394 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007395else
Martin v. Löwis11437992002-04-12 09:54:03 +00007396
7397cat >>confdefs.h <<_ACEOF
7398#define mode_t int
7399_ACEOF
7400
7401fi
7402
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007403{ $as_echo "$as_me:$LINENO: checking for off_t" >&5
7404$as_echo_n "checking for off_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007405if test "${ac_cv_type_off_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007406 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007407else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007408 ac_cv_type_off_t=no
7409cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007410/* confdefs.h. */
7411_ACEOF
7412cat confdefs.h >>conftest.$ac_ext
7413cat >>conftest.$ac_ext <<_ACEOF
7414/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007415$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007416int
7417main ()
7418{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007419if (sizeof (off_t))
7420 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007421 ;
7422 return 0;
7423}
7424_ACEOF
7425rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007426if { (ac_try="$ac_compile"
7427case "(($ac_try" in
7428 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7429 *) ac_try_echo=$ac_try;;
7430esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007431eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7432$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007433 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007434 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007435 grep -v '^ *+' conftest.er1 >conftest.err
7436 rm -f conftest.er1
7437 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007438 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007439 (exit $ac_status); } && {
7440 test -z "$ac_c_werror_flag" ||
7441 test ! -s conftest.err
7442 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007443 cat >conftest.$ac_ext <<_ACEOF
7444/* confdefs.h. */
7445_ACEOF
7446cat confdefs.h >>conftest.$ac_ext
7447cat >>conftest.$ac_ext <<_ACEOF
7448/* end confdefs.h. */
7449$ac_includes_default
7450int
7451main ()
7452{
7453if (sizeof ((off_t)))
7454 return 0;
7455 ;
7456 return 0;
7457}
7458_ACEOF
7459rm -f conftest.$ac_objext
7460if { (ac_try="$ac_compile"
7461case "(($ac_try" in
7462 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7463 *) ac_try_echo=$ac_try;;
7464esac
7465eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7466$as_echo "$ac_try_echo") >&5
7467 (eval "$ac_compile") 2>conftest.er1
7468 ac_status=$?
7469 grep -v '^ *+' conftest.er1 >conftest.err
7470 rm -f conftest.er1
7471 cat conftest.err >&5
7472 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7473 (exit $ac_status); } && {
7474 test -z "$ac_c_werror_flag" ||
7475 test ! -s conftest.err
7476 } && test -s conftest.$ac_objext; then
7477 :
Guido van Rossum627b2d71993-12-24 10:39:16 +00007478else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007479 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007480sed 's/^/| /' conftest.$ac_ext >&5
7481
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007482 ac_cv_type_off_t=yes
7483fi
7484
7485rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7486else
7487 $as_echo "$as_me: failed program was:" >&5
7488sed 's/^/| /' conftest.$ac_ext >&5
7489
7490
Guido van Rossum627b2d71993-12-24 10:39:16 +00007491fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007492
7493rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00007494fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007495{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
7496$as_echo "$ac_cv_type_off_t" >&6; }
7497if test "x$ac_cv_type_off_t" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007498 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007499else
Martin v. Löwis11437992002-04-12 09:54:03 +00007500
7501cat >>confdefs.h <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00007502#define off_t long int
Martin v. Löwis11437992002-04-12 09:54:03 +00007503_ACEOF
7504
7505fi
7506
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007507{ $as_echo "$as_me:$LINENO: checking for pid_t" >&5
7508$as_echo_n "checking for pid_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007509if test "${ac_cv_type_pid_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007510 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007511else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007512 ac_cv_type_pid_t=no
7513cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007514/* confdefs.h. */
7515_ACEOF
7516cat confdefs.h >>conftest.$ac_ext
7517cat >>conftest.$ac_ext <<_ACEOF
7518/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007519$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007520int
7521main ()
7522{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007523if (sizeof (pid_t))
7524 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007525 ;
7526 return 0;
7527}
7528_ACEOF
7529rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007530if { (ac_try="$ac_compile"
7531case "(($ac_try" in
7532 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7533 *) ac_try_echo=$ac_try;;
7534esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007535eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7536$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007537 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007538 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007539 grep -v '^ *+' conftest.er1 >conftest.err
7540 rm -f conftest.er1
7541 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007542 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007543 (exit $ac_status); } && {
7544 test -z "$ac_c_werror_flag" ||
7545 test ! -s conftest.err
7546 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007547 cat >conftest.$ac_ext <<_ACEOF
7548/* confdefs.h. */
7549_ACEOF
7550cat confdefs.h >>conftest.$ac_ext
7551cat >>conftest.$ac_ext <<_ACEOF
7552/* end confdefs.h. */
7553$ac_includes_default
7554int
7555main ()
7556{
7557if (sizeof ((pid_t)))
7558 return 0;
7559 ;
7560 return 0;
7561}
7562_ACEOF
7563rm -f conftest.$ac_objext
7564if { (ac_try="$ac_compile"
7565case "(($ac_try" in
7566 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7567 *) ac_try_echo=$ac_try;;
7568esac
7569eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7570$as_echo "$ac_try_echo") >&5
7571 (eval "$ac_compile") 2>conftest.er1
7572 ac_status=$?
7573 grep -v '^ *+' conftest.er1 >conftest.err
7574 rm -f conftest.er1
7575 cat conftest.err >&5
7576 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7577 (exit $ac_status); } && {
7578 test -z "$ac_c_werror_flag" ||
7579 test ! -s conftest.err
7580 } && test -s conftest.$ac_objext; then
7581 :
Guido van Rossum627b2d71993-12-24 10:39:16 +00007582else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007583 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007584sed 's/^/| /' conftest.$ac_ext >&5
7585
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007586 ac_cv_type_pid_t=yes
7587fi
7588
7589rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7590else
7591 $as_echo "$as_me: failed program was:" >&5
7592sed 's/^/| /' conftest.$ac_ext >&5
7593
7594
Guido van Rossum627b2d71993-12-24 10:39:16 +00007595fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007596
7597rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00007598fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007599{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
7600$as_echo "$ac_cv_type_pid_t" >&6; }
7601if test "x$ac_cv_type_pid_t" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007602 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007603else
Martin v. Löwis11437992002-04-12 09:54:03 +00007604
7605cat >>confdefs.h <<_ACEOF
7606#define pid_t int
7607_ACEOF
7608
7609fi
7610
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007611{ $as_echo "$as_me:$LINENO: checking return type of signal handlers" >&5
7612$as_echo_n "checking return type of signal handlers... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007613if test "${ac_cv_type_signal+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007614 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007615else
7616 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007617/* confdefs.h. */
7618_ACEOF
7619cat confdefs.h >>conftest.$ac_ext
7620cat >>conftest.$ac_ext <<_ACEOF
7621/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00007622#include <sys/types.h>
7623#include <signal.h>
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00007624
Martin v. Löwis11437992002-04-12 09:54:03 +00007625int
7626main ()
7627{
Martin v. Löwiseba40652007-08-30 20:10:57 +00007628return *(signal (0, 0)) (0) == 1;
Martin v. Löwis11437992002-04-12 09:54:03 +00007629 ;
7630 return 0;
7631}
7632_ACEOF
7633rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007634if { (ac_try="$ac_compile"
7635case "(($ac_try" in
7636 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7637 *) ac_try_echo=$ac_try;;
7638esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007639eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7640$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007641 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007642 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007643 grep -v '^ *+' conftest.er1 >conftest.err
7644 rm -f conftest.er1
7645 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007646 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007647 (exit $ac_status); } && {
7648 test -z "$ac_c_werror_flag" ||
7649 test ! -s conftest.err
7650 } && test -s conftest.$ac_objext; then
7651 ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00007652else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007653 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007654sed 's/^/| /' conftest.$ac_ext >&5
7655
Martin v. Löwiseba40652007-08-30 20:10:57 +00007656 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00007657fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007658
7659rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007660fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007661{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
7662$as_echo "$ac_cv_type_signal" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00007663
Martin v. Löwis11437992002-04-12 09:54:03 +00007664cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007665#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00007666_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00007667
Michael W. Hudson54241132001-12-07 15:38:26 +00007668
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007669{ $as_echo "$as_me:$LINENO: checking for size_t" >&5
7670$as_echo_n "checking for size_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007671if test "${ac_cv_type_size_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007672 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007673else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007674 ac_cv_type_size_t=no
7675cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007676/* confdefs.h. */
7677_ACEOF
7678cat confdefs.h >>conftest.$ac_ext
7679cat >>conftest.$ac_ext <<_ACEOF
7680/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007681$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007682int
7683main ()
7684{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007685if (sizeof (size_t))
7686 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007687 ;
7688 return 0;
7689}
7690_ACEOF
7691rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007692if { (ac_try="$ac_compile"
7693case "(($ac_try" in
7694 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7695 *) ac_try_echo=$ac_try;;
7696esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007697eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7698$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007699 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007700 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007701 grep -v '^ *+' conftest.er1 >conftest.err
7702 rm -f conftest.er1
7703 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007704 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007705 (exit $ac_status); } && {
7706 test -z "$ac_c_werror_flag" ||
7707 test ! -s conftest.err
7708 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007709 cat >conftest.$ac_ext <<_ACEOF
7710/* confdefs.h. */
7711_ACEOF
7712cat confdefs.h >>conftest.$ac_ext
7713cat >>conftest.$ac_ext <<_ACEOF
7714/* end confdefs.h. */
7715$ac_includes_default
7716int
7717main ()
7718{
7719if (sizeof ((size_t)))
7720 return 0;
7721 ;
7722 return 0;
7723}
7724_ACEOF
7725rm -f conftest.$ac_objext
7726if { (ac_try="$ac_compile"
7727case "(($ac_try" in
7728 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7729 *) ac_try_echo=$ac_try;;
7730esac
7731eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7732$as_echo "$ac_try_echo") >&5
7733 (eval "$ac_compile") 2>conftest.er1
7734 ac_status=$?
7735 grep -v '^ *+' conftest.er1 >conftest.err
7736 rm -f conftest.er1
7737 cat conftest.err >&5
7738 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7739 (exit $ac_status); } && {
7740 test -z "$ac_c_werror_flag" ||
7741 test ! -s conftest.err
7742 } && test -s conftest.$ac_objext; then
7743 :
Guido van Rossum627b2d71993-12-24 10:39:16 +00007744else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007745 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007746sed 's/^/| /' conftest.$ac_ext >&5
7747
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007748 ac_cv_type_size_t=yes
7749fi
7750
7751rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7752else
7753 $as_echo "$as_me: failed program was:" >&5
7754sed 's/^/| /' conftest.$ac_ext >&5
7755
7756
Guido van Rossum627b2d71993-12-24 10:39:16 +00007757fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007758
7759rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00007760fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007761{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
7762$as_echo "$ac_cv_type_size_t" >&6; }
7763if test "x$ac_cv_type_size_t" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007764 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007765else
Martin v. Löwis11437992002-04-12 09:54:03 +00007766
7767cat >>confdefs.h <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00007768#define size_t unsigned int
Martin v. Löwis11437992002-04-12 09:54:03 +00007769_ACEOF
7770
7771fi
7772
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007773{ $as_echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
7774$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007775if test "${ac_cv_type_uid_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007776 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007777else
7778 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007779/* confdefs.h. */
7780_ACEOF
7781cat confdefs.h >>conftest.$ac_ext
7782cat >>conftest.$ac_ext <<_ACEOF
7783/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007784#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007785
7786_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007787if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00007788 $EGREP "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007789 ac_cv_type_uid_t=yes
7790else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007791 ac_cv_type_uid_t=no
7792fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00007793rm -f conftest*
7794
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007795fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007796{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
7797$as_echo "$ac_cv_type_uid_t" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00007798if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007799
Martin v. Löwis11437992002-04-12 09:54:03 +00007800cat >>confdefs.h <<\_ACEOF
7801#define uid_t int
7802_ACEOF
7803
7804
7805cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007806#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00007807_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007808
7809fi
7810
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007811
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007812 { $as_echo "$as_me:$LINENO: checking for uint32_t" >&5
7813$as_echo_n "checking for uint32_t... " >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007814if test "${ac_cv_c_uint32_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007815 $as_echo_n "(cached) " >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007816else
7817 ac_cv_c_uint32_t=no
7818 for ac_type in 'uint32_t' 'unsigned int' 'unsigned long int' \
7819 'unsigned long long int' 'unsigned short int' 'unsigned char'; do
7820 cat >conftest.$ac_ext <<_ACEOF
7821/* confdefs.h. */
7822_ACEOF
7823cat confdefs.h >>conftest.$ac_ext
7824cat >>conftest.$ac_ext <<_ACEOF
7825/* end confdefs.h. */
7826$ac_includes_default
7827int
7828main ()
7829{
7830static int test_array [1 - 2 * !(($ac_type) -1 >> (32 - 1) == 1)];
7831test_array [0] = 0
7832
7833 ;
7834 return 0;
7835}
7836_ACEOF
7837rm -f conftest.$ac_objext
7838if { (ac_try="$ac_compile"
7839case "(($ac_try" in
7840 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7841 *) ac_try_echo=$ac_try;;
7842esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007843eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7844$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007845 (eval "$ac_compile") 2>conftest.er1
7846 ac_status=$?
7847 grep -v '^ *+' conftest.er1 >conftest.err
7848 rm -f conftest.er1
7849 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007850 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007851 (exit $ac_status); } && {
7852 test -z "$ac_c_werror_flag" ||
7853 test ! -s conftest.err
7854 } && test -s conftest.$ac_objext; then
7855 case $ac_type in
7856 uint32_t) ac_cv_c_uint32_t=yes ;;
7857 *) ac_cv_c_uint32_t=$ac_type ;;
7858esac
7859
7860else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007861 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007862sed 's/^/| /' conftest.$ac_ext >&5
7863
7864
7865fi
7866
7867rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7868 test "$ac_cv_c_uint32_t" != no && break
7869 done
7870fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007871{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_uint32_t" >&5
7872$as_echo "$ac_cv_c_uint32_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007873 case $ac_cv_c_uint32_t in #(
7874 no|yes) ;; #(
7875 *)
7876
7877cat >>confdefs.h <<\_ACEOF
7878#define _UINT32_T 1
7879_ACEOF
7880
7881
7882cat >>confdefs.h <<_ACEOF
7883#define uint32_t $ac_cv_c_uint32_t
7884_ACEOF
7885;;
7886 esac
7887
7888
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007889 { $as_echo "$as_me:$LINENO: checking for uint64_t" >&5
7890$as_echo_n "checking for uint64_t... " >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007891if test "${ac_cv_c_uint64_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007892 $as_echo_n "(cached) " >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007893else
7894 ac_cv_c_uint64_t=no
7895 for ac_type in 'uint64_t' 'unsigned int' 'unsigned long int' \
7896 'unsigned long long int' 'unsigned short int' 'unsigned char'; do
7897 cat >conftest.$ac_ext <<_ACEOF
7898/* confdefs.h. */
7899_ACEOF
7900cat confdefs.h >>conftest.$ac_ext
7901cat >>conftest.$ac_ext <<_ACEOF
7902/* end confdefs.h. */
7903$ac_includes_default
7904int
7905main ()
7906{
7907static int test_array [1 - 2 * !(($ac_type) -1 >> (64 - 1) == 1)];
7908test_array [0] = 0
7909
7910 ;
7911 return 0;
7912}
7913_ACEOF
7914rm -f conftest.$ac_objext
7915if { (ac_try="$ac_compile"
7916case "(($ac_try" in
7917 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7918 *) ac_try_echo=$ac_try;;
7919esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007920eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7921$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007922 (eval "$ac_compile") 2>conftest.er1
7923 ac_status=$?
7924 grep -v '^ *+' conftest.er1 >conftest.err
7925 rm -f conftest.er1
7926 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007927 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007928 (exit $ac_status); } && {
7929 test -z "$ac_c_werror_flag" ||
7930 test ! -s conftest.err
7931 } && test -s conftest.$ac_objext; then
7932 case $ac_type in
7933 uint64_t) ac_cv_c_uint64_t=yes ;;
7934 *) ac_cv_c_uint64_t=$ac_type ;;
7935esac
7936
7937else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007938 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007939sed 's/^/| /' conftest.$ac_ext >&5
7940
7941
7942fi
7943
7944rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7945 test "$ac_cv_c_uint64_t" != no && break
7946 done
7947fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007948{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_uint64_t" >&5
7949$as_echo "$ac_cv_c_uint64_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007950 case $ac_cv_c_uint64_t in #(
7951 no|yes) ;; #(
7952 *)
7953
7954cat >>confdefs.h <<\_ACEOF
7955#define _UINT64_T 1
7956_ACEOF
7957
7958
7959cat >>confdefs.h <<_ACEOF
7960#define uint64_t $ac_cv_c_uint64_t
7961_ACEOF
7962;;
7963 esac
7964
7965
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007966 { $as_echo "$as_me:$LINENO: checking for int32_t" >&5
7967$as_echo_n "checking for int32_t... " >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007968if test "${ac_cv_c_int32_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007969 $as_echo_n "(cached) " >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007970else
7971 ac_cv_c_int32_t=no
7972 for ac_type in 'int32_t' 'int' 'long int' \
7973 'long long int' 'short int' 'signed char'; do
7974 cat >conftest.$ac_ext <<_ACEOF
7975/* confdefs.h. */
7976_ACEOF
7977cat confdefs.h >>conftest.$ac_ext
7978cat >>conftest.$ac_ext <<_ACEOF
7979/* end confdefs.h. */
7980$ac_includes_default
7981int
7982main ()
7983{
7984static int test_array [1 - 2 * !(0 < ($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 1))];
7985test_array [0] = 0
7986
7987 ;
7988 return 0;
7989}
7990_ACEOF
7991rm -f conftest.$ac_objext
7992if { (ac_try="$ac_compile"
7993case "(($ac_try" in
7994 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7995 *) ac_try_echo=$ac_try;;
7996esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007997eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7998$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007999 (eval "$ac_compile") 2>conftest.er1
8000 ac_status=$?
8001 grep -v '^ *+' conftest.er1 >conftest.err
8002 rm -f conftest.er1
8003 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008004 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008005 (exit $ac_status); } && {
8006 test -z "$ac_c_werror_flag" ||
8007 test ! -s conftest.err
8008 } && test -s conftest.$ac_objext; then
8009 cat >conftest.$ac_ext <<_ACEOF
8010/* confdefs.h. */
8011_ACEOF
8012cat confdefs.h >>conftest.$ac_ext
8013cat >>conftest.$ac_ext <<_ACEOF
8014/* end confdefs.h. */
8015$ac_includes_default
8016int
8017main ()
8018{
8019static int test_array [1 - 2 * !(($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 1)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008020 < ($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 2))];
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008021test_array [0] = 0
8022
8023 ;
8024 return 0;
8025}
8026_ACEOF
8027rm -f conftest.$ac_objext
8028if { (ac_try="$ac_compile"
8029case "(($ac_try" in
8030 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8031 *) ac_try_echo=$ac_try;;
8032esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008033eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8034$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008035 (eval "$ac_compile") 2>conftest.er1
8036 ac_status=$?
8037 grep -v '^ *+' conftest.er1 >conftest.err
8038 rm -f conftest.er1
8039 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008040 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008041 (exit $ac_status); } && {
8042 test -z "$ac_c_werror_flag" ||
8043 test ! -s conftest.err
8044 } && test -s conftest.$ac_objext; then
8045 :
8046else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008047 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008048sed 's/^/| /' conftest.$ac_ext >&5
8049
8050 case $ac_type in
8051 int32_t) ac_cv_c_int32_t=yes ;;
8052 *) ac_cv_c_int32_t=$ac_type ;;
8053esac
8054
8055fi
8056
8057rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8058else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008059 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008060sed 's/^/| /' conftest.$ac_ext >&5
8061
8062
8063fi
8064
8065rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8066 test "$ac_cv_c_int32_t" != no && break
8067 done
8068fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008069{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_int32_t" >&5
8070$as_echo "$ac_cv_c_int32_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008071 case $ac_cv_c_int32_t in #(
8072 no|yes) ;; #(
8073 *)
8074
8075cat >>confdefs.h <<_ACEOF
8076#define int32_t $ac_cv_c_int32_t
8077_ACEOF
8078;;
8079 esac
8080
8081
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008082 { $as_echo "$as_me:$LINENO: checking for int64_t" >&5
8083$as_echo_n "checking for int64_t... " >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008084if test "${ac_cv_c_int64_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008085 $as_echo_n "(cached) " >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008086else
8087 ac_cv_c_int64_t=no
8088 for ac_type in 'int64_t' 'int' 'long int' \
8089 'long long int' 'short int' 'signed char'; do
8090 cat >conftest.$ac_ext <<_ACEOF
8091/* confdefs.h. */
8092_ACEOF
8093cat confdefs.h >>conftest.$ac_ext
8094cat >>conftest.$ac_ext <<_ACEOF
8095/* end confdefs.h. */
8096$ac_includes_default
8097int
8098main ()
8099{
8100static int test_array [1 - 2 * !(0 < ($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 1))];
8101test_array [0] = 0
8102
8103 ;
8104 return 0;
8105}
8106_ACEOF
8107rm -f conftest.$ac_objext
8108if { (ac_try="$ac_compile"
8109case "(($ac_try" in
8110 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8111 *) ac_try_echo=$ac_try;;
8112esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008113eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8114$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008115 (eval "$ac_compile") 2>conftest.er1
8116 ac_status=$?
8117 grep -v '^ *+' conftest.er1 >conftest.err
8118 rm -f conftest.er1
8119 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008120 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008121 (exit $ac_status); } && {
8122 test -z "$ac_c_werror_flag" ||
8123 test ! -s conftest.err
8124 } && test -s conftest.$ac_objext; then
8125 cat >conftest.$ac_ext <<_ACEOF
8126/* confdefs.h. */
8127_ACEOF
8128cat confdefs.h >>conftest.$ac_ext
8129cat >>conftest.$ac_ext <<_ACEOF
8130/* end confdefs.h. */
8131$ac_includes_default
8132int
8133main ()
8134{
8135static int test_array [1 - 2 * !(($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 1)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008136 < ($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 2))];
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008137test_array [0] = 0
8138
8139 ;
8140 return 0;
8141}
8142_ACEOF
8143rm -f conftest.$ac_objext
8144if { (ac_try="$ac_compile"
8145case "(($ac_try" in
8146 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8147 *) ac_try_echo=$ac_try;;
8148esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008149eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8150$as_echo "$ac_try_echo") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008151 (eval "$ac_compile") 2>conftest.er1
8152 ac_status=$?
8153 grep -v '^ *+' conftest.er1 >conftest.err
8154 rm -f conftest.er1
8155 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008156 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008157 (exit $ac_status); } && {
8158 test -z "$ac_c_werror_flag" ||
8159 test ! -s conftest.err
8160 } && test -s conftest.$ac_objext; then
8161 :
8162else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008163 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008164sed 's/^/| /' conftest.$ac_ext >&5
8165
8166 case $ac_type in
8167 int64_t) ac_cv_c_int64_t=yes ;;
8168 *) ac_cv_c_int64_t=$ac_type ;;
8169esac
8170
8171fi
8172
8173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8174else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008175 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008176sed 's/^/| /' conftest.$ac_ext >&5
8177
8178
8179fi
8180
8181rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8182 test "$ac_cv_c_int64_t" != no && break
8183 done
8184fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008185{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_int64_t" >&5
8186$as_echo "$ac_cv_c_int64_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00008187 case $ac_cv_c_int64_t in #(
8188 no|yes) ;; #(
8189 *)
8190
8191cat >>confdefs.h <<_ACEOF
8192#define int64_t $ac_cv_c_int64_t
8193_ACEOF
8194;;
8195 esac
8196
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008197{ $as_echo "$as_me:$LINENO: checking for ssize_t" >&5
8198$as_echo_n "checking for ssize_t... " >&6; }
Martin v. Löwis18e16552006-02-15 17:27:45 +00008199if test "${ac_cv_type_ssize_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008200 $as_echo_n "(cached) " >&6
Martin v. Löwis18e16552006-02-15 17:27:45 +00008201else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008202 ac_cv_type_ssize_t=no
8203cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwis18e16552006-02-15 17:27:45 +00008204/* confdefs.h. */
8205_ACEOF
8206cat confdefs.h >>conftest.$ac_ext
8207cat >>conftest.$ac_ext <<_ACEOF
8208/* end confdefs.h. */
8209$ac_includes_default
8210int
8211main ()
8212{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008213if (sizeof (ssize_t))
8214 return 0;
Martin v. Löwis18e16552006-02-15 17:27:45 +00008215 ;
8216 return 0;
8217}
8218_ACEOF
8219rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008220if { (ac_try="$ac_compile"
8221case "(($ac_try" in
8222 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8223 *) ac_try_echo=$ac_try;;
8224esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008225eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8226$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008227 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +00008228 ac_status=$?
8229 grep -v '^ *+' conftest.er1 >conftest.err
8230 rm -f conftest.er1
8231 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008232 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008233 (exit $ac_status); } && {
8234 test -z "$ac_c_werror_flag" ||
8235 test ! -s conftest.err
8236 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008237 cat >conftest.$ac_ext <<_ACEOF
8238/* confdefs.h. */
8239_ACEOF
8240cat confdefs.h >>conftest.$ac_ext
8241cat >>conftest.$ac_ext <<_ACEOF
8242/* end confdefs.h. */
8243$ac_includes_default
8244int
8245main ()
8246{
8247if (sizeof ((ssize_t)))
8248 return 0;
8249 ;
8250 return 0;
8251}
8252_ACEOF
8253rm -f conftest.$ac_objext
8254if { (ac_try="$ac_compile"
8255case "(($ac_try" in
8256 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8257 *) ac_try_echo=$ac_try;;
8258esac
8259eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8260$as_echo "$ac_try_echo") >&5
8261 (eval "$ac_compile") 2>conftest.er1
8262 ac_status=$?
8263 grep -v '^ *+' conftest.er1 >conftest.err
8264 rm -f conftest.er1
8265 cat conftest.err >&5
8266 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8267 (exit $ac_status); } && {
8268 test -z "$ac_c_werror_flag" ||
8269 test ! -s conftest.err
8270 } && test -s conftest.$ac_objext; then
8271 :
Martin v. Löwis18e16552006-02-15 17:27:45 +00008272else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008273 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +00008274sed 's/^/| /' conftest.$ac_ext >&5
8275
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008276 ac_cv_type_ssize_t=yes
8277fi
8278
8279rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8280else
8281 $as_echo "$as_me: failed program was:" >&5
8282sed 's/^/| /' conftest.$ac_ext >&5
8283
8284
Martin v. Löwis18e16552006-02-15 17:27:45 +00008285fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008286
8287rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +00008288fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008289{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
8290$as_echo "$ac_cv_type_ssize_t" >&6; }
8291if test "x$ac_cv_type_ssize_t" = x""yes; then
Martin v. Löwis18e16552006-02-15 17:27:45 +00008292
8293cat >>confdefs.h <<\_ACEOF
8294#define HAVE_SSIZE_T 1
8295_ACEOF
8296
8297fi
8298
Jack Jansendd19cf82001-12-06 22:36:17 +00008299
Michael W. Hudson54241132001-12-07 15:38:26 +00008300# Sizes of various common basic types
Skip Montanarob9820a32004-01-17 00:16:12 +00008301# ANSI C requires sizeof(char) == 1, so no need to check it
Martin v. Löwiseba40652007-08-30 20:10:57 +00008302# The cast to long int works around a bug in the HP C Compiler
8303# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8304# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8305# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008306{ $as_echo "$as_me:$LINENO: checking size of int" >&5
8307$as_echo_n "checking size of int... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00008308if test "${ac_cv_sizeof_int+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008309 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00008310else
Martin v. Löwis11437992002-04-12 09:54:03 +00008311 if test "$cross_compiling" = yes; then
8312 # Depending upon the size, compute the lo and hi bounds.
8313cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008314/* confdefs.h. */
8315_ACEOF
8316cat confdefs.h >>conftest.$ac_ext
8317cat >>conftest.$ac_ext <<_ACEOF
8318/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008319$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008320int
8321main ()
8322{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008323static int test_array [1 - 2 * !(((long int) (sizeof (int))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008324test_array [0] = 0
8325
8326 ;
8327 return 0;
8328}
8329_ACEOF
8330rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008331if { (ac_try="$ac_compile"
8332case "(($ac_try" in
8333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8334 *) ac_try_echo=$ac_try;;
8335esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008336eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8337$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008338 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008339 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008340 grep -v '^ *+' conftest.er1 >conftest.err
8341 rm -f conftest.er1
8342 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008343 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008344 (exit $ac_status); } && {
8345 test -z "$ac_c_werror_flag" ||
8346 test ! -s conftest.err
8347 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008348 ac_lo=0 ac_mid=0
8349 while :; do
8350 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008351/* confdefs.h. */
8352_ACEOF
8353cat confdefs.h >>conftest.$ac_ext
8354cat >>conftest.$ac_ext <<_ACEOF
8355/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008356$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008357int
8358main ()
8359{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008360static int test_array [1 - 2 * !(((long int) (sizeof (int))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008361test_array [0] = 0
8362
8363 ;
8364 return 0;
8365}
8366_ACEOF
8367rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008368if { (ac_try="$ac_compile"
8369case "(($ac_try" in
8370 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8371 *) ac_try_echo=$ac_try;;
8372esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008373eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8374$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008375 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008376 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008377 grep -v '^ *+' conftest.er1 >conftest.err
8378 rm -f conftest.er1
8379 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008380 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008381 (exit $ac_status); } && {
8382 test -z "$ac_c_werror_flag" ||
8383 test ! -s conftest.err
8384 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008385 ac_hi=$ac_mid; break
8386else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008387 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008388sed 's/^/| /' conftest.$ac_ext >&5
8389
Martin v. Löwiseba40652007-08-30 20:10:57 +00008390 ac_lo=`expr $ac_mid + 1`
8391 if test $ac_lo -le $ac_mid; then
8392 ac_lo= ac_hi=
8393 break
8394 fi
8395 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008396fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008397
8398rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008399 done
8400else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008401 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008402sed 's/^/| /' conftest.$ac_ext >&5
8403
Martin v. Löwiseba40652007-08-30 20:10:57 +00008404 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008405/* confdefs.h. */
8406_ACEOF
8407cat confdefs.h >>conftest.$ac_ext
8408cat >>conftest.$ac_ext <<_ACEOF
8409/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008410$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008411int
8412main ()
8413{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008414static int test_array [1 - 2 * !(((long int) (sizeof (int))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008415test_array [0] = 0
8416
8417 ;
8418 return 0;
8419}
8420_ACEOF
8421rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008422if { (ac_try="$ac_compile"
8423case "(($ac_try" in
8424 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8425 *) ac_try_echo=$ac_try;;
8426esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008427eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8428$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008429 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008430 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008431 grep -v '^ *+' conftest.er1 >conftest.err
8432 rm -f conftest.er1
8433 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008434 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008435 (exit $ac_status); } && {
8436 test -z "$ac_c_werror_flag" ||
8437 test ! -s conftest.err
8438 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008439 ac_hi=-1 ac_mid=-1
8440 while :; do
8441 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008442/* confdefs.h. */
8443_ACEOF
8444cat confdefs.h >>conftest.$ac_ext
8445cat >>conftest.$ac_ext <<_ACEOF
8446/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008447$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008448int
8449main ()
8450{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008451static int test_array [1 - 2 * !(((long int) (sizeof (int))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008452test_array [0] = 0
8453
8454 ;
8455 return 0;
8456}
8457_ACEOF
8458rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008459if { (ac_try="$ac_compile"
8460case "(($ac_try" in
8461 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8462 *) ac_try_echo=$ac_try;;
8463esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008464eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8465$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008466 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008467 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008468 grep -v '^ *+' conftest.er1 >conftest.err
8469 rm -f conftest.er1
8470 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008471 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008472 (exit $ac_status); } && {
8473 test -z "$ac_c_werror_flag" ||
8474 test ! -s conftest.err
8475 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008476 ac_lo=$ac_mid; break
8477else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008478 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008479sed 's/^/| /' conftest.$ac_ext >&5
8480
Martin v. Löwiseba40652007-08-30 20:10:57 +00008481 ac_hi=`expr '(' $ac_mid ')' - 1`
8482 if test $ac_mid -le $ac_hi; then
8483 ac_lo= ac_hi=
8484 break
8485 fi
8486 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00008487fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008488
8489rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008490 done
8491else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008492 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008493sed 's/^/| /' conftest.$ac_ext >&5
8494
Martin v. Löwiseba40652007-08-30 20:10:57 +00008495 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00008496fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008497
8498rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008499fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008500
8501rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008502# Binary search between lo and hi bounds.
8503while test "x$ac_lo" != "x$ac_hi"; do
8504 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8505 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008506/* confdefs.h. */
8507_ACEOF
8508cat confdefs.h >>conftest.$ac_ext
8509cat >>conftest.$ac_ext <<_ACEOF
8510/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008511$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008512int
8513main ()
8514{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008515static int test_array [1 - 2 * !(((long int) (sizeof (int))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008516test_array [0] = 0
8517
8518 ;
8519 return 0;
8520}
8521_ACEOF
8522rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008523if { (ac_try="$ac_compile"
8524case "(($ac_try" in
8525 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8526 *) ac_try_echo=$ac_try;;
8527esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008528eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8529$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008530 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008531 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008532 grep -v '^ *+' conftest.er1 >conftest.err
8533 rm -f conftest.er1
8534 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008535 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008536 (exit $ac_status); } && {
8537 test -z "$ac_c_werror_flag" ||
8538 test ! -s conftest.err
8539 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008540 ac_hi=$ac_mid
8541else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008542 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008543sed 's/^/| /' conftest.$ac_ext >&5
8544
Martin v. Löwiseba40652007-08-30 20:10:57 +00008545 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008546fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008547
8548rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008549done
8550case $ac_lo in
8551?*) ac_cv_sizeof_int=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00008552'') if test "$ac_cv_type_int" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008553 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
8554$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8555{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00008556See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008557$as_echo "$as_me: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00008558See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008559 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008560 else
8561 ac_cv_sizeof_int=0
8562 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00008563esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008564else
Martin v. Löwis11437992002-04-12 09:54:03 +00008565 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008566/* confdefs.h. */
8567_ACEOF
8568cat confdefs.h >>conftest.$ac_ext
8569cat >>conftest.$ac_ext <<_ACEOF
8570/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008571$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008572static long int longval () { return (long int) (sizeof (int)); }
8573static unsigned long int ulongval () { return (long int) (sizeof (int)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008574#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008575#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008576int
8577main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008578{
Martin v. Löwis11437992002-04-12 09:54:03 +00008579
8580 FILE *f = fopen ("conftest.val", "w");
8581 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00008582 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008583 if (((long int) (sizeof (int))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00008584 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008585 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008586 if (i != ((long int) (sizeof (int))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008587 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008588 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008589 }
8590 else
8591 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008592 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008593 if (i != ((long int) (sizeof (int))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008594 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008595 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008596 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008597 /* Do not output a trailing newline, as this causes \r\n confusion
8598 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +00008599 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008600
8601 ;
8602 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008603}
Martin v. Löwis11437992002-04-12 09:54:03 +00008604_ACEOF
8605rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008606if { (ac_try="$ac_link"
8607case "(($ac_try" in
8608 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8609 *) ac_try_echo=$ac_try;;
8610esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008611eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8612$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008613 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008614 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008615 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008616 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00008617 { (case "(($ac_try" in
8618 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8619 *) ac_try_echo=$ac_try;;
8620esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008621eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8622$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008623 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008624 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008625 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008626 (exit $ac_status); }; }; then
8627 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008628else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008629 $as_echo "$as_me: program exited with status $ac_status" >&5
8630$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008631sed 's/^/| /' conftest.$ac_ext >&5
8632
Martin v. Löwis11437992002-04-12 09:54:03 +00008633( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00008634if test "$ac_cv_type_int" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008635 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
8636$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8637{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00008638See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008639$as_echo "$as_me: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00008640See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008641 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008642 else
8643 ac_cv_sizeof_int=0
8644 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008645fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008646rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00008647rm -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 +00008648fi
8649rm -f conftest.val
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008650fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008651{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
8652$as_echo "$ac_cv_sizeof_int" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008653
8654
8655
Martin v. Löwis11437992002-04-12 09:54:03 +00008656cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008657#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00008658_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008659
8660
Martin v. Löwiseba40652007-08-30 20:10:57 +00008661# The cast to long int works around a bug in the HP C Compiler
8662# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8663# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8664# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008665{ $as_echo "$as_me:$LINENO: checking size of long" >&5
8666$as_echo_n "checking size of long... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00008667if test "${ac_cv_sizeof_long+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008668 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00008669else
Martin v. Löwis11437992002-04-12 09:54:03 +00008670 if test "$cross_compiling" = yes; then
8671 # Depending upon the size, compute the lo and hi bounds.
8672cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008673/* confdefs.h. */
8674_ACEOF
8675cat confdefs.h >>conftest.$ac_ext
8676cat >>conftest.$ac_ext <<_ACEOF
8677/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008678$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008679int
8680main ()
8681{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008682static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008683test_array [0] = 0
8684
8685 ;
8686 return 0;
8687}
8688_ACEOF
8689rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008690if { (ac_try="$ac_compile"
8691case "(($ac_try" in
8692 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8693 *) ac_try_echo=$ac_try;;
8694esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008695eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8696$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008697 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008698 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008699 grep -v '^ *+' conftest.er1 >conftest.err
8700 rm -f conftest.er1
8701 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008702 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008703 (exit $ac_status); } && {
8704 test -z "$ac_c_werror_flag" ||
8705 test ! -s conftest.err
8706 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008707 ac_lo=0 ac_mid=0
8708 while :; do
8709 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008710/* confdefs.h. */
8711_ACEOF
8712cat confdefs.h >>conftest.$ac_ext
8713cat >>conftest.$ac_ext <<_ACEOF
8714/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008715$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008716int
8717main ()
8718{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008719static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008720test_array [0] = 0
8721
8722 ;
8723 return 0;
8724}
8725_ACEOF
8726rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008727if { (ac_try="$ac_compile"
8728case "(($ac_try" in
8729 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8730 *) ac_try_echo=$ac_try;;
8731esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008732eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8733$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008734 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008735 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008736 grep -v '^ *+' conftest.er1 >conftest.err
8737 rm -f conftest.er1
8738 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008739 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008740 (exit $ac_status); } && {
8741 test -z "$ac_c_werror_flag" ||
8742 test ! -s conftest.err
8743 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008744 ac_hi=$ac_mid; break
8745else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008746 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008747sed 's/^/| /' conftest.$ac_ext >&5
8748
Martin v. Löwiseba40652007-08-30 20:10:57 +00008749 ac_lo=`expr $ac_mid + 1`
8750 if test $ac_lo -le $ac_mid; then
8751 ac_lo= ac_hi=
8752 break
8753 fi
8754 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008755fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008756
8757rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008758 done
8759else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008760 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008761sed 's/^/| /' conftest.$ac_ext >&5
8762
Martin v. Löwiseba40652007-08-30 20:10:57 +00008763 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008764/* confdefs.h. */
8765_ACEOF
8766cat confdefs.h >>conftest.$ac_ext
8767cat >>conftest.$ac_ext <<_ACEOF
8768/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008769$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008770int
8771main ()
8772{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008773static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008774test_array [0] = 0
8775
8776 ;
8777 return 0;
8778}
8779_ACEOF
8780rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008781if { (ac_try="$ac_compile"
8782case "(($ac_try" in
8783 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8784 *) ac_try_echo=$ac_try;;
8785esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008786eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8787$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008788 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008789 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008790 grep -v '^ *+' conftest.er1 >conftest.err
8791 rm -f conftest.er1
8792 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008793 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008794 (exit $ac_status); } && {
8795 test -z "$ac_c_werror_flag" ||
8796 test ! -s conftest.err
8797 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008798 ac_hi=-1 ac_mid=-1
8799 while :; do
8800 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008801/* confdefs.h. */
8802_ACEOF
8803cat confdefs.h >>conftest.$ac_ext
8804cat >>conftest.$ac_ext <<_ACEOF
8805/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008806$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008807int
8808main ()
8809{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008810static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008811test_array [0] = 0
8812
8813 ;
8814 return 0;
8815}
8816_ACEOF
8817rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008818if { (ac_try="$ac_compile"
8819case "(($ac_try" in
8820 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8821 *) ac_try_echo=$ac_try;;
8822esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008823eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8824$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008825 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008826 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008827 grep -v '^ *+' conftest.er1 >conftest.err
8828 rm -f conftest.er1
8829 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008830 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008831 (exit $ac_status); } && {
8832 test -z "$ac_c_werror_flag" ||
8833 test ! -s conftest.err
8834 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008835 ac_lo=$ac_mid; break
8836else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008837 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008838sed 's/^/| /' conftest.$ac_ext >&5
8839
Martin v. Löwiseba40652007-08-30 20:10:57 +00008840 ac_hi=`expr '(' $ac_mid ')' - 1`
8841 if test $ac_mid -le $ac_hi; then
8842 ac_lo= ac_hi=
8843 break
8844 fi
8845 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00008846fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008847
8848rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008849 done
8850else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008851 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008852sed 's/^/| /' conftest.$ac_ext >&5
8853
Martin v. Löwiseba40652007-08-30 20:10:57 +00008854 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00008855fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008856
8857rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008858fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008859
8860rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008861# Binary search between lo and hi bounds.
8862while test "x$ac_lo" != "x$ac_hi"; do
8863 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8864 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008865/* confdefs.h. */
8866_ACEOF
8867cat confdefs.h >>conftest.$ac_ext
8868cat >>conftest.$ac_ext <<_ACEOF
8869/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008870$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008871int
8872main ()
8873{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008874static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008875test_array [0] = 0
8876
8877 ;
8878 return 0;
8879}
8880_ACEOF
8881rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008882if { (ac_try="$ac_compile"
8883case "(($ac_try" in
8884 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8885 *) ac_try_echo=$ac_try;;
8886esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008887eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8888$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008889 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008890 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008891 grep -v '^ *+' conftest.er1 >conftest.err
8892 rm -f conftest.er1
8893 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008894 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008895 (exit $ac_status); } && {
8896 test -z "$ac_c_werror_flag" ||
8897 test ! -s conftest.err
8898 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008899 ac_hi=$ac_mid
8900else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008901 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008902sed 's/^/| /' conftest.$ac_ext >&5
8903
Martin v. Löwiseba40652007-08-30 20:10:57 +00008904 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008905fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008906
8907rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008908done
8909case $ac_lo in
8910?*) ac_cv_sizeof_long=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00008911'') if test "$ac_cv_type_long" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008912 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
8913$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8914{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008915See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008916$as_echo "$as_me: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008917See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008918 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008919 else
8920 ac_cv_sizeof_long=0
8921 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00008922esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008923else
Martin v. Löwis11437992002-04-12 09:54:03 +00008924 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008925/* confdefs.h. */
8926_ACEOF
8927cat confdefs.h >>conftest.$ac_ext
8928cat >>conftest.$ac_ext <<_ACEOF
8929/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008930$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008931static long int longval () { return (long int) (sizeof (long)); }
8932static unsigned long int ulongval () { return (long int) (sizeof (long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008933#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008934#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008935int
8936main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008937{
Martin v. Löwis11437992002-04-12 09:54:03 +00008938
8939 FILE *f = fopen ("conftest.val", "w");
8940 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00008941 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008942 if (((long int) (sizeof (long))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00008943 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008944 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008945 if (i != ((long int) (sizeof (long))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008946 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008947 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008948 }
8949 else
8950 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008951 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008952 if (i != ((long int) (sizeof (long))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008953 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008954 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008955 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008956 /* Do not output a trailing newline, as this causes \r\n confusion
8957 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +00008958 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008959
8960 ;
8961 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008962}
Martin v. Löwis11437992002-04-12 09:54:03 +00008963_ACEOF
8964rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008965if { (ac_try="$ac_link"
8966case "(($ac_try" in
8967 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8968 *) ac_try_echo=$ac_try;;
8969esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008970eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8971$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008972 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008973 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008974 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008975 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00008976 { (case "(($ac_try" in
8977 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8978 *) ac_try_echo=$ac_try;;
8979esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008980eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8981$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008982 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008983 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008984 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008985 (exit $ac_status); }; }; then
8986 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008987else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008988 $as_echo "$as_me: program exited with status $ac_status" >&5
8989$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008990sed 's/^/| /' conftest.$ac_ext >&5
8991
Martin v. Löwis11437992002-04-12 09:54:03 +00008992( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00008993if test "$ac_cv_type_long" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008994 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
8995$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8996{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008997See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00008998$as_echo "$as_me: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008999See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009000 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009001 else
9002 ac_cv_sizeof_long=0
9003 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009004fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009005rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00009006rm -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 +00009007fi
9008rm -f conftest.val
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009009fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009010{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
9011$as_echo "$ac_cv_sizeof_long" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009012
9013
9014
Martin v. Löwis11437992002-04-12 09:54:03 +00009015cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009016#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00009017_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009018
9019
Martin v. Löwiseba40652007-08-30 20:10:57 +00009020# The cast to long int works around a bug in the HP C Compiler
9021# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9022# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9023# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009024{ $as_echo "$as_me:$LINENO: checking size of void *" >&5
9025$as_echo_n "checking size of void *... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009026if test "${ac_cv_sizeof_void_p+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009027 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00009028else
Martin v. Löwis11437992002-04-12 09:54:03 +00009029 if test "$cross_compiling" = yes; then
9030 # Depending upon the size, compute the lo and hi bounds.
9031cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009032/* confdefs.h. */
9033_ACEOF
9034cat confdefs.h >>conftest.$ac_ext
9035cat >>conftest.$ac_ext <<_ACEOF
9036/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009037$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009038int
9039main ()
9040{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009041static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009042test_array [0] = 0
9043
9044 ;
9045 return 0;
9046}
9047_ACEOF
9048rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009049if { (ac_try="$ac_compile"
9050case "(($ac_try" in
9051 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9052 *) ac_try_echo=$ac_try;;
9053esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009054eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9055$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009056 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009057 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009058 grep -v '^ *+' conftest.er1 >conftest.err
9059 rm -f conftest.er1
9060 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009061 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009062 (exit $ac_status); } && {
9063 test -z "$ac_c_werror_flag" ||
9064 test ! -s conftest.err
9065 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009066 ac_lo=0 ac_mid=0
9067 while :; do
9068 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009069/* confdefs.h. */
9070_ACEOF
9071cat confdefs.h >>conftest.$ac_ext
9072cat >>conftest.$ac_ext <<_ACEOF
9073/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009074$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009075int
9076main ()
9077{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009078static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009079test_array [0] = 0
9080
9081 ;
9082 return 0;
9083}
9084_ACEOF
9085rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009086if { (ac_try="$ac_compile"
9087case "(($ac_try" in
9088 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9089 *) ac_try_echo=$ac_try;;
9090esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009091eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9092$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009093 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009094 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009095 grep -v '^ *+' conftest.er1 >conftest.err
9096 rm -f conftest.er1
9097 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009098 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009099 (exit $ac_status); } && {
9100 test -z "$ac_c_werror_flag" ||
9101 test ! -s conftest.err
9102 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009103 ac_hi=$ac_mid; break
9104else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009105 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009106sed 's/^/| /' conftest.$ac_ext >&5
9107
Martin v. Löwiseba40652007-08-30 20:10:57 +00009108 ac_lo=`expr $ac_mid + 1`
9109 if test $ac_lo -le $ac_mid; then
9110 ac_lo= ac_hi=
9111 break
9112 fi
9113 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009114fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009115
9116rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009117 done
9118else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009119 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009120sed 's/^/| /' conftest.$ac_ext >&5
9121
Martin v. Löwiseba40652007-08-30 20:10:57 +00009122 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009123/* confdefs.h. */
9124_ACEOF
9125cat confdefs.h >>conftest.$ac_ext
9126cat >>conftest.$ac_ext <<_ACEOF
9127/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009128$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009129int
9130main ()
9131{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009132static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009133test_array [0] = 0
9134
9135 ;
9136 return 0;
9137}
9138_ACEOF
9139rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009140if { (ac_try="$ac_compile"
9141case "(($ac_try" in
9142 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9143 *) ac_try_echo=$ac_try;;
9144esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009145eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9146$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009147 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009148 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009149 grep -v '^ *+' conftest.er1 >conftest.err
9150 rm -f conftest.er1
9151 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009152 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009153 (exit $ac_status); } && {
9154 test -z "$ac_c_werror_flag" ||
9155 test ! -s conftest.err
9156 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009157 ac_hi=-1 ac_mid=-1
9158 while :; do
9159 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009160/* confdefs.h. */
9161_ACEOF
9162cat confdefs.h >>conftest.$ac_ext
9163cat >>conftest.$ac_ext <<_ACEOF
9164/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009165$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009166int
9167main ()
9168{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009169static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009170test_array [0] = 0
9171
9172 ;
9173 return 0;
9174}
9175_ACEOF
9176rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009177if { (ac_try="$ac_compile"
9178case "(($ac_try" in
9179 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9180 *) ac_try_echo=$ac_try;;
9181esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009182eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9183$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009184 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009185 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009186 grep -v '^ *+' conftest.er1 >conftest.err
9187 rm -f conftest.er1
9188 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009189 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009190 (exit $ac_status); } && {
9191 test -z "$ac_c_werror_flag" ||
9192 test ! -s conftest.err
9193 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009194 ac_lo=$ac_mid; break
9195else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009196 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009197sed 's/^/| /' conftest.$ac_ext >&5
9198
Martin v. Löwiseba40652007-08-30 20:10:57 +00009199 ac_hi=`expr '(' $ac_mid ')' - 1`
9200 if test $ac_mid -le $ac_hi; then
9201 ac_lo= ac_hi=
9202 break
9203 fi
9204 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00009205fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009206
9207rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009208 done
9209else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009210 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009211sed 's/^/| /' conftest.$ac_ext >&5
9212
Martin v. Löwiseba40652007-08-30 20:10:57 +00009213 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00009214fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009215
9216rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009217fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009218
9219rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009220# Binary search between lo and hi bounds.
9221while test "x$ac_lo" != "x$ac_hi"; do
9222 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9223 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009224/* confdefs.h. */
9225_ACEOF
9226cat confdefs.h >>conftest.$ac_ext
9227cat >>conftest.$ac_ext <<_ACEOF
9228/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009229$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009230int
9231main ()
9232{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009233static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009234test_array [0] = 0
9235
9236 ;
9237 return 0;
9238}
9239_ACEOF
9240rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009241if { (ac_try="$ac_compile"
9242case "(($ac_try" in
9243 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9244 *) ac_try_echo=$ac_try;;
9245esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009246eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9247$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009248 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009249 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009250 grep -v '^ *+' conftest.er1 >conftest.err
9251 rm -f conftest.er1
9252 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009253 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009254 (exit $ac_status); } && {
9255 test -z "$ac_c_werror_flag" ||
9256 test ! -s conftest.err
9257 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009258 ac_hi=$ac_mid
9259else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009260 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009261sed 's/^/| /' conftest.$ac_ext >&5
9262
Martin v. Löwiseba40652007-08-30 20:10:57 +00009263 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009264fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009265
9266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009267done
9268case $ac_lo in
9269?*) ac_cv_sizeof_void_p=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009270'') if test "$ac_cv_type_void_p" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009271 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
9272$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9273{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00009274See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009275$as_echo "$as_me: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00009276See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009277 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009278 else
9279 ac_cv_sizeof_void_p=0
9280 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009281esac
Guido van Rossumad678af1998-10-02 14:42:15 +00009282else
Martin v. Löwis11437992002-04-12 09:54:03 +00009283 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009284/* confdefs.h. */
9285_ACEOF
9286cat confdefs.h >>conftest.$ac_ext
9287cat >>conftest.$ac_ext <<_ACEOF
9288/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009289$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009290static long int longval () { return (long int) (sizeof (void *)); }
9291static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009292#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009293#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009294int
9295main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00009296{
Martin v. Löwis11437992002-04-12 09:54:03 +00009297
9298 FILE *f = fopen ("conftest.val", "w");
9299 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00009300 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009301 if (((long int) (sizeof (void *))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00009302 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009303 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009304 if (i != ((long int) (sizeof (void *))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009305 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009306 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009307 }
9308 else
9309 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009310 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009311 if (i != ((long int) (sizeof (void *))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009312 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009313 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009314 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009315 /* Do not output a trailing newline, as this causes \r\n confusion
9316 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +00009317 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009318
9319 ;
9320 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00009321}
Martin v. Löwis11437992002-04-12 09:54:03 +00009322_ACEOF
9323rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009324if { (ac_try="$ac_link"
9325case "(($ac_try" in
9326 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9327 *) ac_try_echo=$ac_try;;
9328esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009329eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9330$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009331 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009332 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009333 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009334 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00009335 { (case "(($ac_try" in
9336 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9337 *) ac_try_echo=$ac_try;;
9338esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009339eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9340$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009341 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009342 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009343 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009344 (exit $ac_status); }; }; then
9345 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00009346else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009347 $as_echo "$as_me: program exited with status $ac_status" >&5
9348$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009349sed 's/^/| /' conftest.$ac_ext >&5
9350
Martin v. Löwis11437992002-04-12 09:54:03 +00009351( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00009352if test "$ac_cv_type_void_p" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009353 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
9354$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9355{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00009356See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009357$as_echo "$as_me: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00009358See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009359 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009360 else
9361 ac_cv_sizeof_void_p=0
9362 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009363fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009364rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00009365rm -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 +00009366fi
9367rm -f conftest.val
Guido van Rossumad678af1998-10-02 14:42:15 +00009368fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009369{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
9370$as_echo "$ac_cv_sizeof_void_p" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009371
9372
9373
Martin v. Löwis11437992002-04-12 09:54:03 +00009374cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00009375#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00009376_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00009377
9378
Martin v. Löwiseba40652007-08-30 20:10:57 +00009379# The cast to long int works around a bug in the HP C Compiler
9380# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9381# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9382# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009383{ $as_echo "$as_me:$LINENO: checking size of short" >&5
9384$as_echo_n "checking size of short... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009385if test "${ac_cv_sizeof_short+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009386 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00009387else
Martin v. Löwis11437992002-04-12 09:54:03 +00009388 if test "$cross_compiling" = yes; then
9389 # Depending upon the size, compute the lo and hi bounds.
9390cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009391/* confdefs.h. */
9392_ACEOF
9393cat confdefs.h >>conftest.$ac_ext
9394cat >>conftest.$ac_ext <<_ACEOF
9395/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009396$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009397int
9398main ()
9399{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009400static int test_array [1 - 2 * !(((long int) (sizeof (short))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009401test_array [0] = 0
9402
9403 ;
9404 return 0;
9405}
9406_ACEOF
9407rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009408if { (ac_try="$ac_compile"
9409case "(($ac_try" in
9410 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9411 *) ac_try_echo=$ac_try;;
9412esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009413eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9414$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009415 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009416 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009417 grep -v '^ *+' conftest.er1 >conftest.err
9418 rm -f conftest.er1
9419 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009420 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009421 (exit $ac_status); } && {
9422 test -z "$ac_c_werror_flag" ||
9423 test ! -s conftest.err
9424 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009425 ac_lo=0 ac_mid=0
9426 while :; do
9427 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009428/* confdefs.h. */
9429_ACEOF
9430cat confdefs.h >>conftest.$ac_ext
9431cat >>conftest.$ac_ext <<_ACEOF
9432/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009433$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009434int
9435main ()
9436{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009437static int test_array [1 - 2 * !(((long int) (sizeof (short))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009438test_array [0] = 0
9439
9440 ;
9441 return 0;
9442}
9443_ACEOF
9444rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009445if { (ac_try="$ac_compile"
9446case "(($ac_try" in
9447 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9448 *) ac_try_echo=$ac_try;;
9449esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009450eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9451$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009452 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009453 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009454 grep -v '^ *+' conftest.er1 >conftest.err
9455 rm -f conftest.er1
9456 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009457 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009458 (exit $ac_status); } && {
9459 test -z "$ac_c_werror_flag" ||
9460 test ! -s conftest.err
9461 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009462 ac_hi=$ac_mid; break
9463else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009464 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009465sed 's/^/| /' conftest.$ac_ext >&5
9466
Martin v. Löwiseba40652007-08-30 20:10:57 +00009467 ac_lo=`expr $ac_mid + 1`
9468 if test $ac_lo -le $ac_mid; then
9469 ac_lo= ac_hi=
9470 break
9471 fi
9472 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009473fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009474
9475rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009476 done
9477else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009478 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009479sed 's/^/| /' conftest.$ac_ext >&5
9480
Martin v. Löwiseba40652007-08-30 20:10:57 +00009481 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009482/* confdefs.h. */
9483_ACEOF
9484cat confdefs.h >>conftest.$ac_ext
9485cat >>conftest.$ac_ext <<_ACEOF
9486/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009487$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009488int
9489main ()
9490{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009491static int test_array [1 - 2 * !(((long int) (sizeof (short))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009492test_array [0] = 0
9493
9494 ;
9495 return 0;
9496}
9497_ACEOF
9498rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009499if { (ac_try="$ac_compile"
9500case "(($ac_try" in
9501 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9502 *) ac_try_echo=$ac_try;;
9503esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009504eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9505$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009506 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009507 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009508 grep -v '^ *+' conftest.er1 >conftest.err
9509 rm -f conftest.er1
9510 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009511 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009512 (exit $ac_status); } && {
9513 test -z "$ac_c_werror_flag" ||
9514 test ! -s conftest.err
9515 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009516 ac_hi=-1 ac_mid=-1
9517 while :; do
9518 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009519/* confdefs.h. */
9520_ACEOF
9521cat confdefs.h >>conftest.$ac_ext
9522cat >>conftest.$ac_ext <<_ACEOF
9523/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009524$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009525int
9526main ()
9527{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009528static int test_array [1 - 2 * !(((long int) (sizeof (short))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009529test_array [0] = 0
9530
9531 ;
9532 return 0;
9533}
9534_ACEOF
9535rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009536if { (ac_try="$ac_compile"
9537case "(($ac_try" in
9538 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9539 *) ac_try_echo=$ac_try;;
9540esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009541eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9542$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009543 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009544 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009545 grep -v '^ *+' conftest.er1 >conftest.err
9546 rm -f conftest.er1
9547 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009548 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009549 (exit $ac_status); } && {
9550 test -z "$ac_c_werror_flag" ||
9551 test ! -s conftest.err
9552 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009553 ac_lo=$ac_mid; break
9554else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009555 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009556sed 's/^/| /' conftest.$ac_ext >&5
9557
Martin v. Löwiseba40652007-08-30 20:10:57 +00009558 ac_hi=`expr '(' $ac_mid ')' - 1`
9559 if test $ac_mid -le $ac_hi; then
9560 ac_lo= ac_hi=
9561 break
9562 fi
9563 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00009564fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009565
9566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009567 done
9568else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009569 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009570sed 's/^/| /' conftest.$ac_ext >&5
9571
Martin v. Löwiseba40652007-08-30 20:10:57 +00009572 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00009573fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009574
9575rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009576fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009577
9578rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009579# Binary search between lo and hi bounds.
9580while test "x$ac_lo" != "x$ac_hi"; do
9581 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9582 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009583/* confdefs.h. */
9584_ACEOF
9585cat confdefs.h >>conftest.$ac_ext
9586cat >>conftest.$ac_ext <<_ACEOF
9587/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009588$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009589int
9590main ()
9591{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009592static int test_array [1 - 2 * !(((long int) (sizeof (short))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009593test_array [0] = 0
9594
9595 ;
9596 return 0;
9597}
9598_ACEOF
9599rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009600if { (ac_try="$ac_compile"
9601case "(($ac_try" in
9602 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9603 *) ac_try_echo=$ac_try;;
9604esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009605eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9606$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009607 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009608 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009609 grep -v '^ *+' conftest.er1 >conftest.err
9610 rm -f conftest.er1
9611 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009612 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009613 (exit $ac_status); } && {
9614 test -z "$ac_c_werror_flag" ||
9615 test ! -s conftest.err
9616 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009617 ac_hi=$ac_mid
9618else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009619 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009620sed 's/^/| /' conftest.$ac_ext >&5
9621
Martin v. Löwiseba40652007-08-30 20:10:57 +00009622 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009623fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009624
9625rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009626done
9627case $ac_lo in
9628?*) ac_cv_sizeof_short=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009629'') if test "$ac_cv_type_short" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009630 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
9631$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9632{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009633See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009634$as_echo "$as_me: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009635See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009636 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009637 else
9638 ac_cv_sizeof_short=0
9639 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009640esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00009641else
Martin v. Löwis11437992002-04-12 09:54:03 +00009642 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009643/* confdefs.h. */
9644_ACEOF
9645cat confdefs.h >>conftest.$ac_ext
9646cat >>conftest.$ac_ext <<_ACEOF
9647/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009648$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009649static long int longval () { return (long int) (sizeof (short)); }
9650static unsigned long int ulongval () { return (long int) (sizeof (short)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009651#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009652#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009653int
9654main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00009655{
Martin v. Löwis11437992002-04-12 09:54:03 +00009656
9657 FILE *f = fopen ("conftest.val", "w");
9658 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00009659 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009660 if (((long int) (sizeof (short))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00009661 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009662 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009663 if (i != ((long int) (sizeof (short))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009664 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009665 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009666 }
9667 else
9668 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009669 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009670 if (i != ((long int) (sizeof (short))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009671 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009672 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009673 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009674 /* Do not output a trailing newline, as this causes \r\n confusion
9675 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +00009676 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009677
9678 ;
9679 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00009680}
Martin v. Löwis11437992002-04-12 09:54:03 +00009681_ACEOF
9682rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009683if { (ac_try="$ac_link"
9684case "(($ac_try" in
9685 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9686 *) ac_try_echo=$ac_try;;
9687esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009688eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9689$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009690 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009691 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009692 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009693 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00009694 { (case "(($ac_try" in
9695 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9696 *) ac_try_echo=$ac_try;;
9697esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009698eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9699$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009700 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009701 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009702 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009703 (exit $ac_status); }; }; then
9704 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00009705else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009706 $as_echo "$as_me: program exited with status $ac_status" >&5
9707$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009708sed 's/^/| /' conftest.$ac_ext >&5
9709
Martin v. Löwis11437992002-04-12 09:54:03 +00009710( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00009711if test "$ac_cv_type_short" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009712 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
9713$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9714{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009715See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009716$as_echo "$as_me: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009717See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009718 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009719 else
9720 ac_cv_sizeof_short=0
9721 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009722fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009723rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +00009724rm -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 +00009725fi
9726rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +00009727fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009728{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
9729$as_echo "$ac_cv_sizeof_short" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009730
9731
9732
Martin v. Löwis11437992002-04-12 09:54:03 +00009733cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009734#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00009735_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009736
9737
Martin v. Löwiseba40652007-08-30 20:10:57 +00009738# The cast to long int works around a bug in the HP C Compiler
9739# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9740# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9741# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009742{ $as_echo "$as_me:$LINENO: checking size of float" >&5
9743$as_echo_n "checking size of float... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009744if test "${ac_cv_sizeof_float+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009745 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00009746else
Martin v. Löwis11437992002-04-12 09:54:03 +00009747 if test "$cross_compiling" = yes; then
9748 # Depending upon the size, compute the lo and hi bounds.
9749cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009750/* confdefs.h. */
9751_ACEOF
9752cat confdefs.h >>conftest.$ac_ext
9753cat >>conftest.$ac_ext <<_ACEOF
9754/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009755$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009756int
9757main ()
9758{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009759static int test_array [1 - 2 * !(((long int) (sizeof (float))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009760test_array [0] = 0
9761
9762 ;
9763 return 0;
9764}
9765_ACEOF
9766rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009767if { (ac_try="$ac_compile"
9768case "(($ac_try" in
9769 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9770 *) ac_try_echo=$ac_try;;
9771esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009772eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9773$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009774 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009775 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009776 grep -v '^ *+' conftest.er1 >conftest.err
9777 rm -f conftest.er1
9778 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009779 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009780 (exit $ac_status); } && {
9781 test -z "$ac_c_werror_flag" ||
9782 test ! -s conftest.err
9783 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009784 ac_lo=0 ac_mid=0
9785 while :; do
9786 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009787/* confdefs.h. */
9788_ACEOF
9789cat confdefs.h >>conftest.$ac_ext
9790cat >>conftest.$ac_ext <<_ACEOF
9791/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009792$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009793int
9794main ()
9795{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009796static int test_array [1 - 2 * !(((long int) (sizeof (float))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009797test_array [0] = 0
9798
9799 ;
9800 return 0;
9801}
9802_ACEOF
9803rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009804if { (ac_try="$ac_compile"
9805case "(($ac_try" in
9806 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9807 *) ac_try_echo=$ac_try;;
9808esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009809eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9810$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009811 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009812 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009813 grep -v '^ *+' conftest.er1 >conftest.err
9814 rm -f conftest.er1
9815 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009816 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009817 (exit $ac_status); } && {
9818 test -z "$ac_c_werror_flag" ||
9819 test ! -s conftest.err
9820 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009821 ac_hi=$ac_mid; break
9822else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009823 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009824sed 's/^/| /' conftest.$ac_ext >&5
9825
Martin v. Löwiseba40652007-08-30 20:10:57 +00009826 ac_lo=`expr $ac_mid + 1`
9827 if test $ac_lo -le $ac_mid; then
9828 ac_lo= ac_hi=
9829 break
9830 fi
9831 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009832fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009833
9834rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009835 done
9836else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009837 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009838sed 's/^/| /' conftest.$ac_ext >&5
9839
Martin v. Löwiseba40652007-08-30 20:10:57 +00009840 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009841/* confdefs.h. */
9842_ACEOF
9843cat confdefs.h >>conftest.$ac_ext
9844cat >>conftest.$ac_ext <<_ACEOF
9845/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009846$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009847int
9848main ()
9849{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009850static int test_array [1 - 2 * !(((long int) (sizeof (float))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009851test_array [0] = 0
9852
9853 ;
9854 return 0;
9855}
9856_ACEOF
9857rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009858if { (ac_try="$ac_compile"
9859case "(($ac_try" in
9860 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9861 *) ac_try_echo=$ac_try;;
9862esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009863eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9864$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009865 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009866 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009867 grep -v '^ *+' conftest.er1 >conftest.err
9868 rm -f conftest.er1
9869 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009870 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009871 (exit $ac_status); } && {
9872 test -z "$ac_c_werror_flag" ||
9873 test ! -s conftest.err
9874 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009875 ac_hi=-1 ac_mid=-1
9876 while :; do
9877 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009878/* confdefs.h. */
9879_ACEOF
9880cat confdefs.h >>conftest.$ac_ext
9881cat >>conftest.$ac_ext <<_ACEOF
9882/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009883$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009884int
9885main ()
9886{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009887static int test_array [1 - 2 * !(((long int) (sizeof (float))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009888test_array [0] = 0
9889
9890 ;
9891 return 0;
9892}
9893_ACEOF
9894rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009895if { (ac_try="$ac_compile"
9896case "(($ac_try" in
9897 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9898 *) ac_try_echo=$ac_try;;
9899esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009900eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9901$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009902 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009903 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009904 grep -v '^ *+' conftest.er1 >conftest.err
9905 rm -f conftest.er1
9906 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009907 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009908 (exit $ac_status); } && {
9909 test -z "$ac_c_werror_flag" ||
9910 test ! -s conftest.err
9911 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009912 ac_lo=$ac_mid; break
9913else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009914 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009915sed 's/^/| /' conftest.$ac_ext >&5
9916
Martin v. Löwiseba40652007-08-30 20:10:57 +00009917 ac_hi=`expr '(' $ac_mid ')' - 1`
9918 if test $ac_mid -le $ac_hi; then
9919 ac_lo= ac_hi=
9920 break
9921 fi
9922 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00009923fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009924
9925rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009926 done
9927else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009928 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009929sed 's/^/| /' conftest.$ac_ext >&5
9930
Martin v. Löwiseba40652007-08-30 20:10:57 +00009931 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00009932fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009933
9934rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009935fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009936
9937rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009938# Binary search between lo and hi bounds.
9939while test "x$ac_lo" != "x$ac_hi"; do
9940 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9941 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009942/* confdefs.h. */
9943_ACEOF
9944cat confdefs.h >>conftest.$ac_ext
9945cat >>conftest.$ac_ext <<_ACEOF
9946/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009947$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009948int
9949main ()
9950{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009951static int test_array [1 - 2 * !(((long int) (sizeof (float))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009952test_array [0] = 0
9953
9954 ;
9955 return 0;
9956}
9957_ACEOF
9958rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009959if { (ac_try="$ac_compile"
9960case "(($ac_try" in
9961 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9962 *) ac_try_echo=$ac_try;;
9963esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009964eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9965$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009966 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009967 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009968 grep -v '^ *+' conftest.er1 >conftest.err
9969 rm -f conftest.er1
9970 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009971 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009972 (exit $ac_status); } && {
9973 test -z "$ac_c_werror_flag" ||
9974 test ! -s conftest.err
9975 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009976 ac_hi=$ac_mid
9977else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009978 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009979sed 's/^/| /' conftest.$ac_ext >&5
9980
Martin v. Löwiseba40652007-08-30 20:10:57 +00009981 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009982fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009983
9984rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009985done
9986case $ac_lo in
9987?*) ac_cv_sizeof_float=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009988'') if test "$ac_cv_type_float" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009989 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
9990$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9991{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009992See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009993$as_echo "$as_me: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009994See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00009995 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009996 else
9997 ac_cv_sizeof_float=0
9998 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009999esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000010000else
Martin v. Löwis11437992002-04-12 09:54:03 +000010001 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010002/* confdefs.h. */
10003_ACEOF
10004cat confdefs.h >>conftest.$ac_ext
10005cat >>conftest.$ac_ext <<_ACEOF
10006/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010007$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010008static long int longval () { return (long int) (sizeof (float)); }
10009static unsigned long int ulongval () { return (long int) (sizeof (float)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000010010#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010011#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010012int
10013main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +000010014{
Martin v. Löwis11437992002-04-12 09:54:03 +000010015
10016 FILE *f = fopen ("conftest.val", "w");
10017 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000010018 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010019 if (((long int) (sizeof (float))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000010020 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010021 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010022 if (i != ((long int) (sizeof (float))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010023 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010024 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010025 }
10026 else
10027 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010028 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010029 if (i != ((long int) (sizeof (float))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010030 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010031 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010032 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010033 /* Do not output a trailing newline, as this causes \r\n confusion
10034 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000010035 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000010036
10037 ;
10038 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000010039}
Martin v. Löwis11437992002-04-12 09:54:03 +000010040_ACEOF
10041rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010042if { (ac_try="$ac_link"
10043case "(($ac_try" in
10044 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10045 *) ac_try_echo=$ac_try;;
10046esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010047eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10048$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010049 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010050 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010051 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010052 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000010053 { (case "(($ac_try" in
10054 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10055 *) ac_try_echo=$ac_try;;
10056esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010057eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10058$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010059 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010060 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010061 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010062 (exit $ac_status); }; }; then
10063 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000010064else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010065 $as_echo "$as_me: program exited with status $ac_status" >&5
10066$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010067sed 's/^/| /' conftest.$ac_ext >&5
10068
Martin v. Löwis11437992002-04-12 09:54:03 +000010069( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000010070if test "$ac_cv_type_float" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010071 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
10072$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10073{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +000010074See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010075$as_echo "$as_me: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +000010076See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010077 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010078 else
10079 ac_cv_sizeof_float=0
10080 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010081fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010082rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000010083rm -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 +000010084fi
10085rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +000010086fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010087{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
10088$as_echo "$ac_cv_sizeof_float" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010089
10090
10091
Martin v. Löwis11437992002-04-12 09:54:03 +000010092cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000010093#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +000010094_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000010095
10096
Martin v. Löwiseba40652007-08-30 20:10:57 +000010097# The cast to long int works around a bug in the HP C Compiler
10098# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10099# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10100# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010101{ $as_echo "$as_me:$LINENO: checking size of double" >&5
10102$as_echo_n "checking size of double... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000010103if test "${ac_cv_sizeof_double+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010104 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000010105else
Martin v. Löwis11437992002-04-12 09:54:03 +000010106 if test "$cross_compiling" = yes; then
10107 # Depending upon the size, compute the lo and hi bounds.
10108cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010109/* confdefs.h. */
10110_ACEOF
10111cat confdefs.h >>conftest.$ac_ext
10112cat >>conftest.$ac_ext <<_ACEOF
10113/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010114$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010115int
10116main ()
10117{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010118static int test_array [1 - 2 * !(((long int) (sizeof (double))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010119test_array [0] = 0
10120
10121 ;
10122 return 0;
10123}
10124_ACEOF
10125rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010126if { (ac_try="$ac_compile"
10127case "(($ac_try" in
10128 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10129 *) ac_try_echo=$ac_try;;
10130esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010131eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10132$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010133 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010134 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010135 grep -v '^ *+' conftest.er1 >conftest.err
10136 rm -f conftest.er1
10137 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010138 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010139 (exit $ac_status); } && {
10140 test -z "$ac_c_werror_flag" ||
10141 test ! -s conftest.err
10142 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010143 ac_lo=0 ac_mid=0
10144 while :; do
10145 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010146/* confdefs.h. */
10147_ACEOF
10148cat confdefs.h >>conftest.$ac_ext
10149cat >>conftest.$ac_ext <<_ACEOF
10150/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010151$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010152int
10153main ()
10154{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010155static int test_array [1 - 2 * !(((long int) (sizeof (double))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010156test_array [0] = 0
10157
10158 ;
10159 return 0;
10160}
10161_ACEOF
10162rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010163if { (ac_try="$ac_compile"
10164case "(($ac_try" in
10165 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10166 *) ac_try_echo=$ac_try;;
10167esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010168eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10169$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010170 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010171 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010172 grep -v '^ *+' conftest.er1 >conftest.err
10173 rm -f conftest.er1
10174 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010175 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010176 (exit $ac_status); } && {
10177 test -z "$ac_c_werror_flag" ||
10178 test ! -s conftest.err
10179 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010180 ac_hi=$ac_mid; break
10181else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010182 $as_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=`expr $ac_mid + 1`
10186 if test $ac_lo -le $ac_mid; then
10187 ac_lo= ac_hi=
10188 break
10189 fi
10190 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010191fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010192
10193rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010194 done
10195else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010196 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010197sed 's/^/| /' conftest.$ac_ext >&5
10198
Martin v. Löwiseba40652007-08-30 20:10:57 +000010199 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010200/* confdefs.h. */
10201_ACEOF
10202cat confdefs.h >>conftest.$ac_ext
10203cat >>conftest.$ac_ext <<_ACEOF
10204/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010205$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010206int
10207main ()
10208{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010209static int test_array [1 - 2 * !(((long int) (sizeof (double))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010210test_array [0] = 0
10211
10212 ;
10213 return 0;
10214}
10215_ACEOF
10216rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010217if { (ac_try="$ac_compile"
10218case "(($ac_try" in
10219 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10220 *) ac_try_echo=$ac_try;;
10221esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010222eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10223$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010224 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010225 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010226 grep -v '^ *+' conftest.er1 >conftest.err
10227 rm -f conftest.er1
10228 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010229 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010230 (exit $ac_status); } && {
10231 test -z "$ac_c_werror_flag" ||
10232 test ! -s conftest.err
10233 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010234 ac_hi=-1 ac_mid=-1
10235 while :; do
10236 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010237/* confdefs.h. */
10238_ACEOF
10239cat confdefs.h >>conftest.$ac_ext
10240cat >>conftest.$ac_ext <<_ACEOF
10241/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010242$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010243int
10244main ()
10245{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010246static int test_array [1 - 2 * !(((long int) (sizeof (double))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010247test_array [0] = 0
10248
10249 ;
10250 return 0;
10251}
10252_ACEOF
10253rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010254if { (ac_try="$ac_compile"
10255case "(($ac_try" in
10256 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10257 *) ac_try_echo=$ac_try;;
10258esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010259eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10260$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010261 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010262 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010263 grep -v '^ *+' conftest.er1 >conftest.err
10264 rm -f conftest.er1
10265 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010266 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010267 (exit $ac_status); } && {
10268 test -z "$ac_c_werror_flag" ||
10269 test ! -s conftest.err
10270 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010271 ac_lo=$ac_mid; break
10272else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010273 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010274sed 's/^/| /' conftest.$ac_ext >&5
10275
Martin v. Löwiseba40652007-08-30 20:10:57 +000010276 ac_hi=`expr '(' $ac_mid ')' - 1`
10277 if test $ac_mid -le $ac_hi; then
10278 ac_lo= ac_hi=
10279 break
10280 fi
10281 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000010282fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010283
10284rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010285 done
10286else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010287 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010288sed 's/^/| /' conftest.$ac_ext >&5
10289
Martin v. Löwiseba40652007-08-30 20:10:57 +000010290 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000010291fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010292
10293rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010294fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010295
10296rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010297# Binary search between lo and hi bounds.
10298while test "x$ac_lo" != "x$ac_hi"; do
10299 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
10300 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010301/* confdefs.h. */
10302_ACEOF
10303cat confdefs.h >>conftest.$ac_ext
10304cat >>conftest.$ac_ext <<_ACEOF
10305/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010306$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010307int
10308main ()
10309{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010310static int test_array [1 - 2 * !(((long int) (sizeof (double))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010311test_array [0] = 0
10312
10313 ;
10314 return 0;
10315}
10316_ACEOF
10317rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010318if { (ac_try="$ac_compile"
10319case "(($ac_try" in
10320 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10321 *) ac_try_echo=$ac_try;;
10322esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010323eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10324$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010325 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010326 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010327 grep -v '^ *+' conftest.er1 >conftest.err
10328 rm -f conftest.er1
10329 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010330 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010331 (exit $ac_status); } && {
10332 test -z "$ac_c_werror_flag" ||
10333 test ! -s conftest.err
10334 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010335 ac_hi=$ac_mid
10336else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010337 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010338sed 's/^/| /' conftest.$ac_ext >&5
10339
Martin v. Löwiseba40652007-08-30 20:10:57 +000010340 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010341fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010342
10343rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010344done
10345case $ac_lo in
10346?*) ac_cv_sizeof_double=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000010347'') if test "$ac_cv_type_double" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010348 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
10349$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10350{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +000010351See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010352$as_echo "$as_me: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +000010353See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010354 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010355 else
10356 ac_cv_sizeof_double=0
10357 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000010358esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000010359else
Martin v. Löwis11437992002-04-12 09:54:03 +000010360 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010361/* confdefs.h. */
10362_ACEOF
10363cat confdefs.h >>conftest.$ac_ext
10364cat >>conftest.$ac_ext <<_ACEOF
10365/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010366$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010367static long int longval () { return (long int) (sizeof (double)); }
10368static unsigned long int ulongval () { return (long int) (sizeof (double)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000010369#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010370#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010371int
10372main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +000010373{
Martin v. Löwis11437992002-04-12 09:54:03 +000010374
10375 FILE *f = fopen ("conftest.val", "w");
10376 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000010377 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010378 if (((long int) (sizeof (double))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000010379 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010380 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010381 if (i != ((long int) (sizeof (double))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010382 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010383 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010384 }
10385 else
10386 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010387 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010388 if (i != ((long int) (sizeof (double))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010389 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010390 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010391 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010392 /* Do not output a trailing newline, as this causes \r\n confusion
10393 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000010394 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000010395
10396 ;
10397 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000010398}
Martin v. Löwis11437992002-04-12 09:54:03 +000010399_ACEOF
10400rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010401if { (ac_try="$ac_link"
10402case "(($ac_try" in
10403 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10404 *) ac_try_echo=$ac_try;;
10405esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010406eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10407$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010408 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010409 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010410 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010411 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000010412 { (case "(($ac_try" in
10413 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10414 *) ac_try_echo=$ac_try;;
10415esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010416eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10417$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010418 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010419 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010420 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010421 (exit $ac_status); }; }; then
10422 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000010423else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010424 $as_echo "$as_me: program exited with status $ac_status" >&5
10425$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010426sed 's/^/| /' conftest.$ac_ext >&5
10427
Martin v. Löwis11437992002-04-12 09:54:03 +000010428( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000010429if test "$ac_cv_type_double" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010430 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
10431$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10432{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +000010433See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010434$as_echo "$as_me: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +000010435See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010436 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010437 else
10438 ac_cv_sizeof_double=0
10439 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010440fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010441rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000010442rm -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 +000010443fi
10444rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +000010445fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010446{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
10447$as_echo "$ac_cv_sizeof_double" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010448
10449
10450
Martin v. Löwis11437992002-04-12 09:54:03 +000010451cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000010452#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +000010453_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000010454
10455
Martin v. Löwiseba40652007-08-30 20:10:57 +000010456# The cast to long int works around a bug in the HP C Compiler
10457# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10458# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10459# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010460{ $as_echo "$as_me:$LINENO: checking size of fpos_t" >&5
10461$as_echo_n "checking size of fpos_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000010462if test "${ac_cv_sizeof_fpos_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010463 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000010464else
Martin v. Löwis11437992002-04-12 09:54:03 +000010465 if test "$cross_compiling" = yes; then
10466 # Depending upon the size, compute the lo and hi bounds.
10467cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010468/* confdefs.h. */
10469_ACEOF
10470cat confdefs.h >>conftest.$ac_ext
10471cat >>conftest.$ac_ext <<_ACEOF
10472/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010473$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010474int
10475main ()
10476{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010477static int test_array [1 - 2 * !(((long int) (sizeof (fpos_t))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010478test_array [0] = 0
10479
10480 ;
10481 return 0;
10482}
10483_ACEOF
10484rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010485if { (ac_try="$ac_compile"
10486case "(($ac_try" in
10487 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10488 *) ac_try_echo=$ac_try;;
10489esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010490eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10491$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010492 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010493 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010494 grep -v '^ *+' conftest.er1 >conftest.err
10495 rm -f conftest.er1
10496 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010497 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010498 (exit $ac_status); } && {
10499 test -z "$ac_c_werror_flag" ||
10500 test ! -s conftest.err
10501 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010502 ac_lo=0 ac_mid=0
10503 while :; do
10504 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010505/* confdefs.h. */
10506_ACEOF
10507cat confdefs.h >>conftest.$ac_ext
10508cat >>conftest.$ac_ext <<_ACEOF
10509/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010510$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010511int
10512main ()
10513{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010514static int test_array [1 - 2 * !(((long int) (sizeof (fpos_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010515test_array [0] = 0
10516
10517 ;
10518 return 0;
10519}
10520_ACEOF
10521rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010522if { (ac_try="$ac_compile"
10523case "(($ac_try" in
10524 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10525 *) ac_try_echo=$ac_try;;
10526esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010527eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10528$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010529 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010530 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010531 grep -v '^ *+' conftest.er1 >conftest.err
10532 rm -f conftest.er1
10533 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010534 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010535 (exit $ac_status); } && {
10536 test -z "$ac_c_werror_flag" ||
10537 test ! -s conftest.err
10538 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010539 ac_hi=$ac_mid; break
10540else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010541 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010542sed 's/^/| /' conftest.$ac_ext >&5
10543
Martin v. Löwiseba40652007-08-30 20:10:57 +000010544 ac_lo=`expr $ac_mid + 1`
10545 if test $ac_lo -le $ac_mid; then
10546 ac_lo= ac_hi=
10547 break
10548 fi
10549 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010550fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010551
10552rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010553 done
10554else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010555 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010556sed 's/^/| /' conftest.$ac_ext >&5
10557
Martin v. Löwiseba40652007-08-30 20:10:57 +000010558 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010559/* confdefs.h. */
10560_ACEOF
10561cat confdefs.h >>conftest.$ac_ext
10562cat >>conftest.$ac_ext <<_ACEOF
10563/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010564$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010565int
10566main ()
10567{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010568static int test_array [1 - 2 * !(((long int) (sizeof (fpos_t))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010569test_array [0] = 0
10570
10571 ;
10572 return 0;
10573}
10574_ACEOF
10575rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010576if { (ac_try="$ac_compile"
10577case "(($ac_try" in
10578 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10579 *) ac_try_echo=$ac_try;;
10580esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010581eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10582$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010583 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010584 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010585 grep -v '^ *+' conftest.er1 >conftest.err
10586 rm -f conftest.er1
10587 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010588 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010589 (exit $ac_status); } && {
10590 test -z "$ac_c_werror_flag" ||
10591 test ! -s conftest.err
10592 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010593 ac_hi=-1 ac_mid=-1
10594 while :; do
10595 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010596/* confdefs.h. */
10597_ACEOF
10598cat confdefs.h >>conftest.$ac_ext
10599cat >>conftest.$ac_ext <<_ACEOF
10600/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010601$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010602int
10603main ()
10604{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010605static int test_array [1 - 2 * !(((long int) (sizeof (fpos_t))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010606test_array [0] = 0
10607
10608 ;
10609 return 0;
10610}
10611_ACEOF
10612rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010613if { (ac_try="$ac_compile"
10614case "(($ac_try" in
10615 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10616 *) ac_try_echo=$ac_try;;
10617esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010618eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10619$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010620 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010621 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010622 grep -v '^ *+' conftest.er1 >conftest.err
10623 rm -f conftest.er1
10624 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010625 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010626 (exit $ac_status); } && {
10627 test -z "$ac_c_werror_flag" ||
10628 test ! -s conftest.err
10629 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010630 ac_lo=$ac_mid; break
10631else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010632 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010633sed 's/^/| /' conftest.$ac_ext >&5
10634
Martin v. Löwiseba40652007-08-30 20:10:57 +000010635 ac_hi=`expr '(' $ac_mid ')' - 1`
10636 if test $ac_mid -le $ac_hi; then
10637 ac_lo= ac_hi=
10638 break
10639 fi
10640 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +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öwis11437992002-04-12 09:54:03 +000010644 done
10645else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010646 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010647sed 's/^/| /' conftest.$ac_ext >&5
10648
Martin v. Löwiseba40652007-08-30 20:10:57 +000010649 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000010650fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010651
10652rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010653fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010654
10655rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010656# Binary search between lo and hi bounds.
10657while test "x$ac_lo" != "x$ac_hi"; do
10658 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
10659 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010660/* confdefs.h. */
10661_ACEOF
10662cat confdefs.h >>conftest.$ac_ext
10663cat >>conftest.$ac_ext <<_ACEOF
10664/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010665$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000010666int
10667main ()
10668{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010669static int test_array [1 - 2 * !(((long int) (sizeof (fpos_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010670test_array [0] = 0
10671
10672 ;
10673 return 0;
10674}
10675_ACEOF
10676rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010677if { (ac_try="$ac_compile"
10678case "(($ac_try" in
10679 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10680 *) ac_try_echo=$ac_try;;
10681esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010682eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10683$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010684 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010685 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010686 grep -v '^ *+' conftest.er1 >conftest.err
10687 rm -f conftest.er1
10688 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010689 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010690 (exit $ac_status); } && {
10691 test -z "$ac_c_werror_flag" ||
10692 test ! -s conftest.err
10693 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010694 ac_hi=$ac_mid
10695else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010696 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010697sed 's/^/| /' conftest.$ac_ext >&5
10698
Martin v. Löwiseba40652007-08-30 20:10:57 +000010699 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010700fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010701
10702rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010703done
10704case $ac_lo in
10705?*) ac_cv_sizeof_fpos_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000010706'') if test "$ac_cv_type_fpos_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010707 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
10708$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10709{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010710See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010711$as_echo "$as_me: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010712See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010713 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010714 else
10715 ac_cv_sizeof_fpos_t=0
10716 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000010717esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010718else
Martin v. Löwis11437992002-04-12 09:54:03 +000010719 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010720/* confdefs.h. */
10721_ACEOF
10722cat confdefs.h >>conftest.$ac_ext
10723cat >>conftest.$ac_ext <<_ACEOF
10724/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010725$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010726static long int longval () { return (long int) (sizeof (fpos_t)); }
10727static unsigned long int ulongval () { return (long int) (sizeof (fpos_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000010728#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010729#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010730int
10731main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010732{
Martin v. Löwis11437992002-04-12 09:54:03 +000010733
10734 FILE *f = fopen ("conftest.val", "w");
10735 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000010736 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010737 if (((long int) (sizeof (fpos_t))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000010738 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010739 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010740 if (i != ((long int) (sizeof (fpos_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010741 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010742 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010743 }
10744 else
10745 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010746 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010747 if (i != ((long int) (sizeof (fpos_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010748 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010749 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010750 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010751 /* Do not output a trailing newline, as this causes \r\n confusion
10752 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000010753 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000010754
10755 ;
10756 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010757}
Martin v. Löwis11437992002-04-12 09:54:03 +000010758_ACEOF
10759rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010760if { (ac_try="$ac_link"
10761case "(($ac_try" in
10762 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10763 *) ac_try_echo=$ac_try;;
10764esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010765eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10766$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010767 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010768 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010769 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010770 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000010771 { (case "(($ac_try" in
10772 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10773 *) ac_try_echo=$ac_try;;
10774esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010775eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10776$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010777 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010778 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010779 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010780 (exit $ac_status); }; }; then
10781 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010782else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010783 $as_echo "$as_me: program exited with status $ac_status" >&5
10784$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010785sed 's/^/| /' conftest.$ac_ext >&5
10786
Martin v. Löwis11437992002-04-12 09:54:03 +000010787( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000010788if test "$ac_cv_type_fpos_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010789 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
10790$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10791{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010792See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010793$as_echo "$as_me: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010794See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010795 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010796 else
10797 ac_cv_sizeof_fpos_t=0
10798 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010799fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010800rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000010801rm -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 +000010802fi
10803rm -f conftest.val
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010804fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010805{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
10806$as_echo "$ac_cv_sizeof_fpos_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010807
10808
10809
Martin v. Löwis11437992002-04-12 09:54:03 +000010810cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010811#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +000010812_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010813
Michael W. Hudson54241132001-12-07 15:38:26 +000010814
Martin v. Löwiseba40652007-08-30 20:10:57 +000010815# The cast to long int works around a bug in the HP C Compiler
10816# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10817# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10818# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010819{ $as_echo "$as_me:$LINENO: checking size of size_t" >&5
10820$as_echo_n "checking size of size_t... " >&6; }
Martin v. Löwis18e16552006-02-15 17:27:45 +000010821if test "${ac_cv_sizeof_size_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010822 $as_echo_n "(cached) " >&6
Martin v. Löwis18e16552006-02-15 17:27:45 +000010823else
Martin v. Löwis18e16552006-02-15 17:27:45 +000010824 if test "$cross_compiling" = yes; then
10825 # Depending upon the size, compute the lo and hi bounds.
10826cat >conftest.$ac_ext <<_ACEOF
10827/* confdefs.h. */
10828_ACEOF
10829cat confdefs.h >>conftest.$ac_ext
10830cat >>conftest.$ac_ext <<_ACEOF
10831/* end confdefs.h. */
10832$ac_includes_default
10833int
10834main ()
10835{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010836static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010837test_array [0] = 0
10838
10839 ;
10840 return 0;
10841}
10842_ACEOF
10843rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010844if { (ac_try="$ac_compile"
10845case "(($ac_try" in
10846 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10847 *) ac_try_echo=$ac_try;;
10848esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010849eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10850$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010851 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010852 ac_status=$?
10853 grep -v '^ *+' conftest.er1 >conftest.err
10854 rm -f conftest.er1
10855 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010856 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010857 (exit $ac_status); } && {
10858 test -z "$ac_c_werror_flag" ||
10859 test ! -s conftest.err
10860 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010861 ac_lo=0 ac_mid=0
10862 while :; do
10863 cat >conftest.$ac_ext <<_ACEOF
10864/* confdefs.h. */
10865_ACEOF
10866cat confdefs.h >>conftest.$ac_ext
10867cat >>conftest.$ac_ext <<_ACEOF
10868/* end confdefs.h. */
10869$ac_includes_default
10870int
10871main ()
10872{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010873static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010874test_array [0] = 0
10875
10876 ;
10877 return 0;
10878}
10879_ACEOF
10880rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010881if { (ac_try="$ac_compile"
10882case "(($ac_try" in
10883 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10884 *) ac_try_echo=$ac_try;;
10885esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010886eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10887$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010888 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010889 ac_status=$?
10890 grep -v '^ *+' conftest.er1 >conftest.err
10891 rm -f conftest.er1
10892 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010893 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010894 (exit $ac_status); } && {
10895 test -z "$ac_c_werror_flag" ||
10896 test ! -s conftest.err
10897 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010898 ac_hi=$ac_mid; break
10899else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010900 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010901sed 's/^/| /' conftest.$ac_ext >&5
10902
Martin v. Löwiseba40652007-08-30 20:10:57 +000010903 ac_lo=`expr $ac_mid + 1`
10904 if test $ac_lo -le $ac_mid; then
10905 ac_lo= ac_hi=
10906 break
10907 fi
10908 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis18e16552006-02-15 17:27:45 +000010909fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010910
10911rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010912 done
10913else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010914 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010915sed 's/^/| /' conftest.$ac_ext >&5
10916
Martin v. Löwiseba40652007-08-30 20:10:57 +000010917 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwis18e16552006-02-15 17:27:45 +000010918/* confdefs.h. */
10919_ACEOF
10920cat confdefs.h >>conftest.$ac_ext
10921cat >>conftest.$ac_ext <<_ACEOF
10922/* end confdefs.h. */
10923$ac_includes_default
10924int
10925main ()
10926{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010927static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010928test_array [0] = 0
10929
10930 ;
10931 return 0;
10932}
10933_ACEOF
10934rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010935if { (ac_try="$ac_compile"
10936case "(($ac_try" in
10937 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10938 *) ac_try_echo=$ac_try;;
10939esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010940eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10941$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010942 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010943 ac_status=$?
10944 grep -v '^ *+' conftest.er1 >conftest.err
10945 rm -f conftest.er1
10946 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010947 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010948 (exit $ac_status); } && {
10949 test -z "$ac_c_werror_flag" ||
10950 test ! -s conftest.err
10951 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010952 ac_hi=-1 ac_mid=-1
10953 while :; do
10954 cat >conftest.$ac_ext <<_ACEOF
10955/* confdefs.h. */
10956_ACEOF
10957cat confdefs.h >>conftest.$ac_ext
10958cat >>conftest.$ac_ext <<_ACEOF
10959/* end confdefs.h. */
10960$ac_includes_default
10961int
10962main ()
10963{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010964static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010965test_array [0] = 0
10966
10967 ;
10968 return 0;
10969}
10970_ACEOF
10971rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010972if { (ac_try="$ac_compile"
10973case "(($ac_try" in
10974 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10975 *) ac_try_echo=$ac_try;;
10976esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010977eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10978$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010979 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010980 ac_status=$?
10981 grep -v '^ *+' conftest.er1 >conftest.err
10982 rm -f conftest.er1
10983 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010984 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010985 (exit $ac_status); } && {
10986 test -z "$ac_c_werror_flag" ||
10987 test ! -s conftest.err
10988 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010989 ac_lo=$ac_mid; break
10990else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000010991 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010992sed 's/^/| /' conftest.$ac_ext >&5
10993
Martin v. Löwiseba40652007-08-30 20:10:57 +000010994 ac_hi=`expr '(' $ac_mid ')' - 1`
10995 if test $ac_mid -le $ac_hi; then
10996 ac_lo= ac_hi=
10997 break
10998 fi
10999 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis18e16552006-02-15 17:27:45 +000011000fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011001
11002rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000011003 done
11004else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011005 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011006sed 's/^/| /' conftest.$ac_ext >&5
11007
Martin v. Löwiseba40652007-08-30 20:10:57 +000011008 ac_lo= ac_hi=
Martin v. Löwis18e16552006-02-15 17:27:45 +000011009fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011010
11011rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000011012fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011013
11014rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000011015# Binary search between lo and hi bounds.
11016while test "x$ac_lo" != "x$ac_hi"; do
11017 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11018 cat >conftest.$ac_ext <<_ACEOF
11019/* confdefs.h. */
11020_ACEOF
11021cat confdefs.h >>conftest.$ac_ext
11022cat >>conftest.$ac_ext <<_ACEOF
11023/* end confdefs.h. */
11024$ac_includes_default
11025int
11026main ()
11027{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011028static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000011029test_array [0] = 0
11030
11031 ;
11032 return 0;
11033}
11034_ACEOF
11035rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011036if { (ac_try="$ac_compile"
11037case "(($ac_try" in
11038 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11039 *) ac_try_echo=$ac_try;;
11040esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011041eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11042$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011043 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000011044 ac_status=$?
11045 grep -v '^ *+' conftest.er1 >conftest.err
11046 rm -f conftest.er1
11047 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011048 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011049 (exit $ac_status); } && {
11050 test -z "$ac_c_werror_flag" ||
11051 test ! -s conftest.err
11052 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000011053 ac_hi=$ac_mid
11054else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011055 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011056sed 's/^/| /' conftest.$ac_ext >&5
11057
Martin v. Löwiseba40652007-08-30 20:10:57 +000011058 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis18e16552006-02-15 17:27:45 +000011059fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011060
11061rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000011062done
11063case $ac_lo in
11064?*) ac_cv_sizeof_size_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000011065'') if test "$ac_cv_type_size_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011066 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11067$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11068{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000011069See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011070$as_echo "$as_me: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000011071See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011072 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011073 else
11074 ac_cv_sizeof_size_t=0
11075 fi ;;
Martin v. Löwis18e16552006-02-15 17:27:45 +000011076esac
11077else
Martin v. Löwis18e16552006-02-15 17:27:45 +000011078 cat >conftest.$ac_ext <<_ACEOF
11079/* confdefs.h. */
11080_ACEOF
11081cat confdefs.h >>conftest.$ac_ext
11082cat >>conftest.$ac_ext <<_ACEOF
11083/* end confdefs.h. */
11084$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011085static long int longval () { return (long int) (sizeof (size_t)); }
11086static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
Martin v. Löwis18e16552006-02-15 17:27:45 +000011087#include <stdio.h>
11088#include <stdlib.h>
11089int
11090main ()
11091{
11092
11093 FILE *f = fopen ("conftest.val", "w");
11094 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000011095 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011096 if (((long int) (sizeof (size_t))) < 0)
Martin v. Löwis18e16552006-02-15 17:27:45 +000011097 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011098 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011099 if (i != ((long int) (sizeof (size_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011100 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011101 fprintf (f, "%ld", i);
Martin v. Löwis18e16552006-02-15 17:27:45 +000011102 }
11103 else
11104 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011105 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011106 if (i != ((long int) (sizeof (size_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011107 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011108 fprintf (f, "%lu", i);
Martin v. Löwis18e16552006-02-15 17:27:45 +000011109 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011110 /* Do not output a trailing newline, as this causes \r\n confusion
11111 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000011112 return ferror (f) || fclose (f) != 0;
Martin v. Löwis18e16552006-02-15 17:27:45 +000011113
11114 ;
11115 return 0;
11116}
11117_ACEOF
11118rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011119if { (ac_try="$ac_link"
11120case "(($ac_try" in
11121 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11122 *) ac_try_echo=$ac_try;;
11123esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011124eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11125$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011126 (eval "$ac_link") 2>&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011127 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011128 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011129 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000011130 { (case "(($ac_try" in
11131 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11132 *) ac_try_echo=$ac_try;;
11133esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011134eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11135$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011136 (eval "$ac_try") 2>&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011137 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011138 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011139 (exit $ac_status); }; }; then
11140 ac_cv_sizeof_size_t=`cat conftest.val`
11141else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011142 $as_echo "$as_me: program exited with status $ac_status" >&5
11143$as_echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000011144sed 's/^/| /' conftest.$ac_ext >&5
11145
11146( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000011147if test "$ac_cv_type_size_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011148 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11149$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11150{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000011151See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011152$as_echo "$as_me: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000011153See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011154 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011155 else
11156 ac_cv_sizeof_size_t=0
11157 fi
Martin v. Löwis18e16552006-02-15 17:27:45 +000011158fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011159rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000011160rm -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 +000011161fi
11162rm -f conftest.val
Martin v. Löwis18e16552006-02-15 17:27:45 +000011163fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011164{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
11165$as_echo "$ac_cv_sizeof_size_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011166
11167
11168
Martin v. Löwis18e16552006-02-15 17:27:45 +000011169cat >>confdefs.h <<_ACEOF
11170#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
11171_ACEOF
11172
11173
Christian Heimes951cc0f2008-01-31 23:08:23 +000011174# The cast to long int works around a bug in the HP C Compiler
11175# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11176# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11177# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011178{ $as_echo "$as_me:$LINENO: checking size of pid_t" >&5
11179$as_echo_n "checking size of pid_t... " >&6; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011180if test "${ac_cv_sizeof_pid_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011181 $as_echo_n "(cached) " >&6
Christian Heimes951cc0f2008-01-31 23:08:23 +000011182else
11183 if test "$cross_compiling" = yes; then
11184 # Depending upon the size, compute the lo and hi bounds.
11185cat >conftest.$ac_ext <<_ACEOF
11186/* confdefs.h. */
11187_ACEOF
11188cat confdefs.h >>conftest.$ac_ext
11189cat >>conftest.$ac_ext <<_ACEOF
11190/* end confdefs.h. */
11191$ac_includes_default
Christian Heimes951cc0f2008-01-31 23:08:23 +000011192int
11193main ()
11194{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011195static int test_array [1 - 2 * !(((long int) (sizeof (pid_t))) >= 0)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011196test_array [0] = 0
11197
11198 ;
11199 return 0;
11200}
11201_ACEOF
11202rm -f conftest.$ac_objext
11203if { (ac_try="$ac_compile"
11204case "(($ac_try" in
11205 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11206 *) ac_try_echo=$ac_try;;
11207esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011208eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11209$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011210 (eval "$ac_compile") 2>conftest.er1
11211 ac_status=$?
11212 grep -v '^ *+' conftest.er1 >conftest.err
11213 rm -f conftest.er1
11214 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011215 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011216 (exit $ac_status); } && {
11217 test -z "$ac_c_werror_flag" ||
11218 test ! -s conftest.err
11219 } && test -s conftest.$ac_objext; then
11220 ac_lo=0 ac_mid=0
11221 while :; do
11222 cat >conftest.$ac_ext <<_ACEOF
11223/* confdefs.h. */
11224_ACEOF
11225cat confdefs.h >>conftest.$ac_ext
11226cat >>conftest.$ac_ext <<_ACEOF
11227/* end confdefs.h. */
11228$ac_includes_default
Christian Heimes951cc0f2008-01-31 23:08:23 +000011229int
11230main ()
11231{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011232static int test_array [1 - 2 * !(((long int) (sizeof (pid_t))) <= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011233test_array [0] = 0
11234
11235 ;
11236 return 0;
11237}
11238_ACEOF
11239rm -f conftest.$ac_objext
11240if { (ac_try="$ac_compile"
11241case "(($ac_try" in
11242 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11243 *) ac_try_echo=$ac_try;;
11244esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011245eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11246$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011247 (eval "$ac_compile") 2>conftest.er1
11248 ac_status=$?
11249 grep -v '^ *+' conftest.er1 >conftest.err
11250 rm -f conftest.er1
11251 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011252 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011253 (exit $ac_status); } && {
11254 test -z "$ac_c_werror_flag" ||
11255 test ! -s conftest.err
11256 } && test -s conftest.$ac_objext; then
11257 ac_hi=$ac_mid; break
11258else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011259 $as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011260sed 's/^/| /' conftest.$ac_ext >&5
11261
11262 ac_lo=`expr $ac_mid + 1`
11263 if test $ac_lo -le $ac_mid; then
11264 ac_lo= ac_hi=
11265 break
11266 fi
11267 ac_mid=`expr 2 '*' $ac_mid + 1`
11268fi
11269
11270rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11271 done
11272else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011273 $as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011274sed 's/^/| /' conftest.$ac_ext >&5
11275
11276 cat >conftest.$ac_ext <<_ACEOF
11277/* confdefs.h. */
11278_ACEOF
11279cat confdefs.h >>conftest.$ac_ext
11280cat >>conftest.$ac_ext <<_ACEOF
11281/* end confdefs.h. */
11282$ac_includes_default
Christian Heimes951cc0f2008-01-31 23:08:23 +000011283int
11284main ()
11285{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011286static int test_array [1 - 2 * !(((long int) (sizeof (pid_t))) < 0)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011287test_array [0] = 0
11288
11289 ;
11290 return 0;
11291}
11292_ACEOF
11293rm -f conftest.$ac_objext
11294if { (ac_try="$ac_compile"
11295case "(($ac_try" in
11296 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11297 *) ac_try_echo=$ac_try;;
11298esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011299eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11300$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011301 (eval "$ac_compile") 2>conftest.er1
11302 ac_status=$?
11303 grep -v '^ *+' conftest.er1 >conftest.err
11304 rm -f conftest.er1
11305 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011306 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011307 (exit $ac_status); } && {
11308 test -z "$ac_c_werror_flag" ||
11309 test ! -s conftest.err
11310 } && test -s conftest.$ac_objext; then
11311 ac_hi=-1 ac_mid=-1
11312 while :; do
11313 cat >conftest.$ac_ext <<_ACEOF
11314/* confdefs.h. */
11315_ACEOF
11316cat confdefs.h >>conftest.$ac_ext
11317cat >>conftest.$ac_ext <<_ACEOF
11318/* end confdefs.h. */
11319$ac_includes_default
Christian Heimes951cc0f2008-01-31 23:08:23 +000011320int
11321main ()
11322{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011323static int test_array [1 - 2 * !(((long int) (sizeof (pid_t))) >= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011324test_array [0] = 0
11325
11326 ;
11327 return 0;
11328}
11329_ACEOF
11330rm -f conftest.$ac_objext
11331if { (ac_try="$ac_compile"
11332case "(($ac_try" in
11333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11334 *) ac_try_echo=$ac_try;;
11335esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011336eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11337$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011338 (eval "$ac_compile") 2>conftest.er1
11339 ac_status=$?
11340 grep -v '^ *+' conftest.er1 >conftest.err
11341 rm -f conftest.er1
11342 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011343 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011344 (exit $ac_status); } && {
11345 test -z "$ac_c_werror_flag" ||
11346 test ! -s conftest.err
11347 } && test -s conftest.$ac_objext; then
11348 ac_lo=$ac_mid; break
11349else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011350 $as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011351sed 's/^/| /' conftest.$ac_ext >&5
11352
11353 ac_hi=`expr '(' $ac_mid ')' - 1`
11354 if test $ac_mid -le $ac_hi; then
11355 ac_lo= ac_hi=
11356 break
11357 fi
11358 ac_mid=`expr 2 '*' $ac_mid`
11359fi
11360
11361rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11362 done
11363else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011364 $as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011365sed 's/^/| /' conftest.$ac_ext >&5
11366
11367 ac_lo= ac_hi=
11368fi
11369
11370rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11371fi
11372
11373rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11374# Binary search between lo and hi bounds.
11375while test "x$ac_lo" != "x$ac_hi"; do
11376 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11377 cat >conftest.$ac_ext <<_ACEOF
11378/* confdefs.h. */
11379_ACEOF
11380cat confdefs.h >>conftest.$ac_ext
11381cat >>conftest.$ac_ext <<_ACEOF
11382/* end confdefs.h. */
11383$ac_includes_default
Christian Heimes951cc0f2008-01-31 23:08:23 +000011384int
11385main ()
11386{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011387static int test_array [1 - 2 * !(((long int) (sizeof (pid_t))) <= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011388test_array [0] = 0
11389
11390 ;
11391 return 0;
11392}
11393_ACEOF
11394rm -f conftest.$ac_objext
11395if { (ac_try="$ac_compile"
11396case "(($ac_try" in
11397 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11398 *) ac_try_echo=$ac_try;;
11399esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011400eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11401$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011402 (eval "$ac_compile") 2>conftest.er1
11403 ac_status=$?
11404 grep -v '^ *+' conftest.er1 >conftest.err
11405 rm -f conftest.er1
11406 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011407 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011408 (exit $ac_status); } && {
11409 test -z "$ac_c_werror_flag" ||
11410 test ! -s conftest.err
11411 } && test -s conftest.$ac_objext; then
11412 ac_hi=$ac_mid
11413else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011414 $as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011415sed 's/^/| /' conftest.$ac_ext >&5
11416
11417 ac_lo=`expr '(' $ac_mid ')' + 1`
11418fi
11419
11420rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11421done
11422case $ac_lo in
11423?*) ac_cv_sizeof_pid_t=$ac_lo;;
11424'') if test "$ac_cv_type_pid_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011425 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11426$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11427{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011428See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011429$as_echo "$as_me: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011430See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011431 { (exit 77); exit 77; }; }; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011432 else
11433 ac_cv_sizeof_pid_t=0
11434 fi ;;
11435esac
11436else
11437 cat >conftest.$ac_ext <<_ACEOF
11438/* confdefs.h. */
11439_ACEOF
11440cat confdefs.h >>conftest.$ac_ext
11441cat >>conftest.$ac_ext <<_ACEOF
11442/* end confdefs.h. */
11443$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011444static long int longval () { return (long int) (sizeof (pid_t)); }
11445static unsigned long int ulongval () { return (long int) (sizeof (pid_t)); }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011446#include <stdio.h>
11447#include <stdlib.h>
11448int
11449main ()
11450{
11451
11452 FILE *f = fopen ("conftest.val", "w");
11453 if (! f)
11454 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011455 if (((long int) (sizeof (pid_t))) < 0)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011456 {
11457 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011458 if (i != ((long int) (sizeof (pid_t))))
Christian Heimes951cc0f2008-01-31 23:08:23 +000011459 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011460 fprintf (f, "%ld", i);
Christian Heimes951cc0f2008-01-31 23:08:23 +000011461 }
11462 else
11463 {
11464 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011465 if (i != ((long int) (sizeof (pid_t))))
Christian Heimes951cc0f2008-01-31 23:08:23 +000011466 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011467 fprintf (f, "%lu", i);
Christian Heimes951cc0f2008-01-31 23:08:23 +000011468 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011469 /* Do not output a trailing newline, as this causes \r\n confusion
11470 on some platforms. */
Christian Heimes951cc0f2008-01-31 23:08:23 +000011471 return ferror (f) || fclose (f) != 0;
11472
11473 ;
11474 return 0;
11475}
11476_ACEOF
11477rm -f conftest$ac_exeext
11478if { (ac_try="$ac_link"
11479case "(($ac_try" in
11480 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11481 *) ac_try_echo=$ac_try;;
11482esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011483eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11484$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011485 (eval "$ac_link") 2>&5
11486 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011487 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011488 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11489 { (case "(($ac_try" in
11490 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11491 *) ac_try_echo=$ac_try;;
11492esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011493eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11494$as_echo "$ac_try_echo") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011495 (eval "$ac_try") 2>&5
11496 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011497 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011498 (exit $ac_status); }; }; then
11499 ac_cv_sizeof_pid_t=`cat conftest.val`
11500else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011501 $as_echo "$as_me: program exited with status $ac_status" >&5
11502$as_echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011503sed 's/^/| /' conftest.$ac_ext >&5
11504
11505( exit $ac_status )
11506if test "$ac_cv_type_pid_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011507 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11508$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11509{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011510See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011511$as_echo "$as_me: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011512See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011513 { (exit 77); exit 77; }; }; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011514 else
11515 ac_cv_sizeof_pid_t=0
11516 fi
11517fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011518rm -rf conftest.dSYM
Christian Heimes951cc0f2008-01-31 23:08:23 +000011519rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11520fi
11521rm -f conftest.val
11522fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011523{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_pid_t" >&5
11524$as_echo "$ac_cv_sizeof_pid_t" >&6; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011525
11526
11527
11528cat >>confdefs.h <<_ACEOF
11529#define SIZEOF_PID_T $ac_cv_sizeof_pid_t
11530_ACEOF
11531
11532
Michael W. Hudson54241132001-12-07 15:38:26 +000011533
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011534{ $as_echo "$as_me:$LINENO: checking for long long support" >&5
11535$as_echo_n "checking for long long support... " >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011536have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +000011537cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011538/* confdefs.h. */
11539_ACEOF
11540cat confdefs.h >>conftest.$ac_ext
11541cat >>conftest.$ac_ext <<_ACEOF
11542/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011543
Martin v. Löwis11437992002-04-12 09:54:03 +000011544int
11545main ()
11546{
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011547long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +000011548 ;
11549 return 0;
11550}
11551_ACEOF
11552rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011553if { (ac_try="$ac_compile"
11554case "(($ac_try" in
11555 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11556 *) ac_try_echo=$ac_try;;
11557esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011558eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11559$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011560 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011561 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011562 grep -v '^ *+' conftest.er1 >conftest.err
11563 rm -f conftest.er1
11564 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011565 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011566 (exit $ac_status); } && {
11567 test -z "$ac_c_werror_flag" ||
11568 test ! -s conftest.err
11569 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011570
11571
11572cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011573#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011574_ACEOF
11575
Martin v. Löwisc45929e2002-04-06 10:10:49 +000011576 have_long_long=yes
11577
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011578else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011579 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011580sed 's/^/| /' conftest.$ac_ext >&5
11581
Martin v. Löwiseba40652007-08-30 20:10:57 +000011582
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011583fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011584
11585rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011586{ $as_echo "$as_me:$LINENO: result: $have_long_long" >&5
11587$as_echo "$have_long_long" >&6; }
Guido van Rossum96f2eb91999-04-10 16:02:18 +000011588if test "$have_long_long" = yes ; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000011589# The cast to long int works around a bug in the HP C Compiler
11590# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11591# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11592# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011593{ $as_echo "$as_me:$LINENO: checking size of long long" >&5
11594$as_echo_n "checking size of long long... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000011595if test "${ac_cv_sizeof_long_long+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011596 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000011597else
Martin v. Löwis11437992002-04-12 09:54:03 +000011598 if test "$cross_compiling" = yes; then
11599 # Depending upon the size, compute the lo and hi bounds.
11600cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011601/* confdefs.h. */
11602_ACEOF
11603cat confdefs.h >>conftest.$ac_ext
11604cat >>conftest.$ac_ext <<_ACEOF
11605/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011606$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000011607int
11608main ()
11609{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011610static int test_array [1 - 2 * !(((long int) (sizeof (long long))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011611test_array [0] = 0
11612
11613 ;
11614 return 0;
11615}
11616_ACEOF
11617rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011618if { (ac_try="$ac_compile"
11619case "(($ac_try" in
11620 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11621 *) ac_try_echo=$ac_try;;
11622esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011623eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11624$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011625 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011626 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011627 grep -v '^ *+' conftest.er1 >conftest.err
11628 rm -f conftest.er1
11629 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011630 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011631 (exit $ac_status); } && {
11632 test -z "$ac_c_werror_flag" ||
11633 test ! -s conftest.err
11634 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011635 ac_lo=0 ac_mid=0
11636 while :; do
11637 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011638/* confdefs.h. */
11639_ACEOF
11640cat confdefs.h >>conftest.$ac_ext
11641cat >>conftest.$ac_ext <<_ACEOF
11642/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011643$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000011644int
11645main ()
11646{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011647static int test_array [1 - 2 * !(((long int) (sizeof (long long))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011648test_array [0] = 0
11649
11650 ;
11651 return 0;
11652}
11653_ACEOF
11654rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011655if { (ac_try="$ac_compile"
11656case "(($ac_try" in
11657 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11658 *) ac_try_echo=$ac_try;;
11659esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011660eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11661$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011662 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011663 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011664 grep -v '^ *+' conftest.er1 >conftest.err
11665 rm -f conftest.er1
11666 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011667 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011668 (exit $ac_status); } && {
11669 test -z "$ac_c_werror_flag" ||
11670 test ! -s conftest.err
11671 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011672 ac_hi=$ac_mid; break
11673else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011674 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011675sed 's/^/| /' conftest.$ac_ext >&5
11676
Martin v. Löwiseba40652007-08-30 20:10:57 +000011677 ac_lo=`expr $ac_mid + 1`
11678 if test $ac_lo -le $ac_mid; then
11679 ac_lo= ac_hi=
11680 break
11681 fi
11682 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000011683fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011684
11685rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011686 done
11687else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011688 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011689sed 's/^/| /' conftest.$ac_ext >&5
11690
Martin v. Löwiseba40652007-08-30 20:10:57 +000011691 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011692/* confdefs.h. */
11693_ACEOF
11694cat confdefs.h >>conftest.$ac_ext
11695cat >>conftest.$ac_ext <<_ACEOF
11696/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011697$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000011698int
11699main ()
11700{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011701static int test_array [1 - 2 * !(((long int) (sizeof (long long))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011702test_array [0] = 0
11703
11704 ;
11705 return 0;
11706}
11707_ACEOF
11708rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011709if { (ac_try="$ac_compile"
11710case "(($ac_try" in
11711 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11712 *) ac_try_echo=$ac_try;;
11713esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011714eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11715$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011716 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011717 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011718 grep -v '^ *+' conftest.er1 >conftest.err
11719 rm -f conftest.er1
11720 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011721 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011722 (exit $ac_status); } && {
11723 test -z "$ac_c_werror_flag" ||
11724 test ! -s conftest.err
11725 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011726 ac_hi=-1 ac_mid=-1
11727 while :; do
11728 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011729/* confdefs.h. */
11730_ACEOF
11731cat confdefs.h >>conftest.$ac_ext
11732cat >>conftest.$ac_ext <<_ACEOF
11733/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011734$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000011735int
11736main ()
11737{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011738static int test_array [1 - 2 * !(((long int) (sizeof (long long))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011739test_array [0] = 0
11740
11741 ;
11742 return 0;
11743}
11744_ACEOF
11745rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011746if { (ac_try="$ac_compile"
11747case "(($ac_try" in
11748 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11749 *) ac_try_echo=$ac_try;;
11750esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011751eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11752$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011753 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011754 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011755 grep -v '^ *+' conftest.er1 >conftest.err
11756 rm -f conftest.er1
11757 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011758 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011759 (exit $ac_status); } && {
11760 test -z "$ac_c_werror_flag" ||
11761 test ! -s conftest.err
11762 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011763 ac_lo=$ac_mid; break
11764else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011765 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011766sed 's/^/| /' conftest.$ac_ext >&5
11767
Martin v. Löwiseba40652007-08-30 20:10:57 +000011768 ac_hi=`expr '(' $ac_mid ')' - 1`
11769 if test $ac_mid -le $ac_hi; then
11770 ac_lo= ac_hi=
11771 break
11772 fi
11773 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000011774fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011775
11776rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011777 done
11778else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011779 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011780sed 's/^/| /' conftest.$ac_ext >&5
11781
Martin v. Löwiseba40652007-08-30 20:10:57 +000011782 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000011783fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011784
11785rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011786fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011787
11788rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011789# Binary search between lo and hi bounds.
11790while test "x$ac_lo" != "x$ac_hi"; do
11791 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11792 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011793/* confdefs.h. */
11794_ACEOF
11795cat confdefs.h >>conftest.$ac_ext
11796cat >>conftest.$ac_ext <<_ACEOF
11797/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011798$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000011799int
11800main ()
11801{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011802static int test_array [1 - 2 * !(((long int) (sizeof (long long))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011803test_array [0] = 0
11804
11805 ;
11806 return 0;
11807}
11808_ACEOF
11809rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011810if { (ac_try="$ac_compile"
11811case "(($ac_try" in
11812 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11813 *) ac_try_echo=$ac_try;;
11814esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011815eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11816$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011817 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011818 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011819 grep -v '^ *+' conftest.er1 >conftest.err
11820 rm -f conftest.er1
11821 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011822 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011823 (exit $ac_status); } && {
11824 test -z "$ac_c_werror_flag" ||
11825 test ! -s conftest.err
11826 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011827 ac_hi=$ac_mid
11828else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011829 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011830sed 's/^/| /' conftest.$ac_ext >&5
11831
Martin v. Löwiseba40652007-08-30 20:10:57 +000011832 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000011833fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011834
11835rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011836done
11837case $ac_lo in
11838?*) ac_cv_sizeof_long_long=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000011839'') if test "$ac_cv_type_long_long" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011840 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11841$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11842{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011843See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011844$as_echo "$as_me: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011845See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011846 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011847 else
11848 ac_cv_sizeof_long_long=0
11849 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011850esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011851else
Martin v. Löwis11437992002-04-12 09:54:03 +000011852 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011853/* confdefs.h. */
11854_ACEOF
11855cat confdefs.h >>conftest.$ac_ext
11856cat >>conftest.$ac_ext <<_ACEOF
11857/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011858$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011859static long int longval () { return (long int) (sizeof (long long)); }
11860static unsigned long int ulongval () { return (long int) (sizeof (long long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000011861#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011862#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011863int
11864main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011865{
Martin v. Löwis11437992002-04-12 09:54:03 +000011866
11867 FILE *f = fopen ("conftest.val", "w");
11868 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000011869 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011870 if (((long int) (sizeof (long long))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000011871 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011872 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011873 if (i != ((long int) (sizeof (long long))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011874 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011875 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000011876 }
11877 else
11878 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011879 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011880 if (i != ((long int) (sizeof (long long))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011881 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011882 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000011883 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011884 /* Do not output a trailing newline, as this causes \r\n confusion
11885 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000011886 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000011887
11888 ;
11889 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011890}
Martin v. Löwis11437992002-04-12 09:54:03 +000011891_ACEOF
11892rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011893if { (ac_try="$ac_link"
11894case "(($ac_try" in
11895 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11896 *) ac_try_echo=$ac_try;;
11897esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011898eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11899$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011900 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011901 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011902 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011903 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000011904 { (case "(($ac_try" in
11905 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11906 *) ac_try_echo=$ac_try;;
11907esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011908eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11909$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011910 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011911 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011912 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011913 (exit $ac_status); }; }; then
11914 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011915else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011916 $as_echo "$as_me: program exited with status $ac_status" >&5
11917$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011918sed 's/^/| /' conftest.$ac_ext >&5
11919
Martin v. Löwis11437992002-04-12 09:54:03 +000011920( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000011921if test "$ac_cv_type_long_long" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011922 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11923$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11924{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011925See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011926$as_echo "$as_me: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011927See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011928 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011929 else
11930 ac_cv_sizeof_long_long=0
11931 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011932fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011933rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000011934rm -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 +000011935fi
11936rm -f conftest.val
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011937fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011938{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
11939$as_echo "$ac_cv_sizeof_long_long" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011940
11941
11942
Martin v. Löwis11437992002-04-12 09:54:03 +000011943cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011944#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +000011945_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011946
Michael W. Hudson54241132001-12-07 15:38:26 +000011947
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011948fi
11949
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011950{ $as_echo "$as_me:$LINENO: checking for long double support" >&5
11951$as_echo_n "checking for long double support... " >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011952have_long_double=no
11953cat >conftest.$ac_ext <<_ACEOF
11954/* confdefs.h. */
11955_ACEOF
11956cat confdefs.h >>conftest.$ac_ext
11957cat >>conftest.$ac_ext <<_ACEOF
11958/* end confdefs.h. */
11959
11960int
11961main ()
11962{
11963long double x; x = (long double)0.;
11964 ;
11965 return 0;
11966}
11967_ACEOF
11968rm -f conftest.$ac_objext
11969if { (ac_try="$ac_compile"
11970case "(($ac_try" in
11971 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11972 *) ac_try_echo=$ac_try;;
11973esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011974eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11975$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011976 (eval "$ac_compile") 2>conftest.er1
11977 ac_status=$?
11978 grep -v '^ *+' conftest.er1 >conftest.err
11979 rm -f conftest.er1
11980 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011981 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011982 (exit $ac_status); } && {
11983 test -z "$ac_c_werror_flag" ||
11984 test ! -s conftest.err
11985 } && test -s conftest.$ac_objext; then
11986
11987
11988cat >>confdefs.h <<\_ACEOF
11989#define HAVE_LONG_DOUBLE 1
11990_ACEOF
11991
11992 have_long_double=yes
11993
11994else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000011995 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011996sed 's/^/| /' conftest.$ac_ext >&5
11997
11998
11999fi
12000
12001rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012002{ $as_echo "$as_me:$LINENO: result: $have_long_double" >&5
12003$as_echo "$have_long_double" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012004if test "$have_long_double" = yes ; then
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012005# The cast to long int works around a bug in the HP C Compiler
12006# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12007# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12008# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012009{ $as_echo "$as_me:$LINENO: checking size of long double" >&5
12010$as_echo_n "checking size of long double... " >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012011if test "${ac_cv_sizeof_long_double+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012012 $as_echo_n "(cached) " >&6
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012013else
12014 if test "$cross_compiling" = yes; then
12015 # Depending upon the size, compute the lo and hi bounds.
12016cat >conftest.$ac_ext <<_ACEOF
12017/* confdefs.h. */
12018_ACEOF
12019cat confdefs.h >>conftest.$ac_ext
12020cat >>conftest.$ac_ext <<_ACEOF
12021/* end confdefs.h. */
12022$ac_includes_default
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012023int
12024main ()
12025{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012026static int test_array [1 - 2 * !(((long int) (sizeof (long double))) >= 0)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012027test_array [0] = 0
12028
12029 ;
12030 return 0;
12031}
12032_ACEOF
12033rm -f conftest.$ac_objext
12034if { (ac_try="$ac_compile"
12035case "(($ac_try" in
12036 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12037 *) ac_try_echo=$ac_try;;
12038esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012039eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12040$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012041 (eval "$ac_compile") 2>conftest.er1
12042 ac_status=$?
12043 grep -v '^ *+' conftest.er1 >conftest.err
12044 rm -f conftest.er1
12045 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012046 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012047 (exit $ac_status); } && {
12048 test -z "$ac_c_werror_flag" ||
12049 test ! -s conftest.err
12050 } && test -s conftest.$ac_objext; then
12051 ac_lo=0 ac_mid=0
12052 while :; do
12053 cat >conftest.$ac_ext <<_ACEOF
12054/* confdefs.h. */
12055_ACEOF
12056cat confdefs.h >>conftest.$ac_ext
12057cat >>conftest.$ac_ext <<_ACEOF
12058/* end confdefs.h. */
12059$ac_includes_default
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012060int
12061main ()
12062{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012063static int test_array [1 - 2 * !(((long int) (sizeof (long double))) <= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012064test_array [0] = 0
12065
12066 ;
12067 return 0;
12068}
12069_ACEOF
12070rm -f conftest.$ac_objext
12071if { (ac_try="$ac_compile"
12072case "(($ac_try" in
12073 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12074 *) ac_try_echo=$ac_try;;
12075esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012076eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12077$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012078 (eval "$ac_compile") 2>conftest.er1
12079 ac_status=$?
12080 grep -v '^ *+' conftest.er1 >conftest.err
12081 rm -f conftest.er1
12082 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012083 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012084 (exit $ac_status); } && {
12085 test -z "$ac_c_werror_flag" ||
12086 test ! -s conftest.err
12087 } && test -s conftest.$ac_objext; then
12088 ac_hi=$ac_mid; break
12089else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012090 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012091sed 's/^/| /' conftest.$ac_ext >&5
12092
12093 ac_lo=`expr $ac_mid + 1`
12094 if test $ac_lo -le $ac_mid; then
12095 ac_lo= ac_hi=
12096 break
12097 fi
12098 ac_mid=`expr 2 '*' $ac_mid + 1`
12099fi
12100
12101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12102 done
12103else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012104 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012105sed 's/^/| /' conftest.$ac_ext >&5
12106
12107 cat >conftest.$ac_ext <<_ACEOF
12108/* confdefs.h. */
12109_ACEOF
12110cat confdefs.h >>conftest.$ac_ext
12111cat >>conftest.$ac_ext <<_ACEOF
12112/* end confdefs.h. */
12113$ac_includes_default
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012114int
12115main ()
12116{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012117static int test_array [1 - 2 * !(((long int) (sizeof (long double))) < 0)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012118test_array [0] = 0
12119
12120 ;
12121 return 0;
12122}
12123_ACEOF
12124rm -f conftest.$ac_objext
12125if { (ac_try="$ac_compile"
12126case "(($ac_try" in
12127 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12128 *) ac_try_echo=$ac_try;;
12129esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012130eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12131$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012132 (eval "$ac_compile") 2>conftest.er1
12133 ac_status=$?
12134 grep -v '^ *+' conftest.er1 >conftest.err
12135 rm -f conftest.er1
12136 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012137 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012138 (exit $ac_status); } && {
12139 test -z "$ac_c_werror_flag" ||
12140 test ! -s conftest.err
12141 } && test -s conftest.$ac_objext; then
12142 ac_hi=-1 ac_mid=-1
12143 while :; do
12144 cat >conftest.$ac_ext <<_ACEOF
12145/* confdefs.h. */
12146_ACEOF
12147cat confdefs.h >>conftest.$ac_ext
12148cat >>conftest.$ac_ext <<_ACEOF
12149/* end confdefs.h. */
12150$ac_includes_default
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012151int
12152main ()
12153{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012154static int test_array [1 - 2 * !(((long int) (sizeof (long double))) >= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012155test_array [0] = 0
12156
12157 ;
12158 return 0;
12159}
12160_ACEOF
12161rm -f conftest.$ac_objext
12162if { (ac_try="$ac_compile"
12163case "(($ac_try" in
12164 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12165 *) ac_try_echo=$ac_try;;
12166esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012167eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12168$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012169 (eval "$ac_compile") 2>conftest.er1
12170 ac_status=$?
12171 grep -v '^ *+' conftest.er1 >conftest.err
12172 rm -f conftest.er1
12173 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012174 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012175 (exit $ac_status); } && {
12176 test -z "$ac_c_werror_flag" ||
12177 test ! -s conftest.err
12178 } && test -s conftest.$ac_objext; then
12179 ac_lo=$ac_mid; break
12180else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012181 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012182sed 's/^/| /' conftest.$ac_ext >&5
12183
12184 ac_hi=`expr '(' $ac_mid ')' - 1`
12185 if test $ac_mid -le $ac_hi; then
12186 ac_lo= ac_hi=
12187 break
12188 fi
12189 ac_mid=`expr 2 '*' $ac_mid`
12190fi
12191
12192rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12193 done
12194else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012195 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012196sed 's/^/| /' conftest.$ac_ext >&5
12197
12198 ac_lo= ac_hi=
12199fi
12200
12201rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12202fi
12203
12204rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12205# Binary search between lo and hi bounds.
12206while test "x$ac_lo" != "x$ac_hi"; do
12207 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12208 cat >conftest.$ac_ext <<_ACEOF
12209/* confdefs.h. */
12210_ACEOF
12211cat confdefs.h >>conftest.$ac_ext
12212cat >>conftest.$ac_ext <<_ACEOF
12213/* end confdefs.h. */
12214$ac_includes_default
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012215int
12216main ()
12217{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012218static int test_array [1 - 2 * !(((long int) (sizeof (long double))) <= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012219test_array [0] = 0
12220
12221 ;
12222 return 0;
12223}
12224_ACEOF
12225rm -f conftest.$ac_objext
12226if { (ac_try="$ac_compile"
12227case "(($ac_try" in
12228 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12229 *) ac_try_echo=$ac_try;;
12230esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012231eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12232$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012233 (eval "$ac_compile") 2>conftest.er1
12234 ac_status=$?
12235 grep -v '^ *+' conftest.er1 >conftest.err
12236 rm -f conftest.er1
12237 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012238 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012239 (exit $ac_status); } && {
12240 test -z "$ac_c_werror_flag" ||
12241 test ! -s conftest.err
12242 } && test -s conftest.$ac_objext; then
12243 ac_hi=$ac_mid
12244else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012245 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012246sed 's/^/| /' conftest.$ac_ext >&5
12247
12248 ac_lo=`expr '(' $ac_mid ')' + 1`
12249fi
12250
12251rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12252done
12253case $ac_lo in
12254?*) ac_cv_sizeof_long_double=$ac_lo;;
12255'') if test "$ac_cv_type_long_double" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012256 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
12257$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12258{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012259See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012260$as_echo "$as_me: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012261See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012262 { (exit 77); exit 77; }; }; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012263 else
12264 ac_cv_sizeof_long_double=0
12265 fi ;;
12266esac
12267else
12268 cat >conftest.$ac_ext <<_ACEOF
12269/* confdefs.h. */
12270_ACEOF
12271cat confdefs.h >>conftest.$ac_ext
12272cat >>conftest.$ac_ext <<_ACEOF
12273/* end confdefs.h. */
12274$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012275static long int longval () { return (long int) (sizeof (long double)); }
12276static unsigned long int ulongval () { return (long int) (sizeof (long double)); }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012277#include <stdio.h>
12278#include <stdlib.h>
12279int
12280main ()
12281{
12282
12283 FILE *f = fopen ("conftest.val", "w");
12284 if (! f)
12285 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012286 if (((long int) (sizeof (long double))) < 0)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012287 {
12288 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012289 if (i != ((long int) (sizeof (long double))))
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012290 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012291 fprintf (f, "%ld", i);
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012292 }
12293 else
12294 {
12295 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012296 if (i != ((long int) (sizeof (long double))))
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012297 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012298 fprintf (f, "%lu", i);
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012299 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012300 /* Do not output a trailing newline, as this causes \r\n confusion
12301 on some platforms. */
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012302 return ferror (f) || fclose (f) != 0;
12303
12304 ;
12305 return 0;
12306}
12307_ACEOF
12308rm -f conftest$ac_exeext
12309if { (ac_try="$ac_link"
12310case "(($ac_try" in
12311 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12312 *) ac_try_echo=$ac_try;;
12313esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012314eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12315$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012316 (eval "$ac_link") 2>&5
12317 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012318 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012319 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12320 { (case "(($ac_try" in
12321 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12322 *) ac_try_echo=$ac_try;;
12323esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012324eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12325$as_echo "$ac_try_echo") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012326 (eval "$ac_try") 2>&5
12327 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012328 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012329 (exit $ac_status); }; }; then
12330 ac_cv_sizeof_long_double=`cat conftest.val`
12331else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012332 $as_echo "$as_me: program exited with status $ac_status" >&5
12333$as_echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012334sed 's/^/| /' conftest.$ac_ext >&5
12335
12336( exit $ac_status )
12337if test "$ac_cv_type_long_double" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012338 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
12339$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12340{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012341See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012342$as_echo "$as_me: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012343See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012344 { (exit 77); exit 77; }; }; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012345 else
12346 ac_cv_sizeof_long_double=0
12347 fi
12348fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012349rm -rf conftest.dSYM
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012350rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12351fi
12352rm -f conftest.val
12353fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012354{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_double" >&5
12355$as_echo "$ac_cv_sizeof_long_double" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012356
12357
12358
12359cat >>confdefs.h <<_ACEOF
12360#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
12361_ACEOF
12362
12363
12364fi
12365
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012366{ $as_echo "$as_me:$LINENO: checking for _Bool support" >&5
12367$as_echo_n "checking for _Bool support... " >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012368have_c99_bool=no
12369cat >conftest.$ac_ext <<_ACEOF
12370/* confdefs.h. */
12371_ACEOF
12372cat confdefs.h >>conftest.$ac_ext
12373cat >>conftest.$ac_ext <<_ACEOF
12374/* end confdefs.h. */
12375
12376int
12377main ()
12378{
12379_Bool x; x = (_Bool)0;
12380 ;
12381 return 0;
12382}
12383_ACEOF
12384rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012385if { (ac_try="$ac_compile"
12386case "(($ac_try" in
12387 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12388 *) ac_try_echo=$ac_try;;
12389esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012390eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12391$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012392 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012393 ac_status=$?
12394 grep -v '^ *+' conftest.er1 >conftest.err
12395 rm -f conftest.er1
12396 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012397 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012398 (exit $ac_status); } && {
12399 test -z "$ac_c_werror_flag" ||
12400 test ! -s conftest.err
12401 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012402
12403
12404cat >>confdefs.h <<\_ACEOF
12405#define HAVE_C99_BOOL 1
12406_ACEOF
12407
12408 have_c99_bool=yes
12409
12410else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012411 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012412sed 's/^/| /' conftest.$ac_ext >&5
12413
Martin v. Löwiseba40652007-08-30 20:10:57 +000012414
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012415fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012416
12417rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012418{ $as_echo "$as_me:$LINENO: result: $have_c99_bool" >&5
12419$as_echo "$have_c99_bool" >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012420if test "$have_c99_bool" = yes ; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000012421# The cast to long int works around a bug in the HP C Compiler
12422# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12423# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12424# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012425{ $as_echo "$as_me:$LINENO: checking size of _Bool" >&5
12426$as_echo_n "checking size of _Bool... " >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012427if test "${ac_cv_sizeof__Bool+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012428 $as_echo_n "(cached) " >&6
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012429else
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012430 if test "$cross_compiling" = yes; then
12431 # Depending upon the size, compute the lo and hi bounds.
12432cat >conftest.$ac_ext <<_ACEOF
12433/* confdefs.h. */
12434_ACEOF
12435cat confdefs.h >>conftest.$ac_ext
12436cat >>conftest.$ac_ext <<_ACEOF
12437/* end confdefs.h. */
12438$ac_includes_default
12439int
12440main ()
12441{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012442static int test_array [1 - 2 * !(((long int) (sizeof (_Bool))) >= 0)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012443test_array [0] = 0
12444
12445 ;
12446 return 0;
12447}
12448_ACEOF
12449rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012450if { (ac_try="$ac_compile"
12451case "(($ac_try" in
12452 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12453 *) ac_try_echo=$ac_try;;
12454esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012455eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12456$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012457 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012458 ac_status=$?
12459 grep -v '^ *+' conftest.er1 >conftest.err
12460 rm -f conftest.er1
12461 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012462 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012463 (exit $ac_status); } && {
12464 test -z "$ac_c_werror_flag" ||
12465 test ! -s conftest.err
12466 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012467 ac_lo=0 ac_mid=0
12468 while :; do
12469 cat >conftest.$ac_ext <<_ACEOF
12470/* confdefs.h. */
12471_ACEOF
12472cat confdefs.h >>conftest.$ac_ext
12473cat >>conftest.$ac_ext <<_ACEOF
12474/* end confdefs.h. */
12475$ac_includes_default
12476int
12477main ()
12478{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012479static int test_array [1 - 2 * !(((long int) (sizeof (_Bool))) <= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012480test_array [0] = 0
12481
12482 ;
12483 return 0;
12484}
12485_ACEOF
12486rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012487if { (ac_try="$ac_compile"
12488case "(($ac_try" in
12489 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12490 *) ac_try_echo=$ac_try;;
12491esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012492eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12493$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012494 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012495 ac_status=$?
12496 grep -v '^ *+' conftest.er1 >conftest.err
12497 rm -f conftest.er1
12498 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012499 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012500 (exit $ac_status); } && {
12501 test -z "$ac_c_werror_flag" ||
12502 test ! -s conftest.err
12503 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012504 ac_hi=$ac_mid; break
12505else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012506 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012507sed 's/^/| /' conftest.$ac_ext >&5
12508
Martin v. Löwiseba40652007-08-30 20:10:57 +000012509 ac_lo=`expr $ac_mid + 1`
12510 if test $ac_lo -le $ac_mid; then
12511 ac_lo= ac_hi=
12512 break
12513 fi
12514 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012515fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012516
12517rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012518 done
12519else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012520 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012521sed 's/^/| /' conftest.$ac_ext >&5
12522
Martin v. Löwiseba40652007-08-30 20:10:57 +000012523 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012524/* confdefs.h. */
12525_ACEOF
12526cat confdefs.h >>conftest.$ac_ext
12527cat >>conftest.$ac_ext <<_ACEOF
12528/* end confdefs.h. */
12529$ac_includes_default
12530int
12531main ()
12532{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012533static int test_array [1 - 2 * !(((long int) (sizeof (_Bool))) < 0)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012534test_array [0] = 0
12535
12536 ;
12537 return 0;
12538}
12539_ACEOF
12540rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012541if { (ac_try="$ac_compile"
12542case "(($ac_try" in
12543 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12544 *) ac_try_echo=$ac_try;;
12545esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012546eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12547$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012548 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012549 ac_status=$?
12550 grep -v '^ *+' conftest.er1 >conftest.err
12551 rm -f conftest.er1
12552 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012553 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012554 (exit $ac_status); } && {
12555 test -z "$ac_c_werror_flag" ||
12556 test ! -s conftest.err
12557 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012558 ac_hi=-1 ac_mid=-1
12559 while :; do
12560 cat >conftest.$ac_ext <<_ACEOF
12561/* confdefs.h. */
12562_ACEOF
12563cat confdefs.h >>conftest.$ac_ext
12564cat >>conftest.$ac_ext <<_ACEOF
12565/* end confdefs.h. */
12566$ac_includes_default
12567int
12568main ()
12569{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012570static int test_array [1 - 2 * !(((long int) (sizeof (_Bool))) >= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012571test_array [0] = 0
12572
12573 ;
12574 return 0;
12575}
12576_ACEOF
12577rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012578if { (ac_try="$ac_compile"
12579case "(($ac_try" in
12580 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12581 *) ac_try_echo=$ac_try;;
12582esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012583eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12584$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012585 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012586 ac_status=$?
12587 grep -v '^ *+' conftest.er1 >conftest.err
12588 rm -f conftest.er1
12589 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012590 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012591 (exit $ac_status); } && {
12592 test -z "$ac_c_werror_flag" ||
12593 test ! -s conftest.err
12594 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012595 ac_lo=$ac_mid; break
12596else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012597 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012598sed 's/^/| /' conftest.$ac_ext >&5
12599
Martin v. Löwiseba40652007-08-30 20:10:57 +000012600 ac_hi=`expr '(' $ac_mid ')' - 1`
12601 if test $ac_mid -le $ac_hi; then
12602 ac_lo= ac_hi=
12603 break
12604 fi
12605 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012606fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012607
12608rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012609 done
12610else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012611 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012612sed 's/^/| /' conftest.$ac_ext >&5
12613
Martin v. Löwiseba40652007-08-30 20:10:57 +000012614 ac_lo= ac_hi=
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012615fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012616
12617rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012618fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012619
12620rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012621# Binary search between lo and hi bounds.
12622while test "x$ac_lo" != "x$ac_hi"; do
12623 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12624 cat >conftest.$ac_ext <<_ACEOF
12625/* confdefs.h. */
12626_ACEOF
12627cat confdefs.h >>conftest.$ac_ext
12628cat >>conftest.$ac_ext <<_ACEOF
12629/* end confdefs.h. */
12630$ac_includes_default
12631int
12632main ()
12633{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012634static int test_array [1 - 2 * !(((long int) (sizeof (_Bool))) <= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012635test_array [0] = 0
12636
12637 ;
12638 return 0;
12639}
12640_ACEOF
12641rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012642if { (ac_try="$ac_compile"
12643case "(($ac_try" in
12644 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12645 *) ac_try_echo=$ac_try;;
12646esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012647eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12648$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012649 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012650 ac_status=$?
12651 grep -v '^ *+' conftest.er1 >conftest.err
12652 rm -f conftest.er1
12653 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012654 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012655 (exit $ac_status); } && {
12656 test -z "$ac_c_werror_flag" ||
12657 test ! -s conftest.err
12658 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012659 ac_hi=$ac_mid
12660else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012661 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012662sed 's/^/| /' conftest.$ac_ext >&5
12663
Martin v. Löwiseba40652007-08-30 20:10:57 +000012664 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012665fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012666
12667rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012668done
12669case $ac_lo in
12670?*) ac_cv_sizeof__Bool=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000012671'') if test "$ac_cv_type__Bool" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012672 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
12673$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12674{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012675See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012676$as_echo "$as_me: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012677See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012678 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012679 else
12680 ac_cv_sizeof__Bool=0
12681 fi ;;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012682esac
12683else
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012684 cat >conftest.$ac_ext <<_ACEOF
12685/* confdefs.h. */
12686_ACEOF
12687cat confdefs.h >>conftest.$ac_ext
12688cat >>conftest.$ac_ext <<_ACEOF
12689/* end confdefs.h. */
12690$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012691static long int longval () { return (long int) (sizeof (_Bool)); }
12692static unsigned long int ulongval () { return (long int) (sizeof (_Bool)); }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012693#include <stdio.h>
12694#include <stdlib.h>
12695int
12696main ()
12697{
12698
12699 FILE *f = fopen ("conftest.val", "w");
12700 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000012701 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012702 if (((long int) (sizeof (_Bool))) < 0)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012703 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012704 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012705 if (i != ((long int) (sizeof (_Bool))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012706 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012707 fprintf (f, "%ld", i);
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012708 }
12709 else
12710 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012711 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012712 if (i != ((long int) (sizeof (_Bool))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012713 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012714 fprintf (f, "%lu", i);
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012715 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012716 /* Do not output a trailing newline, as this causes \r\n confusion
12717 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000012718 return ferror (f) || fclose (f) != 0;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012719
12720 ;
12721 return 0;
12722}
12723_ACEOF
12724rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012725if { (ac_try="$ac_link"
12726case "(($ac_try" in
12727 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12728 *) ac_try_echo=$ac_try;;
12729esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012730eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12731$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012732 (eval "$ac_link") 2>&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012733 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012734 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012735 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000012736 { (case "(($ac_try" in
12737 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12738 *) ac_try_echo=$ac_try;;
12739esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012740eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12741$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012742 (eval "$ac_try") 2>&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012743 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012744 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012745 (exit $ac_status); }; }; then
12746 ac_cv_sizeof__Bool=`cat conftest.val`
12747else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012748 $as_echo "$as_me: program exited with status $ac_status" >&5
12749$as_echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012750sed 's/^/| /' conftest.$ac_ext >&5
12751
12752( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000012753if test "$ac_cv_type__Bool" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012754 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
12755$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12756{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012757See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012758$as_echo "$as_me: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012759See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012760 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012761 else
12762 ac_cv_sizeof__Bool=0
12763 fi
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012764fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012765rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000012766rm -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 +000012767fi
12768rm -f conftest.val
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012769fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012770{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof__Bool" >&5
12771$as_echo "$ac_cv_sizeof__Bool" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012772
12773
12774
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012775cat >>confdefs.h <<_ACEOF
12776#define SIZEOF__BOOL $ac_cv_sizeof__Bool
12777_ACEOF
12778
12779
12780fi
12781
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012782{ $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
12783$as_echo_n "checking for uintptr_t... " >&6; }
Martin v. Löwisebe26702006-10-02 14:55:51 +000012784if test "${ac_cv_type_uintptr_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012785 $as_echo_n "(cached) " >&6
Martin v. Löwisebe26702006-10-02 14:55:51 +000012786else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012787 ac_cv_type_uintptr_t=no
12788cat >conftest.$ac_ext <<_ACEOF
12789/* confdefs.h. */
12790_ACEOF
12791cat confdefs.h >>conftest.$ac_ext
12792cat >>conftest.$ac_ext <<_ACEOF
12793/* end confdefs.h. */
12794#ifdef HAVE_STDINT_H
12795 #include <stdint.h>
12796 #endif
12797
12798int
12799main ()
12800{
12801if (sizeof (uintptr_t))
12802 return 0;
12803 ;
12804 return 0;
12805}
12806_ACEOF
12807rm -f conftest.$ac_objext
12808if { (ac_try="$ac_compile"
12809case "(($ac_try" in
12810 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12811 *) ac_try_echo=$ac_try;;
12812esac
12813eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12814$as_echo "$ac_try_echo") >&5
12815 (eval "$ac_compile") 2>conftest.er1
12816 ac_status=$?
12817 grep -v '^ *+' conftest.er1 >conftest.err
12818 rm -f conftest.er1
12819 cat conftest.err >&5
12820 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12821 (exit $ac_status); } && {
12822 test -z "$ac_c_werror_flag" ||
12823 test ! -s conftest.err
12824 } && test -s conftest.$ac_objext; then
Martin v. Löwisebe26702006-10-02 14:55:51 +000012825 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012826/* confdefs.h. */
12827_ACEOF
12828cat confdefs.h >>conftest.$ac_ext
12829cat >>conftest.$ac_ext <<_ACEOF
12830/* end confdefs.h. */
Martin v. Löwis40e9aed2006-10-02 15:20:37 +000012831#ifdef HAVE_STDINT_H
12832 #include <stdint.h>
12833 #endif
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012834
Martin v. Löwis11437992002-04-12 09:54:03 +000012835int
12836main ()
12837{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012838if (sizeof ((uintptr_t)))
12839 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000012840 ;
12841 return 0;
12842}
12843_ACEOF
12844rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012845if { (ac_try="$ac_compile"
12846case "(($ac_try" in
12847 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12848 *) ac_try_echo=$ac_try;;
12849esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012850eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12851$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012852 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012853 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012854 grep -v '^ *+' conftest.er1 >conftest.err
12855 rm -f conftest.er1
12856 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012857 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012858 (exit $ac_status); } && {
12859 test -z "$ac_c_werror_flag" ||
12860 test ! -s conftest.err
12861 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012862 :
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012863else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012864 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012865sed 's/^/| /' conftest.$ac_ext >&5
12866
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012867 ac_cv_type_uintptr_t=yes
12868fi
12869
12870rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12871else
12872 $as_echo "$as_me: failed program was:" >&5
12873sed 's/^/| /' conftest.$ac_ext >&5
12874
12875
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012876fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012877
12878rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebe26702006-10-02 14:55:51 +000012879fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012880{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
12881$as_echo "$ac_cv_type_uintptr_t" >&6; }
12882if test "x$ac_cv_type_uintptr_t" = x""yes; then
Martin v. Löwisebe26702006-10-02 14:55:51 +000012883
12884cat >>confdefs.h <<_ACEOF
12885#define HAVE_UINTPTR_T 1
12886_ACEOF
12887
Martin v. Löwiseba40652007-08-30 20:10:57 +000012888# The cast to long int works around a bug in the HP C Compiler
12889# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12890# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12891# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012892{ $as_echo "$as_me:$LINENO: checking size of uintptr_t" >&5
12893$as_echo_n "checking size of uintptr_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000012894if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012895 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000012896else
Martin v. Löwis11437992002-04-12 09:54:03 +000012897 if test "$cross_compiling" = yes; then
12898 # Depending upon the size, compute the lo and hi bounds.
12899cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012900/* confdefs.h. */
12901_ACEOF
12902cat confdefs.h >>conftest.$ac_ext
12903cat >>conftest.$ac_ext <<_ACEOF
12904/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012905$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000012906int
12907main ()
12908{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012909static int test_array [1 - 2 * !(((long int) (sizeof (uintptr_t))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012910test_array [0] = 0
12911
12912 ;
12913 return 0;
12914}
12915_ACEOF
12916rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012917if { (ac_try="$ac_compile"
12918case "(($ac_try" in
12919 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12920 *) ac_try_echo=$ac_try;;
12921esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012922eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12923$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012924 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012925 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012926 grep -v '^ *+' conftest.er1 >conftest.err
12927 rm -f conftest.er1
12928 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012929 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012930 (exit $ac_status); } && {
12931 test -z "$ac_c_werror_flag" ||
12932 test ! -s conftest.err
12933 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012934 ac_lo=0 ac_mid=0
12935 while :; do
12936 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012937/* confdefs.h. */
12938_ACEOF
12939cat confdefs.h >>conftest.$ac_ext
12940cat >>conftest.$ac_ext <<_ACEOF
12941/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012942$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000012943int
12944main ()
12945{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012946static int test_array [1 - 2 * !(((long int) (sizeof (uintptr_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012947test_array [0] = 0
12948
12949 ;
12950 return 0;
12951}
12952_ACEOF
12953rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012954if { (ac_try="$ac_compile"
12955case "(($ac_try" in
12956 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12957 *) ac_try_echo=$ac_try;;
12958esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012959eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12960$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012961 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012962 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012963 grep -v '^ *+' conftest.er1 >conftest.err
12964 rm -f conftest.er1
12965 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012966 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012967 (exit $ac_status); } && {
12968 test -z "$ac_c_werror_flag" ||
12969 test ! -s conftest.err
12970 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012971 ac_hi=$ac_mid; break
12972else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012973 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012974sed 's/^/| /' conftest.$ac_ext >&5
12975
Martin v. Löwiseba40652007-08-30 20:10:57 +000012976 ac_lo=`expr $ac_mid + 1`
12977 if test $ac_lo -le $ac_mid; then
12978 ac_lo= ac_hi=
12979 break
12980 fi
12981 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000012982fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012983
12984rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012985 done
12986else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000012987 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012988sed 's/^/| /' conftest.$ac_ext >&5
12989
Martin v. Löwiseba40652007-08-30 20:10:57 +000012990 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012991/* confdefs.h. */
12992_ACEOF
12993cat confdefs.h >>conftest.$ac_ext
12994cat >>conftest.$ac_ext <<_ACEOF
12995/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012996$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000012997int
12998main ()
12999{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013000static int test_array [1 - 2 * !(((long int) (sizeof (uintptr_t))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000013001test_array [0] = 0
13002
13003 ;
13004 return 0;
13005}
13006_ACEOF
13007rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013008if { (ac_try="$ac_compile"
13009case "(($ac_try" in
13010 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13011 *) ac_try_echo=$ac_try;;
13012esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013013eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13014$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013015 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013016 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013017 grep -v '^ *+' conftest.er1 >conftest.err
13018 rm -f conftest.er1
13019 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013020 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013021 (exit $ac_status); } && {
13022 test -z "$ac_c_werror_flag" ||
13023 test ! -s conftest.err
13024 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013025 ac_hi=-1 ac_mid=-1
13026 while :; do
13027 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013028/* confdefs.h. */
13029_ACEOF
13030cat confdefs.h >>conftest.$ac_ext
13031cat >>conftest.$ac_ext <<_ACEOF
13032/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013033$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000013034int
13035main ()
13036{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013037static int test_array [1 - 2 * !(((long int) (sizeof (uintptr_t))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000013038test_array [0] = 0
13039
13040 ;
13041 return 0;
13042}
13043_ACEOF
13044rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013045if { (ac_try="$ac_compile"
13046case "(($ac_try" in
13047 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13048 *) ac_try_echo=$ac_try;;
13049esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013050eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13051$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013052 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013053 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013054 grep -v '^ *+' conftest.er1 >conftest.err
13055 rm -f conftest.er1
13056 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013057 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013058 (exit $ac_status); } && {
13059 test -z "$ac_c_werror_flag" ||
13060 test ! -s conftest.err
13061 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013062 ac_lo=$ac_mid; break
13063else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013064 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013065sed 's/^/| /' conftest.$ac_ext >&5
13066
Martin v. Löwiseba40652007-08-30 20:10:57 +000013067 ac_hi=`expr '(' $ac_mid ')' - 1`
13068 if test $ac_mid -le $ac_hi; then
13069 ac_lo= ac_hi=
13070 break
13071 fi
13072 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000013073fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013074
13075rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013076 done
13077else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013078 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013079sed 's/^/| /' conftest.$ac_ext >&5
13080
Martin v. Löwiseba40652007-08-30 20:10:57 +000013081 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000013082fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013083
13084rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013085fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013086
13087rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013088# Binary search between lo and hi bounds.
13089while test "x$ac_lo" != "x$ac_hi"; do
13090 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
13091 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013092/* confdefs.h. */
13093_ACEOF
13094cat confdefs.h >>conftest.$ac_ext
13095cat >>conftest.$ac_ext <<_ACEOF
13096/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013097$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000013098int
13099main ()
13100{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013101static int test_array [1 - 2 * !(((long int) (sizeof (uintptr_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000013102test_array [0] = 0
13103
13104 ;
13105 return 0;
13106}
13107_ACEOF
13108rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013109if { (ac_try="$ac_compile"
13110case "(($ac_try" in
13111 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13112 *) ac_try_echo=$ac_try;;
13113esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013114eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13115$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013116 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013117 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013118 grep -v '^ *+' conftest.er1 >conftest.err
13119 rm -f conftest.er1
13120 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013121 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013122 (exit $ac_status); } && {
13123 test -z "$ac_c_werror_flag" ||
13124 test ! -s conftest.err
13125 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013126 ac_hi=$ac_mid
13127else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013128 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013129sed 's/^/| /' conftest.$ac_ext >&5
13130
Martin v. Löwiseba40652007-08-30 20:10:57 +000013131 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000013132fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013133
13134rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013135done
13136case $ac_lo in
13137?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000013138'') if test "$ac_cv_type_uintptr_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013139 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
13140$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
13141{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000013142See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013143$as_echo "$as_me: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000013144See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013145 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013146 else
13147 ac_cv_sizeof_uintptr_t=0
13148 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000013149esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013150else
Martin v. Löwis11437992002-04-12 09:54:03 +000013151 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013152/* confdefs.h. */
13153_ACEOF
13154cat confdefs.h >>conftest.$ac_ext
13155cat >>conftest.$ac_ext <<_ACEOF
13156/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013157$ac_includes_default
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013158static long int longval () { return (long int) (sizeof (uintptr_t)); }
13159static unsigned long int ulongval () { return (long int) (sizeof (uintptr_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000013160#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013161#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013162int
13163main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013164{
Martin v. Löwis11437992002-04-12 09:54:03 +000013165
13166 FILE *f = fopen ("conftest.val", "w");
13167 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000013168 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013169 if (((long int) (sizeof (uintptr_t))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000013170 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000013171 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013172 if (i != ((long int) (sizeof (uintptr_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000013173 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013174 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000013175 }
13176 else
13177 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000013178 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013179 if (i != ((long int) (sizeof (uintptr_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000013180 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013181 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000013182 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013183 /* Do not output a trailing newline, as this causes \r\n confusion
13184 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000013185 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000013186
13187 ;
13188 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013189}
Martin v. Löwis11437992002-04-12 09:54:03 +000013190_ACEOF
13191rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013192if { (ac_try="$ac_link"
13193case "(($ac_try" in
13194 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13195 *) ac_try_echo=$ac_try;;
13196esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013197eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13198$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013199 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013200 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013201 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013202 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013203 { (case "(($ac_try" in
13204 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13205 *) ac_try_echo=$ac_try;;
13206esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013207eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13208$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013209 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013210 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013211 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013212 (exit $ac_status); }; }; then
13213 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013214else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013215 $as_echo "$as_me: program exited with status $ac_status" >&5
13216$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013217sed 's/^/| /' conftest.$ac_ext >&5
13218
Martin v. Löwis11437992002-04-12 09:54:03 +000013219( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000013220if test "$ac_cv_type_uintptr_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013221 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
13222$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
13223{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000013224See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013225$as_echo "$as_me: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000013226See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013227 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013228 else
13229 ac_cv_sizeof_uintptr_t=0
13230 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013231fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013232rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000013233rm -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 +000013234fi
13235rm -f conftest.val
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013236fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013237{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
13238$as_echo "$ac_cv_sizeof_uintptr_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013239
13240
13241
Martin v. Löwis11437992002-04-12 09:54:03 +000013242cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013243#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013244_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013245
Michael W. Hudson54241132001-12-07 15:38:26 +000013246
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013247fi
13248
Martin v. Löwisebe26702006-10-02 14:55:51 +000013249
13250
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013251# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013252{ $as_echo "$as_me:$LINENO: checking size of off_t" >&5
13253$as_echo_n "checking size of off_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013254if test "${ac_cv_sizeof_off_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013255 $as_echo_n "(cached) " >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013256else
13257 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013258 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013259else
Martin v. Löwis11437992002-04-12 09:54:03 +000013260 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013261/* confdefs.h. */
13262_ACEOF
13263cat confdefs.h >>conftest.$ac_ext
13264cat >>conftest.$ac_ext <<_ACEOF
13265/* end confdefs.h. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013266#include <stdio.h>
13267#include <sys/types.h>
13268main()
13269{
13270 FILE *f=fopen("conftestval", "w");
13271 if (!f) exit(1);
13272 fprintf(f, "%d\n", sizeof(off_t));
13273 exit(0);
13274}
Martin v. Löwis11437992002-04-12 09:54:03 +000013275_ACEOF
13276rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013277if { (ac_try="$ac_link"
13278case "(($ac_try" in
13279 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13280 *) ac_try_echo=$ac_try;;
13281esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013282eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13283$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013284 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013285 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013286 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013287 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013288 { (case "(($ac_try" in
13289 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13290 *) ac_try_echo=$ac_try;;
13291esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013292eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13293$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013294 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013295 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013296 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013297 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013298 ac_cv_sizeof_off_t=`cat conftestval`
13299else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013300 $as_echo "$as_me: program exited with status $ac_status" >&5
13301$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013302sed 's/^/| /' conftest.$ac_ext >&5
13303
Martin v. Löwis11437992002-04-12 09:54:03 +000013304( exit $ac_status )
13305ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013306fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013307rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000013308rm -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 +000013309fi
13310
Martin v. Löwiseba40652007-08-30 20:10:57 +000013311
13312
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013313fi
13314
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013315{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
13316$as_echo "$ac_cv_sizeof_off_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013317
13318cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013319#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013320_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013321
Michael W. Hudson54241132001-12-07 15:38:26 +000013322
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013323{ $as_echo "$as_me:$LINENO: checking whether to enable large file support" >&5
13324$as_echo_n "checking whether to enable large file support... " >&6; }
Guido van Rossum96f2eb91999-04-10 16:02:18 +000013325if test "$have_long_long" = yes -a \
13326 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
13327 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013328
Martin v. Löwis11437992002-04-12 09:54:03 +000013329cat >>confdefs.h <<\_ACEOF
13330#define HAVE_LARGEFILE_SUPPORT 1
13331_ACEOF
13332
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013333 { $as_echo "$as_me:$LINENO: result: yes" >&5
13334$as_echo "yes" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013335else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013336 { $as_echo "$as_me:$LINENO: result: no" >&5
13337$as_echo "no" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013338fi
13339
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013340# AC_CHECK_SIZEOF() doesn't include <time.h>.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013341{ $as_echo "$as_me:$LINENO: checking size of time_t" >&5
13342$as_echo_n "checking size of time_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013343if test "${ac_cv_sizeof_time_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013344 $as_echo_n "(cached) " >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013345else
13346 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013347 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013348else
Martin v. Löwis11437992002-04-12 09:54:03 +000013349 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013350/* confdefs.h. */
13351_ACEOF
13352cat confdefs.h >>conftest.$ac_ext
13353cat >>conftest.$ac_ext <<_ACEOF
13354/* end confdefs.h. */
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013355#include <stdio.h>
13356#include <time.h>
13357main()
13358{
13359 FILE *f=fopen("conftestval", "w");
13360 if (!f) exit(1);
13361 fprintf(f, "%d\n", sizeof(time_t));
13362 exit(0);
13363}
Martin v. Löwis11437992002-04-12 09:54:03 +000013364_ACEOF
13365rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013366if { (ac_try="$ac_link"
13367case "(($ac_try" in
13368 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13369 *) ac_try_echo=$ac_try;;
13370esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013371eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13372$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013373 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013374 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013375 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013376 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013377 { (case "(($ac_try" in
13378 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13379 *) ac_try_echo=$ac_try;;
13380esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013381eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13382$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013383 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013384 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013385 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013386 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013387 ac_cv_sizeof_time_t=`cat conftestval`
13388else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013389 $as_echo "$as_me: program exited with status $ac_status" >&5
13390$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013391sed 's/^/| /' conftest.$ac_ext >&5
13392
Martin v. Löwis11437992002-04-12 09:54:03 +000013393( exit $ac_status )
13394ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013395fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013396rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000013397rm -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 +000013398fi
13399
Martin v. Löwiseba40652007-08-30 20:10:57 +000013400
13401
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013402fi
13403
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013404{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
13405$as_echo "$ac_cv_sizeof_time_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013406
13407cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013408#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013409_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013410
Michael W. Hudson54241132001-12-07 15:38:26 +000013411
13412
Trent Mick635f6fb2000-08-23 21:33:05 +000013413# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013414ac_save_cc="$CC"
13415if test "$ac_cv_kpthread" = "yes"
13416then CC="$CC -Kpthread"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000013417elif test "$ac_cv_kthread" = "yes"
13418then CC="$CC -Kthread"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000013419elif test "$ac_cv_pthread" = "yes"
13420then CC="$CC -pthread"
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013421fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013422{ $as_echo "$as_me:$LINENO: checking for pthread_t" >&5
13423$as_echo_n "checking for pthread_t... " >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000013424have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013425cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013426/* confdefs.h. */
13427_ACEOF
13428cat confdefs.h >>conftest.$ac_ext
13429cat >>conftest.$ac_ext <<_ACEOF
13430/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +000013431#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013432int
13433main ()
13434{
Guido van Rossum12580492000-09-24 16:47:19 +000013435pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +000013436 ;
13437 return 0;
13438}
13439_ACEOF
13440rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013441if { (ac_try="$ac_compile"
13442case "(($ac_try" in
13443 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13444 *) ac_try_echo=$ac_try;;
13445esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013446eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13447$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013448 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013449 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013450 grep -v '^ *+' conftest.er1 >conftest.err
13451 rm -f conftest.er1
13452 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013453 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013454 (exit $ac_status); } && {
13455 test -z "$ac_c_werror_flag" ||
13456 test ! -s conftest.err
13457 } && test -s conftest.$ac_objext; then
Trent Mick635f6fb2000-08-23 21:33:05 +000013458 have_pthread_t=yes
13459else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013460 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013461sed 's/^/| /' conftest.$ac_ext >&5
13462
Martin v. Löwiseba40652007-08-30 20:10:57 +000013463
Trent Mick635f6fb2000-08-23 21:33:05 +000013464fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013465
13466rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013467{ $as_echo "$as_me:$LINENO: result: $have_pthread_t" >&5
13468$as_echo "$have_pthread_t" >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000013469if test "$have_pthread_t" = yes ; then
13470 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013471 { $as_echo "$as_me:$LINENO: checking size of pthread_t" >&5
13472$as_echo_n "checking size of pthread_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013473 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013474 $as_echo_n "(cached) " >&6
Trent Mick635f6fb2000-08-23 21:33:05 +000013475else
13476 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013477 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +000013478else
Martin v. Löwis11437992002-04-12 09:54:03 +000013479 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013480/* confdefs.h. */
13481_ACEOF
13482cat confdefs.h >>conftest.$ac_ext
13483cat >>conftest.$ac_ext <<_ACEOF
13484/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +000013485#include <stdio.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000013486#include <pthread.h>
Trent Mick635f6fb2000-08-23 21:33:05 +000013487 main()
13488 {
13489 FILE *f=fopen("conftestval", "w");
13490 if (!f) exit(1);
13491 fprintf(f, "%d\n", sizeof(pthread_t));
13492 exit(0);
13493 }
Martin v. Löwis11437992002-04-12 09:54:03 +000013494_ACEOF
13495rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013496if { (ac_try="$ac_link"
13497case "(($ac_try" in
13498 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13499 *) ac_try_echo=$ac_try;;
13500esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013501eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13502$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013503 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013504 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013505 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013506 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013507 { (case "(($ac_try" in
13508 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13509 *) ac_try_echo=$ac_try;;
13510esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013511eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13512$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013513 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013514 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013515 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013516 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +000013517 ac_cv_sizeof_pthread_t=`cat conftestval`
13518else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013519 $as_echo "$as_me: program exited with status $ac_status" >&5
13520$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013521sed 's/^/| /' conftest.$ac_ext >&5
13522
Martin v. Löwis11437992002-04-12 09:54:03 +000013523( exit $ac_status )
13524ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +000013525fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013526rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000013527rm -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 +000013528fi
13529
Martin v. Löwiseba40652007-08-30 20:10:57 +000013530
13531
Trent Mick635f6fb2000-08-23 21:33:05 +000013532fi
13533
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013534 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
13535$as_echo "$ac_cv_sizeof_pthread_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013536
13537cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +000013538#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013539_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +000013540
13541fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013542CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +000013543
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013544{ $as_echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
13545$as_echo_n "checking for --enable-toolbox-glue... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013546# Check whether --enable-toolbox-glue was given.
Jack Jansene578a632001-08-15 01:27:14 +000013547if test "${enable_toolbox_glue+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000013548 enableval=$enable_toolbox_glue;
13549fi
Jack Jansene578a632001-08-15 01:27:14 +000013550
13551
13552if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +000013553then
Jack Jansene578a632001-08-15 01:27:14 +000013554 case $ac_sys_system/$ac_sys_release in
13555 Darwin/*)
13556 enable_toolbox_glue="yes";;
13557 *)
13558 enable_toolbox_glue="no";;
13559 esac
13560fi
13561case "$enable_toolbox_glue" in
13562yes)
Jack Jansene578a632001-08-15 01:27:14 +000013563 extra_machdep_objs="Python/mactoolboxglue.o"
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013564 extra_undefs="-u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +000013565
13566cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +000013567#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013568_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +000013569
13570 ;;
13571*)
Jack Jansene578a632001-08-15 01:27:14 +000013572 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +000013573 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +000013574 ;;
13575esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013576{ $as_echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
13577$as_echo "$enable_toolbox_glue" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000013578
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013579
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000013580
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013581case $ac_sys_system/$ac_sys_release in
Anthony Baxter82201742006-04-09 15:07:40 +000013582 Darwin/[01567]\..*)
Bob Ippolito7026a0a2005-03-28 23:23:47 +000013583 OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000"
13584 ;;
13585 Darwin/*)
13586 OTHER_LIBTOOL_OPT=""
13587 ;;
13588esac
13589
13590
13591case $ac_sys_system/$ac_sys_release in
Anthony Baxter82201742006-04-09 15:07:40 +000013592 Darwin/[01567]\..*)
Ronald Oussoren988117f2006-04-29 11:31:35 +000013593 LIBTOOL_CRUFT="-framework System -lcc_dynamic"
13594 if test "${enable_universalsdk}"; then
13595 :
13596 else
13597 LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `arch`"
13598 fi
Jack Jansenb36687a2004-07-16 08:43:47 +000013599 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000013600 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +000013601 Darwin/*)
Bob Ippolito7026a0a2005-03-28 23:23:47 +000013602 gcc_version=`gcc -v 2>&1 | grep version | cut -d\ -f3`
13603 if test ${gcc_version} '<' 4.0
13604 then
13605 LIBTOOL_CRUFT="-lcc_dynamic"
13606 else
13607 LIBTOOL_CRUFT=""
13608 fi
Jack Jansen39fd2312006-02-23 15:12:19 +000013609 LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only `arch`"
Jack Jansenb36687a2004-07-16 08:43:47 +000013610 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013611 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013612esac
13613
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013614{ $as_echo "$as_me:$LINENO: checking for --enable-framework" >&5
13615$as_echo_n "checking for --enable-framework... " >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000013616if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013617then
Skip Montanarodecc6a42003-01-01 20:07:49 +000013618 BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +000013619 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +000013620 # in the build location.
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013621
Martin v. Löwis11437992002-04-12 09:54:03 +000013622cat >>confdefs.h <<\_ACEOF
13623#define WITH_NEXT_FRAMEWORK 1
13624_ACEOF
13625
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013626 { $as_echo "$as_me:$LINENO: result: yes" >&5
13627$as_echo "yes" >&6; }
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013628else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013629 { $as_echo "$as_me:$LINENO: result: no" >&5
13630$as_echo "no" >&6; }
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013631fi
13632
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013633{ $as_echo "$as_me:$LINENO: checking for dyld" >&5
13634$as_echo_n "checking for dyld... " >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013635case $ac_sys_system/$ac_sys_release in
13636 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013637
Martin v. Löwis11437992002-04-12 09:54:03 +000013638cat >>confdefs.h <<\_ACEOF
13639#define WITH_DYLD 1
13640_ACEOF
13641
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013642 { $as_echo "$as_me:$LINENO: result: always on for Darwin" >&5
13643$as_echo "always on for Darwin" >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013644 ;;
13645 *)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013646 { $as_echo "$as_me:$LINENO: result: no" >&5
13647$as_echo "no" >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000013648 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013649esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013650
Guido van Rossum0a516c91994-09-12 10:58:40 +000013651# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +000013652
Michael W. Hudson54241132001-12-07 15:38:26 +000013653
13654
13655
13656
Guido van Rossum0a516c91994-09-12 10:58:40 +000013657# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +000013658# -- usually .so, .sl on HP-UX, .dll on Cygwin
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013659{ $as_echo "$as_me:$LINENO: checking SO" >&5
13660$as_echo_n "checking SO... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013661if test -z "$SO"
13662then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013663 case $ac_sys_system in
Neal Norwitz58e28882006-05-19 07:00:58 +000013664 hp*|HP*)
13665 case `uname -m` in
13666 ia64) SO=.so;;
13667 *) SO=.sl;;
13668 esac
13669 ;;
Guido van Rossumaef734b2001-01-10 21:09:12 +000013670 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +000013671 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013672 esac
Martin v. Löwis368de8f2003-06-14 14:46:38 +000013673else
13674 # this might also be a termcap variable, see #610332
13675 echo
13676 echo '====================================================================='
13677 echo '+ +'
13678 echo '+ WARNING: You have set SO in your environment. +'
13679 echo '+ Do you really mean to change the extension for shared libraries? +'
13680 echo '+ Continuing in 10 seconds to let you to ponder. +'
13681 echo '+ +'
13682 echo '====================================================================='
13683 sleep 10
Guido van Rossum0a516c91994-09-12 10:58:40 +000013684fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013685{ $as_echo "$as_me:$LINENO: result: $SO" >&5
13686$as_echo "$SO" >&6; }
Neal Norwitz58e28882006-05-19 07:00:58 +000013687
Ronald Oussoren79f90492009-01-02 10:44:46 +000013688
Neal Norwitz58e28882006-05-19 07:00:58 +000013689cat >>confdefs.h <<_ACEOF
13690#define SHLIB_EXT "$SO"
13691_ACEOF
13692
Guido van Rossum0a516c91994-09-12 10:58:40 +000013693# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis12af0482004-01-31 12:34:17 +000013694# -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013695# (Shared libraries in this instance are shared modules to be loaded into
13696# Python, as opposed to building Python itself as a shared library.)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013697{ $as_echo "$as_me:$LINENO: checking LDSHARED" >&5
13698$as_echo_n "checking LDSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013699if test -z "$LDSHARED"
13700then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013701 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013702 AIX*)
13703 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +000013704 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013705 ;;
13706 BeOS*)
13707 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +000013708 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013709 ;;
Guido van Rossum07397971997-04-29 21:49:50 +000013710 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +000013711 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Martin v. Löwis11437992002-04-12 09:54:03 +000013712 SunOS/5*)
Greg Ward57c9a662000-05-26 12:22:54 +000013713 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +000013714 then LDSHARED='$(CC) -shared'
Martin v. Löwisaa5afe12002-10-07 06:21:41 +000013715 else LDSHARED='$(CC) -G';
Greg Ward57c9a662000-05-26 12:22:54 +000013716 fi ;;
Thomas Hellerdc96a772008-04-04 10:07:55 +000013717 hp*|HP*)
13718 if test "$GCC" = "yes"
13719 then LDSHARED='$(CC) -shared'
13720 else LDSHARED='ld -b';
13721 fi ;;
Guido van Rossumda88dad1995-01-26 00:46:29 +000013722 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
Jack Jansen418c3b12001-11-14 10:59:57 +000013723 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +000013724 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13725 if test "$enable_framework" ; then
13726 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013727 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13728 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000013729 else
13730 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +000013731 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +000013732 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000013733 Darwin/1.4*|Darwin/5.*|Darwin/6.*)
Jack Jansene578a632001-08-15 01:27:14 +000013734 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13735 if test "$enable_framework" ; then
13736 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013737 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13738 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013739 else
Michael W. Hudson594bc802002-03-07 09:59:15 +000013740 # No framework, use the Python app as bundle-loader
13741 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
Jack Jansenc28fc372003-02-25 13:14:43 +000013742 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013743 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000013744 Darwin/*)
13745 # Use -undefined dynamic_lookup whenever possible (10.3 and later).
13746 # This allows an extension to be used in any Python
Ronald Oussoren38f1b982007-09-02 09:46:07 +000013747
Ronald Oussoren5640ce22008-06-05 12:58:24 +000013748 if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2
Jack Jansen6b08a402004-06-03 12:41:45 +000013749 then
Ronald Oussoren988117f2006-04-29 11:31:35 +000013750 if test "${enable_universalsdk}"; then
Ronald Oussoren5640ce22008-06-05 12:58:24 +000013751 LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}"
Ronald Oussoren988117f2006-04-29 11:31:35 +000013752 fi
Jack Jansen6b08a402004-06-03 12:41:45 +000013753 LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined dynamic_lookup'
13754 BLDSHARED="$LDSHARED"
Jack Jansen6b08a402004-06-03 12:41:45 +000013755 else
13756 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13757 if test "$enable_framework" ; then
13758 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013759 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13760 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansen6b08a402004-06-03 12:41:45 +000013761 else
13762 # No framework, use the Python app as bundle-loader
13763 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
13764 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
13765 fi
13766 fi
13767 ;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +000013768 Linux*|GNU*|QNX*) LDSHARED='$(CC) -shared';;
Guido van Rossum458e7fa1999-09-17 15:40:40 +000013769 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwis222c5152006-06-03 07:37:13 +000013770 FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +000013771 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +000013772 then
Hye-Shik Chang33761492004-10-26 09:53:46 +000013773 LDSHARED="$CC -shared ${LDFLAGS}"
Guido van Rossum0286ae82000-08-29 15:06:49 +000013774 else
13775 LDSHARED="ld -Bshareable ${LDFLAGS}"
13776 fi;;
Martin v. Löwis222c5152006-06-03 07:37:13 +000013777 OpenBSD*)
13778 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
13779 then
13780 LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
13781 else
13782 case `uname -r` in
13783 [01].* | 2.[0-7] | 2.[0-7].*)
13784 LDSHARED="ld -Bshareable ${LDFLAGS}"
13785 ;;
13786 *)
13787 LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
13788 ;;
13789 esac
13790 fi;;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013791 NetBSD*|DragonFly*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013792 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000013793 if test "$GCC" = "yes"
Martin v. Löwis79f3c532002-12-11 12:51:58 +000013794 then LDSHARED='$(CC) -shared'
13795 else LDSHARED='$(CC) -G'
Martin v. Löwisbec19582001-03-21 15:57:54 +000013796 fi;;
Martin v. Löwis79f3c532002-12-11 12:51:58 +000013797 SCO_SV*) LDSHARED='$(CC) -Wl,-G,-Bexport';;
Trent Mick635f6fb2000-08-23 21:33:05 +000013798 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +000013799 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013800 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013801 *) LDSHARED="ld";;
13802 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013803fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013804{ $as_echo "$as_me:$LINENO: result: $LDSHARED" >&5
13805$as_echo "$LDSHARED" >&6; }
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013806BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +000013807# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013808# library (module) -- this is only needed for a few systems
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013809{ $as_echo "$as_me:$LINENO: checking CCSHARED" >&5
13810$as_echo_n "checking CCSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013811if test -z "$CCSHARED"
13812then
Guido van Rossum07397971997-04-29 21:49:50 +000013813 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +000013814 SunOS*) if test "$GCC" = yes;
Martin v. Löwiseb623572007-03-12 10:50:39 +000013815 then CCSHARED="-fPIC";
13816 elif test `uname -p` = sparc;
13817 then CCSHARED="-xcode=pic32";
13818 else CCSHARED="-Kpic";
13819 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +000013820 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +000013821 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +000013822 else CCSHARED="+z";
13823 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000013824 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000013825 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013826 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013827 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000013828 if test "$GCC" = "yes"
13829 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +000013830 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +000013831 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000013832 SCO_SV*)
13833 if test "$GCC" = "yes"
13834 then CCSHARED="-fPIC"
13835 else CCSHARED="-Kpic -belf"
13836 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +000013837 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013838 IRIX*/6*) case $CC in
13839 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +000013840 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013841 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013842 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013843 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013844fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013845{ $as_echo "$as_me:$LINENO: result: $CCSHARED" >&5
13846$as_echo "$CCSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013847# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013848# the python executable -- this is only needed for a few systems
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013849{ $as_echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
13850$as_echo_n "checking LINKFORSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013851if test -z "$LINKFORSHARED"
13852then
Guido van Rossum07397971997-04-29 21:49:50 +000013853 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013854 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +000013855 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +000013856 LINKFORSHARED="-Wl,-E -Wl,+s";;
13857# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000013858 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000013859 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013860 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +000013861 Darwin/*)
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013862 # -u _PyMac_Error is needed to pull in the mac toolbox glue,
13863 # which is
Jack Jansene578a632001-08-15 01:27:14 +000013864 # not used by the core itself but which needs to be in the core so
13865 # that dynamically loaded extension modules have access to it.
Jack Jansen97e3f002003-02-23 22:59:01 +000013866 # -prebind is no longer used, because it actually seems to give a
13867 # slowdown in stead of a speedup, maybe due to the large number of
13868 # dynamic loads Python does.
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013869
13870 LINKFORSHARED="$extra_undefs"
Jack Jansene578a632001-08-15 01:27:14 +000013871 if test "$enable_framework"
13872 then
Jack Jansenda49e192005-01-07 13:08:22 +000013873 LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013874 fi
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013875 LINKFORSHARED="$LINKFORSHARED";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013876 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000013877 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +000013878 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013879 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*)
Guido van Rossumdf693651999-01-07 21:50:41 +000013880 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
13881 then
13882 LINKFORSHARED="-Wl,--export-dynamic"
13883 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013884 SunOS/5*) case $CC in
13885 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +000013886 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +000013887 then
13888 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013889 fi;;
13890 esac;;
Jason Tishler30765592003-09-04 11:04:06 +000013891 CYGWIN*)
13892 if test $enable_shared = "no"
13893 then
13894 LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)'
13895 fi;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +000013896 QNX*)
13897 # -Wl,-E causes the symbols to be added to the dynamic
13898 # symbol table so that they can be found when a module
13899 # is loaded. -N 2048K causes the stack size to be set
13900 # to 2048 kilobytes so that the stack doesn't overflow
13901 # when running test_compile.py.
13902 LINKFORSHARED='-Wl,-E -N 2048K';;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013903 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013904fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013905{ $as_echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
13906$as_echo "$LINKFORSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013907
Michael W. Hudson54241132001-12-07 15:38:26 +000013908
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000013909
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013910{ $as_echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
13911$as_echo_n "checking CFLAGSFORSHARED... " >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013912if test ! "$LIBRARY" = "$LDLIBRARY"
13913then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +000013914 case $ac_sys_system in
13915 CYGWIN*)
13916 # Cygwin needs CCSHARED when building extension DLLs
13917 # but not when building the interpreter DLL.
13918 CFLAGSFORSHARED='';;
13919 *)
13920 CFLAGSFORSHARED='$(CCSHARED)'
13921 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013922fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013923{ $as_echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
13924$as_echo "$CFLAGSFORSHARED" >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013925
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013926# SHLIBS are libraries (except -lc and -lm) to link to the python shared
13927# library (with --enable-shared).
13928# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +000013929# symbols, this must be set to $(LIBS) (expanded by make). We do this even
13930# if it is not required, since it creates a dependency of the shared library
13931# to LIBS. This, in turn, means that applications linking the shared libpython
13932# don't need to link LIBS explicitly. The default should be only changed
13933# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013934
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013935{ $as_echo "$as_me:$LINENO: checking SHLIBS" >&5
13936$as_echo_n "checking SHLIBS... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013937case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013938 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +000013939 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013940esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013941{ $as_echo "$as_me:$LINENO: result: $SHLIBS" >&5
13942$as_echo "$SHLIBS" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013943
13944
Guido van Rossum627b2d71993-12-24 10:39:16 +000013945# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +000013946
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013947{ $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
13948$as_echo_n "checking for dlopen in -ldl... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013949if test "${ac_cv_lib_dl_dlopen+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013950 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013951else
Martin v. Löwis11437992002-04-12 09:54:03 +000013952 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013953LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000013954cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013955/* confdefs.h. */
13956_ACEOF
13957cat confdefs.h >>conftest.$ac_ext
13958cat >>conftest.$ac_ext <<_ACEOF
13959/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013960
Martin v. Löwiseba40652007-08-30 20:10:57 +000013961/* Override any GCC internal prototype to avoid an error.
13962 Use char because int might match the return type of a GCC
13963 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013964#ifdef __cplusplus
13965extern "C"
13966#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013967char dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013968int
13969main ()
13970{
Martin v. Löwiseba40652007-08-30 20:10:57 +000013971return dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013972 ;
13973 return 0;
13974}
13975_ACEOF
13976rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013977if { (ac_try="$ac_link"
13978case "(($ac_try" in
13979 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13980 *) ac_try_echo=$ac_try;;
13981esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013982eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13983$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013984 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013985 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013986 grep -v '^ *+' conftest.er1 >conftest.err
13987 rm -f conftest.er1
13988 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013989 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013990 (exit $ac_status); } && {
13991 test -z "$ac_c_werror_flag" ||
13992 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013993 } && test -s conftest$ac_exeext && {
13994 test "$cross_compiling" = yes ||
13995 $as_test_x conftest$ac_exeext
13996 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013997 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013998else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000013999 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014000sed 's/^/| /' conftest.$ac_ext >&5
14001
Martin v. Löwiseba40652007-08-30 20:10:57 +000014002 ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000014003fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014004
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014005rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014006rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014007 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014008LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000014009fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014010{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
14011$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14012if test "x$ac_cv_lib_dl_dlopen" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014013 cat >>confdefs.h <<_ACEOF
14014#define HAVE_LIBDL 1
14015_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014016
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014017 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014018
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014019fi
14020 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +000014021
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014022{ $as_echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
14023$as_echo_n "checking for shl_load in -ldld... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014024if test "${ac_cv_lib_dld_shl_load+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014025 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014026else
Martin v. Löwis11437992002-04-12 09:54:03 +000014027 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014028LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014029cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014030/* confdefs.h. */
14031_ACEOF
14032cat confdefs.h >>conftest.$ac_ext
14033cat >>conftest.$ac_ext <<_ACEOF
14034/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014035
Martin v. Löwiseba40652007-08-30 20:10:57 +000014036/* Override any GCC internal prototype to avoid an error.
14037 Use char because int might match the return type of a GCC
14038 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014039#ifdef __cplusplus
14040extern "C"
14041#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014042char shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014043int
14044main ()
14045{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014046return shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014047 ;
14048 return 0;
14049}
14050_ACEOF
14051rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014052if { (ac_try="$ac_link"
14053case "(($ac_try" in
14054 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14055 *) ac_try_echo=$ac_try;;
14056esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014057eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14058$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014059 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014060 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014061 grep -v '^ *+' conftest.er1 >conftest.err
14062 rm -f conftest.er1
14063 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014064 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014065 (exit $ac_status); } && {
14066 test -z "$ac_c_werror_flag" ||
14067 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014068 } && test -s conftest$ac_exeext && {
14069 test "$cross_compiling" = yes ||
14070 $as_test_x conftest$ac_exeext
14071 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014072 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014073else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014074 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014075sed 's/^/| /' conftest.$ac_ext >&5
14076
Martin v. Löwiseba40652007-08-30 20:10:57 +000014077 ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000014078fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014079
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014080rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014081rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014082 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014083LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000014084fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014085{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
14086$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14087if test "x$ac_cv_lib_dld_shl_load" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014088 cat >>confdefs.h <<_ACEOF
14089#define HAVE_LIBDLD 1
14090_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014091
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014092 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014093
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014094fi
14095 # Dynamic linking for HP-UX
Martin v. Löwis519adae2003-09-20 10:47:47 +000014096
Ronald Oussoren79f90492009-01-02 10:44:46 +000014097# only check for sem_init if thread support is requested
Martin v. Löwis519adae2003-09-20 10:47:47 +000014098if test "$with_threads" = "yes" -o -z "$with_threads"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014099 { $as_echo "$as_me:$LINENO: checking for library containing sem_init" >&5
14100$as_echo_n "checking for library containing sem_init... " >&6; }
Martin v. Löwis82c19a72002-10-06 11:48:09 +000014101if test "${ac_cv_search_sem_init+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014102 $as_echo_n "(cached) " >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +000014103else
Martin v. Löwis82c19a72002-10-06 11:48:09 +000014104 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +000014105cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014106/* confdefs.h. */
14107_ACEOF
14108cat confdefs.h >>conftest.$ac_ext
14109cat >>conftest.$ac_ext <<_ACEOF
14110/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014111
Martin v. Löwiseba40652007-08-30 20:10:57 +000014112/* Override any GCC internal prototype to avoid an error.
14113 Use char because int might match the return type of a GCC
14114 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014115#ifdef __cplusplus
14116extern "C"
14117#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014118char sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014119int
14120main ()
14121{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014122return sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014123 ;
14124 return 0;
14125}
14126_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000014127for ac_lib in '' pthread rt posix4; do
14128 if test -z "$ac_lib"; then
14129 ac_res="none required"
14130 else
14131 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +000014132 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +000014133 fi
14134 rm -f conftest.$ac_objext conftest$ac_exeext
14135if { (ac_try="$ac_link"
14136case "(($ac_try" in
14137 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14138 *) ac_try_echo=$ac_try;;
14139esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014140eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14141$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014142 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +000014143 ac_status=$?
14144 grep -v '^ *+' conftest.er1 >conftest.err
14145 rm -f conftest.er1
14146 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014147 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014148 (exit $ac_status); } && {
14149 test -z "$ac_c_werror_flag" ||
14150 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014151 } && test -s conftest$ac_exeext && {
14152 test "$cross_compiling" = yes ||
14153 $as_test_x conftest$ac_exeext
14154 }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014155 ac_cv_search_sem_init=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +000014156else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014157 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +000014158sed 's/^/| /' conftest.$ac_ext >&5
14159
Martin v. Löwiseba40652007-08-30 20:10:57 +000014160
Brett Cannon19fab762007-06-02 03:02:29 +000014161fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014162
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014163rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014164rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14165 conftest$ac_exeext
14166 if test "${ac_cv_search_sem_init+set}" = set; then
14167 break
Skip Montanaro89e975f2007-08-22 19:05:21 +000014168fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014169done
14170if test "${ac_cv_search_sem_init+set}" = set; then
14171 :
14172else
14173 ac_cv_search_sem_init=no
14174fi
14175rm conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +000014176LIBS=$ac_func_search_save_LIBS
14177fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014178{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
14179$as_echo "$ac_cv_search_sem_init" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000014180ac_res=$ac_cv_search_sem_init
14181if test "$ac_res" != no; then
14182 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +000014183
Martin v. Löwis41933dd2002-03-21 15:10:58 +000014184fi
Martin v. Löwisd3545ec2003-05-03 11:25:43 +000014185 # 'Real Time' functions on Solaris
Martin v. Löwis519adae2003-09-20 10:47:47 +000014186 # posix4 on Solaris 2.6
14187 # pthread (first!) on Linux
14188fi
14189
Martin v. Löwis19d17342003-06-14 21:03:05 +000014190# check if we need libintl for locale functions
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014191{ $as_echo "$as_me:$LINENO: checking for textdomain in -lintl" >&5
14192$as_echo_n "checking for textdomain in -lintl... " >&6; }
Martin v. Löwis19d17342003-06-14 21:03:05 +000014193if test "${ac_cv_lib_intl_textdomain+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014194 $as_echo_n "(cached) " >&6
Martin v. Löwis19d17342003-06-14 21:03:05 +000014195else
14196 ac_check_lib_save_LIBS=$LIBS
14197LIBS="-lintl $LIBS"
14198cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014199/* confdefs.h. */
14200_ACEOF
14201cat confdefs.h >>conftest.$ac_ext
14202cat >>conftest.$ac_ext <<_ACEOF
14203/* end confdefs.h. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000014204
Martin v. Löwiseba40652007-08-30 20:10:57 +000014205/* Override any GCC internal prototype to avoid an error.
14206 Use char because int might match the return type of a GCC
14207 builtin and then its argument prototype would still apply. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000014208#ifdef __cplusplus
14209extern "C"
14210#endif
Martin v. Löwis19d17342003-06-14 21:03:05 +000014211char textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000014212int
14213main ()
14214{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014215return textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000014216 ;
14217 return 0;
14218}
14219_ACEOF
14220rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014221if { (ac_try="$ac_link"
14222case "(($ac_try" in
14223 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14224 *) ac_try_echo=$ac_try;;
14225esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014226eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14227$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014228 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis19d17342003-06-14 21:03:05 +000014229 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014230 grep -v '^ *+' conftest.er1 >conftest.err
14231 rm -f conftest.er1
14232 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014233 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014234 (exit $ac_status); } && {
14235 test -z "$ac_c_werror_flag" ||
14236 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014237 } && test -s conftest$ac_exeext && {
14238 test "$cross_compiling" = yes ||
14239 $as_test_x conftest$ac_exeext
14240 }; then
Martin v. Löwis19d17342003-06-14 21:03:05 +000014241 ac_cv_lib_intl_textdomain=yes
14242else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014243 $as_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_intl_textdomain=no
Martin v. Löwis19d17342003-06-14 21:03:05 +000014247fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014248
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014249rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014250rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014251 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis19d17342003-06-14 21:03:05 +000014252LIBS=$ac_check_lib_save_LIBS
14253fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014254{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_intl_textdomain" >&5
14255$as_echo "$ac_cv_lib_intl_textdomain" >&6; }
14256if test "x$ac_cv_lib_intl_textdomain" = x""yes; then
Martin v. Löwis19d17342003-06-14 21:03:05 +000014257
14258cat >>confdefs.h <<\_ACEOF
14259#define WITH_LIBINTL 1
14260_ACEOF
14261
14262fi
14263
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014264
14265# checks for system dependent C++ extensions support
14266case "$ac_sys_system" in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014267 AIX*) { $as_echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
14268$as_echo_n "checking for genuine AIX C++ extensions support... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014269 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014270/* confdefs.h. */
14271_ACEOF
14272cat confdefs.h >>conftest.$ac_ext
14273cat >>conftest.$ac_ext <<_ACEOF
14274/* end confdefs.h. */
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014275#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014276int
14277main ()
14278{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014279loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +000014280 ;
14281 return 0;
14282}
14283_ACEOF
14284rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014285if { (ac_try="$ac_link"
14286case "(($ac_try" in
14287 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14288 *) ac_try_echo=$ac_try;;
14289esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014290eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14291$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014292 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014293 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014294 grep -v '^ *+' conftest.er1 >conftest.err
14295 rm -f conftest.er1
14296 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014297 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014298 (exit $ac_status); } && {
14299 test -z "$ac_c_werror_flag" ||
14300 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014301 } && test -s conftest$ac_exeext && {
14302 test "$cross_compiling" = yes ||
14303 $as_test_x conftest$ac_exeext
14304 }; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014305
Martin v. Löwis11437992002-04-12 09:54:03 +000014306cat >>confdefs.h <<\_ACEOF
14307#define AIX_GENUINE_CPLUSPLUS 1
14308_ACEOF
14309
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014310 { $as_echo "$as_me:$LINENO: result: yes" >&5
14311$as_echo "yes" >&6; }
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014312else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014313 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014314sed 's/^/| /' conftest.$ac_ext >&5
14315
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014316 { $as_echo "$as_me:$LINENO: result: no" >&5
14317$as_echo "no" >&6; }
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014318fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014319
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014320rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014321rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014322 conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014323 *) ;;
14324esac
14325
Guido van Rossum70c7f481998-03-26 18:44:10 +000014326# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014327# BeOS' sockets are stashed in libnet.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014328{ $as_echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
14329$as_echo_n "checking for t_open in -lnsl... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014330if test "${ac_cv_lib_nsl_t_open+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014331 $as_echo_n "(cached) " >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014332else
Martin v. Löwis11437992002-04-12 09:54:03 +000014333 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014334LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014335cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014336/* confdefs.h. */
14337_ACEOF
14338cat confdefs.h >>conftest.$ac_ext
14339cat >>conftest.$ac_ext <<_ACEOF
14340/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014341
Martin v. Löwiseba40652007-08-30 20:10:57 +000014342/* Override any GCC internal prototype to avoid an error.
14343 Use char because int might match the return type of a GCC
14344 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014345#ifdef __cplusplus
14346extern "C"
14347#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014348char t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014349int
14350main ()
14351{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014352return t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014353 ;
14354 return 0;
14355}
14356_ACEOF
14357rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014358if { (ac_try="$ac_link"
14359case "(($ac_try" in
14360 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14361 *) ac_try_echo=$ac_try;;
14362esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014363eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14364$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014365 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014366 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014367 grep -v '^ *+' conftest.er1 >conftest.err
14368 rm -f conftest.er1
14369 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014370 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014371 (exit $ac_status); } && {
14372 test -z "$ac_c_werror_flag" ||
14373 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014374 } && test -s conftest$ac_exeext && {
14375 test "$cross_compiling" = yes ||
14376 $as_test_x conftest$ac_exeext
14377 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014378 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014379else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014380 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014381sed 's/^/| /' conftest.$ac_ext >&5
14382
Martin v. Löwiseba40652007-08-30 20:10:57 +000014383 ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014384fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014385
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014386rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014387rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014388 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014389LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014390fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014391{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
14392$as_echo "$ac_cv_lib_nsl_t_open" >&6; }
14393if test "x$ac_cv_lib_nsl_t_open" = x""yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014394 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014395fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +000014396 # SVR4
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014397{ $as_echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
14398$as_echo_n "checking for socket in -lsocket... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014399if test "${ac_cv_lib_socket_socket+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014400 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014401else
Martin v. Löwis11437992002-04-12 09:54:03 +000014402 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014403LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014404cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014405/* confdefs.h. */
14406_ACEOF
14407cat confdefs.h >>conftest.$ac_ext
14408cat >>conftest.$ac_ext <<_ACEOF
14409/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014410
Martin v. Löwiseba40652007-08-30 20:10:57 +000014411/* Override any GCC internal prototype to avoid an error.
14412 Use char because int might match the return type of a GCC
14413 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014414#ifdef __cplusplus
14415extern "C"
14416#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014417char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014418int
14419main ()
14420{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014421return socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014422 ;
14423 return 0;
14424}
14425_ACEOF
14426rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014427if { (ac_try="$ac_link"
14428case "(($ac_try" in
14429 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14430 *) ac_try_echo=$ac_try;;
14431esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014432eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14433$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014434 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014435 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014436 grep -v '^ *+' conftest.er1 >conftest.err
14437 rm -f conftest.er1
14438 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014439 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014440 (exit $ac_status); } && {
14441 test -z "$ac_c_werror_flag" ||
14442 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014443 } && test -s conftest$ac_exeext && {
14444 test "$cross_compiling" = yes ||
14445 $as_test_x conftest$ac_exeext
14446 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014447 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014448else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014449 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014450sed 's/^/| /' conftest.$ac_ext >&5
14451
Martin v. Löwiseba40652007-08-30 20:10:57 +000014452 ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014453fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014454
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014455rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014456rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014457 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014458LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014459fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014460{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
14461$as_echo "$ac_cv_lib_socket_socket" >&6; }
14462if test "x$ac_cv_lib_socket_socket" = x""yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +000014463 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +000014464fi
14465 # SVR4 sockets
Skip Montanarob9949db2004-01-17 04:04:13 +000014466
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +000014467case "$ac_sys_system" in
14468BeOS*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014469{ $as_echo "$as_me:$LINENO: checking for socket in -lnet" >&5
14470$as_echo_n "checking for socket in -lnet... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014471if test "${ac_cv_lib_net_socket+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014472 $as_echo_n "(cached) " >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000014473else
Martin v. Löwis11437992002-04-12 09:54:03 +000014474 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000014475LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014476cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014477/* confdefs.h. */
14478_ACEOF
14479cat confdefs.h >>conftest.$ac_ext
14480cat >>conftest.$ac_ext <<_ACEOF
14481/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014482
Martin v. Löwiseba40652007-08-30 20:10:57 +000014483/* Override any GCC internal prototype to avoid an error.
14484 Use char because int might match the return type of a GCC
14485 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014486#ifdef __cplusplus
14487extern "C"
14488#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014489char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014490int
14491main ()
14492{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014493return socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014494 ;
14495 return 0;
14496}
14497_ACEOF
14498rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014499if { (ac_try="$ac_link"
14500case "(($ac_try" in
14501 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14502 *) ac_try_echo=$ac_try;;
14503esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014504eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14505$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014506 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014507 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014508 grep -v '^ *+' conftest.er1 >conftest.err
14509 rm -f conftest.er1
14510 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014511 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014512 (exit $ac_status); } && {
14513 test -z "$ac_c_werror_flag" ||
14514 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014515 } && test -s conftest$ac_exeext && {
14516 test "$cross_compiling" = yes ||
14517 $as_test_x conftest$ac_exeext
14518 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014519 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000014520else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014521 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014522sed 's/^/| /' conftest.$ac_ext >&5
14523
Martin v. Löwiseba40652007-08-30 20:10:57 +000014524 ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +000014525fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014526
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014527rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000014528rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014529 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014530LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000014531fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014532{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
14533$as_echo "$ac_cv_lib_net_socket" >&6; }
14534if test "x$ac_cv_lib_net_socket" = x""yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014535 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014536fi
14537 # BeOS
14538;;
14539esac
Guido van Rossum70c7f481998-03-26 18:44:10 +000014540
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014541{ $as_echo "$as_me:$LINENO: checking for --with-libs" >&5
14542$as_echo_n "checking for --with-libs... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014543
Martin v. Löwiseba40652007-08-30 20:10:57 +000014544# Check whether --with-libs was given.
Guido van Rossuma68acba1996-07-31 17:36:39 +000014545if test "${with_libs+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014546 withval=$with_libs;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014547{ $as_echo "$as_me:$LINENO: result: $withval" >&5
14548$as_echo "$withval" >&6; }
Guido van Rossuma68acba1996-07-31 17:36:39 +000014549LIBS="$withval $LIBS"
14550
14551else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014552 { $as_echo "$as_me:$LINENO: result: no" >&5
14553$as_echo "no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000014554fi
14555
Guido van Rossum7f43da71994-08-01 12:15:30 +000014556
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014557# Check for use of the system libffi library
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014558{ $as_echo "$as_me:$LINENO: checking for --with-system-ffi" >&5
14559$as_echo_n "checking for --with-system-ffi... " >&6; }
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014560
Martin v. Löwiseba40652007-08-30 20:10:57 +000014561# Check whether --with-system_ffi was given.
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014562if test "${with_system_ffi+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014563 withval=$with_system_ffi;
14564fi
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014565
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014566
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014567{ $as_echo "$as_me:$LINENO: result: $with_system_ffi" >&5
14568$as_echo "$with_system_ffi" >&6; }
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014569
Benjamin Peterson867475c2009-04-29 20:36:25 +000014570# Check for --with-dbmliborder
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014571{ $as_echo "$as_me:$LINENO: checking for --with-dbmliborder" >&5
14572$as_echo_n "checking for --with-dbmliborder... " >&6; }
Benjamin Peterson867475c2009-04-29 20:36:25 +000014573
14574# Check whether --with-dbmliborder was given.
14575if test "${with_dbmliborder+set}" = set; then
14576 withval=$with_dbmliborder;
14577if test x$with_dbmliborder = xyes
14578then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014579{ { $as_echo "$as_me:$LINENO: error: proper usage is --with-dbmliborder=db1:db2:..." >&5
14580$as_echo "$as_me: error: proper usage is --with-dbmliborder=db1:db2:..." >&2;}
Benjamin Peterson867475c2009-04-29 20:36:25 +000014581 { (exit 1); exit 1; }; }
14582else
14583 for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do
14584 if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb
14585 then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014586 { { $as_echo "$as_me:$LINENO: error: proper usage is --with-dbmliborder=db1:db2:..." >&5
14587$as_echo "$as_me: error: proper usage is --with-dbmliborder=db1:db2:..." >&2;}
Benjamin Peterson867475c2009-04-29 20:36:25 +000014588 { (exit 1); exit 1; }; }
14589 fi
14590 done
14591fi
14592fi
14593
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014594{ $as_echo "$as_me:$LINENO: result: $with_dbmliborder" >&5
14595$as_echo "$with_dbmliborder" >&6; }
Benjamin Peterson867475c2009-04-29 20:36:25 +000014596
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000014597# Determine if signalmodule should be used.
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014598
14599
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014600{ $as_echo "$as_me:$LINENO: checking for --with-signal-module" >&5
14601$as_echo_n "checking for --with-signal-module... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014602
Martin v. Löwiseba40652007-08-30 20:10:57 +000014603# Check whether --with-signal-module was given.
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014604if test "${with_signal_module+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014605 withval=$with_signal_module;
14606fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014607
14608
14609if test -z "$with_signal_module"
14610then with_signal_module="yes"
14611fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014612{ $as_echo "$as_me:$LINENO: result: $with_signal_module" >&5
14613$as_echo "$with_signal_module" >&6; }
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014614
14615if test "${with_signal_module}" = "yes"; then
14616 USE_SIGNAL_MODULE=""
14617 SIGNAL_OBJS=""
14618else
14619 USE_SIGNAL_MODULE="#"
14620 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
14621fi
14622
Guido van Rossum3d15bd82001-01-10 18:53:48 +000014623# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +000014624
Barry Warsawc0d24d82000-06-29 16:12:00 +000014625USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +000014626
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014627{ $as_echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
14628$as_echo_n "checking for --with-dec-threads... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014629
Guido van Rossumec2f0731997-01-22 20:54:01 +000014630
Martin v. Löwiseba40652007-08-30 20:10:57 +000014631# Check whether --with-dec-threads was given.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014632if test "${with_dec_threads+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014633 withval=$with_dec_threads;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014634{ $as_echo "$as_me:$LINENO: result: $withval" >&5
14635$as_echo "$withval" >&6; }
Guido van Rossumec2f0731997-01-22 20:54:01 +000014636LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +000014637if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +000014638 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +000014639fi
Guido van Rossumec2f0731997-01-22 20:54:01 +000014640else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014641 { $as_echo "$as_me:$LINENO: result: no" >&5
14642$as_echo "no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000014643fi
14644
Martin v. Löwis11437992002-04-12 09:54:03 +000014645
14646# Templates for things AC_DEFINEd more than once.
14647# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014648
14649
Martin v. Löwis11437992002-04-12 09:54:03 +000014650
14651
14652
14653
14654
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014655{ $as_echo "$as_me:$LINENO: checking for --with-threads" >&5
14656$as_echo_n "checking for --with-threads... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014657
Martin v. Löwiseba40652007-08-30 20:10:57 +000014658# Check whether --with-threads was given.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014659if test "${with_threads+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014660 withval=$with_threads;
14661fi
Guido van Rossumec2f0731997-01-22 20:54:01 +000014662
14663
Barry Warsawc0d24d82000-06-29 16:12:00 +000014664# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +000014665
Martin v. Löwiseba40652007-08-30 20:10:57 +000014666# Check whether --with-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014667if test "${with_thread+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014668 withval=$with_thread; with_threads=$with_thread
14669fi
14670
Barry Warsawc0d24d82000-06-29 16:12:00 +000014671
14672if test -z "$with_threads"
14673then with_threads="yes"
14674fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014675{ $as_echo "$as_me:$LINENO: result: $with_threads" >&5
14676$as_echo "$with_threads" >&6; }
Barry Warsawc0d24d82000-06-29 16:12:00 +000014677
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014678
Barry Warsawc0d24d82000-06-29 16:12:00 +000014679if test "$with_threads" = "no"
14680then
14681 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014682elif test "$ac_cv_pthread_is_default" = yes
14683then
Martin v. Löwis11437992002-04-12 09:54:03 +000014684 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014685#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014686_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014687
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014688 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +000014689 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014690#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014691_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014692
14693 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000014694 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000014695elif test "$ac_cv_kpthread" = "yes"
14696then
14697 CC="$CC -Kpthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014698 if test "$ac_cv_cxx_thread" = "yes"; then
14699 CXX="$CXX -Kpthread"
14700 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014701 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000014702#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014703_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000014704
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000014705 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014706 THREADOBJ="Python/thread.o"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000014707elif test "$ac_cv_kthread" = "yes"
14708then
14709 CC="$CC -Kthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014710 if test "$ac_cv_cxx_thread" = "yes"; then
14711 CXX="$CXX -Kthread"
14712 fi
Martin v. Löwis5f433f02003-05-05 05:05:30 +000014713 cat >>confdefs.h <<\_ACEOF
14714#define WITH_THREAD 1
14715_ACEOF
14716
14717 posix_threads=yes
14718 THREADOBJ="Python/thread.o"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014719elif test "$ac_cv_pthread" = "yes"
14720then
14721 CC="$CC -pthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014722 if test "$ac_cv_cxx_thread" = "yes"; then
14723 CXX="$CXX -pthread"
14724 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014725 cat >>confdefs.h <<\_ACEOF
14726#define WITH_THREAD 1
14727_ACEOF
14728
14729 posix_threads=yes
14730 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000014731else
14732 if test ! -z "$with_threads" -a -d "$with_threads"
14733 then LDFLAGS="$LDFLAGS -L$with_threads"
14734 fi
14735 if test ! -z "$withval" -a -d "$withval"
14736 then LDFLAGS="$LDFLAGS -L$withval"
14737 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014738
14739 # According to the POSIX spec, a pthreads implementation must
Matthias Klosea2542be2004-08-16 11:35:51 +000014740 # define _POSIX_THREADS in unistd.h. Some apparently don't
14741 # (e.g. gnu pth with pthread emulation)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014742 { $as_echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
14743$as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014744 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014745/* confdefs.h. */
14746_ACEOF
14747cat confdefs.h >>conftest.$ac_ext
14748cat >>conftest.$ac_ext <<_ACEOF
14749/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +000014750
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014751#include <unistd.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000014752#ifdef _POSIX_THREADS
14753yes
14754#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014755
14756_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014757if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000014758 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014759 unistd_defines_pthreads=yes
14760else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014761 unistd_defines_pthreads=no
14762fi
14763rm -f conftest*
14764
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014765 { $as_echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
14766$as_echo "$unistd_defines_pthreads" >&6; }
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014767
Martin v. Löwis11437992002-04-12 09:54:03 +000014768 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000014769#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014770_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000014771
Martin v. Löwis11437992002-04-12 09:54:03 +000014772 if test "${ac_cv_header_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014773 { $as_echo "$as_me:$LINENO: checking for cthreads.h" >&5
14774$as_echo_n "checking for cthreads.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014775if test "${ac_cv_header_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014776 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014777fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014778{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
14779$as_echo "$ac_cv_header_cthreads_h" >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014780else
Martin v. Löwis11437992002-04-12 09:54:03 +000014781 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014782{ $as_echo "$as_me:$LINENO: checking cthreads.h usability" >&5
14783$as_echo_n "checking cthreads.h usability... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014784cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014785/* confdefs.h. */
14786_ACEOF
14787cat confdefs.h >>conftest.$ac_ext
14788cat >>conftest.$ac_ext <<_ACEOF
14789/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014790$ac_includes_default
14791#include <cthreads.h>
14792_ACEOF
14793rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014794if { (ac_try="$ac_compile"
14795case "(($ac_try" in
14796 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14797 *) ac_try_echo=$ac_try;;
14798esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014799eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14800$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014801 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014802 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014803 grep -v '^ *+' conftest.er1 >conftest.err
14804 rm -f conftest.er1
14805 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014806 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014807 (exit $ac_status); } && {
14808 test -z "$ac_c_werror_flag" ||
14809 test ! -s conftest.err
14810 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014811 ac_header_compiler=yes
14812else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014813 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014814sed 's/^/| /' conftest.$ac_ext >&5
14815
Martin v. Löwiseba40652007-08-30 20:10:57 +000014816 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014817fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014818
14819rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014820{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14821$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014822
14823# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014824{ $as_echo "$as_me:$LINENO: checking cthreads.h presence" >&5
14825$as_echo_n "checking cthreads.h presence... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014826cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014827/* confdefs.h. */
14828_ACEOF
14829cat confdefs.h >>conftest.$ac_ext
14830cat >>conftest.$ac_ext <<_ACEOF
14831/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014832#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014833_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000014834if { (ac_try="$ac_cpp conftest.$ac_ext"
14835case "(($ac_try" in
14836 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14837 *) ac_try_echo=$ac_try;;
14838esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014839eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14840$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014841 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014842 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000014843 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000014844 rm -f conftest.er1
14845 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014846 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014847 (exit $ac_status); } >/dev/null && {
14848 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14849 test ! -s conftest.err
14850 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014851 ac_header_preproc=yes
14852else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014853 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014854sed 's/^/| /' conftest.$ac_ext >&5
14855
Martin v. Löwis11437992002-04-12 09:54:03 +000014856 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014857fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014858
Martin v. Löwis11437992002-04-12 09:54:03 +000014859rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014860{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14861$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014862
14863# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014864case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14865 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014866 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
14867$as_echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14868 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the compiler's result" >&5
14869$as_echo "$as_me: WARNING: cthreads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000014870 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000014871 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000014872 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014873 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
14874$as_echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
14875 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
14876$as_echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
14877 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: see the Autoconf documentation" >&5
14878$as_echo "$as_me: WARNING: cthreads.h: see the Autoconf documentation" >&2;}
14879 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: section \"Present But Cannot Be Compiled\"" >&5
14880$as_echo "$as_me: WARNING: cthreads.h: section \"Present But Cannot Be Compiled\"" >&2;}
14881 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
14882$as_echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;}
14883 { $as_echo "$as_me:$LINENO: WARNING: cthreads.h: in the future, the compiler will take precedence" >&5
14884$as_echo "$as_me: WARNING: cthreads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000014885 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000014886## -------------------------------------- ##
14887## Report this to http://bugs.python.org/ ##
14888## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000014889_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000014890 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000014891 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000014892esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014893{ $as_echo "$as_me:$LINENO: checking for cthreads.h" >&5
14894$as_echo_n "checking for cthreads.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014895if test "${ac_cv_header_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014896 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014897else
14898 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014899fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014900{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
14901$as_echo "$ac_cv_header_cthreads_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014902
14903fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014904if test "x$ac_cv_header_cthreads_h" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014905 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014906#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014907_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014908
Martin v. Löwis11437992002-04-12 09:54:03 +000014909 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014910#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014911_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014912
Martin v. Löwis11437992002-04-12 09:54:03 +000014913
14914cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014915#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014916_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014917
14918 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014919 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014920else
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014921
Martin v. Löwis11437992002-04-12 09:54:03 +000014922 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014923 { $as_echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
14924$as_echo_n "checking for mach/cthreads.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014925if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014926 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014927fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014928{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
14929$as_echo "$ac_cv_header_mach_cthreads_h" >&6; }
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014930else
Martin v. Löwis11437992002-04-12 09:54:03 +000014931 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014932{ $as_echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
14933$as_echo_n "checking mach/cthreads.h usability... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014934cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014935/* confdefs.h. */
14936_ACEOF
14937cat confdefs.h >>conftest.$ac_ext
14938cat >>conftest.$ac_ext <<_ACEOF
14939/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014940$ac_includes_default
14941#include <mach/cthreads.h>
14942_ACEOF
14943rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014944if { (ac_try="$ac_compile"
14945case "(($ac_try" in
14946 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14947 *) ac_try_echo=$ac_try;;
14948esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014949eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14950$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014951 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014952 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014953 grep -v '^ *+' conftest.er1 >conftest.err
14954 rm -f conftest.er1
14955 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014956 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014957 (exit $ac_status); } && {
14958 test -z "$ac_c_werror_flag" ||
14959 test ! -s conftest.err
14960 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014961 ac_header_compiler=yes
14962else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014963 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014964sed 's/^/| /' conftest.$ac_ext >&5
14965
Martin v. Löwiseba40652007-08-30 20:10:57 +000014966 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014967fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014968
14969rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014970{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14971$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014972
14973# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014974{ $as_echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
14975$as_echo_n "checking mach/cthreads.h presence... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014976cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014977/* confdefs.h. */
14978_ACEOF
14979cat confdefs.h >>conftest.$ac_ext
14980cat >>conftest.$ac_ext <<_ACEOF
14981/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014982#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014983_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000014984if { (ac_try="$ac_cpp conftest.$ac_ext"
14985case "(($ac_try" in
14986 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14987 *) ac_try_echo=$ac_try;;
14988esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014989eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14990$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014991 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014992 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000014993 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000014994 rm -f conftest.er1
14995 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000014996 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014997 (exit $ac_status); } >/dev/null && {
14998 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14999 test ! -s conftest.err
15000 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015001 ac_header_preproc=yes
15002else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015003 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015004sed 's/^/| /' conftest.$ac_ext >&5
15005
Martin v. Löwis11437992002-04-12 09:54:03 +000015006 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015007fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015008
Martin v. Löwis11437992002-04-12 09:54:03 +000015009rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015010{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15011$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015012
15013# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015014case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15015 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015016 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
15017$as_echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15018 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the compiler's result" >&5
15019$as_echo "$as_me: WARNING: mach/cthreads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000015020 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000015021 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015022 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015023 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
15024$as_echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
15025 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
15026$as_echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
15027 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: see the Autoconf documentation" >&5
15028$as_echo "$as_me: WARNING: mach/cthreads.h: see the Autoconf documentation" >&2;}
15029 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: section \"Present But Cannot Be Compiled\"" >&5
15030$as_echo "$as_me: WARNING: mach/cthreads.h: section \"Present But Cannot Be Compiled\"" >&2;}
15031 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
15032$as_echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;}
15033 { $as_echo "$as_me:$LINENO: WARNING: mach/cthreads.h: in the future, the compiler will take precedence" >&5
15034$as_echo "$as_me: WARNING: mach/cthreads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000015035 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000015036## -------------------------------------- ##
15037## Report this to http://bugs.python.org/ ##
15038## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000015039_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000015040 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000015041 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000015042esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015043{ $as_echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
15044$as_echo_n "checking for mach/cthreads.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015045if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015046 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000015047else
15048 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015049fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015050{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
15051$as_echo "$ac_cv_header_mach_cthreads_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015052
15053fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015054if test "x$ac_cv_header_mach_cthreads_h" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015055 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015056#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015057_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015058
Martin v. Löwis11437992002-04-12 09:54:03 +000015059 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015060#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015061_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015062
Martin v. Löwis11437992002-04-12 09:54:03 +000015063
15064cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015065#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015066_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015067
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015068 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000015069else
Guido van Rossum7b3853f1996-07-30 18:09:35 +000015070
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015071 { $as_echo "$as_me:$LINENO: checking for --with-pth" >&5
15072$as_echo_n "checking for --with-pth... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015073
Martin v. Löwiseba40652007-08-30 20:10:57 +000015074# Check whether --with-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +000015075if test "${with_pth+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015076 withval=$with_pth; { $as_echo "$as_me:$LINENO: result: $withval" >&5
15077$as_echo "$withval" >&6; }
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000015078 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000015079#define WITH_THREAD 1
15080_ACEOF
15081
15082
15083cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000015084#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015085_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000015086
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000015087 LIBS="-lpth $LIBS"
15088 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +000015089else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015090 { $as_echo "$as_me:$LINENO: result: no" >&5
15091$as_echo "no" >&6; }
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000015092
15093 # Just looking for pthread_create in libpthread is not enough:
15094 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
15095 # So we really have to include pthread.h, and then link.
15096 _libs=$LIBS
15097 LIBS="$LIBS -lpthread"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015098 { $as_echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
15099$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015100 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015101/* confdefs.h. */
15102_ACEOF
15103cat confdefs.h >>conftest.$ac_ext
15104cat >>conftest.$ac_ext <<_ACEOF
15105/* end confdefs.h. */
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000015106#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000015107
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000015108void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000015109int
15110main ()
15111{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000015112
15113pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000015114 ;
15115 return 0;
15116}
15117_ACEOF
15118rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015119if { (ac_try="$ac_link"
15120case "(($ac_try" in
15121 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15122 *) ac_try_echo=$ac_try;;
15123esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015124eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15125$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015126 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015127 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015128 grep -v '^ *+' conftest.er1 >conftest.err
15129 rm -f conftest.er1
15130 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015131 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015132 (exit $ac_status); } && {
15133 test -z "$ac_c_werror_flag" ||
15134 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015135 } && test -s conftest$ac_exeext && {
15136 test "$cross_compiling" = yes ||
15137 $as_test_x conftest$ac_exeext
15138 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015139
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015140 { $as_echo "$as_me:$LINENO: result: yes" >&5
15141$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015142 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000015143#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015144_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000015145
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000015146 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015147 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000015148else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015149 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015150sed 's/^/| /' conftest.$ac_ext >&5
15151
Martin v. Löwis11437992002-04-12 09:54:03 +000015152
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000015153 LIBS=$_libs
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015154 { $as_echo "$as_me:$LINENO: checking for pthread_detach" >&5
15155$as_echo_n "checking for pthread_detach... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015156if test "${ac_cv_func_pthread_detach+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015157 $as_echo_n "(cached) " >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000015158else
Martin v. Löwis11437992002-04-12 09:54:03 +000015159 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015160/* confdefs.h. */
15161_ACEOF
15162cat confdefs.h >>conftest.$ac_ext
15163cat >>conftest.$ac_ext <<_ACEOF
15164/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015165/* Define pthread_detach to an innocuous variant, in case <limits.h> declares pthread_detach.
15166 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15167#define pthread_detach innocuous_pthread_detach
15168
Guido van Rossumad678af1998-10-02 14:42:15 +000015169/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000015170 which can conflict with char pthread_detach (); below.
15171 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015172 <limits.h> exists even on freestanding compilers. */
15173
15174#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000015175# include <limits.h>
15176#else
15177# include <assert.h>
15178#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015179
15180#undef pthread_detach
15181
Martin v. Löwiseba40652007-08-30 20:10:57 +000015182/* Override any GCC internal prototype to avoid an error.
15183 Use char because int might match the return type of a GCC
15184 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015185#ifdef __cplusplus
15186extern "C"
15187#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015188char pthread_detach ();
Guido van Rossumad678af1998-10-02 14:42:15 +000015189/* The GNU C library defines this for functions which it implements
15190 to always fail with ENOSYS. Some functions are actually named
15191 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000015192#if defined __stub_pthread_detach || defined __stub___pthread_detach
Guido van Rossumad678af1998-10-02 14:42:15 +000015193choke me
Guido van Rossumad678af1998-10-02 14:42:15 +000015194#endif
15195
Skip Montanaro6dead952003-09-25 14:50:04 +000015196int
15197main ()
15198{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015199return pthread_detach ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015200 ;
15201 return 0;
15202}
15203_ACEOF
15204rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015205if { (ac_try="$ac_link"
15206case "(($ac_try" in
15207 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15208 *) ac_try_echo=$ac_try;;
15209esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015210eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15211$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015212 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015213 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015214 grep -v '^ *+' conftest.er1 >conftest.err
15215 rm -f conftest.er1
15216 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015217 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015218 (exit $ac_status); } && {
15219 test -z "$ac_c_werror_flag" ||
15220 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015221 } && test -s conftest$ac_exeext && {
15222 test "$cross_compiling" = yes ||
15223 $as_test_x conftest$ac_exeext
15224 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015225 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000015226else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015227 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015228sed 's/^/| /' conftest.$ac_ext >&5
15229
Martin v. Löwiseba40652007-08-30 20:10:57 +000015230 ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000015231fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015232
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015233rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015234rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015235 conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000015236fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015237{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
15238$as_echo "$ac_cv_func_pthread_detach" >&6; }
15239if test "x$ac_cv_func_pthread_detach" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015240 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000015241#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015242_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000015243
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000015244 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015245 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000015246else
Guido van Rossumad678af1998-10-02 14:42:15 +000015247
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015248 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015249 { $as_echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
15250$as_echo_n "checking for atheos/threads.h... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015251if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015252 $as_echo_n "(cached) " >&6
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015253fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015254{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
15255$as_echo "$ac_cv_header_atheos_threads_h" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015256else
15257 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015258{ $as_echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
15259$as_echo_n "checking atheos/threads.h usability... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015260cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015261/* confdefs.h. */
15262_ACEOF
15263cat confdefs.h >>conftest.$ac_ext
15264cat >>conftest.$ac_ext <<_ACEOF
15265/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015266$ac_includes_default
15267#include <atheos/threads.h>
15268_ACEOF
15269rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015270if { (ac_try="$ac_compile"
15271case "(($ac_try" in
15272 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15273 *) ac_try_echo=$ac_try;;
15274esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015275eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15276$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015277 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015278 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015279 grep -v '^ *+' conftest.er1 >conftest.err
15280 rm -f conftest.er1
15281 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015282 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015283 (exit $ac_status); } && {
15284 test -z "$ac_c_werror_flag" ||
15285 test ! -s conftest.err
15286 } && test -s conftest.$ac_objext; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015287 ac_header_compiler=yes
15288else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015289 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015290sed 's/^/| /' conftest.$ac_ext >&5
15291
Martin v. Löwiseba40652007-08-30 20:10:57 +000015292 ac_header_compiler=no
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015293fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015294
15295rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015296{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15297$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015298
15299# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015300{ $as_echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
15301$as_echo_n "checking atheos/threads.h presence... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015302cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015303/* confdefs.h. */
15304_ACEOF
15305cat confdefs.h >>conftest.$ac_ext
15306cat >>conftest.$ac_ext <<_ACEOF
15307/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015308#include <atheos/threads.h>
15309_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000015310if { (ac_try="$ac_cpp conftest.$ac_ext"
15311case "(($ac_try" in
15312 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15313 *) ac_try_echo=$ac_try;;
15314esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015315eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15316$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015317 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015318 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000015319 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015320 rm -f conftest.er1
15321 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015322 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015323 (exit $ac_status); } >/dev/null && {
15324 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15325 test ! -s conftest.err
15326 }; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015327 ac_header_preproc=yes
15328else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015329 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015330sed 's/^/| /' conftest.$ac_ext >&5
15331
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015332 ac_header_preproc=no
15333fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015334
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015335rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015336{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15337$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015338
15339# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015340case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15341 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015342 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
15343$as_echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15344 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the compiler's result" >&5
15345$as_echo "$as_me: WARNING: atheos/threads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000015346 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000015347 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015348 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015349 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
15350$as_echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
15351 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
15352$as_echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
15353 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: see the Autoconf documentation" >&5
15354$as_echo "$as_me: WARNING: atheos/threads.h: see the Autoconf documentation" >&2;}
15355 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: section \"Present But Cannot Be Compiled\"" >&5
15356$as_echo "$as_me: WARNING: atheos/threads.h: section \"Present But Cannot Be Compiled\"" >&2;}
15357 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
15358$as_echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;}
15359 { $as_echo "$as_me:$LINENO: WARNING: atheos/threads.h: in the future, the compiler will take precedence" >&5
15360$as_echo "$as_me: WARNING: atheos/threads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000015361 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000015362## -------------------------------------- ##
15363## Report this to http://bugs.python.org/ ##
15364## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000015365_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000015366 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000015367 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015368esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015369{ $as_echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
15370$as_echo_n "checking for atheos/threads.h... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015371if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015372 $as_echo_n "(cached) " >&6
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015373else
15374 ac_cv_header_atheos_threads_h=$ac_header_preproc
15375fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015376{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
15377$as_echo "$ac_cv_header_atheos_threads_h" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015378
15379fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015380if test "x$ac_cv_header_atheos_threads_h" = x""yes; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015381 cat >>confdefs.h <<\_ACEOF
15382#define WITH_THREAD 1
15383_ACEOF
15384
15385
15386cat >>confdefs.h <<\_ACEOF
15387#define ATHEOS_THREADS 1
15388_ACEOF
15389
15390 THREADOBJ="Python/thread.o"
15391else
15392
Martin v. Löwis11437992002-04-12 09:54:03 +000015393 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015394 { $as_echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
15395$as_echo_n "checking for kernel/OS.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015396if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015397 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000015398fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015399{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
15400$as_echo "$ac_cv_header_kernel_OS_h" >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015401else
Martin v. Löwis11437992002-04-12 09:54:03 +000015402 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015403{ $as_echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
15404$as_echo_n "checking kernel/OS.h usability... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015405cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015406/* confdefs.h. */
15407_ACEOF
15408cat confdefs.h >>conftest.$ac_ext
15409cat >>conftest.$ac_ext <<_ACEOF
15410/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015411$ac_includes_default
15412#include <kernel/OS.h>
15413_ACEOF
15414rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015415if { (ac_try="$ac_compile"
15416case "(($ac_try" in
15417 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15418 *) ac_try_echo=$ac_try;;
15419esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015420eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15421$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015422 (eval "$ac_compile") 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
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015427 $as_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
15431 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015432 ac_header_compiler=yes
15433else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015434 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015435sed 's/^/| /' conftest.$ac_ext >&5
15436
Martin v. Löwiseba40652007-08-30 20:10:57 +000015437 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015438fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015439
15440rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015441{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15442$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015443
15444# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015445{ $as_echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
15446$as_echo_n "checking kernel/OS.h presence... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015447cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015448/* confdefs.h. */
15449_ACEOF
15450cat confdefs.h >>conftest.$ac_ext
15451cat >>conftest.$ac_ext <<_ACEOF
15452/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015453#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015454_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000015455if { (ac_try="$ac_cpp conftest.$ac_ext"
15456case "(($ac_try" in
15457 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15458 *) ac_try_echo=$ac_try;;
15459esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015460eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15461$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015462 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015463 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000015464 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000015465 rm -f conftest.er1
15466 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015467 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015468 (exit $ac_status); } >/dev/null && {
15469 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15470 test ! -s conftest.err
15471 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015472 ac_header_preproc=yes
15473else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015474 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015475sed 's/^/| /' conftest.$ac_ext >&5
15476
Martin v. Löwis11437992002-04-12 09:54:03 +000015477 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015478fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015479
Martin v. Löwis11437992002-04-12 09:54:03 +000015480rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015481{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15482$as_echo "$ac_header_preproc" >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015483
Martin v. Löwis11437992002-04-12 09:54:03 +000015484# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015485case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15486 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015487 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
15488$as_echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15489 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the compiler's result" >&5
15490$as_echo "$as_me: WARNING: kernel/OS.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000015491 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000015492 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015493 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015494 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
15495$as_echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
15496 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
15497$as_echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
15498 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: see the Autoconf documentation" >&5
15499$as_echo "$as_me: WARNING: kernel/OS.h: see the Autoconf documentation" >&2;}
15500 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: section \"Present But Cannot Be Compiled\"" >&5
15501$as_echo "$as_me: WARNING: kernel/OS.h: section \"Present But Cannot Be Compiled\"" >&2;}
15502 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
15503$as_echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;}
15504 { $as_echo "$as_me:$LINENO: WARNING: kernel/OS.h: in the future, the compiler will take precedence" >&5
15505$as_echo "$as_me: WARNING: kernel/OS.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000015506 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000015507## -------------------------------------- ##
15508## Report this to http://bugs.python.org/ ##
15509## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000015510_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000015511 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000015512 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000015513esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015514{ $as_echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
15515$as_echo_n "checking for kernel/OS.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015516if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015517 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000015518else
15519 ac_cv_header_kernel_OS_h=$ac_header_preproc
15520fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015521{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
15522$as_echo "$ac_cv_header_kernel_OS_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015523
15524fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015525if test "x$ac_cv_header_kernel_OS_h" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015526 cat >>confdefs.h <<\_ACEOF
15527#define WITH_THREAD 1
15528_ACEOF
15529
15530
15531cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015532#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015533_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015534
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015535 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015536else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015537
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015538 { $as_echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
15539$as_echo_n "checking for pthread_create in -lpthreads... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015540if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015541 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015542else
Martin v. Löwis11437992002-04-12 09:54:03 +000015543 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015544LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015545cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015546/* confdefs.h. */
15547_ACEOF
15548cat confdefs.h >>conftest.$ac_ext
15549cat >>conftest.$ac_ext <<_ACEOF
15550/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015551
Martin v. Löwiseba40652007-08-30 20:10:57 +000015552/* Override any GCC internal prototype to avoid an error.
15553 Use char because int might match the return type of a GCC
15554 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015555#ifdef __cplusplus
15556extern "C"
15557#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015558char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015559int
15560main ()
15561{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015562return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015563 ;
15564 return 0;
15565}
15566_ACEOF
15567rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015568if { (ac_try="$ac_link"
15569case "(($ac_try" in
15570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15571 *) ac_try_echo=$ac_try;;
15572esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015573eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15574$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015575 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015576 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015577 grep -v '^ *+' conftest.er1 >conftest.err
15578 rm -f conftest.er1
15579 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015580 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015581 (exit $ac_status); } && {
15582 test -z "$ac_c_werror_flag" ||
15583 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015584 } && test -s conftest$ac_exeext && {
15585 test "$cross_compiling" = yes ||
15586 $as_test_x conftest$ac_exeext
15587 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015588 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000015589else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015590 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015591sed 's/^/| /' conftest.$ac_ext >&5
15592
Martin v. Löwiseba40652007-08-30 20:10:57 +000015593 ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000015594fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015595
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015596rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015597rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015598 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015599LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000015600fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015601{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
15602$as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; }
15603if test "x$ac_cv_lib_pthreads_pthread_create" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015604 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000015605#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015606_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000015607
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015608 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015609 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015610 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000015611else
Greg Steinadf63d62000-07-05 10:38:09 +000015612
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015613 { $as_echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
15614$as_echo_n "checking for pthread_create in -lc_r... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015615if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015616 $as_echo_n "(cached) " >&6
Greg Steinadf63d62000-07-05 10:38:09 +000015617else
Martin v. Löwis11437992002-04-12 09:54:03 +000015618 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000015619LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015620cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015621/* confdefs.h. */
15622_ACEOF
15623cat confdefs.h >>conftest.$ac_ext
15624cat >>conftest.$ac_ext <<_ACEOF
15625/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015626
Martin v. Löwiseba40652007-08-30 20:10:57 +000015627/* Override any GCC internal prototype to avoid an error.
15628 Use char because int might match the return type of a GCC
15629 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015630#ifdef __cplusplus
15631extern "C"
15632#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015633char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015634int
15635main ()
15636{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015637return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015638 ;
15639 return 0;
15640}
15641_ACEOF
15642rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015643if { (ac_try="$ac_link"
15644case "(($ac_try" in
15645 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15646 *) ac_try_echo=$ac_try;;
15647esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015648eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15649$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015650 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015651 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015652 grep -v '^ *+' conftest.er1 >conftest.err
15653 rm -f conftest.er1
15654 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015655 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015656 (exit $ac_status); } && {
15657 test -z "$ac_c_werror_flag" ||
15658 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015659 } && test -s conftest$ac_exeext && {
15660 test "$cross_compiling" = yes ||
15661 $as_test_x conftest$ac_exeext
15662 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015663 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000015664else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015665 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015666sed 's/^/| /' conftest.$ac_ext >&5
15667
Martin v. Löwiseba40652007-08-30 20:10:57 +000015668 ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000015669fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015670
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015671rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015672rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015673 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015674LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000015675fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015676{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
15677$as_echo "$ac_cv_lib_c_r_pthread_create" >&6; }
15678if test "x$ac_cv_lib_c_r_pthread_create" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015679 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000015680#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015681_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000015682
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015683 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015684 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015685 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015686else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015687
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015688 { $as_echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
15689$as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015690if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015691 $as_echo_n "(cached) " >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015692else
Martin v. Löwis11437992002-04-12 09:54:03 +000015693 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015694LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015695cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015696/* confdefs.h. */
15697_ACEOF
15698cat confdefs.h >>conftest.$ac_ext
15699cat >>conftest.$ac_ext <<_ACEOF
15700/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015701
Martin v. Löwiseba40652007-08-30 20:10:57 +000015702/* Override any GCC internal prototype to avoid an error.
15703 Use char because int might match the return type of a GCC
15704 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015705#ifdef __cplusplus
15706extern "C"
15707#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015708char __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015709int
15710main ()
15711{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015712return __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015713 ;
15714 return 0;
15715}
15716_ACEOF
15717rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015718if { (ac_try="$ac_link"
15719case "(($ac_try" in
15720 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15721 *) ac_try_echo=$ac_try;;
15722esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015723eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15724$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015725 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015726 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015727 grep -v '^ *+' conftest.er1 >conftest.err
15728 rm -f conftest.er1
15729 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015730 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015731 (exit $ac_status); } && {
15732 test -z "$ac_c_werror_flag" ||
15733 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015734 } && test -s conftest$ac_exeext && {
15735 test "$cross_compiling" = yes ||
15736 $as_test_x conftest$ac_exeext
15737 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015738 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015739else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015740 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015741sed 's/^/| /' conftest.$ac_ext >&5
15742
Martin v. Löwiseba40652007-08-30 20:10:57 +000015743 ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015744fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015745
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015746rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015747rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015748 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015749LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015750fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015751{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
15752$as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; }
15753if test "x$ac_cv_lib_pthread___pthread_create_system" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015754 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015755#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015756_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015757
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015758 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015759 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015760 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015761else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015762
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015763 { $as_echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
15764$as_echo_n "checking for pthread_create in -lcma... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015765if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015766 $as_echo_n "(cached) " >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000015767else
Martin v. Löwis11437992002-04-12 09:54:03 +000015768 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000015769LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015770cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015771/* confdefs.h. */
15772_ACEOF
15773cat confdefs.h >>conftest.$ac_ext
15774cat >>conftest.$ac_ext <<_ACEOF
15775/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015776
Martin v. Löwiseba40652007-08-30 20:10:57 +000015777/* Override any GCC internal prototype to avoid an error.
15778 Use char because int might match the return type of a GCC
15779 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015780#ifdef __cplusplus
15781extern "C"
15782#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015783char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015784int
15785main ()
15786{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015787return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015788 ;
15789 return 0;
15790}
15791_ACEOF
15792rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015793if { (ac_try="$ac_link"
15794case "(($ac_try" in
15795 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15796 *) ac_try_echo=$ac_try;;
15797esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015798eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15799$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015800 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015801 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015802 grep -v '^ *+' conftest.er1 >conftest.err
15803 rm -f conftest.er1
15804 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015805 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015806 (exit $ac_status); } && {
15807 test -z "$ac_c_werror_flag" ||
15808 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015809 } && test -s conftest$ac_exeext && {
15810 test "$cross_compiling" = yes ||
15811 $as_test_x conftest$ac_exeext
15812 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015813 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000015814else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015815 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015816sed 's/^/| /' conftest.$ac_ext >&5
15817
Martin v. Löwiseba40652007-08-30 20:10:57 +000015818 ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000015819fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015820
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015821rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015822rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015823 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015824LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000015825fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015826{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
15827$as_echo "$ac_cv_lib_cma_pthread_create" >&6; }
15828if test "x$ac_cv_lib_cma_pthread_create" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015829 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000015830#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015831_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000015832
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015833 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015834 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015835 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000015836else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000015837
Martin v. Löwis130fb172001-07-19 11:00:41 +000015838 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000015839fi
15840
Guido van Rossum627b2d71993-12-24 10:39:16 +000015841
Guido van Rossum7b3853f1996-07-30 18:09:35 +000015842fi
15843
Guido van Rossum0be3e491997-05-22 20:33:33 +000015844fi
15845
Guido van Rossum49545951997-12-02 19:28:29 +000015846fi
15847
Guido van Rossumb93a8621998-05-07 13:27:32 +000015848fi
15849
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015850
Michael W. Hudson54241132001-12-07 15:38:26 +000015851fi
15852
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015853
15854fi
15855
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015856fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015857
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015858rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015859rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015860 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015861fi
15862
Martin v. Löwis11437992002-04-12 09:54:03 +000015863fi
15864
15865
15866fi
15867
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015868
Michael W. Hudson54241132001-12-07 15:38:26 +000015869
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015870 { $as_echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
15871$as_echo_n "checking for usconfig in -lmpc... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015872if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015873 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015874else
Martin v. Löwis11437992002-04-12 09:54:03 +000015875 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015876LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015877cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015878/* confdefs.h. */
15879_ACEOF
15880cat confdefs.h >>conftest.$ac_ext
15881cat >>conftest.$ac_ext <<_ACEOF
15882/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015883
Martin v. Löwiseba40652007-08-30 20:10:57 +000015884/* Override any GCC internal prototype to avoid an error.
15885 Use char because int might match the return type of a GCC
15886 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015887#ifdef __cplusplus
15888extern "C"
15889#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015890char usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015891int
15892main ()
15893{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015894return usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015895 ;
15896 return 0;
15897}
15898_ACEOF
15899rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015900if { (ac_try="$ac_link"
15901case "(($ac_try" in
15902 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15903 *) ac_try_echo=$ac_try;;
15904esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015905eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15906$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015907 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015908 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015909 grep -v '^ *+' conftest.er1 >conftest.err
15910 rm -f conftest.er1
15911 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015912 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015913 (exit $ac_status); } && {
15914 test -z "$ac_c_werror_flag" ||
15915 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015916 } && test -s conftest$ac_exeext && {
15917 test "$cross_compiling" = yes ||
15918 $as_test_x conftest$ac_exeext
15919 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015920 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015921else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015922 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015923sed 's/^/| /' conftest.$ac_ext >&5
15924
Martin v. Löwiseba40652007-08-30 20:10:57 +000015925 ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015926fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015927
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015928rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000015929rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015930 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015931LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015932fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015933{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
15934$as_echo "$ac_cv_lib_mpc_usconfig" >&6; }
15935if test "x$ac_cv_lib_mpc_usconfig" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015936 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015937#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015938_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000015939
Martin v. Löwis130fb172001-07-19 11:00:41 +000015940 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015941 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000015942 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000015943fi
15944
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000015945
Neal Norwitza978ab02002-11-02 16:58:05 +000015946 if test "$posix_threads" != "yes"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015947 { $as_echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
15948$as_echo_n "checking for thr_create in -lthread... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015949if test "${ac_cv_lib_thread_thr_create+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015950 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015951else
Martin v. Löwis11437992002-04-12 09:54:03 +000015952 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015953LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015954cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015955/* confdefs.h. */
15956_ACEOF
15957cat confdefs.h >>conftest.$ac_ext
15958cat >>conftest.$ac_ext <<_ACEOF
15959/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015960
Martin v. Löwiseba40652007-08-30 20:10:57 +000015961/* Override any GCC internal prototype to avoid an error.
15962 Use char because int might match the return type of a GCC
15963 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015964#ifdef __cplusplus
15965extern "C"
15966#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015967char thr_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015968int
15969main ()
15970{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015971return thr_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015972 ;
15973 return 0;
15974}
15975_ACEOF
15976rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015977if { (ac_try="$ac_link"
15978case "(($ac_try" in
15979 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15980 *) ac_try_echo=$ac_try;;
15981esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015982eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15983$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015984 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015985 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015986 grep -v '^ *+' conftest.er1 >conftest.err
15987 rm -f conftest.er1
15988 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015989 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015990 (exit $ac_status); } && {
15991 test -z "$ac_c_werror_flag" ||
15992 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015993 } && test -s conftest$ac_exeext && {
15994 test "$cross_compiling" = yes ||
15995 $as_test_x conftest$ac_exeext
15996 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015997 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015998else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000015999 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016000sed 's/^/| /' conftest.$ac_ext >&5
16001
Martin v. Löwiseba40652007-08-30 20:10:57 +000016002 ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000016003fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016004
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016005rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000016006rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000016007 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000016008LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016009fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016010{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
16011$as_echo "$ac_cv_lib_thread_thr_create" >&6; }
16012if test "x$ac_cv_lib_thread_thr_create" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016013 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016014#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016015_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000016016
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000016017 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000016018 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000016019 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000016020fi
16021
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000016022 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016023
Martin v. Löwis130fb172001-07-19 11:00:41 +000016024 if test "$USE_THREAD_MODULE" != "#"
16025 then
16026 # If the above checks didn't disable threads, (at least) OSF1
16027 # needs this '-threads' argument during linking.
16028 case $ac_sys_system in
16029 OSF1) LDLAST=-threads;;
16030 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000016031 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016032fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000016033
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016034if test "$posix_threads" = "yes"; then
16035 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000016036
16037cat >>confdefs.h <<\_ACEOF
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016038#define _POSIX_THREADS 1
16039_ACEOF
16040
16041 fi
16042
16043 # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8.
16044 case $ac_sys_system/$ac_sys_release in
16045 SunOS/5.6)
16046cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000016047#define HAVE_PTHREAD_DESTRUCTOR 1
16048_ACEOF
16049
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016050 ;;
16051 SunOS/5.8)
16052cat >>confdefs.h <<\_ACEOF
16053#define HAVE_BROKEN_POSIX_SEMAPHORES 1
16054_ACEOF
16055
16056 ;;
Christian Heimescba36bb2008-01-30 22:54:18 +000016057 AIX/5)
16058cat >>confdefs.h <<\_ACEOF
16059#define HAVE_BROKEN_POSIX_SEMAPHORES 1
16060_ACEOF
16061
16062 ;;
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016063 esac
16064
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016065 { $as_echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
16066$as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016067 if test "${ac_cv_pthread_system_supported+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016068 $as_echo_n "(cached) " >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016069else
16070 if test "$cross_compiling" = yes; then
16071 ac_cv_pthread_system_supported=no
16072else
16073 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016074/* confdefs.h. */
16075_ACEOF
16076cat confdefs.h >>conftest.$ac_ext
16077cat >>conftest.$ac_ext <<_ACEOF
16078/* end confdefs.h. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016079#include <pthread.h>
16080 void *foo(void *parm) {
16081 return NULL;
16082 }
16083 main() {
16084 pthread_attr_t attr;
16085 pthread_t id;
16086 if (pthread_attr_init(&attr)) exit(-1);
16087 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
16088 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
16089 exit(0);
16090 }
16091_ACEOF
16092rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016093if { (ac_try="$ac_link"
16094case "(($ac_try" in
16095 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16096 *) ac_try_echo=$ac_try;;
16097esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016098eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16099$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016100 (eval "$ac_link") 2>&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016101 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016102 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016103 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000016104 { (case "(($ac_try" in
16105 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16106 *) ac_try_echo=$ac_try;;
16107esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016108eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16109$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016110 (eval "$ac_try") 2>&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016111 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016112 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016113 (exit $ac_status); }; }; then
16114 ac_cv_pthread_system_supported=yes
16115else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016116 $as_echo "$as_me: program exited with status $ac_status" >&5
16117$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016118sed 's/^/| /' conftest.$ac_ext >&5
16119
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016120( exit $ac_status )
16121ac_cv_pthread_system_supported=no
16122fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016123rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000016124rm -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 +000016125fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000016126
Martin v. Löwiseba40652007-08-30 20:10:57 +000016127
16128
Guido van Rossum627b2d71993-12-24 10:39:16 +000016129fi
16130
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016131 { $as_echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
16132$as_echo "$ac_cv_pthread_system_supported" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016133 if test "$ac_cv_pthread_system_supported" = "yes"; then
16134
16135cat >>confdefs.h <<\_ACEOF
16136#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
16137_ACEOF
16138
16139 fi
16140
16141for ac_func in pthread_sigmask
16142do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016143as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16144{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
16145$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016146if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016147 $as_echo_n "(cached) " >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016148else
16149 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016150/* confdefs.h. */
16151_ACEOF
16152cat confdefs.h >>conftest.$ac_ext
16153cat >>conftest.$ac_ext <<_ACEOF
16154/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016155/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16156 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16157#define $ac_func innocuous_$ac_func
16158
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016159/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000016160 which can conflict with char $ac_func (); below.
16161 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016162 <limits.h> exists even on freestanding compilers. */
16163
16164#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000016165# include <limits.h>
16166#else
16167# include <assert.h>
16168#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016169
16170#undef $ac_func
16171
Martin v. Löwiseba40652007-08-30 20:10:57 +000016172/* Override any GCC internal prototype to avoid an error.
16173 Use char because int might match the return type of a GCC
16174 builtin and then its argument prototype would still apply. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016175#ifdef __cplusplus
16176extern "C"
16177#endif
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016178char $ac_func ();
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016179/* The GNU C library defines this for functions which it implements
16180 to always fail with ENOSYS. Some functions are actually named
16181 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000016182#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016183choke me
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016184#endif
16185
Skip Montanaro6dead952003-09-25 14:50:04 +000016186int
16187main ()
16188{
Martin v. Löwiseba40652007-08-30 20:10:57 +000016189return $ac_func ();
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016190 ;
16191 return 0;
16192}
16193_ACEOF
16194rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016195if { (ac_try="$ac_link"
16196case "(($ac_try" in
16197 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16198 *) ac_try_echo=$ac_try;;
16199esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016200eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16201$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016202 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016203 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016204 grep -v '^ *+' conftest.er1 >conftest.err
16205 rm -f conftest.er1
16206 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016207 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016208 (exit $ac_status); } && {
16209 test -z "$ac_c_werror_flag" ||
16210 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016211 } && test -s conftest$ac_exeext && {
16212 test "$cross_compiling" = yes ||
16213 $as_test_x conftest$ac_exeext
16214 }; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016215 eval "$as_ac_var=yes"
16216else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016217 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016218sed 's/^/| /' conftest.$ac_ext >&5
16219
Martin v. Löwiseba40652007-08-30 20:10:57 +000016220 eval "$as_ac_var=no"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016221fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016222
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016223rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000016224rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000016225 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016226fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016227ac_res=`eval 'as_val=${'$as_ac_var'}
16228 $as_echo "$as_val"'`
16229 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
16230$as_echo "$ac_res" >&6; }
16231as_val=`eval 'as_val=${'$as_ac_var'}
16232 $as_echo "$as_val"'`
16233 if test "x$as_val" = x""yes; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016234 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016235#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016236_ACEOF
Jason Tishlerfac083d2003-07-22 15:20:49 +000016237 case $ac_sys_system in
16238 CYGWIN*)
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016239
Jason Tishlerfac083d2003-07-22 15:20:49 +000016240cat >>confdefs.h <<\_ACEOF
16241#define HAVE_BROKEN_PTHREAD_SIGMASK 1
16242_ACEOF
16243
16244 ;;
16245 esac
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000016246fi
16247done
16248
16249fi
16250
16251
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016252# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000016253
16254
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016255{ $as_echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
16256$as_echo_n "checking if --enable-ipv6 is specified... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016257# Check whether --enable-ipv6 was given.
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016258if test "${enable_ipv6+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016259 enableval=$enable_ipv6; case "$enableval" in
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016260 no)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016261 { $as_echo "$as_me:$LINENO: result: no" >&5
16262$as_echo "no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016263 ipv6=no
16264 ;;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016265 *) { $as_echo "$as_me:$LINENO: result: yes" >&5
16266$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016267 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016268#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016269_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016270
16271 ipv6=yes
16272 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000016273 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016274else
Martin v. Löwis11437992002-04-12 09:54:03 +000016275
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016276 if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016277 { $as_echo "$as_me:$LINENO: result: no" >&5
16278$as_echo "no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016279 ipv6=no
16280
16281else
Martin v. Löwis11437992002-04-12 09:54:03 +000016282 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016283/* confdefs.h. */
16284_ACEOF
16285cat confdefs.h >>conftest.$ac_ext
16286cat >>conftest.$ac_ext <<_ACEOF
16287/* end confdefs.h. */
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016288 /* AF_INET6 available check */
16289#include <sys/types.h>
16290#include <sys/socket.h>
16291main()
16292{
16293 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
16294 exit(1);
16295 else
16296 exit(0);
16297}
16298
Martin v. Löwis11437992002-04-12 09:54:03 +000016299_ACEOF
16300rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016301if { (ac_try="$ac_link"
16302case "(($ac_try" in
16303 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16304 *) ac_try_echo=$ac_try;;
16305esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016306eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16307$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016308 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000016309 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016310 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000016311 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000016312 { (case "(($ac_try" in
16313 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16314 *) ac_try_echo=$ac_try;;
16315esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016316eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16317$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016318 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000016319 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016320 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000016321 (exit $ac_status); }; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016322 { $as_echo "$as_me:$LINENO: result: yes" >&5
16323$as_echo "yes" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016324 ipv6=yes
16325else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016326 $as_echo "$as_me: program exited with status $ac_status" >&5
16327$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016328sed 's/^/| /' conftest.$ac_ext >&5
16329
Martin v. Löwis11437992002-04-12 09:54:03 +000016330( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016331{ $as_echo "$as_me:$LINENO: result: no" >&5
16332$as_echo "no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016333 ipv6=no
16334fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016335rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000016336rm -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 +000016337fi
16338
Martin v. Löwiseba40652007-08-30 20:10:57 +000016339
16340
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016341if test "$ipv6" = "yes"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016342 { $as_echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
16343$as_echo_n "checking if RFC2553 API is available... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016344 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016345/* confdefs.h. */
16346_ACEOF
16347cat confdefs.h >>conftest.$ac_ext
16348cat >>conftest.$ac_ext <<_ACEOF
16349/* end confdefs.h. */
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016350#include <sys/types.h>
16351#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016352int
16353main ()
16354{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016355struct sockaddr_in6 x;
16356x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000016357 ;
16358 return 0;
16359}
16360_ACEOF
16361rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016362if { (ac_try="$ac_compile"
16363case "(($ac_try" in
16364 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16365 *) ac_try_echo=$ac_try;;
16366esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016367eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16368$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016369 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000016370 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016371 grep -v '^ *+' conftest.er1 >conftest.err
16372 rm -f conftest.er1
16373 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016374 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016375 (exit $ac_status); } && {
16376 test -z "$ac_c_werror_flag" ||
16377 test ! -s conftest.err
16378 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016379 { $as_echo "$as_me:$LINENO: result: yes" >&5
16380$as_echo "yes" >&6; }
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016381 ipv6=yes
16382else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016383 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016384sed 's/^/| /' conftest.$ac_ext >&5
16385
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016386 { $as_echo "$as_me:$LINENO: result: no" >&5
16387$as_echo "no" >&6; }
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016388 ipv6=no
16389fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016390
16391rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016392fi
16393
16394if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016395 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016396#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016397_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016398
16399fi
16400
Martin v. Löwiseba40652007-08-30 20:10:57 +000016401fi
16402
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016403
16404ipv6type=unknown
16405ipv6lib=none
16406ipv6trylibc=no
16407
16408if test "$ipv6" = "yes"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016409 { $as_echo "$as_me:$LINENO: checking ipv6 stack type" >&5
16410$as_echo_n "checking ipv6 stack type... " >&6; }
Guido van Rossumb8552162001-09-05 14:58:11 +000016411 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
16412 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016413 case $i in
16414 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000016415 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016416/* confdefs.h. */
16417_ACEOF
16418cat confdefs.h >>conftest.$ac_ext
16419cat >>conftest.$ac_ext <<_ACEOF
16420/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016421
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016422#include <netinet/in.h>
16423#ifdef IPV6_INRIA_VERSION
16424yes
16425#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016426_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016427if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016428 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016429 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016430fi
16431rm -f conftest*
16432
16433 ;;
16434 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000016435 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016436/* confdefs.h. */
16437_ACEOF
16438cat confdefs.h >>conftest.$ac_ext
16439cat >>conftest.$ac_ext <<_ACEOF
16440/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016441
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016442#include <netinet/in.h>
16443#ifdef __KAME__
16444yes
16445#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016446_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016447if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016448 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016449 ipv6type=$i;
16450 ipv6lib=inet6
16451 ipv6libdir=/usr/local/v6/lib
16452 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016453fi
16454rm -f conftest*
16455
16456 ;;
16457 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000016458 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016459/* confdefs.h. */
16460_ACEOF
16461cat confdefs.h >>conftest.$ac_ext
16462cat >>conftest.$ac_ext <<_ACEOF
16463/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016464
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016465#include <features.h>
16466#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
16467yes
16468#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016469_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016470if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016471 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016472 ipv6type=$i;
16473 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016474fi
16475rm -f conftest*
16476
16477 ;;
16478 linux-inet6)
16479 if test -d /usr/inet6; then
16480 ipv6type=$i
16481 ipv6lib=inet6
16482 ipv6libdir=/usr/inet6/lib
Skip Montanarodecc6a42003-01-01 20:07:49 +000016483 BASECFLAGS="-I/usr/inet6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016484 fi
16485 ;;
16486 solaris)
16487 if test -f /etc/netconfig; then
16488 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
16489 ipv6type=$i
16490 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016491 fi
16492 fi
16493 ;;
16494 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000016495 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016496/* confdefs.h. */
16497_ACEOF
16498cat confdefs.h >>conftest.$ac_ext
16499cat >>conftest.$ac_ext <<_ACEOF
16500/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016501
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016502#include <sys/param.h>
16503#ifdef _TOSHIBA_INET6
16504yes
16505#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016506_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016507if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016508 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016509 ipv6type=$i;
16510 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016511 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016512fi
16513rm -f conftest*
16514
16515 ;;
16516 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000016517 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016518/* confdefs.h. */
16519_ACEOF
16520cat confdefs.h >>conftest.$ac_ext
16521cat >>conftest.$ac_ext <<_ACEOF
16522/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016523
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016524#include </usr/local/v6/include/sys/v6config.h>
16525#ifdef __V6D__
16526yes
16527#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016528_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016529if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016530 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016531 ipv6type=$i;
16532 ipv6lib=v6;
16533 ipv6libdir=/usr/local/v6/lib;
Skip Montanarodecc6a42003-01-01 20:07:49 +000016534 BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016535fi
16536rm -f conftest*
16537
16538 ;;
16539 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000016540 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016541/* confdefs.h. */
16542_ACEOF
16543cat confdefs.h >>conftest.$ac_ext
16544cat >>conftest.$ac_ext <<_ACEOF
16545/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016546
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016547#include <sys/param.h>
16548#ifdef _ZETA_MINAMI_INET6
16549yes
16550#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016551_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016552if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016553 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016554 ipv6type=$i;
16555 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016556 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016557fi
16558rm -f conftest*
16559
16560 ;;
16561 esac
16562 if test "$ipv6type" != "unknown"; then
16563 break
16564 fi
16565 done
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016566 { $as_echo "$as_me:$LINENO: result: $ipv6type" >&5
16567$as_echo "$ipv6type" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016568fi
16569
16570if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
16571 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
16572 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
16573 echo "using lib$ipv6lib"
16574 else
16575 if test $ipv6trylibc = "yes"; then
16576 echo "using libc"
16577 else
16578 echo 'Fatal: no $ipv6lib library found. cannot continue.'
16579 echo "You need to fetch lib$ipv6lib.a from appropriate"
16580 echo 'ipv6 kit and compile beforehand.'
16581 exit 1
16582 fi
16583 fi
16584fi
16585
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016586{ $as_echo "$as_me:$LINENO: checking for OSX 10.5 SDK or later" >&5
16587$as_echo_n "checking for OSX 10.5 SDK or later... " >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016588cat >conftest.$ac_ext <<_ACEOF
16589/* confdefs.h. */
16590_ACEOF
16591cat confdefs.h >>conftest.$ac_ext
16592cat >>conftest.$ac_ext <<_ACEOF
16593/* end confdefs.h. */
16594#include <Carbon/Carbon.h>
16595int
16596main ()
16597{
16598FSIORefNum fRef = 0
16599 ;
16600 return 0;
16601}
16602_ACEOF
16603rm -f conftest.$ac_objext
16604if { (ac_try="$ac_compile"
16605case "(($ac_try" in
16606 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16607 *) ac_try_echo=$ac_try;;
16608esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016609eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16610$as_echo "$ac_try_echo") >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016611 (eval "$ac_compile") 2>conftest.er1
16612 ac_status=$?
16613 grep -v '^ *+' conftest.er1 >conftest.err
16614 rm -f conftest.er1
16615 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016616 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016617 (exit $ac_status); } && {
16618 test -z "$ac_c_werror_flag" ||
16619 test ! -s conftest.err
16620 } && test -s conftest.$ac_objext; then
16621
16622cat >>confdefs.h <<\_ACEOF
16623#define HAVE_OSX105_SDK 1
16624_ACEOF
16625
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016626 { $as_echo "$as_me:$LINENO: result: yes" >&5
16627$as_echo "yes" >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016628else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016629 $as_echo "$as_me: failed program was:" >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016630sed 's/^/| /' conftest.$ac_ext >&5
16631
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016632 { $as_echo "$as_me:$LINENO: result: no" >&5
16633$as_echo "no" >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016634
16635fi
16636
16637rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16638
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016639# Check for --with-doc-strings
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016640{ $as_echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
16641$as_echo_n "checking for --with-doc-strings... " >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016642
Martin v. Löwiseba40652007-08-30 20:10:57 +000016643# Check whether --with-doc-strings was given.
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016644if test "${with_doc_strings+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016645 withval=$with_doc_strings;
16646fi
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016647
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016648
16649if test -z "$with_doc_strings"
16650then with_doc_strings="yes"
16651fi
16652if test "$with_doc_strings" != "no"
16653then
16654
16655cat >>confdefs.h <<\_ACEOF
16656#define WITH_DOC_STRINGS 1
16657_ACEOF
16658
16659fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016660{ $as_echo "$as_me:$LINENO: result: $with_doc_strings" >&5
16661$as_echo "$with_doc_strings" >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016662
Neil Schemenauera35c6882001-02-27 04:45:05 +000016663# Check for Python-specific malloc support
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016664{ $as_echo "$as_me:$LINENO: checking for --with-tsc" >&5
16665$as_echo_n "checking for --with-tsc... " >&6; }
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016666
Martin v. Löwiseba40652007-08-30 20:10:57 +000016667# Check whether --with-tsc was given.
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016668if test "${with_tsc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016669 withval=$with_tsc;
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016670if test "$withval" != no
16671then
16672
16673cat >>confdefs.h <<\_ACEOF
16674#define WITH_TSC 1
16675_ACEOF
16676
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016677 { $as_echo "$as_me:$LINENO: result: yes" >&5
16678$as_echo "yes" >&6; }
16679else { $as_echo "$as_me:$LINENO: result: no" >&5
16680$as_echo "no" >&6; }
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016681fi
16682else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016683 { $as_echo "$as_me:$LINENO: result: no" >&5
16684$as_echo "no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016685fi
16686
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016687
16688# Check for Python-specific malloc support
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016689{ $as_echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
16690$as_echo_n "checking for --with-pymalloc... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016691
Martin v. Löwiseba40652007-08-30 20:10:57 +000016692# Check whether --with-pymalloc was given.
Neil Schemenauera35c6882001-02-27 04:45:05 +000016693if test "${with_pymalloc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016694 withval=$with_pymalloc;
16695fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016696
Neil Schemenauera35c6882001-02-27 04:45:05 +000016697
Neil Schemenauer16c22972002-03-22 15:34:49 +000016698if test -z "$with_pymalloc"
16699then with_pymalloc="yes"
16700fi
16701if test "$with_pymalloc" != "no"
16702then
Martin v. Löwis11437992002-04-12 09:54:03 +000016703
16704cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000016705#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016706_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000016707
16708fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016709{ $as_echo "$as_me:$LINENO: result: $with_pymalloc" >&5
16710$as_echo "$with_pymalloc" >&6; }
Neil Schemenauer16c22972002-03-22 15:34:49 +000016711
Barry Warsawef82cd72000-06-30 16:21:01 +000016712# Check for --with-wctype-functions
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016713{ $as_echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
16714$as_echo_n "checking for --with-wctype-functions... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016715
Martin v. Löwiseba40652007-08-30 20:10:57 +000016716# Check whether --with-wctype-functions was given.
Barry Warsawef82cd72000-06-30 16:21:01 +000016717if test "${with_wctype_functions+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016718 withval=$with_wctype_functions;
Barry Warsawef82cd72000-06-30 16:21:01 +000016719if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000016720then
16721
16722cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000016723#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016724_ACEOF
16725
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016726 { $as_echo "$as_me:$LINENO: result: yes" >&5
16727$as_echo "yes" >&6; }
16728else { $as_echo "$as_me:$LINENO: result: no" >&5
16729$as_echo "no" >&6; }
Barry Warsawef82cd72000-06-30 16:21:01 +000016730fi
16731else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016732 { $as_echo "$as_me:$LINENO: result: no" >&5
16733$as_echo "no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016734fi
16735
Barry Warsawef82cd72000-06-30 16:21:01 +000016736
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016737# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000016738
Guido van Rossum98935bf2001-09-05 19:13:16 +000016739DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000016740
Guido van Rossume97ee181999-12-20 21:27:22 +000016741# the dlopen() function means we might want to use dynload_shlib.o. some
16742# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000016743
Thomas Wouters3a584202000-08-05 23:28:51 +000016744for ac_func in dlopen
16745do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016746as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16747{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
16748$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016749if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016750 $as_echo_n "(cached) " >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000016751else
Martin v. Löwis11437992002-04-12 09:54:03 +000016752 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016753/* confdefs.h. */
16754_ACEOF
16755cat confdefs.h >>conftest.$ac_ext
16756cat >>conftest.$ac_ext <<_ACEOF
16757/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016758/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16759 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16760#define $ac_func innocuous_$ac_func
16761
Guido van Rossume97ee181999-12-20 21:27:22 +000016762/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000016763 which can conflict with char $ac_func (); below.
16764 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016765 <limits.h> exists even on freestanding compilers. */
16766
16767#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000016768# include <limits.h>
16769#else
16770# include <assert.h>
16771#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016772
16773#undef $ac_func
16774
Martin v. Löwiseba40652007-08-30 20:10:57 +000016775/* Override any GCC internal prototype to avoid an error.
16776 Use char because int might match the return type of a GCC
16777 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016778#ifdef __cplusplus
16779extern "C"
16780#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016781char $ac_func ();
Guido van Rossume97ee181999-12-20 21:27:22 +000016782/* The GNU C library defines this for functions which it implements
16783 to always fail with ENOSYS. Some functions are actually named
16784 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000016785#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossume97ee181999-12-20 21:27:22 +000016786choke me
Guido van Rossume97ee181999-12-20 21:27:22 +000016787#endif
16788
Skip Montanaro6dead952003-09-25 14:50:04 +000016789int
16790main ()
16791{
Martin v. Löwiseba40652007-08-30 20:10:57 +000016792return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016793 ;
16794 return 0;
16795}
16796_ACEOF
16797rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016798if { (ac_try="$ac_link"
16799case "(($ac_try" in
16800 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16801 *) ac_try_echo=$ac_try;;
16802esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016803eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16804$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016805 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000016806 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016807 grep -v '^ *+' conftest.er1 >conftest.err
16808 rm -f conftest.er1
16809 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016810 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016811 (exit $ac_status); } && {
16812 test -z "$ac_c_werror_flag" ||
16813 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016814 } && test -s conftest$ac_exeext && {
16815 test "$cross_compiling" = yes ||
16816 $as_test_x conftest$ac_exeext
16817 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016818 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000016819else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016820 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016821sed 's/^/| /' conftest.$ac_ext >&5
16822
Martin v. Löwiseba40652007-08-30 20:10:57 +000016823 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000016824fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016825
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016826rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000016827rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000016828 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016829fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016830ac_res=`eval 'as_val=${'$as_ac_var'}
16831 $as_echo "$as_val"'`
16832 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
16833$as_echo "$ac_res" >&6; }
16834as_val=`eval 'as_val=${'$as_ac_var'}
16835 $as_echo "$as_val"'`
16836 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016837 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016838#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016839_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016840
Guido van Rossume97ee181999-12-20 21:27:22 +000016841fi
Thomas Wouters3a584202000-08-05 23:28:51 +000016842done
Guido van Rossume97ee181999-12-20 21:27:22 +000016843
Michael W. Hudson54241132001-12-07 15:38:26 +000016844
Guido van Rossume97ee181999-12-20 21:27:22 +000016845# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
16846# loading of modules.
16847
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016848{ $as_echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
16849$as_echo_n "checking DYNLOADFILE... " >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000016850if test -z "$DYNLOADFILE"
16851then
16852 case $ac_sys_system/$ac_sys_release in
Martin v. Löwisc19c5a62003-11-18 20:00:44 +000016853 AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c
16854 if test "$ac_cv_func_dlopen" = yes
16855 then DYNLOADFILE="dynload_shlib.o"
16856 else DYNLOADFILE="dynload_aix.o"
16857 fi
16858 ;;
Guido van Rossume97ee181999-12-20 21:27:22 +000016859 BeOS*) DYNLOADFILE="dynload_beos.o";;
16860 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Anthony Baxter82201742006-04-09 15:07:40 +000016861 # Use dynload_next.c only on 10.2 and below, which don't have native dlopen()
16862 Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000016863 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000016864 *)
16865 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
16866 # out any dynamic loading
16867 if test "$ac_cv_func_dlopen" = yes
16868 then DYNLOADFILE="dynload_shlib.o"
16869 else DYNLOADFILE="dynload_stub.o"
16870 fi
16871 ;;
16872 esac
16873fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016874{ $as_echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
16875$as_echo "$DYNLOADFILE" >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000016876if test "$DYNLOADFILE" != "dynload_stub.o"
16877then
Martin v. Löwis11437992002-04-12 09:54:03 +000016878
16879cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016880#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016881_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016882
16883fi
16884
Neil Schemenauer4e425612001-06-19 15:44:15 +000016885# MACHDEP_OBJS can be set to platform-specific object files needed by Python
16886
Michael W. Hudson54241132001-12-07 15:38:26 +000016887
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016888{ $as_echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
16889$as_echo_n "checking MACHDEP_OBJS... " >&6; }
Neil Schemenauer4e425612001-06-19 15:44:15 +000016890if test -z "$MACHDEP_OBJS"
16891then
Jack Jansene578a632001-08-15 01:27:14 +000016892 MACHDEP_OBJS=$extra_machdep_objs
16893else
16894 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000016895fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016896{ $as_echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
16897$as_echo "MACHDEP_OBJS" >&6; }
Neil Schemenauer4e425612001-06-19 15:44:15 +000016898
Guido van Rossum627b2d71993-12-24 10:39:16 +000016899# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000016900
16901
16902
16903
16904
16905
16906
16907
16908
16909
16910
16911
16912
16913
16914
16915
16916
16917
16918
16919
16920
16921
16922
16923
16924
16925
16926
16927
16928
16929
16930
16931
16932
16933
16934
16935
16936
16937
16938
16939
16940
16941
16942
16943
16944
16945
16946
16947
16948
16949
16950
16951
16952
16953
16954
16955
16956
16957
16958
16959
16960
16961
16962
16963
16964
16965
16966
16967
16968
16969
16970
Martin v. Löwisd6320502004-08-12 13:45:08 +000016971
Martin v. Löwisc3001752005-01-23 09:27:24 +000016972
16973
Neal Norwitz05a45592006-03-20 06:30:08 +000016974
16975
Martin v. Löwis382abef2007-02-19 10:55:19 +000016976
16977
Christian Heimes36281872007-11-30 21:11:28 +000016978
Martin v. Löwisaef18b12008-03-24 13:31:16 +000016979
16980
Jesse Noller355b1262009-04-02 00:03:28 +000016981
16982
16983
16984
Martin v. Löwisaef18b12008-03-24 13:31:16 +000016985for ac_func in alarm setitimer getitimer bind_textdomain_codeset chown \
16986 clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \
Martin v. Löwis438b5342002-12-27 10:16:42 +000016987 gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \
Martin v. Löwisc3001752005-01-23 09:27:24 +000016988 getpriority getpwent getspnam getspent getsid getwd \
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000016989 kill killpg lchmod lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000016990 mremap nice pathconf pause plock poll pthread_init \
Guido van Rossum162e38c2003-02-19 15:25:10 +000016991 putenv readlink realpath \
Jesse Noller355b1262009-04-02 00:03:28 +000016992 select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \
16993 setgid \
Martin v. Löwis4daacb12003-03-28 18:37:01 +000016994 setlocale setregid setreuid setsid setpgid setpgrp setuid setvbuf snprintf \
Skip Montanaro7e11a012004-02-07 12:55:46 +000016995 sigaction siginterrupt sigrelse strftime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000016996 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Neal Norwitz05a45592006-03-20 06:30:08 +000016997 truncate uname unsetenv utimes waitpid wait3 wait4 wcscoll _getpty
Guido van Rossum627b2d71993-12-24 10:39:16 +000016998do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000016999as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17000{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
17001$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000017002if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017003 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017004else
Martin v. Löwis11437992002-04-12 09:54:03 +000017005 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017006/* confdefs.h. */
17007_ACEOF
17008cat confdefs.h >>conftest.$ac_ext
17009cat >>conftest.$ac_ext <<_ACEOF
17010/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000017011/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17012 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17013#define $ac_func innocuous_$ac_func
17014
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000017015/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000017016 which can conflict with char $ac_func (); below.
17017 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000017018 <limits.h> exists even on freestanding compilers. */
17019
17020#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000017021# include <limits.h>
17022#else
17023# include <assert.h>
17024#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000017025
17026#undef $ac_func
17027
Martin v. Löwiseba40652007-08-30 20:10:57 +000017028/* Override any GCC internal prototype to avoid an error.
17029 Use char because int might match the return type of a GCC
17030 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017031#ifdef __cplusplus
17032extern "C"
17033#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000017034char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000017035/* The GNU C library defines this for functions which it implements
17036 to always fail with ENOSYS. Some functions are actually named
17037 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000017038#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum627b2d71993-12-24 10:39:16 +000017039choke me
Guido van Rossum627b2d71993-12-24 10:39:16 +000017040#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017041
Skip Montanaro6dead952003-09-25 14:50:04 +000017042int
17043main ()
17044{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017045return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000017046 ;
17047 return 0;
17048}
17049_ACEOF
17050rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017051if { (ac_try="$ac_link"
17052case "(($ac_try" in
17053 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17054 *) ac_try_echo=$ac_try;;
17055esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017056eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17057$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017058 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000017059 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017060 grep -v '^ *+' conftest.er1 >conftest.err
17061 rm -f conftest.er1
17062 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017063 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017064 (exit $ac_status); } && {
17065 test -z "$ac_c_werror_flag" ||
17066 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017067 } && test -s conftest$ac_exeext && {
17068 test "$cross_compiling" = yes ||
17069 $as_test_x conftest$ac_exeext
17070 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000017071 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000017072else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017073 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017074sed 's/^/| /' conftest.$ac_ext >&5
17075
Martin v. Löwiseba40652007-08-30 20:10:57 +000017076 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000017077fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017078
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017079rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000017080rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017081 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000017082fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017083ac_res=`eval 'as_val=${'$as_ac_var'}
17084 $as_echo "$as_val"'`
17085 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
17086$as_echo "$ac_res" >&6; }
17087as_val=`eval 'as_val=${'$as_ac_var'}
17088 $as_echo "$as_val"'`
17089 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000017090 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017091#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017092_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000017093
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000017094fi
17095done
17096
Michael W. Hudson54241132001-12-07 15:38:26 +000017097
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017098# For some functions, having a definition is not sufficient, since
17099# we want to take their address.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017100{ $as_echo "$as_me:$LINENO: checking for chroot" >&5
17101$as_echo_n "checking for chroot... " >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017102cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017103/* confdefs.h. */
17104_ACEOF
17105cat confdefs.h >>conftest.$ac_ext
17106cat >>conftest.$ac_ext <<_ACEOF
17107/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017108#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017109int
17110main ()
17111{
17112void *x=chroot
17113 ;
17114 return 0;
17115}
17116_ACEOF
17117rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017118if { (ac_try="$ac_compile"
17119case "(($ac_try" in
17120 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17121 *) ac_try_echo=$ac_try;;
17122esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017123eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17124$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017125 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017126 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017127 grep -v '^ *+' conftest.er1 >conftest.err
17128 rm -f conftest.er1
17129 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017130 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017131 (exit $ac_status); } && {
17132 test -z "$ac_c_werror_flag" ||
17133 test ! -s conftest.err
17134 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017135
17136cat >>confdefs.h <<\_ACEOF
17137#define HAVE_CHROOT 1
17138_ACEOF
17139
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017140 { $as_echo "$as_me:$LINENO: result: yes" >&5
17141$as_echo "yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017142else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017143 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017144sed 's/^/| /' conftest.$ac_ext >&5
17145
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017146 { $as_echo "$as_me:$LINENO: result: no" >&5
17147$as_echo "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017148
17149fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017150
17151rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017152{ $as_echo "$as_me:$LINENO: checking for link" >&5
17153$as_echo_n "checking for link... " >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017154cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017155/* confdefs.h. */
17156_ACEOF
17157cat confdefs.h >>conftest.$ac_ext
17158cat >>conftest.$ac_ext <<_ACEOF
17159/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017160#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017161int
17162main ()
17163{
17164void *x=link
17165 ;
17166 return 0;
17167}
17168_ACEOF
17169rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017170if { (ac_try="$ac_compile"
17171case "(($ac_try" in
17172 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17173 *) ac_try_echo=$ac_try;;
17174esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017175eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17176$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017177 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017178 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017179 grep -v '^ *+' conftest.er1 >conftest.err
17180 rm -f conftest.er1
17181 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017182 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017183 (exit $ac_status); } && {
17184 test -z "$ac_c_werror_flag" ||
17185 test ! -s conftest.err
17186 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017187
17188cat >>confdefs.h <<\_ACEOF
17189#define HAVE_LINK 1
17190_ACEOF
17191
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017192 { $as_echo "$as_me:$LINENO: result: yes" >&5
17193$as_echo "yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017194else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017195 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017196sed 's/^/| /' conftest.$ac_ext >&5
17197
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017198 { $as_echo "$as_me:$LINENO: result: no" >&5
17199$as_echo "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017200
17201fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017202
17203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017204{ $as_echo "$as_me:$LINENO: checking for symlink" >&5
17205$as_echo_n "checking for symlink... " >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017206cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017207/* confdefs.h. */
17208_ACEOF
17209cat confdefs.h >>conftest.$ac_ext
17210cat >>conftest.$ac_ext <<_ACEOF
17211/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017212#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017213int
17214main ()
17215{
17216void *x=symlink
17217 ;
17218 return 0;
17219}
17220_ACEOF
17221rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017222if { (ac_try="$ac_compile"
17223case "(($ac_try" in
17224 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17225 *) ac_try_echo=$ac_try;;
17226esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017227eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17228$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017229 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017230 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017231 grep -v '^ *+' conftest.er1 >conftest.err
17232 rm -f conftest.er1
17233 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017234 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017235 (exit $ac_status); } && {
17236 test -z "$ac_c_werror_flag" ||
17237 test ! -s conftest.err
17238 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017239
17240cat >>confdefs.h <<\_ACEOF
17241#define HAVE_SYMLINK 1
17242_ACEOF
17243
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017244 { $as_echo "$as_me:$LINENO: result: yes" >&5
17245$as_echo "yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017246else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017247 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017248sed 's/^/| /' conftest.$ac_ext >&5
17249
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017250 { $as_echo "$as_me:$LINENO: result: no" >&5
17251$as_echo "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017252
17253fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017254
17255rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017256{ $as_echo "$as_me:$LINENO: checking for fchdir" >&5
17257$as_echo_n "checking for fchdir... " >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017258cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017259/* confdefs.h. */
17260_ACEOF
17261cat confdefs.h >>conftest.$ac_ext
17262cat >>conftest.$ac_ext <<_ACEOF
17263/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017264#include <unistd.h>
17265int
17266main ()
17267{
17268void *x=fchdir
17269 ;
17270 return 0;
17271}
17272_ACEOF
17273rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017274if { (ac_try="$ac_compile"
17275case "(($ac_try" in
17276 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17277 *) ac_try_echo=$ac_try;;
17278esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017279eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17280$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017281 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017282 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017283 grep -v '^ *+' conftest.er1 >conftest.err
17284 rm -f conftest.er1
17285 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017286 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017287 (exit $ac_status); } && {
17288 test -z "$ac_c_werror_flag" ||
17289 test ! -s conftest.err
17290 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017291
17292cat >>confdefs.h <<\_ACEOF
17293#define HAVE_FCHDIR 1
17294_ACEOF
17295
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017296 { $as_echo "$as_me:$LINENO: result: yes" >&5
17297$as_echo "yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017298else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017299 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017300sed 's/^/| /' conftest.$ac_ext >&5
17301
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017302 { $as_echo "$as_me:$LINENO: result: no" >&5
17303$as_echo "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017304
17305fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017306
17307rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017308{ $as_echo "$as_me:$LINENO: checking for fsync" >&5
17309$as_echo_n "checking for fsync... " >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017310cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017311/* confdefs.h. */
17312_ACEOF
17313cat confdefs.h >>conftest.$ac_ext
17314cat >>conftest.$ac_ext <<_ACEOF
17315/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017316#include <unistd.h>
17317int
17318main ()
17319{
17320void *x=fsync
17321 ;
17322 return 0;
17323}
17324_ACEOF
17325rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017326if { (ac_try="$ac_compile"
17327case "(($ac_try" in
17328 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17329 *) ac_try_echo=$ac_try;;
17330esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017331eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17332$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017333 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017334 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017335 grep -v '^ *+' conftest.er1 >conftest.err
17336 rm -f conftest.er1
17337 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017338 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017339 (exit $ac_status); } && {
17340 test -z "$ac_c_werror_flag" ||
17341 test ! -s conftest.err
17342 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017343
17344cat >>confdefs.h <<\_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017345#define HAVE_FSYNC 1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017346_ACEOF
17347
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017348 { $as_echo "$as_me:$LINENO: result: yes" >&5
17349$as_echo "yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017350else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017351 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017352sed 's/^/| /' conftest.$ac_ext >&5
17353
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017354 { $as_echo "$as_me:$LINENO: result: no" >&5
17355$as_echo "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017356
17357fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017358
17359rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017360{ $as_echo "$as_me:$LINENO: checking for fdatasync" >&5
17361$as_echo_n "checking for fdatasync... " >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017362cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017363/* confdefs.h. */
17364_ACEOF
17365cat confdefs.h >>conftest.$ac_ext
17366cat >>conftest.$ac_ext <<_ACEOF
17367/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017368#include <unistd.h>
17369int
17370main ()
17371{
17372void *x=fdatasync
17373 ;
17374 return 0;
17375}
17376_ACEOF
17377rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017378if { (ac_try="$ac_compile"
17379case "(($ac_try" in
17380 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17381 *) ac_try_echo=$ac_try;;
17382esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017383eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17384$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017385 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017386 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017387 grep -v '^ *+' conftest.er1 >conftest.err
17388 rm -f conftest.er1
17389 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017390 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017391 (exit $ac_status); } && {
17392 test -z "$ac_c_werror_flag" ||
17393 test ! -s conftest.err
17394 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017395
17396cat >>confdefs.h <<\_ACEOF
17397#define HAVE_FDATASYNC 1
17398_ACEOF
17399
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017400 { $as_echo "$as_me:$LINENO: result: yes" >&5
17401$as_echo "yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017402else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017403 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017404sed 's/^/| /' conftest.$ac_ext >&5
17405
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017406 { $as_echo "$as_me:$LINENO: result: no" >&5
17407$as_echo "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017408
17409fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017410
17411rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017412{ $as_echo "$as_me:$LINENO: checking for epoll" >&5
17413$as_echo_n "checking for epoll... " >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017414cat >conftest.$ac_ext <<_ACEOF
17415/* confdefs.h. */
17416_ACEOF
17417cat confdefs.h >>conftest.$ac_ext
17418cat >>conftest.$ac_ext <<_ACEOF
17419/* end confdefs.h. */
17420#include <sys/epoll.h>
17421int
17422main ()
17423{
17424void *x=epoll_create
17425 ;
17426 return 0;
17427}
17428_ACEOF
17429rm -f conftest.$ac_objext
17430if { (ac_try="$ac_compile"
17431case "(($ac_try" in
17432 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17433 *) ac_try_echo=$ac_try;;
17434esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017435eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17436$as_echo "$ac_try_echo") >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017437 (eval "$ac_compile") 2>conftest.er1
17438 ac_status=$?
17439 grep -v '^ *+' conftest.er1 >conftest.err
17440 rm -f conftest.er1
17441 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017442 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017443 (exit $ac_status); } && {
17444 test -z "$ac_c_werror_flag" ||
17445 test ! -s conftest.err
17446 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017447
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017448cat >>confdefs.h <<\_ACEOF
17449#define HAVE_EPOLL 1
17450_ACEOF
17451
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017452 { $as_echo "$as_me:$LINENO: result: yes" >&5
17453$as_echo "yes" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017454else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017455 $as_echo "$as_me: failed program was:" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017456sed 's/^/| /' conftest.$ac_ext >&5
17457
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017458 { $as_echo "$as_me:$LINENO: result: no" >&5
17459$as_echo "no" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017460
17461fi
17462
17463rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017464{ $as_echo "$as_me:$LINENO: checking for kqueue" >&5
17465$as_echo_n "checking for kqueue... " >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017466cat >conftest.$ac_ext <<_ACEOF
17467/* confdefs.h. */
17468_ACEOF
17469cat confdefs.h >>conftest.$ac_ext
17470cat >>conftest.$ac_ext <<_ACEOF
17471/* end confdefs.h. */
17472
17473#include <sys/types.h>
17474#include <sys/event.h>
17475
17476int
17477main ()
17478{
17479int x=kqueue()
17480 ;
17481 return 0;
17482}
17483_ACEOF
17484rm -f conftest.$ac_objext
17485if { (ac_try="$ac_compile"
17486case "(($ac_try" in
17487 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17488 *) ac_try_echo=$ac_try;;
17489esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017490eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17491$as_echo "$ac_try_echo") >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017492 (eval "$ac_compile") 2>conftest.er1
17493 ac_status=$?
17494 grep -v '^ *+' conftest.er1 >conftest.err
17495 rm -f conftest.er1
17496 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017497 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017498 (exit $ac_status); } && {
17499 test -z "$ac_c_werror_flag" ||
17500 test ! -s conftest.err
17501 } && test -s conftest.$ac_objext; then
17502
17503cat >>confdefs.h <<\_ACEOF
17504#define HAVE_KQUEUE 1
17505_ACEOF
17506
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017507 { $as_echo "$as_me:$LINENO: result: yes" >&5
17508$as_echo "yes" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017509else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017510 $as_echo "$as_me: failed program was:" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017511sed 's/^/| /' conftest.$ac_ext >&5
17512
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017513 { $as_echo "$as_me:$LINENO: result: no" >&5
17514$as_echo "no" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017515
17516fi
17517
17518rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd5843682002-11-21 20:41:28 +000017519# On some systems (eg. FreeBSD 5), we would find a definition of the
17520# functions ctermid_r, setgroups in the library, but no prototype
17521# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
17522# address to avoid compiler warnings and potential miscompilations
17523# because of the missing prototypes.
17524
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017525{ $as_echo "$as_me:$LINENO: checking for ctermid_r" >&5
17526$as_echo_n "checking for ctermid_r... " >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017527cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017528/* confdefs.h. */
17529_ACEOF
17530cat confdefs.h >>conftest.$ac_ext
17531cat >>conftest.$ac_ext <<_ACEOF
17532/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000017533
17534#include "confdefs.h"
17535#include <stdio.h>
17536
Martin v. Löwisd5843682002-11-21 20:41:28 +000017537int
17538main ()
17539{
17540void* p = ctermid_r
17541 ;
17542 return 0;
17543}
17544_ACEOF
17545rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017546if { (ac_try="$ac_compile"
17547case "(($ac_try" in
17548 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17549 *) ac_try_echo=$ac_try;;
17550esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017551eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17552$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017553 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd5843682002-11-21 20:41:28 +000017554 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017555 grep -v '^ *+' conftest.er1 >conftest.err
17556 rm -f conftest.er1
17557 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017558 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017559 (exit $ac_status); } && {
17560 test -z "$ac_c_werror_flag" ||
17561 test ! -s conftest.err
17562 } && test -s conftest.$ac_objext; then
Martin v. Löwisd5843682002-11-21 20:41:28 +000017563
17564cat >>confdefs.h <<\_ACEOF
17565#define HAVE_CTERMID_R 1
17566_ACEOF
17567
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017568 { $as_echo "$as_me:$LINENO: result: yes" >&5
17569$as_echo "yes" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017570else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017571 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017572sed 's/^/| /' conftest.$ac_ext >&5
17573
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017574 { $as_echo "$as_me:$LINENO: result: no" >&5
17575$as_echo "no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017576
17577fi
Martin v. Löwisd5843682002-11-21 20:41:28 +000017578
Martin v. Löwiseba40652007-08-30 20:10:57 +000017579rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17580
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017581{ $as_echo "$as_me:$LINENO: checking for flock" >&5
17582$as_echo_n "checking for flock... " >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017583cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017584/* confdefs.h. */
17585_ACEOF
17586cat confdefs.h >>conftest.$ac_ext
17587cat >>conftest.$ac_ext <<_ACEOF
17588/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017589
17590#include "confdefs.h"
17591#include <sys/file.h>
17592
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017593int
17594main ()
17595{
17596void* p = flock
17597 ;
17598 return 0;
17599}
17600_ACEOF
17601rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017602if { (ac_try="$ac_compile"
17603case "(($ac_try" in
17604 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17605 *) ac_try_echo=$ac_try;;
17606esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017607eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17608$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017609 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017610 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017611 grep -v '^ *+' conftest.er1 >conftest.err
17612 rm -f conftest.er1
17613 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017614 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017615 (exit $ac_status); } && {
17616 test -z "$ac_c_werror_flag" ||
17617 test ! -s conftest.err
17618 } && test -s conftest.$ac_objext; then
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017619
17620cat >>confdefs.h <<\_ACEOF
17621#define HAVE_FLOCK 1
17622_ACEOF
17623
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017624 { $as_echo "$as_me:$LINENO: result: yes" >&5
17625$as_echo "yes" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017626else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017627 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017628sed 's/^/| /' conftest.$ac_ext >&5
17629
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017630 { $as_echo "$as_me:$LINENO: result: no" >&5
17631$as_echo "no" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017632
17633fi
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017634
Martin v. Löwiseba40652007-08-30 20:10:57 +000017635rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17636
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017637{ $as_echo "$as_me:$LINENO: checking for getpagesize" >&5
17638$as_echo_n "checking for getpagesize... " >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017639cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017640/* confdefs.h. */
17641_ACEOF
17642cat confdefs.h >>conftest.$ac_ext
17643cat >>conftest.$ac_ext <<_ACEOF
17644/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017645
17646#include "confdefs.h"
17647#include <unistd.h>
17648
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017649int
17650main ()
17651{
17652void* p = getpagesize
17653 ;
17654 return 0;
17655}
17656_ACEOF
17657rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017658if { (ac_try="$ac_compile"
17659case "(($ac_try" in
17660 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17661 *) ac_try_echo=$ac_try;;
17662esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017663eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17664$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017665 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017666 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017667 grep -v '^ *+' conftest.er1 >conftest.err
17668 rm -f conftest.er1
17669 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017670 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017671 (exit $ac_status); } && {
17672 test -z "$ac_c_werror_flag" ||
17673 test ! -s conftest.err
17674 } && test -s conftest.$ac_objext; then
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017675
17676cat >>confdefs.h <<\_ACEOF
17677#define HAVE_GETPAGESIZE 1
17678_ACEOF
17679
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017680 { $as_echo "$as_me:$LINENO: result: yes" >&5
17681$as_echo "yes" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017682else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017683 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017684sed 's/^/| /' conftest.$ac_ext >&5
17685
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017686 { $as_echo "$as_me:$LINENO: result: no" >&5
17687$as_echo "no" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017688
17689fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017690
17691rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017692
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017693for ac_prog in true
17694do
17695 # Extract the first word of "$ac_prog", so it can be a program name with args.
17696set dummy $ac_prog; ac_word=$2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017697{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
17698$as_echo_n "checking for $ac_word... " >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017699if test "${ac_cv_prog_TRUE+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017700 $as_echo_n "(cached) " >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017701else
17702 if test -n "$TRUE"; then
17703 ac_cv_prog_TRUE="$TRUE" # Let the user override the test.
17704else
17705as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17706for as_dir in $PATH
17707do
17708 IFS=$as_save_IFS
17709 test -z "$as_dir" && as_dir=.
17710 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +000017711 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 +000017712 ac_cv_prog_TRUE="$ac_prog"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017713 $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017714 break 2
17715 fi
17716done
17717done
Martin v. Löwiseba40652007-08-30 20:10:57 +000017718IFS=$as_save_IFS
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017719
17720fi
17721fi
17722TRUE=$ac_cv_prog_TRUE
17723if test -n "$TRUE"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017724 { $as_echo "$as_me:$LINENO: result: $TRUE" >&5
17725$as_echo "$TRUE" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017726else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017727 { $as_echo "$as_me:$LINENO: result: no" >&5
17728$as_echo "no" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017729fi
17730
Martin v. Löwiseba40652007-08-30 20:10:57 +000017731
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017732 test -n "$TRUE" && break
17733done
17734test -n "$TRUE" || TRUE="/bin/true"
17735
17736
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017737{ $as_echo "$as_me:$LINENO: checking for inet_aton in -lc" >&5
17738$as_echo_n "checking for inet_aton in -lc... " >&6; }
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017739if test "${ac_cv_lib_c_inet_aton+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017740 $as_echo_n "(cached) " >&6
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017741else
17742 ac_check_lib_save_LIBS=$LIBS
17743LIBS="-lc $LIBS"
17744cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017745/* confdefs.h. */
17746_ACEOF
17747cat confdefs.h >>conftest.$ac_ext
17748cat >>conftest.$ac_ext <<_ACEOF
17749/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017750
Martin v. Löwiseba40652007-08-30 20:10:57 +000017751/* Override any GCC internal prototype to avoid an error.
17752 Use char because int might match the return type of a GCC
17753 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017754#ifdef __cplusplus
17755extern "C"
17756#endif
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017757char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017758int
17759main ()
17760{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017761return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017762 ;
17763 return 0;
17764}
17765_ACEOF
17766rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017767if { (ac_try="$ac_link"
17768case "(($ac_try" in
17769 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17770 *) ac_try_echo=$ac_try;;
17771esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017772eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17773$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017774 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017775 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017776 grep -v '^ *+' conftest.er1 >conftest.err
17777 rm -f conftest.er1
17778 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017779 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017780 (exit $ac_status); } && {
17781 test -z "$ac_c_werror_flag" ||
17782 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017783 } && test -s conftest$ac_exeext && {
17784 test "$cross_compiling" = yes ||
17785 $as_test_x conftest$ac_exeext
17786 }; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017787 ac_cv_lib_c_inet_aton=yes
17788else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017789 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017790sed 's/^/| /' conftest.$ac_ext >&5
17791
Martin v. Löwiseba40652007-08-30 20:10:57 +000017792 ac_cv_lib_c_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017793fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017794
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017795rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000017796rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017797 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017798LIBS=$ac_check_lib_save_LIBS
17799fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017800{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_inet_aton" >&5
17801$as_echo "$ac_cv_lib_c_inet_aton" >&6; }
17802if test "x$ac_cv_lib_c_inet_aton" = x""yes; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017803 $ac_cv_prog_TRUE
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017804else
17805
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017806{ $as_echo "$as_me:$LINENO: checking for inet_aton in -lresolv" >&5
17807$as_echo_n "checking for inet_aton in -lresolv... " >&6; }
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017808if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017809 $as_echo_n "(cached) " >&6
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017810else
17811 ac_check_lib_save_LIBS=$LIBS
17812LIBS="-lresolv $LIBS"
17813cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017814/* confdefs.h. */
17815_ACEOF
17816cat confdefs.h >>conftest.$ac_ext
17817cat >>conftest.$ac_ext <<_ACEOF
17818/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017819
Martin v. Löwiseba40652007-08-30 20:10:57 +000017820/* Override any GCC internal prototype to avoid an error.
17821 Use char because int might match the return type of a GCC
17822 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017823#ifdef __cplusplus
17824extern "C"
17825#endif
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017826char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017827int
17828main ()
17829{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017830return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017831 ;
17832 return 0;
17833}
17834_ACEOF
17835rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017836if { (ac_try="$ac_link"
17837case "(($ac_try" in
17838 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17839 *) ac_try_echo=$ac_try;;
17840esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017841eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17842$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017843 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017844 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017845 grep -v '^ *+' conftest.er1 >conftest.err
17846 rm -f conftest.er1
17847 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017848 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017849 (exit $ac_status); } && {
17850 test -z "$ac_c_werror_flag" ||
17851 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017852 } && test -s conftest$ac_exeext && {
17853 test "$cross_compiling" = yes ||
17854 $as_test_x conftest$ac_exeext
17855 }; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017856 ac_cv_lib_resolv_inet_aton=yes
17857else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017858 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017859sed 's/^/| /' conftest.$ac_ext >&5
17860
Martin v. Löwiseba40652007-08-30 20:10:57 +000017861 ac_cv_lib_resolv_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017862fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017863
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017864rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000017865rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017866 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017867LIBS=$ac_check_lib_save_LIBS
17868fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017869{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_inet_aton" >&5
17870$as_echo "$ac_cv_lib_resolv_inet_aton" >&6; }
17871if test "x$ac_cv_lib_resolv_inet_aton" = x""yes; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017872 cat >>confdefs.h <<_ACEOF
17873#define HAVE_LIBRESOLV 1
17874_ACEOF
17875
17876 LIBS="-lresolv $LIBS"
17877
17878fi
17879
17880
17881fi
17882
17883
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017884# On Tru64, chflags seems to be present, but calling it will
17885# exit Python
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017886{ $as_echo "$as_me:$LINENO: checking for chflags" >&5
17887$as_echo_n "checking for chflags... " >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017888if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017889 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
17890$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17891{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017892See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017893$as_echo "$as_me: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017894See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017895 { (exit 1); exit 1; }; }; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017896else
17897 cat >conftest.$ac_ext <<_ACEOF
17898/* confdefs.h. */
17899_ACEOF
17900cat confdefs.h >>conftest.$ac_ext
17901cat >>conftest.$ac_ext <<_ACEOF
17902/* end confdefs.h. */
17903
17904#include <sys/stat.h>
17905#include <unistd.h>
17906int main(int argc, char*argv[])
17907{
17908 if(chflags(argv[0], 0) != 0)
17909 return 1;
17910 return 0;
17911}
17912
17913_ACEOF
17914rm -f conftest$ac_exeext
17915if { (ac_try="$ac_link"
17916case "(($ac_try" in
17917 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17918 *) ac_try_echo=$ac_try;;
17919esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017920eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17921$as_echo "$ac_try_echo") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017922 (eval "$ac_link") 2>&5
17923 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017924 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017925 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17926 { (case "(($ac_try" in
17927 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17928 *) ac_try_echo=$ac_try;;
17929esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017930eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17931$as_echo "$ac_try_echo") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017932 (eval "$ac_try") 2>&5
17933 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017934 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017935 (exit $ac_status); }; }; then
17936
17937cat >>confdefs.h <<\_ACEOF
17938#define HAVE_CHFLAGS 1
17939_ACEOF
17940
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017941 { $as_echo "$as_me:$LINENO: result: yes" >&5
17942$as_echo "yes" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017943else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017944 $as_echo "$as_me: program exited with status $ac_status" >&5
17945$as_echo "$as_me: failed program was:" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017946sed 's/^/| /' conftest.$ac_ext >&5
17947
17948( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017949{ $as_echo "$as_me:$LINENO: result: no" >&5
17950$as_echo "no" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017951
17952fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017953rm -rf conftest.dSYM
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017954rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17955fi
17956
17957
17958
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017959{ $as_echo "$as_me:$LINENO: checking for lchflags" >&5
17960$as_echo_n "checking for lchflags... " >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017961if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017962 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
17963$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17964{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017965See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017966$as_echo "$as_me: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017967See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017968 { (exit 1); exit 1; }; }; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017969else
17970 cat >conftest.$ac_ext <<_ACEOF
17971/* confdefs.h. */
17972_ACEOF
17973cat confdefs.h >>conftest.$ac_ext
17974cat >>conftest.$ac_ext <<_ACEOF
17975/* end confdefs.h. */
17976
17977#include <sys/stat.h>
17978#include <unistd.h>
17979int main(int argc, char*argv[])
17980{
17981 if(lchflags(argv[0], 0) != 0)
17982 return 1;
17983 return 0;
17984}
17985
17986_ACEOF
17987rm -f conftest$ac_exeext
17988if { (ac_try="$ac_link"
17989case "(($ac_try" in
17990 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17991 *) ac_try_echo=$ac_try;;
17992esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017993eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17994$as_echo "$ac_try_echo") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017995 (eval "$ac_link") 2>&5
17996 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000017997 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017998 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17999 { (case "(($ac_try" in
18000 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18001 *) ac_try_echo=$ac_try;;
18002esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018003eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18004$as_echo "$ac_try_echo") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018005 (eval "$ac_try") 2>&5
18006 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018007 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018008 (exit $ac_status); }; }; then
18009
18010cat >>confdefs.h <<\_ACEOF
18011#define HAVE_LCHFLAGS 1
18012_ACEOF
18013
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018014 { $as_echo "$as_me:$LINENO: result: yes" >&5
18015$as_echo "yes" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018016else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018017 $as_echo "$as_me: program exited with status $ac_status" >&5
18018$as_echo "$as_me: failed program was:" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018019sed 's/^/| /' conftest.$ac_ext >&5
18020
18021( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018022{ $as_echo "$as_me:$LINENO: result: no" >&5
18023$as_echo "no" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018024
18025fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018026rm -rf conftest.dSYM
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000018027rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18028fi
18029
18030
18031
Ronald Oussorenf8752642006-07-06 10:13:35 +000018032case $ac_sys_system/$ac_sys_release in
18033Darwin/*)
18034 _CUR_CFLAGS="${CFLAGS}"
18035 _CUR_LDFLAGS="${LDFLAGS}"
18036 CFLAGS="${CFLAGS} -Wl,-search_paths_first"
18037 LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib"
18038 ;;
18039esac
18040
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018041{ $as_echo "$as_me:$LINENO: checking for inflateCopy in -lz" >&5
18042$as_echo_n "checking for inflateCopy in -lz... " >&6; }
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018043if test "${ac_cv_lib_z_inflateCopy+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018044 $as_echo_n "(cached) " >&6
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018045else
18046 ac_check_lib_save_LIBS=$LIBS
18047LIBS="-lz $LIBS"
18048cat >conftest.$ac_ext <<_ACEOF
18049/* confdefs.h. */
18050_ACEOF
18051cat confdefs.h >>conftest.$ac_ext
18052cat >>conftest.$ac_ext <<_ACEOF
18053/* end confdefs.h. */
18054
Martin v. Löwiseba40652007-08-30 20:10:57 +000018055/* Override any GCC internal prototype to avoid an error.
18056 Use char because int might match the return type of a GCC
18057 builtin and then its argument prototype would still apply. */
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018058#ifdef __cplusplus
18059extern "C"
18060#endif
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018061char inflateCopy ();
18062int
18063main ()
18064{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018065return inflateCopy ();
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018066 ;
18067 return 0;
18068}
18069_ACEOF
18070rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018071if { (ac_try="$ac_link"
18072case "(($ac_try" in
18073 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18074 *) ac_try_echo=$ac_try;;
18075esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018076eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18077$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018078 (eval "$ac_link") 2>conftest.er1
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018079 ac_status=$?
18080 grep -v '^ *+' conftest.er1 >conftest.err
18081 rm -f conftest.er1
18082 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018083 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018084 (exit $ac_status); } && {
18085 test -z "$ac_c_werror_flag" ||
18086 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018087 } && test -s conftest$ac_exeext && {
18088 test "$cross_compiling" = yes ||
18089 $as_test_x conftest$ac_exeext
18090 }; then
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018091 ac_cv_lib_z_inflateCopy=yes
18092else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018093 $as_echo "$as_me: failed program was:" >&5
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018094sed 's/^/| /' conftest.$ac_ext >&5
18095
Martin v. Löwiseba40652007-08-30 20:10:57 +000018096 ac_cv_lib_z_inflateCopy=no
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018097fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018098
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018099rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018100rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018101 conftest$ac_exeext conftest.$ac_ext
18102LIBS=$ac_check_lib_save_LIBS
18103fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018104{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflateCopy" >&5
18105$as_echo "$ac_cv_lib_z_inflateCopy" >&6; }
18106if test "x$ac_cv_lib_z_inflateCopy" = x""yes; then
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000018107
18108cat >>confdefs.h <<\_ACEOF
18109#define HAVE_ZLIB_COPY 1
18110_ACEOF
18111
18112fi
18113
18114
Ronald Oussorenf8752642006-07-06 10:13:35 +000018115case $ac_sys_system/$ac_sys_release in
18116Darwin/*)
18117 CFLAGS="${_CUR_CFLAGS}"
18118 LDFLAGS="${_CUR_LDFLAGS}"
18119 ;;
18120esac
18121
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018122{ $as_echo "$as_me:$LINENO: checking for hstrerror" >&5
18123$as_echo_n "checking for hstrerror... " >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018124cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018125/* confdefs.h. */
18126_ACEOF
18127cat confdefs.h >>conftest.$ac_ext
18128cat >>conftest.$ac_ext <<_ACEOF
18129/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000018130
18131#include "confdefs.h"
18132#include <netdb.h>
18133
Martin v. Löwise9416172003-05-03 10:12:45 +000018134int
18135main ()
18136{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000018137void* p = hstrerror; hstrerror(0)
Martin v. Löwise9416172003-05-03 10:12:45 +000018138 ;
18139 return 0;
18140}
18141_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000018142rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018143if { (ac_try="$ac_link"
18144case "(($ac_try" in
18145 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18146 *) ac_try_echo=$ac_try;;
18147esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018148eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18149$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018150 (eval "$ac_link") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000018151 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018152 grep -v '^ *+' conftest.er1 >conftest.err
18153 rm -f conftest.er1
18154 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018155 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018156 (exit $ac_status); } && {
18157 test -z "$ac_c_werror_flag" ||
18158 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018159 } && test -s conftest$ac_exeext && {
18160 test "$cross_compiling" = yes ||
18161 $as_test_x conftest$ac_exeext
18162 }; then
Martin v. Löwise9416172003-05-03 10:12:45 +000018163
18164cat >>confdefs.h <<\_ACEOF
18165#define HAVE_HSTRERROR 1
18166_ACEOF
18167
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018168 { $as_echo "$as_me:$LINENO: result: yes" >&5
18169$as_echo "yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018170else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018171 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018172sed 's/^/| /' conftest.$ac_ext >&5
18173
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018174 { $as_echo "$as_me:$LINENO: result: no" >&5
18175$as_echo "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018176
18177fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018178
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018179rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018180rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018181 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000018182
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018183{ $as_echo "$as_me:$LINENO: checking for inet_aton" >&5
18184$as_echo_n "checking for inet_aton... " >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018185cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018186/* confdefs.h. */
18187_ACEOF
18188cat confdefs.h >>conftest.$ac_ext
18189cat >>conftest.$ac_ext <<_ACEOF
18190/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000018191
18192#include "confdefs.h"
Martin v. Löwis86d66262006-02-17 08:40:11 +000018193#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000018194#include <sys/socket.h>
18195#include <netinet/in.h>
18196#include <arpa/inet.h>
18197
Martin v. Löwise9416172003-05-03 10:12:45 +000018198int
18199main ()
18200{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000018201void* p = inet_aton;inet_aton(0,0)
Martin v. Löwise9416172003-05-03 10:12:45 +000018202 ;
18203 return 0;
18204}
18205_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000018206rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018207if { (ac_try="$ac_link"
18208case "(($ac_try" in
18209 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18210 *) ac_try_echo=$ac_try;;
18211esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018212eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18213$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018214 (eval "$ac_link") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000018215 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018216 grep -v '^ *+' conftest.er1 >conftest.err
18217 rm -f conftest.er1
18218 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018219 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018220 (exit $ac_status); } && {
18221 test -z "$ac_c_werror_flag" ||
18222 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018223 } && test -s conftest$ac_exeext && {
18224 test "$cross_compiling" = yes ||
18225 $as_test_x conftest$ac_exeext
18226 }; then
Martin v. Löwise9416172003-05-03 10:12:45 +000018227
18228cat >>confdefs.h <<\_ACEOF
18229#define HAVE_INET_ATON 1
18230_ACEOF
18231
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018232 { $as_echo "$as_me:$LINENO: result: yes" >&5
18233$as_echo "yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018234else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018235 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018236sed 's/^/| /' conftest.$ac_ext >&5
18237
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018238 { $as_echo "$as_me:$LINENO: result: no" >&5
18239$as_echo "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018240
18241fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018242
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018243rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018244rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018245 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000018246
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018247{ $as_echo "$as_me:$LINENO: checking for inet_pton" >&5
18248$as_echo_n "checking for inet_pton... " >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018249cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018250/* confdefs.h. */
18251_ACEOF
18252cat confdefs.h >>conftest.$ac_ext
18253cat >>conftest.$ac_ext <<_ACEOF
18254/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000018255
18256#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000018257#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000018258#include <sys/socket.h>
18259#include <netinet/in.h>
18260#include <arpa/inet.h>
18261
Martin v. Löwise9416172003-05-03 10:12:45 +000018262int
18263main ()
18264{
18265void* p = inet_pton
18266 ;
18267 return 0;
18268}
18269_ACEOF
18270rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018271if { (ac_try="$ac_compile"
18272case "(($ac_try" in
18273 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18274 *) ac_try_echo=$ac_try;;
18275esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018276eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18277$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018278 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000018279 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018280 grep -v '^ *+' conftest.er1 >conftest.err
18281 rm -f conftest.er1
18282 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018283 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018284 (exit $ac_status); } && {
18285 test -z "$ac_c_werror_flag" ||
18286 test ! -s conftest.err
18287 } && test -s conftest.$ac_objext; then
Martin v. Löwise9416172003-05-03 10:12:45 +000018288
18289cat >>confdefs.h <<\_ACEOF
18290#define HAVE_INET_PTON 1
18291_ACEOF
18292
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018293 { $as_echo "$as_me:$LINENO: result: yes" >&5
18294$as_echo "yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018295else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018296 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018297sed 's/^/| /' conftest.$ac_ext >&5
18298
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018299 { $as_echo "$as_me:$LINENO: result: no" >&5
18300$as_echo "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000018301
18302fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018303
18304rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000018305
Martin v. Löwisd6640d42003-07-06 09:29:52 +000018306# On some systems, setgroups is in unistd.h, on others, in grp.h
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018307{ $as_echo "$as_me:$LINENO: checking for setgroups" >&5
18308$as_echo_n "checking for setgroups... " >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000018309cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018310/* confdefs.h. */
18311_ACEOF
18312cat confdefs.h >>conftest.$ac_ext
18313cat >>conftest.$ac_ext <<_ACEOF
18314/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000018315
18316#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000018317#include <unistd.h>
Martin v. Löwisd6640d42003-07-06 09:29:52 +000018318#ifdef HAVE_GRP_H
18319#include <grp.h>
18320#endif
Martin v. Löwisd5843682002-11-21 20:41:28 +000018321
Martin v. Löwisd5843682002-11-21 20:41:28 +000018322int
18323main ()
18324{
18325void* p = setgroups
18326 ;
18327 return 0;
18328}
18329_ACEOF
18330rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018331if { (ac_try="$ac_compile"
18332case "(($ac_try" in
18333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18334 *) ac_try_echo=$ac_try;;
18335esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018336eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18337$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018338 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd5843682002-11-21 20:41:28 +000018339 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018340 grep -v '^ *+' conftest.er1 >conftest.err
18341 rm -f conftest.er1
18342 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018343 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018344 (exit $ac_status); } && {
18345 test -z "$ac_c_werror_flag" ||
18346 test ! -s conftest.err
18347 } && test -s conftest.$ac_objext; then
Martin v. Löwisd5843682002-11-21 20:41:28 +000018348
18349cat >>confdefs.h <<\_ACEOF
18350#define HAVE_SETGROUPS 1
18351_ACEOF
18352
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018353 { $as_echo "$as_me:$LINENO: result: yes" >&5
18354$as_echo "yes" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000018355else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018356 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018357sed 's/^/| /' conftest.$ac_ext >&5
18358
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018359 { $as_echo "$as_me:$LINENO: result: no" >&5
18360$as_echo "no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000018361
18362fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018363
18364rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd5843682002-11-21 20:41:28 +000018365
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018366# check for openpty and forkpty
18367
Martin v. Löwis11437992002-04-12 09:54:03 +000018368
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018369for ac_func in openpty
18370do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018371as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18372{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18373$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018374if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018375 $as_echo_n "(cached) " >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018376else
Martin v. Löwis11437992002-04-12 09:54:03 +000018377 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018378/* confdefs.h. */
18379_ACEOF
18380cat confdefs.h >>conftest.$ac_ext
18381cat >>conftest.$ac_ext <<_ACEOF
18382/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018383/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18384 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18385#define $ac_func innocuous_$ac_func
18386
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018387/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018388 which can conflict with char $ac_func (); below.
18389 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018390 <limits.h> exists even on freestanding compilers. */
18391
18392#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018393# include <limits.h>
18394#else
18395# include <assert.h>
18396#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018397
18398#undef $ac_func
18399
Martin v. Löwiseba40652007-08-30 20:10:57 +000018400/* Override any GCC internal prototype to avoid an error.
18401 Use char because int might match the return type of a GCC
18402 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018403#ifdef __cplusplus
18404extern "C"
18405#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018406char $ac_func ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018407/* The GNU C library defines this for functions which it implements
18408 to always fail with ENOSYS. Some functions are actually named
18409 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018410#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018411choke me
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018412#endif
18413
Skip Montanaro6dead952003-09-25 14:50:04 +000018414int
18415main ()
18416{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018417return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018418 ;
18419 return 0;
18420}
18421_ACEOF
18422rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018423if { (ac_try="$ac_link"
18424case "(($ac_try" in
18425 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18426 *) ac_try_echo=$ac_try;;
18427esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018428eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18429$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018430 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018431 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018432 grep -v '^ *+' conftest.er1 >conftest.err
18433 rm -f conftest.er1
18434 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018435 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018436 (exit $ac_status); } && {
18437 test -z "$ac_c_werror_flag" ||
18438 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018439 } && test -s conftest$ac_exeext && {
18440 test "$cross_compiling" = yes ||
18441 $as_test_x conftest$ac_exeext
18442 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018443 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018444else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018445 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018446sed 's/^/| /' conftest.$ac_ext >&5
18447
Martin v. Löwiseba40652007-08-30 20:10:57 +000018448 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018449fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018450
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018451rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018452rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018453 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018454fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018455ac_res=`eval 'as_val=${'$as_ac_var'}
18456 $as_echo "$as_val"'`
18457 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18458$as_echo "$ac_res" >&6; }
18459as_val=`eval 'as_val=${'$as_ac_var'}
18460 $as_echo "$as_val"'`
18461 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018462 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018463#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018464_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018465
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018466else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018467 { $as_echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
18468$as_echo_n "checking for openpty in -lutil... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000018469if test "${ac_cv_lib_util_openpty+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018470 $as_echo_n "(cached) " >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018471else
Martin v. Löwis11437992002-04-12 09:54:03 +000018472 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018473LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000018474cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018475/* confdefs.h. */
18476_ACEOF
18477cat confdefs.h >>conftest.$ac_ext
18478cat >>conftest.$ac_ext <<_ACEOF
18479/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018480
Martin v. Löwiseba40652007-08-30 20:10:57 +000018481/* Override any GCC internal prototype to avoid an error.
18482 Use char because int might match the return type of a GCC
18483 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018484#ifdef __cplusplus
18485extern "C"
18486#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018487char openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018488int
18489main ()
18490{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018491return openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018492 ;
18493 return 0;
18494}
18495_ACEOF
18496rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018497if { (ac_try="$ac_link"
18498case "(($ac_try" in
18499 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18500 *) ac_try_echo=$ac_try;;
18501esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018502eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18503$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018504 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018505 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018506 grep -v '^ *+' conftest.er1 >conftest.err
18507 rm -f conftest.er1
18508 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018509 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018510 (exit $ac_status); } && {
18511 test -z "$ac_c_werror_flag" ||
18512 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018513 } && test -s conftest$ac_exeext && {
18514 test "$cross_compiling" = yes ||
18515 $as_test_x conftest$ac_exeext
18516 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018517 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000018518else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018519 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018520sed 's/^/| /' conftest.$ac_ext >&5
18521
Martin v. Löwiseba40652007-08-30 20:10:57 +000018522 ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018523fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018524
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018525rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018526rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018527 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018528LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018529fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018530{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
18531$as_echo "$ac_cv_lib_util_openpty" >&6; }
18532if test "x$ac_cv_lib_util_openpty" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018533 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018534#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018535_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018536 LIBS="$LIBS -lutil"
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018537else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018538 { $as_echo "$as_me:$LINENO: checking for openpty in -lbsd" >&5
18539$as_echo_n "checking for openpty in -lbsd... " >&6; }
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018540if test "${ac_cv_lib_bsd_openpty+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018541 $as_echo_n "(cached) " >&6
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018542else
18543 ac_check_lib_save_LIBS=$LIBS
18544LIBS="-lbsd $LIBS"
18545cat >conftest.$ac_ext <<_ACEOF
18546/* confdefs.h. */
18547_ACEOF
18548cat confdefs.h >>conftest.$ac_ext
18549cat >>conftest.$ac_ext <<_ACEOF
18550/* end confdefs.h. */
18551
Martin v. Löwiseba40652007-08-30 20:10:57 +000018552/* Override any GCC internal prototype to avoid an error.
18553 Use char because int might match the return type of a GCC
18554 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018555#ifdef __cplusplus
18556extern "C"
18557#endif
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018558char openpty ();
18559int
18560main ()
18561{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018562return openpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018563 ;
18564 return 0;
18565}
18566_ACEOF
18567rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018568if { (ac_try="$ac_link"
18569case "(($ac_try" in
18570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18571 *) ac_try_echo=$ac_try;;
18572esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018573eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18574$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018575 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018576 ac_status=$?
18577 grep -v '^ *+' conftest.er1 >conftest.err
18578 rm -f conftest.er1
18579 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018580 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018581 (exit $ac_status); } && {
18582 test -z "$ac_c_werror_flag" ||
18583 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018584 } && test -s conftest$ac_exeext && {
18585 test "$cross_compiling" = yes ||
18586 $as_test_x conftest$ac_exeext
18587 }; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018588 ac_cv_lib_bsd_openpty=yes
18589else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018590 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018591sed 's/^/| /' conftest.$ac_ext >&5
18592
Martin v. Löwiseba40652007-08-30 20:10:57 +000018593 ac_cv_lib_bsd_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018594fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018595
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018596rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018597rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018598 conftest$ac_exeext conftest.$ac_ext
18599LIBS=$ac_check_lib_save_LIBS
18600fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018601{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_openpty" >&5
18602$as_echo "$ac_cv_lib_bsd_openpty" >&6; }
18603if test "x$ac_cv_lib_bsd_openpty" = x""yes; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018604 cat >>confdefs.h <<\_ACEOF
18605#define HAVE_OPENPTY 1
18606_ACEOF
18607 LIBS="$LIBS -lbsd"
18608fi
18609
18610
18611fi
18612
Fred Drake8cef4cf2000-06-28 16:40:38 +000018613
18614fi
18615done
18616
Martin v. Löwis11437992002-04-12 09:54:03 +000018617
Fred Drake8cef4cf2000-06-28 16:40:38 +000018618for ac_func in forkpty
18619do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018620as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18621{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18622$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018623if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018624 $as_echo_n "(cached) " >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018625else
Martin v. Löwis11437992002-04-12 09:54:03 +000018626 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018627/* confdefs.h. */
18628_ACEOF
18629cat confdefs.h >>conftest.$ac_ext
18630cat >>conftest.$ac_ext <<_ACEOF
18631/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018632/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18633 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18634#define $ac_func innocuous_$ac_func
18635
Fred Drake8cef4cf2000-06-28 16:40:38 +000018636/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018637 which can conflict with char $ac_func (); below.
18638 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018639 <limits.h> exists even on freestanding compilers. */
18640
18641#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018642# include <limits.h>
18643#else
18644# include <assert.h>
18645#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018646
18647#undef $ac_func
18648
Martin v. Löwiseba40652007-08-30 20:10:57 +000018649/* Override any GCC internal prototype to avoid an error.
18650 Use char because int might match the return type of a GCC
18651 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018652#ifdef __cplusplus
18653extern "C"
18654#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018655char $ac_func ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000018656/* The GNU C library defines this for functions which it implements
18657 to always fail with ENOSYS. Some functions are actually named
18658 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018659#if defined __stub_$ac_func || defined __stub___$ac_func
Fred Drake8cef4cf2000-06-28 16:40:38 +000018660choke me
Fred Drake8cef4cf2000-06-28 16:40:38 +000018661#endif
18662
Skip Montanaro6dead952003-09-25 14:50:04 +000018663int
18664main ()
18665{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018666return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018667 ;
18668 return 0;
18669}
18670_ACEOF
18671rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018672if { (ac_try="$ac_link"
18673case "(($ac_try" in
18674 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18675 *) ac_try_echo=$ac_try;;
18676esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018677eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18678$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018679 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018680 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018681 grep -v '^ *+' conftest.er1 >conftest.err
18682 rm -f conftest.er1
18683 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018684 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018685 (exit $ac_status); } && {
18686 test -z "$ac_c_werror_flag" ||
18687 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018688 } && test -s conftest$ac_exeext && {
18689 test "$cross_compiling" = yes ||
18690 $as_test_x conftest$ac_exeext
18691 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018692 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018693else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018694 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018695sed 's/^/| /' conftest.$ac_ext >&5
18696
Martin v. Löwiseba40652007-08-30 20:10:57 +000018697 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018698fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018699
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018700rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018701rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018702 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018703fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018704ac_res=`eval 'as_val=${'$as_ac_var'}
18705 $as_echo "$as_val"'`
18706 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18707$as_echo "$ac_res" >&6; }
18708as_val=`eval 'as_val=${'$as_ac_var'}
18709 $as_echo "$as_val"'`
18710 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018711 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018712#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018713_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018714
Fred Drake8cef4cf2000-06-28 16:40:38 +000018715else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018716 { $as_echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
18717$as_echo_n "checking for forkpty in -lutil... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000018718if test "${ac_cv_lib_util_forkpty+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018719 $as_echo_n "(cached) " >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018720else
Martin v. Löwis11437992002-04-12 09:54:03 +000018721 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018722LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000018723cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018724/* confdefs.h. */
18725_ACEOF
18726cat confdefs.h >>conftest.$ac_ext
18727cat >>conftest.$ac_ext <<_ACEOF
18728/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018729
Martin v. Löwiseba40652007-08-30 20:10:57 +000018730/* Override any GCC internal prototype to avoid an error.
18731 Use char because int might match the return type of a GCC
18732 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018733#ifdef __cplusplus
18734extern "C"
18735#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018736char forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018737int
18738main ()
18739{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018740return forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018741 ;
18742 return 0;
18743}
18744_ACEOF
18745rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018746if { (ac_try="$ac_link"
18747case "(($ac_try" in
18748 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18749 *) ac_try_echo=$ac_try;;
18750esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018751eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18752$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018753 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018754 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018755 grep -v '^ *+' conftest.er1 >conftest.err
18756 rm -f conftest.er1
18757 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018758 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018759 (exit $ac_status); } && {
18760 test -z "$ac_c_werror_flag" ||
18761 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018762 } && test -s conftest$ac_exeext && {
18763 test "$cross_compiling" = yes ||
18764 $as_test_x conftest$ac_exeext
18765 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018766 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000018767else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018768 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018769sed 's/^/| /' conftest.$ac_ext >&5
18770
Martin v. Löwiseba40652007-08-30 20:10:57 +000018771 ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018772fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018773
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018774rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018775rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018776 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018777LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018778fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018779{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
18780$as_echo "$ac_cv_lib_util_forkpty" >&6; }
18781if test "x$ac_cv_lib_util_forkpty" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018782 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018783#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018784_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018785 LIBS="$LIBS -lutil"
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018786else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018787 { $as_echo "$as_me:$LINENO: checking for forkpty in -lbsd" >&5
18788$as_echo_n "checking for forkpty in -lbsd... " >&6; }
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018789if test "${ac_cv_lib_bsd_forkpty+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018790 $as_echo_n "(cached) " >&6
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018791else
18792 ac_check_lib_save_LIBS=$LIBS
18793LIBS="-lbsd $LIBS"
18794cat >conftest.$ac_ext <<_ACEOF
18795/* confdefs.h. */
18796_ACEOF
18797cat confdefs.h >>conftest.$ac_ext
18798cat >>conftest.$ac_ext <<_ACEOF
18799/* end confdefs.h. */
18800
Martin v. Löwiseba40652007-08-30 20:10:57 +000018801/* Override any GCC internal prototype to avoid an error.
18802 Use char because int might match the return type of a GCC
18803 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018804#ifdef __cplusplus
18805extern "C"
18806#endif
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018807char forkpty ();
18808int
18809main ()
18810{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018811return forkpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018812 ;
18813 return 0;
18814}
18815_ACEOF
18816rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018817if { (ac_try="$ac_link"
18818case "(($ac_try" in
18819 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18820 *) ac_try_echo=$ac_try;;
18821esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018822eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18823$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018824 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018825 ac_status=$?
18826 grep -v '^ *+' conftest.er1 >conftest.err
18827 rm -f conftest.er1
18828 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018829 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018830 (exit $ac_status); } && {
18831 test -z "$ac_c_werror_flag" ||
18832 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018833 } && test -s conftest$ac_exeext && {
18834 test "$cross_compiling" = yes ||
18835 $as_test_x conftest$ac_exeext
18836 }; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018837 ac_cv_lib_bsd_forkpty=yes
18838else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018839 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018840sed 's/^/| /' conftest.$ac_ext >&5
18841
Martin v. Löwiseba40652007-08-30 20:10:57 +000018842 ac_cv_lib_bsd_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018843fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018844
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018845rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000018846rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018847 conftest$ac_exeext conftest.$ac_ext
18848LIBS=$ac_check_lib_save_LIBS
18849fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018850{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_forkpty" >&5
18851$as_echo "$ac_cv_lib_bsd_forkpty" >&6; }
18852if test "x$ac_cv_lib_bsd_forkpty" = x""yes; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018853 cat >>confdefs.h <<\_ACEOF
18854#define HAVE_FORKPTY 1
18855_ACEOF
18856 LIBS="$LIBS -lbsd"
18857fi
18858
18859
18860fi
18861
Fred Drake8cef4cf2000-06-28 16:40:38 +000018862
18863fi
18864done
18865
Jack Jansendd19cf82001-12-06 22:36:17 +000018866
Brett Cannonaa5778d2008-03-18 04:09:00 +000018867# Stuff for expat.
18868
18869for ac_func in memmove
18870do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018871as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18872{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18873$as_echo_n "checking for $ac_func... " >&6; }
Brett Cannonaa5778d2008-03-18 04:09:00 +000018874if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018875 $as_echo_n "(cached) " >&6
Brett Cannonaa5778d2008-03-18 04:09:00 +000018876else
18877 cat >conftest.$ac_ext <<_ACEOF
18878/* confdefs.h. */
18879_ACEOF
18880cat confdefs.h >>conftest.$ac_ext
18881cat >>conftest.$ac_ext <<_ACEOF
18882/* end confdefs.h. */
18883/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18884 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18885#define $ac_func innocuous_$ac_func
18886
18887/* System header to define __stub macros and hopefully few prototypes,
18888 which can conflict with char $ac_func (); below.
18889 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18890 <limits.h> exists even on freestanding compilers. */
18891
18892#ifdef __STDC__
18893# include <limits.h>
18894#else
18895# include <assert.h>
18896#endif
18897
18898#undef $ac_func
18899
18900/* Override any GCC internal prototype to avoid an error.
18901 Use char because int might match the return type of a GCC
18902 builtin and then its argument prototype would still apply. */
18903#ifdef __cplusplus
18904extern "C"
18905#endif
18906char $ac_func ();
18907/* The GNU C library defines this for functions which it implements
18908 to always fail with ENOSYS. Some functions are actually named
18909 something starting with __ and the normal name is an alias. */
18910#if defined __stub_$ac_func || defined __stub___$ac_func
18911choke me
18912#endif
18913
18914int
18915main ()
18916{
18917return $ac_func ();
18918 ;
18919 return 0;
18920}
18921_ACEOF
18922rm -f conftest.$ac_objext conftest$ac_exeext
18923if { (ac_try="$ac_link"
18924case "(($ac_try" in
18925 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18926 *) ac_try_echo=$ac_try;;
18927esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018928eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18929$as_echo "$ac_try_echo") >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018930 (eval "$ac_link") 2>conftest.er1
18931 ac_status=$?
18932 grep -v '^ *+' conftest.er1 >conftest.err
18933 rm -f conftest.er1
18934 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018935 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018936 (exit $ac_status); } && {
18937 test -z "$ac_c_werror_flag" ||
18938 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018939 } && test -s conftest$ac_exeext && {
18940 test "$cross_compiling" = yes ||
18941 $as_test_x conftest$ac_exeext
18942 }; then
Brett Cannonaa5778d2008-03-18 04:09:00 +000018943 eval "$as_ac_var=yes"
18944else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018945 $as_echo "$as_me: failed program was:" >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018946sed 's/^/| /' conftest.$ac_ext >&5
18947
18948 eval "$as_ac_var=no"
18949fi
18950
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018951rm -rf conftest.dSYM
Brett Cannonaa5778d2008-03-18 04:09:00 +000018952rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18953 conftest$ac_exeext conftest.$ac_ext
18954fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018955ac_res=`eval 'as_val=${'$as_ac_var'}
18956 $as_echo "$as_val"'`
18957 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18958$as_echo "$ac_res" >&6; }
18959as_val=`eval 'as_val=${'$as_ac_var'}
18960 $as_echo "$as_val"'`
18961 if test "x$as_val" = x""yes; then
Brett Cannonaa5778d2008-03-18 04:09:00 +000018962 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018963#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Brett Cannonaa5778d2008-03-18 04:09:00 +000018964_ACEOF
18965
18966fi
18967done
18968
18969
Michael W. Hudson54241132001-12-07 15:38:26 +000018970# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000018971
18972
18973
18974
18975
18976
Fred Drake8cef4cf2000-06-28 16:40:38 +000018977for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
18978do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018979as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18980{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18981$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018982if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000018983 $as_echo_n "(cached) " >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018984else
Martin v. Löwis11437992002-04-12 09:54:03 +000018985 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018986/* confdefs.h. */
18987_ACEOF
18988cat confdefs.h >>conftest.$ac_ext
18989cat >>conftest.$ac_ext <<_ACEOF
18990/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018991/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18992 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18993#define $ac_func innocuous_$ac_func
18994
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018995/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018996 which can conflict with char $ac_func (); below.
18997 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018998 <limits.h> exists even on freestanding compilers. */
18999
19000#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019001# include <limits.h>
19002#else
19003# include <assert.h>
19004#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019005
19006#undef $ac_func
19007
Martin v. Löwiseba40652007-08-30 20:10:57 +000019008/* Override any GCC internal prototype to avoid an error.
19009 Use char because int might match the return type of a GCC
19010 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019011#ifdef __cplusplus
19012extern "C"
19013#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019014char $ac_func ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000019015/* The GNU C library defines this for functions which it implements
19016 to always fail with ENOSYS. Some functions are actually named
19017 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019018#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossumf98e2a71999-01-06 18:53:34 +000019019choke me
Guido van Rossumf98e2a71999-01-06 18:53:34 +000019020#endif
19021
Skip Montanaro6dead952003-09-25 14:50:04 +000019022int
19023main ()
19024{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019025return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019026 ;
19027 return 0;
19028}
19029_ACEOF
19030rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019031if { (ac_try="$ac_link"
19032case "(($ac_try" in
19033 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19034 *) ac_try_echo=$ac_try;;
19035esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019036eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19037$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019038 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019039 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019040 grep -v '^ *+' conftest.er1 >conftest.err
19041 rm -f conftest.er1
19042 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019043 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019044 (exit $ac_status); } && {
19045 test -z "$ac_c_werror_flag" ||
19046 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019047 } && test -s conftest$ac_exeext && {
19048 test "$cross_compiling" = yes ||
19049 $as_test_x conftest$ac_exeext
19050 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019051 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019052else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019053 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019054sed 's/^/| /' conftest.$ac_ext >&5
19055
Martin v. Löwiseba40652007-08-30 20:10:57 +000019056 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019057fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019058
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019059rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019060rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019061 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019062fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019063ac_res=`eval 'as_val=${'$as_ac_var'}
19064 $as_echo "$as_val"'`
19065 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19066$as_echo "$ac_res" >&6; }
19067as_val=`eval 'as_val=${'$as_ac_var'}
19068 $as_echo "$as_val"'`
19069 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019070 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019071#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019072_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000019073
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019074fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000019075done
19076
Michael W. Hudson54241132001-12-07 15:38:26 +000019077
Martin v. Löwis11437992002-04-12 09:54:03 +000019078
19079
19080
Brett Cannonaa5778d2008-03-18 04:09:00 +000019081for ac_func in dup2 getcwd strdup
Thomas Wouters3a584202000-08-05 23:28:51 +000019082do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019083as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19084{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19085$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019086if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019087 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019088else
Martin v. Löwis11437992002-04-12 09:54:03 +000019089 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019090/* confdefs.h. */
19091_ACEOF
19092cat confdefs.h >>conftest.$ac_ext
19093cat >>conftest.$ac_ext <<_ACEOF
19094/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019095/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19096 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19097#define $ac_func innocuous_$ac_func
19098
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000019099/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019100 which can conflict with char $ac_func (); below.
19101 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019102 <limits.h> exists even on freestanding compilers. */
19103
19104#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019105# include <limits.h>
19106#else
19107# include <assert.h>
19108#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019109
19110#undef $ac_func
19111
Martin v. Löwiseba40652007-08-30 20:10:57 +000019112/* Override any GCC internal prototype to avoid an error.
19113 Use char because int might match the return type of a GCC
19114 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019115#ifdef __cplusplus
19116extern "C"
19117#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019118char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000019119/* The GNU C library defines this for functions which it implements
19120 to always fail with ENOSYS. Some functions are actually named
19121 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019122#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum627b2d71993-12-24 10:39:16 +000019123choke me
Guido van Rossum627b2d71993-12-24 10:39:16 +000019124#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019125
Skip Montanaro6dead952003-09-25 14:50:04 +000019126int
19127main ()
19128{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019129return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019130 ;
19131 return 0;
19132}
19133_ACEOF
19134rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019135if { (ac_try="$ac_link"
19136case "(($ac_try" in
19137 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19138 *) ac_try_echo=$ac_try;;
19139esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019140eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19141$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019142 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019143 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019144 grep -v '^ *+' conftest.er1 >conftest.err
19145 rm -f conftest.er1
19146 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019147 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019148 (exit $ac_status); } && {
19149 test -z "$ac_c_werror_flag" ||
19150 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019151 } && test -s conftest$ac_exeext && {
19152 test "$cross_compiling" = yes ||
19153 $as_test_x conftest$ac_exeext
19154 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019155 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000019156else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019157 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019158sed 's/^/| /' conftest.$ac_ext >&5
19159
Martin v. Löwiseba40652007-08-30 20:10:57 +000019160 eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000019161fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019162
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019163rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019164rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019165 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000019166fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019167ac_res=`eval 'as_val=${'$as_ac_var'}
19168 $as_echo "$as_val"'`
19169 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19170$as_echo "$ac_res" >&6; }
19171as_val=`eval 'as_val=${'$as_ac_var'}
19172 $as_echo "$as_val"'`
19173 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019174 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019175#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019176_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000019177
Martin v. Löwis1142de32002-03-29 16:28:31 +000019178else
Martin v. Löwiseba40652007-08-30 20:10:57 +000019179 case " $LIBOBJS " in
Skip Montanarof0d5f792004-08-15 14:08:23 +000019180 *" $ac_func.$ac_objext "* ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000019181 *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19182 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000019183esac
19184
Martin v. Löwis1142de32002-03-29 16:28:31 +000019185fi
19186done
19187
19188
Martin v. Löwis11437992002-04-12 09:54:03 +000019189
Martin v. Löwis1142de32002-03-29 16:28:31 +000019190for ac_func in getpgrp
19191do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019192as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19193{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19194$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019195if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019196 $as_echo_n "(cached) " >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000019197else
Martin v. Löwis11437992002-04-12 09:54:03 +000019198 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019199/* confdefs.h. */
19200_ACEOF
19201cat confdefs.h >>conftest.$ac_ext
19202cat >>conftest.$ac_ext <<_ACEOF
19203/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019204/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19205 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19206#define $ac_func innocuous_$ac_func
19207
Martin v. Löwis1142de32002-03-29 16:28:31 +000019208/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019209 which can conflict with char $ac_func (); below.
19210 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019211 <limits.h> exists even on freestanding compilers. */
19212
19213#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019214# include <limits.h>
19215#else
19216# include <assert.h>
19217#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019218
19219#undef $ac_func
19220
Martin v. Löwiseba40652007-08-30 20:10:57 +000019221/* Override any GCC internal prototype to avoid an error.
19222 Use char because int might match the return type of a GCC
19223 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019224#ifdef __cplusplus
19225extern "C"
19226#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019227char $ac_func ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000019228/* The GNU C library defines this for functions which it implements
19229 to always fail with ENOSYS. Some functions are actually named
19230 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019231#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis1142de32002-03-29 16:28:31 +000019232choke me
Martin v. Löwis1142de32002-03-29 16:28:31 +000019233#endif
19234
Skip Montanaro6dead952003-09-25 14:50:04 +000019235int
19236main ()
19237{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019238return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019239 ;
19240 return 0;
19241}
19242_ACEOF
19243rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019244if { (ac_try="$ac_link"
19245case "(($ac_try" in
19246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19247 *) ac_try_echo=$ac_try;;
19248esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019249eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19250$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019251 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019252 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019253 grep -v '^ *+' conftest.er1 >conftest.err
19254 rm -f conftest.er1
19255 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019256 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019257 (exit $ac_status); } && {
19258 test -z "$ac_c_werror_flag" ||
19259 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019260 } && test -s conftest$ac_exeext && {
19261 test "$cross_compiling" = yes ||
19262 $as_test_x conftest$ac_exeext
19263 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019264 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000019265else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019266 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019267sed 's/^/| /' conftest.$ac_ext >&5
19268
Martin v. Löwiseba40652007-08-30 20:10:57 +000019269 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019270fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019271
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019272rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019273rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019274 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019275fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019276ac_res=`eval 'as_val=${'$as_ac_var'}
19277 $as_echo "$as_val"'`
19278 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19279$as_echo "$ac_res" >&6; }
19280as_val=`eval 'as_val=${'$as_ac_var'}
19281 $as_echo "$as_val"'`
19282 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019283 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019284#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019285_ACEOF
19286 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019287/* confdefs.h. */
19288_ACEOF
19289cat confdefs.h >>conftest.$ac_ext
19290cat >>conftest.$ac_ext <<_ACEOF
19291/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019292#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000019293int
19294main ()
19295{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019296getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000019297 ;
19298 return 0;
19299}
19300_ACEOF
19301rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019302if { (ac_try="$ac_compile"
19303case "(($ac_try" in
19304 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19305 *) ac_try_echo=$ac_try;;
19306esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019307eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19308$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019309 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019310 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019311 grep -v '^ *+' conftest.er1 >conftest.err
19312 rm -f conftest.er1
19313 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019314 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019315 (exit $ac_status); } && {
19316 test -z "$ac_c_werror_flag" ||
19317 test ! -s conftest.err
19318 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019319
19320cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019321#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019322_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000019323
Martin v. Löwis11437992002-04-12 09:54:03 +000019324
Guido van Rossumf78abae1997-01-21 22:02:36 +000019325else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019326 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019327sed 's/^/| /' conftest.$ac_ext >&5
19328
Martin v. Löwiseba40652007-08-30 20:10:57 +000019329
Guido van Rossum627b2d71993-12-24 10:39:16 +000019330fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019331
19332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000019333
Guido van Rossum627b2d71993-12-24 10:39:16 +000019334fi
Thomas Wouters3a584202000-08-05 23:28:51 +000019335done
Guido van Rossum627b2d71993-12-24 10:39:16 +000019336
Jack Jansen150753c2003-03-29 22:07:47 +000019337
19338for ac_func in setpgrp
19339do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019340as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19341{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19342$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019343if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019344 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019345else
Martin v. Löwis11437992002-04-12 09:54:03 +000019346 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019347/* confdefs.h. */
19348_ACEOF
19349cat confdefs.h >>conftest.$ac_ext
19350cat >>conftest.$ac_ext <<_ACEOF
19351/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019352/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19353 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19354#define $ac_func innocuous_$ac_func
19355
Jack Jansen150753c2003-03-29 22:07:47 +000019356/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019357 which can conflict with char $ac_func (); below.
19358 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019359 <limits.h> exists even on freestanding compilers. */
19360
19361#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019362# include <limits.h>
19363#else
19364# include <assert.h>
19365#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019366
19367#undef $ac_func
19368
Martin v. Löwiseba40652007-08-30 20:10:57 +000019369/* Override any GCC internal prototype to avoid an error.
19370 Use char because int might match the return type of a GCC
19371 builtin and then its argument prototype would still apply. */
Jack Jansen150753c2003-03-29 22:07:47 +000019372#ifdef __cplusplus
19373extern "C"
Martin v. Löwis11437992002-04-12 09:54:03 +000019374#endif
Jack Jansen150753c2003-03-29 22:07:47 +000019375char $ac_func ();
Jack Jansen150753c2003-03-29 22:07:47 +000019376/* The GNU C library defines this for functions which it implements
19377 to always fail with ENOSYS. Some functions are actually named
19378 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019379#if defined __stub_$ac_func || defined __stub___$ac_func
Jack Jansen150753c2003-03-29 22:07:47 +000019380choke me
Jack Jansen150753c2003-03-29 22:07:47 +000019381#endif
19382
Skip Montanaro6dead952003-09-25 14:50:04 +000019383int
19384main ()
19385{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019386return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019387 ;
19388 return 0;
19389}
19390_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000019391rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019392if { (ac_try="$ac_link"
19393case "(($ac_try" in
19394 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19395 *) ac_try_echo=$ac_try;;
19396esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019397eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19398$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019399 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019400 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019401 grep -v '^ *+' conftest.er1 >conftest.err
19402 rm -f conftest.er1
19403 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019404 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019405 (exit $ac_status); } && {
19406 test -z "$ac_c_werror_flag" ||
19407 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019408 } && test -s conftest$ac_exeext && {
19409 test "$cross_compiling" = yes ||
19410 $as_test_x conftest$ac_exeext
19411 }; then
Jack Jansen150753c2003-03-29 22:07:47 +000019412 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000019413else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019414 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019415sed 's/^/| /' conftest.$ac_ext >&5
19416
Martin v. Löwiseba40652007-08-30 20:10:57 +000019417 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019418fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019419
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019420rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019421rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019422 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019423fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019424ac_res=`eval 'as_val=${'$as_ac_var'}
19425 $as_echo "$as_val"'`
19426 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19427$as_echo "$ac_res" >&6; }
19428as_val=`eval 'as_val=${'$as_ac_var'}
19429 $as_echo "$as_val"'`
19430 if test "x$as_val" = x""yes; then
Jack Jansen150753c2003-03-29 22:07:47 +000019431 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019432#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Jack Jansen150753c2003-03-29 22:07:47 +000019433_ACEOF
19434 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019435/* confdefs.h. */
19436_ACEOF
19437cat confdefs.h >>conftest.$ac_ext
19438cat >>conftest.$ac_ext <<_ACEOF
19439/* end confdefs.h. */
Jack Jansen150753c2003-03-29 22:07:47 +000019440#include <unistd.h>
Jack Jansen150753c2003-03-29 22:07:47 +000019441int
19442main ()
19443{
19444setpgrp(0,0);
19445 ;
19446 return 0;
19447}
19448_ACEOF
19449rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019450if { (ac_try="$ac_compile"
19451case "(($ac_try" in
19452 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19453 *) ac_try_echo=$ac_try;;
19454esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019455eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19456$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019457 (eval "$ac_compile") 2>conftest.er1
Jack Jansen150753c2003-03-29 22:07:47 +000019458 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019459 grep -v '^ *+' conftest.er1 >conftest.err
19460 rm -f conftest.er1
19461 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019462 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019463 (exit $ac_status); } && {
19464 test -z "$ac_c_werror_flag" ||
19465 test ! -s conftest.err
19466 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019467
19468cat >>confdefs.h <<\_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000019469#define SETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019470_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019471
Jack Jansen150753c2003-03-29 22:07:47 +000019472
19473else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019474 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019475sed 's/^/| /' conftest.$ac_ext >&5
19476
Martin v. Löwiseba40652007-08-30 20:10:57 +000019477
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019478fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019479
19480rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Jack Jansen150753c2003-03-29 22:07:47 +000019481
19482fi
19483done
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019484
Martin v. Löwis11437992002-04-12 09:54:03 +000019485
Thomas Wouters3a584202000-08-05 23:28:51 +000019486for ac_func in gettimeofday
19487do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019488as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19489{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19490$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019491if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019492 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019493else
Martin v. Löwis11437992002-04-12 09:54:03 +000019494 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019495/* confdefs.h. */
19496_ACEOF
19497cat confdefs.h >>conftest.$ac_ext
19498cat >>conftest.$ac_ext <<_ACEOF
19499/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019500/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19501 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19502#define $ac_func innocuous_$ac_func
19503
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000019504/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019505 which can conflict with char $ac_func (); below.
19506 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019507 <limits.h> exists even on freestanding compilers. */
19508
19509#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019510# include <limits.h>
19511#else
19512# include <assert.h>
19513#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019514
19515#undef $ac_func
19516
Martin v. Löwiseba40652007-08-30 20:10:57 +000019517/* Override any GCC internal prototype to avoid an error.
19518 Use char because int might match the return type of a GCC
19519 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019520#ifdef __cplusplus
19521extern "C"
19522#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019523char $ac_func ();
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019524/* The GNU C library defines this for functions which it implements
19525 to always fail with ENOSYS. Some functions are actually named
19526 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019527#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019528choke me
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019529#endif
19530
Skip Montanaro6dead952003-09-25 14:50:04 +000019531int
19532main ()
19533{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019534return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019535 ;
19536 return 0;
19537}
19538_ACEOF
19539rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019540if { (ac_try="$ac_link"
19541case "(($ac_try" in
19542 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19543 *) ac_try_echo=$ac_try;;
19544esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019545eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19546$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019547 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019548 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019549 grep -v '^ *+' conftest.er1 >conftest.err
19550 rm -f conftest.er1
19551 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019552 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019553 (exit $ac_status); } && {
19554 test -z "$ac_c_werror_flag" ||
19555 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019556 } && test -s conftest$ac_exeext && {
19557 test "$cross_compiling" = yes ||
19558 $as_test_x conftest$ac_exeext
19559 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019560 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000019561else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019562 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019563sed 's/^/| /' conftest.$ac_ext >&5
19564
Martin v. Löwiseba40652007-08-30 20:10:57 +000019565 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019566fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019567
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019568rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019569rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019570 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019571fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019572ac_res=`eval 'as_val=${'$as_ac_var'}
19573 $as_echo "$as_val"'`
19574 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19575$as_echo "$ac_res" >&6; }
19576as_val=`eval 'as_val=${'$as_ac_var'}
19577 $as_echo "$as_val"'`
19578 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019579 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019580#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019581_ACEOF
19582 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019583/* confdefs.h. */
19584_ACEOF
19585cat confdefs.h >>conftest.$ac_ext
19586cat >>conftest.$ac_ext <<_ACEOF
19587/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000019588#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000019589int
19590main ()
19591{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019592gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000019593 ;
19594 return 0;
19595}
19596_ACEOF
19597rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019598if { (ac_try="$ac_compile"
19599case "(($ac_try" in
19600 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19601 *) ac_try_echo=$ac_try;;
19602esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019603eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19604$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019605 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019606 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019607 grep -v '^ *+' conftest.er1 >conftest.err
19608 rm -f conftest.er1
19609 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019610 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019611 (exit $ac_status); } && {
19612 test -z "$ac_c_werror_flag" ||
19613 test ! -s conftest.err
19614 } && test -s conftest.$ac_objext; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000019615 :
19616else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019617 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019618sed 's/^/| /' conftest.$ac_ext >&5
19619
Martin v. Löwis11437992002-04-12 09:54:03 +000019620
19621cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019622#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019623_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000019624
Martin v. Löwis11437992002-04-12 09:54:03 +000019625
Guido van Rossum627b2d71993-12-24 10:39:16 +000019626fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019627
19628rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000019629
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019630fi
Thomas Wouters3a584202000-08-05 23:28:51 +000019631done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019632
Michael W. Hudson54241132001-12-07 15:38:26 +000019633
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019634{ $as_echo "$as_me:$LINENO: checking for major" >&5
19635$as_echo_n "checking for major... " >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019636cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019637/* confdefs.h. */
19638_ACEOF
19639cat confdefs.h >>conftest.$ac_ext
19640cat >>conftest.$ac_ext <<_ACEOF
19641/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019642
Neal Norwitz6eb37f02003-02-23 23:28:15 +000019643#if defined(MAJOR_IN_MKDEV)
19644#include <sys/mkdev.h>
19645#elif defined(MAJOR_IN_SYSMACROS)
19646#include <sys/sysmacros.h>
19647#else
19648#include <sys/types.h>
19649#endif
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019650
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019651int
19652main ()
19653{
19654
19655 makedev(major(0),minor(0));
19656
19657 ;
19658 return 0;
19659}
19660_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000019661rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019662if { (ac_try="$ac_link"
19663case "(($ac_try" in
19664 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19665 *) ac_try_echo=$ac_try;;
19666esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019667eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19668$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019669 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019670 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019671 grep -v '^ *+' conftest.er1 >conftest.err
19672 rm -f conftest.er1
19673 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019674 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019675 (exit $ac_status); } && {
19676 test -z "$ac_c_werror_flag" ||
19677 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019678 } && test -s conftest$ac_exeext && {
19679 test "$cross_compiling" = yes ||
19680 $as_test_x conftest$ac_exeext
19681 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019682
19683
19684cat >>confdefs.h <<\_ACEOF
19685#define HAVE_DEVICE_MACROS 1
19686_ACEOF
19687
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019688 { $as_echo "$as_me:$LINENO: result: yes" >&5
19689$as_echo "yes" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019690
19691else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019692 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019693sed 's/^/| /' conftest.$ac_ext >&5
19694
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019695
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019696 { $as_echo "$as_me:$LINENO: result: no" >&5
19697$as_echo "no" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019698
19699fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019700
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019701rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019702rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019703 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019704
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019705# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000019706# for [no]getaddrinfo in netdb.h.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019707{ $as_echo "$as_me:$LINENO: checking for getaddrinfo" >&5
19708$as_echo_n "checking for getaddrinfo... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019709cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019710/* confdefs.h. */
19711_ACEOF
19712cat confdefs.h >>conftest.$ac_ext
19713cat >>conftest.$ac_ext <<_ACEOF
19714/* end confdefs.h. */
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019715
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000019716#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019717#include <sys/socket.h>
19718#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000019719#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019720
Martin v. Löwis11437992002-04-12 09:54:03 +000019721int
19722main ()
19723{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019724
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019725getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019726
Martin v. Löwis11437992002-04-12 09:54:03 +000019727 ;
19728 return 0;
19729}
19730_ACEOF
19731rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019732if { (ac_try="$ac_link"
19733case "(($ac_try" in
19734 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19735 *) ac_try_echo=$ac_try;;
19736esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019737eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19738$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019739 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +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
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019744 $as_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
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019748 } && test -s conftest$ac_exeext && {
19749 test "$cross_compiling" = yes ||
19750 $as_test_x conftest$ac_exeext
19751 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019752
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019753{ $as_echo "$as_me:$LINENO: result: yes" >&5
19754$as_echo "yes" >&6; }
19755{ $as_echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
19756$as_echo_n "checking getaddrinfo bug... " >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019757if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019758 { $as_echo "$as_me:$LINENO: result: buggy" >&5
19759$as_echo "buggy" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019760buggygetaddrinfo=yes
19761else
Martin v. Löwis11437992002-04-12 09:54:03 +000019762 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019763/* confdefs.h. */
19764_ACEOF
19765cat confdefs.h >>conftest.$ac_ext
19766cat >>conftest.$ac_ext <<_ACEOF
19767/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019768
19769#include <sys/types.h>
19770#include <netdb.h>
19771#include <string.h>
19772#include <sys/socket.h>
19773#include <netinet/in.h>
19774
19775main()
19776{
19777 int passive, gaierr, inet4 = 0, inet6 = 0;
19778 struct addrinfo hints, *ai, *aitop;
19779 char straddr[INET6_ADDRSTRLEN], strport[16];
19780
19781 for (passive = 0; passive <= 1; passive++) {
19782 memset(&hints, 0, sizeof(hints));
19783 hints.ai_family = AF_UNSPEC;
19784 hints.ai_flags = passive ? AI_PASSIVE : 0;
19785 hints.ai_socktype = SOCK_STREAM;
Hye-Shik Chang54f94392004-04-14 07:55:31 +000019786 hints.ai_protocol = IPPROTO_TCP;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019787 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
19788 (void)gai_strerror(gaierr);
19789 goto bad;
19790 }
19791 for (ai = aitop; ai; ai = ai->ai_next) {
19792 if (ai->ai_addr == NULL ||
19793 ai->ai_addrlen == 0 ||
19794 getnameinfo(ai->ai_addr, ai->ai_addrlen,
19795 straddr, sizeof(straddr), strport, sizeof(strport),
19796 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
19797 goto bad;
19798 }
19799 switch (ai->ai_family) {
19800 case AF_INET:
19801 if (strcmp(strport, "54321") != 0) {
19802 goto bad;
19803 }
19804 if (passive) {
19805 if (strcmp(straddr, "0.0.0.0") != 0) {
19806 goto bad;
19807 }
19808 } else {
19809 if (strcmp(straddr, "127.0.0.1") != 0) {
19810 goto bad;
19811 }
19812 }
19813 inet4++;
19814 break;
19815 case AF_INET6:
19816 if (strcmp(strport, "54321") != 0) {
19817 goto bad;
19818 }
19819 if (passive) {
19820 if (strcmp(straddr, "::") != 0) {
19821 goto bad;
19822 }
19823 } else {
19824 if (strcmp(straddr, "::1") != 0) {
19825 goto bad;
19826 }
19827 }
19828 inet6++;
19829 break;
19830 case AF_UNSPEC:
19831 goto bad;
19832 break;
19833 default:
19834 /* another family support? */
19835 break;
19836 }
19837 }
19838 }
19839
19840 if (!(inet4 == 0 || inet4 == 2))
19841 goto bad;
19842 if (!(inet6 == 0 || inet6 == 2))
19843 goto bad;
19844
19845 if (aitop)
19846 freeaddrinfo(aitop);
19847 exit(0);
19848
19849 bad:
19850 if (aitop)
19851 freeaddrinfo(aitop);
19852 exit(1);
19853}
19854
Martin v. Löwis11437992002-04-12 09:54:03 +000019855_ACEOF
19856rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019857if { (ac_try="$ac_link"
19858case "(($ac_try" in
19859 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19860 *) ac_try_echo=$ac_try;;
19861esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019862eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19863$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019864 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019865 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019866 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019867 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000019868 { (case "(($ac_try" in
19869 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19870 *) ac_try_echo=$ac_try;;
19871esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019872eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19873$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019874 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019875 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019876 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019877 (exit $ac_status); }; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019878 { $as_echo "$as_me:$LINENO: result: good" >&5
19879$as_echo "good" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019880buggygetaddrinfo=no
19881else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019882 $as_echo "$as_me: program exited with status $ac_status" >&5
19883$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019884sed 's/^/| /' conftest.$ac_ext >&5
19885
Martin v. Löwis11437992002-04-12 09:54:03 +000019886( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019887{ $as_echo "$as_me:$LINENO: result: buggy" >&5
19888$as_echo "buggy" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019889buggygetaddrinfo=yes
19890fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019891rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019892rm -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 +000019893fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019894
19895
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019896else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019897 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019898sed 's/^/| /' conftest.$ac_ext >&5
19899
Martin v. Löwis11437992002-04-12 09:54:03 +000019900
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019901{ $as_echo "$as_me:$LINENO: result: no" >&5
19902$as_echo "no" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019903buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019904
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019905fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019906
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019907rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000019908rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019909 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019910
19911if test "$buggygetaddrinfo" = "yes"; then
19912 if test "$ipv6" = "yes"; then
19913 echo 'Fatal: You must get working getaddrinfo() function.'
19914 echo ' or you can specify "--disable-ipv6"'.
19915 exit 1
19916 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019917else
Martin v. Löwis11437992002-04-12 09:54:03 +000019918
19919cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019920#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019921_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019922
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019923fi
Martin v. Löwis11437992002-04-12 09:54:03 +000019924
Jack Jansen9a66b6d2001-08-08 13:56:14 +000019925for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019926do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019927as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19928{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19929$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019930if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019931 $as_echo_n "(cached) " >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019932else
Martin v. Löwis11437992002-04-12 09:54:03 +000019933 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019934/* confdefs.h. */
19935_ACEOF
19936cat confdefs.h >>conftest.$ac_ext
19937cat >>conftest.$ac_ext <<_ACEOF
19938/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019939/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19940 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19941#define $ac_func innocuous_$ac_func
19942
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019943/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019944 which can conflict with char $ac_func (); below.
19945 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019946 <limits.h> exists even on freestanding compilers. */
19947
19948#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019949# include <limits.h>
19950#else
19951# include <assert.h>
19952#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019953
19954#undef $ac_func
19955
Martin v. Löwiseba40652007-08-30 20:10:57 +000019956/* Override any GCC internal prototype to avoid an error.
19957 Use char because int might match the return type of a GCC
19958 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019959#ifdef __cplusplus
19960extern "C"
19961#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019962char $ac_func ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019963/* The GNU C library defines this for functions which it implements
19964 to always fail with ENOSYS. Some functions are actually named
19965 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019966#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019967choke me
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019968#endif
19969
Skip Montanaro6dead952003-09-25 14:50:04 +000019970int
19971main ()
19972{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019973return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019974 ;
19975 return 0;
19976}
19977_ACEOF
19978rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019979if { (ac_try="$ac_link"
19980case "(($ac_try" in
19981 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19982 *) ac_try_echo=$ac_try;;
19983esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019984eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19985$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019986 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019987 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019988 grep -v '^ *+' conftest.er1 >conftest.err
19989 rm -f conftest.er1
19990 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019991 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019992 (exit $ac_status); } && {
19993 test -z "$ac_c_werror_flag" ||
19994 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000019995 } && test -s conftest$ac_exeext && {
19996 test "$cross_compiling" = yes ||
19997 $as_test_x conftest$ac_exeext
19998 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019999 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000020000else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020001 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020002sed 's/^/| /' conftest.$ac_ext >&5
20003
Martin v. Löwiseba40652007-08-30 20:10:57 +000020004 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000020005fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020006
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020007rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000020008rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000020009 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000020010fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020011ac_res=`eval 'as_val=${'$as_ac_var'}
20012 $as_echo "$as_val"'`
20013 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20014$as_echo "$ac_res" >&6; }
20015as_val=`eval 'as_val=${'$as_ac_var'}
20016 $as_echo "$as_val"'`
20017 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020018 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020019#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020020_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020021
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020022fi
20023done
20024
Michael W. Hudson54241132001-12-07 15:38:26 +000020025
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020026# checks for structures
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020027{ $as_echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
20028$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020029if test "${ac_cv_header_time+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020030 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020031else
Martin v. Löwis11437992002-04-12 09:54:03 +000020032 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020033/* confdefs.h. */
20034_ACEOF
20035cat confdefs.h >>conftest.$ac_ext
20036cat >>conftest.$ac_ext <<_ACEOF
20037/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020038#include <sys/types.h>
20039#include <sys/time.h>
20040#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000020041
Martin v. Löwis11437992002-04-12 09:54:03 +000020042int
20043main ()
20044{
20045if ((struct tm *) 0)
20046return 0;
20047 ;
20048 return 0;
20049}
20050_ACEOF
20051rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020052if { (ac_try="$ac_compile"
20053case "(($ac_try" in
20054 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20055 *) ac_try_echo=$ac_try;;
20056esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020057eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20058$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020059 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020060 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020061 grep -v '^ *+' conftest.er1 >conftest.err
20062 rm -f conftest.er1
20063 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020064 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020065 (exit $ac_status); } && {
20066 test -z "$ac_c_werror_flag" ||
20067 test ! -s conftest.err
20068 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020069 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000020070else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020071 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020072sed 's/^/| /' conftest.$ac_ext >&5
20073
Martin v. Löwiseba40652007-08-30 20:10:57 +000020074 ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000020075fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020076
20077rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020078fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020079{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
20080$as_echo "$ac_cv_header_time" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000020081if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020082
20083cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020084#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020085_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020086
20087fi
20088
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020089{ $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
20090$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020091if test "${ac_cv_struct_tm+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020092 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020093else
Martin v. Löwis11437992002-04-12 09:54:03 +000020094 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020095/* confdefs.h. */
20096_ACEOF
20097cat confdefs.h >>conftest.$ac_ext
20098cat >>conftest.$ac_ext <<_ACEOF
20099/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020100#include <sys/types.h>
20101#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000020102
Martin v. Löwis11437992002-04-12 09:54:03 +000020103int
20104main ()
20105{
Martin v. Löwiseba40652007-08-30 20:10:57 +000020106struct tm tm;
20107 int *p = &tm.tm_sec;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020108 return !p;
Martin v. Löwis11437992002-04-12 09:54:03 +000020109 ;
20110 return 0;
20111}
20112_ACEOF
20113rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020114if { (ac_try="$ac_compile"
20115case "(($ac_try" in
20116 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20117 *) ac_try_echo=$ac_try;;
20118esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020119eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20120$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020121 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020122 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020123 grep -v '^ *+' conftest.er1 >conftest.err
20124 rm -f conftest.er1
20125 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020126 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020127 (exit $ac_status); } && {
20128 test -z "$ac_c_werror_flag" ||
20129 test ! -s conftest.err
20130 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020131 ac_cv_struct_tm=time.h
20132else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020133 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020134sed 's/^/| /' conftest.$ac_ext >&5
20135
Martin v. Löwiseba40652007-08-30 20:10:57 +000020136 ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020137fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020138
20139rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020140fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020141{ $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
20142$as_echo "$ac_cv_struct_tm" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000020143if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020144
20145cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020146#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020147_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020148
20149fi
20150
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020151{ $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
20152$as_echo_n "checking for struct tm.tm_zone... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020153if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020154 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020155else
Martin v. Löwis11437992002-04-12 09:54:03 +000020156 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020157/* confdefs.h. */
20158_ACEOF
20159cat confdefs.h >>conftest.$ac_ext
20160cat >>conftest.$ac_ext <<_ACEOF
20161/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020162#include <sys/types.h>
20163#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000020164
20165
Martin v. Löwis11437992002-04-12 09:54:03 +000020166int
20167main ()
20168{
20169static struct tm ac_aggr;
20170if (ac_aggr.tm_zone)
20171return 0;
20172 ;
20173 return 0;
20174}
20175_ACEOF
20176rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020177if { (ac_try="$ac_compile"
20178case "(($ac_try" in
20179 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20180 *) ac_try_echo=$ac_try;;
20181esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020182eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20183$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020184 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020185 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020186 grep -v '^ *+' conftest.er1 >conftest.err
20187 rm -f conftest.er1
20188 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020189 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020190 (exit $ac_status); } && {
20191 test -z "$ac_c_werror_flag" ||
20192 test ! -s conftest.err
20193 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020194 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000020195else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020196 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020197sed 's/^/| /' conftest.$ac_ext >&5
20198
Martin v. Löwiseba40652007-08-30 20:10:57 +000020199 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020200/* confdefs.h. */
20201_ACEOF
20202cat confdefs.h >>conftest.$ac_ext
20203cat >>conftest.$ac_ext <<_ACEOF
20204/* end confdefs.h. */
20205#include <sys/types.h>
20206#include <$ac_cv_struct_tm>
20207
20208
20209int
20210main ()
20211{
20212static struct tm ac_aggr;
20213if (sizeof ac_aggr.tm_zone)
20214return 0;
20215 ;
20216 return 0;
20217}
20218_ACEOF
20219rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020220if { (ac_try="$ac_compile"
20221case "(($ac_try" in
20222 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20223 *) ac_try_echo=$ac_try;;
20224esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020225eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20226$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020227 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020228 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020229 grep -v '^ *+' conftest.er1 >conftest.err
20230 rm -f conftest.er1
20231 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020232 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020233 (exit $ac_status); } && {
20234 test -z "$ac_c_werror_flag" ||
20235 test ! -s conftest.err
20236 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000020237 ac_cv_member_struct_tm_tm_zone=yes
20238else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020239 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020240sed 's/^/| /' conftest.$ac_ext >&5
20241
Martin v. Löwiseba40652007-08-30 20:10:57 +000020242 ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000020243fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020244
20245rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000020246fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020247
20248rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020249fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020250{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
20251$as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
20252if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020253
20254cat >>confdefs.h <<_ACEOF
20255#define HAVE_STRUCT_TM_TM_ZONE 1
20256_ACEOF
20257
20258
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020259fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000020260
Martin v. Löwis11437992002-04-12 09:54:03 +000020261if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
20262
20263cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020264#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020265_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020266
20267else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020268 { $as_echo "$as_me:$LINENO: checking whether tzname is declared" >&5
20269$as_echo_n "checking whether tzname is declared... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000020270if test "${ac_cv_have_decl_tzname+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020271 $as_echo_n "(cached) " >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +000020272else
20273 cat >conftest.$ac_ext <<_ACEOF
20274/* confdefs.h. */
20275_ACEOF
20276cat confdefs.h >>conftest.$ac_ext
20277cat >>conftest.$ac_ext <<_ACEOF
20278/* end confdefs.h. */
20279#include <time.h>
20280
20281int
20282main ()
20283{
20284#ifndef tzname
20285 (void) tzname;
20286#endif
20287
20288 ;
20289 return 0;
20290}
20291_ACEOF
20292rm -f conftest.$ac_objext
20293if { (ac_try="$ac_compile"
20294case "(($ac_try" in
20295 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20296 *) ac_try_echo=$ac_try;;
20297esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020298eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20299$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020300 (eval "$ac_compile") 2>conftest.er1
20301 ac_status=$?
20302 grep -v '^ *+' conftest.er1 >conftest.err
20303 rm -f conftest.er1
20304 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020305 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020306 (exit $ac_status); } && {
20307 test -z "$ac_c_werror_flag" ||
20308 test ! -s conftest.err
20309 } && test -s conftest.$ac_objext; then
20310 ac_cv_have_decl_tzname=yes
20311else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020312 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020313sed 's/^/| /' conftest.$ac_ext >&5
20314
20315 ac_cv_have_decl_tzname=no
20316fi
20317
20318rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20319fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020320{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5
20321$as_echo "$ac_cv_have_decl_tzname" >&6; }
20322if test "x$ac_cv_have_decl_tzname" = x""yes; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000020323
20324cat >>confdefs.h <<_ACEOF
20325#define HAVE_DECL_TZNAME 1
20326_ACEOF
20327
20328
20329else
20330 cat >>confdefs.h <<_ACEOF
20331#define HAVE_DECL_TZNAME 0
20332_ACEOF
20333
20334
20335fi
20336
20337
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020338 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
20339$as_echo_n "checking for tzname... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020340if test "${ac_cv_var_tzname+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020341 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020342else
Martin v. Löwis11437992002-04-12 09:54:03 +000020343 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020344/* confdefs.h. */
20345_ACEOF
20346cat confdefs.h >>conftest.$ac_ext
20347cat >>conftest.$ac_ext <<_ACEOF
20348/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000020349#include <time.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +000020350#if !HAVE_DECL_TZNAME
20351extern char *tzname[];
Guido van Rossum627b2d71993-12-24 10:39:16 +000020352#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000020353
Martin v. Löwis11437992002-04-12 09:54:03 +000020354int
20355main ()
20356{
Martin v. Löwiseba40652007-08-30 20:10:57 +000020357return tzname[0][0];
Martin v. Löwis11437992002-04-12 09:54:03 +000020358 ;
20359 return 0;
20360}
20361_ACEOF
20362rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020363if { (ac_try="$ac_link"
20364case "(($ac_try" in
20365 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20366 *) ac_try_echo=$ac_try;;
20367esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020368eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20369$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020370 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020371 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020372 grep -v '^ *+' conftest.er1 >conftest.err
20373 rm -f conftest.er1
20374 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020375 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020376 (exit $ac_status); } && {
20377 test -z "$ac_c_werror_flag" ||
20378 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020379 } && test -s conftest$ac_exeext && {
20380 test "$cross_compiling" = yes ||
20381 $as_test_x conftest$ac_exeext
20382 }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020383 ac_cv_var_tzname=yes
20384else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020385 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020386sed 's/^/| /' conftest.$ac_ext >&5
20387
Martin v. Löwiseba40652007-08-30 20:10:57 +000020388 ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000020389fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020390
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020391rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000020392rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000020393 conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000020394fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020395{ $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
20396$as_echo "$ac_cv_var_tzname" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000020397 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020398
20399cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020400#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020401_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000020402
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020403 fi
20404fi
20405
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020406{ $as_echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
20407$as_echo_n "checking for struct stat.st_rdev... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020408if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020409 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000020410else
20411 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020412/* confdefs.h. */
20413_ACEOF
20414cat confdefs.h >>conftest.$ac_ext
20415cat >>conftest.$ac_ext <<_ACEOF
20416/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020417$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020418int
20419main ()
20420{
20421static struct stat ac_aggr;
20422if (ac_aggr.st_rdev)
20423return 0;
20424 ;
20425 return 0;
20426}
20427_ACEOF
20428rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020429if { (ac_try="$ac_compile"
20430case "(($ac_try" in
20431 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20432 *) ac_try_echo=$ac_try;;
20433esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020434eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20435$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020436 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020437 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020438 grep -v '^ *+' conftest.er1 >conftest.err
20439 rm -f conftest.er1
20440 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020441 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020442 (exit $ac_status); } && {
20443 test -z "$ac_c_werror_flag" ||
20444 test ! -s conftest.err
20445 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020446 ac_cv_member_struct_stat_st_rdev=yes
20447else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020448 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020449sed 's/^/| /' conftest.$ac_ext >&5
20450
Martin v. Löwiseba40652007-08-30 20:10:57 +000020451 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020452/* confdefs.h. */
20453_ACEOF
20454cat confdefs.h >>conftest.$ac_ext
20455cat >>conftest.$ac_ext <<_ACEOF
20456/* end confdefs.h. */
20457$ac_includes_default
20458int
20459main ()
20460{
20461static struct stat ac_aggr;
20462if (sizeof ac_aggr.st_rdev)
20463return 0;
20464 ;
20465 return 0;
20466}
20467_ACEOF
20468rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020469if { (ac_try="$ac_compile"
20470case "(($ac_try" in
20471 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20472 *) ac_try_echo=$ac_try;;
20473esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020474eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20475$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020476 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020477 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020478 grep -v '^ *+' conftest.er1 >conftest.err
20479 rm -f conftest.er1
20480 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020481 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020482 (exit $ac_status); } && {
20483 test -z "$ac_c_werror_flag" ||
20484 test ! -s conftest.err
20485 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000020486 ac_cv_member_struct_stat_st_rdev=yes
20487else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020488 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020489sed 's/^/| /' conftest.$ac_ext >&5
20490
Martin v. Löwiseba40652007-08-30 20:10:57 +000020491 ac_cv_member_struct_stat_st_rdev=no
Martin v. Löwis11437992002-04-12 09:54:03 +000020492fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020493
20494rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000020495fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020496
20497rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020498fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020499{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
20500$as_echo "$ac_cv_member_struct_stat_st_rdev" >&6; }
20501if test "x$ac_cv_member_struct_stat_st_rdev" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020502
20503cat >>confdefs.h <<_ACEOF
20504#define HAVE_STRUCT_STAT_ST_RDEV 1
20505_ACEOF
20506
20507
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020508fi
20509
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020510{ $as_echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
20511$as_echo_n "checking for struct stat.st_blksize... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020512if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020513 $as_echo_n "(cached) " >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020514else
Martin v. Löwis11437992002-04-12 09:54:03 +000020515 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020516/* confdefs.h. */
20517_ACEOF
20518cat confdefs.h >>conftest.$ac_ext
20519cat >>conftest.$ac_ext <<_ACEOF
20520/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020521$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020522int
20523main ()
20524{
20525static struct stat ac_aggr;
20526if (ac_aggr.st_blksize)
20527return 0;
20528 ;
20529 return 0;
20530}
20531_ACEOF
20532rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020533if { (ac_try="$ac_compile"
20534case "(($ac_try" in
20535 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20536 *) ac_try_echo=$ac_try;;
20537esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020538eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20539$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020540 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020541 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020542 grep -v '^ *+' conftest.er1 >conftest.err
20543 rm -f conftest.er1
20544 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020545 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020546 (exit $ac_status); } && {
20547 test -z "$ac_c_werror_flag" ||
20548 test ! -s conftest.err
20549 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020550 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000020551else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020552 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020553sed 's/^/| /' conftest.$ac_ext >&5
20554
Martin v. Löwiseba40652007-08-30 20:10:57 +000020555 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020556/* confdefs.h. */
20557_ACEOF
20558cat confdefs.h >>conftest.$ac_ext
20559cat >>conftest.$ac_ext <<_ACEOF
20560/* end confdefs.h. */
20561$ac_includes_default
20562int
20563main ()
20564{
20565static struct stat ac_aggr;
20566if (sizeof ac_aggr.st_blksize)
20567return 0;
20568 ;
20569 return 0;
20570}
20571_ACEOF
20572rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020573if { (ac_try="$ac_compile"
20574case "(($ac_try" in
20575 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20576 *) ac_try_echo=$ac_try;;
20577esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020578eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20579$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020580 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020581 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020582 grep -v '^ *+' conftest.er1 >conftest.err
20583 rm -f conftest.er1
20584 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020585 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020586 (exit $ac_status); } && {
20587 test -z "$ac_c_werror_flag" ||
20588 test ! -s conftest.err
20589 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000020590 ac_cv_member_struct_stat_st_blksize=yes
20591else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020592 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020593sed 's/^/| /' conftest.$ac_ext >&5
20594
Martin v. Löwiseba40652007-08-30 20:10:57 +000020595 ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000020596fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020597
20598rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000020599fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020600
20601rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020602fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020603{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
20604$as_echo "$ac_cv_member_struct_stat_st_blksize" >&6; }
20605if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000020606
Martin v. Löwis11437992002-04-12 09:54:03 +000020607cat >>confdefs.h <<_ACEOF
20608#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
20609_ACEOF
20610
20611
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020612fi
20613
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020614{ $as_echo "$as_me:$LINENO: checking for struct stat.st_flags" >&5
20615$as_echo_n "checking for struct stat.st_flags... " >&6; }
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020616if test "${ac_cv_member_struct_stat_st_flags+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020617 $as_echo_n "(cached) " >&6
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020618else
20619 cat >conftest.$ac_ext <<_ACEOF
20620/* confdefs.h. */
20621_ACEOF
20622cat confdefs.h >>conftest.$ac_ext
20623cat >>conftest.$ac_ext <<_ACEOF
20624/* end confdefs.h. */
20625$ac_includes_default
20626int
20627main ()
20628{
20629static struct stat ac_aggr;
20630if (ac_aggr.st_flags)
20631return 0;
20632 ;
20633 return 0;
20634}
20635_ACEOF
20636rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020637if { (ac_try="$ac_compile"
20638case "(($ac_try" in
20639 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20640 *) ac_try_echo=$ac_try;;
20641esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020642eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20643$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020644 (eval "$ac_compile") 2>conftest.er1
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020645 ac_status=$?
20646 grep -v '^ *+' conftest.er1 >conftest.err
20647 rm -f conftest.er1
20648 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020649 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020650 (exit $ac_status); } && {
20651 test -z "$ac_c_werror_flag" ||
20652 test ! -s conftest.err
20653 } && test -s conftest.$ac_objext; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020654 ac_cv_member_struct_stat_st_flags=yes
20655else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020656 $as_echo "$as_me: failed program was:" >&5
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020657sed 's/^/| /' conftest.$ac_ext >&5
20658
Martin v. Löwiseba40652007-08-30 20:10:57 +000020659 cat >conftest.$ac_ext <<_ACEOF
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020660/* confdefs.h. */
20661_ACEOF
20662cat confdefs.h >>conftest.$ac_ext
20663cat >>conftest.$ac_ext <<_ACEOF
20664/* end confdefs.h. */
20665$ac_includes_default
20666int
20667main ()
20668{
20669static struct stat ac_aggr;
20670if (sizeof ac_aggr.st_flags)
20671return 0;
20672 ;
20673 return 0;
20674}
20675_ACEOF
20676rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020677if { (ac_try="$ac_compile"
20678case "(($ac_try" in
20679 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20680 *) ac_try_echo=$ac_try;;
20681esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020682eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20683$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020684 (eval "$ac_compile") 2>conftest.er1
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020685 ac_status=$?
20686 grep -v '^ *+' conftest.er1 >conftest.err
20687 rm -f conftest.er1
20688 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020689 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020690 (exit $ac_status); } && {
20691 test -z "$ac_c_werror_flag" ||
20692 test ! -s conftest.err
20693 } && test -s conftest.$ac_objext; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020694 ac_cv_member_struct_stat_st_flags=yes
20695else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020696 $as_echo "$as_me: failed program was:" >&5
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020697sed 's/^/| /' conftest.$ac_ext >&5
20698
Martin v. Löwiseba40652007-08-30 20:10:57 +000020699 ac_cv_member_struct_stat_st_flags=no
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020700fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020701
20702rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020703fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020704
20705rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020706fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020707{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_flags" >&5
20708$as_echo "$ac_cv_member_struct_stat_st_flags" >&6; }
20709if test "x$ac_cv_member_struct_stat_st_flags" = x""yes; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020710
20711cat >>confdefs.h <<_ACEOF
20712#define HAVE_STRUCT_STAT_ST_FLAGS 1
20713_ACEOF
20714
20715
20716fi
20717
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020718{ $as_echo "$as_me:$LINENO: checking for struct stat.st_gen" >&5
20719$as_echo_n "checking for struct stat.st_gen... " >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020720if test "${ac_cv_member_struct_stat_st_gen+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020721 $as_echo_n "(cached) " >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020722else
20723 cat >conftest.$ac_ext <<_ACEOF
20724/* confdefs.h. */
20725_ACEOF
20726cat confdefs.h >>conftest.$ac_ext
20727cat >>conftest.$ac_ext <<_ACEOF
20728/* end confdefs.h. */
20729$ac_includes_default
20730int
20731main ()
20732{
20733static struct stat ac_aggr;
20734if (ac_aggr.st_gen)
20735return 0;
20736 ;
20737 return 0;
20738}
20739_ACEOF
20740rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020741if { (ac_try="$ac_compile"
20742case "(($ac_try" in
20743 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20744 *) ac_try_echo=$ac_try;;
20745esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020746eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20747$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020748 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020749 ac_status=$?
20750 grep -v '^ *+' conftest.er1 >conftest.err
20751 rm -f conftest.er1
20752 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020753 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020754 (exit $ac_status); } && {
20755 test -z "$ac_c_werror_flag" ||
20756 test ! -s conftest.err
20757 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020758 ac_cv_member_struct_stat_st_gen=yes
20759else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020760 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020761sed 's/^/| /' conftest.$ac_ext >&5
20762
Martin v. Löwiseba40652007-08-30 20:10:57 +000020763 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020764/* confdefs.h. */
20765_ACEOF
20766cat confdefs.h >>conftest.$ac_ext
20767cat >>conftest.$ac_ext <<_ACEOF
20768/* end confdefs.h. */
20769$ac_includes_default
20770int
20771main ()
20772{
20773static struct stat ac_aggr;
20774if (sizeof ac_aggr.st_gen)
20775return 0;
20776 ;
20777 return 0;
20778}
20779_ACEOF
20780rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020781if { (ac_try="$ac_compile"
20782case "(($ac_try" in
20783 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20784 *) ac_try_echo=$ac_try;;
20785esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020786eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20787$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020788 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020789 ac_status=$?
20790 grep -v '^ *+' conftest.er1 >conftest.err
20791 rm -f conftest.er1
20792 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020793 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020794 (exit $ac_status); } && {
20795 test -z "$ac_c_werror_flag" ||
20796 test ! -s conftest.err
20797 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020798 ac_cv_member_struct_stat_st_gen=yes
20799else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020800 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020801sed 's/^/| /' conftest.$ac_ext >&5
20802
Martin v. Löwiseba40652007-08-30 20:10:57 +000020803 ac_cv_member_struct_stat_st_gen=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020804fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020805
20806rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020807fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020808
20809rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020810fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020811{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_gen" >&5
20812$as_echo "$ac_cv_member_struct_stat_st_gen" >&6; }
20813if test "x$ac_cv_member_struct_stat_st_gen" = x""yes; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020814
20815cat >>confdefs.h <<_ACEOF
20816#define HAVE_STRUCT_STAT_ST_GEN 1
20817_ACEOF
20818
20819
20820fi
20821
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020822{ $as_echo "$as_me:$LINENO: checking for struct stat.st_birthtime" >&5
20823$as_echo_n "checking for struct stat.st_birthtime... " >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020824if test "${ac_cv_member_struct_stat_st_birthtime+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020825 $as_echo_n "(cached) " >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020826else
20827 cat >conftest.$ac_ext <<_ACEOF
20828/* confdefs.h. */
20829_ACEOF
20830cat confdefs.h >>conftest.$ac_ext
20831cat >>conftest.$ac_ext <<_ACEOF
20832/* end confdefs.h. */
20833$ac_includes_default
20834int
20835main ()
20836{
20837static struct stat ac_aggr;
20838if (ac_aggr.st_birthtime)
20839return 0;
20840 ;
20841 return 0;
20842}
20843_ACEOF
20844rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020845if { (ac_try="$ac_compile"
20846case "(($ac_try" in
20847 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20848 *) ac_try_echo=$ac_try;;
20849esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020850eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20851$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020852 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020853 ac_status=$?
20854 grep -v '^ *+' conftest.er1 >conftest.err
20855 rm -f conftest.er1
20856 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020857 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020858 (exit $ac_status); } && {
20859 test -z "$ac_c_werror_flag" ||
20860 test ! -s conftest.err
20861 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020862 ac_cv_member_struct_stat_st_birthtime=yes
20863else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020864 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020865sed 's/^/| /' conftest.$ac_ext >&5
20866
Martin v. Löwiseba40652007-08-30 20:10:57 +000020867 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020868/* confdefs.h. */
20869_ACEOF
20870cat confdefs.h >>conftest.$ac_ext
20871cat >>conftest.$ac_ext <<_ACEOF
20872/* end confdefs.h. */
20873$ac_includes_default
20874int
20875main ()
20876{
20877static struct stat ac_aggr;
20878if (sizeof ac_aggr.st_birthtime)
20879return 0;
20880 ;
20881 return 0;
20882}
20883_ACEOF
20884rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020885if { (ac_try="$ac_compile"
20886case "(($ac_try" in
20887 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20888 *) ac_try_echo=$ac_try;;
20889esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020890eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20891$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020892 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020893 ac_status=$?
20894 grep -v '^ *+' conftest.er1 >conftest.err
20895 rm -f conftest.er1
20896 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020897 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020898 (exit $ac_status); } && {
20899 test -z "$ac_c_werror_flag" ||
20900 test ! -s conftest.err
20901 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020902 ac_cv_member_struct_stat_st_birthtime=yes
20903else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020904 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020905sed 's/^/| /' conftest.$ac_ext >&5
20906
Martin v. Löwiseba40652007-08-30 20:10:57 +000020907 ac_cv_member_struct_stat_st_birthtime=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020908fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020909
20910rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020911fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020912
20913rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020914fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020915{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_birthtime" >&5
20916$as_echo "$ac_cv_member_struct_stat_st_birthtime" >&6; }
20917if test "x$ac_cv_member_struct_stat_st_birthtime" = x""yes; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020918
20919cat >>confdefs.h <<_ACEOF
20920#define HAVE_STRUCT_STAT_ST_BIRTHTIME 1
20921_ACEOF
20922
20923
20924fi
20925
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020926{ $as_echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
20927$as_echo_n "checking for struct stat.st_blocks... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020928if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020929 $as_echo_n "(cached) " >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020930else
Martin v. Löwis11437992002-04-12 09:54:03 +000020931 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020932/* confdefs.h. */
20933_ACEOF
20934cat confdefs.h >>conftest.$ac_ext
20935cat >>conftest.$ac_ext <<_ACEOF
20936/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020937$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020938int
20939main ()
20940{
20941static struct stat ac_aggr;
20942if (ac_aggr.st_blocks)
20943return 0;
20944 ;
20945 return 0;
20946}
20947_ACEOF
20948rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020949if { (ac_try="$ac_compile"
20950case "(($ac_try" in
20951 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20952 *) ac_try_echo=$ac_try;;
20953esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020954eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20955$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020956 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020957 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020958 grep -v '^ *+' conftest.er1 >conftest.err
20959 rm -f conftest.er1
20960 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020961 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020962 (exit $ac_status); } && {
20963 test -z "$ac_c_werror_flag" ||
20964 test ! -s conftest.err
20965 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020966 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000020967else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020968 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020969sed 's/^/| /' conftest.$ac_ext >&5
20970
Martin v. Löwiseba40652007-08-30 20:10:57 +000020971 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020972/* confdefs.h. */
20973_ACEOF
20974cat confdefs.h >>conftest.$ac_ext
20975cat >>conftest.$ac_ext <<_ACEOF
20976/* end confdefs.h. */
20977$ac_includes_default
20978int
20979main ()
20980{
20981static struct stat ac_aggr;
20982if (sizeof ac_aggr.st_blocks)
20983return 0;
20984 ;
20985 return 0;
20986}
20987_ACEOF
20988rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020989if { (ac_try="$ac_compile"
20990case "(($ac_try" in
20991 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20992 *) ac_try_echo=$ac_try;;
20993esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000020994eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20995$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020996 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020997 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020998 grep -v '^ *+' conftest.er1 >conftest.err
20999 rm -f conftest.er1
21000 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021001 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021002 (exit $ac_status); } && {
21003 test -z "$ac_c_werror_flag" ||
21004 test ! -s conftest.err
21005 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000021006 ac_cv_member_struct_stat_st_blocks=yes
21007else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021008 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021009sed 's/^/| /' conftest.$ac_ext >&5
21010
Martin v. Löwiseba40652007-08-30 20:10:57 +000021011 ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000021012fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021013
21014rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000021015fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021016
21017rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000021018fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021019{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
21020$as_echo "$ac_cv_member_struct_stat_st_blocks" >&6; }
21021if test "x$ac_cv_member_struct_stat_st_blocks" = x""yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000021022
Martin v. Löwis11437992002-04-12 09:54:03 +000021023cat >>confdefs.h <<_ACEOF
21024#define HAVE_STRUCT_STAT_ST_BLOCKS 1
21025_ACEOF
21026
21027
21028cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000021029#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021030_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000021031
21032else
Martin v. Löwiseba40652007-08-30 20:10:57 +000021033 case " $LIBOBJS " in
Skip Montanarof0d5f792004-08-15 14:08:23 +000021034 *" fileblocks.$ac_objext "* ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000021035 *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
21036 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000021037esac
21038
Guido van Rossum98bf58f2001-10-18 20:34:25 +000021039fi
21040
Michael W. Hudson54241132001-12-07 15:38:26 +000021041
Martin v. Löwis11437992002-04-12 09:54:03 +000021042
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021043{ $as_echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
21044$as_echo_n "checking for time.h that defines altzone... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021045if test "${ac_cv_header_time_altzone+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021046 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021047else
Martin v. Löwis11437992002-04-12 09:54:03 +000021048 cat >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 +000021054#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021055int
21056main ()
21057{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021058return altzone;
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
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021069eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21070$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021071 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021072 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021073 grep -v '^ *+' conftest.er1 >conftest.err
21074 rm -f conftest.er1
21075 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021076 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021077 (exit $ac_status); } && {
21078 test -z "$ac_c_werror_flag" ||
21079 test ! -s conftest.err
21080 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021081 ac_cv_header_time_altzone=yes
21082else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021083 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021084sed 's/^/| /' conftest.$ac_ext >&5
21085
Martin v. Löwiseba40652007-08-30 20:10:57 +000021086 ac_cv_header_time_altzone=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021087fi
21088
Martin v. Löwiseba40652007-08-30 20:10:57 +000021089rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21090fi
21091
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021092{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
21093$as_echo "$ac_cv_header_time_altzone" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021094if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021095
21096cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021097#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021098_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021099
21100fi
21101
Guido van Rossumda88dad1995-01-26 00:46:29 +000021102was_it_defined=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021103{ $as_echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
21104$as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021105cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021106/* confdefs.h. */
21107_ACEOF
21108cat confdefs.h >>conftest.$ac_ext
21109cat >>conftest.$ac_ext <<_ACEOF
21110/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000021111
21112#include <sys/types.h>
21113#include <sys/select.h>
21114#include <sys/time.h>
21115
Martin v. Löwis11437992002-04-12 09:54:03 +000021116int
21117main ()
21118{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021119;
Martin v. Löwis11437992002-04-12 09:54:03 +000021120 ;
21121 return 0;
21122}
21123_ACEOF
21124rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021125if { (ac_try="$ac_compile"
21126case "(($ac_try" in
21127 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21128 *) ac_try_echo=$ac_try;;
21129esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021130eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21131$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021132 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021133 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021134 grep -v '^ *+' conftest.er1 >conftest.err
21135 rm -f conftest.er1
21136 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021137 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021138 (exit $ac_status); } && {
21139 test -z "$ac_c_werror_flag" ||
21140 test ! -s conftest.err
21141 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021142
21143
21144cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021145#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021146_ACEOF
21147
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021148 was_it_defined=yes
21149
Guido van Rossumf78abae1997-01-21 22:02:36 +000021150else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021151 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021152sed 's/^/| /' conftest.$ac_ext >&5
21153
Brett Cannon19fab762007-06-02 03:02:29 +000021154
Martin v. Löwiseba40652007-08-30 20:10:57 +000021155fi
21156
21157rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021158{ $as_echo "$as_me:$LINENO: result: $was_it_defined" >&5
21159$as_echo "$was_it_defined" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021160
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021161{ $as_echo "$as_me:$LINENO: checking for addrinfo" >&5
21162$as_echo_n "checking for addrinfo... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021163if test "${ac_cv_struct_addrinfo+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021164 $as_echo_n "(cached) " >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021165else
Martin v. Löwis11437992002-04-12 09:54:03 +000021166 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021167/* confdefs.h. */
21168_ACEOF
21169cat confdefs.h >>conftest.$ac_ext
21170cat >>conftest.$ac_ext <<_ACEOF
21171/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021172
21173# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021174int
21175main ()
21176{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021177struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000021178 ;
21179 return 0;
21180}
21181_ACEOF
21182rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021183if { (ac_try="$ac_compile"
21184case "(($ac_try" in
21185 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21186 *) ac_try_echo=$ac_try;;
21187esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021188eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21189$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021190 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021191 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021192 grep -v '^ *+' conftest.er1 >conftest.err
21193 rm -f conftest.er1
21194 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021195 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021196 (exit $ac_status); } && {
21197 test -z "$ac_c_werror_flag" ||
21198 test ! -s conftest.err
21199 } && test -s conftest.$ac_objext; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021200 ac_cv_struct_addrinfo=yes
21201else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021202 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021203sed 's/^/| /' conftest.$ac_ext >&5
21204
Martin v. Löwiseba40652007-08-30 20:10:57 +000021205 ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021206fi
21207
Martin v. Löwiseba40652007-08-30 20:10:57 +000021208rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21209fi
21210
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021211{ $as_echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
21212$as_echo "$ac_cv_struct_addrinfo" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021213if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021214
21215cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021216#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021217_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021218
21219fi
21220
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021221{ $as_echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
21222$as_echo_n "checking for sockaddr_storage... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021223if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021224 $as_echo_n "(cached) " >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021225else
Martin v. Löwis11437992002-04-12 09:54:03 +000021226 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021227/* confdefs.h. */
21228_ACEOF
21229cat confdefs.h >>conftest.$ac_ext
21230cat >>conftest.$ac_ext <<_ACEOF
21231/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021232
21233# include <sys/types.h>
21234# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021235int
21236main ()
21237{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021238struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000021239 ;
21240 return 0;
21241}
21242_ACEOF
21243rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021244if { (ac_try="$ac_compile"
21245case "(($ac_try" in
21246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21247 *) ac_try_echo=$ac_try;;
21248esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021249eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21250$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021251 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021252 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021253 grep -v '^ *+' conftest.er1 >conftest.err
21254 rm -f conftest.er1
21255 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021256 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021257 (exit $ac_status); } && {
21258 test -z "$ac_c_werror_flag" ||
21259 test ! -s conftest.err
21260 } && test -s conftest.$ac_objext; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021261 ac_cv_struct_sockaddr_storage=yes
21262else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021263 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021264sed 's/^/| /' conftest.$ac_ext >&5
21265
Martin v. Löwiseba40652007-08-30 20:10:57 +000021266 ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021267fi
21268
Martin v. Löwiseba40652007-08-30 20:10:57 +000021269rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21270fi
21271
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021272{ $as_echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
21273$as_echo "$ac_cv_struct_sockaddr_storage" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021274if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021275
21276cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021277#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021278_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021279
21280fi
21281
Guido van Rossum627b2d71993-12-24 10:39:16 +000021282# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000021283
Michael W. Hudson54241132001-12-07 15:38:26 +000021284
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021285{ $as_echo "$as_me:$LINENO: checking whether char is unsigned" >&5
21286$as_echo_n "checking whether char is unsigned... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021287if test "${ac_cv_c_char_unsigned+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021288 $as_echo_n "(cached) " >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000021289else
Martin v. Löwis11437992002-04-12 09:54:03 +000021290 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021291/* confdefs.h. */
21292_ACEOF
21293cat confdefs.h >>conftest.$ac_ext
21294cat >>conftest.$ac_ext <<_ACEOF
21295/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021296$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000021297int
21298main ()
21299{
21300static int test_array [1 - 2 * !(((char) -1) < 0)];
21301test_array [0] = 0
21302
21303 ;
21304 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000021305}
Martin v. Löwis11437992002-04-12 09:54:03 +000021306_ACEOF
21307rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021308if { (ac_try="$ac_compile"
21309case "(($ac_try" in
21310 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21311 *) ac_try_echo=$ac_try;;
21312esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021313eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21314$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021315 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021316 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021317 grep -v '^ *+' conftest.er1 >conftest.err
21318 rm -f conftest.er1
21319 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021320 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021321 (exit $ac_status); } && {
21322 test -z "$ac_c_werror_flag" ||
21323 test ! -s conftest.err
21324 } && test -s conftest.$ac_objext; then
Michael W. Hudson54241132001-12-07 15:38:26 +000021325 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000021326else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021327 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021328sed 's/^/| /' conftest.$ac_ext >&5
21329
Martin v. Löwiseba40652007-08-30 20:10:57 +000021330 ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021331fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021332
21333rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000021334fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021335{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
21336$as_echo "$ac_cv_c_char_unsigned" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021337if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021338 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021339#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021340_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021341
21342fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000021343
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021344{ $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
21345$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021346if test "${ac_cv_c_const+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021347 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000021348else
21349 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021350/* confdefs.h. */
21351_ACEOF
21352cat confdefs.h >>conftest.$ac_ext
21353cat >>conftest.$ac_ext <<_ACEOF
21354/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021355
Martin v. Löwis11437992002-04-12 09:54:03 +000021356int
21357main ()
21358{
21359/* FIXME: Include the comments suggested by Paul. */
21360#ifndef __cplusplus
21361 /* Ultrix mips cc rejects this. */
21362 typedef int charset[2];
Martin v. Löwiseba40652007-08-30 20:10:57 +000021363 const charset cs;
Martin v. Löwis11437992002-04-12 09:54:03 +000021364 /* SunOS 4.1.1 cc rejects this. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021365 char const *const *pcpcc;
21366 char **ppc;
Martin v. Löwis11437992002-04-12 09:54:03 +000021367 /* NEC SVR4.0.2 mips cc rejects this. */
21368 struct point {int x, y;};
21369 static struct point const zero = {0,0};
21370 /* AIX XL C 1.02.0.0 rejects this.
21371 It does not let you subtract one const X* pointer from another in
21372 an arm of an if-expression whose if-part is not a constant
21373 expression */
21374 const char *g = "string";
Martin v. Löwiseba40652007-08-30 20:10:57 +000021375 pcpcc = &g + (g ? g-g : 0);
Martin v. Löwis11437992002-04-12 09:54:03 +000021376 /* HPUX 7.0 cc rejects these. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021377 ++pcpcc;
21378 ppc = (char**) pcpcc;
21379 pcpcc = (char const *const *) ppc;
Martin v. Löwis11437992002-04-12 09:54:03 +000021380 { /* SCO 3.2v4 cc rejects this. */
21381 char *t;
21382 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021383
Martin v. Löwis11437992002-04-12 09:54:03 +000021384 *t++ = 0;
Martin v. Löwiseba40652007-08-30 20:10:57 +000021385 if (s) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000021386 }
21387 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
21388 int x[] = {25, 17};
21389 const int *foo = &x[0];
21390 ++foo;
21391 }
21392 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
21393 typedef const int *iptr;
21394 iptr p = 0;
21395 ++p;
21396 }
21397 { /* AIX XL C 1.02.0.0 rejects this saying
21398 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
21399 struct s { int j; const int *ap[3]; };
21400 struct s *b; b->j = 5;
21401 }
21402 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
21403 const int foo = 10;
Martin v. Löwiseba40652007-08-30 20:10:57 +000021404 if (!foo) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000021405 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021406 return !cs[0] && !zero.x;
Martin v. Löwis11437992002-04-12 09:54:03 +000021407#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000021408
Martin v. Löwis11437992002-04-12 09:54:03 +000021409 ;
21410 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000021411}
Martin v. Löwis11437992002-04-12 09:54:03 +000021412_ACEOF
21413rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021414if { (ac_try="$ac_compile"
21415case "(($ac_try" in
21416 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21417 *) ac_try_echo=$ac_try;;
21418esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021419eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21420$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021421 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021422 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021423 grep -v '^ *+' conftest.er1 >conftest.err
21424 rm -f conftest.er1
21425 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021426 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021427 (exit $ac_status); } && {
21428 test -z "$ac_c_werror_flag" ||
21429 test ! -s conftest.err
21430 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021431 ac_cv_c_const=yes
21432else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021433 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021434sed 's/^/| /' conftest.$ac_ext >&5
21435
Martin v. Löwiseba40652007-08-30 20:10:57 +000021436 ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021437fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021438
21439rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021440fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021441{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
21442$as_echo "$ac_cv_c_const" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021443if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021444
21445cat >>confdefs.h <<\_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021446#define const /**/
Martin v. Löwis11437992002-04-12 09:54:03 +000021447_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021448
21449fi
21450
Michael W. Hudson54241132001-12-07 15:38:26 +000021451
Guido van Rossumda88dad1995-01-26 00:46:29 +000021452works=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021453{ $as_echo "$as_me:$LINENO: checking for working volatile" >&5
21454$as_echo_n "checking for working volatile... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021455cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021456/* confdefs.h. */
21457_ACEOF
21458cat confdefs.h >>conftest.$ac_ext
21459cat >>conftest.$ac_ext <<_ACEOF
21460/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000021461
Martin v. Löwis11437992002-04-12 09:54:03 +000021462int
21463main ()
21464{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021465volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000021466 ;
21467 return 0;
21468}
21469_ACEOF
21470rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021471if { (ac_try="$ac_compile"
21472case "(($ac_try" in
21473 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21474 *) ac_try_echo=$ac_try;;
21475esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021476eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21477$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021478 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021479 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021480 grep -v '^ *+' conftest.er1 >conftest.err
21481 rm -f conftest.er1
21482 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021483 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021484 (exit $ac_status); } && {
21485 test -z "$ac_c_werror_flag" ||
21486 test ! -s conftest.err
21487 } && test -s conftest.$ac_objext; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000021488 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000021489else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021490 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021491sed 's/^/| /' conftest.$ac_ext >&5
21492
Martin v. Löwis11437992002-04-12 09:54:03 +000021493
21494cat >>confdefs.h <<\_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021495#define volatile /**/
Martin v. Löwis11437992002-04-12 09:54:03 +000021496_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000021497
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021498
Guido van Rossum627b2d71993-12-24 10:39:16 +000021499fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021500
21501rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021502{ $as_echo "$as_me:$LINENO: result: $works" >&5
21503$as_echo "$works" >&6; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000021504
Guido van Rossumda88dad1995-01-26 00:46:29 +000021505works=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021506{ $as_echo "$as_me:$LINENO: checking for working signed char" >&5
21507$as_echo_n "checking for working signed char... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021508cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021509/* confdefs.h. */
21510_ACEOF
21511cat confdefs.h >>conftest.$ac_ext
21512cat >>conftest.$ac_ext <<_ACEOF
21513/* end confdefs.h. */
Guido van Rossumdabb11b1994-10-11 15:04:27 +000021514
Martin v. Löwis11437992002-04-12 09:54:03 +000021515int
21516main ()
21517{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021518signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000021519 ;
21520 return 0;
21521}
21522_ACEOF
21523rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021524if { (ac_try="$ac_compile"
21525case "(($ac_try" in
21526 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21527 *) ac_try_echo=$ac_try;;
21528esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021529eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21530$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021531 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021532 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021533 grep -v '^ *+' conftest.er1 >conftest.err
21534 rm -f conftest.er1
21535 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021536 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021537 (exit $ac_status); } && {
21538 test -z "$ac_c_werror_flag" ||
21539 test ! -s conftest.err
21540 } && test -s conftest.$ac_objext; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000021541 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000021542else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021543 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021544sed 's/^/| /' conftest.$ac_ext >&5
21545
Martin v. Löwis11437992002-04-12 09:54:03 +000021546
21547cat >>confdefs.h <<\_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021548#define signed /**/
Martin v. Löwis11437992002-04-12 09:54:03 +000021549_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000021550
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021551
Guido van Rossum7f43da71994-08-01 12:15:30 +000021552fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021553
21554rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021555{ $as_echo "$as_me:$LINENO: result: $works" >&5
21556$as_echo "$works" >&6; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000021557
Guido van Rossumda88dad1995-01-26 00:46:29 +000021558have_prototypes=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021559{ $as_echo "$as_me:$LINENO: checking for prototypes" >&5
21560$as_echo_n "checking for prototypes... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021561cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021562/* confdefs.h. */
21563_ACEOF
21564cat confdefs.h >>conftest.$ac_ext
21565cat >>conftest.$ac_ext <<_ACEOF
21566/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000021567int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021568int
21569main ()
21570{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021571return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000021572 ;
21573 return 0;
21574}
21575_ACEOF
21576rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021577if { (ac_try="$ac_compile"
21578case "(($ac_try" in
21579 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21580 *) ac_try_echo=$ac_try;;
21581esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021582eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21583$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021584 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021585 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021586 grep -v '^ *+' conftest.er1 >conftest.err
21587 rm -f conftest.er1
21588 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021589 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021590 (exit $ac_status); } && {
21591 test -z "$ac_c_werror_flag" ||
21592 test ! -s conftest.err
21593 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021594
21595
21596cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021597#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021598_ACEOF
21599
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021600 have_prototypes=yes
21601
Guido van Rossumf78abae1997-01-21 22:02:36 +000021602else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021603 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021604sed 's/^/| /' conftest.$ac_ext >&5
21605
Martin v. Löwiseba40652007-08-30 20:10:57 +000021606
Guido van Rossum7f43da71994-08-01 12:15:30 +000021607fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021608
21609rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021610{ $as_echo "$as_me:$LINENO: result: $have_prototypes" >&5
21611$as_echo "$have_prototypes" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021612
Guido van Rossumda88dad1995-01-26 00:46:29 +000021613works=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021614{ $as_echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
21615$as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021616cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021617/* confdefs.h. */
21618_ACEOF
21619cat confdefs.h >>conftest.$ac_ext
21620cat >>conftest.$ac_ext <<_ACEOF
21621/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000021622
21623#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000021624int foo(int x, ...) {
21625 va_list va;
21626 va_start(va, x);
21627 va_arg(va, int);
21628 va_arg(va, char *);
21629 va_arg(va, double);
21630 return 0;
21631}
Guido van Rossum7f43da71994-08-01 12:15:30 +000021632
Martin v. Löwis11437992002-04-12 09:54:03 +000021633int
21634main ()
21635{
Guido van Rossum90eea071996-08-30 20:58:57 +000021636return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000021637 ;
21638 return 0;
21639}
21640_ACEOF
21641rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021642if { (ac_try="$ac_compile"
21643case "(($ac_try" in
21644 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21645 *) ac_try_echo=$ac_try;;
21646esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021647eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21648$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021649 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021650 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021651 grep -v '^ *+' conftest.er1 >conftest.err
21652 rm -f conftest.er1
21653 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021654 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021655 (exit $ac_status); } && {
21656 test -z "$ac_c_werror_flag" ||
21657 test ! -s conftest.err
21658 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021659
21660
21661cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021662#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021663_ACEOF
21664
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021665 works=yes
21666
Guido van Rossumf78abae1997-01-21 22:02:36 +000021667else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021668 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021669sed 's/^/| /' conftest.$ac_ext >&5
21670
Martin v. Löwiseba40652007-08-30 20:10:57 +000021671
Guido van Rossum627b2d71993-12-24 10:39:16 +000021672fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021673
21674rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021675{ $as_echo "$as_me:$LINENO: result: $works" >&5
21676$as_echo "$works" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021677
Martin v. Löwisd6320502004-08-12 13:45:08 +000021678# check for socketpair
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021679{ $as_echo "$as_me:$LINENO: checking for socketpair" >&5
21680$as_echo_n "checking for socketpair... " >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021681cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisd6320502004-08-12 13:45:08 +000021682/* confdefs.h. */
21683_ACEOF
21684cat confdefs.h >>conftest.$ac_ext
21685cat >>conftest.$ac_ext <<_ACEOF
21686/* end confdefs.h. */
21687
21688#include <sys/types.h>
21689#include <sys/socket.h>
21690
21691int
21692main ()
21693{
21694void *x=socketpair
21695 ;
21696 return 0;
21697}
21698_ACEOF
21699rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021700if { (ac_try="$ac_compile"
21701case "(($ac_try" in
21702 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21703 *) ac_try_echo=$ac_try;;
21704esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021705eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21706$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021707 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd6320502004-08-12 13:45:08 +000021708 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021709 grep -v '^ *+' conftest.er1 >conftest.err
21710 rm -f conftest.er1
21711 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021712 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021713 (exit $ac_status); } && {
21714 test -z "$ac_c_werror_flag" ||
21715 test ! -s conftest.err
21716 } && test -s conftest.$ac_objext; then
Martin v. Löwisd6320502004-08-12 13:45:08 +000021717
21718cat >>confdefs.h <<\_ACEOF
21719#define HAVE_SOCKETPAIR 1
21720_ACEOF
21721
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021722 { $as_echo "$as_me:$LINENO: result: yes" >&5
21723$as_echo "yes" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021724else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021725 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisd6320502004-08-12 13:45:08 +000021726sed 's/^/| /' conftest.$ac_ext >&5
21727
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021728 { $as_echo "$as_me:$LINENO: result: no" >&5
21729$as_echo "no" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021730
21731fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021732
21733rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd6320502004-08-12 13:45:08 +000021734
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021735# check if sockaddr has sa_len member
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021736{ $as_echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
21737$as_echo_n "checking if sockaddr has sa_len member... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021738cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021739/* confdefs.h. */
21740_ACEOF
21741cat confdefs.h >>conftest.$ac_ext
21742cat >>conftest.$ac_ext <<_ACEOF
21743/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021744#include <sys/types.h>
21745#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021746int
21747main ()
21748{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021749struct sockaddr x;
21750x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000021751 ;
21752 return 0;
21753}
21754_ACEOF
21755rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021756if { (ac_try="$ac_compile"
21757case "(($ac_try" in
21758 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21759 *) ac_try_echo=$ac_try;;
21760esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021761eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21762$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021763 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021764 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021765 grep -v '^ *+' conftest.er1 >conftest.err
21766 rm -f conftest.er1
21767 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021768 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021769 (exit $ac_status); } && {
21770 test -z "$ac_c_werror_flag" ||
21771 test ! -s conftest.err
21772 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021773 { $as_echo "$as_me:$LINENO: result: yes" >&5
21774$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021775
21776cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021777#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021778_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021779
21780else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021781 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021782sed 's/^/| /' conftest.$ac_ext >&5
21783
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021784 { $as_echo "$as_me:$LINENO: result: no" >&5
21785$as_echo "no" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021786fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021787
21788rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021789
Guido van Rossumda88dad1995-01-26 00:46:29 +000021790va_list_is_array=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021791{ $as_echo "$as_me:$LINENO: checking whether va_list is an array" >&5
21792$as_echo_n "checking whether va_list is an array... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021793cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021794/* confdefs.h. */
21795_ACEOF
21796cat confdefs.h >>conftest.$ac_ext
21797cat >>conftest.$ac_ext <<_ACEOF
21798/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021799
21800#ifdef HAVE_STDARG_PROTOTYPES
21801#include <stdarg.h>
21802#else
21803#include <varargs.h>
21804#endif
21805
Martin v. Löwis11437992002-04-12 09:54:03 +000021806int
21807main ()
21808{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021809va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000021810 ;
21811 return 0;
21812}
21813_ACEOF
21814rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021815if { (ac_try="$ac_compile"
21816case "(($ac_try" in
21817 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21818 *) ac_try_echo=$ac_try;;
21819esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021820eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21821$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021822 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021823 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021824 grep -v '^ *+' conftest.er1 >conftest.err
21825 rm -f conftest.er1
21826 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021827 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021828 (exit $ac_status); } && {
21829 test -z "$ac_c_werror_flag" ||
21830 test ! -s conftest.err
21831 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021832 :
21833else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021834 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021835sed 's/^/| /' conftest.$ac_ext >&5
21836
Martin v. Löwis11437992002-04-12 09:54:03 +000021837
21838
21839cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021840#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021841_ACEOF
21842
Guido van Rossumda88dad1995-01-26 00:46:29 +000021843 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021844
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021845fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021846
21847rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021848{ $as_echo "$as_me:$LINENO: result: $va_list_is_array" >&5
21849$as_echo "$va_list_is_array" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021850
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021851# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000021852
21853
21854
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021855{ $as_echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
21856$as_echo_n "checking for gethostbyname_r... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021857if test "${ac_cv_func_gethostbyname_r+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021858 $as_echo_n "(cached) " >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021859else
Martin v. Löwis11437992002-04-12 09:54:03 +000021860 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021861/* confdefs.h. */
21862_ACEOF
21863cat confdefs.h >>conftest.$ac_ext
21864cat >>conftest.$ac_ext <<_ACEOF
21865/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021866/* Define gethostbyname_r to an innocuous variant, in case <limits.h> declares gethostbyname_r.
21867 For example, HP-UX 11i <limits.h> declares gettimeofday. */
21868#define gethostbyname_r innocuous_gethostbyname_r
21869
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021870/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000021871 which can conflict with char gethostbyname_r (); below.
21872 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021873 <limits.h> exists even on freestanding compilers. */
21874
21875#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000021876# include <limits.h>
21877#else
21878# include <assert.h>
21879#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021880
21881#undef gethostbyname_r
21882
Martin v. Löwiseba40652007-08-30 20:10:57 +000021883/* Override any GCC internal prototype to avoid an error.
21884 Use char because int might match the return type of a GCC
21885 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021886#ifdef __cplusplus
21887extern "C"
21888#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000021889char gethostbyname_r ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021890/* The GNU C library defines this for functions which it implements
21891 to always fail with ENOSYS. Some functions are actually named
21892 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021893#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021894choke me
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021895#endif
21896
Skip Montanaro6dead952003-09-25 14:50:04 +000021897int
21898main ()
21899{
Martin v. Löwiseba40652007-08-30 20:10:57 +000021900return gethostbyname_r ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021901 ;
21902 return 0;
21903}
21904_ACEOF
21905rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021906if { (ac_try="$ac_link"
21907case "(($ac_try" in
21908 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21909 *) ac_try_echo=$ac_try;;
21910esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021911eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21912$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021913 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021914 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021915 grep -v '^ *+' conftest.er1 >conftest.err
21916 rm -f conftest.er1
21917 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021918 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021919 (exit $ac_status); } && {
21920 test -z "$ac_c_werror_flag" ||
21921 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021922 } && test -s conftest$ac_exeext && {
21923 test "$cross_compiling" = yes ||
21924 $as_test_x conftest$ac_exeext
21925 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021926 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021927else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021928 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021929sed 's/^/| /' conftest.$ac_ext >&5
21930
Martin v. Löwiseba40652007-08-30 20:10:57 +000021931 ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021932fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021933
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021934rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000021935rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021936 conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021937fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021938{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
21939$as_echo "$ac_cv_func_gethostbyname_r" >&6; }
21940if test "x$ac_cv_func_gethostbyname_r" = x""yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021941
Martin v. Löwis11437992002-04-12 09:54:03 +000021942 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021943#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021944_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021945
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021946 { $as_echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
21947$as_echo_n "checking gethostbyname_r with 6 args... " >&6; }
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021948 OLD_CFLAGS=$CFLAGS
21949 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000021950 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021951/* confdefs.h. */
21952_ACEOF
21953cat confdefs.h >>conftest.$ac_ext
21954cat >>conftest.$ac_ext <<_ACEOF
21955/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021956
21957# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021958
Martin v. Löwis11437992002-04-12 09:54:03 +000021959int
21960main ()
21961{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021962
21963 char *name;
21964 struct hostent *he, *res;
21965 char buffer[2048];
21966 int buflen = 2048;
21967 int h_errnop;
21968
21969 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000021970
21971 ;
21972 return 0;
21973}
21974_ACEOF
21975rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021976if { (ac_try="$ac_compile"
21977case "(($ac_try" in
21978 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21979 *) ac_try_echo=$ac_try;;
21980esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021981eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21982$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021983 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021984 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021985 grep -v '^ *+' conftest.er1 >conftest.err
21986 rm -f conftest.er1
21987 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000021988 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021989 (exit $ac_status); } && {
21990 test -z "$ac_c_werror_flag" ||
21991 test ! -s conftest.err
21992 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021993
21994 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021995#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021996_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021997
Martin v. Löwis11437992002-04-12 09:54:03 +000021998
21999cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022000#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022001_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022002
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022003 { $as_echo "$as_me:$LINENO: result: yes" >&5
22004$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022005
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022006else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022007 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022008sed 's/^/| /' conftest.$ac_ext >&5
22009
Martin v. Löwis11437992002-04-12 09:54:03 +000022010
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022011 { $as_echo "$as_me:$LINENO: result: no" >&5
22012$as_echo "no" >&6; }
22013 { $as_echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
22014$as_echo_n "checking gethostbyname_r with 5 args... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022015 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022016/* confdefs.h. */
22017_ACEOF
22018cat confdefs.h >>conftest.$ac_ext
22019cat >>conftest.$ac_ext <<_ACEOF
22020/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022021
22022# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000022023
Martin v. Löwis11437992002-04-12 09:54:03 +000022024int
22025main ()
22026{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022027
22028 char *name;
22029 struct hostent *he;
22030 char buffer[2048];
22031 int buflen = 2048;
22032 int h_errnop;
22033
22034 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000022035
22036 ;
22037 return 0;
22038}
22039_ACEOF
22040rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022041if { (ac_try="$ac_compile"
22042case "(($ac_try" in
22043 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22044 *) ac_try_echo=$ac_try;;
22045esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022046eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22047$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022048 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022049 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022050 grep -v '^ *+' conftest.er1 >conftest.err
22051 rm -f conftest.er1
22052 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022053 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022054 (exit $ac_status); } && {
22055 test -z "$ac_c_werror_flag" ||
22056 test ! -s conftest.err
22057 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022058
22059 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000022060#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022061_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000022062
Martin v. Löwis11437992002-04-12 09:54:03 +000022063
22064cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022065#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022066_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022067
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022068 { $as_echo "$as_me:$LINENO: result: yes" >&5
22069$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022070
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022071else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022072 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022073sed 's/^/| /' conftest.$ac_ext >&5
22074
Martin v. Löwis11437992002-04-12 09:54:03 +000022075
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022076 { $as_echo "$as_me:$LINENO: result: no" >&5
22077$as_echo "no" >&6; }
22078 { $as_echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
22079$as_echo_n "checking gethostbyname_r with 3 args... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022080 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022081/* confdefs.h. */
22082_ACEOF
22083cat confdefs.h >>conftest.$ac_ext
22084cat >>conftest.$ac_ext <<_ACEOF
22085/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022086
22087# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000022088
Martin v. Löwis11437992002-04-12 09:54:03 +000022089int
22090main ()
22091{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022092
22093 char *name;
22094 struct hostent *he;
22095 struct hostent_data data;
22096
22097 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000022098
22099 ;
22100 return 0;
22101}
22102_ACEOF
22103rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022104if { (ac_try="$ac_compile"
22105case "(($ac_try" in
22106 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22107 *) ac_try_echo=$ac_try;;
22108esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022109eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22110$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022111 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022112 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022113 grep -v '^ *+' conftest.er1 >conftest.err
22114 rm -f conftest.er1
22115 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022116 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022117 (exit $ac_status); } && {
22118 test -z "$ac_c_werror_flag" ||
22119 test ! -s conftest.err
22120 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022121
22122 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000022123#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022124_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000022125
Martin v. Löwis11437992002-04-12 09:54:03 +000022126
22127cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022128#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022129_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022130
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022131 { $as_echo "$as_me:$LINENO: result: yes" >&5
22132$as_echo "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022133
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022134else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022135 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022136sed 's/^/| /' conftest.$ac_ext >&5
22137
Martin v. Löwis11437992002-04-12 09:54:03 +000022138
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022139 { $as_echo "$as_me:$LINENO: result: no" >&5
22140$as_echo "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022141
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022142fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022143
22144rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022145
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022146fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022147
22148rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022149
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022150fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022151
22152rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022153 CFLAGS=$OLD_CFLAGS
22154
22155else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022156
Martin v. Löwis11437992002-04-12 09:54:03 +000022157
22158for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000022159do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022160as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22161{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22162$as_echo_n "checking for $ac_func... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000022163if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022164 $as_echo_n "(cached) " >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022165else
Martin v. Löwis11437992002-04-12 09:54:03 +000022166 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022167/* confdefs.h. */
22168_ACEOF
22169cat confdefs.h >>conftest.$ac_ext
22170cat >>conftest.$ac_ext <<_ACEOF
22171/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022172/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22173 For example, HP-UX 11i <limits.h> declares gettimeofday. */
22174#define $ac_func innocuous_$ac_func
22175
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022176/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000022177 which can conflict with char $ac_func (); below.
22178 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022179 <limits.h> exists even on freestanding compilers. */
22180
22181#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000022182# include <limits.h>
22183#else
22184# include <assert.h>
22185#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022186
22187#undef $ac_func
22188
Martin v. Löwiseba40652007-08-30 20:10:57 +000022189/* Override any GCC internal prototype to avoid an error.
22190 Use char because int might match the return type of a GCC
22191 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022192#ifdef __cplusplus
22193extern "C"
22194#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000022195char $ac_func ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022196/* The GNU C library defines this for functions which it implements
22197 to always fail with ENOSYS. Some functions are actually named
22198 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000022199#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022200choke me
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022201#endif
22202
Skip Montanaro6dead952003-09-25 14:50:04 +000022203int
22204main ()
22205{
Martin v. Löwiseba40652007-08-30 20:10:57 +000022206return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000022207 ;
22208 return 0;
22209}
22210_ACEOF
22211rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022212if { (ac_try="$ac_link"
22213case "(($ac_try" in
22214 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22215 *) ac_try_echo=$ac_try;;
22216esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022217eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22218$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022219 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022220 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022221 grep -v '^ *+' conftest.er1 >conftest.err
22222 rm -f conftest.er1
22223 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022224 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022225 (exit $ac_status); } && {
22226 test -z "$ac_c_werror_flag" ||
22227 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022228 } && test -s conftest$ac_exeext && {
22229 test "$cross_compiling" = yes ||
22230 $as_test_x conftest$ac_exeext
22231 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022232 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000022233else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022234 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022235sed 's/^/| /' conftest.$ac_ext >&5
22236
Martin v. Löwiseba40652007-08-30 20:10:57 +000022237 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000022238fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022239
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022240rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000022241rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000022242 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000022243fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022244ac_res=`eval 'as_val=${'$as_ac_var'}
22245 $as_echo "$as_val"'`
22246 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22247$as_echo "$ac_res" >&6; }
22248as_val=`eval 'as_val=${'$as_ac_var'}
22249 $as_echo "$as_val"'`
22250 if test "x$as_val" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022251 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022252#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022253_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022254
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022255fi
Thomas Wouters3a584202000-08-05 23:28:51 +000022256done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022257
Michael W. Hudson54241132001-12-07 15:38:26 +000022258
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000022259fi
22260
Michael W. Hudson54241132001-12-07 15:38:26 +000022261
22262
22263
22264
22265
22266
Guido van Rossum627b2d71993-12-24 10:39:16 +000022267# checks for system services
22268# (none yet)
22269
Guido van Rossum76be6ed1995-01-02 18:33:54 +000022270# Linux requires this for correct f.p. operations
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022271{ $as_echo "$as_me:$LINENO: checking for __fpu_control" >&5
22272$as_echo_n "checking for __fpu_control... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022273if test "${ac_cv_func___fpu_control+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022274 $as_echo_n "(cached) " >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022275else
Martin v. Löwis11437992002-04-12 09:54:03 +000022276 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022277/* confdefs.h. */
22278_ACEOF
22279cat confdefs.h >>conftest.$ac_ext
22280cat >>conftest.$ac_ext <<_ACEOF
22281/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022282/* Define __fpu_control to an innocuous variant, in case <limits.h> declares __fpu_control.
22283 For example, HP-UX 11i <limits.h> declares gettimeofday. */
22284#define __fpu_control innocuous___fpu_control
22285
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022286/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000022287 which can conflict with char __fpu_control (); below.
22288 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022289 <limits.h> exists even on freestanding compilers. */
22290
22291#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000022292# include <limits.h>
22293#else
22294# include <assert.h>
22295#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000022296
22297#undef __fpu_control
22298
Martin v. Löwiseba40652007-08-30 20:10:57 +000022299/* Override any GCC internal prototype to avoid an error.
22300 Use char because int might match the return type of a GCC
22301 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022302#ifdef __cplusplus
22303extern "C"
22304#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000022305char __fpu_control ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022306/* The GNU C library defines this for functions which it implements
22307 to always fail with ENOSYS. Some functions are actually named
22308 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000022309#if defined __stub___fpu_control || defined __stub_____fpu_control
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022310choke me
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022311#endif
22312
Skip Montanaro6dead952003-09-25 14:50:04 +000022313int
22314main ()
22315{
Martin v. Löwiseba40652007-08-30 20:10:57 +000022316return __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000022317 ;
22318 return 0;
22319}
22320_ACEOF
22321rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022322if { (ac_try="$ac_link"
22323case "(($ac_try" in
22324 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22325 *) ac_try_echo=$ac_try;;
22326esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022327eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22328$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022329 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022330 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022331 grep -v '^ *+' conftest.er1 >conftest.err
22332 rm -f conftest.er1
22333 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022334 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022335 (exit $ac_status); } && {
22336 test -z "$ac_c_werror_flag" ||
22337 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022338 } && test -s conftest$ac_exeext && {
22339 test "$cross_compiling" = yes ||
22340 $as_test_x conftest$ac_exeext
22341 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022342 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022343else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022344 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022345sed 's/^/| /' conftest.$ac_ext >&5
22346
Martin v. Löwiseba40652007-08-30 20:10:57 +000022347 ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022348fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022349
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022350rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000022351rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000022352 conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022353fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022354{ $as_echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
22355$as_echo "$ac_cv_func___fpu_control" >&6; }
22356if test "x$ac_cv_func___fpu_control" = x""yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022357 :
22358else
Martin v. Löwis11437992002-04-12 09:54:03 +000022359
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022360{ $as_echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
22361$as_echo_n "checking for __fpu_control in -lieee... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022362if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022363 $as_echo_n "(cached) " >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000022364else
Martin v. Löwis11437992002-04-12 09:54:03 +000022365 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000022366LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000022367cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022368/* confdefs.h. */
22369_ACEOF
22370cat confdefs.h >>conftest.$ac_ext
22371cat >>conftest.$ac_ext <<_ACEOF
22372/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022373
Martin v. Löwiseba40652007-08-30 20:10:57 +000022374/* Override any GCC internal prototype to avoid an error.
22375 Use char because int might match the return type of a GCC
22376 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022377#ifdef __cplusplus
22378extern "C"
22379#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000022380char __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000022381int
22382main ()
22383{
Martin v. Löwiseba40652007-08-30 20:10:57 +000022384return __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000022385 ;
22386 return 0;
22387}
22388_ACEOF
22389rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022390if { (ac_try="$ac_link"
22391case "(($ac_try" in
22392 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22393 *) ac_try_echo=$ac_try;;
22394esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022395eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22396$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022397 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022398 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022399 grep -v '^ *+' conftest.er1 >conftest.err
22400 rm -f conftest.er1
22401 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022402 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022403 (exit $ac_status); } && {
22404 test -z "$ac_c_werror_flag" ||
22405 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022406 } && test -s conftest$ac_exeext && {
22407 test "$cross_compiling" = yes ||
22408 $as_test_x conftest$ac_exeext
22409 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022410 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000022411else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022412 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022413sed 's/^/| /' conftest.$ac_ext >&5
22414
Martin v. Löwiseba40652007-08-30 20:10:57 +000022415 ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000022416fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022417
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022418rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000022419rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000022420 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022421LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000022422fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022423{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
22424$as_echo "$ac_cv_lib_ieee___fpu_control" >&6; }
22425if test "x$ac_cv_lib_ieee___fpu_control" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022426 cat >>confdefs.h <<_ACEOF
22427#define HAVE_LIBIEEE 1
22428_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000022429
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000022430 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000022431
Guido van Rossum627b2d71993-12-24 10:39:16 +000022432fi
22433
Michael W. Hudson54241132001-12-07 15:38:26 +000022434
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000022435fi
22436
Michael W. Hudson54241132001-12-07 15:38:26 +000022437
Guido van Rossum7f253911997-05-09 02:42:48 +000022438# Check for --with-fpectl
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022439{ $as_echo "$as_me:$LINENO: checking for --with-fpectl" >&5
22440$as_echo_n "checking for --with-fpectl... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022441
Martin v. Löwiseba40652007-08-30 20:10:57 +000022442# Check whether --with-fpectl was given.
Guido van Rossum7f253911997-05-09 02:42:48 +000022443if test "${with_fpectl+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000022444 withval=$with_fpectl;
Guido van Rossum7f253911997-05-09 02:42:48 +000022445if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000022446then
22447
22448cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000022449#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022450_ACEOF
22451
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022452 { $as_echo "$as_me:$LINENO: result: yes" >&5
22453$as_echo "yes" >&6; }
22454else { $as_echo "$as_me:$LINENO: result: no" >&5
22455$as_echo "no" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000022456fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000022457else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022458 { $as_echo "$as_me:$LINENO: result: no" >&5
22459$as_echo "no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000022460fi
22461
Guido van Rossum7f253911997-05-09 02:42:48 +000022462
Guido van Rossum7f43da71994-08-01 12:15:30 +000022463# check for --with-libm=...
22464
Guido van Rossum563e7081996-09-10 18:20:48 +000022465case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000022466Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000022467BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000022468*) LIBM=-lm
22469esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022470{ $as_echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
22471$as_echo_n "checking for --with-libm=STRING... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022472
Martin v. Löwiseba40652007-08-30 20:10:57 +000022473# Check whether --with-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000022474if test "${with_libm+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000022475 withval=$with_libm;
Guido van Rossum7f253911997-05-09 02:42:48 +000022476if test "$withval" = no
22477then LIBM=
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022478 { $as_echo "$as_me:$LINENO: result: force LIBM empty" >&5
22479$as_echo "force LIBM empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000022480elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000022481then LIBM=$withval
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022482 { $as_echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
22483$as_echo "set LIBM=\"$withval\"" >&6; }
22484else { { $as_echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
22485$as_echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000022486 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000022487fi
Guido van Rossum7f253911997-05-09 02:42:48 +000022488else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022489 { $as_echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
22490$as_echo "default LIBM=\"$LIBM\"" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000022491fi
22492
Guido van Rossum7f43da71994-08-01 12:15:30 +000022493
22494# check for --with-libc=...
22495
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022496{ $as_echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
22497$as_echo_n "checking for --with-libc=STRING... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022498
Martin v. Löwiseba40652007-08-30 20:10:57 +000022499# Check whether --with-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000022500if test "${with_libc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000022501 withval=$with_libc;
Guido van Rossum7f253911997-05-09 02:42:48 +000022502if test "$withval" = no
22503then LIBC=
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022504 { $as_echo "$as_me:$LINENO: result: force LIBC empty" >&5
22505$as_echo "force LIBC empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000022506elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000022507then LIBC=$withval
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022508 { $as_echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
22509$as_echo "set LIBC=\"$withval\"" >&6; }
22510else { { $as_echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
22511$as_echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000022512 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000022513fi
Guido van Rossum7f253911997-05-09 02:42:48 +000022514else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022515 { $as_echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
22516$as_echo "default LIBC=\"$LIBC\"" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000022517fi
22518
Guido van Rossum7f43da71994-08-01 12:15:30 +000022519
Christian Heimes0a8143f2007-12-18 23:22:54 +000022520# ************************************
22521# * Check for mathematical functions *
22522# ************************************
Mark Dickinson265d7382008-04-21 22:32:24 +000022523
Mark Dickinson7a3d8642008-04-22 00:54:27 +000022524LIBS_SAVE=$LIBS
22525LIBS="$LIBS $LIBM"
22526
Mark Dickinson04b27232009-01-04 12:29:36 +000022527# Detect whether system arithmetic is subject to x87-style double
22528# rounding issues. The result of this test has little meaning on non
22529# IEEE 754 platforms. On IEEE 754, test should return 1 if rounding
22530# mode is round-to-nearest and double rounding issues are present, and
22531# 0 otherwise. See http://bugs.python.org/issue2937 for more info.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022532{ $as_echo "$as_me:$LINENO: checking for x87-style double rounding" >&5
22533$as_echo_n "checking for x87-style double rounding... " >&6; }
Mark Dickinson04b27232009-01-04 12:29:36 +000022534if test "${ac_cv_x87_double_rounding+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022535 $as_echo_n "(cached) " >&6
Mark Dickinson04b27232009-01-04 12:29:36 +000022536else
22537
22538if test "$cross_compiling" = yes; then
22539 ac_cv_x87_double_rounding=no
22540else
22541 cat >conftest.$ac_ext <<_ACEOF
22542/* confdefs.h. */
22543_ACEOF
22544cat confdefs.h >>conftest.$ac_ext
22545cat >>conftest.$ac_ext <<_ACEOF
22546/* end confdefs.h. */
22547
22548#include <stdlib.h>
22549#include <math.h>
22550int main() {
22551 volatile double x, y, z;
22552 /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */
22553 x = 0.99999999999999989; /* 1-2**-53 */
22554 y = 1./x;
22555 if (y != 1.)
22556 exit(0);
22557 /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */
22558 x = 1e16;
22559 y = 2.99999;
22560 z = x + y;
22561 if (z != 1e16+4.)
22562 exit(0);
22563 /* both tests show evidence of double rounding */
22564 exit(1);
22565}
22566
22567_ACEOF
22568rm -f conftest$ac_exeext
22569if { (ac_try="$ac_link"
22570case "(($ac_try" in
22571 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22572 *) ac_try_echo=$ac_try;;
22573esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022574eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22575$as_echo "$ac_try_echo") >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022576 (eval "$ac_link") 2>&5
22577 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022578 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022579 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22580 { (case "(($ac_try" in
22581 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22582 *) ac_try_echo=$ac_try;;
22583esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022584eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22585$as_echo "$ac_try_echo") >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022586 (eval "$ac_try") 2>&5
22587 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022588 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022589 (exit $ac_status); }; }; then
22590 ac_cv_x87_double_rounding=no
22591else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022592 $as_echo "$as_me: program exited with status $ac_status" >&5
22593$as_echo "$as_me: failed program was:" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022594sed 's/^/| /' conftest.$ac_ext >&5
22595
22596( exit $ac_status )
22597ac_cv_x87_double_rounding=yes
22598fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022599rm -rf conftest.dSYM
Mark Dickinson04b27232009-01-04 12:29:36 +000022600rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22601fi
22602
22603
22604fi
22605
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022606{ $as_echo "$as_me:$LINENO: result: $ac_cv_x87_double_rounding" >&5
22607$as_echo "$ac_cv_x87_double_rounding" >&6; }
Mark Dickinson04b27232009-01-04 12:29:36 +000022608if test "$ac_cv_x87_double_rounding" = yes
22609then
22610
22611cat >>confdefs.h <<\_ACEOF
22612#define X87_DOUBLE_ROUNDING 1
22613_ACEOF
22614
22615fi
22616
Jesse Noller355b1262009-04-02 00:03:28 +000022617# Multiprocessing check for broken sem_getvalue
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022618{ $as_echo "$as_me:$LINENO: checking for broken sem_getvalue" >&5
22619$as_echo_n "checking for broken sem_getvalue... " >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022620if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022621 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
22622$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22623{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Jesse Noller355b1262009-04-02 00:03:28 +000022624See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022625$as_echo "$as_me: error: cannot run test program while cross compiling
Jesse Noller355b1262009-04-02 00:03:28 +000022626See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022627 { (exit 1); exit 1; }; }; }
Jesse Noller355b1262009-04-02 00:03:28 +000022628else
22629 cat >conftest.$ac_ext <<_ACEOF
22630/* confdefs.h. */
22631_ACEOF
22632cat confdefs.h >>conftest.$ac_ext
22633cat >>conftest.$ac_ext <<_ACEOF
22634/* end confdefs.h. */
22635
22636#include <unistd.h>
22637#include <fcntl.h>
22638#include <stdio.h>
22639#include <semaphore.h>
22640#include <sys/stat.h>
22641
22642int main(void){
22643 sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0);
22644 int count;
22645 int res;
22646 if(a==SEM_FAILED){
22647 perror("sem_open");
22648 return 1;
22649
22650 }
22651 res = sem_getvalue(a, &count);
22652 sem_close(a);
22653 return res==-1 ? 1 : 0;
22654}
22655
22656
22657_ACEOF
22658rm -f conftest$ac_exeext
22659if { (ac_try="$ac_link"
22660case "(($ac_try" in
22661 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22662 *) ac_try_echo=$ac_try;;
22663esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022664eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22665$as_echo "$ac_try_echo") >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022666 (eval "$ac_link") 2>&5
22667 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022668 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022669 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22670 { (case "(($ac_try" in
22671 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22672 *) ac_try_echo=$ac_try;;
22673esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022674eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22675$as_echo "$ac_try_echo") >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022676 (eval "$ac_try") 2>&5
22677 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022678 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022679 (exit $ac_status); }; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022680 { $as_echo "$as_me:$LINENO: result: no" >&5
22681$as_echo "no" >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022682else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022683 $as_echo "$as_me: program exited with status $ac_status" >&5
22684$as_echo "$as_me: failed program was:" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022685sed 's/^/| /' conftest.$ac_ext >&5
22686
22687( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022688{ $as_echo "$as_me:$LINENO: result: yes" >&5
22689$as_echo "yes" >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022690
22691cat >>confdefs.h <<\_ACEOF
22692#define HAVE_BROKEN_SEM_GETVALUE 1
22693_ACEOF
22694
22695
22696fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022697rm -rf conftest.dSYM
Jesse Noller355b1262009-04-02 00:03:28 +000022698rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22699fi
22700
22701
Mark Dickinson04b27232009-01-04 12:29:36 +000022702
Mark Dickinson265d7382008-04-21 22:32:24 +000022703# On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of
22704# -0. on some architectures.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022705{ $as_echo "$as_me:$LINENO: checking whether tanh preserves the sign of zero" >&5
22706$as_echo_n "checking whether tanh preserves the sign of zero... " >&6; }
Mark Dickinson265d7382008-04-21 22:32:24 +000022707if test "${ac_cv_tanh_preserves_zero_sign+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022708 $as_echo_n "(cached) " >&6
Mark Dickinson265d7382008-04-21 22:32:24 +000022709else
22710
22711if test "$cross_compiling" = yes; then
22712 ac_cv_tanh_preserves_zero_sign=no
22713else
22714 cat >conftest.$ac_ext <<_ACEOF
22715/* confdefs.h. */
22716_ACEOF
22717cat confdefs.h >>conftest.$ac_ext
22718cat >>conftest.$ac_ext <<_ACEOF
22719/* end confdefs.h. */
22720
22721#include <math.h>
Mark Dickinson7a3d8642008-04-22 00:54:27 +000022722#include <stdlib.h>
Mark Dickinson265d7382008-04-21 22:32:24 +000022723int main() {
22724 /* return 0 if either negative zeros don't exist
22725 on this platform or if negative zeros exist
22726 and tanh(-0.) == -0. */
22727 if (atan2(0., -1.) == atan2(-0., -1.) ||
22728 atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0);
22729 else exit(1);
22730}
22731
22732_ACEOF
22733rm -f conftest$ac_exeext
22734if { (ac_try="$ac_link"
22735case "(($ac_try" in
22736 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22737 *) ac_try_echo=$ac_try;;
22738esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022739eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22740$as_echo "$ac_try_echo") >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022741 (eval "$ac_link") 2>&5
22742 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022743 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022744 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22745 { (case "(($ac_try" in
22746 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22747 *) ac_try_echo=$ac_try;;
22748esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022749eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22750$as_echo "$ac_try_echo") >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022751 (eval "$ac_try") 2>&5
22752 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022753 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022754 (exit $ac_status); }; }; then
22755 ac_cv_tanh_preserves_zero_sign=yes
22756else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022757 $as_echo "$as_me: program exited with status $ac_status" >&5
22758$as_echo "$as_me: failed program was:" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022759sed 's/^/| /' conftest.$ac_ext >&5
22760
22761( exit $ac_status )
22762ac_cv_tanh_preserves_zero_sign=no
22763fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022764rm -rf conftest.dSYM
Mark Dickinson265d7382008-04-21 22:32:24 +000022765rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22766fi
22767
22768
22769fi
22770
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022771{ $as_echo "$as_me:$LINENO: result: $ac_cv_tanh_preserves_zero_sign" >&5
22772$as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; }
Mark Dickinson265d7382008-04-21 22:32:24 +000022773if test "$ac_cv_tanh_preserves_zero_sign" = yes
22774then
22775
22776cat >>confdefs.h <<\_ACEOF
22777#define TANH_PRESERVES_ZERO_SIGN 1
22778_ACEOF
22779
22780fi
22781
Martin v. Löwis11437992002-04-12 09:54:03 +000022782
Guido van Rossum2b3ac691996-08-30 15:18:41 +000022783
Michael W. Hudson54241132001-12-07 15:38:26 +000022784
Christian Heimes0a8143f2007-12-18 23:22:54 +000022785
22786
22787
22788
22789
Mark Dickinson8e5446f2009-04-18 14:41:37 +000022790
22791for ac_func in acosh asinh atanh copysign expm1 finite hypot log1p round
Christian Heimes0a8143f2007-12-18 23:22:54 +000022792do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022793as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22794{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22795$as_echo_n "checking for $ac_func... " >&6; }
Christian Heimes0a8143f2007-12-18 23:22:54 +000022796if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022797 $as_echo_n "(cached) " >&6
Christian Heimes0a8143f2007-12-18 23:22:54 +000022798else
22799 cat >conftest.$ac_ext <<_ACEOF
22800/* confdefs.h. */
22801_ACEOF
22802cat confdefs.h >>conftest.$ac_ext
22803cat >>conftest.$ac_ext <<_ACEOF
22804/* end confdefs.h. */
22805/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22806 For example, HP-UX 11i <limits.h> declares gettimeofday. */
22807#define $ac_func innocuous_$ac_func
22808
22809/* System header to define __stub macros and hopefully few prototypes,
22810 which can conflict with char $ac_func (); below.
22811 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22812 <limits.h> exists even on freestanding compilers. */
22813
22814#ifdef __STDC__
22815# include <limits.h>
22816#else
22817# include <assert.h>
22818#endif
22819
22820#undef $ac_func
22821
22822/* Override any GCC internal prototype to avoid an error.
22823 Use char because int might match the return type of a GCC
22824 builtin and then its argument prototype would still apply. */
22825#ifdef __cplusplus
22826extern "C"
22827#endif
22828char $ac_func ();
22829/* The GNU C library defines this for functions which it implements
22830 to always fail with ENOSYS. Some functions are actually named
22831 something starting with __ and the normal name is an alias. */
22832#if defined __stub_$ac_func || defined __stub___$ac_func
22833choke me
22834#endif
22835
22836int
22837main ()
22838{
22839return $ac_func ();
22840 ;
22841 return 0;
22842}
22843_ACEOF
22844rm -f conftest.$ac_objext conftest$ac_exeext
22845if { (ac_try="$ac_link"
22846case "(($ac_try" in
22847 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22848 *) ac_try_echo=$ac_try;;
22849esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022850eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22851$as_echo "$ac_try_echo") >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022852 (eval "$ac_link") 2>conftest.er1
22853 ac_status=$?
22854 grep -v '^ *+' conftest.er1 >conftest.err
22855 rm -f conftest.er1
22856 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022857 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022858 (exit $ac_status); } && {
22859 test -z "$ac_c_werror_flag" ||
22860 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022861 } && test -s conftest$ac_exeext && {
22862 test "$cross_compiling" = yes ||
22863 $as_test_x conftest$ac_exeext
22864 }; then
Christian Heimes0a8143f2007-12-18 23:22:54 +000022865 eval "$as_ac_var=yes"
22866else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022867 $as_echo "$as_me: failed program was:" >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022868sed 's/^/| /' conftest.$ac_ext >&5
22869
22870 eval "$as_ac_var=no"
22871fi
22872
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022873rm -rf conftest.dSYM
Christian Heimes0a8143f2007-12-18 23:22:54 +000022874rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22875 conftest$ac_exeext conftest.$ac_ext
22876fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022877ac_res=`eval 'as_val=${'$as_ac_var'}
22878 $as_echo "$as_val"'`
22879 { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22880$as_echo "$ac_res" >&6; }
22881as_val=`eval 'as_val=${'$as_ac_var'}
22882 $as_echo "$as_val"'`
22883 if test "x$as_val" = x""yes; then
Christian Heimes0a8143f2007-12-18 23:22:54 +000022884 cat >>confdefs.h <<_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022885#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
Christian Heimes0a8143f2007-12-18 23:22:54 +000022886_ACEOF
22887
22888fi
22889done
22890
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022891{ $as_echo "$as_me:$LINENO: checking whether isinf is declared" >&5
22892$as_echo_n "checking whether isinf is declared... " >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022893if test "${ac_cv_have_decl_isinf+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022894 $as_echo_n "(cached) " >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022895else
22896 cat >conftest.$ac_ext <<_ACEOF
22897/* confdefs.h. */
22898_ACEOF
22899cat confdefs.h >>conftest.$ac_ext
22900cat >>conftest.$ac_ext <<_ACEOF
22901/* end confdefs.h. */
22902#include <math.h>
22903
22904int
22905main ()
22906{
22907#ifndef isinf
22908 (void) isinf;
22909#endif
22910
22911 ;
22912 return 0;
22913}
22914_ACEOF
22915rm -f conftest.$ac_objext
22916if { (ac_try="$ac_compile"
22917case "(($ac_try" in
22918 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22919 *) ac_try_echo=$ac_try;;
22920esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022921eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22922$as_echo "$ac_try_echo") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022923 (eval "$ac_compile") 2>conftest.er1
22924 ac_status=$?
22925 grep -v '^ *+' conftest.er1 >conftest.err
22926 rm -f conftest.er1
22927 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022928 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022929 (exit $ac_status); } && {
22930 test -z "$ac_c_werror_flag" ||
22931 test ! -s conftest.err
22932 } && test -s conftest.$ac_objext; then
22933 ac_cv_have_decl_isinf=yes
22934else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022935 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022936sed 's/^/| /' conftest.$ac_ext >&5
22937
22938 ac_cv_have_decl_isinf=no
22939fi
22940
22941rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22942fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022943{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_isinf" >&5
22944$as_echo "$ac_cv_have_decl_isinf" >&6; }
22945if test "x$ac_cv_have_decl_isinf" = x""yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022946
22947cat >>confdefs.h <<_ACEOF
22948#define HAVE_DECL_ISINF 1
22949_ACEOF
22950
22951
22952else
22953 cat >>confdefs.h <<_ACEOF
22954#define HAVE_DECL_ISINF 0
22955_ACEOF
22956
22957
22958fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022959{ $as_echo "$as_me:$LINENO: checking whether isnan is declared" >&5
22960$as_echo_n "checking whether isnan is declared... " >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022961if test "${ac_cv_have_decl_isnan+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022962 $as_echo_n "(cached) " >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022963else
22964 cat >conftest.$ac_ext <<_ACEOF
22965/* confdefs.h. */
22966_ACEOF
22967cat confdefs.h >>conftest.$ac_ext
22968cat >>conftest.$ac_ext <<_ACEOF
22969/* end confdefs.h. */
22970#include <math.h>
22971
22972int
22973main ()
22974{
22975#ifndef isnan
22976 (void) isnan;
22977#endif
22978
22979 ;
22980 return 0;
22981}
22982_ACEOF
22983rm -f conftest.$ac_objext
22984if { (ac_try="$ac_compile"
22985case "(($ac_try" in
22986 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22987 *) ac_try_echo=$ac_try;;
22988esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022989eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22990$as_echo "$ac_try_echo") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022991 (eval "$ac_compile") 2>conftest.er1
22992 ac_status=$?
22993 grep -v '^ *+' conftest.er1 >conftest.err
22994 rm -f conftest.er1
22995 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000022996 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022997 (exit $ac_status); } && {
22998 test -z "$ac_c_werror_flag" ||
22999 test ! -s conftest.err
23000 } && test -s conftest.$ac_objext; then
23001 ac_cv_have_decl_isnan=yes
23002else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023003 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023004sed 's/^/| /' conftest.$ac_ext >&5
23005
23006 ac_cv_have_decl_isnan=no
23007fi
23008
23009rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23010fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023011{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_isnan" >&5
23012$as_echo "$ac_cv_have_decl_isnan" >&6; }
23013if test "x$ac_cv_have_decl_isnan" = x""yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023014
23015cat >>confdefs.h <<_ACEOF
23016#define HAVE_DECL_ISNAN 1
23017_ACEOF
23018
23019
23020else
23021 cat >>confdefs.h <<_ACEOF
23022#define HAVE_DECL_ISNAN 0
23023_ACEOF
23024
23025
23026fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023027{ $as_echo "$as_me:$LINENO: checking whether isfinite is declared" >&5
23028$as_echo_n "checking whether isfinite is declared... " >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023029if test "${ac_cv_have_decl_isfinite+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023030 $as_echo_n "(cached) " >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023031else
23032 cat >conftest.$ac_ext <<_ACEOF
23033/* confdefs.h. */
23034_ACEOF
23035cat confdefs.h >>conftest.$ac_ext
23036cat >>conftest.$ac_ext <<_ACEOF
23037/* end confdefs.h. */
23038#include <math.h>
23039
23040int
23041main ()
23042{
23043#ifndef isfinite
23044 (void) isfinite;
23045#endif
23046
23047 ;
23048 return 0;
23049}
23050_ACEOF
23051rm -f conftest.$ac_objext
23052if { (ac_try="$ac_compile"
23053case "(($ac_try" in
23054 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23055 *) ac_try_echo=$ac_try;;
23056esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023057eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23058$as_echo "$ac_try_echo") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023059 (eval "$ac_compile") 2>conftest.er1
23060 ac_status=$?
23061 grep -v '^ *+' conftest.er1 >conftest.err
23062 rm -f conftest.er1
23063 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023064 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023065 (exit $ac_status); } && {
23066 test -z "$ac_c_werror_flag" ||
23067 test ! -s conftest.err
23068 } && test -s conftest.$ac_objext; then
23069 ac_cv_have_decl_isfinite=yes
23070else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023071 $as_echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023072sed 's/^/| /' conftest.$ac_ext >&5
23073
23074 ac_cv_have_decl_isfinite=no
23075fi
23076
23077rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23078fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023079{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_isfinite" >&5
23080$as_echo "$ac_cv_have_decl_isfinite" >&6; }
23081if test "x$ac_cv_have_decl_isfinite" = x""yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000023082
23083cat >>confdefs.h <<_ACEOF
23084#define HAVE_DECL_ISFINITE 1
23085_ACEOF
23086
23087
23088else
23089 cat >>confdefs.h <<_ACEOF
23090#define HAVE_DECL_ISFINITE 0
23091_ACEOF
23092
23093
23094fi
23095
23096
Christian Heimes0a8143f2007-12-18 23:22:54 +000023097
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000023098LIBS=$LIBS_SAVE
23099
Mark Dickinsonefc82f72009-03-20 15:51:55 +000023100# determine what size digit to use for Python's longs
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023101{ $as_echo "$as_me:$LINENO: checking digit size for Python's longs" >&5
23102$as_echo_n "checking digit size for Python's longs... " >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000023103# Check whether --enable-big-digits was given.
23104if test "${enable_big_digits+set}" = set; then
23105 enableval=$enable_big_digits; case $enable_big_digits in
23106yes)
23107 enable_big_digits=30 ;;
23108no)
23109 enable_big_digits=15 ;;
2311015|30)
23111 ;;
23112*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023113 { { $as_echo "$as_me:$LINENO: error: bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" >&5
23114$as_echo "$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 +000023115 { (exit 1); exit 1; }; } ;;
23116esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023117{ $as_echo "$as_me:$LINENO: result: $enable_big_digits" >&5
23118$as_echo "$enable_big_digits" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000023119
23120cat >>confdefs.h <<_ACEOF
23121#define PYLONG_BITS_IN_DIGIT $enable_big_digits
23122_ACEOF
23123
23124
23125else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023126 { $as_echo "$as_me:$LINENO: result: no value specified" >&5
23127$as_echo "no value specified" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000023128fi
23129
23130
Guido van Rossumef2255b2000-03-10 22:30:29 +000023131# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000023132if test "${ac_cv_header_wchar_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023133 { $as_echo "$as_me:$LINENO: checking for wchar.h" >&5
23134$as_echo_n "checking for wchar.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023135if test "${ac_cv_header_wchar_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023136 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000023137fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023138{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
23139$as_echo "$ac_cv_header_wchar_h" >&6; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000023140else
Martin v. Löwis11437992002-04-12 09:54:03 +000023141 # Is the header compilable?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023142{ $as_echo "$as_me:$LINENO: checking wchar.h usability" >&5
23143$as_echo_n "checking wchar.h usability... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023144cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023145/* confdefs.h. */
23146_ACEOF
23147cat confdefs.h >>conftest.$ac_ext
23148cat >>conftest.$ac_ext <<_ACEOF
23149/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023150$ac_includes_default
23151#include <wchar.h>
23152_ACEOF
23153rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023154if { (ac_try="$ac_compile"
23155case "(($ac_try" in
23156 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23157 *) ac_try_echo=$ac_try;;
23158esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023159eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23160$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023161 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023162 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023163 grep -v '^ *+' conftest.er1 >conftest.err
23164 rm -f conftest.er1
23165 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023166 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023167 (exit $ac_status); } && {
23168 test -z "$ac_c_werror_flag" ||
23169 test ! -s conftest.err
23170 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023171 ac_header_compiler=yes
23172else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023173 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023174sed 's/^/| /' conftest.$ac_ext >&5
23175
Martin v. Löwiseba40652007-08-30 20:10:57 +000023176 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000023177fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023178
23179rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023180{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
23181$as_echo "$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023182
23183# Is the header present?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023184{ $as_echo "$as_me:$LINENO: checking wchar.h presence" >&5
23185$as_echo_n "checking wchar.h presence... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023186cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023187/* confdefs.h. */
23188_ACEOF
23189cat confdefs.h >>conftest.$ac_ext
23190cat >>conftest.$ac_ext <<_ACEOF
23191/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000023192#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023193_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000023194if { (ac_try="$ac_cpp conftest.$ac_ext"
23195case "(($ac_try" in
23196 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23197 *) ac_try_echo=$ac_try;;
23198esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023199eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23200$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023201 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023202 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000023203 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000023204 rm -f conftest.er1
23205 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023206 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023207 (exit $ac_status); } >/dev/null && {
23208 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
23209 test ! -s conftest.err
23210 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023211 ac_header_preproc=yes
23212else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023213 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023214sed 's/^/| /' conftest.$ac_ext >&5
23215
Martin v. Löwis11437992002-04-12 09:54:03 +000023216 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000023217fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023218
Martin v. Löwis11437992002-04-12 09:54:03 +000023219rm -f conftest.err conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023220{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
23221$as_echo "$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023222
23223# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023224case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
23225 yes:no: )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023226 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
23227$as_echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
23228 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the compiler's result" >&5
23229$as_echo "$as_me: WARNING: wchar.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000023230 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023231 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000023232 no:yes:* )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023233 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
23234$as_echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
23235 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
23236$as_echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
23237 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: see the Autoconf documentation" >&5
23238$as_echo "$as_me: WARNING: wchar.h: see the Autoconf documentation" >&2;}
23239 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: section \"Present But Cannot Be Compiled\"" >&5
23240$as_echo "$as_me: WARNING: wchar.h: section \"Present But Cannot Be Compiled\"" >&2;}
23241 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
23242$as_echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;}
23243 { $as_echo "$as_me:$LINENO: WARNING: wchar.h: in the future, the compiler will take precedence" >&5
23244$as_echo "$as_me: WARNING: wchar.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000023245 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000023246## -------------------------------------- ##
23247## Report this to http://bugs.python.org/ ##
23248## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000023249_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000023250 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000023251 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000023252esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023253{ $as_echo "$as_me:$LINENO: checking for wchar.h" >&5
23254$as_echo_n "checking for wchar.h... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023255if test "${ac_cv_header_wchar_h+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023256 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000023257else
23258 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000023259fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023260{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
23261$as_echo "$ac_cv_header_wchar_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023262
23263fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023264if test "x$ac_cv_header_wchar_h" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023265
23266
23267cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000023268#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000023269_ACEOF
23270
Martin v. Löwisc45929e2002-04-06 10:10:49 +000023271 wchar_h="yes"
23272
Guido van Rossumef2255b2000-03-10 22:30:29 +000023273else
Martin v. Löwis11437992002-04-12 09:54:03 +000023274 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000023275
23276fi
23277
Michael W. Hudson54241132001-12-07 15:38:26 +000023278
Martin v. Löwis11437992002-04-12 09:54:03 +000023279
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023280# determine wchar_t size
23281if test "$wchar_h" = yes
23282then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023283 # The cast to long int works around a bug in the HP C Compiler
Martin v. Löwiseba40652007-08-30 20:10:57 +000023284# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23285# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23286# This bug is HP SR number 8606223364.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023287{ $as_echo "$as_me:$LINENO: checking size of wchar_t" >&5
23288$as_echo_n "checking size of wchar_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023289if test "${ac_cv_sizeof_wchar_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023290 $as_echo_n "(cached) " >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000023291else
Martin v. Löwis11437992002-04-12 09:54:03 +000023292 if test "$cross_compiling" = yes; then
23293 # Depending upon the size, compute the lo and hi bounds.
23294cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023295/* confdefs.h. */
23296_ACEOF
23297cat confdefs.h >>conftest.$ac_ext
23298cat >>conftest.$ac_ext <<_ACEOF
23299/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023300#include <wchar.h>
23301
Martin v. Löwis11437992002-04-12 09:54:03 +000023302int
23303main ()
23304{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023305static int test_array [1 - 2 * !(((long int) (sizeof (wchar_t))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000023306test_array [0] = 0
23307
23308 ;
23309 return 0;
23310}
23311_ACEOF
23312rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023313if { (ac_try="$ac_compile"
23314case "(($ac_try" in
23315 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23316 *) ac_try_echo=$ac_try;;
23317esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023318eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23319$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023320 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023321 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023322 grep -v '^ *+' conftest.er1 >conftest.err
23323 rm -f conftest.er1
23324 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023325 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023326 (exit $ac_status); } && {
23327 test -z "$ac_c_werror_flag" ||
23328 test ! -s conftest.err
23329 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023330 ac_lo=0 ac_mid=0
23331 while :; do
23332 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023333/* confdefs.h. */
23334_ACEOF
23335cat confdefs.h >>conftest.$ac_ext
23336cat >>conftest.$ac_ext <<_ACEOF
23337/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023338#include <wchar.h>
23339
Martin v. Löwis11437992002-04-12 09:54:03 +000023340int
23341main ()
23342{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023343static int test_array [1 - 2 * !(((long int) (sizeof (wchar_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000023344test_array [0] = 0
23345
23346 ;
23347 return 0;
23348}
23349_ACEOF
23350rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023351if { (ac_try="$ac_compile"
23352case "(($ac_try" in
23353 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23354 *) ac_try_echo=$ac_try;;
23355esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023356eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23357$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023358 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023359 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023360 grep -v '^ *+' conftest.er1 >conftest.err
23361 rm -f conftest.er1
23362 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023363 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023364 (exit $ac_status); } && {
23365 test -z "$ac_c_werror_flag" ||
23366 test ! -s conftest.err
23367 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023368 ac_hi=$ac_mid; break
23369else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023370 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023371sed 's/^/| /' conftest.$ac_ext >&5
23372
Martin v. Löwiseba40652007-08-30 20:10:57 +000023373 ac_lo=`expr $ac_mid + 1`
23374 if test $ac_lo -le $ac_mid; then
23375 ac_lo= ac_hi=
23376 break
23377 fi
23378 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000023379fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023380
23381rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023382 done
23383else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023384 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023385sed 's/^/| /' conftest.$ac_ext >&5
23386
Martin v. Löwiseba40652007-08-30 20:10:57 +000023387 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023388/* confdefs.h. */
23389_ACEOF
23390cat confdefs.h >>conftest.$ac_ext
23391cat >>conftest.$ac_ext <<_ACEOF
23392/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023393#include <wchar.h>
23394
Martin v. Löwis11437992002-04-12 09:54:03 +000023395int
23396main ()
23397{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023398static int test_array [1 - 2 * !(((long int) (sizeof (wchar_t))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000023399test_array [0] = 0
23400
23401 ;
23402 return 0;
23403}
23404_ACEOF
23405rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023406if { (ac_try="$ac_compile"
23407case "(($ac_try" in
23408 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23409 *) ac_try_echo=$ac_try;;
23410esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023411eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23412$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023413 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023414 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023415 grep -v '^ *+' conftest.er1 >conftest.err
23416 rm -f conftest.er1
23417 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023418 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023419 (exit $ac_status); } && {
23420 test -z "$ac_c_werror_flag" ||
23421 test ! -s conftest.err
23422 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023423 ac_hi=-1 ac_mid=-1
23424 while :; do
23425 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023426/* confdefs.h. */
23427_ACEOF
23428cat confdefs.h >>conftest.$ac_ext
23429cat >>conftest.$ac_ext <<_ACEOF
23430/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023431#include <wchar.h>
23432
Martin v. Löwis11437992002-04-12 09:54:03 +000023433int
23434main ()
23435{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023436static int test_array [1 - 2 * !(((long int) (sizeof (wchar_t))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000023437test_array [0] = 0
23438
23439 ;
23440 return 0;
23441}
23442_ACEOF
23443rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023444if { (ac_try="$ac_compile"
23445case "(($ac_try" in
23446 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23447 *) ac_try_echo=$ac_try;;
23448esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023449eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23450$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023451 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023452 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023453 grep -v '^ *+' conftest.er1 >conftest.err
23454 rm -f conftest.er1
23455 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023456 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023457 (exit $ac_status); } && {
23458 test -z "$ac_c_werror_flag" ||
23459 test ! -s conftest.err
23460 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023461 ac_lo=$ac_mid; break
23462else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023463 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023464sed 's/^/| /' conftest.$ac_ext >&5
23465
Martin v. Löwiseba40652007-08-30 20:10:57 +000023466 ac_hi=`expr '(' $ac_mid ')' - 1`
23467 if test $ac_mid -le $ac_hi; then
23468 ac_lo= ac_hi=
23469 break
23470 fi
23471 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000023472fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023473
23474rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023475 done
23476else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023477 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023478sed 's/^/| /' conftest.$ac_ext >&5
23479
Martin v. Löwiseba40652007-08-30 20:10:57 +000023480 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000023481fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023482
23483rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023484fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023485
23486rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023487# Binary search between lo and hi bounds.
23488while test "x$ac_lo" != "x$ac_hi"; do
23489 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23490 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023491/* confdefs.h. */
23492_ACEOF
23493cat confdefs.h >>conftest.$ac_ext
23494cat >>conftest.$ac_ext <<_ACEOF
23495/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023496#include <wchar.h>
23497
Martin v. Löwis11437992002-04-12 09:54:03 +000023498int
23499main ()
23500{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023501static int test_array [1 - 2 * !(((long int) (sizeof (wchar_t))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000023502test_array [0] = 0
23503
23504 ;
23505 return 0;
23506}
23507_ACEOF
23508rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023509if { (ac_try="$ac_compile"
23510case "(($ac_try" in
23511 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23512 *) ac_try_echo=$ac_try;;
23513esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023514eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23515$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023516 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023517 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023518 grep -v '^ *+' conftest.er1 >conftest.err
23519 rm -f conftest.er1
23520 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023521 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023522 (exit $ac_status); } && {
23523 test -z "$ac_c_werror_flag" ||
23524 test ! -s conftest.err
23525 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023526 ac_hi=$ac_mid
23527else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023528 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023529sed 's/^/| /' conftest.$ac_ext >&5
23530
Martin v. Löwiseba40652007-08-30 20:10:57 +000023531 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000023532fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023533
23534rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023535done
23536case $ac_lo in
23537?*) ac_cv_sizeof_wchar_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000023538'') if test "$ac_cv_type_wchar_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023539 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23540$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23541{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023542See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023543$as_echo "$as_me: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023544See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023545 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023546 else
23547 ac_cv_sizeof_wchar_t=0
23548 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000023549esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023550else
Martin v. Löwis11437992002-04-12 09:54:03 +000023551 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023552/* confdefs.h. */
23553_ACEOF
23554cat confdefs.h >>conftest.$ac_ext
23555cat >>conftest.$ac_ext <<_ACEOF
23556/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023557#include <wchar.h>
23558
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023559static long int longval () { return (long int) (sizeof (wchar_t)); }
23560static unsigned long int ulongval () { return (long int) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000023561#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023562#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023563int
23564main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023565{
Martin v. Löwis11437992002-04-12 09:54:03 +000023566
23567 FILE *f = fopen ("conftest.val", "w");
23568 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000023569 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023570 if (((long int) (sizeof (wchar_t))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000023571 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000023572 long int i = longval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023573 if (i != ((long int) (sizeof (wchar_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000023574 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023575 fprintf (f, "%ld", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000023576 }
23577 else
23578 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000023579 unsigned long int i = ulongval ();
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023580 if (i != ((long int) (sizeof (wchar_t))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000023581 return 1;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023582 fprintf (f, "%lu", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000023583 }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023584 /* Do not output a trailing newline, as this causes \r\n confusion
23585 on some platforms. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000023586 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000023587
23588 ;
23589 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000023590}
Martin v. Löwis11437992002-04-12 09:54:03 +000023591_ACEOF
23592rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023593if { (ac_try="$ac_link"
23594case "(($ac_try" in
23595 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23596 *) ac_try_echo=$ac_try;;
23597esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023598eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23599$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023600 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023601 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023602 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023603 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023604 { (case "(($ac_try" in
23605 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23606 *) ac_try_echo=$ac_try;;
23607esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023608eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23609$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023610 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023611 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023612 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023613 (exit $ac_status); }; }; then
23614 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000023615else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023616 $as_echo "$as_me: program exited with status $ac_status" >&5
23617$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023618sed 's/^/| /' conftest.$ac_ext >&5
23619
Martin v. Löwis11437992002-04-12 09:54:03 +000023620( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000023621if test "$ac_cv_type_wchar_t" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023622 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23623$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23624{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023625See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023626$as_echo "$as_me: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023627See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023628 { (exit 77); exit 77; }; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023629 else
23630 ac_cv_sizeof_wchar_t=0
23631 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000023632fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023633rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000023634rm -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 +000023635fi
23636rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +000023637fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023638{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
23639$as_echo "$ac_cv_sizeof_wchar_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023640
23641
23642
Martin v. Löwis11437992002-04-12 09:54:03 +000023643cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023644#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000023645_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023646
Michael W. Hudson54241132001-12-07 15:38:26 +000023647
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023648fi
23649
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023650{ $as_echo "$as_me:$LINENO: checking for UCS-4 tcl" >&5
23651$as_echo_n "checking for UCS-4 tcl... " >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023652have_ucs4_tcl=no
23653cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023654/* confdefs.h. */
23655_ACEOF
23656cat confdefs.h >>conftest.$ac_ext
23657cat >>conftest.$ac_ext <<_ACEOF
23658/* end confdefs.h. */
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023659
23660#include <tcl.h>
23661#if TCL_UTF_MAX != 6
23662# error "NOT UCS4_TCL"
23663#endif
23664int
23665main ()
23666{
23667
23668 ;
23669 return 0;
23670}
23671_ACEOF
23672rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023673if { (ac_try="$ac_compile"
23674case "(($ac_try" in
23675 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23676 *) ac_try_echo=$ac_try;;
23677esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023678eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23679$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023680 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023681 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023682 grep -v '^ *+' conftest.er1 >conftest.err
23683 rm -f conftest.er1
23684 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023685 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023686 (exit $ac_status); } && {
23687 test -z "$ac_c_werror_flag" ||
23688 test ! -s conftest.err
23689 } && test -s conftest.$ac_objext; then
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023690
23691
23692cat >>confdefs.h <<\_ACEOF
23693#define HAVE_UCS4_TCL 1
23694_ACEOF
23695
23696 have_ucs4_tcl=yes
23697
23698else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023699 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023700sed 's/^/| /' conftest.$ac_ext >&5
23701
Martin v. Löwiseba40652007-08-30 20:10:57 +000023702
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023703fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023704
23705rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023706{ $as_echo "$as_me:$LINENO: result: $have_ucs4_tcl" >&5
23707$as_echo "$have_ucs4_tcl" >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023708
Skip Montanaro6dead952003-09-25 14:50:04 +000023709# check whether wchar_t is signed or not
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023710if test "$wchar_h" = yes
23711then
23712 # check whether wchar_t is signed or not
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023713 { $as_echo "$as_me:$LINENO: checking whether wchar_t is signed" >&5
23714$as_echo_n "checking whether wchar_t is signed... " >&6; }
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023715 if test "${ac_cv_wchar_t_signed+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023716 $as_echo_n "(cached) " >&6
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023717else
23718
23719 if test "$cross_compiling" = yes; then
23720 ac_cv_wchar_t_signed=yes
23721else
23722 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023723/* confdefs.h. */
23724_ACEOF
23725cat confdefs.h >>conftest.$ac_ext
23726cat >>conftest.$ac_ext <<_ACEOF
23727/* end confdefs.h. */
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023728
23729 #include <wchar.h>
23730 int main()
23731 {
Martin v. Löwis44fe0e42006-04-11 07:15:30 +000023732 /* Success: exit code 0 */
23733 exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1);
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023734 }
23735
23736_ACEOF
23737rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023738if { (ac_try="$ac_link"
23739case "(($ac_try" in
23740 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23741 *) ac_try_echo=$ac_try;;
23742esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023743eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23744$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023745 (eval "$ac_link") 2>&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023746 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023747 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023748 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023749 { (case "(($ac_try" in
23750 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23751 *) ac_try_echo=$ac_try;;
23752esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023753eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23754$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023755 (eval "$ac_try") 2>&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023756 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023757 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023758 (exit $ac_status); }; }; then
23759 ac_cv_wchar_t_signed=yes
23760else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023761 $as_echo "$as_me: program exited with status $ac_status" >&5
23762$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023763sed 's/^/| /' conftest.$ac_ext >&5
23764
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023765( exit $ac_status )
23766ac_cv_wchar_t_signed=no
23767fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023768rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000023769rm -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 +000023770fi
23771
Martin v. Löwiseba40652007-08-30 20:10:57 +000023772
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023773fi
23774
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023775 { $as_echo "$as_me:$LINENO: result: $ac_cv_wchar_t_signed" >&5
23776$as_echo "$ac_cv_wchar_t_signed" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023777fi
23778
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023779{ $as_echo "$as_me:$LINENO: checking what type to use for unicode" >&5
23780$as_echo_n "checking what type to use for unicode... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023781# Check whether --enable-unicode was given.
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023782if test "${enable_unicode+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000023783 enableval=$enable_unicode;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023784else
23785 enable_unicode=yes
Martin v. Löwiseba40652007-08-30 20:10:57 +000023786fi
23787
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023788
23789if test $enable_unicode = yes
23790then
Martin v. Löwisfd917792001-06-27 20:22:04 +000023791 # Without any arguments, Py_UNICODE defaults to two-byte mode
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023792 case "$have_ucs4_tcl" in
23793 yes) enable_unicode="ucs4"
23794 ;;
23795 *) enable_unicode="ucs2"
23796 ;;
23797 esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023798fi
23799
Martin v. Löwis0036cba2002-04-12 09:58:45 +000023800
23801
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023802case "$enable_unicode" in
23803ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000023804 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023805#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000023806_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023807
23808 ;;
23809ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000023810 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023811#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000023812_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023813
23814 ;;
23815esac
23816
Michael W. Hudson54241132001-12-07 15:38:26 +000023817
Martin v. Löwis11437992002-04-12 09:54:03 +000023818
23819
Martin v. Löwis0036cba2002-04-12 09:58:45 +000023820
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023821if test "$enable_unicode" = "no"
23822then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000023823 UNICODE_OBJS=""
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023824 { $as_echo "$as_me:$LINENO: result: not used" >&5
23825$as_echo "not used" >&6; }
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023826else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000023827 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000023828
23829cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023830#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000023831_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023832
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023833
23834 # wchar_t is only usable if it maps to an unsigned type
23835 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \
Matthias Klose7dbeed72004-12-24 08:22:17 +000023836 -a "$ac_cv_wchar_t_signed" = "no"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023837 then
23838 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023839
Martin v. Löwis11437992002-04-12 09:54:03 +000023840cat >>confdefs.h <<\_ACEOF
23841#define HAVE_USABLE_WCHAR_T 1
23842_ACEOF
23843
23844 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023845#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000023846_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023847
23848 elif test "$ac_cv_sizeof_short" = "$unicode_size"
23849 then
23850 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000023851 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023852#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000023853_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023854
23855 elif test "$ac_cv_sizeof_long" = "$unicode_size"
23856 then
23857 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000023858 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023859#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000023860_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023861
23862 else
23863 PY_UNICODE_TYPE="no type found"
23864 fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023865 { $as_echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
23866$as_echo "$PY_UNICODE_TYPE" >&6; }
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023867fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000023868
23869# check for endianness
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023870
23871 { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
23872$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023873if test "${ac_cv_c_bigendian+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023874 $as_echo_n "(cached) " >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000023875else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023876 ac_cv_c_bigendian=unknown
23877 # See if we're dealing with a universal compiler.
23878 cat >conftest.$ac_ext <<_ACEOF
23879/* confdefs.h. */
23880_ACEOF
23881cat confdefs.h >>conftest.$ac_ext
23882cat >>conftest.$ac_ext <<_ACEOF
23883/* end confdefs.h. */
23884#ifndef __APPLE_CC__
23885 not a universal capable compiler
23886 #endif
23887 typedef int dummy;
23888
23889_ACEOF
23890rm -f conftest.$ac_objext
23891if { (ac_try="$ac_compile"
23892case "(($ac_try" in
23893 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23894 *) ac_try_echo=$ac_try;;
23895esac
23896eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23897$as_echo "$ac_try_echo") >&5
23898 (eval "$ac_compile") 2>conftest.er1
23899 ac_status=$?
23900 grep -v '^ *+' conftest.er1 >conftest.err
23901 rm -f conftest.er1
23902 cat conftest.err >&5
23903 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23904 (exit $ac_status); } && {
23905 test -z "$ac_c_werror_flag" ||
23906 test ! -s conftest.err
23907 } && test -s conftest.$ac_objext; then
23908
23909 # Check for potential -arch flags. It is not universal unless
23910 # there are some -arch flags. Note that *ppc* also matches
23911 # ppc64. This check is also rather less than ideal.
23912 case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in #(
23913 *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
23914 esac
23915else
23916 $as_echo "$as_me: failed program was:" >&5
23917sed 's/^/| /' conftest.$ac_ext >&5
23918
23919
23920fi
23921
23922rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23923 if test $ac_cv_c_bigendian = unknown; then
23924 # See if sys/param.h defines the BYTE_ORDER macro.
23925 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023926/* confdefs.h. */
23927_ACEOF
23928cat confdefs.h >>conftest.$ac_ext
23929cat >>conftest.$ac_ext <<_ACEOF
23930/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000023931#include <sys/types.h>
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023932 #include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000023933
Martin v. Löwis11437992002-04-12 09:54:03 +000023934int
23935main ()
23936{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023937#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
23938 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
23939 && LITTLE_ENDIAN)
23940 bogus endian macros
23941 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000023942
23943 ;
23944 return 0;
23945}
23946_ACEOF
23947rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023948if { (ac_try="$ac_compile"
23949case "(($ac_try" in
23950 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23951 *) ac_try_echo=$ac_try;;
23952esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023953eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23954$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023955 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023956 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023957 grep -v '^ *+' conftest.er1 >conftest.err
23958 rm -f conftest.er1
23959 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023960 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023961 (exit $ac_status); } && {
23962 test -z "$ac_c_werror_flag" ||
23963 test ! -s conftest.err
23964 } && test -s conftest.$ac_objext; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000023965 # It does; now see whether it defined to BIG_ENDIAN or not.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023966 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023967/* confdefs.h. */
23968_ACEOF
23969cat confdefs.h >>conftest.$ac_ext
23970cat >>conftest.$ac_ext <<_ACEOF
23971/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000023972#include <sys/types.h>
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023973 #include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000023974
Martin v. Löwis11437992002-04-12 09:54:03 +000023975int
23976main ()
23977{
Guido van Rossumef2255b2000-03-10 22:30:29 +000023978#if BYTE_ORDER != BIG_ENDIAN
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023979 not big endian
23980 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000023981
23982 ;
23983 return 0;
23984}
23985_ACEOF
23986rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023987if { (ac_try="$ac_compile"
23988case "(($ac_try" in
23989 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23990 *) ac_try_echo=$ac_try;;
23991esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023992eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23993$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023994 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023995 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023996 grep -v '^ *+' conftest.er1 >conftest.err
23997 rm -f conftest.er1
23998 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023999 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024000 (exit $ac_status); } && {
24001 test -z "$ac_c_werror_flag" ||
24002 test ! -s conftest.err
24003 } && test -s conftest.$ac_objext; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000024004 ac_cv_c_bigendian=yes
24005else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024006 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024007sed 's/^/| /' conftest.$ac_ext >&5
24008
Martin v. Löwiseba40652007-08-30 20:10:57 +000024009 ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000024010fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024011
24012rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000024013else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024014 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024015sed 's/^/| /' conftest.$ac_ext >&5
24016
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024017
24018fi
24019
24020rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24021 fi
24022 if test $ac_cv_c_bigendian = unknown; then
24023 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
24024 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024025/* confdefs.h. */
24026_ACEOF
24027cat confdefs.h >>conftest.$ac_ext
24028cat >>conftest.$ac_ext <<_ACEOF
24029/* end confdefs.h. */
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024030#include <limits.h>
24031
Martin v. Löwis11437992002-04-12 09:54:03 +000024032int
24033main ()
24034{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024035#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
24036 bogus endian macros
24037 #endif
24038
Martin v. Löwis11437992002-04-12 09:54:03 +000024039 ;
24040 return 0;
24041}
24042_ACEOF
24043rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024044if { (ac_try="$ac_compile"
24045case "(($ac_try" in
24046 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24047 *) ac_try_echo=$ac_try;;
24048esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024049eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24050$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024051 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024052 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024053 grep -v '^ *+' conftest.er1 >conftest.err
24054 rm -f conftest.er1
24055 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024056 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024057 (exit $ac_status); } && {
24058 test -z "$ac_c_werror_flag" ||
24059 test ! -s conftest.err
24060 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024061 # It does; now see whether it defined to _BIG_ENDIAN or not.
24062 cat >conftest.$ac_ext <<_ACEOF
24063/* confdefs.h. */
24064_ACEOF
24065cat confdefs.h >>conftest.$ac_ext
24066cat >>conftest.$ac_ext <<_ACEOF
24067/* end confdefs.h. */
24068#include <limits.h>
24069
24070int
24071main ()
24072{
24073#ifndef _BIG_ENDIAN
24074 not big endian
24075 #endif
24076
24077 ;
24078 return 0;
24079}
24080_ACEOF
24081rm -f conftest.$ac_objext
24082if { (ac_try="$ac_compile"
24083case "(($ac_try" in
24084 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24085 *) ac_try_echo=$ac_try;;
24086esac
24087eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24088$as_echo "$ac_try_echo") >&5
24089 (eval "$ac_compile") 2>conftest.er1
24090 ac_status=$?
24091 grep -v '^ *+' conftest.er1 >conftest.err
24092 rm -f conftest.er1
24093 cat conftest.err >&5
24094 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24095 (exit $ac_status); } && {
24096 test -z "$ac_c_werror_flag" ||
24097 test ! -s conftest.err
24098 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000024099 ac_cv_c_bigendian=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000024100else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024101 $as_echo "$as_me: failed program was:" >&5
24102sed 's/^/| /' conftest.$ac_ext >&5
24103
24104 ac_cv_c_bigendian=no
24105fi
24106
24107rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24108else
24109 $as_echo "$as_me: failed program was:" >&5
24110sed 's/^/| /' conftest.$ac_ext >&5
24111
24112
24113fi
24114
24115rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24116 fi
24117 if test $ac_cv_c_bigendian = unknown; then
24118 # Compile a test program.
24119 if test "$cross_compiling" = yes; then
24120 # Try to guess by grepping values from an object file.
24121 cat >conftest.$ac_ext <<_ACEOF
24122/* confdefs.h. */
24123_ACEOF
24124cat confdefs.h >>conftest.$ac_ext
24125cat >>conftest.$ac_ext <<_ACEOF
24126/* end confdefs.h. */
24127short int ascii_mm[] =
24128 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
24129 short int ascii_ii[] =
24130 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
24131 int use_ascii (int i) {
24132 return ascii_mm[i] + ascii_ii[i];
24133 }
24134 short int ebcdic_ii[] =
24135 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
24136 short int ebcdic_mm[] =
24137 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
24138 int use_ebcdic (int i) {
24139 return ebcdic_mm[i] + ebcdic_ii[i];
24140 }
24141 extern int foo;
24142
24143int
24144main ()
24145{
24146return use_ascii (foo) == use_ebcdic (foo);
24147 ;
24148 return 0;
24149}
24150_ACEOF
24151rm -f conftest.$ac_objext
24152if { (ac_try="$ac_compile"
24153case "(($ac_try" in
24154 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24155 *) ac_try_echo=$ac_try;;
24156esac
24157eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24158$as_echo "$ac_try_echo") >&5
24159 (eval "$ac_compile") 2>conftest.er1
24160 ac_status=$?
24161 grep -v '^ *+' conftest.er1 >conftest.err
24162 rm -f conftest.er1
24163 cat conftest.err >&5
24164 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24165 (exit $ac_status); } && {
24166 test -z "$ac_c_werror_flag" ||
24167 test ! -s conftest.err
24168 } && test -s conftest.$ac_objext; then
24169 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
24170 ac_cv_c_bigendian=yes
24171 fi
24172 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
24173 if test "$ac_cv_c_bigendian" = unknown; then
24174 ac_cv_c_bigendian=no
24175 else
24176 # finding both strings is unlikely to happen, but who knows?
24177 ac_cv_c_bigendian=unknown
24178 fi
24179 fi
24180else
24181 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024182sed 's/^/| /' conftest.$ac_ext >&5
24183
Martin v. Löwiseba40652007-08-30 20:10:57 +000024184
Martin v. Löwis11437992002-04-12 09:54:03 +000024185fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024186
24187rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000024188else
24189 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024190/* confdefs.h. */
24191_ACEOF
24192cat confdefs.h >>conftest.$ac_ext
24193cat >>conftest.$ac_ext <<_ACEOF
24194/* end confdefs.h. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000024195$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000024196int
24197main ()
24198{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024199
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024200 /* Are we little or big endian? From Harbison&Steele. */
24201 union
24202 {
24203 long int l;
24204 char c[sizeof (long int)];
24205 } u;
24206 u.l = 1;
24207 return u.c[sizeof (long int) - 1] == 1;
Martin v. Löwiseba40652007-08-30 20:10:57 +000024208
24209 ;
24210 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000024211}
Martin v. Löwis11437992002-04-12 09:54:03 +000024212_ACEOF
24213rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024214if { (ac_try="$ac_link"
24215case "(($ac_try" in
24216 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24217 *) ac_try_echo=$ac_try;;
24218esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024219eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24220$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024221 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024222 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024223 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024224 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024225 { (case "(($ac_try" in
24226 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24227 *) ac_try_echo=$ac_try;;
24228esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024229eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24230$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024231 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024232 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024233 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024234 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000024235 ac_cv_c_bigendian=no
24236else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024237 $as_echo "$as_me: program exited with status $ac_status" >&5
24238$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024239sed 's/^/| /' conftest.$ac_ext >&5
24240
Martin v. Löwis11437992002-04-12 09:54:03 +000024241( exit $ac_status )
24242ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000024243fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024244rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024245rm -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 +000024246fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024247
24248
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024249 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000024250fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024251{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
24252$as_echo "$ac_cv_c_bigendian" >&6; }
24253 case $ac_cv_c_bigendian in #(
24254 yes)
24255 cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000024256#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024257_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024258;; #(
24259 no)
24260 ;; #(
24261 universal)
24262
24263cat >>confdefs.h <<\_ACEOF
24264#define AC_APPLE_UNIVERSAL_BUILD 1
24265_ACEOF
24266
24267 ;; #(
24268 *)
24269 { { $as_echo "$as_me:$LINENO: error: unknown endianness
24270 presetting ac_cv_c_bigendian=no (or yes) will help" >&5
24271$as_echo "$as_me: error: unknown endianness
24272 presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000024273 { (exit 1); exit 1; }; } ;;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024274 esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000024275
Michael W. Hudson54241132001-12-07 15:38:26 +000024276
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024277# Check whether right shifting a negative integer extends the sign bit
24278# or fills with zeros (like the Cray J90, according to Tim Peters).
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024279{ $as_echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
24280$as_echo_n "checking whether right shift extends the sign bit... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024281if test "${ac_cv_rshift_extends_sign+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024282 $as_echo_n "(cached) " >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000024283else
Martin v. Löwis11437992002-04-12 09:54:03 +000024284
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024285if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000024286 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024287else
Martin v. Löwis11437992002-04-12 09:54:03 +000024288 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024289/* confdefs.h. */
24290_ACEOF
24291cat confdefs.h >>conftest.$ac_ext
24292cat >>conftest.$ac_ext <<_ACEOF
24293/* end confdefs.h. */
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024294
24295int main()
24296{
Vladimir Marangozova6180282000-07-12 05:05:06 +000024297 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024298}
24299
Martin v. Löwis11437992002-04-12 09:54:03 +000024300_ACEOF
24301rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024302if { (ac_try="$ac_link"
24303case "(($ac_try" in
24304 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24305 *) ac_try_echo=$ac_try;;
24306esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024307eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24308$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024309 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024310 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024311 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024312 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024313 { (case "(($ac_try" in
24314 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24315 *) ac_try_echo=$ac_try;;
24316esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024317eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24318$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024319 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024320 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024321 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024322 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000024323 ac_cv_rshift_extends_sign=yes
24324else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024325 $as_echo "$as_me: program exited with status $ac_status" >&5
24326$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024327sed 's/^/| /' conftest.$ac_ext >&5
24328
Martin v. Löwis11437992002-04-12 09:54:03 +000024329( exit $ac_status )
24330ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000024331fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024332rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024333rm -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 +000024334fi
24335
Martin v. Löwiseba40652007-08-30 20:10:57 +000024336
24337fi
24338
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024339{ $as_echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
24340$as_echo "$ac_cv_rshift_extends_sign" >&6; }
Vladimir Marangozova6180282000-07-12 05:05:06 +000024341if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024342then
Martin v. Löwis11437992002-04-12 09:54:03 +000024343
24344cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024345#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024346_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024347
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024348fi
24349
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024350# check for getc_unlocked and related locking functions
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024351{ $as_echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
24352$as_echo_n "checking for getc_unlocked() and friends... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024353if test "${ac_cv_have_getc_unlocked+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024354 $as_echo_n "(cached) " >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024355else
Martin v. Löwis11437992002-04-12 09:54:03 +000024356
24357cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024358/* confdefs.h. */
24359_ACEOF
24360cat confdefs.h >>conftest.$ac_ext
24361cat >>conftest.$ac_ext <<_ACEOF
24362/* end confdefs.h. */
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024363#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000024364int
24365main ()
24366{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024367
24368 FILE *f = fopen("/dev/null", "r");
24369 flockfile(f);
24370 getc_unlocked(f);
24371 funlockfile(f);
24372
Martin v. Löwis11437992002-04-12 09:54:03 +000024373 ;
24374 return 0;
24375}
24376_ACEOF
24377rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024378if { (ac_try="$ac_link"
24379case "(($ac_try" in
24380 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24381 *) ac_try_echo=$ac_try;;
24382esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024383eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24384$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024385 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024386 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024387 grep -v '^ *+' conftest.er1 >conftest.err
24388 rm -f conftest.er1
24389 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024390 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024391 (exit $ac_status); } && {
24392 test -z "$ac_c_werror_flag" ||
24393 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024394 } && test -s conftest$ac_exeext && {
24395 test "$cross_compiling" = yes ||
24396 $as_test_x conftest$ac_exeext
24397 }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024398 ac_cv_have_getc_unlocked=yes
24399else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024400 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024401sed 's/^/| /' conftest.$ac_ext >&5
24402
Martin v. Löwiseba40652007-08-30 20:10:57 +000024403 ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024404fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024405
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024406rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024407rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000024408 conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024409fi
24410
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024411{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
24412$as_echo "$ac_cv_have_getc_unlocked" >&6; }
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024413if test "$ac_cv_have_getc_unlocked" = yes
24414then
Martin v. Löwis11437992002-04-12 09:54:03 +000024415
24416cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024417#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024418_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000024419
24420fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000024421
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024422# check where readline lives
Martin v. Löwis82bca632006-02-10 20:49:30 +000024423# save the value of LIBS so we don't actually link Python with readline
24424LIBS_no_readline=$LIBS
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024425
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024426# On some systems we need to link readline to a termcap compatible
24427# library. NOTE: Keep the precedence of listed libraries synchronised
24428# with setup.py.
24429py_cv_lib_readline=no
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024430{ $as_echo "$as_me:$LINENO: checking how to link readline libs" >&5
24431$as_echo_n "checking how to link readline libs... " >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024432for py_libtermcap in "" ncursesw ncurses curses termcap; do
24433 if test -z "$py_libtermcap"; then
24434 READLINE_LIBS="-lreadline"
24435 else
24436 READLINE_LIBS="-lreadline -l$py_libtermcap"
24437 fi
24438 LIBS="$READLINE_LIBS $LIBS_no_readline"
24439 cat >conftest.$ac_ext <<_ACEOF
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024440/* confdefs.h. */
24441_ACEOF
24442cat confdefs.h >>conftest.$ac_ext
24443cat >>conftest.$ac_ext <<_ACEOF
24444/* end confdefs.h. */
24445
Martin v. Löwiseba40652007-08-30 20:10:57 +000024446/* Override any GCC internal prototype to avoid an error.
24447 Use char because int might match the return type of a GCC
24448 builtin and then its argument prototype would still apply. */
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024449#ifdef __cplusplus
24450extern "C"
24451#endif
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024452char readline ();
24453int
24454main ()
24455{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024456return readline ();
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024457 ;
24458 return 0;
24459}
24460_ACEOF
24461rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024462if { (ac_try="$ac_link"
24463case "(($ac_try" in
24464 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24465 *) ac_try_echo=$ac_try;;
24466esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024467eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24468$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024469 (eval "$ac_link") 2>conftest.er1
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024470 ac_status=$?
24471 grep -v '^ *+' conftest.er1 >conftest.err
24472 rm -f conftest.er1
24473 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024474 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024475 (exit $ac_status); } && {
24476 test -z "$ac_c_werror_flag" ||
24477 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024478 } && test -s conftest$ac_exeext && {
24479 test "$cross_compiling" = yes ||
24480 $as_test_x conftest$ac_exeext
24481 }; then
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024482 py_cv_lib_readline=yes
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024483else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024484 $as_echo "$as_me: failed program was:" >&5
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024485sed 's/^/| /' conftest.$ac_ext >&5
24486
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024487
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024488fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024489
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024490rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024491rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024492 conftest$ac_exeext conftest.$ac_ext
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024493 if test $py_cv_lib_readline = yes; then
24494 break
24495 fi
24496done
24497# Uncomment this line if you want to use READINE_LIBS in Makefile or scripts
24498#AC_SUBST([READLINE_LIBS])
Gregory P. Smithe080cdf2008-09-07 19:19:04 +000024499if test $py_cv_lib_readline = no; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024500 { $as_echo "$as_me:$LINENO: result: none" >&5
24501$as_echo "none" >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024502else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024503 { $as_echo "$as_me:$LINENO: result: $READLINE_LIBS" >&5
24504$as_echo "$READLINE_LIBS" >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000024505
24506cat >>confdefs.h <<\_ACEOF
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024507#define HAVE_LIBREADLINE 1
24508_ACEOF
24509
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000024510fi
24511
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024512# check for readline 2.1
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024513{ $as_echo "$as_me:$LINENO: checking for rl_callback_handler_install in -lreadline" >&5
24514$as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; }
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024515if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024516 $as_echo_n "(cached) " >&6
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024517else
24518 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024519LIBS="-lreadline $READLINE_LIBS $LIBS"
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024520cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024521/* confdefs.h. */
24522_ACEOF
24523cat confdefs.h >>conftest.$ac_ext
24524cat >>conftest.$ac_ext <<_ACEOF
24525/* end confdefs.h. */
24526
Martin v. Löwiseba40652007-08-30 20:10:57 +000024527/* Override any GCC internal prototype to avoid an error.
24528 Use char because int might match the return type of a GCC
24529 builtin and then its argument prototype would still apply. */
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024530#ifdef __cplusplus
24531extern "C"
24532#endif
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024533char rl_callback_handler_install ();
24534int
24535main ()
24536{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024537return rl_callback_handler_install ();
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024538 ;
24539 return 0;
24540}
24541_ACEOF
24542rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024543if { (ac_try="$ac_link"
24544case "(($ac_try" in
24545 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24546 *) ac_try_echo=$ac_try;;
24547esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024548eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24549$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024550 (eval "$ac_link") 2>conftest.er1
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024551 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024552 grep -v '^ *+' conftest.er1 >conftest.err
24553 rm -f conftest.er1
24554 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024555 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024556 (exit $ac_status); } && {
24557 test -z "$ac_c_werror_flag" ||
24558 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024559 } && test -s conftest$ac_exeext && {
24560 test "$cross_compiling" = yes ||
24561 $as_test_x conftest$ac_exeext
24562 }; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024563 ac_cv_lib_readline_rl_callback_handler_install=yes
24564else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024565 $as_echo "$as_me: failed program was:" >&5
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024566sed 's/^/| /' conftest.$ac_ext >&5
24567
Martin v. Löwiseba40652007-08-30 20:10:57 +000024568 ac_cv_lib_readline_rl_callback_handler_install=no
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024569fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024570
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024571rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024572rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000024573 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024574LIBS=$ac_check_lib_save_LIBS
24575fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024576{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5
24577$as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; }
24578if test "x$ac_cv_lib_readline_rl_callback_handler_install" = x""yes; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024579
24580cat >>confdefs.h <<\_ACEOF
24581#define HAVE_RL_CALLBACK 1
24582_ACEOF
24583
24584fi
24585
24586
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024587# check for readline 2.2
24588cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024589/* confdefs.h. */
24590_ACEOF
24591cat confdefs.h >>conftest.$ac_ext
24592cat >>conftest.$ac_ext <<_ACEOF
24593/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024594#include <readline/readline.h>
24595_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000024596if { (ac_try="$ac_cpp conftest.$ac_ext"
24597case "(($ac_try" in
24598 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24599 *) ac_try_echo=$ac_try;;
24600esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024601eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24602$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024603 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024604 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000024605 grep -v '^ *+' conftest.er1 >conftest.err
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024606 rm -f conftest.er1
24607 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024608 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024609 (exit $ac_status); } >/dev/null && {
24610 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24611 test ! -s conftest.err
24612 }; then
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024613 have_readline=yes
24614else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024615 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024616sed 's/^/| /' conftest.$ac_ext >&5
24617
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024618 have_readline=no
24619fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024620
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024621rm -f conftest.err conftest.$ac_ext
24622if test $have_readline = yes
24623then
24624 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024625/* confdefs.h. */
24626_ACEOF
24627cat confdefs.h >>conftest.$ac_ext
24628cat >>conftest.$ac_ext <<_ACEOF
24629/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024630#include <readline/readline.h>
24631
24632_ACEOF
24633if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000024634 $EGREP "extern int rl_completion_append_character;" >/dev/null 2>&1; then
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000024635
24636cat >>confdefs.h <<\_ACEOF
24637#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
24638_ACEOF
24639
24640fi
24641rm -f conftest*
24642
24643fi
24644
Martin v. Löwis0daad592001-09-30 21:09:59 +000024645# check for readline 4.0
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024646{ $as_echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
24647$as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024648if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024649 $as_echo_n "(cached) " >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000024650else
Martin v. Löwis11437992002-04-12 09:54:03 +000024651 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024652LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000024653cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024654/* confdefs.h. */
24655_ACEOF
24656cat confdefs.h >>conftest.$ac_ext
24657cat >>conftest.$ac_ext <<_ACEOF
24658/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024659
Martin v. Löwiseba40652007-08-30 20:10:57 +000024660/* Override any GCC internal prototype to avoid an error.
24661 Use char because int might match the return type of a GCC
24662 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024663#ifdef __cplusplus
24664extern "C"
24665#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000024666char rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024667int
24668main ()
24669{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024670return rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024671 ;
24672 return 0;
24673}
24674_ACEOF
24675rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024676if { (ac_try="$ac_link"
24677case "(($ac_try" in
24678 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24679 *) ac_try_echo=$ac_try;;
24680esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024681eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24682$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024683 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024684 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024685 grep -v '^ *+' conftest.er1 >conftest.err
24686 rm -f conftest.er1
24687 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024688 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024689 (exit $ac_status); } && {
24690 test -z "$ac_c_werror_flag" ||
24691 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024692 } && test -s conftest$ac_exeext && {
24693 test "$cross_compiling" = yes ||
24694 $as_test_x conftest$ac_exeext
24695 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000024696 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000024697else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024698 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024699sed 's/^/| /' conftest.$ac_ext >&5
24700
Martin v. Löwiseba40652007-08-30 20:10:57 +000024701 ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000024702fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024703
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024704rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024705rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000024706 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000024707LIBS=$ac_check_lib_save_LIBS
24708fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024709{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
24710$as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; }
24711if test "x$ac_cv_lib_readline_rl_pre_input_hook" = x""yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000024712
Martin v. Löwis11437992002-04-12 09:54:03 +000024713cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000024714#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024715_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000024716
Martin v. Löwis0daad592001-09-30 21:09:59 +000024717fi
24718
Michael W. Hudson54241132001-12-07 15:38:26 +000024719
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024720# also in 4.0
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024721{ $as_echo "$as_me:$LINENO: checking for rl_completion_display_matches_hook in -lreadline" >&5
24722$as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; }
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024723if test "${ac_cv_lib_readline_rl_completion_display_matches_hook+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024724 $as_echo_n "(cached) " >&6
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024725else
24726 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024727LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024728cat >conftest.$ac_ext <<_ACEOF
24729/* confdefs.h. */
24730_ACEOF
24731cat confdefs.h >>conftest.$ac_ext
24732cat >>conftest.$ac_ext <<_ACEOF
24733/* end confdefs.h. */
24734
24735/* Override any GCC internal prototype to avoid an error.
24736 Use char because int might match the return type of a GCC
24737 builtin and then its argument prototype would still apply. */
24738#ifdef __cplusplus
24739extern "C"
24740#endif
24741char rl_completion_display_matches_hook ();
24742int
24743main ()
24744{
24745return rl_completion_display_matches_hook ();
24746 ;
24747 return 0;
24748}
24749_ACEOF
24750rm -f conftest.$ac_objext conftest$ac_exeext
24751if { (ac_try="$ac_link"
24752case "(($ac_try" in
24753 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24754 *) ac_try_echo=$ac_try;;
24755esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024756eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24757$as_echo "$ac_try_echo") >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024758 (eval "$ac_link") 2>conftest.er1
24759 ac_status=$?
24760 grep -v '^ *+' conftest.er1 >conftest.err
24761 rm -f conftest.er1
24762 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024763 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024764 (exit $ac_status); } && {
24765 test -z "$ac_c_werror_flag" ||
24766 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024767 } && test -s conftest$ac_exeext && {
24768 test "$cross_compiling" = yes ||
24769 $as_test_x conftest$ac_exeext
24770 }; then
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024771 ac_cv_lib_readline_rl_completion_display_matches_hook=yes
24772else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024773 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024774sed 's/^/| /' conftest.$ac_ext >&5
24775
24776 ac_cv_lib_readline_rl_completion_display_matches_hook=no
24777fi
24778
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024779rm -rf conftest.dSYM
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024780rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24781 conftest$ac_exeext conftest.$ac_ext
24782LIBS=$ac_check_lib_save_LIBS
24783fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024784{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5
24785$as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; }
24786if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = x""yes; then
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024787
24788cat >>confdefs.h <<\_ACEOF
24789#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1
24790_ACEOF
24791
24792fi
24793
24794
Martin v. Löwis0daad592001-09-30 21:09:59 +000024795# check for readline 4.2
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024796{ $as_echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
24797$as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024798if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024799 $as_echo_n "(cached) " >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000024800else
Martin v. Löwis11437992002-04-12 09:54:03 +000024801 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024802LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000024803cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024804/* confdefs.h. */
24805_ACEOF
24806cat confdefs.h >>conftest.$ac_ext
24807cat >>conftest.$ac_ext <<_ACEOF
24808/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024809
Martin v. Löwiseba40652007-08-30 20:10:57 +000024810/* Override any GCC internal prototype to avoid an error.
24811 Use char because int might match the return type of a GCC
24812 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024813#ifdef __cplusplus
24814extern "C"
24815#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000024816char rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024817int
24818main ()
24819{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024820return rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024821 ;
24822 return 0;
24823}
24824_ACEOF
24825rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024826if { (ac_try="$ac_link"
24827case "(($ac_try" in
24828 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24829 *) ac_try_echo=$ac_try;;
24830esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024831eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24832$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024833 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024834 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024835 grep -v '^ *+' conftest.er1 >conftest.err
24836 rm -f conftest.er1
24837 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024838 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024839 (exit $ac_status); } && {
24840 test -z "$ac_c_werror_flag" ||
24841 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024842 } && test -s conftest$ac_exeext && {
24843 test "$cross_compiling" = yes ||
24844 $as_test_x conftest$ac_exeext
24845 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000024846 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000024847else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024848 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024849sed 's/^/| /' conftest.$ac_ext >&5
24850
Martin v. Löwiseba40652007-08-30 20:10:57 +000024851 ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000024852fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024853
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024854rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024855rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000024856 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000024857LIBS=$ac_check_lib_save_LIBS
24858fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024859{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
24860$as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; }
24861if test "x$ac_cv_lib_readline_rl_completion_matches" = x""yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000024862
Martin v. Löwis11437992002-04-12 09:54:03 +000024863cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000024864#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024865_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000024866
Guido van Rossum353ae582001-07-10 16:45:32 +000024867fi
24868
Jack Jansendd19cf82001-12-06 22:36:17 +000024869
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024870# also in readline 4.2
24871cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024872/* confdefs.h. */
24873_ACEOF
24874cat confdefs.h >>conftest.$ac_ext
24875cat >>conftest.$ac_ext <<_ACEOF
24876/* end confdefs.h. */
24877#include <readline/readline.h>
24878_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000024879if { (ac_try="$ac_cpp conftest.$ac_ext"
24880case "(($ac_try" in
24881 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24882 *) ac_try_echo=$ac_try;;
24883esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024884eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24885$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024886 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024887 ac_status=$?
24888 grep -v '^ *+' conftest.er1 >conftest.err
24889 rm -f conftest.er1
24890 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024891 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024892 (exit $ac_status); } >/dev/null && {
24893 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24894 test ! -s conftest.err
24895 }; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024896 have_readline=yes
24897else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024898 $as_echo "$as_me: failed program was:" >&5
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024899sed 's/^/| /' conftest.$ac_ext >&5
24900
24901 have_readline=no
24902fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024903
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024904rm -f conftest.err conftest.$ac_ext
24905if test $have_readline = yes
24906then
24907 cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024908/* confdefs.h. */
24909_ACEOF
24910cat confdefs.h >>conftest.$ac_ext
24911cat >>conftest.$ac_ext <<_ACEOF
24912/* end confdefs.h. */
24913#include <readline/readline.h>
24914
24915_ACEOF
24916if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24917 $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then
24918
24919cat >>confdefs.h <<\_ACEOF
24920#define HAVE_RL_CATCH_SIGNAL 1
24921_ACEOF
24922
24923fi
24924rm -f conftest*
24925
24926fi
24927
Martin v. Löwis82bca632006-02-10 20:49:30 +000024928# End of readline checks: restore LIBS
24929LIBS=$LIBS_no_readline
24930
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024931{ $as_echo "$as_me:$LINENO: checking for broken nice()" >&5
24932$as_echo_n "checking for broken nice()... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024933if test "${ac_cv_broken_nice+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024934 $as_echo_n "(cached) " >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000024935else
Martin v. Löwis11437992002-04-12 09:54:03 +000024936
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024937if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000024938 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024939else
Martin v. Löwis11437992002-04-12 09:54:03 +000024940 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024941/* confdefs.h. */
24942_ACEOF
24943cat confdefs.h >>conftest.$ac_ext
24944cat >>conftest.$ac_ext <<_ACEOF
24945/* end confdefs.h. */
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024946
24947int main()
24948{
24949 int val1 = nice(1);
24950 if (val1 != -1 && val1 == nice(2))
24951 exit(0);
24952 exit(1);
24953}
24954
Martin v. Löwis11437992002-04-12 09:54:03 +000024955_ACEOF
24956rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024957if { (ac_try="$ac_link"
24958case "(($ac_try" in
24959 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24960 *) ac_try_echo=$ac_try;;
24961esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024962eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24963$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024964 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024965 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024966 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024967 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024968 { (case "(($ac_try" in
24969 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24970 *) ac_try_echo=$ac_try;;
24971esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024972eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24973$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024974 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024975 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024976 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024977 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024978 ac_cv_broken_nice=yes
24979else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024980 $as_echo "$as_me: program exited with status $ac_status" >&5
24981$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024982sed 's/^/| /' conftest.$ac_ext >&5
24983
Martin v. Löwis11437992002-04-12 09:54:03 +000024984( exit $ac_status )
24985ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024986fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024987rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000024988rm -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 +000024989fi
24990
Martin v. Löwiseba40652007-08-30 20:10:57 +000024991
24992fi
24993
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000024994{ $as_echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
24995$as_echo "$ac_cv_broken_nice" >&6; }
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024996if test "$ac_cv_broken_nice" = yes
24997then
Martin v. Löwis11437992002-04-12 09:54:03 +000024998
24999cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000025000#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000025001_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000025002
25003fi
25004
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025005{ $as_echo "$as_me:$LINENO: checking for broken poll()" >&5
25006$as_echo_n "checking for broken poll()... " >&6; }
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025007if test "$cross_compiling" = yes; then
25008 ac_cv_broken_poll=no
25009else
25010 cat >conftest.$ac_ext <<_ACEOF
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025011/* confdefs.h. */
25012_ACEOF
25013cat confdefs.h >>conftest.$ac_ext
25014cat >>conftest.$ac_ext <<_ACEOF
25015/* end confdefs.h. */
25016
25017#include <poll.h>
25018
25019int main (void)
25020 {
25021 struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 };
25022
25023 close (42);
25024
25025 int poll_test = poll (&poll_struct, 1, 0);
25026
25027 if (poll_test < 0)
25028 {
25029 exit(0);
25030 }
25031 else if (poll_test == 0 && poll_struct.revents != POLLNVAL)
25032 {
25033 exit(0);
25034 }
25035 else
25036 {
25037 exit(1);
25038 }
25039 }
25040
25041_ACEOF
25042rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025043if { (ac_try="$ac_link"
25044case "(($ac_try" in
25045 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25046 *) ac_try_echo=$ac_try;;
25047esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025048eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25049$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025050 (eval "$ac_link") 2>&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025051 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025052 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025053 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025054 { (case "(($ac_try" in
25055 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25056 *) ac_try_echo=$ac_try;;
25057esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025058eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25059$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025060 (eval "$ac_try") 2>&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025061 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025062 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025063 (exit $ac_status); }; }; then
25064 ac_cv_broken_poll=yes
25065else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025066 $as_echo "$as_me: program exited with status $ac_status" >&5
25067$as_echo "$as_me: failed program was:" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025068sed 's/^/| /' conftest.$ac_ext >&5
25069
25070( exit $ac_status )
25071ac_cv_broken_poll=no
25072fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025073rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000025074rm -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 +000025075fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025076
25077
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025078{ $as_echo "$as_me:$LINENO: result: $ac_cv_broken_poll" >&5
25079$as_echo "$ac_cv_broken_poll" >&6; }
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025080if test "$ac_cv_broken_poll" = yes
25081then
25082
25083cat >>confdefs.h <<\_ACEOF
25084#define HAVE_BROKEN_POLL 1
25085_ACEOF
25086
25087fi
25088
Brett Cannon43802422005-02-10 20:48:03 +000025089# 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 +000025090# (which is not required by ISO C or UNIX spec) and/or if we support
25091# tzname[]
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025092{ $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
25093$as_echo_n "checking for struct tm.tm_zone... " >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000025094if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025095 $as_echo_n "(cached) " >&6
Brett Cannon43802422005-02-10 20:48:03 +000025096else
25097 cat >conftest.$ac_ext <<_ACEOF
25098/* confdefs.h. */
25099_ACEOF
25100cat confdefs.h >>conftest.$ac_ext
25101cat >>conftest.$ac_ext <<_ACEOF
25102/* end confdefs.h. */
25103#include <sys/types.h>
25104#include <$ac_cv_struct_tm>
25105
25106
25107int
25108main ()
25109{
25110static struct tm ac_aggr;
25111if (ac_aggr.tm_zone)
25112return 0;
25113 ;
25114 return 0;
25115}
25116_ACEOF
25117rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025118if { (ac_try="$ac_compile"
25119case "(($ac_try" in
25120 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25121 *) ac_try_echo=$ac_try;;
25122esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025123eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25124$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025125 (eval "$ac_compile") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000025126 ac_status=$?
25127 grep -v '^ *+' conftest.er1 >conftest.err
25128 rm -f conftest.er1
25129 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025130 $as_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
Brett Cannon43802422005-02-10 20:48:03 +000025135 ac_cv_member_struct_tm_tm_zone=yes
25136else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025137 $as_echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000025138sed 's/^/| /' conftest.$ac_ext >&5
25139
Martin v. Löwiseba40652007-08-30 20:10:57 +000025140 cat >conftest.$ac_ext <<_ACEOF
Brett Cannon43802422005-02-10 20:48:03 +000025141/* confdefs.h. */
25142_ACEOF
25143cat confdefs.h >>conftest.$ac_ext
25144cat >>conftest.$ac_ext <<_ACEOF
25145/* end confdefs.h. */
25146#include <sys/types.h>
25147#include <$ac_cv_struct_tm>
25148
25149
25150int
25151main ()
25152{
25153static struct tm ac_aggr;
25154if (sizeof ac_aggr.tm_zone)
25155return 0;
25156 ;
25157 return 0;
25158}
25159_ACEOF
25160rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025161if { (ac_try="$ac_compile"
25162case "(($ac_try" in
25163 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25164 *) ac_try_echo=$ac_try;;
25165esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025166eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25167$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025168 (eval "$ac_compile") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000025169 ac_status=$?
25170 grep -v '^ *+' conftest.er1 >conftest.err
25171 rm -f conftest.er1
25172 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025173 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025174 (exit $ac_status); } && {
25175 test -z "$ac_c_werror_flag" ||
25176 test ! -s conftest.err
25177 } && test -s conftest.$ac_objext; then
Brett Cannon43802422005-02-10 20:48:03 +000025178 ac_cv_member_struct_tm_tm_zone=yes
25179else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025180 $as_echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000025181sed 's/^/| /' conftest.$ac_ext >&5
25182
Martin v. Löwiseba40652007-08-30 20:10:57 +000025183 ac_cv_member_struct_tm_tm_zone=no
Brett Cannon43802422005-02-10 20:48:03 +000025184fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025185
25186rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Brett Cannon43802422005-02-10 20:48:03 +000025187fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025188
25189rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Brett Cannon43802422005-02-10 20:48:03 +000025190fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025191{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
25192$as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
25193if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
Brett Cannon43802422005-02-10 20:48:03 +000025194
25195cat >>confdefs.h <<_ACEOF
25196#define HAVE_STRUCT_TM_TM_ZONE 1
25197_ACEOF
25198
25199
25200fi
25201
25202if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
25203
25204cat >>confdefs.h <<\_ACEOF
25205#define HAVE_TM_ZONE 1
25206_ACEOF
25207
25208else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025209 { $as_echo "$as_me:$LINENO: checking whether tzname is declared" >&5
25210$as_echo_n "checking whether tzname is declared... " >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000025211if test "${ac_cv_have_decl_tzname+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025212 $as_echo_n "(cached) " >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +000025213else
25214 cat >conftest.$ac_ext <<_ACEOF
25215/* confdefs.h. */
25216_ACEOF
25217cat confdefs.h >>conftest.$ac_ext
25218cat >>conftest.$ac_ext <<_ACEOF
25219/* end confdefs.h. */
25220#include <time.h>
25221
25222int
25223main ()
25224{
25225#ifndef tzname
25226 (void) tzname;
25227#endif
25228
25229 ;
25230 return 0;
25231}
25232_ACEOF
25233rm -f conftest.$ac_objext
25234if { (ac_try="$ac_compile"
25235case "(($ac_try" in
25236 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25237 *) ac_try_echo=$ac_try;;
25238esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025239eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25240$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025241 (eval "$ac_compile") 2>conftest.er1
25242 ac_status=$?
25243 grep -v '^ *+' conftest.er1 >conftest.err
25244 rm -f conftest.er1
25245 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025246 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025247 (exit $ac_status); } && {
25248 test -z "$ac_c_werror_flag" ||
25249 test ! -s conftest.err
25250 } && test -s conftest.$ac_objext; then
25251 ac_cv_have_decl_tzname=yes
25252else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025253 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025254sed 's/^/| /' conftest.$ac_ext >&5
25255
25256 ac_cv_have_decl_tzname=no
25257fi
25258
25259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25260fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025261{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5
25262$as_echo "$ac_cv_have_decl_tzname" >&6; }
25263if test "x$ac_cv_have_decl_tzname" = x""yes; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000025264
25265cat >>confdefs.h <<_ACEOF
25266#define HAVE_DECL_TZNAME 1
25267_ACEOF
25268
25269
25270else
25271 cat >>confdefs.h <<_ACEOF
25272#define HAVE_DECL_TZNAME 0
25273_ACEOF
25274
25275
25276fi
25277
25278
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025279 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
25280$as_echo_n "checking for tzname... " >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000025281if test "${ac_cv_var_tzname+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025282 $as_echo_n "(cached) " >&6
Brett Cannon43802422005-02-10 20:48:03 +000025283else
25284 cat >conftest.$ac_ext <<_ACEOF
25285/* confdefs.h. */
25286_ACEOF
25287cat confdefs.h >>conftest.$ac_ext
25288cat >>conftest.$ac_ext <<_ACEOF
25289/* end confdefs.h. */
25290#include <time.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +000025291#if !HAVE_DECL_TZNAME
25292extern char *tzname[];
Brett Cannon43802422005-02-10 20:48:03 +000025293#endif
25294
25295int
25296main ()
25297{
Martin v. Löwiseba40652007-08-30 20:10:57 +000025298return tzname[0][0];
Brett Cannon43802422005-02-10 20:48:03 +000025299 ;
25300 return 0;
25301}
25302_ACEOF
25303rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025304if { (ac_try="$ac_link"
25305case "(($ac_try" in
25306 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25307 *) ac_try_echo=$ac_try;;
25308esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025309eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25310$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025311 (eval "$ac_link") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000025312 ac_status=$?
25313 grep -v '^ *+' conftest.er1 >conftest.err
25314 rm -f conftest.er1
25315 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025316 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025317 (exit $ac_status); } && {
25318 test -z "$ac_c_werror_flag" ||
25319 test ! -s conftest.err
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025320 } && test -s conftest$ac_exeext && {
25321 test "$cross_compiling" = yes ||
25322 $as_test_x conftest$ac_exeext
25323 }; then
Brett Cannon43802422005-02-10 20:48:03 +000025324 ac_cv_var_tzname=yes
25325else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025326 $as_echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000025327sed 's/^/| /' conftest.$ac_ext >&5
25328
Martin v. Löwiseba40652007-08-30 20:10:57 +000025329 ac_cv_var_tzname=no
Brett Cannon43802422005-02-10 20:48:03 +000025330fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025331
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025332rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000025333rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Brett Cannon43802422005-02-10 20:48:03 +000025334 conftest$ac_exeext conftest.$ac_ext
25335fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025336{ $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
25337$as_echo "$ac_cv_var_tzname" >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000025338 if test $ac_cv_var_tzname = yes; then
25339
25340cat >>confdefs.h <<\_ACEOF
25341#define HAVE_TZNAME 1
25342_ACEOF
25343
25344 fi
25345fi
25346
Nicholas Bastine62c5c82004-03-21 23:45:42 +000025347
Martin v. Löwis1d459062005-03-14 21:23:33 +000025348# check tzset(3) exists and works like we expect it to
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025349{ $as_echo "$as_me:$LINENO: checking for working tzset()" >&5
25350$as_echo_n "checking for working tzset()... " >&6; }
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025351if test "${ac_cv_working_tzset+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025352 $as_echo_n "(cached) " >&6
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025353else
25354
25355if test "$cross_compiling" = yes; then
25356 ac_cv_working_tzset=no
25357else
25358 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025359/* confdefs.h. */
25360_ACEOF
25361cat confdefs.h >>conftest.$ac_ext
25362cat >>conftest.$ac_ext <<_ACEOF
25363/* end confdefs.h. */
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025364
25365#include <stdlib.h>
25366#include <time.h>
Brett Cannon18367812003-09-19 00:59:16 +000025367#include <string.h>
Brett Cannon43802422005-02-10 20:48:03 +000025368
25369#if HAVE_TZNAME
25370extern char *tzname[];
25371#endif
25372
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025373int main()
25374{
Brett Cannon18367812003-09-19 00:59:16 +000025375 /* Note that we need to ensure that not only does tzset(3)
25376 do 'something' with localtime, but it works as documented
25377 in the library reference and as expected by the test suite.
Martin v. Löwis1d459062005-03-14 21:23:33 +000025378 This includes making sure that tzname is set properly if
25379 tm->tm_zone does not exist since it is the alternative way
25380 of getting timezone info.
Brett Cannon18367812003-09-19 00:59:16 +000025381
25382 Red Hat 6.2 doesn't understand the southern hemisphere
Martin v. Löwis1d459062005-03-14 21:23:33 +000025383 after New Year's Day.
Brett Cannon18367812003-09-19 00:59:16 +000025384 */
25385
Martin v. Löwis1d459062005-03-14 21:23:33 +000025386 time_t groundhogday = 1044144000; /* GMT-based */
Brett Cannon18367812003-09-19 00:59:16 +000025387 time_t midyear = groundhogday + (365 * 24 * 3600 / 2);
25388
Neal Norwitz7f2588c2003-04-11 15:35:53 +000025389 putenv("TZ=UTC+0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025390 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000025391 if (localtime(&groundhogday)->tm_hour != 0)
25392 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000025393#if HAVE_TZNAME
25394 /* For UTC, tzname[1] is sometimes "", sometimes " " */
25395 if (strcmp(tzname[0], "UTC") ||
25396 (tzname[1][0] != 0 && tzname[1][0] != ' '))
25397 exit(1);
25398#endif
Brett Cannon18367812003-09-19 00:59:16 +000025399
Neal Norwitz7f2588c2003-04-11 15:35:53 +000025400 putenv("TZ=EST+5EDT,M4.1.0,M10.5.0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025401 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000025402 if (localtime(&groundhogday)->tm_hour != 19)
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025403 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000025404#if HAVE_TZNAME
25405 if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT"))
25406 exit(1);
25407#endif
Brett Cannon18367812003-09-19 00:59:16 +000025408
25409 putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0");
25410 tzset();
25411 if (localtime(&groundhogday)->tm_hour != 11)
25412 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000025413#if HAVE_TZNAME
25414 if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT"))
25415 exit(1);
25416#endif
25417
25418#if HAVE_STRUCT_TM_TM_ZONE
Brett Cannon18367812003-09-19 00:59:16 +000025419 if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT"))
25420 exit(1);
25421 if (strcmp(localtime(&midyear)->tm_zone, "AEST"))
25422 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000025423#endif
Brett Cannon18367812003-09-19 00:59:16 +000025424
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025425 exit(0);
25426}
25427
25428_ACEOF
25429rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025430if { (ac_try="$ac_link"
25431case "(($ac_try" in
25432 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25433 *) ac_try_echo=$ac_try;;
25434esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025435eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25436$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025437 (eval "$ac_link") 2>&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025438 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025439 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025440 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025441 { (case "(($ac_try" in
25442 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25443 *) ac_try_echo=$ac_try;;
25444esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025445eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25446$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025447 (eval "$ac_try") 2>&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025448 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025449 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025450 (exit $ac_status); }; }; then
25451 ac_cv_working_tzset=yes
25452else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025453 $as_echo "$as_me: program exited with status $ac_status" >&5
25454$as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000025455sed 's/^/| /' conftest.$ac_ext >&5
25456
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025457( exit $ac_status )
25458ac_cv_working_tzset=no
25459fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025460rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000025461rm -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 +000025462fi
25463
Martin v. Löwiseba40652007-08-30 20:10:57 +000025464
25465fi
25466
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025467{ $as_echo "$as_me:$LINENO: result: $ac_cv_working_tzset" >&5
25468$as_echo "$ac_cv_working_tzset" >&6; }
Guido van Rossumd11b62e2003-03-14 21:51:36 +000025469if test "$ac_cv_working_tzset" = yes
25470then
25471
25472cat >>confdefs.h <<\_ACEOF
25473#define HAVE_WORKING_TZSET 1
25474_ACEOF
25475
25476fi
25477
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025478# Look for subsecond timestamps in struct stat
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025479{ $as_echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
25480$as_echo_n "checking for tv_nsec in struct stat... " >&6; }
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025481if test "${ac_cv_stat_tv_nsec+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025482 $as_echo_n "(cached) " >&6
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025483else
25484 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025485/* confdefs.h. */
25486_ACEOF
25487cat confdefs.h >>conftest.$ac_ext
25488cat >>conftest.$ac_ext <<_ACEOF
25489/* end confdefs.h. */
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025490#include <sys/stat.h>
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025491int
25492main ()
25493{
25494
25495struct stat st;
25496st.st_mtim.tv_nsec = 1;
25497
25498 ;
25499 return 0;
25500}
25501_ACEOF
25502rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025503if { (ac_try="$ac_compile"
25504case "(($ac_try" in
25505 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25506 *) ac_try_echo=$ac_try;;
25507esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025508eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25509$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025510 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025511 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000025512 grep -v '^ *+' conftest.er1 >conftest.err
25513 rm -f conftest.er1
25514 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025515 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025516 (exit $ac_status); } && {
25517 test -z "$ac_c_werror_flag" ||
25518 test ! -s conftest.err
25519 } && test -s conftest.$ac_objext; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000025520 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025521else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025522 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000025523sed 's/^/| /' conftest.$ac_ext >&5
25524
Martin v. Löwiseba40652007-08-30 20:10:57 +000025525 ac_cv_stat_tv_nsec=no
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025526fi
25527
Martin v. Löwiseba40652007-08-30 20:10:57 +000025528rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25529fi
25530
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025531{ $as_echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
25532$as_echo "$ac_cv_stat_tv_nsec" >&6; }
Martin v. Löwis94717ed2002-09-09 14:24:16 +000025533if test "$ac_cv_stat_tv_nsec" = yes
25534then
25535
25536cat >>confdefs.h <<\_ACEOF
25537#define HAVE_STAT_TV_NSEC 1
25538_ACEOF
25539
25540fi
25541
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025542# Look for BSD style subsecond timestamps in struct stat
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025543{ $as_echo "$as_me:$LINENO: checking for tv_nsec2 in struct stat" >&5
25544$as_echo_n "checking for tv_nsec2 in struct stat... " >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025545if test "${ac_cv_stat_tv_nsec2+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025546 $as_echo_n "(cached) " >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025547else
25548 cat >conftest.$ac_ext <<_ACEOF
25549/* confdefs.h. */
25550_ACEOF
25551cat confdefs.h >>conftest.$ac_ext
25552cat >>conftest.$ac_ext <<_ACEOF
25553/* end confdefs.h. */
25554#include <sys/stat.h>
25555int
25556main ()
25557{
25558
25559struct stat st;
25560st.st_mtimespec.tv_nsec = 1;
25561
25562 ;
25563 return 0;
25564}
25565_ACEOF
25566rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025567if { (ac_try="$ac_compile"
25568case "(($ac_try" in
25569 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25570 *) ac_try_echo=$ac_try;;
25571esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025572eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25573$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025574 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025575 ac_status=$?
25576 grep -v '^ *+' conftest.er1 >conftest.err
25577 rm -f conftest.er1
25578 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025579 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025580 (exit $ac_status); } && {
25581 test -z "$ac_c_werror_flag" ||
25582 test ! -s conftest.err
25583 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025584 ac_cv_stat_tv_nsec2=yes
25585else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025586 $as_echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025587sed 's/^/| /' conftest.$ac_ext >&5
25588
Martin v. Löwiseba40652007-08-30 20:10:57 +000025589 ac_cv_stat_tv_nsec2=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025590fi
25591
Martin v. Löwiseba40652007-08-30 20:10:57 +000025592rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25593fi
25594
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025595{ $as_echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec2" >&5
25596$as_echo "$ac_cv_stat_tv_nsec2" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000025597if test "$ac_cv_stat_tv_nsec2" = yes
25598then
25599
25600cat >>confdefs.h <<\_ACEOF
25601#define HAVE_STAT_TV_NSEC2 1
25602_ACEOF
25603
25604fi
25605
Jack Jansen666b1e72001-10-31 12:11:48 +000025606# On HP/UX 11.0, mvwdelch is a block with a return statement
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025607{ $as_echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
25608$as_echo_n "checking whether mvwdelch is an expression... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000025609if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025610 $as_echo_n "(cached) " >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000025611else
Martin v. Löwis11437992002-04-12 09:54:03 +000025612 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025613/* confdefs.h. */
25614_ACEOF
25615cat confdefs.h >>conftest.$ac_ext
25616cat >>conftest.$ac_ext <<_ACEOF
25617/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000025618#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000025619int
25620main ()
25621{
Jack Jansen666b1e72001-10-31 12:11:48 +000025622
25623 int rtn;
25624 rtn = mvwdelch(0,0,0);
25625
Martin v. Löwis11437992002-04-12 09:54:03 +000025626 ;
25627 return 0;
25628}
25629_ACEOF
25630rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025631if { (ac_try="$ac_compile"
25632case "(($ac_try" in
25633 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25634 *) ac_try_echo=$ac_try;;
25635esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025636eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25637$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025638 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000025639 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000025640 grep -v '^ *+' conftest.er1 >conftest.err
25641 rm -f conftest.er1
25642 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025643 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025644 (exit $ac_status); } && {
25645 test -z "$ac_c_werror_flag" ||
25646 test ! -s conftest.err
25647 } && test -s conftest.$ac_objext; then
Jack Jansen666b1e72001-10-31 12:11:48 +000025648 ac_cv_mvwdelch_is_expression=yes
25649else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025650 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000025651sed 's/^/| /' conftest.$ac_ext >&5
25652
Martin v. Löwiseba40652007-08-30 20:10:57 +000025653 ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000025654fi
25655
Martin v. Löwiseba40652007-08-30 20:10:57 +000025656rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25657fi
25658
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025659{ $as_echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
25660$as_echo "$ac_cv_mvwdelch_is_expression" >&6; }
Jack Jansen666b1e72001-10-31 12:11:48 +000025661
25662if test "$ac_cv_mvwdelch_is_expression" = yes
25663then
Martin v. Löwis11437992002-04-12 09:54:03 +000025664
25665cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000025666#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000025667_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000025668
25669fi
25670
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025671{ $as_echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
25672$as_echo_n "checking whether WINDOW has _flags... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000025673if test "${ac_cv_window_has_flags+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025674 $as_echo_n "(cached) " >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000025675else
Martin v. Löwis11437992002-04-12 09:54:03 +000025676 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025677/* confdefs.h. */
25678_ACEOF
25679cat confdefs.h >>conftest.$ac_ext
25680cat >>conftest.$ac_ext <<_ACEOF
25681/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000025682#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000025683int
25684main ()
25685{
Jack Jansen666b1e72001-10-31 12:11:48 +000025686
25687 WINDOW *w;
25688 w->_flags = 0;
25689
Martin v. Löwis11437992002-04-12 09:54:03 +000025690 ;
25691 return 0;
25692}
25693_ACEOF
25694rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025695if { (ac_try="$ac_compile"
25696case "(($ac_try" in
25697 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25698 *) ac_try_echo=$ac_try;;
25699esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025700eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25701$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025702 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000025703 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000025704 grep -v '^ *+' conftest.er1 >conftest.err
25705 rm -f conftest.er1
25706 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025707 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025708 (exit $ac_status); } && {
25709 test -z "$ac_c_werror_flag" ||
25710 test ! -s conftest.err
25711 } && test -s conftest.$ac_objext; then
Jack Jansen666b1e72001-10-31 12:11:48 +000025712 ac_cv_window_has_flags=yes
25713else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025714 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000025715sed 's/^/| /' conftest.$ac_ext >&5
25716
Martin v. Löwiseba40652007-08-30 20:10:57 +000025717 ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000025718fi
25719
Martin v. Löwiseba40652007-08-30 20:10:57 +000025720rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25721fi
25722
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025723{ $as_echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
25724$as_echo "$ac_cv_window_has_flags" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000025725
Jack Jansen666b1e72001-10-31 12:11:48 +000025726
25727if test "$ac_cv_window_has_flags" = yes
25728then
Martin v. Löwis11437992002-04-12 09:54:03 +000025729
25730cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000025731#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000025732_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000025733
25734fi
25735
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025736{ $as_echo "$as_me:$LINENO: checking for is_term_resized" >&5
25737$as_echo_n "checking for is_term_resized... " >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025738cat >conftest.$ac_ext <<_ACEOF
25739/* confdefs.h. */
25740_ACEOF
25741cat confdefs.h >>conftest.$ac_ext
25742cat >>conftest.$ac_ext <<_ACEOF
25743/* end confdefs.h. */
25744#include <curses.h>
25745int
25746main ()
25747{
25748void *x=is_term_resized
25749 ;
25750 return 0;
25751}
25752_ACEOF
25753rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025754if { (ac_try="$ac_compile"
25755case "(($ac_try" in
25756 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25757 *) ac_try_echo=$ac_try;;
25758esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025759eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25760$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025761 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025762 ac_status=$?
25763 grep -v '^ *+' conftest.er1 >conftest.err
25764 rm -f conftest.er1
25765 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025766 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025767 (exit $ac_status); } && {
25768 test -z "$ac_c_werror_flag" ||
25769 test ! -s conftest.err
25770 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025771
25772cat >>confdefs.h <<\_ACEOF
25773#define HAVE_CURSES_IS_TERM_RESIZED 1
25774_ACEOF
25775
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025776 { $as_echo "$as_me:$LINENO: result: yes" >&5
25777$as_echo "yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025778else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025779 $as_echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025780sed 's/^/| /' conftest.$ac_ext >&5
25781
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025782 { $as_echo "$as_me:$LINENO: result: no" >&5
25783$as_echo "no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025784
25785fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025786
Martin v. Löwiseba40652007-08-30 20:10:57 +000025787rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25788
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025789{ $as_echo "$as_me:$LINENO: checking for resize_term" >&5
25790$as_echo_n "checking for resize_term... " >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025791cat >conftest.$ac_ext <<_ACEOF
25792/* confdefs.h. */
25793_ACEOF
25794cat confdefs.h >>conftest.$ac_ext
25795cat >>conftest.$ac_ext <<_ACEOF
25796/* end confdefs.h. */
25797#include <curses.h>
25798int
25799main ()
25800{
25801void *x=resize_term
25802 ;
25803 return 0;
25804}
25805_ACEOF
25806rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025807if { (ac_try="$ac_compile"
25808case "(($ac_try" in
25809 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25810 *) ac_try_echo=$ac_try;;
25811esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025812eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25813$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025814 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025815 ac_status=$?
25816 grep -v '^ *+' conftest.er1 >conftest.err
25817 rm -f conftest.er1
25818 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025819 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025820 (exit $ac_status); } && {
25821 test -z "$ac_c_werror_flag" ||
25822 test ! -s conftest.err
25823 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025824
25825cat >>confdefs.h <<\_ACEOF
25826#define HAVE_CURSES_RESIZE_TERM 1
25827_ACEOF
25828
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025829 { $as_echo "$as_me:$LINENO: result: yes" >&5
25830$as_echo "yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025831else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025832 $as_echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025833sed 's/^/| /' conftest.$ac_ext >&5
25834
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025835 { $as_echo "$as_me:$LINENO: result: no" >&5
25836$as_echo "no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025837
25838fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025839
Martin v. Löwiseba40652007-08-30 20:10:57 +000025840rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25841
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025842{ $as_echo "$as_me:$LINENO: checking for resizeterm" >&5
25843$as_echo_n "checking for resizeterm... " >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025844cat >conftest.$ac_ext <<_ACEOF
25845/* confdefs.h. */
25846_ACEOF
25847cat confdefs.h >>conftest.$ac_ext
25848cat >>conftest.$ac_ext <<_ACEOF
25849/* end confdefs.h. */
25850#include <curses.h>
25851int
25852main ()
25853{
25854void *x=resizeterm
25855 ;
25856 return 0;
25857}
25858_ACEOF
25859rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025860if { (ac_try="$ac_compile"
25861case "(($ac_try" in
25862 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25863 *) ac_try_echo=$ac_try;;
25864esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025865eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25866$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025867 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025868 ac_status=$?
25869 grep -v '^ *+' conftest.er1 >conftest.err
25870 rm -f conftest.er1
25871 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025872 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025873 (exit $ac_status); } && {
25874 test -z "$ac_c_werror_flag" ||
25875 test ! -s conftest.err
25876 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025877
25878cat >>confdefs.h <<\_ACEOF
25879#define HAVE_CURSES_RESIZETERM 1
25880_ACEOF
25881
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025882 { $as_echo "$as_me:$LINENO: result: yes" >&5
25883$as_echo "yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025884else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025885 $as_echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025886sed 's/^/| /' conftest.$ac_ext >&5
25887
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025888 { $as_echo "$as_me:$LINENO: result: no" >&5
25889$as_echo "no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025890
25891fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025892
Martin v. Löwiseba40652007-08-30 20:10:57 +000025893rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25894
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025895{ $as_echo "$as_me:$LINENO: checking for /dev/ptmx" >&5
25896$as_echo_n "checking for /dev/ptmx... " >&6; }
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025897
25898if test -r /dev/ptmx
25899then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025900 { $as_echo "$as_me:$LINENO: result: yes" >&5
25901$as_echo "yes" >&6; }
Martin v. Löwis24a880b2002-12-31 12:55:15 +000025902
25903cat >>confdefs.h <<\_ACEOF
25904#define HAVE_DEV_PTMX 1
25905_ACEOF
25906
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025907else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025908 { $as_echo "$as_me:$LINENO: result: no" >&5
25909$as_echo "no" >&6; }
Martin v. Löwis24a880b2002-12-31 12:55:15 +000025910fi
25911
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025912{ $as_echo "$as_me:$LINENO: checking for /dev/ptc" >&5
25913$as_echo_n "checking for /dev/ptc... " >&6; }
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025914
25915if test -r /dev/ptc
25916then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025917 { $as_echo "$as_me:$LINENO: result: yes" >&5
25918$as_echo "yes" >&6; }
Neal Norwitz865400f2003-03-21 01:42:58 +000025919
25920cat >>confdefs.h <<\_ACEOF
25921#define HAVE_DEV_PTC 1
25922_ACEOF
25923
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025924else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025925 { $as_echo "$as_me:$LINENO: result: no" >&5
25926$as_echo "no" >&6; }
Neal Norwitz865400f2003-03-21 01:42:58 +000025927fi
25928
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025929{ $as_echo "$as_me:$LINENO: checking for %zd printf() format support" >&5
25930$as_echo_n "checking for %zd printf() format support... " >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000025931if test "$cross_compiling" = yes; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025932 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25933$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25934{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Brett Cannon09d12362006-05-11 05:11:33 +000025935See \`config.log' for more details." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025936$as_echo "$as_me: error: cannot run test program while cross compiling
Brett Cannon09d12362006-05-11 05:11:33 +000025937See \`config.log' for more details." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025938 { (exit 1); exit 1; }; }; }
Brett Cannon09d12362006-05-11 05:11:33 +000025939else
25940 cat >conftest.$ac_ext <<_ACEOF
25941/* confdefs.h. */
25942_ACEOF
25943cat confdefs.h >>conftest.$ac_ext
25944cat >>conftest.$ac_ext <<_ACEOF
25945/* end confdefs.h. */
25946#include <stdio.h>
25947#include <stddef.h>
25948#include <string.h>
25949
Christian Heimesdb3d6cb2007-12-16 21:39:43 +000025950#ifdef HAVE_SYS_TYPES_H
25951#include <sys/types.h>
25952#endif
Neal Norwitz4a8fbdb2006-09-22 08:16:26 +000025953
25954#ifdef HAVE_SSIZE_T
25955typedef ssize_t Py_ssize_t;
25956#elif SIZEOF_VOID_P == SIZEOF_LONG
25957typedef long Py_ssize_t;
25958#else
25959typedef int Py_ssize_t;
25960#endif
Brett Cannon09d12362006-05-11 05:11:33 +000025961
Christian Heimesdb3d6cb2007-12-16 21:39:43 +000025962int main()
25963{
25964 char buffer[256];
25965
Brett Cannon09d12362006-05-11 05:11:33 +000025966 if(sprintf(buffer, "%zd", (size_t)123) < 0)
25967 return 1;
25968
Neal Norwitz4a8fbdb2006-09-22 08:16:26 +000025969 if (strcmp(buffer, "123"))
25970 return 1;
25971
25972 if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
25973 return 1;
25974
25975 if (strcmp(buffer, "-123"))
Brett Cannon09d12362006-05-11 05:11:33 +000025976 return 1;
25977
25978 return 0;
25979}
25980_ACEOF
25981rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025982if { (ac_try="$ac_link"
25983case "(($ac_try" in
25984 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25985 *) ac_try_echo=$ac_try;;
25986esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025987eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25988$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025989 (eval "$ac_link") 2>&5
Brett Cannon09d12362006-05-11 05:11:33 +000025990 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025991 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000025992 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025993 { (case "(($ac_try" in
25994 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25995 *) ac_try_echo=$ac_try;;
25996esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025997eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25998$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025999 (eval "$ac_try") 2>&5
Brett Cannon09d12362006-05-11 05:11:33 +000026000 ac_status=$?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026001 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000026002 (exit $ac_status); }; }; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026003 { $as_echo "$as_me:$LINENO: result: yes" >&5
26004$as_echo "yes" >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000026005
26006cat >>confdefs.h <<\_ACEOF
26007#define PY_FORMAT_SIZE_T "z"
26008_ACEOF
26009
26010else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026011 $as_echo "$as_me: program exited with status $ac_status" >&5
26012$as_echo "$as_me: failed program was:" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000026013sed 's/^/| /' conftest.$ac_ext >&5
26014
26015( exit $ac_status )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026016{ $as_echo "$as_me:$LINENO: result: no" >&5
26017$as_echo "no" >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000026018fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026019rm -rf conftest.dSYM
Martin v. Löwiseba40652007-08-30 20:10:57 +000026020rm -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 +000026021fi
26022
Martin v. Löwiseba40652007-08-30 20:10:57 +000026023
26024
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026025{ $as_echo "$as_me:$LINENO: checking for socklen_t" >&5
26026$as_echo_n "checking for socklen_t... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000026027if test "${ac_cv_type_socklen_t+set}" = set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026028 $as_echo_n "(cached) " >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000026029else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026030 ac_cv_type_socklen_t=no
26031cat >conftest.$ac_ext <<_ACEOF
26032/* confdefs.h. */
26033_ACEOF
26034cat confdefs.h >>conftest.$ac_ext
26035cat >>conftest.$ac_ext <<_ACEOF
26036/* end confdefs.h. */
26037
26038#ifdef HAVE_SYS_TYPES_H
26039#include <sys/types.h>
26040#endif
26041#ifdef HAVE_SYS_SOCKET_H
26042#include <sys/socket.h>
26043#endif
26044
26045
26046int
26047main ()
26048{
26049if (sizeof (socklen_t))
26050 return 0;
26051 ;
26052 return 0;
26053}
26054_ACEOF
26055rm -f conftest.$ac_objext
26056if { (ac_try="$ac_compile"
26057case "(($ac_try" in
26058 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26059 *) ac_try_echo=$ac_try;;
26060esac
26061eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26062$as_echo "$ac_try_echo") >&5
26063 (eval "$ac_compile") 2>conftest.er1
26064 ac_status=$?
26065 grep -v '^ *+' conftest.er1 >conftest.err
26066 rm -f conftest.er1
26067 cat conftest.err >&5
26068 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26069 (exit $ac_status); } && {
26070 test -z "$ac_c_werror_flag" ||
26071 test ! -s conftest.err
26072 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000026073 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000026074/* confdefs.h. */
26075_ACEOF
26076cat confdefs.h >>conftest.$ac_ext
26077cat >>conftest.$ac_ext <<_ACEOF
26078/* end confdefs.h. */
Martin v. Löwis01c04012002-11-11 14:58:44 +000026079
26080#ifdef HAVE_SYS_TYPES_H
26081#include <sys/types.h>
26082#endif
26083#ifdef HAVE_SYS_SOCKET_H
26084#include <sys/socket.h>
26085#endif
26086
26087
Martin v. Löwis11437992002-04-12 09:54:03 +000026088int
26089main ()
26090{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026091if (sizeof ((socklen_t)))
26092 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000026093 ;
26094 return 0;
26095}
26096_ACEOF
26097rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000026098if { (ac_try="$ac_compile"
26099case "(($ac_try" in
26100 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26101 *) ac_try_echo=$ac_try;;
26102esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026103eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26104$as_echo "$ac_try_echo") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000026105 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000026106 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000026107 grep -v '^ *+' conftest.er1 >conftest.err
26108 rm -f conftest.er1
26109 cat conftest.err >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026110 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000026111 (exit $ac_status); } && {
26112 test -z "$ac_c_werror_flag" ||
26113 test ! -s conftest.err
26114 } && test -s conftest.$ac_objext; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026115 :
Guido van Rossum95713eb2000-05-18 20:53:31 +000026116else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026117 $as_echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000026118sed 's/^/| /' conftest.$ac_ext >&5
26119
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026120 ac_cv_type_socklen_t=yes
26121fi
26122
26123rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26124else
26125 $as_echo "$as_me: failed program was:" >&5
26126sed 's/^/| /' conftest.$ac_ext >&5
26127
26128
Guido van Rossum95713eb2000-05-18 20:53:31 +000026129fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000026130
26131rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000026132fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026133{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
26134$as_echo "$ac_cv_type_socklen_t" >&6; }
26135if test "x$ac_cv_type_socklen_t" = x""yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000026136 :
26137else
Guido van Rossum95713eb2000-05-18 20:53:31 +000026138
Martin v. Löwis01c04012002-11-11 14:58:44 +000026139cat >>confdefs.h <<\_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000026140#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000026141_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000026142
26143fi
26144
Michael W. Hudson54241132001-12-07 15:38:26 +000026145
Michael W. Hudson54241132001-12-07 15:38:26 +000026146
26147
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000026148for h in `(cd $srcdir;echo Python/thread_*.h)`
26149do
26150 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
26151done
26152
Michael W. Hudson54241132001-12-07 15:38:26 +000026153
Neal Norwitzd24499d2005-12-18 21:36:39 +000026154SRCDIRS="Parser Grammar Objects Python Modules Mac"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026155{ $as_echo "$as_me:$LINENO: checking for build directories" >&5
26156$as_echo_n "checking for build directories... " >&6; }
Neil Schemenauerd32c2492001-01-24 17:25:28 +000026157for dir in $SRCDIRS; do
26158 if test ! -d $dir; then
26159 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000026160 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000026161done
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026162{ $as_echo "$as_me:$LINENO: result: done" >&5
26163$as_echo "done" >&6; }
Fred Drake036144d2000-10-26 17:09:35 +000026164
Guido van Rossum627b2d71993-12-24 10:39:16 +000026165# generate output files
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026166ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config Misc/python.pc"
Martin v. Löwis88afe662002-10-26 13:47:44 +000026167
Martin v. Löwis11437992002-04-12 09:54:03 +000026168cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026169# This file is a shell script that caches the results of configure
26170# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000026171# scripts and configure runs, see configure's option --config-cache.
26172# It is not useful on other systems. If it contains results you don't
26173# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026174#
Martin v. Löwis11437992002-04-12 09:54:03 +000026175# config.status only pays attention to the cache file if you give it
26176# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026177#
Skip Montanaro6dead952003-09-25 14:50:04 +000026178# `ac_cv_env_foo' variables (set or unset) will be overridden when
Martin v. Löwis11437992002-04-12 09:54:03 +000026179# loading this file, other *unset* `ac_cv_foo' will be assigned the
26180# following values.
26181
26182_ACEOF
26183
Guido van Rossumf78abae1997-01-21 22:02:36 +000026184# The following way of writing the cache mishandles newlines in values,
26185# but we know of no workaround that is simple, portable, and efficient.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026186# So, we kill variables containing newlines.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000026187# Ultrix sh set writes to stderr and can't be redirected directly,
26188# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026189(
26190 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
26191 eval ac_val=\$$ac_var
26192 case $ac_val in #(
26193 *${as_nl}*)
26194 case $ac_var in #(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026195 *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
26196$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026197 esac
26198 case $ac_var in #(
26199 _ | IFS | as_nl) ;; #(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026200 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
Martin v. Löwiseba40652007-08-30 20:10:57 +000026201 *) $as_unset $ac_var ;;
26202 esac ;;
26203 esac
26204 done
26205
Martin v. Löwis11437992002-04-12 09:54:03 +000026206 (set) 2>&1 |
Martin v. Löwiseba40652007-08-30 20:10:57 +000026207 case $as_nl`(ac_space=' '; set) 2>&1` in #(
26208 *${as_nl}ac_space=\ *)
Martin v. Löwis11437992002-04-12 09:54:03 +000026209 # `set' does not quote correctly, so add quotes (double-quote
26210 # substitution turns \\\\ into \\, and sed turns \\ into \).
26211 sed -n \
Skip Montanarof0d5f792004-08-15 14:08:23 +000026212 "s/'/'\\\\''/g;
26213 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
Martin v. Löwiseba40652007-08-30 20:10:57 +000026214 ;; #(
Martin v. Löwis11437992002-04-12 09:54:03 +000026215 *)
26216 # `set' quotes correctly as required by POSIX, so do not add quotes.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026217 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Martin v. Löwis11437992002-04-12 09:54:03 +000026218 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026219 esac |
26220 sort
26221) |
Martin v. Löwis11437992002-04-12 09:54:03 +000026222 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +000026223 /^ac_cv_env_/b end
Martin v. Löwis11437992002-04-12 09:54:03 +000026224 t clear
Martin v. Löwiseba40652007-08-30 20:10:57 +000026225 :clear
Martin v. Löwis11437992002-04-12 09:54:03 +000026226 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26227 t end
Martin v. Löwiseba40652007-08-30 20:10:57 +000026228 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26229 :end' >>confcache
26230if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
26231 if test -w "$cache_file"; then
26232 test "x$cache_file" != "x/dev/null" &&
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026233 { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
26234$as_echo "$as_me: updating cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +000026235 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000026236 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026237 { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
26238$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000026239 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026240fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000026241rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000026242
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026243test "x$prefix" = xNONE && prefix=$ac_default_prefix
26244# Let make expand exec_prefix.
26245test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000026246
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026247DEFS=-DHAVE_CONFIG_H
26248
Skip Montanaro6dead952003-09-25 14:50:04 +000026249ac_libobjs=
26250ac_ltlibobjs=
26251for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
26252 # 1. Remove the extension, and $U if already installed.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026253 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026254 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
Martin v. Löwiseba40652007-08-30 20:10:57 +000026255 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
26256 # will be set to the directory where LIBOBJS objects are built.
26257 ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
26258 ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
Skip Montanaro6dead952003-09-25 14:50:04 +000026259done
26260LIBOBJS=$ac_libobjs
26261
26262LTLIBOBJS=$ac_ltlibobjs
26263
26264
Martin v. Löwis11437992002-04-12 09:54:03 +000026265
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026266
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026267: ${CONFIG_STATUS=./config.status}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026268ac_write_fail=0
Martin v. Löwis11437992002-04-12 09:54:03 +000026269ac_clean_files_save=$ac_clean_files
26270ac_clean_files="$ac_clean_files $CONFIG_STATUS"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026271{ $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
26272$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
26273cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026274#! $SHELL
26275# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000026276# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026277# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000026278# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000026279
Martin v. Löwis11437992002-04-12 09:54:03 +000026280debug=false
Skip Montanaro6dead952003-09-25 14:50:04 +000026281ac_cs_recheck=false
26282ac_cs_silent=false
Martin v. Löwis11437992002-04-12 09:54:03 +000026283SHELL=\${CONFIG_SHELL-$SHELL}
26284_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000026285
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026286cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026287## --------------------- ##
26288## M4sh Initialization. ##
26289## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000026290
Martin v. Löwiseba40652007-08-30 20:10:57 +000026291# Be more Bourne compatible
26292DUALCASE=1; export DUALCASE # for MKS sh
Martin v. Löwis11437992002-04-12 09:54:03 +000026293if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
26294 emulate sh
26295 NULLCMD=:
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026296 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
Skip Montanaro6dead952003-09-25 14:50:04 +000026297 # is contrary to our usage. Disable this feature.
26298 alias -g '${1+"$@"}'='"$@"'
Martin v. Löwiseba40652007-08-30 20:10:57 +000026299 setopt NO_GLOB_SUBST
Skip Montanaro89e975f2007-08-22 19:05:21 +000026300else
Martin v. Löwiseba40652007-08-30 20:10:57 +000026301 case `(set -o) 2>/dev/null` in
26302 *posix*) set -o posix ;;
26303esac
26304
Martin v. Löwis11437992002-04-12 09:54:03 +000026305fi
Michael W. Hudson54241132001-12-07 15:38:26 +000026306
Skip Montanaro6dead952003-09-25 14:50:04 +000026307
Martin v. Löwis11437992002-04-12 09:54:03 +000026308
26309
Martin v. Löwiseba40652007-08-30 20:10:57 +000026310# PATH needs CR
Martin v. Löwis11437992002-04-12 09:54:03 +000026311# Avoid depending upon Character Ranges.
26312as_cr_letters='abcdefghijklmnopqrstuvwxyz'
26313as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
26314as_cr_Letters=$as_cr_letters$as_cr_LETTERS
26315as_cr_digits='0123456789'
26316as_cr_alnum=$as_cr_Letters$as_cr_digits
26317
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026318as_nl='
26319'
26320export as_nl
26321# Printing a long string crashes Solaris 7 /usr/bin/printf.
26322as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
26323as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
26324as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
26325if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
26326 as_echo='printf %s\n'
26327 as_echo_n='printf %s'
26328else
26329 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
26330 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
26331 as_echo_n='/usr/ucb/echo -n'
26332 else
26333 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
26334 as_echo_n_body='eval
26335 arg=$1;
26336 case $arg in
26337 *"$as_nl"*)
26338 expr "X$arg" : "X\\(.*\\)$as_nl";
26339 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
26340 esac;
26341 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
26342 '
26343 export as_echo_n_body
26344 as_echo_n='sh -c $as_echo_n_body as_echo'
26345 fi
26346 export as_echo_body
26347 as_echo='sh -c $as_echo_body as_echo'
26348fi
26349
Martin v. Löwis11437992002-04-12 09:54:03 +000026350# The user is always right.
26351if test "${PATH_SEPARATOR+set}" != set; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026352 PATH_SEPARATOR=:
26353 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
26354 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
26355 PATH_SEPARATOR=';'
26356 }
Martin v. Löwis11437992002-04-12 09:54:03 +000026357fi
26358
Martin v. Löwiseba40652007-08-30 20:10:57 +000026359# Support unset when possible.
26360if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
26361 as_unset=unset
26362else
26363 as_unset=false
26364fi
Martin v. Löwis11437992002-04-12 09:54:03 +000026365
Martin v. Löwiseba40652007-08-30 20:10:57 +000026366
26367# IFS
26368# We need space, tab and new line, in precisely that order. Quoting is
26369# there to prevent editors from complaining about space-tab.
26370# (If _AS_PATH_WALK were called with IFS unset, it would disable word
26371# splitting by setting IFS to empty value.)
Martin v. Löwiseba40652007-08-30 20:10:57 +000026372IFS=" "" $as_nl"
26373
26374# Find who we are. Look in the path if we contain no directory separator.
26375case $0 in
26376 *[\\/]* ) as_myself=$0 ;;
26377 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +000026378for as_dir in $PATH
26379do
26380 IFS=$as_save_IFS
26381 test -z "$as_dir" && as_dir=.
26382 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
26383done
Martin v. Löwiseba40652007-08-30 20:10:57 +000026384IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +000026385
Martin v. Löwiseba40652007-08-30 20:10:57 +000026386 ;;
26387esac
26388# We did not find ourselves, most probably we were run as `sh COMMAND'
26389# in which case we are not to be found in the path.
26390if test "x$as_myself" = x; then
26391 as_myself=$0
26392fi
26393if test ! -f "$as_myself"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026394 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +000026395 { (exit 1); exit 1; }
26396fi
26397
26398# Work around bugs in pre-3.0 UWIN ksh.
26399for as_var in ENV MAIL MAILPATH
26400do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
26401done
26402PS1='$ '
26403PS2='> '
26404PS4='+ '
26405
26406# NLS nuisances.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026407LC_ALL=C
26408export LC_ALL
26409LANGUAGE=C
26410export LANGUAGE
Martin v. Löwiseba40652007-08-30 20:10:57 +000026411
26412# Required to use basename.
26413if expr a : '\(a\)' >/dev/null 2>&1 &&
26414 test "X`expr 00001 : '.*\(...\)'`" = X001; then
26415 as_expr=expr
26416else
26417 as_expr=false
26418fi
26419
26420if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
26421 as_basename=basename
26422else
26423 as_basename=false
26424fi
26425
26426
26427# Name of the executable.
26428as_me=`$as_basename -- "$0" ||
26429$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
26430 X"$0" : 'X\(//\)$' \| \
26431 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026432$as_echo X/"$0" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000026433 sed '/^.*\/\([^/][^/]*\)\/*$/{
26434 s//\1/
26435 q
26436 }
26437 /^X\/\(\/\/\)$/{
26438 s//\1/
26439 q
26440 }
26441 /^X\/\(\/\).*/{
26442 s//\1/
26443 q
26444 }
26445 s/.*/./; q'`
26446
26447# CDPATH.
26448$as_unset CDPATH
26449
26450
26451
Martin v. Löwis11437992002-04-12 09:54:03 +000026452 as_lineno_1=$LINENO
26453 as_lineno_2=$LINENO
Martin v. Löwis11437992002-04-12 09:54:03 +000026454 test "x$as_lineno_1" != "x$as_lineno_2" &&
Martin v. Löwiseba40652007-08-30 20:10:57 +000026455 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
Jack Jansendd19cf82001-12-06 22:36:17 +000026456
Martin v. Löwis11437992002-04-12 09:54:03 +000026457 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
26458 # uniformly replaced by the line number. The first 'sed' inserts a
Martin v. Löwiseba40652007-08-30 20:10:57 +000026459 # line-number line after each line using $LINENO; the second 'sed'
26460 # does the real work. The second script uses 'N' to pair each
26461 # line-number line with the line containing $LINENO, and appends
26462 # trailing '-' during substitution so that $LINENO is not a special
26463 # case at line end.
Martin v. Löwis11437992002-04-12 09:54:03 +000026464 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
Martin v. Löwiseba40652007-08-30 20:10:57 +000026465 # scripts with optimization help from Paolo Bonzini. Blame Lee
26466 # E. McMahon (1931-1989) for sed's syntax. :-)
26467 sed -n '
26468 p
26469 /[$]LINENO/=
26470 ' <$as_myself |
Martin v. Löwis11437992002-04-12 09:54:03 +000026471 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +000026472 s/[$]LINENO.*/&-/
26473 t lineno
26474 b
26475 :lineno
Martin v. Löwis11437992002-04-12 09:54:03 +000026476 N
Martin v. Löwiseba40652007-08-30 20:10:57 +000026477 :loop
26478 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
Martin v. Löwis11437992002-04-12 09:54:03 +000026479 t loop
Martin v. Löwiseba40652007-08-30 20:10:57 +000026480 s/-\n.*//
Martin v. Löwis11437992002-04-12 09:54:03 +000026481 ' >$as_me.lineno &&
Martin v. Löwiseba40652007-08-30 20:10:57 +000026482 chmod +x "$as_me.lineno" ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026483 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000026484 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000026485
Martin v. Löwis11437992002-04-12 09:54:03 +000026486 # Don't try to exec as it changes $[0], causing all sort of problems
26487 # (the dirname of $[0] is not the place where we might find the
Martin v. Löwiseba40652007-08-30 20:10:57 +000026488 # original and so on. Autoconf is especially sensitive to this).
26489 . "./$as_me.lineno"
Martin v. Löwis11437992002-04-12 09:54:03 +000026490 # Exit status is that of the last command.
26491 exit
26492}
26493
26494
Martin v. Löwiseba40652007-08-30 20:10:57 +000026495if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
26496 as_dirname=dirname
26497else
26498 as_dirname=false
26499fi
26500
26501ECHO_C= ECHO_N= ECHO_T=
26502case `echo -n x` in
26503-n*)
26504 case `echo 'x\c'` in
26505 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
26506 *) ECHO_C='\c';;
26507 esac;;
26508*)
26509 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +000026510esac
Martin v. Löwiseba40652007-08-30 20:10:57 +000026511if expr a : '\(a\)' >/dev/null 2>&1 &&
26512 test "X`expr 00001 : '.*\(...\)'`" = X001; then
Martin v. Löwis11437992002-04-12 09:54:03 +000026513 as_expr=expr
26514else
26515 as_expr=false
26516fi
26517
26518rm -f conf$$ conf$$.exe conf$$.file
Martin v. Löwiseba40652007-08-30 20:10:57 +000026519if test -d conf$$.dir; then
26520 rm -f conf$$.dir/conf$$.file
26521else
26522 rm -f conf$$.dir
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026523 mkdir conf$$.dir 2>/dev/null
Martin v. Löwiseba40652007-08-30 20:10:57 +000026524fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026525if (echo >conf$$.file) 2>/dev/null; then
26526 if ln -s conf$$.file conf$$ 2>/dev/null; then
26527 as_ln_s='ln -s'
26528 # ... but there are two gotchas:
26529 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
26530 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
26531 # In both cases, we have to default to `cp -p'.
26532 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
26533 as_ln_s='cp -p'
26534 elif ln conf$$.file conf$$ 2>/dev/null; then
26535 as_ln_s=ln
26536 else
Martin v. Löwis11437992002-04-12 09:54:03 +000026537 as_ln_s='cp -p'
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026538 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000026539else
26540 as_ln_s='cp -p'
26541fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000026542rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
26543rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +000026544
Skip Montanaro6dead952003-09-25 14:50:04 +000026545if mkdir -p . 2>/dev/null; then
26546 as_mkdir_p=:
26547else
Skip Montanarof0d5f792004-08-15 14:08:23 +000026548 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +000026549 as_mkdir_p=false
26550fi
26551
Martin v. Löwiseba40652007-08-30 20:10:57 +000026552if test -x / >/dev/null 2>&1; then
26553 as_test_x='test -x'
26554else
26555 if ls -dL / >/dev/null 2>&1; then
26556 as_ls_L_option=L
26557 else
26558 as_ls_L_option=
26559 fi
26560 as_test_x='
26561 eval sh -c '\''
26562 if test -d "$1"; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026563 test -d "$1/.";
Martin v. Löwiseba40652007-08-30 20:10:57 +000026564 else
26565 case $1 in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026566 -*)set "./$1";;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026567 esac;
26568 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
26569 ???[sx]*):;;*)false;;esac;fi
26570 '\'' sh
26571 '
26572fi
26573as_executable_p=$as_test_x
Martin v. Löwis11437992002-04-12 09:54:03 +000026574
26575# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000026576as_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 +000026577
26578# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000026579as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +000026580
26581
Martin v. Löwis11437992002-04-12 09:54:03 +000026582exec 6>&1
26583
Martin v. Löwiseba40652007-08-30 20:10:57 +000026584# Save the log message, to keep $[0] and so on meaningful, and to
Martin v. Löwis11437992002-04-12 09:54:03 +000026585# report actual input values of CONFIG_FILES etc. instead of their
Martin v. Löwiseba40652007-08-30 20:10:57 +000026586# values after options handling.
26587ac_log="
Martin v. Löwis174440b2008-10-03 08:59:41 +000026588This file was extended by python $as_me 2.7, which was
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026589generated by GNU Autoconf 2.63. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +000026590
26591 CONFIG_FILES = $CONFIG_FILES
26592 CONFIG_HEADERS = $CONFIG_HEADERS
26593 CONFIG_LINKS = $CONFIG_LINKS
26594 CONFIG_COMMANDS = $CONFIG_COMMANDS
26595 $ $0 $@
26596
Martin v. Löwiseba40652007-08-30 20:10:57 +000026597on `(hostname || uname -n) 2>/dev/null | sed 1q`
26598"
26599
Martin v. Löwis11437992002-04-12 09:54:03 +000026600_ACEOF
26601
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026602case $ac_config_files in *"
26603"*) set x $ac_config_files; shift; ac_config_files=$*;;
26604esac
26605
26606case $ac_config_headers in *"
26607"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
26608esac
26609
26610
26611cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026612# Files that config.status was made for.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026613config_files="`echo $ac_config_files`"
26614config_headers="`echo $ac_config_headers`"
Martin v. Löwis11437992002-04-12 09:54:03 +000026615
Martin v. Löwiseba40652007-08-30 20:10:57 +000026616_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000026617
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026618cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026619ac_cs_usage="\
26620\`$as_me' instantiates files from templates according to the
26621current configuration.
26622
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026623Usage: $0 [OPTION]... [FILE]...
Martin v. Löwis11437992002-04-12 09:54:03 +000026624
26625 -h, --help print this help, then exit
Martin v. Löwiseba40652007-08-30 20:10:57 +000026626 -V, --version print version number and configuration settings, then exit
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026627 -q, --quiet, --silent
26628 do not print progress messages
Martin v. Löwis11437992002-04-12 09:54:03 +000026629 -d, --debug don't remove temporary files
26630 --recheck update $as_me by reconfiguring in the same conditions
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026631 --file=FILE[:TEMPLATE]
26632 instantiate the configuration file FILE
26633 --header=FILE[:TEMPLATE]
26634 instantiate the configuration header FILE
Martin v. Löwis11437992002-04-12 09:54:03 +000026635
26636Configuration files:
26637$config_files
26638
26639Configuration headers:
26640$config_headers
26641
26642Report bugs to <bug-autoconf@gnu.org>."
Skip Montanaro89e975f2007-08-22 19:05:21 +000026643
Martin v. Löwiseba40652007-08-30 20:10:57 +000026644_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026645cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026646ac_cs_version="\\
Martin v. Löwis174440b2008-10-03 08:59:41 +000026647python config.status 2.7
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026648configured by $0, generated by GNU Autoconf 2.63,
26649 with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
Martin v. Löwis11437992002-04-12 09:54:03 +000026650
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026651Copyright (C) 2008 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +000026652This config.status script is free software; the Free Software Foundation
26653gives unlimited permission to copy, distribute and modify it."
Martin v. Löwiseba40652007-08-30 20:10:57 +000026654
26655ac_pwd='$ac_pwd'
26656srcdir='$srcdir'
26657INSTALL='$INSTALL'
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026658test -n "\$AWK" || AWK=awk
Martin v. Löwis11437992002-04-12 09:54:03 +000026659_ACEOF
26660
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026661cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26662# The default lists apply if the user does not specify any file.
Martin v. Löwis11437992002-04-12 09:54:03 +000026663ac_need_defaults=:
26664while test $# != 0
26665do
26666 case $1 in
26667 --*=*)
Martin v. Löwiseba40652007-08-30 20:10:57 +000026668 ac_option=`expr "X$1" : 'X\([^=]*\)='`
26669 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
Skip Montanaro6dead952003-09-25 14:50:04 +000026670 ac_shift=:
Martin v. Löwis11437992002-04-12 09:54:03 +000026671 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026672 *)
Skip Montanaro6dead952003-09-25 14:50:04 +000026673 ac_option=$1
26674 ac_optarg=$2
26675 ac_shift=shift
26676 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026677 esac
26678
Skip Montanaro6dead952003-09-25 14:50:04 +000026679 case $ac_option in
Martin v. Löwis11437992002-04-12 09:54:03 +000026680 # Handling of the options.
Skip Montanaro6dead952003-09-25 14:50:04 +000026681 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
26682 ac_cs_recheck=: ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026683 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026684 $as_echo "$ac_cs_version"; exit ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026685 --debug | --debu | --deb | --de | --d | -d )
Martin v. Löwis11437992002-04-12 09:54:03 +000026686 debug=: ;;
26687 --file | --fil | --fi | --f )
Skip Montanaro6dead952003-09-25 14:50:04 +000026688 $ac_shift
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026689 case $ac_optarg in
26690 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26691 esac
26692 CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
Martin v. Löwis11437992002-04-12 09:54:03 +000026693 ac_need_defaults=false;;
26694 --header | --heade | --head | --hea )
Skip Montanaro6dead952003-09-25 14:50:04 +000026695 $ac_shift
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026696 case $ac_optarg in
26697 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
26698 esac
26699 CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
Martin v. Löwis11437992002-04-12 09:54:03 +000026700 ac_need_defaults=false;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026701 --he | --h)
26702 # Conflict between --help and --header
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026703 { $as_echo "$as_me: error: ambiguous option: $1
Martin v. Löwiseba40652007-08-30 20:10:57 +000026704Try \`$0 --help' for more information." >&2
26705 { (exit 1); exit 1; }; };;
26706 --help | --hel | -h )
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026707 $as_echo "$ac_cs_usage"; exit ;;
Skip Montanaro6dead952003-09-25 14:50:04 +000026708 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
26709 | -silent | --silent | --silen | --sile | --sil | --si | --s)
26710 ac_cs_silent=: ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026711
26712 # This is an error.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026713 -*) { $as_echo "$as_me: error: unrecognized option: $1
Martin v. Löwiseba40652007-08-30 20:10:57 +000026714Try \`$0 --help' for more information." >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000026715 { (exit 1); exit 1; }; } ;;
26716
Martin v. Löwiseba40652007-08-30 20:10:57 +000026717 *) ac_config_targets="$ac_config_targets $1"
26718 ac_need_defaults=false ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026719
26720 esac
26721 shift
26722done
26723
Skip Montanaro6dead952003-09-25 14:50:04 +000026724ac_configure_extra_args=
26725
26726if $ac_cs_silent; then
26727 exec 6>/dev/null
26728 ac_configure_extra_args="$ac_configure_extra_args --silent"
26729fi
26730
26731_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026732cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Skip Montanaro6dead952003-09-25 14:50:04 +000026733if \$ac_cs_recheck; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026734 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
26735 shift
26736 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
26737 CONFIG_SHELL='$SHELL'
Martin v. Löwiseba40652007-08-30 20:10:57 +000026738 export CONFIG_SHELL
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026739 exec "\$@"
Skip Montanaro6dead952003-09-25 14:50:04 +000026740fi
26741
Martin v. Löwis11437992002-04-12 09:54:03 +000026742_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026743cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwiseba40652007-08-30 20:10:57 +000026744exec 5>>config.log
26745{
26746 echo
26747 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
26748## Running $as_me. ##
26749_ASBOX
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026750 $as_echo "$ac_log"
Martin v. Löwiseba40652007-08-30 20:10:57 +000026751} >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000026752
Martin v. Löwiseba40652007-08-30 20:10:57 +000026753_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026754cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwiseba40652007-08-30 20:10:57 +000026755_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000026756
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026757cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwiseba40652007-08-30 20:10:57 +000026758
26759# Handling of arguments.
Martin v. Löwis11437992002-04-12 09:54:03 +000026760for ac_config_target in $ac_config_targets
26761do
Martin v. Löwiseba40652007-08-30 20:10:57 +000026762 case $ac_config_target in
26763 "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
26764 "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;;
26765 "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;;
26766 "Mac/IDLE/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/IDLE/Makefile" ;;
Ronald Oussoren580c7fe2008-05-02 19:45:11 +000026767 "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;;
26768 "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026769 "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
26770 "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026771 "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026772
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026773 *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
26774$as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000026775 { (exit 1); exit 1; }; };;
26776 esac
26777done
26778
Martin v. Löwiseba40652007-08-30 20:10:57 +000026779
Martin v. Löwis11437992002-04-12 09:54:03 +000026780# If the user did not use the arguments to specify the items to instantiate,
26781# then the envvar interface is used. Set only those that are not.
26782# We use the long form for the default assignment because of an extremely
26783# bizarre bug on SunOS 4.1.3.
26784if $ac_need_defaults; then
26785 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
26786 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
26787fi
26788
Skip Montanaro6dead952003-09-25 14:50:04 +000026789# Have a temporary directory for convenience. Make it in the build tree
Martin v. Löwiseba40652007-08-30 20:10:57 +000026790# simply because there is no reason against having it here, and in addition,
Skip Montanaro6dead952003-09-25 14:50:04 +000026791# creating and moving files from /tmp can sometimes cause problems.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026792# Hook for its removal unless debugging.
26793# Note that there is a small window in which the directory will not be cleaned:
26794# after its creation but before its name has been assigned to `$tmp'.
Martin v. Löwis11437992002-04-12 09:54:03 +000026795$debug ||
26796{
Martin v. Löwiseba40652007-08-30 20:10:57 +000026797 tmp=
26798 trap 'exit_status=$?
26799 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
26800' 0
Martin v. Löwis11437992002-04-12 09:54:03 +000026801 trap '{ (exit 1); exit 1; }' 1 2 13 15
26802}
Martin v. Löwis11437992002-04-12 09:54:03 +000026803# Create a (secure) tmp directory for tmp files.
Skip Montanaro6dead952003-09-25 14:50:04 +000026804
Martin v. Löwis11437992002-04-12 09:54:03 +000026805{
Martin v. Löwiseba40652007-08-30 20:10:57 +000026806 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
Martin v. Löwis11437992002-04-12 09:54:03 +000026807 test -n "$tmp" && test -d "$tmp"
26808} ||
26809{
Martin v. Löwiseba40652007-08-30 20:10:57 +000026810 tmp=./conf$$-$RANDOM
26811 (umask 077 && mkdir "$tmp")
Martin v. Löwis11437992002-04-12 09:54:03 +000026812} ||
26813{
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026814 $as_echo "$as_me: cannot create a temporary directory in ." >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000026815 { (exit 1); exit 1; }
26816}
26817
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026818# Set up the scripts for CONFIG_FILES section.
26819# No need to generate them if there are no CONFIG_FILES.
26820# This happens for instance with `./config.status config.h'.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026821if test -n "$CONFIG_FILES"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000026822
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026823
26824ac_cr='
26825'
26826ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
26827if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
26828 ac_cs_awk_cr='\\r'
26829else
26830 ac_cs_awk_cr=$ac_cr
26831fi
26832
26833echo 'BEGIN {' >"$tmp/subs1.awk" &&
Martin v. Löwis11437992002-04-12 09:54:03 +000026834_ACEOF
26835
Martin v. Löwiseba40652007-08-30 20:10:57 +000026836
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026837{
26838 echo "cat >conf$$subs.awk <<_ACEOF" &&
26839 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
26840 echo "_ACEOF"
26841} >conf$$subs.sh ||
26842 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26843$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26844 { (exit 1); exit 1; }; }
26845ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
Martin v. Löwiseba40652007-08-30 20:10:57 +000026846ac_delim='%!_!# '
26847for ac_last_try in false false false false false :; do
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026848 . ./conf$$subs.sh ||
26849 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26850$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
26851 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000026852
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026853 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
26854 if test $ac_delim_n = $ac_delim_num; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000026855 break
26856 elif $ac_last_try; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026857 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26858$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026859 { (exit 1); exit 1; }; }
26860 else
26861 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
Martin v. Löwis11437992002-04-12 09:54:03 +000026862 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000026863done
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026864rm -f conf$$subs.sh
Martin v. Löwiseba40652007-08-30 20:10:57 +000026865
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026866cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26867cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
Martin v. Löwiseba40652007-08-30 20:10:57 +000026868_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026869sed -n '
26870h
26871s/^/S["/; s/!.*/"]=/
26872p
26873g
26874s/^[^!]*!//
26875:repl
26876t repl
26877s/'"$ac_delim"'$//
26878t delim
26879:nl
26880h
26881s/\(.\{148\}\).*/\1/
26882t more1
26883s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
26884p
26885n
26886b repl
26887:more1
26888s/["\\]/\\&/g; s/^/"/; s/$/"\\/
26889p
26890g
26891s/.\{148\}//
26892t nl
26893:delim
26894h
26895s/\(.\{148\}\).*/\1/
26896t more2
26897s/["\\]/\\&/g; s/^/"/; s/$/"/
26898p
26899b
26900:more2
26901s/["\\]/\\&/g; s/^/"/; s/$/"\\/
26902p
26903g
26904s/.\{148\}//
26905t delim
26906' <conf$$subs.awk | sed '
26907/^[^""]/{
26908 N
26909 s/\n//
26910}
26911' >>$CONFIG_STATUS || ac_write_fail=1
26912rm -f conf$$subs.awk
26913cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
26914_ACAWK
26915cat >>"\$tmp/subs1.awk" <<_ACAWK &&
26916 for (key in S) S_is_set[key] = 1
26917 FS = ""
26918
26919}
26920{
26921 line = $ 0
26922 nfields = split(line, field, "@")
26923 substed = 0
26924 len = length(field[1])
26925 for (i = 2; i < nfields; i++) {
26926 key = field[i]
26927 keylen = length(key)
26928 if (S_is_set[key]) {
26929 value = S[key]
26930 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
26931 len += length(value) + length(field[++i])
26932 substed = 1
26933 } else
26934 len += 1 + keylen
26935 }
26936
26937 print line
26938}
26939
26940_ACAWK
Martin v. Löwiseba40652007-08-30 20:10:57 +000026941_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026942cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
26943if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
26944 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
26945else
26946 cat
26947fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
26948 || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
26949$as_echo "$as_me: error: could not setup config files machinery" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026950 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000026951_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026952
26953# VPATH may cause trouble with some makes, so we remove $(srcdir),
26954# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
26955# trailing colons and then remove the whole line if VPATH becomes empty
26956# (actually we leave an empty line to preserve line numbers).
26957if test "x$srcdir" = x.; then
26958 ac_vpsub='/^[ ]*VPATH[ ]*=/{
26959s/:*\$(srcdir):*/:/
26960s/:*\${srcdir}:*/:/
26961s/:*@srcdir@:*/:/
26962s/^\([^=]*=[ ]*\):*/\1/
26963s/:*$//
26964s/^[^=]*=[ ]*$//
26965}'
26966fi
26967
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026968cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000026969fi # test -n "$CONFIG_FILES"
26970
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026971# Set up the scripts for CONFIG_HEADERS section.
26972# No need to generate them if there are no CONFIG_HEADERS.
26973# This happens for instance with `./config.status Makefile'.
26974if test -n "$CONFIG_HEADERS"; then
26975cat >"$tmp/defines.awk" <<\_ACAWK ||
26976BEGIN {
26977_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026978
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000026979# Transform confdefs.h into an awk script `defines.awk', embedded as
26980# here-document in config.status, that substitutes the proper values into
26981# config.h.in to produce config.h.
26982
26983# Create a delimiter string that does not exist in confdefs.h, to ease
26984# handling of long lines.
26985ac_delim='%!_!# '
26986for ac_last_try in false false :; do
26987 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
26988 if test -z "$ac_t"; then
26989 break
26990 elif $ac_last_try; then
26991 { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
26992$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
26993 { (exit 1); exit 1; }; }
26994 else
26995 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26996 fi
26997done
26998
26999# For the awk script, D is an array of macro values keyed by name,
27000# likewise P contains macro parameters if any. Preserve backslash
27001# newline sequences.
27002
27003ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
27004sed -n '
27005s/.\{148\}/&'"$ac_delim"'/g
27006t rset
27007:rset
27008s/^[ ]*#[ ]*define[ ][ ]*/ /
27009t def
27010d
27011:def
27012s/\\$//
27013t bsnl
27014s/["\\]/\\&/g
27015s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27016D["\1"]=" \3"/p
27017s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
27018d
27019:bsnl
27020s/["\\]/\\&/g
27021s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
27022D["\1"]=" \3\\\\\\n"\\/p
27023t cont
27024s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
27025t cont
27026d
27027:cont
27028n
27029s/.\{148\}/&'"$ac_delim"'/g
27030t clear
27031:clear
27032s/\\$//
27033t bsnlc
27034s/["\\]/\\&/g; s/^/"/; s/$/"/p
27035d
27036:bsnlc
27037s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
27038b cont
27039' <confdefs.h | sed '
27040s/'"$ac_delim"'/"\\\
27041"/g' >>$CONFIG_STATUS || ac_write_fail=1
27042
27043cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27044 for (key in D) D_is_set[key] = 1
27045 FS = ""
27046}
27047/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
27048 line = \$ 0
27049 split(line, arg, " ")
27050 if (arg[1] == "#") {
27051 defundef = arg[2]
27052 mac1 = arg[3]
27053 } else {
27054 defundef = substr(arg[1], 2)
27055 mac1 = arg[2]
27056 }
27057 split(mac1, mac2, "(") #)
27058 macro = mac2[1]
27059 prefix = substr(line, 1, index(line, defundef) - 1)
27060 if (D_is_set[macro]) {
27061 # Preserve the white space surrounding the "#".
27062 print prefix "define", macro P[macro] D[macro]
27063 next
27064 } else {
27065 # Replace #undef with comments. This is necessary, for example,
27066 # in the case of _POSIX_SOURCE, which is predefined and required
27067 # on some systems where configure will not decide to define it.
27068 if (defundef == "undef") {
27069 print "/*", prefix defundef, macro, "*/"
27070 next
27071 }
27072 }
27073}
27074{ print }
27075_ACAWK
27076_ACEOF
27077cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27078 { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
27079$as_echo "$as_me: error: could not setup config headers machinery" >&2;}
27080 { (exit 1); exit 1; }; }
27081fi # test -n "$CONFIG_HEADERS"
27082
27083
27084eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS "
27085shift
27086for ac_tag
Martin v. Löwiseba40652007-08-30 20:10:57 +000027087do
27088 case $ac_tag in
27089 :[FHLC]) ac_mode=$ac_tag; continue;;
27090 esac
27091 case $ac_mode$ac_tag in
27092 :[FHL]*:*);;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027093 :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
27094$as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000027095 { (exit 1); exit 1; }; };;
27096 :[FH]-) ac_tag=-:-;;
27097 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
27098 esac
27099 ac_save_IFS=$IFS
27100 IFS=:
27101 set x $ac_tag
27102 IFS=$ac_save_IFS
27103 shift
27104 ac_file=$1
27105 shift
27106
27107 case $ac_mode in
27108 :L) ac_source=$1;;
27109 :[FH])
27110 ac_file_inputs=
27111 for ac_f
27112 do
27113 case $ac_f in
27114 -) ac_f="$tmp/stdin";;
27115 *) # Look for the file first in the build tree, then in the source tree
27116 # (if the path is not absolute). The absolute path cannot be DOS-style,
27117 # because $ac_f cannot contain `:'.
27118 test -f "$ac_f" ||
27119 case $ac_f in
27120 [\\/$]*) false;;
27121 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
27122 esac ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027123 { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
27124$as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000027125 { (exit 1); exit 1; }; };;
27126 esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027127 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
27128 ac_file_inputs="$ac_file_inputs '$ac_f'"
Martin v. Löwiseba40652007-08-30 20:10:57 +000027129 done
27130
27131 # Let's still pretend it is `configure' which instantiates (i.e., don't
27132 # use $as_me), people would be surprised to read:
27133 # /* config.h. Generated by config.status. */
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027134 configure_input='Generated from '`
27135 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
27136 `' by configure.'
Martin v. Löwiseba40652007-08-30 20:10:57 +000027137 if test x"$ac_file" != x-; then
27138 configure_input="$ac_file. $configure_input"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027139 { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
27140$as_echo "$as_me: creating $ac_file" >&6;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000027141 fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027142 # Neutralize special characters interpreted by sed in replacement strings.
27143 case $configure_input in #(
27144 *\&* | *\|* | *\\* )
27145 ac_sed_conf_input=`$as_echo "$configure_input" |
27146 sed 's/[\\\\&|]/\\\\&/g'`;; #(
27147 *) ac_sed_conf_input=$configure_input;;
27148 esac
Martin v. Löwiseba40652007-08-30 20:10:57 +000027149
27150 case $ac_tag in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027151 *:-:* | *:-) cat >"$tmp/stdin" \
27152 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
27153$as_echo "$as_me: error: could not create $ac_file" >&2;}
27154 { (exit 1); exit 1; }; } ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000027155 esac
27156 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000027157 esac
27158
Martin v. Löwiseba40652007-08-30 20:10:57 +000027159 ac_dir=`$as_dirname -- "$ac_file" ||
Martin v. Löwis11437992002-04-12 09:54:03 +000027160$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
Skip Montanarof0d5f792004-08-15 14:08:23 +000027161 X"$ac_file" : 'X\(//\)[^/]' \| \
27162 X"$ac_file" : 'X\(//\)$' \| \
Martin v. Löwiseba40652007-08-30 20:10:57 +000027163 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027164$as_echo X"$ac_file" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000027165 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27166 s//\1/
27167 q
27168 }
27169 /^X\(\/\/\)[^/].*/{
27170 s//\1/
27171 q
27172 }
27173 /^X\(\/\/\)$/{
27174 s//\1/
27175 q
27176 }
27177 /^X\(\/\).*/{
27178 s//\1/
27179 q
27180 }
27181 s/.*/./; q'`
27182 { as_dir="$ac_dir"
27183 case $as_dir in #(
27184 -*) as_dir=./$as_dir;;
27185 esac
27186 test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
Skip Montanaro6dead952003-09-25 14:50:04 +000027187 as_dirs=
Martin v. Löwiseba40652007-08-30 20:10:57 +000027188 while :; do
27189 case $as_dir in #(
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027190 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
Martin v. Löwiseba40652007-08-30 20:10:57 +000027191 *) as_qdir=$as_dir;;
27192 esac
27193 as_dirs="'$as_qdir' $as_dirs"
27194 as_dir=`$as_dirname -- "$as_dir" ||
Skip Montanaro6dead952003-09-25 14:50:04 +000027195$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
Skip Montanarof0d5f792004-08-15 14:08:23 +000027196 X"$as_dir" : 'X\(//\)[^/]' \| \
27197 X"$as_dir" : 'X\(//\)$' \| \
Martin v. Löwiseba40652007-08-30 20:10:57 +000027198 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027199$as_echo X"$as_dir" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000027200 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
27201 s//\1/
27202 q
27203 }
27204 /^X\(\/\/\)[^/].*/{
27205 s//\1/
27206 q
27207 }
27208 /^X\(\/\/\)$/{
27209 s//\1/
27210 q
27211 }
27212 /^X\(\/\).*/{
27213 s//\1/
27214 q
27215 }
27216 s/.*/./; q'`
27217 test -d "$as_dir" && break
Skip Montanaro6dead952003-09-25 14:50:04 +000027218 done
Martin v. Löwiseba40652007-08-30 20:10:57 +000027219 test -z "$as_dirs" || eval "mkdir $as_dirs"
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027220 } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
27221$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
Skip Montanaro6dead952003-09-25 14:50:04 +000027222 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +000027223 ac_builddir=.
27224
Martin v. Löwiseba40652007-08-30 20:10:57 +000027225case "$ac_dir" in
27226.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
27227*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027228 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
Martin v. Löwiseba40652007-08-30 20:10:57 +000027229 # A ".." for each directory in $ac_dir_suffix.
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027230 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
Martin v. Löwiseba40652007-08-30 20:10:57 +000027231 case $ac_top_builddir_sub in
27232 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
27233 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
27234 esac ;;
27235esac
27236ac_abs_top_builddir=$ac_pwd
27237ac_abs_builddir=$ac_pwd$ac_dir_suffix
27238# for backward compatibility:
27239ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +000027240
27241case $srcdir in
Martin v. Löwiseba40652007-08-30 20:10:57 +000027242 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +000027243 ac_srcdir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +000027244 ac_top_srcdir=$ac_top_builddir_sub
27245 ac_abs_top_srcdir=$ac_pwd ;;
27246 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +000027247 ac_srcdir=$srcdir$ac_dir_suffix;
Martin v. Löwiseba40652007-08-30 20:10:57 +000027248 ac_top_srcdir=$srcdir
27249 ac_abs_top_srcdir=$srcdir ;;
27250 *) # Relative name.
27251 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
27252 ac_top_srcdir=$ac_top_build_prefix$srcdir
27253 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000027254esac
Martin v. Löwiseba40652007-08-30 20:10:57 +000027255ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +000027256
Martin v. Löwis11437992002-04-12 09:54:03 +000027257
Martin v. Löwiseba40652007-08-30 20:10:57 +000027258 case $ac_mode in
27259 :F)
27260 #
27261 # CONFIG_FILE
27262 #
Martin v. Löwis11437992002-04-12 09:54:03 +000027263
27264 case $INSTALL in
27265 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000027266 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000027267 esac
Brett Cannon19fab762007-06-02 03:02:29 +000027268_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000027269
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027270cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwiseba40652007-08-30 20:10:57 +000027271# If the template does not know about datarootdir, expand it.
27272# FIXME: This hack should be removed a few years after 2.60.
27273ac_datarootdir_hack=; ac_datarootdir_seen=
27274
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027275ac_sed_dataroot='
27276/datarootdir/ {
Martin v. Löwiseba40652007-08-30 20:10:57 +000027277 p
27278 q
27279}
27280/@datadir@/p
27281/@docdir@/p
27282/@infodir@/p
27283/@localedir@/p
27284/@mandir@/p
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027285'
27286case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
Martin v. Löwiseba40652007-08-30 20:10:57 +000027287*datarootdir*) ac_datarootdir_seen=yes;;
27288*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027289 { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
27290$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000027291_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027292cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwiseba40652007-08-30 20:10:57 +000027293 ac_datarootdir_hack='
27294 s&@datadir@&$datadir&g
27295 s&@docdir@&$docdir&g
27296 s&@infodir@&$infodir&g
27297 s&@localedir@&$localedir&g
27298 s&@mandir@&$mandir&g
27299 s&\\\${datarootdir}&$datarootdir&g' ;;
27300esac
27301_ACEOF
27302
27303# Neutralize VPATH when `$srcdir' = `.'.
27304# Shell code in configure.ac might set extrasub.
27305# FIXME: do we really want to maintain this feature?
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027306cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27307ac_sed_extra="$ac_vpsub
Martin v. Löwis11437992002-04-12 09:54:03 +000027308$extrasub
27309_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027310cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000027311:t
27312/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027313s|@configure_input@|$ac_sed_conf_input|;t t
Martin v. Löwiseba40652007-08-30 20:10:57 +000027314s&@top_builddir@&$ac_top_builddir_sub&;t t
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027315s&@top_build_prefix@&$ac_top_build_prefix&;t t
Martin v. Löwiseba40652007-08-30 20:10:57 +000027316s&@srcdir@&$ac_srcdir&;t t
27317s&@abs_srcdir@&$ac_abs_srcdir&;t t
27318s&@top_srcdir@&$ac_top_srcdir&;t t
27319s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
27320s&@builddir@&$ac_builddir&;t t
27321s&@abs_builddir@&$ac_abs_builddir&;t t
27322s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
27323s&@INSTALL@&$ac_INSTALL&;t t
27324$ac_datarootdir_hack
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027325"
27326eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
27327 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
27328$as_echo "$as_me: error: could not create $ac_file" >&2;}
27329 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000027330
Martin v. Löwiseba40652007-08-30 20:10:57 +000027331test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
27332 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
27333 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027334 { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Martin v. Löwiseba40652007-08-30 20:10:57 +000027335which seems to be undefined. Please make sure it is defined." >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027336$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Martin v. Löwiseba40652007-08-30 20:10:57 +000027337which seems to be undefined. Please make sure it is defined." >&2;}
Guido van Rossum76be6ed1995-01-02 18:33:54 +000027338
Martin v. Löwiseba40652007-08-30 20:10:57 +000027339 rm -f "$tmp/stdin"
Martin v. Löwis11437992002-04-12 09:54:03 +000027340 case $ac_file in
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027341 -) cat "$tmp/out" && rm -f "$tmp/out";;
27342 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
27343 esac \
27344 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
27345$as_echo "$as_me: error: could not create $ac_file" >&2;}
27346 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000027347 ;;
27348 :H)
27349 #
27350 # CONFIG_HEADER
27351 #
Martin v. Löwis11437992002-04-12 09:54:03 +000027352 if test x"$ac_file" != x-; then
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027353 {
27354 $as_echo "/* $configure_input */" \
27355 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
27356 } >"$tmp/config.h" \
27357 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
27358$as_echo "$as_me: error: could not create $ac_file" >&2;}
27359 { (exit 1); exit 1; }; }
27360 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
27361 { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
27362$as_echo "$as_me: $ac_file is unchanged" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +000027363 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027364 rm -f "$ac_file"
27365 mv "$tmp/config.h" "$ac_file" \
27366 || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
27367$as_echo "$as_me: error: could not create $ac_file" >&2;}
27368 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +000027369 fi
27370 else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027371 $as_echo "/* $configure_input */" \
27372 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
27373 || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
27374$as_echo "$as_me: error: could not create -" >&2;}
27375 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +000027376 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000027377 ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +000027378
Martin v. Löwiseba40652007-08-30 20:10:57 +000027379
27380 esac
27381
27382done # for ac_tag
27383
Guido van Rossum627b2d71993-12-24 10:39:16 +000027384
Martin v. Löwis11437992002-04-12 09:54:03 +000027385{ (exit 0); exit 0; }
27386_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000027387chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000027388ac_clean_files=$ac_clean_files_save
27389
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027390test $ac_write_fail = 0 ||
27391 { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
27392$as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
27393 { (exit 1); exit 1; }; }
27394
Martin v. Löwis11437992002-04-12 09:54:03 +000027395
27396# configure is writing to config.log, and then calls config.status.
27397# config.status does its own redirection, appending to config.log.
27398# Unfortunately, on DOS this fails, as config.log is still kept open
27399# by configure, so config.status won't be able to write to it; its
27400# output is simply discarded. So we exec the FD to /dev/null,
27401# effectively closing config.log, so it can be properly (re)opened and
27402# appended to by config.status. When coming back to configure, we
27403# need to make the FD available again.
27404if test "$no_create" != yes; then
27405 ac_cs_success=:
Skip Montanaro6dead952003-09-25 14:50:04 +000027406 ac_config_status_args=
27407 test "$silent" = yes &&
27408 ac_config_status_args="$ac_config_status_args --quiet"
Martin v. Löwis11437992002-04-12 09:54:03 +000027409 exec 5>/dev/null
Skip Montanaro6dead952003-09-25 14:50:04 +000027410 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
Martin v. Löwis11437992002-04-12 09:54:03 +000027411 exec 5>>config.log
27412 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27413 # would make configure fail if this is the last instruction.
27414 $ac_cs_success || { (exit 1); exit 1; }
27415fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027416if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
27417 { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
27418$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
27419fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000027420
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000027421
Martin v. Löwisf7afe952006-04-14 15:16:15 +000027422echo "creating Modules/Setup"
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000027423if test ! -f Modules/Setup
27424then
27425 cp $srcdir/Modules/Setup.dist Modules/Setup
27426fi
27427
Martin v. Löwisf7afe952006-04-14 15:16:15 +000027428echo "creating Modules/Setup.local"
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000027429if test ! -f Modules/Setup.local
27430then
27431 echo "# Edit this file for local setup changes" >Modules/Setup.local
27432fi
27433
27434echo "creating Makefile"
27435$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
27436 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000027437 Modules/Setup.local Modules/Setup
Skip Montanaro89e975f2007-08-22 19:05:21 +000027438
27439case $ac_sys_system in
27440BeOS)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027441 { $as_echo "$as_me:$LINENO: WARNING:
Skip Montanaro89e975f2007-08-22 19:05:21 +000027442
27443 Support for BeOS is deprecated as of Python 2.6.
27444 See PEP 11 for the gory details.
27445 " >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000027446$as_echo "$as_me: WARNING:
Skip Montanaro89e975f2007-08-22 19:05:21 +000027447
27448 Support for BeOS is deprecated as of Python 2.6.
27449 See PEP 11 for the gory details.
27450 " >&2;}
27451 ;;
27452*) ;;
27453esac
27454
Neil Schemenauerc761fc82001-02-19 04:50:49 +000027455mv config.c Modules