• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for python 3.10.
4#
5# Report bugs to <https://bugs.python.org/>.
6#
7#
8# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20  emulate sh
21  NULLCMD=:
22  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23  # is contrary to our usage.  Disable this feature.
24  alias -g '${1+"$@"}'='"$@"'
25  setopt NO_GLOB_SUBST
26else
27  case `(set -o) 2>/dev/null` in #(
28  *posix*) :
29    set -o posix ;; #(
30  *) :
31     ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47  as_echo='print -r --'
48  as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50  as_echo='printf %s\n'
51  as_echo_n='printf %s'
52else
53  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55    as_echo_n='/usr/ucb/echo -n'
56  else
57    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58    as_echo_n_body='eval
59      arg=$1;
60      case $arg in #(
61      *"$as_nl"*)
62	expr "X$arg" : "X\\(.*\\)$as_nl";
63	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64      esac;
65      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66    '
67    export as_echo_n_body
68    as_echo_n='sh -c $as_echo_n_body as_echo'
69  fi
70  export as_echo_body
71  as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; then
76  PATH_SEPARATOR=:
77  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79      PATH_SEPARATOR=';'
80  }
81fi
82
83
84# IFS
85# We need space, tab and new line, in precisely that order.  Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" ""	$as_nl"
90
91# Find who we are.  Look in the path if we contain no directory separator.
92as_myself=
93case $0 in #((
94  *[\\/]* ) as_myself=$0 ;;
95  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96for as_dir in $PATH
97do
98  IFS=$as_save_IFS
99  test -z "$as_dir" && as_dir=.
100    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101  done
102IFS=$as_save_IFS
103
104     ;;
105esac
106# We did not find ourselves, most probably we were run as `sh COMMAND'
107# in which case we are not to be found in the path.
108if test "x$as_myself" = x; then
109  as_myself=$0
110fi
111if test ! -f "$as_myself"; then
112  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113  exit 1
114fi
115
116# Unset variables that we do not need and which cause bugs (e.g. in
117# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
118# suppresses any "Segmentation fault" message there.  '((' could
119# trigger a bug in pdksh 5.2.14.
120for as_var in BASH_ENV ENV MAIL MAILPATH
121do eval test x\${$as_var+set} = xset \
122  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123done
124PS1='$ '
125PS2='> '
126PS4='+ '
127
128# NLS nuisances.
129LC_ALL=C
130export LC_ALL
131LANGUAGE=C
132export LANGUAGE
133
134# CDPATH.
135(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137# Use a proper internal environment variable to ensure we don't fall
138  # into an infinite loop, continuously re-executing ourselves.
139  if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140    _as_can_reexec=no; export _as_can_reexec;
141    # We cannot yet assume a decent shell, so we have to provide a
142# neutralization value for shells without unset; and this also
143# works around shells that cannot unset nonexistent variables.
144# Preserve -v and -x to the replacement shell.
145BASH_ENV=/dev/null
146ENV=/dev/null
147(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148case $- in # ((((
149  *v*x* | *x*v* ) as_opts=-vx ;;
150  *v* ) as_opts=-v ;;
151  *x* ) as_opts=-x ;;
152  * ) as_opts= ;;
153esac
154exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155# Admittedly, this is quite paranoid, since all the known shells bail
156# out after a failed `exec'.
157$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158as_fn_exit 255
159  fi
160  # We don't want this to propagate to other subprocesses.
161          { _as_can_reexec=; unset _as_can_reexec;}
162if test "x$CONFIG_SHELL" = x; then
163  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164  emulate sh
165  NULLCMD=:
166  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167  # is contrary to our usage.  Disable this feature.
168  alias -g '\${1+\"\$@\"}'='\"\$@\"'
169  setopt NO_GLOB_SUBST
170else
171  case \`(set -o) 2>/dev/null\` in #(
172  *posix*) :
173    set -o posix ;; #(
174  *) :
175     ;;
176esac
177fi
178"
179  as_required="as_fn_return () { (exit \$1); }
180as_fn_success () { as_fn_return 0; }
181as_fn_failure () { as_fn_return 1; }
182as_fn_ret_success () { return 0; }
183as_fn_ret_failure () { return 1; }
184
185exitcode=0
186as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192else
193  exitcode=1; echo positional parameters were not saved.
194fi
195test x\$exitcode = x0 || exit 1
196test -x / || exit 1"
197  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201test \$(( 1 + 1 )) = 2 || exit 1"
202  if (eval "$as_required") 2>/dev/null; then :
203  as_have_required=yes
204else
205  as_have_required=no
206fi
207  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
208
209else
210  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
211as_found=false
212for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
213do
214  IFS=$as_save_IFS
215  test -z "$as_dir" && as_dir=.
216  as_found=:
217  case $as_dir in #(
218	 /*)
219	   for as_base in sh bash ksh sh5; do
220	     # Try only shells that exist, to save several forks.
221	     as_shell=$as_dir/$as_base
222	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
223		    { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
224  CONFIG_SHELL=$as_shell as_have_required=yes
225		   if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
226  break 2
227fi
228fi
229	   done;;
230       esac
231  as_found=false
232done
233$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
234	      { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
235  CONFIG_SHELL=$SHELL as_have_required=yes
236fi; }
237IFS=$as_save_IFS
238
239
240      if test "x$CONFIG_SHELL" != x; then :
241  export CONFIG_SHELL
242             # We cannot yet assume a decent shell, so we have to provide a
243# neutralization value for shells without unset; and this also
244# works around shells that cannot unset nonexistent variables.
245# Preserve -v and -x to the replacement shell.
246BASH_ENV=/dev/null
247ENV=/dev/null
248(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
249case $- in # ((((
250  *v*x* | *x*v* ) as_opts=-vx ;;
251  *v* ) as_opts=-v ;;
252  *x* ) as_opts=-x ;;
253  * ) as_opts= ;;
254esac
255exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
256# Admittedly, this is quite paranoid, since all the known shells bail
257# out after a failed `exec'.
258$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
259exit 255
260fi
261
262    if test x$as_have_required = xno; then :
263  $as_echo "$0: This script requires a shell more modern than all"
264  $as_echo "$0: the shells that I found on your system."
265  if test x${ZSH_VERSION+set} = xset ; then
266    $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
267    $as_echo "$0: be upgraded to zsh 4.3.4 or later."
268  else
269    $as_echo "$0: Please tell bug-autoconf@gnu.org and
270$0: https://bugs.python.org/ about your system, including
271$0: any error possibly output before this message. Then
272$0: install a modern shell, or manually run the script
273$0: under such a shell if you do have one."
274  fi
275  exit 1
276fi
277fi
278fi
279SHELL=${CONFIG_SHELL-/bin/sh}
280export SHELL
281# Unset more variables known to interfere with behavior of common tools.
282CLICOLOR_FORCE= GREP_OPTIONS=
283unset CLICOLOR_FORCE GREP_OPTIONS
284
285## --------------------- ##
286## M4sh Shell Functions. ##
287## --------------------- ##
288# as_fn_unset VAR
289# ---------------
290# Portably unset VAR.
291as_fn_unset ()
292{
293  { eval $1=; unset $1;}
294}
295as_unset=as_fn_unset
296
297# as_fn_set_status STATUS
298# -----------------------
299# Set $? to STATUS, without forking.
300as_fn_set_status ()
301{
302  return $1
303} # as_fn_set_status
304
305# as_fn_exit STATUS
306# -----------------
307# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
308as_fn_exit ()
309{
310  set +e
311  as_fn_set_status $1
312  exit $1
313} # as_fn_exit
314
315# as_fn_mkdir_p
316# -------------
317# Create "$as_dir" as a directory, including parents if necessary.
318as_fn_mkdir_p ()
319{
320
321  case $as_dir in #(
322  -*) as_dir=./$as_dir;;
323  esac
324  test -d "$as_dir" || eval $as_mkdir_p || {
325    as_dirs=
326    while :; do
327      case $as_dir in #(
328      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
329      *) as_qdir=$as_dir;;
330      esac
331      as_dirs="'$as_qdir' $as_dirs"
332      as_dir=`$as_dirname -- "$as_dir" ||
333$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
334	 X"$as_dir" : 'X\(//\)[^/]' \| \
335	 X"$as_dir" : 'X\(//\)$' \| \
336	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
337$as_echo X"$as_dir" |
338    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
339	    s//\1/
340	    q
341	  }
342	  /^X\(\/\/\)[^/].*/{
343	    s//\1/
344	    q
345	  }
346	  /^X\(\/\/\)$/{
347	    s//\1/
348	    q
349	  }
350	  /^X\(\/\).*/{
351	    s//\1/
352	    q
353	  }
354	  s/.*/./; q'`
355      test -d "$as_dir" && break
356    done
357    test -z "$as_dirs" || eval "mkdir $as_dirs"
358  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
359
360
361} # as_fn_mkdir_p
362
363# as_fn_executable_p FILE
364# -----------------------
365# Test if FILE is an executable regular file.
366as_fn_executable_p ()
367{
368  test -f "$1" && test -x "$1"
369} # as_fn_executable_p
370# as_fn_append VAR VALUE
371# ----------------------
372# Append the text in VALUE to the end of the definition contained in VAR. Take
373# advantage of any shell optimizations that allow amortized linear growth over
374# repeated appends, instead of the typical quadratic growth present in naive
375# implementations.
376if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
377  eval 'as_fn_append ()
378  {
379    eval $1+=\$2
380  }'
381else
382  as_fn_append ()
383  {
384    eval $1=\$$1\$2
385  }
386fi # as_fn_append
387
388# as_fn_arith ARG...
389# ------------------
390# Perform arithmetic evaluation on the ARGs, and store the result in the
391# global $as_val. Take advantage of shells that can avoid forks. The arguments
392# must be portable across $(()) and expr.
393if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
394  eval 'as_fn_arith ()
395  {
396    as_val=$(( $* ))
397  }'
398else
399  as_fn_arith ()
400  {
401    as_val=`expr "$@" || test $? -eq 1`
402  }
403fi # as_fn_arith
404
405
406# as_fn_error STATUS ERROR [LINENO LOG_FD]
407# ----------------------------------------
408# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
409# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
410# script with STATUS, using 1 if that was 0.
411as_fn_error ()
412{
413  as_status=$1; test $as_status -eq 0 && as_status=1
414  if test "$4"; then
415    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
416    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
417  fi
418  $as_echo "$as_me: error: $2" >&2
419  as_fn_exit $as_status
420} # as_fn_error
421
422if expr a : '\(a\)' >/dev/null 2>&1 &&
423   test "X`expr 00001 : '.*\(...\)'`" = X001; then
424  as_expr=expr
425else
426  as_expr=false
427fi
428
429if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
430  as_basename=basename
431else
432  as_basename=false
433fi
434
435if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
436  as_dirname=dirname
437else
438  as_dirname=false
439fi
440
441as_me=`$as_basename -- "$0" ||
442$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
443	 X"$0" : 'X\(//\)$' \| \
444	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
445$as_echo X/"$0" |
446    sed '/^.*\/\([^/][^/]*\)\/*$/{
447	    s//\1/
448	    q
449	  }
450	  /^X\/\(\/\/\)$/{
451	    s//\1/
452	    q
453	  }
454	  /^X\/\(\/\).*/{
455	    s//\1/
456	    q
457	  }
458	  s/.*/./; q'`
459
460# Avoid depending upon Character Ranges.
461as_cr_letters='abcdefghijklmnopqrstuvwxyz'
462as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
463as_cr_Letters=$as_cr_letters$as_cr_LETTERS
464as_cr_digits='0123456789'
465as_cr_alnum=$as_cr_Letters$as_cr_digits
466
467
468  as_lineno_1=$LINENO as_lineno_1a=$LINENO
469  as_lineno_2=$LINENO as_lineno_2a=$LINENO
470  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
471  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
472  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
473  sed -n '
474    p
475    /[$]LINENO/=
476  ' <$as_myself |
477    sed '
478      s/[$]LINENO.*/&-/
479      t lineno
480      b
481      :lineno
482      N
483      :loop
484      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
485      t loop
486      s/-\n.*//
487    ' >$as_me.lineno &&
488  chmod +x "$as_me.lineno" ||
489    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
490
491  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
492  # already done that, so ensure we don't try to do so again and fall
493  # in an infinite loop.  This has already happened in practice.
494  _as_can_reexec=no; export _as_can_reexec
495  # Don't try to exec as it changes $[0], causing all sort of problems
496  # (the dirname of $[0] is not the place where we might find the
497  # original and so on.  Autoconf is especially sensitive to this).
498  . "./$as_me.lineno"
499  # Exit status is that of the last command.
500  exit
501}
502
503ECHO_C= ECHO_N= ECHO_T=
504case `echo -n x` in #(((((
505-n*)
506  case `echo 'xy\c'` in
507  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
508  xy)  ECHO_C='\c';;
509  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
510       ECHO_T='	';;
511  esac;;
512*)
513  ECHO_N='-n';;
514esac
515
516rm -f conf$$ conf$$.exe conf$$.file
517if test -d conf$$.dir; then
518  rm -f conf$$.dir/conf$$.file
519else
520  rm -f conf$$.dir
521  mkdir conf$$.dir 2>/dev/null
522fi
523if (echo >conf$$.file) 2>/dev/null; then
524  if ln -s conf$$.file conf$$ 2>/dev/null; then
525    as_ln_s='ln -s'
526    # ... but there are two gotchas:
527    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
528    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
529    # In both cases, we have to default to `cp -pR'.
530    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
531      as_ln_s='cp -pR'
532  elif ln conf$$.file conf$$ 2>/dev/null; then
533    as_ln_s=ln
534  else
535    as_ln_s='cp -pR'
536  fi
537else
538  as_ln_s='cp -pR'
539fi
540rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
541rmdir conf$$.dir 2>/dev/null
542
543if mkdir -p . 2>/dev/null; then
544  as_mkdir_p='mkdir -p "$as_dir"'
545else
546  test -d ./-p && rmdir ./-p
547  as_mkdir_p=false
548fi
549
550as_test_x='test -x'
551as_executable_p=as_fn_executable_p
552
553# Sed expression to map a string onto a valid CPP name.
554as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
555
556# Sed expression to map a string onto a valid variable name.
557as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
558
559
560test -n "$DJDIR" || exec 7<&0 </dev/null
561exec 6>&1
562
563# Name of the host.
564# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
565# so uname gets run too.
566ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
567
568#
569# Initializations.
570#
571ac_default_prefix=/usr/local
572ac_clean_files=
573ac_config_libobj_dir=.
574LIBOBJS=
575cross_compiling=no
576subdirs=
577MFLAGS=
578MAKEFLAGS=
579
580# Identity of this package.
581PACKAGE_NAME='python'
582PACKAGE_TARNAME='python'
583PACKAGE_VERSION='3.10'
584PACKAGE_STRING='python 3.10'
585PACKAGE_BUGREPORT='https://bugs.python.org/'
586PACKAGE_URL=''
587
588ac_unique_file="Include/object.h"
589# Factoring default headers for most tests.
590ac_includes_default="\
591#include <stdio.h>
592#ifdef HAVE_SYS_TYPES_H
593# include <sys/types.h>
594#endif
595#ifdef HAVE_SYS_STAT_H
596# include <sys/stat.h>
597#endif
598#ifdef STDC_HEADERS
599# include <stdlib.h>
600# include <stddef.h>
601#else
602# ifdef HAVE_STDLIB_H
603#  include <stdlib.h>
604# endif
605#endif
606#ifdef HAVE_STRING_H
607# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
608#  include <memory.h>
609# endif
610# include <string.h>
611#endif
612#ifdef HAVE_STRINGS_H
613# include <strings.h>
614#endif
615#ifdef HAVE_INTTYPES_H
616# include <inttypes.h>
617#endif
618#ifdef HAVE_STDINT_H
619# include <stdint.h>
620#endif
621#ifdef HAVE_UNISTD_H
622# include <unistd.h>
623#endif"
624
625ac_subst_vars='LTLIBOBJS
626TEST_MODULES
627LIBRARY_DEPS
628STATIC_LIBPYTHON
629OPENSSL_RPATH
630OPENSSL_LDFLAGS
631OPENSSL_LIBS
632OPENSSL_INCLUDES
633ENSUREPIP
634SRCDIRS
635THREADHEADERS
636WHEEL_PKG_DIR
637LIBPL
638PY_ENABLE_SHARED
639PLATLIBDIR
640BINLIBDEST
641LIBPYTHON
642EXT_SUFFIX
643ALT_SOABI
644SOABI
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
657DTRACE_OBJS
658DTRACE_HEADERS
659DFLAGS
660DTRACE
661TCLTK_LIBS
662TCLTK_INCLUDES
663LIBFFI_INCLUDEDIR
664PKG_CONFIG_LIBDIR
665PKG_CONFIG_PATH
666PKG_CONFIG
667TZPATH
668SHLIBS
669CFLAGSFORSHARED
670LINKFORSHARED
671CCSHARED
672BLDSHARED
673LDCXXSHARED
674LDSHARED
675SHLIB_SUFFIX
676LIBTOOL_CRUFT
677OTHER_LIBTOOL_OPT
678UNIVERSAL_ARCH_FLAGS
679LDFLAGS_NODIST
680CFLAGS_NODIST
681BASECFLAGS
682CFLAGS_ALIASING
683OPT
684LLVM_PROF_FOUND
685LLVM_PROFDATA
686LLVM_PROF_ERR
687LLVM_PROF_FILE
688LLVM_PROF_MERGER
689PGO_PROF_USE_FLAG
690PGO_PROF_GEN_FLAG
691LLVM_AR_FOUND
692LLVM_AR
693PROFILE_TASK
694DEF_MAKE_RULE
695DEF_MAKE_ALL_RULE
696ABIFLAGS
697LN
698MKDIR_P
699INSTALL_DATA
700INSTALL_SCRIPT
701INSTALL_PROGRAM
702ac_ct_READELF
703READELF
704ARFLAGS
705ac_ct_AR
706AR
707GNULD
708EXPORTSFROM
709EXPORTSYMS
710LINKCC
711LDVERSION
712RUNSHARED
713INSTSONAME
714LDLIBRARYDIR
715PY3LIBRARY
716BLDLIBRARY
717DLLLIBRARY
718LDLIBRARY
719LIBRARY
720BUILDEXEEXT
721EGREP
722NO_AS_NEEDED
723MULTIARCH_CPPFLAGS
724PLATFORM_TRIPLET
725MULTIARCH
726ac_ct_CXX
727MAINCC
728CXX
729SED
730GREP
731CPP
732OBJEXT
733EXEEXT
734ac_ct_CC
735CPPFLAGS
736LDFLAGS
737CFLAGS
738CC
739EXPORT_MACOSX_DEPLOYMENT_TARGET
740CONFIGURE_MACOSX_DEPLOYMENT_TARGET
741_PYTHON_HOST_PLATFORM
742MACHDEP
743FRAMEWORKINSTALLAPPSPREFIX
744FRAMEWORKUNIXTOOLSPREFIX
745FRAMEWORKPYTHONW
746FRAMEWORKALTINSTALLLAST
747FRAMEWORKALTINSTALLFIRST
748FRAMEWORKINSTALLLAST
749FRAMEWORKINSTALLFIRST
750PYTHONFRAMEWORKINSTALLDIR
751PYTHONFRAMEWORKPREFIX
752PYTHONFRAMEWORKDIR
753PYTHONFRAMEWORKIDENTIFIER
754PYTHONFRAMEWORK
755LIPO_INTEL64_FLAGS
756LIPO_32BIT_FLAGS
757ARCH_RUN_32BIT
758UNIVERSALSDK
759CONFIG_ARGS
760SOVERSION
761VERSION
762PYTHON_FOR_BUILD
763PYTHON_FOR_REGEN
764host_os
765host_vendor
766host_cpu
767host
768build_os
769build_vendor
770build_cpu
771build
772HAS_GIT
773GITBRANCH
774GITTAG
775GITVERSION
776BASECPPFLAGS
777target_alias
778host_alias
779build_alias
780LIBS
781ECHO_T
782ECHO_N
783ECHO_C
784DEFS
785mandir
786localedir
787libdir
788psdir
789pdfdir
790dvidir
791htmldir
792infodir
793docdir
794oldincludedir
795includedir
796runstatedir
797localstatedir
798sharedstatedir
799sysconfdir
800datadir
801datarootdir
802libexecdir
803sbindir
804bindir
805program_transform_name
806prefix
807exec_prefix
808PACKAGE_URL
809PACKAGE_BUGREPORT
810PACKAGE_STRING
811PACKAGE_VERSION
812PACKAGE_TARNAME
813PACKAGE_NAME
814PATH_SEPARATOR
815SHELL'
816ac_subst_files=''
817ac_user_opts='
818enable_option_checking
819enable_universalsdk
820with_universal_archs
821with_framework_name
822enable_framework
823with_cxx_main
824with_suffix
825enable_shared
826enable_profiling
827with_pydebug
828with_trace_refs
829with_assertions
830enable_optimizations
831with_lto
832with_address_sanitizer
833with_memory_sanitizer
834with_undefined_behavior_sanitizer
835with_hash_algorithm
836with_tzpath
837with_libs
838with_system_expat
839with_system_ffi
840with_system_libmpdec
841with_decimal_contextvar
842enable_loadable_sqlite_extensions
843with_tcltk_includes
844with_tcltk_libs
845with_dbmliborder
846enable_ipv6
847with_doc_strings
848with_pymalloc
849with_c_locale_coercion
850with_valgrind
851with_dtrace
852with_libm
853with_libc
854enable_big_digits
855with_platlibdir
856with_wheel_pkg_dir
857with_readline
858with_computed_gotos
859with_ensurepip
860with_openssl
861with_openssl_rpath
862with_ssl_default_suites
863with_builtin_hashlib_hashes
864with_experimental_isolated_subinterpreters
865with_static_libpython
866enable_test_modules
867'
868      ac_precious_vars='build_alias
869host_alias
870target_alias
871MACHDEP
872CC
873CFLAGS
874LDFLAGS
875LIBS
876CPPFLAGS
877CPP
878PROFILE_TASK
879PKG_CONFIG
880PKG_CONFIG_PATH
881PKG_CONFIG_LIBDIR'
882
883
884# Initialize some variables set by options.
885ac_init_help=
886ac_init_version=false
887ac_unrecognized_opts=
888ac_unrecognized_sep=
889# The variables have the same names as the options, with
890# dashes changed to underlines.
891cache_file=/dev/null
892exec_prefix=NONE
893no_create=
894no_recursion=
895prefix=NONE
896program_prefix=NONE
897program_suffix=NONE
898program_transform_name=s,x,x,
899silent=
900site=
901srcdir=
902verbose=
903x_includes=NONE
904x_libraries=NONE
905
906# Installation directory options.
907# These are left unexpanded so users can "make install exec_prefix=/foo"
908# and all the variables that are supposed to be based on exec_prefix
909# by default will actually change.
910# Use braces instead of parens because sh, perl, etc. also accept them.
911# (The list follows the same order as the GNU Coding Standards.)
912bindir='${exec_prefix}/bin'
913sbindir='${exec_prefix}/sbin'
914libexecdir='${exec_prefix}/libexec'
915datarootdir='${prefix}/share'
916datadir='${datarootdir}'
917sysconfdir='${prefix}/etc'
918sharedstatedir='${prefix}/com'
919localstatedir='${prefix}/var'
920runstatedir='${localstatedir}/run'
921includedir='${prefix}/include'
922oldincludedir='/usr/include'
923docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
924infodir='${datarootdir}/info'
925htmldir='${docdir}'
926dvidir='${docdir}'
927pdfdir='${docdir}'
928psdir='${docdir}'
929libdir='${exec_prefix}/lib'
930localedir='${datarootdir}/locale'
931mandir='${datarootdir}/man'
932
933ac_prev=
934ac_dashdash=
935for ac_option
936do
937  # If the previous option needs an argument, assign it.
938  if test -n "$ac_prev"; then
939    eval $ac_prev=\$ac_option
940    ac_prev=
941    continue
942  fi
943
944  case $ac_option in
945  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
946  *=)   ac_optarg= ;;
947  *)    ac_optarg=yes ;;
948  esac
949
950  # Accept the important Cygnus configure options, so we can diagnose typos.
951
952  case $ac_dashdash$ac_option in
953  --)
954    ac_dashdash=yes ;;
955
956  -bindir | --bindir | --bindi | --bind | --bin | --bi)
957    ac_prev=bindir ;;
958  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
959    bindir=$ac_optarg ;;
960
961  -build | --build | --buil | --bui | --bu)
962    ac_prev=build_alias ;;
963  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
964    build_alias=$ac_optarg ;;
965
966  -cache-file | --cache-file | --cache-fil | --cache-fi \
967  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
968    ac_prev=cache_file ;;
969  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
970  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
971    cache_file=$ac_optarg ;;
972
973  --config-cache | -C)
974    cache_file=config.cache ;;
975
976  -datadir | --datadir | --datadi | --datad)
977    ac_prev=datadir ;;
978  -datadir=* | --datadir=* | --datadi=* | --datad=*)
979    datadir=$ac_optarg ;;
980
981  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
982  | --dataroo | --dataro | --datar)
983    ac_prev=datarootdir ;;
984  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
985  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
986    datarootdir=$ac_optarg ;;
987
988  -disable-* | --disable-*)
989    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
990    # Reject names that are not valid shell variable names.
991    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
992      as_fn_error $? "invalid feature name: $ac_useropt"
993    ac_useropt_orig=$ac_useropt
994    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
995    case $ac_user_opts in
996      *"
997"enable_$ac_useropt"
998"*) ;;
999      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1000	 ac_unrecognized_sep=', ';;
1001    esac
1002    eval enable_$ac_useropt=no ;;
1003
1004  -docdir | --docdir | --docdi | --doc | --do)
1005    ac_prev=docdir ;;
1006  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1007    docdir=$ac_optarg ;;
1008
1009  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1010    ac_prev=dvidir ;;
1011  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1012    dvidir=$ac_optarg ;;
1013
1014  -enable-* | --enable-*)
1015    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1016    # Reject names that are not valid shell variable names.
1017    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1018      as_fn_error $? "invalid feature name: $ac_useropt"
1019    ac_useropt_orig=$ac_useropt
1020    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1021    case $ac_user_opts in
1022      *"
1023"enable_$ac_useropt"
1024"*) ;;
1025      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1026	 ac_unrecognized_sep=', ';;
1027    esac
1028    eval enable_$ac_useropt=\$ac_optarg ;;
1029
1030  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1031  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1032  | --exec | --exe | --ex)
1033    ac_prev=exec_prefix ;;
1034  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1035  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1036  | --exec=* | --exe=* | --ex=*)
1037    exec_prefix=$ac_optarg ;;
1038
1039  -gas | --gas | --ga | --g)
1040    # Obsolete; use --with-gas.
1041    with_gas=yes ;;
1042
1043  -help | --help | --hel | --he | -h)
1044    ac_init_help=long ;;
1045  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1046    ac_init_help=recursive ;;
1047  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1048    ac_init_help=short ;;
1049
1050  -host | --host | --hos | --ho)
1051    ac_prev=host_alias ;;
1052  -host=* | --host=* | --hos=* | --ho=*)
1053    host_alias=$ac_optarg ;;
1054
1055  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1056    ac_prev=htmldir ;;
1057  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1058  | --ht=*)
1059    htmldir=$ac_optarg ;;
1060
1061  -includedir | --includedir | --includedi | --included | --include \
1062  | --includ | --inclu | --incl | --inc)
1063    ac_prev=includedir ;;
1064  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1065  | --includ=* | --inclu=* | --incl=* | --inc=*)
1066    includedir=$ac_optarg ;;
1067
1068  -infodir | --infodir | --infodi | --infod | --info | --inf)
1069    ac_prev=infodir ;;
1070  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1071    infodir=$ac_optarg ;;
1072
1073  -libdir | --libdir | --libdi | --libd)
1074    ac_prev=libdir ;;
1075  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1076    libdir=$ac_optarg ;;
1077
1078  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1079  | --libexe | --libex | --libe)
1080    ac_prev=libexecdir ;;
1081  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1082  | --libexe=* | --libex=* | --libe=*)
1083    libexecdir=$ac_optarg ;;
1084
1085  -localedir | --localedir | --localedi | --localed | --locale)
1086    ac_prev=localedir ;;
1087  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1088    localedir=$ac_optarg ;;
1089
1090  -localstatedir | --localstatedir | --localstatedi | --localstated \
1091  | --localstate | --localstat | --localsta | --localst | --locals)
1092    ac_prev=localstatedir ;;
1093  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1094  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1095    localstatedir=$ac_optarg ;;
1096
1097  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1098    ac_prev=mandir ;;
1099  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1100    mandir=$ac_optarg ;;
1101
1102  -nfp | --nfp | --nf)
1103    # Obsolete; use --without-fp.
1104    with_fp=no ;;
1105
1106  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1107  | --no-cr | --no-c | -n)
1108    no_create=yes ;;
1109
1110  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1111  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1112    no_recursion=yes ;;
1113
1114  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1115  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1116  | --oldin | --oldi | --old | --ol | --o)
1117    ac_prev=oldincludedir ;;
1118  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1119  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1120  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1121    oldincludedir=$ac_optarg ;;
1122
1123  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1124    ac_prev=prefix ;;
1125  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1126    prefix=$ac_optarg ;;
1127
1128  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1129  | --program-pre | --program-pr | --program-p)
1130    ac_prev=program_prefix ;;
1131  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1132  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1133    program_prefix=$ac_optarg ;;
1134
1135  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1136  | --program-suf | --program-su | --program-s)
1137    ac_prev=program_suffix ;;
1138  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1139  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1140    program_suffix=$ac_optarg ;;
1141
1142  -program-transform-name | --program-transform-name \
1143  | --program-transform-nam | --program-transform-na \
1144  | --program-transform-n | --program-transform- \
1145  | --program-transform | --program-transfor \
1146  | --program-transfo | --program-transf \
1147  | --program-trans | --program-tran \
1148  | --progr-tra | --program-tr | --program-t)
1149    ac_prev=program_transform_name ;;
1150  -program-transform-name=* | --program-transform-name=* \
1151  | --program-transform-nam=* | --program-transform-na=* \
1152  | --program-transform-n=* | --program-transform-=* \
1153  | --program-transform=* | --program-transfor=* \
1154  | --program-transfo=* | --program-transf=* \
1155  | --program-trans=* | --program-tran=* \
1156  | --progr-tra=* | --program-tr=* | --program-t=*)
1157    program_transform_name=$ac_optarg ;;
1158
1159  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1160    ac_prev=pdfdir ;;
1161  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1162    pdfdir=$ac_optarg ;;
1163
1164  -psdir | --psdir | --psdi | --psd | --ps)
1165    ac_prev=psdir ;;
1166  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1167    psdir=$ac_optarg ;;
1168
1169  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1170  | -silent | --silent | --silen | --sile | --sil)
1171    silent=yes ;;
1172
1173  -runstatedir | --runstatedir | --runstatedi | --runstated \
1174  | --runstate | --runstat | --runsta | --runst | --runs \
1175  | --run | --ru | --r)
1176    ac_prev=runstatedir ;;
1177  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1178  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1179  | --run=* | --ru=* | --r=*)
1180    runstatedir=$ac_optarg ;;
1181
1182  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1183    ac_prev=sbindir ;;
1184  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1185  | --sbi=* | --sb=*)
1186    sbindir=$ac_optarg ;;
1187
1188  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1189  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1190  | --sharedst | --shareds | --shared | --share | --shar \
1191  | --sha | --sh)
1192    ac_prev=sharedstatedir ;;
1193  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1194  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1195  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1196  | --sha=* | --sh=*)
1197    sharedstatedir=$ac_optarg ;;
1198
1199  -site | --site | --sit)
1200    ac_prev=site ;;
1201  -site=* | --site=* | --sit=*)
1202    site=$ac_optarg ;;
1203
1204  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1205    ac_prev=srcdir ;;
1206  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1207    srcdir=$ac_optarg ;;
1208
1209  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1210  | --syscon | --sysco | --sysc | --sys | --sy)
1211    ac_prev=sysconfdir ;;
1212  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1213  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1214    sysconfdir=$ac_optarg ;;
1215
1216  -target | --target | --targe | --targ | --tar | --ta | --t)
1217    ac_prev=target_alias ;;
1218  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1219    target_alias=$ac_optarg ;;
1220
1221  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1222    verbose=yes ;;
1223
1224  -version | --version | --versio | --versi | --vers | -V)
1225    ac_init_version=: ;;
1226
1227  -with-* | --with-*)
1228    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1229    # Reject names that are not valid shell variable names.
1230    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1231      as_fn_error $? "invalid package name: $ac_useropt"
1232    ac_useropt_orig=$ac_useropt
1233    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1234    case $ac_user_opts in
1235      *"
1236"with_$ac_useropt"
1237"*) ;;
1238      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1239	 ac_unrecognized_sep=', ';;
1240    esac
1241    eval with_$ac_useropt=\$ac_optarg ;;
1242
1243  -without-* | --without-*)
1244    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1245    # Reject names that are not valid shell variable names.
1246    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1247      as_fn_error $? "invalid package name: $ac_useropt"
1248    ac_useropt_orig=$ac_useropt
1249    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1250    case $ac_user_opts in
1251      *"
1252"with_$ac_useropt"
1253"*) ;;
1254      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1255	 ac_unrecognized_sep=', ';;
1256    esac
1257    eval with_$ac_useropt=no ;;
1258
1259  --x)
1260    # Obsolete; use --with-x.
1261    with_x=yes ;;
1262
1263  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1264  | --x-incl | --x-inc | --x-in | --x-i)
1265    ac_prev=x_includes ;;
1266  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1267  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1268    x_includes=$ac_optarg ;;
1269
1270  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1271  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1272    ac_prev=x_libraries ;;
1273  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1274  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1275    x_libraries=$ac_optarg ;;
1276
1277  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1278Try \`$0 --help' for more information"
1279    ;;
1280
1281  *=*)
1282    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1283    # Reject names that are not valid shell variable names.
1284    case $ac_envvar in #(
1285      '' | [0-9]* | *[!_$as_cr_alnum]* )
1286      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1287    esac
1288    eval $ac_envvar=\$ac_optarg
1289    export $ac_envvar ;;
1290
1291  *)
1292    # FIXME: should be removed in autoconf 3.0.
1293    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1294    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1295      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1296    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1297    ;;
1298
1299  esac
1300done
1301
1302if test -n "$ac_prev"; then
1303  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1304  as_fn_error $? "missing argument to $ac_option"
1305fi
1306
1307if test -n "$ac_unrecognized_opts"; then
1308  case $enable_option_checking in
1309    no) ;;
1310    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1311    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1312  esac
1313fi
1314
1315# Check all directory arguments for consistency.
1316for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1317		datadir sysconfdir sharedstatedir localstatedir includedir \
1318		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1319		libdir localedir mandir runstatedir
1320do
1321  eval ac_val=\$$ac_var
1322  # Remove trailing slashes.
1323  case $ac_val in
1324    */ )
1325      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1326      eval $ac_var=\$ac_val;;
1327  esac
1328  # Be sure to have absolute directory names.
1329  case $ac_val in
1330    [\\/$]* | ?:[\\/]* )  continue;;
1331    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1332  esac
1333  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1334done
1335
1336# There might be people who depend on the old broken behavior: `$host'
1337# used to hold the argument of --host etc.
1338# FIXME: To remove some day.
1339build=$build_alias
1340host=$host_alias
1341target=$target_alias
1342
1343# FIXME: To remove some day.
1344if test "x$host_alias" != x; then
1345  if test "x$build_alias" = x; then
1346    cross_compiling=maybe
1347  elif test "x$build_alias" != "x$host_alias"; then
1348    cross_compiling=yes
1349  fi
1350fi
1351
1352ac_tool_prefix=
1353test -n "$host_alias" && ac_tool_prefix=$host_alias-
1354
1355test "$silent" = yes && exec 6>/dev/null
1356
1357
1358ac_pwd=`pwd` && test -n "$ac_pwd" &&
1359ac_ls_di=`ls -di .` &&
1360ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1361  as_fn_error $? "working directory cannot be determined"
1362test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1363  as_fn_error $? "pwd does not report name of working directory"
1364
1365
1366# Find the source files, if location was not specified.
1367if test -z "$srcdir"; then
1368  ac_srcdir_defaulted=yes
1369  # Try the directory containing this script, then the parent directory.
1370  ac_confdir=`$as_dirname -- "$as_myself" ||
1371$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1372	 X"$as_myself" : 'X\(//\)[^/]' \| \
1373	 X"$as_myself" : 'X\(//\)$' \| \
1374	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1375$as_echo X"$as_myself" |
1376    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1377	    s//\1/
1378	    q
1379	  }
1380	  /^X\(\/\/\)[^/].*/{
1381	    s//\1/
1382	    q
1383	  }
1384	  /^X\(\/\/\)$/{
1385	    s//\1/
1386	    q
1387	  }
1388	  /^X\(\/\).*/{
1389	    s//\1/
1390	    q
1391	  }
1392	  s/.*/./; q'`
1393  srcdir=$ac_confdir
1394  if test ! -r "$srcdir/$ac_unique_file"; then
1395    srcdir=..
1396  fi
1397else
1398  ac_srcdir_defaulted=no
1399fi
1400if test ! -r "$srcdir/$ac_unique_file"; then
1401  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1402  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1403fi
1404ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1405ac_abs_confdir=`(
1406	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1407	pwd)`
1408# When building in place, set srcdir=.
1409if test "$ac_abs_confdir" = "$ac_pwd"; then
1410  srcdir=.
1411fi
1412# Remove unnecessary trailing slashes from srcdir.
1413# Double slashes in file names in object file debugging info
1414# mess up M-x gdb in Emacs.
1415case $srcdir in
1416*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1417esac
1418for ac_var in $ac_precious_vars; do
1419  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1420  eval ac_env_${ac_var}_value=\$${ac_var}
1421  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1422  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1423done
1424
1425#
1426# Report the --help message.
1427#
1428if test "$ac_init_help" = "long"; then
1429  # Omit some internal or obsolete options to make the list less imposing.
1430  # This message is too long to be a string in the A/UX 3.1 sh.
1431  cat <<_ACEOF
1432\`configure' configures python 3.10 to adapt to many kinds of systems.
1433
1434Usage: $0 [OPTION]... [VAR=VALUE]...
1435
1436To assign environment variables (e.g., CC, CFLAGS...), specify them as
1437VAR=VALUE.  See below for descriptions of some of the useful variables.
1438
1439Defaults for the options are specified in brackets.
1440
1441Configuration:
1442  -h, --help              display this help and exit
1443      --help=short        display options specific to this package
1444      --help=recursive    display the short help of all the included packages
1445  -V, --version           display version information and exit
1446  -q, --quiet, --silent   do not print \`checking ...' messages
1447      --cache-file=FILE   cache test results in FILE [disabled]
1448  -C, --config-cache      alias for \`--cache-file=config.cache'
1449  -n, --no-create         do not create output files
1450      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1451
1452Installation directories:
1453  --prefix=PREFIX         install architecture-independent files in PREFIX
1454                          [$ac_default_prefix]
1455  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1456                          [PREFIX]
1457
1458By default, \`make install' will install all the files in
1459\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1460an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1461for instance \`--prefix=\$HOME'.
1462
1463For better control, use the options below.
1464
1465Fine tuning of the installation directories:
1466  --bindir=DIR            user executables [EPREFIX/bin]
1467  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1468  --libexecdir=DIR        program executables [EPREFIX/libexec]
1469  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1470  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1471  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1472  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
1473  --libdir=DIR            object code libraries [EPREFIX/lib]
1474  --includedir=DIR        C header files [PREFIX/include]
1475  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1476  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1477  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1478  --infodir=DIR           info documentation [DATAROOTDIR/info]
1479  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1480  --mandir=DIR            man documentation [DATAROOTDIR/man]
1481  --docdir=DIR            documentation root [DATAROOTDIR/doc/python]
1482  --htmldir=DIR           html documentation [DOCDIR]
1483  --dvidir=DIR            dvi documentation [DOCDIR]
1484  --pdfdir=DIR            pdf documentation [DOCDIR]
1485  --psdir=DIR             ps documentation [DOCDIR]
1486_ACEOF
1487
1488  cat <<\_ACEOF
1489
1490System types:
1491  --build=BUILD     configure for building on BUILD [guessed]
1492  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1493_ACEOF
1494fi
1495
1496if test -n "$ac_init_help"; then
1497  case $ac_init_help in
1498     short | recursive ) echo "Configuration of python 3.10:";;
1499   esac
1500  cat <<\_ACEOF
1501
1502Optional Features:
1503  --disable-option-checking  ignore unrecognized --enable/--with options
1504  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1505  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1506  --enable-universalsdk[=SDKDIR]
1507                          create a universal binary build. SDKDIR specifies
1508                          which macOS SDK should be used to perform the build,
1509                          see Mac/README.rst. (default is no)
1510  --enable-framework[=INSTALLDIR]
1511                          create a Python.framework rather than a traditional
1512                          Unix install. optional INSTALLDIR specifies the
1513                          installation path. see Mac/README.rst (default is
1514                          no)
1515  --enable-shared         enable building a shared Python library (default is
1516                          no)
1517  --enable-profiling      enable C-level code profiling with gprof (default is
1518                          no)
1519  --enable-optimizations  enable expensive, stable optimizations (PGO, etc.)
1520                          (default is no)
1521  --enable-loadable-sqlite-extensions
1522                          support loadable extensions in _sqlite module, see
1523                          Doc/library/sqlite3.rst (default is no)
1524  --enable-ipv6           enable ipv6 (with ipv4) support, see
1525                          Doc/library/socket.rst (default is yes if supported)
1526  --enable-big-digits[=15|30]
1527                          use big digits (30 or 15 bits) for Python longs
1528                          (default is system-dependent)]
1529  --disable-test-modules  don't build nor install test modules
1530
1531Optional Packages:
1532  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1533  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1534  --with-universal-archs=ARCH
1535                          specify the kind of macOS universal binary that
1536                          should be created. This option is only valid when
1537                          --enable-universalsdk is set; options are:
1538                          ("universal2", "intel-64", "intel-32", "intel",
1539                          "32-bit", "64-bit", "3-way", or "all") see
1540                          Mac/README.rst
1541  --with-framework-name=FRAMEWORK
1542                          specify the name for the python framework on macOS
1543                          only valid when --enable-framework is set. see
1544                          Mac/README.rst (default is 'Python')
1545  --with-cxx-main[=COMPILER]
1546                          compile main() and link Python executable with C++
1547                          compiler specified in COMPILER (default is $CXX)
1548  --with-suffix=SUFFIX    set executable suffix to SUFFIX (default is '.exe')
1549  --with-pydebug          build with Py_DEBUG defined (default is no)
1550  --with-trace-refs       enable tracing references for debugging purpose
1551                          (default is no)
1552  --with-assertions       build with C assertions enabled (default is no)
1553  --with-lto              enable Link-Time-Optimization in any build (default
1554                          is no)
1555  --with-address-sanitizer
1556                          enable AddressSanitizer memory error detector,
1557                          'asan' (default is no)
1558  --with-memory-sanitizer enable MemorySanitizer allocation error detector,
1559                          'msan' (default is no)
1560  --with-undefined-behavior-sanitizer
1561                          enable UndefinedBehaviorSanitizer undefined
1562                          behaviour detector, 'ubsan' (default is no)
1563  --with-hash-algorithm=[fnv|siphash24]
1564                          select hash algorithm for use in Python/pyhash.c
1565                          (default is SipHash24)
1566  --with-tzpath=<list of absolute paths separated by pathsep>
1567                           Select the default time zone search path for zoneinfo.TZPATH
1568
1569  --with-libs='lib1 ...'  link against additional libs (default is no)
1570  --with-system-expat     build pyexpat module using an installed expat
1571                          library, see Doc/library/pyexpat.rst (default is no)
1572  --with-system-ffi       build _ctypes module using an installed ffi library,
1573                          see Doc/library/ctypes.rst (default is
1574                          system-dependent)
1575  --with-system-libmpdec  build _decimal module using an installed libmpdec
1576                          library, see Doc/library/decimal.rst (default is no)
1577  --with-decimal-contextvar
1578                          build _decimal module using a coroutine-local rather
1579                          than a thread-local context (default is yes)
1580  --with-tcltk-includes='-I...'
1581                          override search for Tcl and Tk include files
1582  --with-tcltk-libs='-L...'
1583                          override search for Tcl and Tk libs
1584  --with-dbmliborder=db1:db2:...
1585                          override order to check db backends for dbm; a valid
1586                          value is a colon separated string with the backend
1587                          names `ndbm', `gdbm' and `bdb'.
1588  --with-doc-strings      enable documentation strings (default is yes)
1589  --with-pymalloc         enable specialized mallocs (default is yes)
1590  --with-c-locale-coercion
1591                          enable C locale coercion to a UTF-8 based locale
1592                          (default is yes)
1593  --with-valgrind         enable Valgrind support (default is no)
1594  --with-dtrace           enable DTrace support (default is no)
1595  --with-libm=STRING      override libm math library to STRING (default is
1596                          system-dependent)
1597  --with-libc=STRING      override libc C library to STRING (default is
1598                          system-dependent)
1599  --with-platlibdir=DIRNAME
1600                          Python library directory name (default is "lib")
1601  --with-wheel-pkg-dir=PATH
1602                          Directory of wheel packages used by ensurepip
1603                          (default: none)
1604  --with(out)-readline[=editline]
1605                          use Editline for backend or disable readline module
1606  --with-computed-gotos   enable computed gotos in evaluation loop (enabled by
1607                          default on supported compilers)
1608  --with-ensurepip[=install|upgrade|no]
1609                          "install" or "upgrade" using bundled pip (default is
1610                          upgrade)
1611  --with-openssl=DIR      root of the OpenSSL directory
1612  --with-openssl-rpath=[DIR|auto|no]
1613                          Set runtime library directory (rpath) for OpenSSL
1614                          libraries, no (default): don't set rpath, auto:
1615                          auto-detect rpath from --with-openssl and
1616                          pkg-config, DIR: set an explicit rpath
1617  --with-ssl-default-suites=[python|openssl|STRING]
1618                          override default cipher suites string, python: use
1619                          Python's preferred selection (default), openssl:
1620                          leave OpenSSL's defaults untouched, STRING: use a
1621                          custom string, python and STRING also set TLS 1.2 as
1622                          minimum TLS version
1623  --with-builtin-hashlib-hashes=md5,sha1,sha256,sha512,sha3,blake2
1624                          builtin hash modules, md5, sha1, sha256, sha512,
1625                          sha3 (with shake), blake2
1626  --with-experimental-isolated-subinterpreters
1627                          better isolate subinterpreters, experimental build
1628                          mode (default is no)
1629  --without-static-libpython
1630                          do not build libpythonMAJOR.MINOR.a and do not
1631                          install python.o (default is yes)
1632
1633Some influential environment variables:
1634  MACHDEP     name for machine-dependent library files
1635  CC          C compiler command
1636  CFLAGS      C compiler flags
1637  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1638              nonstandard directory <lib dir>
1639  LIBS        libraries to pass to the linker, e.g. -l<library>
1640  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1641              you have headers in a nonstandard directory <include dir>
1642  CPP         C preprocessor
1643  PROFILE_TASK
1644              Python args for PGO generation task
1645  PKG_CONFIG  path to pkg-config utility
1646  PKG_CONFIG_PATH
1647              directories to add to pkg-config's search path
1648  PKG_CONFIG_LIBDIR
1649              path overriding pkg-config's built-in search path
1650
1651Use these variables to override the choices made by `configure' or to help
1652it to find libraries and programs with nonstandard names/locations.
1653
1654Report bugs to <https://bugs.python.org/>.
1655_ACEOF
1656ac_status=$?
1657fi
1658
1659if test "$ac_init_help" = "recursive"; then
1660  # If there are subdirs, report their specific --help.
1661  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1662    test -d "$ac_dir" ||
1663      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1664      continue
1665    ac_builddir=.
1666
1667case "$ac_dir" in
1668.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1669*)
1670  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1671  # A ".." for each directory in $ac_dir_suffix.
1672  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1673  case $ac_top_builddir_sub in
1674  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1675  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1676  esac ;;
1677esac
1678ac_abs_top_builddir=$ac_pwd
1679ac_abs_builddir=$ac_pwd$ac_dir_suffix
1680# for backward compatibility:
1681ac_top_builddir=$ac_top_build_prefix
1682
1683case $srcdir in
1684  .)  # We are building in place.
1685    ac_srcdir=.
1686    ac_top_srcdir=$ac_top_builddir_sub
1687    ac_abs_top_srcdir=$ac_pwd ;;
1688  [\\/]* | ?:[\\/]* )  # Absolute name.
1689    ac_srcdir=$srcdir$ac_dir_suffix;
1690    ac_top_srcdir=$srcdir
1691    ac_abs_top_srcdir=$srcdir ;;
1692  *) # Relative name.
1693    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1694    ac_top_srcdir=$ac_top_build_prefix$srcdir
1695    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1696esac
1697ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1698
1699    cd "$ac_dir" || { ac_status=$?; continue; }
1700    # Check for guested configure.
1701    if test -f "$ac_srcdir/configure.gnu"; then
1702      echo &&
1703      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1704    elif test -f "$ac_srcdir/configure"; then
1705      echo &&
1706      $SHELL "$ac_srcdir/configure" --help=recursive
1707    else
1708      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1709    fi || ac_status=$?
1710    cd "$ac_pwd" || { ac_status=$?; break; }
1711  done
1712fi
1713
1714test -n "$ac_init_help" && exit $ac_status
1715if $ac_init_version; then
1716  cat <<\_ACEOF
1717python configure 3.10
1718generated by GNU Autoconf 2.69
1719
1720Copyright (C) 2012 Free Software Foundation, Inc.
1721This configure script is free software; the Free Software Foundation
1722gives unlimited permission to copy, distribute and modify it.
1723_ACEOF
1724  exit
1725fi
1726
1727## ------------------------ ##
1728## Autoconf initialization. ##
1729## ------------------------ ##
1730
1731# ac_fn_c_try_compile LINENO
1732# --------------------------
1733# Try to compile conftest.$ac_ext, and return whether this succeeded.
1734ac_fn_c_try_compile ()
1735{
1736  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1737  rm -f conftest.$ac_objext
1738  if { { ac_try="$ac_compile"
1739case "(($ac_try" in
1740  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1741  *) ac_try_echo=$ac_try;;
1742esac
1743eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1744$as_echo "$ac_try_echo"; } >&5
1745  (eval "$ac_compile") 2>conftest.err
1746  ac_status=$?
1747  if test -s conftest.err; then
1748    grep -v '^ *+' conftest.err >conftest.er1
1749    cat conftest.er1 >&5
1750    mv -f conftest.er1 conftest.err
1751  fi
1752  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1753  test $ac_status = 0; } && {
1754	 test -z "$ac_c_werror_flag" ||
1755	 test ! -s conftest.err
1756       } && test -s conftest.$ac_objext; then :
1757  ac_retval=0
1758else
1759  $as_echo "$as_me: failed program was:" >&5
1760sed 's/^/| /' conftest.$ac_ext >&5
1761
1762	ac_retval=1
1763fi
1764  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1765  as_fn_set_status $ac_retval
1766
1767} # ac_fn_c_try_compile
1768
1769# ac_fn_c_try_cpp LINENO
1770# ----------------------
1771# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1772ac_fn_c_try_cpp ()
1773{
1774  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1775  if { { ac_try="$ac_cpp conftest.$ac_ext"
1776case "(($ac_try" in
1777  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1778  *) ac_try_echo=$ac_try;;
1779esac
1780eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1781$as_echo "$ac_try_echo"; } >&5
1782  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1783  ac_status=$?
1784  if test -s conftest.err; then
1785    grep -v '^ *+' conftest.err >conftest.er1
1786    cat conftest.er1 >&5
1787    mv -f conftest.er1 conftest.err
1788  fi
1789  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1790  test $ac_status = 0; } > conftest.i && {
1791	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1792	 test ! -s conftest.err
1793       }; then :
1794  ac_retval=0
1795else
1796  $as_echo "$as_me: failed program was:" >&5
1797sed 's/^/| /' conftest.$ac_ext >&5
1798
1799    ac_retval=1
1800fi
1801  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1802  as_fn_set_status $ac_retval
1803
1804} # ac_fn_c_try_cpp
1805
1806# ac_fn_c_try_link LINENO
1807# -----------------------
1808# Try to link conftest.$ac_ext, and return whether this succeeded.
1809ac_fn_c_try_link ()
1810{
1811  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1812  rm -f conftest.$ac_objext conftest$ac_exeext
1813  if { { ac_try="$ac_link"
1814case "(($ac_try" in
1815  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1816  *) ac_try_echo=$ac_try;;
1817esac
1818eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1819$as_echo "$ac_try_echo"; } >&5
1820  (eval "$ac_link") 2>conftest.err
1821  ac_status=$?
1822  if test -s conftest.err; then
1823    grep -v '^ *+' conftest.err >conftest.er1
1824    cat conftest.er1 >&5
1825    mv -f conftest.er1 conftest.err
1826  fi
1827  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1828  test $ac_status = 0; } && {
1829	 test -z "$ac_c_werror_flag" ||
1830	 test ! -s conftest.err
1831       } && test -s conftest$ac_exeext && {
1832	 test "$cross_compiling" = yes ||
1833	 test -x conftest$ac_exeext
1834       }; then :
1835  ac_retval=0
1836else
1837  $as_echo "$as_me: failed program was:" >&5
1838sed 's/^/| /' conftest.$ac_ext >&5
1839
1840	ac_retval=1
1841fi
1842  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1843  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1844  # interfere with the next link command; also delete a directory that is
1845  # left behind by Apple's compiler.  We do this before executing the actions.
1846  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1847  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1848  as_fn_set_status $ac_retval
1849
1850} # ac_fn_c_try_link
1851
1852# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1853# -------------------------------------------------------
1854# Tests whether HEADER exists, giving a warning if it cannot be compiled using
1855# the include files in INCLUDES and setting the cache variable VAR
1856# accordingly.
1857ac_fn_c_check_header_mongrel ()
1858{
1859  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1860  if eval \${$3+:} false; then :
1861  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1862$as_echo_n "checking for $2... " >&6; }
1863if eval \${$3+:} false; then :
1864  $as_echo_n "(cached) " >&6
1865fi
1866eval ac_res=\$$3
1867	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1868$as_echo "$ac_res" >&6; }
1869else
1870  # Is the header compilable?
1871{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1872$as_echo_n "checking $2 usability... " >&6; }
1873cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1874/* end confdefs.h.  */
1875$4
1876#include <$2>
1877_ACEOF
1878if ac_fn_c_try_compile "$LINENO"; then :
1879  ac_header_compiler=yes
1880else
1881  ac_header_compiler=no
1882fi
1883rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1884{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1885$as_echo "$ac_header_compiler" >&6; }
1886
1887# Is the header present?
1888{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1889$as_echo_n "checking $2 presence... " >&6; }
1890cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1891/* end confdefs.h.  */
1892#include <$2>
1893_ACEOF
1894if ac_fn_c_try_cpp "$LINENO"; then :
1895  ac_header_preproc=yes
1896else
1897  ac_header_preproc=no
1898fi
1899rm -f conftest.err conftest.i conftest.$ac_ext
1900{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1901$as_echo "$ac_header_preproc" >&6; }
1902
1903# So?  What about this header?
1904case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1905  yes:no: )
1906    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1907$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1908    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1909$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1910    ;;
1911  no:yes:* )
1912    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1913$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1914    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1915$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1916    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1917$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1918    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1919$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1920    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1921$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1922( $as_echo "## --------------------------------------- ##
1923## Report this to https://bugs.python.org/ ##
1924## --------------------------------------- ##"
1925     ) | sed "s/^/$as_me: WARNING:     /" >&2
1926    ;;
1927esac
1928  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1929$as_echo_n "checking for $2... " >&6; }
1930if eval \${$3+:} false; then :
1931  $as_echo_n "(cached) " >&6
1932else
1933  eval "$3=\$ac_header_compiler"
1934fi
1935eval ac_res=\$$3
1936	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1937$as_echo "$ac_res" >&6; }
1938fi
1939  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1940
1941} # ac_fn_c_check_header_mongrel
1942
1943# ac_fn_c_try_run LINENO
1944# ----------------------
1945# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1946# that executables *can* be run.
1947ac_fn_c_try_run ()
1948{
1949  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1950  if { { ac_try="$ac_link"
1951case "(($ac_try" in
1952  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1953  *) ac_try_echo=$ac_try;;
1954esac
1955eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1956$as_echo "$ac_try_echo"; } >&5
1957  (eval "$ac_link") 2>&5
1958  ac_status=$?
1959  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1960  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1961  { { case "(($ac_try" in
1962  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1963  *) ac_try_echo=$ac_try;;
1964esac
1965eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1966$as_echo "$ac_try_echo"; } >&5
1967  (eval "$ac_try") 2>&5
1968  ac_status=$?
1969  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1970  test $ac_status = 0; }; }; then :
1971  ac_retval=0
1972else
1973  $as_echo "$as_me: program exited with status $ac_status" >&5
1974       $as_echo "$as_me: failed program was:" >&5
1975sed 's/^/| /' conftest.$ac_ext >&5
1976
1977       ac_retval=$ac_status
1978fi
1979  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1980  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1981  as_fn_set_status $ac_retval
1982
1983} # ac_fn_c_try_run
1984
1985# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1986# -------------------------------------------------------
1987# Tests whether HEADER exists and can be compiled using the include files in
1988# INCLUDES, setting the cache variable VAR accordingly.
1989ac_fn_c_check_header_compile ()
1990{
1991  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1992  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1993$as_echo_n "checking for $2... " >&6; }
1994if eval \${$3+:} false; then :
1995  $as_echo_n "(cached) " >&6
1996else
1997  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1998/* end confdefs.h.  */
1999$4
2000#include <$2>
2001_ACEOF
2002if ac_fn_c_try_compile "$LINENO"; then :
2003  eval "$3=yes"
2004else
2005  eval "$3=no"
2006fi
2007rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2008fi
2009eval ac_res=\$$3
2010	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2011$as_echo "$ac_res" >&6; }
2012  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2013
2014} # ac_fn_c_check_header_compile
2015
2016# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2017# -------------------------------------------
2018# Tests whether TYPE exists after having included INCLUDES, setting cache
2019# variable VAR accordingly.
2020ac_fn_c_check_type ()
2021{
2022  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2023  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2024$as_echo_n "checking for $2... " >&6; }
2025if eval \${$3+:} false; then :
2026  $as_echo_n "(cached) " >&6
2027else
2028  eval "$3=no"
2029  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2030/* end confdefs.h.  */
2031$4
2032int
2033main ()
2034{
2035if (sizeof ($2))
2036	 return 0;
2037  ;
2038  return 0;
2039}
2040_ACEOF
2041if ac_fn_c_try_compile "$LINENO"; then :
2042  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2043/* end confdefs.h.  */
2044$4
2045int
2046main ()
2047{
2048if (sizeof (($2)))
2049	    return 0;
2050  ;
2051  return 0;
2052}
2053_ACEOF
2054if ac_fn_c_try_compile "$LINENO"; then :
2055
2056else
2057  eval "$3=yes"
2058fi
2059rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2060fi
2061rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2062fi
2063eval ac_res=\$$3
2064	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2065$as_echo "$ac_res" >&6; }
2066  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2067
2068} # ac_fn_c_check_type
2069
2070# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2071# --------------------------------------------
2072# Tries to find the compile-time value of EXPR in a program that includes
2073# INCLUDES, setting VAR accordingly. Returns whether the value could be
2074# computed
2075ac_fn_c_compute_int ()
2076{
2077  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2078  if test "$cross_compiling" = yes; then
2079    # Depending upon the size, compute the lo and hi bounds.
2080cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2081/* end confdefs.h.  */
2082$4
2083int
2084main ()
2085{
2086static int test_array [1 - 2 * !(($2) >= 0)];
2087test_array [0] = 0;
2088return test_array [0];
2089
2090  ;
2091  return 0;
2092}
2093_ACEOF
2094if ac_fn_c_try_compile "$LINENO"; then :
2095  ac_lo=0 ac_mid=0
2096  while :; do
2097    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2098/* end confdefs.h.  */
2099$4
2100int
2101main ()
2102{
2103static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2104test_array [0] = 0;
2105return test_array [0];
2106
2107  ;
2108  return 0;
2109}
2110_ACEOF
2111if ac_fn_c_try_compile "$LINENO"; then :
2112  ac_hi=$ac_mid; break
2113else
2114  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2115			if test $ac_lo -le $ac_mid; then
2116			  ac_lo= ac_hi=
2117			  break
2118			fi
2119			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2120fi
2121rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2122  done
2123else
2124  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2125/* end confdefs.h.  */
2126$4
2127int
2128main ()
2129{
2130static int test_array [1 - 2 * !(($2) < 0)];
2131test_array [0] = 0;
2132return test_array [0];
2133
2134  ;
2135  return 0;
2136}
2137_ACEOF
2138if ac_fn_c_try_compile "$LINENO"; then :
2139  ac_hi=-1 ac_mid=-1
2140  while :; do
2141    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2142/* end confdefs.h.  */
2143$4
2144int
2145main ()
2146{
2147static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2148test_array [0] = 0;
2149return test_array [0];
2150
2151  ;
2152  return 0;
2153}
2154_ACEOF
2155if ac_fn_c_try_compile "$LINENO"; then :
2156  ac_lo=$ac_mid; break
2157else
2158  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2159			if test $ac_mid -le $ac_hi; then
2160			  ac_lo= ac_hi=
2161			  break
2162			fi
2163			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2164fi
2165rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2166  done
2167else
2168  ac_lo= ac_hi=
2169fi
2170rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2171fi
2172rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2173# Binary search between lo and hi bounds.
2174while test "x$ac_lo" != "x$ac_hi"; do
2175  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2176  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2177/* end confdefs.h.  */
2178$4
2179int
2180main ()
2181{
2182static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2183test_array [0] = 0;
2184return test_array [0];
2185
2186  ;
2187  return 0;
2188}
2189_ACEOF
2190if ac_fn_c_try_compile "$LINENO"; then :
2191  ac_hi=$ac_mid
2192else
2193  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2194fi
2195rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2196done
2197case $ac_lo in #((
2198?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2199'') ac_retval=1 ;;
2200esac
2201  else
2202    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2203/* end confdefs.h.  */
2204$4
2205static long int longval () { return $2; }
2206static unsigned long int ulongval () { return $2; }
2207#include <stdio.h>
2208#include <stdlib.h>
2209int
2210main ()
2211{
2212
2213  FILE *f = fopen ("conftest.val", "w");
2214  if (! f)
2215    return 1;
2216  if (($2) < 0)
2217    {
2218      long int i = longval ();
2219      if (i != ($2))
2220	return 1;
2221      fprintf (f, "%ld", i);
2222    }
2223  else
2224    {
2225      unsigned long int i = ulongval ();
2226      if (i != ($2))
2227	return 1;
2228      fprintf (f, "%lu", i);
2229    }
2230  /* Do not output a trailing newline, as this causes \r\n confusion
2231     on some platforms.  */
2232  return ferror (f) || fclose (f) != 0;
2233
2234  ;
2235  return 0;
2236}
2237_ACEOF
2238if ac_fn_c_try_run "$LINENO"; then :
2239  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2240else
2241  ac_retval=1
2242fi
2243rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2244  conftest.$ac_objext conftest.beam conftest.$ac_ext
2245rm -f conftest.val
2246
2247  fi
2248  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2249  as_fn_set_status $ac_retval
2250
2251} # ac_fn_c_compute_int
2252
2253# ac_fn_c_check_func LINENO FUNC VAR
2254# ----------------------------------
2255# Tests whether FUNC exists, setting the cache variable VAR accordingly
2256ac_fn_c_check_func ()
2257{
2258  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2259  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2260$as_echo_n "checking for $2... " >&6; }
2261if eval \${$3+:} false; then :
2262  $as_echo_n "(cached) " >&6
2263else
2264  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2265/* end confdefs.h.  */
2266/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2267   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2268#define $2 innocuous_$2
2269
2270/* System header to define __stub macros and hopefully few prototypes,
2271    which can conflict with char $2 (); below.
2272    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2273    <limits.h> exists even on freestanding compilers.  */
2274
2275#ifdef __STDC__
2276# include <limits.h>
2277#else
2278# include <assert.h>
2279#endif
2280
2281#undef $2
2282
2283/* Override any GCC internal prototype to avoid an error.
2284   Use char because int might match the return type of a GCC
2285   builtin and then its argument prototype would still apply.  */
2286#ifdef __cplusplus
2287extern "C"
2288#endif
2289char $2 ();
2290/* The GNU C library defines this for functions which it implements
2291    to always fail with ENOSYS.  Some functions are actually named
2292    something starting with __ and the normal name is an alias.  */
2293#if defined __stub_$2 || defined __stub___$2
2294choke me
2295#endif
2296
2297int
2298main ()
2299{
2300return $2 ();
2301  ;
2302  return 0;
2303}
2304_ACEOF
2305if ac_fn_c_try_link "$LINENO"; then :
2306  eval "$3=yes"
2307else
2308  eval "$3=no"
2309fi
2310rm -f core conftest.err conftest.$ac_objext \
2311    conftest$ac_exeext conftest.$ac_ext
2312fi
2313eval ac_res=\$$3
2314	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2315$as_echo "$ac_res" >&6; }
2316  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2317
2318} # ac_fn_c_check_func
2319
2320# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2321# ---------------------------------------------
2322# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2323# accordingly.
2324ac_fn_c_check_decl ()
2325{
2326  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2327  as_decl_name=`echo $2|sed 's/ *(.*//'`
2328  as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2329  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2330$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2331if eval \${$3+:} false; then :
2332  $as_echo_n "(cached) " >&6
2333else
2334  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2335/* end confdefs.h.  */
2336$4
2337int
2338main ()
2339{
2340#ifndef $as_decl_name
2341#ifdef __cplusplus
2342  (void) $as_decl_use;
2343#else
2344  (void) $as_decl_name;
2345#endif
2346#endif
2347
2348  ;
2349  return 0;
2350}
2351_ACEOF
2352if ac_fn_c_try_compile "$LINENO"; then :
2353  eval "$3=yes"
2354else
2355  eval "$3=no"
2356fi
2357rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2358fi
2359eval ac_res=\$$3
2360	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2361$as_echo "$ac_res" >&6; }
2362  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2363
2364} # ac_fn_c_check_decl
2365
2366# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2367# ----------------------------------------------------
2368# Tries to find if the field MEMBER exists in type AGGR, after including
2369# INCLUDES, setting cache variable VAR accordingly.
2370ac_fn_c_check_member ()
2371{
2372  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2373  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2374$as_echo_n "checking for $2.$3... " >&6; }
2375if eval \${$4+:} false; then :
2376  $as_echo_n "(cached) " >&6
2377else
2378  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2379/* end confdefs.h.  */
2380$5
2381int
2382main ()
2383{
2384static $2 ac_aggr;
2385if (ac_aggr.$3)
2386return 0;
2387  ;
2388  return 0;
2389}
2390_ACEOF
2391if ac_fn_c_try_compile "$LINENO"; then :
2392  eval "$4=yes"
2393else
2394  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2395/* end confdefs.h.  */
2396$5
2397int
2398main ()
2399{
2400static $2 ac_aggr;
2401if (sizeof ac_aggr.$3)
2402return 0;
2403  ;
2404  return 0;
2405}
2406_ACEOF
2407if ac_fn_c_try_compile "$LINENO"; then :
2408  eval "$4=yes"
2409else
2410  eval "$4=no"
2411fi
2412rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2413fi
2414rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2415fi
2416eval ac_res=\$$4
2417	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2418$as_echo "$ac_res" >&6; }
2419  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2420
2421} # ac_fn_c_check_member
2422cat >config.log <<_ACEOF
2423This file contains any messages produced by compilers while
2424running configure, to aid debugging if configure makes a mistake.
2425
2426It was created by python $as_me 3.10, which was
2427generated by GNU Autoconf 2.69.  Invocation command line was
2428
2429  $ $0 $@
2430
2431_ACEOF
2432exec 5>>config.log
2433{
2434cat <<_ASUNAME
2435## --------- ##
2436## Platform. ##
2437## --------- ##
2438
2439hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2440uname -m = `(uname -m) 2>/dev/null || echo unknown`
2441uname -r = `(uname -r) 2>/dev/null || echo unknown`
2442uname -s = `(uname -s) 2>/dev/null || echo unknown`
2443uname -v = `(uname -v) 2>/dev/null || echo unknown`
2444
2445/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2446/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2447
2448/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2449/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2450/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2451/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2452/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2453/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2454/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2455
2456_ASUNAME
2457
2458as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2459for as_dir in $PATH
2460do
2461  IFS=$as_save_IFS
2462  test -z "$as_dir" && as_dir=.
2463    $as_echo "PATH: $as_dir"
2464  done
2465IFS=$as_save_IFS
2466
2467} >&5
2468
2469cat >&5 <<_ACEOF
2470
2471
2472## ----------- ##
2473## Core tests. ##
2474## ----------- ##
2475
2476_ACEOF
2477
2478
2479# Keep a trace of the command line.
2480# Strip out --no-create and --no-recursion so they do not pile up.
2481# Strip out --silent because we don't want to record it for future runs.
2482# Also quote any args containing shell meta-characters.
2483# Make two passes to allow for proper duplicate-argument suppression.
2484ac_configure_args=
2485ac_configure_args0=
2486ac_configure_args1=
2487ac_must_keep_next=false
2488for ac_pass in 1 2
2489do
2490  for ac_arg
2491  do
2492    case $ac_arg in
2493    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2494    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2495    | -silent | --silent | --silen | --sile | --sil)
2496      continue ;;
2497    *\'*)
2498      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2499    esac
2500    case $ac_pass in
2501    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2502    2)
2503      as_fn_append ac_configure_args1 " '$ac_arg'"
2504      if test $ac_must_keep_next = true; then
2505	ac_must_keep_next=false # Got value, back to normal.
2506      else
2507	case $ac_arg in
2508	  *=* | --config-cache | -C | -disable-* | --disable-* \
2509	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2510	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2511	  | -with-* | --with-* | -without-* | --without-* | --x)
2512	    case "$ac_configure_args0 " in
2513	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2514	    esac
2515	    ;;
2516	  -* ) ac_must_keep_next=true ;;
2517	esac
2518      fi
2519      as_fn_append ac_configure_args " '$ac_arg'"
2520      ;;
2521    esac
2522  done
2523done
2524{ ac_configure_args0=; unset ac_configure_args0;}
2525{ ac_configure_args1=; unset ac_configure_args1;}
2526
2527# When interrupted or exit'd, cleanup temporary files, and complete
2528# config.log.  We remove comments because anyway the quotes in there
2529# would cause problems or look ugly.
2530# WARNING: Use '\'' to represent an apostrophe within the trap.
2531# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2532trap 'exit_status=$?
2533  # Save into config.log some information that might help in debugging.
2534  {
2535    echo
2536
2537    $as_echo "## ---------------- ##
2538## Cache variables. ##
2539## ---------------- ##"
2540    echo
2541    # The following way of writing the cache mishandles newlines in values,
2542(
2543  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2544    eval ac_val=\$$ac_var
2545    case $ac_val in #(
2546    *${as_nl}*)
2547      case $ac_var in #(
2548      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2549$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2550      esac
2551      case $ac_var in #(
2552      _ | IFS | as_nl) ;; #(
2553      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2554      *) { eval $ac_var=; unset $ac_var;} ;;
2555      esac ;;
2556    esac
2557  done
2558  (set) 2>&1 |
2559    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2560    *${as_nl}ac_space=\ *)
2561      sed -n \
2562	"s/'\''/'\''\\\\'\'''\''/g;
2563	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2564      ;; #(
2565    *)
2566      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2567      ;;
2568    esac |
2569    sort
2570)
2571    echo
2572
2573    $as_echo "## ----------------- ##
2574## Output variables. ##
2575## ----------------- ##"
2576    echo
2577    for ac_var in $ac_subst_vars
2578    do
2579      eval ac_val=\$$ac_var
2580      case $ac_val in
2581      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2582      esac
2583      $as_echo "$ac_var='\''$ac_val'\''"
2584    done | sort
2585    echo
2586
2587    if test -n "$ac_subst_files"; then
2588      $as_echo "## ------------------- ##
2589## File substitutions. ##
2590## ------------------- ##"
2591      echo
2592      for ac_var in $ac_subst_files
2593      do
2594	eval ac_val=\$$ac_var
2595	case $ac_val in
2596	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2597	esac
2598	$as_echo "$ac_var='\''$ac_val'\''"
2599      done | sort
2600      echo
2601    fi
2602
2603    if test -s confdefs.h; then
2604      $as_echo "## ----------- ##
2605## confdefs.h. ##
2606## ----------- ##"
2607      echo
2608      cat confdefs.h
2609      echo
2610    fi
2611    test "$ac_signal" != 0 &&
2612      $as_echo "$as_me: caught signal $ac_signal"
2613    $as_echo "$as_me: exit $exit_status"
2614  } >&5
2615  rm -f core *.core core.conftest.* &&
2616    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2617    exit $exit_status
2618' 0
2619for ac_signal in 1 2 13 15; do
2620  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2621done
2622ac_signal=0
2623
2624# confdefs.h avoids OS command line length limits that DEFS can exceed.
2625rm -f -r conftest* confdefs.h
2626
2627$as_echo "/* confdefs.h */" > confdefs.h
2628
2629# Predefined preprocessor variables.
2630
2631cat >>confdefs.h <<_ACEOF
2632#define PACKAGE_NAME "$PACKAGE_NAME"
2633_ACEOF
2634
2635cat >>confdefs.h <<_ACEOF
2636#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2637_ACEOF
2638
2639cat >>confdefs.h <<_ACEOF
2640#define PACKAGE_VERSION "$PACKAGE_VERSION"
2641_ACEOF
2642
2643cat >>confdefs.h <<_ACEOF
2644#define PACKAGE_STRING "$PACKAGE_STRING"
2645_ACEOF
2646
2647cat >>confdefs.h <<_ACEOF
2648#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2649_ACEOF
2650
2651cat >>confdefs.h <<_ACEOF
2652#define PACKAGE_URL "$PACKAGE_URL"
2653_ACEOF
2654
2655
2656# Let the site file select an alternate cache file if it wants to.
2657# Prefer an explicitly selected file to automatically selected ones.
2658ac_site_file1=NONE
2659ac_site_file2=NONE
2660if test -n "$CONFIG_SITE"; then
2661  # We do not want a PATH search for config.site.
2662  case $CONFIG_SITE in #((
2663    -*)  ac_site_file1=./$CONFIG_SITE;;
2664    */*) ac_site_file1=$CONFIG_SITE;;
2665    *)   ac_site_file1=./$CONFIG_SITE;;
2666  esac
2667elif test "x$prefix" != xNONE; then
2668  ac_site_file1=$prefix/share/config.site
2669  ac_site_file2=$prefix/etc/config.site
2670else
2671  ac_site_file1=$ac_default_prefix/share/config.site
2672  ac_site_file2=$ac_default_prefix/etc/config.site
2673fi
2674for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2675do
2676  test "x$ac_site_file" = xNONE && continue
2677  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2678    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2679$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2680    sed 's/^/| /' "$ac_site_file" >&5
2681    . "$ac_site_file" \
2682      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2683$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2684as_fn_error $? "failed to load site script $ac_site_file
2685See \`config.log' for more details" "$LINENO" 5; }
2686  fi
2687done
2688
2689if test -r "$cache_file"; then
2690  # Some versions of bash will fail to source /dev/null (special files
2691  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2692  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2693    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2694$as_echo "$as_me: loading cache $cache_file" >&6;}
2695    case $cache_file in
2696      [\\/]* | ?:[\\/]* ) . "$cache_file";;
2697      *)                      . "./$cache_file";;
2698    esac
2699  fi
2700else
2701  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2702$as_echo "$as_me: creating cache $cache_file" >&6;}
2703  >$cache_file
2704fi
2705
2706# Check that the precious variables saved in the cache have kept the same
2707# value.
2708ac_cache_corrupted=false
2709for ac_var in $ac_precious_vars; do
2710  eval ac_old_set=\$ac_cv_env_${ac_var}_set
2711  eval ac_new_set=\$ac_env_${ac_var}_set
2712  eval ac_old_val=\$ac_cv_env_${ac_var}_value
2713  eval ac_new_val=\$ac_env_${ac_var}_value
2714  case $ac_old_set,$ac_new_set in
2715    set,)
2716      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2717$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2718      ac_cache_corrupted=: ;;
2719    ,set)
2720      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2721$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2722      ac_cache_corrupted=: ;;
2723    ,);;
2724    *)
2725      if test "x$ac_old_val" != "x$ac_new_val"; then
2726	# differences in whitespace do not lead to failure.
2727	ac_old_val_w=`echo x $ac_old_val`
2728	ac_new_val_w=`echo x $ac_new_val`
2729	if test "$ac_old_val_w" != "$ac_new_val_w"; then
2730	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2731$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2732	  ac_cache_corrupted=:
2733	else
2734	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2735$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2736	  eval $ac_var=\$ac_old_val
2737	fi
2738	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2739$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2740	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2741$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2742      fi;;
2743  esac
2744  # Pass precious variables to config.status.
2745  if test "$ac_new_set" = set; then
2746    case $ac_new_val in
2747    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2748    *) ac_arg=$ac_var=$ac_new_val ;;
2749    esac
2750    case " $ac_configure_args " in
2751      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2752      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2753    esac
2754  fi
2755done
2756if $ac_cache_corrupted; then
2757  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2758$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2759  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2760$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2761  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2762fi
2763## -------------------- ##
2764## Main body of script. ##
2765## -------------------- ##
2766
2767ac_ext=c
2768ac_cpp='$CPP $CPPFLAGS'
2769ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2770ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2771ac_compiler_gnu=$ac_cv_c_compiler_gnu
2772
2773
2774
2775
2776
2777
2778if test "$srcdir" != . -a "$srcdir" != "$(pwd)"; then
2779    # If we're building out-of-tree, we need to make sure the following
2780    # resources get picked up before their $srcdir counterparts.
2781    #   Objects/ -> typeslots.inc
2782    #   Include/ -> Python.h
2783    #   Python/  -> importlib.h
2784    # (A side effect of this is that these resources will automatically be
2785    #  regenerated when building out-of-tree, regardless of whether or not
2786    #  the $srcdir counterpart is up-to-date.  This is an acceptable trade
2787    #  off.)
2788    BASECPPFLAGS="-IObjects -IInclude -IPython"
2789else
2790    BASECPPFLAGS=""
2791fi
2792
2793
2794
2795
2796
2797if test -e $srcdir/.git
2798then
2799# Extract the first word of "git", so it can be a program name with args.
2800set dummy git; ac_word=$2
2801{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2802$as_echo_n "checking for $ac_word... " >&6; }
2803if ${ac_cv_prog_HAS_GIT+:} false; then :
2804  $as_echo_n "(cached) " >&6
2805else
2806  if test -n "$HAS_GIT"; then
2807  ac_cv_prog_HAS_GIT="$HAS_GIT" # Let the user override the test.
2808else
2809as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2810for as_dir in $PATH
2811do
2812  IFS=$as_save_IFS
2813  test -z "$as_dir" && as_dir=.
2814    for ac_exec_ext in '' $ac_executable_extensions; do
2815  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2816    ac_cv_prog_HAS_GIT="found"
2817    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2818    break 2
2819  fi
2820done
2821  done
2822IFS=$as_save_IFS
2823
2824  test -z "$ac_cv_prog_HAS_GIT" && ac_cv_prog_HAS_GIT="not-found"
2825fi
2826fi
2827HAS_GIT=$ac_cv_prog_HAS_GIT
2828if test -n "$HAS_GIT"; then
2829  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAS_GIT" >&5
2830$as_echo "$HAS_GIT" >&6; }
2831else
2832  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2833$as_echo "no" >&6; }
2834fi
2835
2836
2837else
2838HAS_GIT=no-repository
2839fi
2840if test $HAS_GIT = found
2841then
2842    GITVERSION="git --git-dir \$(srcdir)/.git rev-parse --short HEAD"
2843    GITTAG="git --git-dir \$(srcdir)/.git describe --all --always --dirty"
2844    GITBRANCH="git --git-dir \$(srcdir)/.git name-rev --name-only HEAD"
2845else
2846    GITVERSION=""
2847    GITTAG=""
2848    GITBRANCH=""
2849fi
2850
2851
2852ac_config_headers="$ac_config_headers pyconfig.h"
2853
2854
2855ac_aux_dir=
2856for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2857  if test -f "$ac_dir/install-sh"; then
2858    ac_aux_dir=$ac_dir
2859    ac_install_sh="$ac_aux_dir/install-sh -c"
2860    break
2861  elif test -f "$ac_dir/install.sh"; then
2862    ac_aux_dir=$ac_dir
2863    ac_install_sh="$ac_aux_dir/install.sh -c"
2864    break
2865  elif test -f "$ac_dir/shtool"; then
2866    ac_aux_dir=$ac_dir
2867    ac_install_sh="$ac_aux_dir/shtool install -c"
2868    break
2869  fi
2870done
2871if test -z "$ac_aux_dir"; then
2872  as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
2873fi
2874
2875# These three variables are undocumented and unsupported,
2876# and are intended to be withdrawn in a future Autoconf release.
2877# They can cause serious problems if a builder's source tree is in a directory
2878# whose full name contains unusual characters.
2879ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2880ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2881ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2882
2883
2884# Make sure we can run config.sub.
2885$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2886  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2887
2888{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2889$as_echo_n "checking build system type... " >&6; }
2890if ${ac_cv_build+:} false; then :
2891  $as_echo_n "(cached) " >&6
2892else
2893  ac_build_alias=$build_alias
2894test "x$ac_build_alias" = x &&
2895  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2896test "x$ac_build_alias" = x &&
2897  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2898ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2899  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2900
2901fi
2902{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2903$as_echo "$ac_cv_build" >&6; }
2904case $ac_cv_build in
2905*-*-*) ;;
2906*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2907esac
2908build=$ac_cv_build
2909ac_save_IFS=$IFS; IFS='-'
2910set x $ac_cv_build
2911shift
2912build_cpu=$1
2913build_vendor=$2
2914shift; shift
2915# Remember, the first character of IFS is used to create $*,
2916# except with old shells:
2917build_os=$*
2918IFS=$ac_save_IFS
2919case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2920
2921
2922{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2923$as_echo_n "checking host system type... " >&6; }
2924if ${ac_cv_host+:} false; then :
2925  $as_echo_n "(cached) " >&6
2926else
2927  if test "x$host_alias" = x; then
2928  ac_cv_host=$ac_cv_build
2929else
2930  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2931    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2932fi
2933
2934fi
2935{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2936$as_echo "$ac_cv_host" >&6; }
2937case $ac_cv_host in
2938*-*-*) ;;
2939*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2940esac
2941host=$ac_cv_host
2942ac_save_IFS=$IFS; IFS='-'
2943set x $ac_cv_host
2944shift
2945host_cpu=$1
2946host_vendor=$2
2947shift; shift
2948# Remember, the first character of IFS is used to create $*,
2949# except with old shells:
2950host_os=$*
2951IFS=$ac_save_IFS
2952case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2953
2954
2955
2956
2957
2958# pybuilddir.txt will be created by --generate-posix-vars in the Makefile
2959rm -f pybuilddir.txt
2960
2961for ac_prog in python$PACKAGE_VERSION python3 python
2962do
2963  # Extract the first word of "$ac_prog", so it can be a program name with args.
2964set dummy $ac_prog; ac_word=$2
2965{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2966$as_echo_n "checking for $ac_word... " >&6; }
2967if ${ac_cv_prog_PYTHON_FOR_REGEN+:} false; then :
2968  $as_echo_n "(cached) " >&6
2969else
2970  if test -n "$PYTHON_FOR_REGEN"; then
2971  ac_cv_prog_PYTHON_FOR_REGEN="$PYTHON_FOR_REGEN" # Let the user override the test.
2972else
2973as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2974for as_dir in $PATH
2975do
2976  IFS=$as_save_IFS
2977  test -z "$as_dir" && as_dir=.
2978    for ac_exec_ext in '' $ac_executable_extensions; do
2979  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2980    ac_cv_prog_PYTHON_FOR_REGEN="$ac_prog"
2981    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2982    break 2
2983  fi
2984done
2985  done
2986IFS=$as_save_IFS
2987
2988fi
2989fi
2990PYTHON_FOR_REGEN=$ac_cv_prog_PYTHON_FOR_REGEN
2991if test -n "$PYTHON_FOR_REGEN"; then
2992  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_FOR_REGEN" >&5
2993$as_echo "$PYTHON_FOR_REGEN" >&6; }
2994else
2995  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2996$as_echo "no" >&6; }
2997fi
2998
2999
3000  test -n "$PYTHON_FOR_REGEN" && break
3001done
3002test -n "$PYTHON_FOR_REGEN" || PYTHON_FOR_REGEN="python3"
3003
3004
3005
3006if test "$cross_compiling" = yes; then
3007    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python interpreter for cross build" >&5
3008$as_echo_n "checking for python interpreter for cross build... " >&6; }
3009    if test -z "$PYTHON_FOR_BUILD"; then
3010        for interp in python$PACKAGE_VERSION python3 python; do
3011	    which $interp >/dev/null 2>&1 || continue
3012	    if $interp -c "import sys;sys.exit(not '.'.join(str(n) for n in sys.version_info[:2]) == '$PACKAGE_VERSION')"; then
3013	        break
3014	    fi
3015            interp=
3016	done
3017        if test x$interp = x; then
3018	    as_fn_error $? "python$PACKAGE_VERSION interpreter not found" "$LINENO" 5
3019	fi
3020        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $interp" >&5
3021$as_echo "$interp" >&6; }
3022	PYTHON_FOR_BUILD='_PYTHON_PROJECT_BASE=$(abs_builddir) _PYTHON_HOST_PLATFORM=$(_PYTHON_HOST_PLATFORM) PYTHONPATH=$(shell test -f pybuilddir.txt && echo $(abs_builddir)/`cat pybuilddir.txt`:)$(srcdir)/Lib _PYTHON_SYSCONFIGDATA_NAME=_sysconfigdata_$(ABIFLAGS)_$(MACHDEP)_$(MULTIARCH) '$interp
3023    fi
3024elif test "$cross_compiling" = maybe; then
3025    as_fn_error $? "Cross compiling required --host=HOST-TUPLE and --build=ARCH" "$LINENO" 5
3026else
3027    PYTHON_FOR_BUILD='./$(BUILDPYTHON) -E'
3028fi
3029
3030
3031
3032if test "$prefix" != "/"; then
3033    prefix=`echo "$prefix" | sed -e 's/\/$//g'`
3034fi
3035
3036
3037
3038
3039# We don't use PACKAGE_ variables, and they cause conflicts
3040# with other autoconf-based packages that include Python.h
3041grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new
3042rm confdefs.h
3043mv confdefs.h.new confdefs.h
3044
3045
3046VERSION=3.10
3047
3048# Version number of Python's own shared library file.
3049
3050SOVERSION=1.0
3051
3052# The later defininition of _XOPEN_SOURCE disables certain features
3053# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
3054
3055$as_echo "#define _GNU_SOURCE 1" >>confdefs.h
3056
3057
3058# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
3059# certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable
3060# them.
3061
3062$as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
3063
3064
3065# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
3066# certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable
3067# them.
3068
3069$as_echo "#define __BSD_VISIBLE 1" >>confdefs.h
3070
3071
3072# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
3073# certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable
3074# them.
3075
3076$as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
3077
3078
3079
3080define_xopen_source=yes
3081
3082# Arguments passed to configure.
3083
3084CONFIG_ARGS="$ac_configure_args"
3085
3086{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5
3087$as_echo_n "checking for --enable-universalsdk... " >&6; }
3088# Check whether --enable-universalsdk was given.
3089if test "${enable_universalsdk+set}" = set; then :
3090  enableval=$enable_universalsdk;
3091	case $enableval in
3092	yes)
3093		# Locate the best usable SDK, see Mac/README for more
3094		# information
3095		enableval="`/usr/bin/xcodebuild -version -sdk macosx Path 2>/dev/null`"
3096		if ! ( echo $enableval | grep -E '\.sdk' 1>/dev/null )
3097		then
3098			enableval=/Developer/SDKs/MacOSX10.4u.sdk
3099			if test ! -d "${enableval}"
3100			then
3101				enableval=/
3102			fi
3103		fi
3104		;;
3105	esac
3106	case $enableval in
3107	no)
3108		UNIVERSALSDK=
3109		enable_universalsdk=
3110		;;
3111	*)
3112		UNIVERSALSDK=$enableval
3113		if test ! -d "${UNIVERSALSDK}"
3114		then
3115			as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5
3116		fi
3117		;;
3118	esac
3119
3120
3121else
3122
3123   	UNIVERSALSDK=
3124	enable_universalsdk=
3125
3126fi
3127
3128if test -n "${UNIVERSALSDK}"
3129then
3130	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5
3131$as_echo "${UNIVERSALSDK}" >&6; }
3132else
3133	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3134$as_echo "no" >&6; }
3135fi
3136
3137
3138
3139ARCH_RUN_32BIT=""
3140
3141# For backward compatibility reasons we prefer to select '32-bit' if available,
3142# otherwise use 'intel'
3143UNIVERSAL_ARCHS="32-bit"
3144if test "`uname -s`" = "Darwin"
3145then
3146	if test -n "${UNIVERSALSDK}"
3147	then
3148		if test -z "`/usr/bin/file -L "${UNIVERSALSDK}/usr/lib/libSystem.dylib" | grep ppc`"
3149		then
3150			UNIVERSAL_ARCHS="intel"
3151		fi
3152	fi
3153fi
3154
3155
3156
3157{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5
3158$as_echo_n "checking for --with-universal-archs... " >&6; }
3159
3160# Check whether --with-universal-archs was given.
3161if test "${with_universal_archs+set}" = set; then :
3162  withval=$with_universal_archs;
3163	UNIVERSAL_ARCHS="$withval"
3164
3165fi
3166
3167if test -n "${UNIVERSALSDK}"
3168then
3169	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSAL_ARCHS}" >&5
3170$as_echo "${UNIVERSAL_ARCHS}" >&6; }
3171else
3172	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3173$as_echo "no" >&6; }
3174fi
3175
3176
3177# Check whether --with-framework-name was given.
3178if test "${with_framework_name+set}" = set; then :
3179  withval=$with_framework_name;
3180    PYTHONFRAMEWORK=${withval}
3181    PYTHONFRAMEWORKDIR=${withval}.framework
3182    PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'`
3183
3184else
3185
3186    PYTHONFRAMEWORK=Python
3187    PYTHONFRAMEWORKDIR=Python.framework
3188    PYTHONFRAMEWORKIDENTIFIER=org.python.python
3189
3190fi
3191
3192# Check whether --enable-framework was given.
3193if test "${enable_framework+set}" = set; then :
3194  enableval=$enable_framework;
3195	case $enableval in
3196	yes)
3197		enableval=/Library/Frameworks
3198	esac
3199	case $enableval in
3200	no)
3201		PYTHONFRAMEWORK=
3202		PYTHONFRAMEWORKDIR=no-framework
3203		PYTHONFRAMEWORKPREFIX=
3204		PYTHONFRAMEWORKINSTALLDIR=
3205		FRAMEWORKINSTALLFIRST=
3206		FRAMEWORKINSTALLLAST=
3207		FRAMEWORKALTINSTALLFIRST=
3208		FRAMEWORKALTINSTALLLAST=
3209		FRAMEWORKPYTHONW=
3210		if test "x${prefix}" = "xNONE"; then
3211			FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
3212		else
3213			FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3214		fi
3215		enable_framework=
3216		;;
3217	*)
3218		PYTHONFRAMEWORKPREFIX="${enableval}"
3219		PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
3220		FRAMEWORKINSTALLFIRST="frameworkinstallstructure"
3221		FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure "
3222		FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools"
3223		FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools"
3224		FRAMEWORKPYTHONW="frameworkpythonw"
3225		FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3226
3227		if test "x${prefix}" = "xNONE" ; then
3228			FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
3229
3230		else
3231			FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3232		fi
3233
3234		case "${enableval}" in
3235		/System*)
3236			FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3237			if test "${prefix}" = "NONE" ; then
3238				# See below
3239				FRAMEWORKUNIXTOOLSPREFIX="/usr"
3240			fi
3241			;;
3242
3243		/Library*)
3244			FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3245			;;
3246
3247		*/Library/Frameworks)
3248			MDIR="`dirname "${enableval}"`"
3249			MDIR="`dirname "${MDIR}"`"
3250			FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications"
3251
3252			if test "${prefix}" = "NONE"; then
3253				# User hasn't specified the
3254				# --prefix option, but wants to install
3255				# the framework in a non-default location,
3256				# ensure that the compatibility links get
3257				# installed relative to that prefix as well
3258				# instead of in /usr/local.
3259				FRAMEWORKUNIXTOOLSPREFIX="${MDIR}"
3260			fi
3261			;;
3262
3263		*)
3264			FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3265			;;
3266		esac
3267
3268		prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
3269
3270		# Add files for Mac specific code to the list of output
3271		# files:
3272		ac_config_files="$ac_config_files Mac/Makefile"
3273
3274		ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile"
3275
3276		ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist"
3277
3278		ac_config_files="$ac_config_files Mac/Resources/app/Info.plist"
3279
3280	esac
3281
3282else
3283
3284	PYTHONFRAMEWORK=
3285	PYTHONFRAMEWORKDIR=no-framework
3286	PYTHONFRAMEWORKPREFIX=
3287	PYTHONFRAMEWORKINSTALLDIR=
3288	FRAMEWORKINSTALLFIRST=
3289	FRAMEWORKINSTALLLAST=
3290	FRAMEWORKALTINSTALLFIRST=
3291	FRAMEWORKALTINSTALLLAST=
3292	FRAMEWORKPYTHONW=
3293	if test "x${prefix}" = "xNONE" ; then
3294		FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
3295	else
3296		FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3297	fi
3298	enable_framework=
3299
3300
3301fi
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317cat >>confdefs.h <<_ACEOF
3318#define _PYTHONFRAMEWORK "${PYTHONFRAMEWORK}"
3319_ACEOF
3320
3321
3322##AC_ARG_WITH(dyld,
3323##            AS_HELP_STRING([--with-dyld],
3324##                           [use (OpenStep|Rhapsody) dynamic linker]))
3325##
3326# Set name for machine-dependent library files
3327
3328{ $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5
3329$as_echo_n "checking MACHDEP... " >&6; }
3330if test -z "$MACHDEP"
3331then
3332    # avoid using uname for cross builds
3333    if test "$cross_compiling" = yes; then
3334       # ac_sys_system and ac_sys_release are used for setting
3335       # a lot of different things including 'define_xopen_source'
3336       # in the case statement below.
3337	case "$host" in
3338	*-*-linux-android*)
3339		ac_sys_system=Linux-android
3340		;;
3341	*-*-linux*)
3342		ac_sys_system=Linux
3343		;;
3344	*-*-cygwin*)
3345		ac_sys_system=Cygwin
3346		;;
3347	*-*-vxworks*)
3348	    ac_sys_system=VxWorks
3349	    ;;
3350	*)
3351		# for now, limit cross builds to known configurations
3352		MACHDEP="unknown"
3353		as_fn_error $? "cross build not supported for $host" "$LINENO" 5
3354	esac
3355	ac_sys_release=
3356    else
3357	ac_sys_system=`uname -s`
3358	if test "$ac_sys_system" = "AIX" \
3359	-o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
3360		ac_sys_release=`uname -v`
3361	else
3362		ac_sys_release=`uname -r`
3363	fi
3364    fi
3365    ac_md_system=`echo $ac_sys_system |
3366			tr -d '/ ' | tr '[A-Z]' '[a-z]'`
3367    ac_md_release=`echo $ac_sys_release |
3368			tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
3369    MACHDEP="$ac_md_system$ac_md_release"
3370
3371    case $MACHDEP in
3372	aix*) MACHDEP="aix";;
3373	linux*) MACHDEP="linux";;
3374	cygwin*) MACHDEP="cygwin";;
3375	darwin*) MACHDEP="darwin";;
3376	'')	MACHDEP="unknown";;
3377    esac
3378fi
3379{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$MACHDEP\"" >&5
3380$as_echo "\"$MACHDEP\"" >&6; }
3381
3382
3383if test "$cross_compiling" = yes; then
3384	case "$host" in
3385	*-*-linux*)
3386		case "$host_cpu" in
3387		arm*)
3388			_host_cpu=arm
3389			;;
3390		*)
3391			_host_cpu=$host_cpu
3392		esac
3393		;;
3394	*-*-cygwin*)
3395		_host_cpu=
3396		;;
3397	*-*-vxworks*)
3398		_host_cpu=$host_cpu
3399		;;
3400	*)
3401		# for now, limit cross builds to known configurations
3402		MACHDEP="unknown"
3403		as_fn_error $? "cross build not supported for $host" "$LINENO" 5
3404	esac
3405	_PYTHON_HOST_PLATFORM="$MACHDEP${_host_cpu:+-$_host_cpu}"
3406fi
3407
3408# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
3409# disable features if it is defined, without any means to access these
3410# features as extensions. For these systems, we skip the definition of
3411# _XOPEN_SOURCE. Before adding a system to the list to gain access to
3412# some feature, make sure there is no alternative way to access this
3413# feature. Also, when using wildcards, make sure you have verified the
3414# need for not defining _XOPEN_SOURCE on all systems matching the
3415# wildcard, and that the wildcard does not include future systems
3416# (which may remove their limitations).
3417case $ac_sys_system/$ac_sys_release in
3418  # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
3419  # even though select is a POSIX function. Reported by J. Ribbens.
3420  # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish.
3421  # In addition, Stefan Krah confirms that issue #1244610 exists through
3422  # OpenBSD 4.6, but is fixed in 4.7.
3423  OpenBSD/2.* | OpenBSD/3.* | OpenBSD/4.[0123456])
3424    define_xopen_source=no
3425    # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
3426    # also defined. This can be overridden by defining _BSD_SOURCE
3427    # As this has a different meaning on Linux, only define it on OpenBSD
3428
3429$as_echo "#define _BSD_SOURCE 1" >>confdefs.h
3430
3431    ;;
3432  OpenBSD/*)
3433    # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
3434    # also defined. This can be overridden by defining _BSD_SOURCE
3435    # As this has a different meaning on Linux, only define it on OpenBSD
3436
3437$as_echo "#define _BSD_SOURCE 1" >>confdefs.h
3438
3439    ;;
3440  # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of
3441  # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by
3442  # Marc Recht
3443  NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S])
3444    define_xopen_source=no;;
3445  # From the perspective of Solaris, _XOPEN_SOURCE is not so much a
3446  # request to enable features supported by the standard as a request
3447  # to disable features not supported by the standard.  The best way
3448  # for Python to use Solaris is simply to leave _XOPEN_SOURCE out
3449  # entirely and define __EXTENSIONS__ instead.
3450  SunOS/*)
3451    define_xopen_source=no;;
3452  # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
3453  # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
3454  # Reconfirmed for 7.1.4 by Martin v. Loewis.
3455  OpenUNIX/8.0.0| UnixWare/7.1.[0-4])
3456    define_xopen_source=no;;
3457  # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
3458  # but used in struct sockaddr.sa_family. Reported by Tim Rice.
3459  SCO_SV/3.2)
3460    define_xopen_source=no;;
3461  # On MacOS X 10.2, a bug in ncurses.h means that it craps out if
3462  # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which
3463  # identifies itself as Darwin/7.*
3464  # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
3465  # disables platform specific features beyond repair.
3466  # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
3467  # has no effect, don't bother defining them
3468  Darwin/[6789].*)
3469    define_xopen_source=no;;
3470  Darwin/[12][0-9].*)
3471    define_xopen_source=no;;
3472  # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from
3473  # defining NI_NUMERICHOST.
3474  QNX/6.3.2)
3475    define_xopen_source=no
3476    ;;
3477  # On VxWorks, defining _XOPEN_SOURCE causes compile failures
3478  # in network headers still using system V types.
3479  VxWorks/*)
3480    define_xopen_source=no
3481    ;;
3482
3483  # On HP-UX, defining _XOPEN_SOURCE to 600 or greater hides
3484  # chroot() and other functions
3485  hp*|HP*)
3486    define_xopen_source=no
3487    ;;
3488
3489esac
3490
3491if test $define_xopen_source = yes
3492then
3493  # X/Open 7, incorporating POSIX.1-2008
3494
3495$as_echo "#define _XOPEN_SOURCE 700" >>confdefs.h
3496
3497
3498  # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
3499  # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
3500  # several APIs are not declared. Since this is also needed in some
3501  # cases for HP-UX, we define it globally.
3502
3503$as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h
3504
3505
3506
3507$as_echo "#define _POSIX_C_SOURCE 200809L" >>confdefs.h
3508
3509fi
3510
3511# On HP-UX mbstate_t requires _INCLUDE__STDC_A1_SOURCE
3512case $ac_sys_system in
3513  hp*|HP*)
3514    define_stdc_a1=yes;;
3515  *)
3516    define_stdc_a1=no;;
3517esac
3518
3519if test $define_stdc_a1 = yes
3520then
3521
3522$as_echo "#define _INCLUDE__STDC_A1_SOURCE 1" >>confdefs.h
3523
3524fi
3525
3526# Record the configure-time value of MACOSX_DEPLOYMENT_TARGET,
3527# it may influence the way we can build extensions, so distutils
3528# needs to check it
3529
3530
3531CONFIGURE_MACOSX_DEPLOYMENT_TARGET=
3532EXPORT_MACOSX_DEPLOYMENT_TARGET='#'
3533
3534# checks for alternative programs
3535
3536# compiler flags are generated in two sets, BASECFLAGS and OPT.  OPT is just
3537# for debug/optimization stuff.  BASECFLAGS is for flags that are required
3538# just to get things to compile and link.  Users are free to override OPT
3539# when running configure or make.  The build should not break if they do.
3540# BASECFLAGS should generally not be messed with, however.
3541
3542# If the user switches compilers, we can't believe the cache
3543if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
3544then
3545  as_fn_error $? "cached CC is different -- throw away $cache_file
3546(it is also a good idea to do 'make clean' before compiling)" "$LINENO" 5
3547fi
3548
3549# Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2
3550# when the compiler supports them, but we don't always want -O2, and
3551# we set -g later.
3552if test -z "$CFLAGS"; then
3553        CFLAGS=
3554fi
3555
3556if test "$ac_sys_system" = "Darwin"
3557then
3558	# Compiler selection on MacOSX is more complicated than
3559	# AC_PROG_CC can handle, see Mac/README for more
3560	# information
3561	if test -z "${CC}"
3562	then
3563		found_gcc=
3564		found_clang=
3565		as_save_IFS=$IFS; IFS=:
3566		for as_dir in $PATH
3567		do
3568			IFS=$as_save_IFS
3569			if test -x "${as_dir}/gcc"; then
3570				if test -z "${found_gcc}"; then
3571					found_gcc="${as_dir}/gcc"
3572				fi
3573			fi
3574			if test -x "${as_dir}/clang"; then
3575				if test -z "${found_clang}"; then
3576					found_clang="${as_dir}/clang"
3577				fi
3578			fi
3579		done
3580		IFS=$as_save_IFS
3581
3582		if test -n "$found_gcc" -a -n "$found_clang"
3583		then
3584			if test -n "`"$found_gcc" --version | grep llvm-gcc`"
3585			then
3586				{ $as_echo "$as_me:${as_lineno-$LINENO}: Detected llvm-gcc, falling back to clang" >&5
3587$as_echo "$as_me: Detected llvm-gcc, falling back to clang" >&6;}
3588				CC="$found_clang"
3589				CXX="$found_clang++"
3590			fi
3591
3592
3593		elif test -z "$found_gcc" -a -n "$found_clang"
3594		then
3595			{ $as_echo "$as_me:${as_lineno-$LINENO}: No GCC found, use CLANG" >&5
3596$as_echo "$as_me: No GCC found, use CLANG" >&6;}
3597			CC="$found_clang"
3598			CXX="$found_clang++"
3599
3600		elif test -z "$found_gcc" -a -z "$found_clang"
3601		then
3602			found_clang=`/usr/bin/xcrun -find clang 2>/dev/null`
3603			if test -n "${found_clang}"
3604			then
3605				{ $as_echo "$as_me:${as_lineno-$LINENO}: Using clang from Xcode.app" >&5
3606$as_echo "$as_me: Using clang from Xcode.app" >&6;}
3607				CC="${found_clang}"
3608				CXX="`/usr/bin/xcrun -find clang++`"
3609
3610			# else: use default behaviour
3611			fi
3612		fi
3613	fi
3614fi
3615ac_ext=c
3616ac_cpp='$CPP $CPPFLAGS'
3617ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3618ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3619ac_compiler_gnu=$ac_cv_c_compiler_gnu
3620if test -n "$ac_tool_prefix"; then
3621  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3622set dummy ${ac_tool_prefix}gcc; ac_word=$2
3623{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3624$as_echo_n "checking for $ac_word... " >&6; }
3625if ${ac_cv_prog_CC+:} false; then :
3626  $as_echo_n "(cached) " >&6
3627else
3628  if test -n "$CC"; then
3629  ac_cv_prog_CC="$CC" # Let the user override the test.
3630else
3631as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3632for as_dir in $PATH
3633do
3634  IFS=$as_save_IFS
3635  test -z "$as_dir" && as_dir=.
3636    for ac_exec_ext in '' $ac_executable_extensions; do
3637  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3638    ac_cv_prog_CC="${ac_tool_prefix}gcc"
3639    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3640    break 2
3641  fi
3642done
3643  done
3644IFS=$as_save_IFS
3645
3646fi
3647fi
3648CC=$ac_cv_prog_CC
3649if test -n "$CC"; then
3650  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3651$as_echo "$CC" >&6; }
3652else
3653  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3654$as_echo "no" >&6; }
3655fi
3656
3657
3658fi
3659if test -z "$ac_cv_prog_CC"; then
3660  ac_ct_CC=$CC
3661  # Extract the first word of "gcc", so it can be a program name with args.
3662set dummy gcc; ac_word=$2
3663{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3664$as_echo_n "checking for $ac_word... " >&6; }
3665if ${ac_cv_prog_ac_ct_CC+:} false; then :
3666  $as_echo_n "(cached) " >&6
3667else
3668  if test -n "$ac_ct_CC"; then
3669  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3670else
3671as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3672for as_dir in $PATH
3673do
3674  IFS=$as_save_IFS
3675  test -z "$as_dir" && as_dir=.
3676    for ac_exec_ext in '' $ac_executable_extensions; do
3677  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3678    ac_cv_prog_ac_ct_CC="gcc"
3679    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3680    break 2
3681  fi
3682done
3683  done
3684IFS=$as_save_IFS
3685
3686fi
3687fi
3688ac_ct_CC=$ac_cv_prog_ac_ct_CC
3689if test -n "$ac_ct_CC"; then
3690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3691$as_echo "$ac_ct_CC" >&6; }
3692else
3693  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3694$as_echo "no" >&6; }
3695fi
3696
3697  if test "x$ac_ct_CC" = x; then
3698    CC=""
3699  else
3700    case $cross_compiling:$ac_tool_warned in
3701yes:)
3702{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3703$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3704ac_tool_warned=yes ;;
3705esac
3706    CC=$ac_ct_CC
3707  fi
3708else
3709  CC="$ac_cv_prog_CC"
3710fi
3711
3712if test -z "$CC"; then
3713          if test -n "$ac_tool_prefix"; then
3714    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3715set dummy ${ac_tool_prefix}cc; ac_word=$2
3716{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3717$as_echo_n "checking for $ac_word... " >&6; }
3718if ${ac_cv_prog_CC+:} false; then :
3719  $as_echo_n "(cached) " >&6
3720else
3721  if test -n "$CC"; then
3722  ac_cv_prog_CC="$CC" # Let the user override the test.
3723else
3724as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3725for as_dir in $PATH
3726do
3727  IFS=$as_save_IFS
3728  test -z "$as_dir" && as_dir=.
3729    for ac_exec_ext in '' $ac_executable_extensions; do
3730  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3731    ac_cv_prog_CC="${ac_tool_prefix}cc"
3732    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3733    break 2
3734  fi
3735done
3736  done
3737IFS=$as_save_IFS
3738
3739fi
3740fi
3741CC=$ac_cv_prog_CC
3742if test -n "$CC"; then
3743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3744$as_echo "$CC" >&6; }
3745else
3746  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3747$as_echo "no" >&6; }
3748fi
3749
3750
3751  fi
3752fi
3753if test -z "$CC"; then
3754  # Extract the first word of "cc", so it can be a program name with args.
3755set dummy cc; ac_word=$2
3756{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3757$as_echo_n "checking for $ac_word... " >&6; }
3758if ${ac_cv_prog_CC+:} false; then :
3759  $as_echo_n "(cached) " >&6
3760else
3761  if test -n "$CC"; then
3762  ac_cv_prog_CC="$CC" # Let the user override the test.
3763else
3764  ac_prog_rejected=no
3765as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3766for as_dir in $PATH
3767do
3768  IFS=$as_save_IFS
3769  test -z "$as_dir" && as_dir=.
3770    for ac_exec_ext in '' $ac_executable_extensions; do
3771  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3772    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3773       ac_prog_rejected=yes
3774       continue
3775     fi
3776    ac_cv_prog_CC="cc"
3777    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3778    break 2
3779  fi
3780done
3781  done
3782IFS=$as_save_IFS
3783
3784if test $ac_prog_rejected = yes; then
3785  # We found a bogon in the path, so make sure we never use it.
3786  set dummy $ac_cv_prog_CC
3787  shift
3788  if test $# != 0; then
3789    # We chose a different compiler from the bogus one.
3790    # However, it has the same basename, so the bogon will be chosen
3791    # first if we set CC to just the basename; use the full file name.
3792    shift
3793    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3794  fi
3795fi
3796fi
3797fi
3798CC=$ac_cv_prog_CC
3799if test -n "$CC"; then
3800  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3801$as_echo "$CC" >&6; }
3802else
3803  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3804$as_echo "no" >&6; }
3805fi
3806
3807
3808fi
3809if test -z "$CC"; then
3810  if test -n "$ac_tool_prefix"; then
3811  for ac_prog in cl.exe
3812  do
3813    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3814set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3816$as_echo_n "checking for $ac_word... " >&6; }
3817if ${ac_cv_prog_CC+:} false; then :
3818  $as_echo_n "(cached) " >&6
3819else
3820  if test -n "$CC"; then
3821  ac_cv_prog_CC="$CC" # Let the user override the test.
3822else
3823as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3824for as_dir in $PATH
3825do
3826  IFS=$as_save_IFS
3827  test -z "$as_dir" && as_dir=.
3828    for ac_exec_ext in '' $ac_executable_extensions; do
3829  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3830    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3831    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3832    break 2
3833  fi
3834done
3835  done
3836IFS=$as_save_IFS
3837
3838fi
3839fi
3840CC=$ac_cv_prog_CC
3841if test -n "$CC"; then
3842  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3843$as_echo "$CC" >&6; }
3844else
3845  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3846$as_echo "no" >&6; }
3847fi
3848
3849
3850    test -n "$CC" && break
3851  done
3852fi
3853if test -z "$CC"; then
3854  ac_ct_CC=$CC
3855  for ac_prog in cl.exe
3856do
3857  # Extract the first word of "$ac_prog", so it can be a program name with args.
3858set dummy $ac_prog; ac_word=$2
3859{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3860$as_echo_n "checking for $ac_word... " >&6; }
3861if ${ac_cv_prog_ac_ct_CC+:} false; then :
3862  $as_echo_n "(cached) " >&6
3863else
3864  if test -n "$ac_ct_CC"; then
3865  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3866else
3867as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3868for as_dir in $PATH
3869do
3870  IFS=$as_save_IFS
3871  test -z "$as_dir" && as_dir=.
3872    for ac_exec_ext in '' $ac_executable_extensions; do
3873  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3874    ac_cv_prog_ac_ct_CC="$ac_prog"
3875    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3876    break 2
3877  fi
3878done
3879  done
3880IFS=$as_save_IFS
3881
3882fi
3883fi
3884ac_ct_CC=$ac_cv_prog_ac_ct_CC
3885if test -n "$ac_ct_CC"; then
3886  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3887$as_echo "$ac_ct_CC" >&6; }
3888else
3889  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3890$as_echo "no" >&6; }
3891fi
3892
3893
3894  test -n "$ac_ct_CC" && break
3895done
3896
3897  if test "x$ac_ct_CC" = x; then
3898    CC=""
3899  else
3900    case $cross_compiling:$ac_tool_warned in
3901yes:)
3902{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3903$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3904ac_tool_warned=yes ;;
3905esac
3906    CC=$ac_ct_CC
3907  fi
3908fi
3909
3910fi
3911
3912
3913test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3914$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3915as_fn_error $? "no acceptable C compiler found in \$PATH
3916See \`config.log' for more details" "$LINENO" 5; }
3917
3918# Provide some information about the compiler.
3919$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3920set X $ac_compile
3921ac_compiler=$2
3922for ac_option in --version -v -V -qversion; do
3923  { { ac_try="$ac_compiler $ac_option >&5"
3924case "(($ac_try" in
3925  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3926  *) ac_try_echo=$ac_try;;
3927esac
3928eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3929$as_echo "$ac_try_echo"; } >&5
3930  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3931  ac_status=$?
3932  if test -s conftest.err; then
3933    sed '10a\
3934... rest of stderr output deleted ...
3935         10q' conftest.err >conftest.er1
3936    cat conftest.er1 >&5
3937  fi
3938  rm -f conftest.er1 conftest.err
3939  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3940  test $ac_status = 0; }
3941done
3942
3943cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3944/* end confdefs.h.  */
3945
3946int
3947main ()
3948{
3949
3950  ;
3951  return 0;
3952}
3953_ACEOF
3954ac_clean_files_save=$ac_clean_files
3955ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3956# Try to create an executable without -o first, disregard a.out.
3957# It will help us diagnose broken compilers, and finding out an intuition
3958# of exeext.
3959{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3960$as_echo_n "checking whether the C compiler works... " >&6; }
3961ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3962
3963# The possible output files:
3964ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3965
3966ac_rmfiles=
3967for ac_file in $ac_files
3968do
3969  case $ac_file in
3970    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3971    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3972  esac
3973done
3974rm -f $ac_rmfiles
3975
3976if { { ac_try="$ac_link_default"
3977case "(($ac_try" in
3978  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3979  *) ac_try_echo=$ac_try;;
3980esac
3981eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3982$as_echo "$ac_try_echo"; } >&5
3983  (eval "$ac_link_default") 2>&5
3984  ac_status=$?
3985  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3986  test $ac_status = 0; }; then :
3987  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3988# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3989# in a Makefile.  We should not override ac_cv_exeext if it was cached,
3990# so that the user can short-circuit this test for compilers unknown to
3991# Autoconf.
3992for ac_file in $ac_files ''
3993do
3994  test -f "$ac_file" || continue
3995  case $ac_file in
3996    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3997	;;
3998    [ab].out )
3999	# We found the default executable, but exeext='' is most
4000	# certainly right.
4001	break;;
4002    *.* )
4003	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4004	then :; else
4005	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4006	fi
4007	# We set ac_cv_exeext here because the later test for it is not
4008	# safe: cross compilers may not add the suffix if given an `-o'
4009	# argument, so we may need to know it at that point already.
4010	# Even if this section looks crufty: it has the advantage of
4011	# actually working.
4012	break;;
4013    * )
4014	break;;
4015  esac
4016done
4017test "$ac_cv_exeext" = no && ac_cv_exeext=
4018
4019else
4020  ac_file=''
4021fi
4022if test -z "$ac_file"; then :
4023  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4024$as_echo "no" >&6; }
4025$as_echo "$as_me: failed program was:" >&5
4026sed 's/^/| /' conftest.$ac_ext >&5
4027
4028{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4029$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4030as_fn_error 77 "C compiler cannot create executables
4031See \`config.log' for more details" "$LINENO" 5; }
4032else
4033  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4034$as_echo "yes" >&6; }
4035fi
4036{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4037$as_echo_n "checking for C compiler default output file name... " >&6; }
4038{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4039$as_echo "$ac_file" >&6; }
4040ac_exeext=$ac_cv_exeext
4041
4042rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4043ac_clean_files=$ac_clean_files_save
4044{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4045$as_echo_n "checking for suffix of executables... " >&6; }
4046if { { ac_try="$ac_link"
4047case "(($ac_try" in
4048  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4049  *) ac_try_echo=$ac_try;;
4050esac
4051eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4052$as_echo "$ac_try_echo"; } >&5
4053  (eval "$ac_link") 2>&5
4054  ac_status=$?
4055  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4056  test $ac_status = 0; }; then :
4057  # If both `conftest.exe' and `conftest' are `present' (well, observable)
4058# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4059# work properly (i.e., refer to `conftest.exe'), while it won't with
4060# `rm'.
4061for ac_file in conftest.exe conftest conftest.*; do
4062  test -f "$ac_file" || continue
4063  case $ac_file in
4064    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4065    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4066	  break;;
4067    * ) break;;
4068  esac
4069done
4070else
4071  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4072$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4073as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4074See \`config.log' for more details" "$LINENO" 5; }
4075fi
4076rm -f conftest conftest$ac_cv_exeext
4077{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4078$as_echo "$ac_cv_exeext" >&6; }
4079
4080rm -f conftest.$ac_ext
4081EXEEXT=$ac_cv_exeext
4082ac_exeext=$EXEEXT
4083cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4084/* end confdefs.h.  */
4085#include <stdio.h>
4086int
4087main ()
4088{
4089FILE *f = fopen ("conftest.out", "w");
4090 return ferror (f) || fclose (f) != 0;
4091
4092  ;
4093  return 0;
4094}
4095_ACEOF
4096ac_clean_files="$ac_clean_files conftest.out"
4097# Check that the compiler produces executables we can run.  If not, either
4098# the compiler is broken, or we cross compile.
4099{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4100$as_echo_n "checking whether we are cross compiling... " >&6; }
4101if test "$cross_compiling" != yes; then
4102  { { ac_try="$ac_link"
4103case "(($ac_try" in
4104  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4105  *) ac_try_echo=$ac_try;;
4106esac
4107eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4108$as_echo "$ac_try_echo"; } >&5
4109  (eval "$ac_link") 2>&5
4110  ac_status=$?
4111  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4112  test $ac_status = 0; }
4113  if { ac_try='./conftest$ac_cv_exeext'
4114  { { case "(($ac_try" in
4115  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4116  *) ac_try_echo=$ac_try;;
4117esac
4118eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4119$as_echo "$ac_try_echo"; } >&5
4120  (eval "$ac_try") 2>&5
4121  ac_status=$?
4122  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4123  test $ac_status = 0; }; }; then
4124    cross_compiling=no
4125  else
4126    if test "$cross_compiling" = maybe; then
4127	cross_compiling=yes
4128    else
4129	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4130$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4131as_fn_error $? "cannot run C compiled programs.
4132If you meant to cross compile, use \`--host'.
4133See \`config.log' for more details" "$LINENO" 5; }
4134    fi
4135  fi
4136fi
4137{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4138$as_echo "$cross_compiling" >&6; }
4139
4140rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4141ac_clean_files=$ac_clean_files_save
4142{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4143$as_echo_n "checking for suffix of object files... " >&6; }
4144if ${ac_cv_objext+:} false; then :
4145  $as_echo_n "(cached) " >&6
4146else
4147  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4148/* end confdefs.h.  */
4149
4150int
4151main ()
4152{
4153
4154  ;
4155  return 0;
4156}
4157_ACEOF
4158rm -f conftest.o conftest.obj
4159if { { ac_try="$ac_compile"
4160case "(($ac_try" in
4161  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4162  *) ac_try_echo=$ac_try;;
4163esac
4164eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4165$as_echo "$ac_try_echo"; } >&5
4166  (eval "$ac_compile") 2>&5
4167  ac_status=$?
4168  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4169  test $ac_status = 0; }; then :
4170  for ac_file in conftest.o conftest.obj conftest.*; do
4171  test -f "$ac_file" || continue;
4172  case $ac_file in
4173    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4174    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4175       break;;
4176  esac
4177done
4178else
4179  $as_echo "$as_me: failed program was:" >&5
4180sed 's/^/| /' conftest.$ac_ext >&5
4181
4182{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4183$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4184as_fn_error $? "cannot compute suffix of object files: cannot compile
4185See \`config.log' for more details" "$LINENO" 5; }
4186fi
4187rm -f conftest.$ac_cv_objext conftest.$ac_ext
4188fi
4189{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4190$as_echo "$ac_cv_objext" >&6; }
4191OBJEXT=$ac_cv_objext
4192ac_objext=$OBJEXT
4193{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4194$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4195if ${ac_cv_c_compiler_gnu+:} false; then :
4196  $as_echo_n "(cached) " >&6
4197else
4198  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4199/* end confdefs.h.  */
4200
4201int
4202main ()
4203{
4204#ifndef __GNUC__
4205       choke me
4206#endif
4207
4208  ;
4209  return 0;
4210}
4211_ACEOF
4212if ac_fn_c_try_compile "$LINENO"; then :
4213  ac_compiler_gnu=yes
4214else
4215  ac_compiler_gnu=no
4216fi
4217rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4218ac_cv_c_compiler_gnu=$ac_compiler_gnu
4219
4220fi
4221{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4222$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4223if test $ac_compiler_gnu = yes; then
4224  GCC=yes
4225else
4226  GCC=
4227fi
4228ac_test_CFLAGS=${CFLAGS+set}
4229ac_save_CFLAGS=$CFLAGS
4230{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4231$as_echo_n "checking whether $CC accepts -g... " >&6; }
4232if ${ac_cv_prog_cc_g+:} false; then :
4233  $as_echo_n "(cached) " >&6
4234else
4235  ac_save_c_werror_flag=$ac_c_werror_flag
4236   ac_c_werror_flag=yes
4237   ac_cv_prog_cc_g=no
4238   CFLAGS="-g"
4239   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4240/* end confdefs.h.  */
4241
4242int
4243main ()
4244{
4245
4246  ;
4247  return 0;
4248}
4249_ACEOF
4250if ac_fn_c_try_compile "$LINENO"; then :
4251  ac_cv_prog_cc_g=yes
4252else
4253  CFLAGS=""
4254      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4255/* end confdefs.h.  */
4256
4257int
4258main ()
4259{
4260
4261  ;
4262  return 0;
4263}
4264_ACEOF
4265if ac_fn_c_try_compile "$LINENO"; then :
4266
4267else
4268  ac_c_werror_flag=$ac_save_c_werror_flag
4269	 CFLAGS="-g"
4270	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4271/* end confdefs.h.  */
4272
4273int
4274main ()
4275{
4276
4277  ;
4278  return 0;
4279}
4280_ACEOF
4281if ac_fn_c_try_compile "$LINENO"; then :
4282  ac_cv_prog_cc_g=yes
4283fi
4284rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4285fi
4286rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4287fi
4288rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4289   ac_c_werror_flag=$ac_save_c_werror_flag
4290fi
4291{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4292$as_echo "$ac_cv_prog_cc_g" >&6; }
4293if test "$ac_test_CFLAGS" = set; then
4294  CFLAGS=$ac_save_CFLAGS
4295elif test $ac_cv_prog_cc_g = yes; then
4296  if test "$GCC" = yes; then
4297    CFLAGS="-g -O2"
4298  else
4299    CFLAGS="-g"
4300  fi
4301else
4302  if test "$GCC" = yes; then
4303    CFLAGS="-O2"
4304  else
4305    CFLAGS=
4306  fi
4307fi
4308{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4309$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4310if ${ac_cv_prog_cc_c89+:} false; then :
4311  $as_echo_n "(cached) " >&6
4312else
4313  ac_cv_prog_cc_c89=no
4314ac_save_CC=$CC
4315cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4316/* end confdefs.h.  */
4317#include <stdarg.h>
4318#include <stdio.h>
4319struct stat;
4320/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4321struct buf { int x; };
4322FILE * (*rcsopen) (struct buf *, struct stat *, int);
4323static char *e (p, i)
4324     char **p;
4325     int i;
4326{
4327  return p[i];
4328}
4329static char *f (char * (*g) (char **, int), char **p, ...)
4330{
4331  char *s;
4332  va_list v;
4333  va_start (v,p);
4334  s = g (p, va_arg (v,int));
4335  va_end (v);
4336  return s;
4337}
4338
4339/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4340   function prototypes and stuff, but not '\xHH' hex character constants.
4341   These don't provoke an error unfortunately, instead are silently treated
4342   as 'x'.  The following induces an error, until -std is added to get
4343   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4344   array size at least.  It's necessary to write '\x00'==0 to get something
4345   that's true only with -std.  */
4346int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4347
4348/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4349   inside strings and character constants.  */
4350#define FOO(x) 'x'
4351int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4352
4353int test (int i, double x);
4354struct s1 {int (*f) (int a);};
4355struct s2 {int (*f) (double a);};
4356int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4357int argc;
4358char **argv;
4359int
4360main ()
4361{
4362return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4363  ;
4364  return 0;
4365}
4366_ACEOF
4367for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4368	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4369do
4370  CC="$ac_save_CC $ac_arg"
4371  if ac_fn_c_try_compile "$LINENO"; then :
4372  ac_cv_prog_cc_c89=$ac_arg
4373fi
4374rm -f core conftest.err conftest.$ac_objext
4375  test "x$ac_cv_prog_cc_c89" != "xno" && break
4376done
4377rm -f conftest.$ac_ext
4378CC=$ac_save_CC
4379
4380fi
4381# AC_CACHE_VAL
4382case "x$ac_cv_prog_cc_c89" in
4383  x)
4384    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4385$as_echo "none needed" >&6; } ;;
4386  xno)
4387    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4388$as_echo "unsupported" >&6; } ;;
4389  *)
4390    CC="$CC $ac_cv_prog_cc_c89"
4391    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4392$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4393esac
4394if test "x$ac_cv_prog_cc_c89" != xno; then :
4395
4396fi
4397
4398ac_ext=c
4399ac_cpp='$CPP $CPPFLAGS'
4400ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4401ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4402ac_compiler_gnu=$ac_cv_c_compiler_gnu
4403
4404ac_ext=c
4405ac_cpp='$CPP $CPPFLAGS'
4406ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4407ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4408ac_compiler_gnu=$ac_cv_c_compiler_gnu
4409{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4410$as_echo_n "checking how to run the C preprocessor... " >&6; }
4411# On Suns, sometimes $CPP names a directory.
4412if test -n "$CPP" && test -d "$CPP"; then
4413  CPP=
4414fi
4415if test -z "$CPP"; then
4416  if ${ac_cv_prog_CPP+:} false; then :
4417  $as_echo_n "(cached) " >&6
4418else
4419      # Double quotes because CPP needs to be expanded
4420    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4421    do
4422      ac_preproc_ok=false
4423for ac_c_preproc_warn_flag in '' yes
4424do
4425  # Use a header file that comes with gcc, so configuring glibc
4426  # with a fresh cross-compiler works.
4427  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4428  # <limits.h> exists even on freestanding compilers.
4429  # On the NeXT, cc -E runs the code through the compiler's parser,
4430  # not just through cpp. "Syntax error" is here to catch this case.
4431  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4432/* end confdefs.h.  */
4433#ifdef __STDC__
4434# include <limits.h>
4435#else
4436# include <assert.h>
4437#endif
4438		     Syntax error
4439_ACEOF
4440if ac_fn_c_try_cpp "$LINENO"; then :
4441
4442else
4443  # Broken: fails on valid input.
4444continue
4445fi
4446rm -f conftest.err conftest.i conftest.$ac_ext
4447
4448  # OK, works on sane cases.  Now check whether nonexistent headers
4449  # can be detected and how.
4450  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4451/* end confdefs.h.  */
4452#include <ac_nonexistent.h>
4453_ACEOF
4454if ac_fn_c_try_cpp "$LINENO"; then :
4455  # Broken: success on invalid input.
4456continue
4457else
4458  # Passes both tests.
4459ac_preproc_ok=:
4460break
4461fi
4462rm -f conftest.err conftest.i conftest.$ac_ext
4463
4464done
4465# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4466rm -f conftest.i conftest.err conftest.$ac_ext
4467if $ac_preproc_ok; then :
4468  break
4469fi
4470
4471    done
4472    ac_cv_prog_CPP=$CPP
4473
4474fi
4475  CPP=$ac_cv_prog_CPP
4476else
4477  ac_cv_prog_CPP=$CPP
4478fi
4479{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4480$as_echo "$CPP" >&6; }
4481ac_preproc_ok=false
4482for ac_c_preproc_warn_flag in '' yes
4483do
4484  # Use a header file that comes with gcc, so configuring glibc
4485  # with a fresh cross-compiler works.
4486  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4487  # <limits.h> exists even on freestanding compilers.
4488  # On the NeXT, cc -E runs the code through the compiler's parser,
4489  # not just through cpp. "Syntax error" is here to catch this case.
4490  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4491/* end confdefs.h.  */
4492#ifdef __STDC__
4493# include <limits.h>
4494#else
4495# include <assert.h>
4496#endif
4497		     Syntax error
4498_ACEOF
4499if ac_fn_c_try_cpp "$LINENO"; then :
4500
4501else
4502  # Broken: fails on valid input.
4503continue
4504fi
4505rm -f conftest.err conftest.i conftest.$ac_ext
4506
4507  # OK, works on sane cases.  Now check whether nonexistent headers
4508  # can be detected and how.
4509  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4510/* end confdefs.h.  */
4511#include <ac_nonexistent.h>
4512_ACEOF
4513if ac_fn_c_try_cpp "$LINENO"; then :
4514  # Broken: success on invalid input.
4515continue
4516else
4517  # Passes both tests.
4518ac_preproc_ok=:
4519break
4520fi
4521rm -f conftest.err conftest.i conftest.$ac_ext
4522
4523done
4524# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4525rm -f conftest.i conftest.err conftest.$ac_ext
4526if $ac_preproc_ok; then :
4527
4528else
4529  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4530$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4531as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4532See \`config.log' for more details" "$LINENO" 5; }
4533fi
4534
4535ac_ext=c
4536ac_cpp='$CPP $CPPFLAGS'
4537ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4538ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4539ac_compiler_gnu=$ac_cv_c_compiler_gnu
4540
4541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4542$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4543if ${ac_cv_path_GREP+:} false; then :
4544  $as_echo_n "(cached) " >&6
4545else
4546  if test -z "$GREP"; then
4547  ac_path_GREP_found=false
4548  # Loop through the user's path and test for each of PROGNAME-LIST
4549  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4550for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4551do
4552  IFS=$as_save_IFS
4553  test -z "$as_dir" && as_dir=.
4554    for ac_prog in grep ggrep; do
4555    for ac_exec_ext in '' $ac_executable_extensions; do
4556      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4557      as_fn_executable_p "$ac_path_GREP" || continue
4558# Check for GNU ac_path_GREP and select it if it is found.
4559  # Check for GNU $ac_path_GREP
4560case `"$ac_path_GREP" --version 2>&1` in
4561*GNU*)
4562  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4563*)
4564  ac_count=0
4565  $as_echo_n 0123456789 >"conftest.in"
4566  while :
4567  do
4568    cat "conftest.in" "conftest.in" >"conftest.tmp"
4569    mv "conftest.tmp" "conftest.in"
4570    cp "conftest.in" "conftest.nl"
4571    $as_echo 'GREP' >> "conftest.nl"
4572    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4573    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4574    as_fn_arith $ac_count + 1 && ac_count=$as_val
4575    if test $ac_count -gt ${ac_path_GREP_max-0}; then
4576      # Best one so far, save it but keep looking for a better one
4577      ac_cv_path_GREP="$ac_path_GREP"
4578      ac_path_GREP_max=$ac_count
4579    fi
4580    # 10*(2^10) chars as input seems more than enough
4581    test $ac_count -gt 10 && break
4582  done
4583  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4584esac
4585
4586      $ac_path_GREP_found && break 3
4587    done
4588  done
4589  done
4590IFS=$as_save_IFS
4591  if test -z "$ac_cv_path_GREP"; then
4592    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4593  fi
4594else
4595  ac_cv_path_GREP=$GREP
4596fi
4597
4598fi
4599{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4600$as_echo "$ac_cv_path_GREP" >&6; }
4601 GREP="$ac_cv_path_GREP"
4602
4603
4604{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
4605$as_echo_n "checking for a sed that does not truncate output... " >&6; }
4606if ${ac_cv_path_SED+:} false; then :
4607  $as_echo_n "(cached) " >&6
4608else
4609            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4610     for ac_i in 1 2 3 4 5 6 7; do
4611       ac_script="$ac_script$as_nl$ac_script"
4612     done
4613     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4614     { ac_script=; unset ac_script;}
4615     if test -z "$SED"; then
4616  ac_path_SED_found=false
4617  # Loop through the user's path and test for each of PROGNAME-LIST
4618  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4619for as_dir in $PATH
4620do
4621  IFS=$as_save_IFS
4622  test -z "$as_dir" && as_dir=.
4623    for ac_prog in sed gsed; do
4624    for ac_exec_ext in '' $ac_executable_extensions; do
4625      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4626      as_fn_executable_p "$ac_path_SED" || continue
4627# Check for GNU ac_path_SED and select it if it is found.
4628  # Check for GNU $ac_path_SED
4629case `"$ac_path_SED" --version 2>&1` in
4630*GNU*)
4631  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4632*)
4633  ac_count=0
4634  $as_echo_n 0123456789 >"conftest.in"
4635  while :
4636  do
4637    cat "conftest.in" "conftest.in" >"conftest.tmp"
4638    mv "conftest.tmp" "conftest.in"
4639    cp "conftest.in" "conftest.nl"
4640    $as_echo '' >> "conftest.nl"
4641    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4642    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4643    as_fn_arith $ac_count + 1 && ac_count=$as_val
4644    if test $ac_count -gt ${ac_path_SED_max-0}; then
4645      # Best one so far, save it but keep looking for a better one
4646      ac_cv_path_SED="$ac_path_SED"
4647      ac_path_SED_max=$ac_count
4648    fi
4649    # 10*(2^10) chars as input seems more than enough
4650    test $ac_count -gt 10 && break
4651  done
4652  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4653esac
4654
4655      $ac_path_SED_found && break 3
4656    done
4657  done
4658  done
4659IFS=$as_save_IFS
4660  if test -z "$ac_cv_path_SED"; then
4661    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
4662  fi
4663else
4664  ac_cv_path_SED=$SED
4665fi
4666
4667fi
4668{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
4669$as_echo "$ac_cv_path_SED" >&6; }
4670 SED="$ac_cv_path_SED"
4671  rm -f conftest.sed
4672
4673
4674
4675
4676{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5
4677$as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; }
4678
4679# Check whether --with-cxx_main was given.
4680if test "${with_cxx_main+set}" = set; then :
4681  withval=$with_cxx_main;
4682
4683	case $withval in
4684	no)	with_cxx_main=no
4685		MAINCC='$(CC)';;
4686	yes)	with_cxx_main=yes
4687		MAINCC='$(CXX)';;
4688	*)	with_cxx_main=yes
4689		MAINCC=$withval
4690		if test -z "$CXX"
4691		then
4692			CXX=$withval
4693		fi;;
4694	esac
4695else
4696
4697	with_cxx_main=no
4698	MAINCC='$(CC)'
4699
4700fi
4701
4702{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5
4703$as_echo "$with_cxx_main" >&6; }
4704
4705preset_cxx="$CXX"
4706if test -z "$CXX"
4707then
4708        case "$CC" in
4709        gcc)    if test -n "$ac_tool_prefix"; then
4710  # Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args.
4711set dummy ${ac_tool_prefix}g++; ac_word=$2
4712{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4713$as_echo_n "checking for $ac_word... " >&6; }
4714if ${ac_cv_path_CXX+:} false; then :
4715  $as_echo_n "(cached) " >&6
4716else
4717  case $CXX in
4718  [\\/]* | ?:[\\/]*)
4719  ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
4720  ;;
4721  *)
4722  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4723for as_dir in notfound
4724do
4725  IFS=$as_save_IFS
4726  test -z "$as_dir" && as_dir=.
4727    for ac_exec_ext in '' $ac_executable_extensions; do
4728  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4729    ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
4730    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4731    break 2
4732  fi
4733done
4734  done
4735IFS=$as_save_IFS
4736
4737  ;;
4738esac
4739fi
4740CXX=$ac_cv_path_CXX
4741if test -n "$CXX"; then
4742  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4743$as_echo "$CXX" >&6; }
4744else
4745  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4746$as_echo "no" >&6; }
4747fi
4748
4749
4750fi
4751if test -z "$ac_cv_path_CXX"; then
4752  ac_pt_CXX=$CXX
4753  # Extract the first word of "g++", so it can be a program name with args.
4754set dummy g++; ac_word=$2
4755{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4756$as_echo_n "checking for $ac_word... " >&6; }
4757if ${ac_cv_path_ac_pt_CXX+:} false; then :
4758  $as_echo_n "(cached) " >&6
4759else
4760  case $ac_pt_CXX in
4761  [\\/]* | ?:[\\/]*)
4762  ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
4763  ;;
4764  *)
4765  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4766for as_dir in notfound
4767do
4768  IFS=$as_save_IFS
4769  test -z "$as_dir" && as_dir=.
4770    for ac_exec_ext in '' $ac_executable_extensions; do
4771  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4772    ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext"
4773    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4774    break 2
4775  fi
4776done
4777  done
4778IFS=$as_save_IFS
4779
4780  ;;
4781esac
4782fi
4783ac_pt_CXX=$ac_cv_path_ac_pt_CXX
4784if test -n "$ac_pt_CXX"; then
4785  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
4786$as_echo "$ac_pt_CXX" >&6; }
4787else
4788  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4789$as_echo "no" >&6; }
4790fi
4791
4792  if test "x$ac_pt_CXX" = x; then
4793    CXX="g++"
4794  else
4795    case $cross_compiling:$ac_tool_warned in
4796yes:)
4797{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4798$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4799ac_tool_warned=yes ;;
4800esac
4801    CXX=$ac_pt_CXX
4802  fi
4803else
4804  CXX="$ac_cv_path_CXX"
4805fi
4806 ;;
4807        cc)     if test -n "$ac_tool_prefix"; then
4808  # Extract the first word of "${ac_tool_prefix}c++", so it can be a program name with args.
4809set dummy ${ac_tool_prefix}c++; ac_word=$2
4810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4811$as_echo_n "checking for $ac_word... " >&6; }
4812if ${ac_cv_path_CXX+:} false; then :
4813  $as_echo_n "(cached) " >&6
4814else
4815  case $CXX in
4816  [\\/]* | ?:[\\/]*)
4817  ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
4818  ;;
4819  *)
4820  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4821for as_dir in notfound
4822do
4823  IFS=$as_save_IFS
4824  test -z "$as_dir" && as_dir=.
4825    for ac_exec_ext in '' $ac_executable_extensions; do
4826  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4827    ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
4828    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4829    break 2
4830  fi
4831done
4832  done
4833IFS=$as_save_IFS
4834
4835  ;;
4836esac
4837fi
4838CXX=$ac_cv_path_CXX
4839if test -n "$CXX"; then
4840  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4841$as_echo "$CXX" >&6; }
4842else
4843  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4844$as_echo "no" >&6; }
4845fi
4846
4847
4848fi
4849if test -z "$ac_cv_path_CXX"; then
4850  ac_pt_CXX=$CXX
4851  # Extract the first word of "c++", so it can be a program name with args.
4852set dummy c++; ac_word=$2
4853{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4854$as_echo_n "checking for $ac_word... " >&6; }
4855if ${ac_cv_path_ac_pt_CXX+:} false; then :
4856  $as_echo_n "(cached) " >&6
4857else
4858  case $ac_pt_CXX in
4859  [\\/]* | ?:[\\/]*)
4860  ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
4861  ;;
4862  *)
4863  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4864for as_dir in notfound
4865do
4866  IFS=$as_save_IFS
4867  test -z "$as_dir" && as_dir=.
4868    for ac_exec_ext in '' $ac_executable_extensions; do
4869  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4870    ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext"
4871    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4872    break 2
4873  fi
4874done
4875  done
4876IFS=$as_save_IFS
4877
4878  ;;
4879esac
4880fi
4881ac_pt_CXX=$ac_cv_path_ac_pt_CXX
4882if test -n "$ac_pt_CXX"; then
4883  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
4884$as_echo "$ac_pt_CXX" >&6; }
4885else
4886  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4887$as_echo "no" >&6; }
4888fi
4889
4890  if test "x$ac_pt_CXX" = x; then
4891    CXX="c++"
4892  else
4893    case $cross_compiling:$ac_tool_warned in
4894yes:)
4895{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4896$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4897ac_tool_warned=yes ;;
4898esac
4899    CXX=$ac_pt_CXX
4900  fi
4901else
4902  CXX="$ac_cv_path_CXX"
4903fi
4904 ;;
4905        clang|*/clang)     if test -n "$ac_tool_prefix"; then
4906  # Extract the first word of "${ac_tool_prefix}clang++", so it can be a program name with args.
4907set dummy ${ac_tool_prefix}clang++; ac_word=$2
4908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4909$as_echo_n "checking for $ac_word... " >&6; }
4910if ${ac_cv_path_CXX+:} false; then :
4911  $as_echo_n "(cached) " >&6
4912else
4913  case $CXX in
4914  [\\/]* | ?:[\\/]*)
4915  ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
4916  ;;
4917  *)
4918  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4919for as_dir in notfound
4920do
4921  IFS=$as_save_IFS
4922  test -z "$as_dir" && as_dir=.
4923    for ac_exec_ext in '' $ac_executable_extensions; do
4924  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4925    ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
4926    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4927    break 2
4928  fi
4929done
4930  done
4931IFS=$as_save_IFS
4932
4933  ;;
4934esac
4935fi
4936CXX=$ac_cv_path_CXX
4937if test -n "$CXX"; then
4938  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4939$as_echo "$CXX" >&6; }
4940else
4941  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4942$as_echo "no" >&6; }
4943fi
4944
4945
4946fi
4947if test -z "$ac_cv_path_CXX"; then
4948  ac_pt_CXX=$CXX
4949  # Extract the first word of "clang++", so it can be a program name with args.
4950set dummy clang++; ac_word=$2
4951{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4952$as_echo_n "checking for $ac_word... " >&6; }
4953if ${ac_cv_path_ac_pt_CXX+:} false; then :
4954  $as_echo_n "(cached) " >&6
4955else
4956  case $ac_pt_CXX in
4957  [\\/]* | ?:[\\/]*)
4958  ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
4959  ;;
4960  *)
4961  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4962for as_dir in notfound
4963do
4964  IFS=$as_save_IFS
4965  test -z "$as_dir" && as_dir=.
4966    for ac_exec_ext in '' $ac_executable_extensions; do
4967  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4968    ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext"
4969    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4970    break 2
4971  fi
4972done
4973  done
4974IFS=$as_save_IFS
4975
4976  ;;
4977esac
4978fi
4979ac_pt_CXX=$ac_cv_path_ac_pt_CXX
4980if test -n "$ac_pt_CXX"; then
4981  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
4982$as_echo "$ac_pt_CXX" >&6; }
4983else
4984  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4985$as_echo "no" >&6; }
4986fi
4987
4988  if test "x$ac_pt_CXX" = x; then
4989    CXX="clang++"
4990  else
4991    case $cross_compiling:$ac_tool_warned in
4992yes:)
4993{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4994$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4995ac_tool_warned=yes ;;
4996esac
4997    CXX=$ac_pt_CXX
4998  fi
4999else
5000  CXX="$ac_cv_path_CXX"
5001fi
5002 ;;
5003        icc|*/icc)         if test -n "$ac_tool_prefix"; then
5004  # Extract the first word of "${ac_tool_prefix}icpc", so it can be a program name with args.
5005set dummy ${ac_tool_prefix}icpc; ac_word=$2
5006{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5007$as_echo_n "checking for $ac_word... " >&6; }
5008if ${ac_cv_path_CXX+:} false; then :
5009  $as_echo_n "(cached) " >&6
5010else
5011  case $CXX in
5012  [\\/]* | ?:[\\/]*)
5013  ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
5014  ;;
5015  *)
5016  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5017for as_dir in notfound
5018do
5019  IFS=$as_save_IFS
5020  test -z "$as_dir" && as_dir=.
5021    for ac_exec_ext in '' $ac_executable_extensions; do
5022  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5023    ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
5024    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5025    break 2
5026  fi
5027done
5028  done
5029IFS=$as_save_IFS
5030
5031  ;;
5032esac
5033fi
5034CXX=$ac_cv_path_CXX
5035if test -n "$CXX"; then
5036  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5037$as_echo "$CXX" >&6; }
5038else
5039  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5040$as_echo "no" >&6; }
5041fi
5042
5043
5044fi
5045if test -z "$ac_cv_path_CXX"; then
5046  ac_pt_CXX=$CXX
5047  # Extract the first word of "icpc", so it can be a program name with args.
5048set dummy icpc; ac_word=$2
5049{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5050$as_echo_n "checking for $ac_word... " >&6; }
5051if ${ac_cv_path_ac_pt_CXX+:} false; then :
5052  $as_echo_n "(cached) " >&6
5053else
5054  case $ac_pt_CXX in
5055  [\\/]* | ?:[\\/]*)
5056  ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
5057  ;;
5058  *)
5059  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5060for as_dir in notfound
5061do
5062  IFS=$as_save_IFS
5063  test -z "$as_dir" && as_dir=.
5064    for ac_exec_ext in '' $ac_executable_extensions; do
5065  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5066    ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext"
5067    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5068    break 2
5069  fi
5070done
5071  done
5072IFS=$as_save_IFS
5073
5074  ;;
5075esac
5076fi
5077ac_pt_CXX=$ac_cv_path_ac_pt_CXX
5078if test -n "$ac_pt_CXX"; then
5079  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
5080$as_echo "$ac_pt_CXX" >&6; }
5081else
5082  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5083$as_echo "no" >&6; }
5084fi
5085
5086  if test "x$ac_pt_CXX" = x; then
5087    CXX="icpc"
5088  else
5089    case $cross_compiling:$ac_tool_warned in
5090yes:)
5091{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5092$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5093ac_tool_warned=yes ;;
5094esac
5095    CXX=$ac_pt_CXX
5096  fi
5097else
5098  CXX="$ac_cv_path_CXX"
5099fi
5100 ;;
5101        esac
5102	if test "$CXX" = "notfound"
5103	then
5104		CXX=""
5105	fi
5106fi
5107if test -z "$CXX"
5108then
5109	if test -n "$ac_tool_prefix"; then
5110  for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
5111  do
5112    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5113set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5114{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5115$as_echo_n "checking for $ac_word... " >&6; }
5116if ${ac_cv_prog_CXX+:} false; then :
5117  $as_echo_n "(cached) " >&6
5118else
5119  if test -n "$CXX"; then
5120  ac_cv_prog_CXX="$CXX" # Let the user override the test.
5121else
5122as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5123for as_dir in $PATH
5124do
5125  IFS=$as_save_IFS
5126  test -z "$as_dir" && as_dir=.
5127    for ac_exec_ext in '' $ac_executable_extensions; do
5128  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5129    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
5130    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5131    break 2
5132  fi
5133done
5134  done
5135IFS=$as_save_IFS
5136
5137fi
5138fi
5139CXX=$ac_cv_prog_CXX
5140if test -n "$CXX"; then
5141  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5142$as_echo "$CXX" >&6; }
5143else
5144  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5145$as_echo "no" >&6; }
5146fi
5147
5148
5149    test -n "$CXX" && break
5150  done
5151fi
5152if test -z "$CXX"; then
5153  ac_ct_CXX=$CXX
5154  for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
5155do
5156  # Extract the first word of "$ac_prog", so it can be a program name with args.
5157set dummy $ac_prog; ac_word=$2
5158{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5159$as_echo_n "checking for $ac_word... " >&6; }
5160if ${ac_cv_prog_ac_ct_CXX+:} false; then :
5161  $as_echo_n "(cached) " >&6
5162else
5163  if test -n "$ac_ct_CXX"; then
5164  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
5165else
5166as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5167for as_dir in $PATH
5168do
5169  IFS=$as_save_IFS
5170  test -z "$as_dir" && as_dir=.
5171    for ac_exec_ext in '' $ac_executable_extensions; do
5172  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5173    ac_cv_prog_ac_ct_CXX="$ac_prog"
5174    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5175    break 2
5176  fi
5177done
5178  done
5179IFS=$as_save_IFS
5180
5181fi
5182fi
5183ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
5184if test -n "$ac_ct_CXX"; then
5185  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
5186$as_echo "$ac_ct_CXX" >&6; }
5187else
5188  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5189$as_echo "no" >&6; }
5190fi
5191
5192
5193  test -n "$ac_ct_CXX" && break
5194done
5195
5196  if test "x$ac_ct_CXX" = x; then
5197    CXX="notfound"
5198  else
5199    case $cross_compiling:$ac_tool_warned in
5200yes:)
5201{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5202$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5203ac_tool_warned=yes ;;
5204esac
5205    CXX=$ac_ct_CXX
5206  fi
5207fi
5208
5209	if test "$CXX" = "notfound"
5210	then
5211		CXX=""
5212	fi
5213fi
5214if test "$preset_cxx" != "$CXX"
5215then
5216        { $as_echo "$as_me:${as_lineno-$LINENO}:
5217
5218  By default, distutils will build C++ extension modules with \"$CXX\".
5219  If this is not intended, then set CXX on the configure command line.
5220  " >&5
5221$as_echo "$as_me:
5222
5223  By default, distutils will build C++ extension modules with \"$CXX\".
5224  If this is not intended, then set CXX on the configure command line.
5225  " >&6;}
5226fi
5227
5228
5229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the platform triplet based on compiler characteristics" >&5
5230$as_echo_n "checking for the platform triplet based on compiler characteristics... " >&6; }
5231cat >> conftest.c <<EOF
5232#undef bfin
5233#undef cris
5234#undef fr30
5235#undef linux
5236#undef hppa
5237#undef hpux
5238#undef i386
5239#undef mips
5240#undef powerpc
5241#undef sparc
5242#undef unix
5243#if defined(__ANDROID__)
5244    # Android is not a multiarch system.
5245#elif defined(__linux__)
5246# if defined(__x86_64__) && defined(__LP64__)
5247        x86_64-linux-gnu
5248# elif defined(__x86_64__) && defined(__ILP32__)
5249        x86_64-linux-gnux32
5250# elif defined(__i386__)
5251        i386-linux-gnu
5252# elif defined(__aarch64__) && defined(__AARCH64EL__)
5253#  if defined(__ILP32__)
5254        aarch64_ilp32-linux-gnu
5255#  else
5256        aarch64-linux-gnu
5257#  endif
5258# elif defined(__aarch64__) && defined(__AARCH64EB__)
5259#  if defined(__ILP32__)
5260        aarch64_be_ilp32-linux-gnu
5261#  else
5262        aarch64_be-linux-gnu
5263#  endif
5264# elif defined(__alpha__)
5265        alpha-linux-gnu
5266# elif defined(__ARM_EABI__) && defined(__ARM_PCS_VFP)
5267#  if defined(__ARMEL__)
5268        arm-linux-gnueabihf
5269#  else
5270        armeb-linux-gnueabihf
5271#  endif
5272# elif defined(__ARM_EABI__) && !defined(__ARM_PCS_VFP)
5273#  if defined(__ARMEL__)
5274        arm-linux-gnueabi
5275#  else
5276        armeb-linux-gnueabi
5277#  endif
5278# elif defined(__hppa__)
5279        hppa-linux-gnu
5280# elif defined(__ia64__)
5281        ia64-linux-gnu
5282# elif defined(__m68k__) && !defined(__mcoldfire__)
5283        m68k-linux-gnu
5284# elif defined(__mips_hard_float) && defined(__mips_isa_rev) && (__mips_isa_rev >=6) && defined(_MIPSEL)
5285#  if _MIPS_SIM == _ABIO32
5286        mipsisa32r6el-linux-gnu
5287#  elif _MIPS_SIM == _ABIN32
5288        mipsisa64r6el-linux-gnuabin32
5289#  elif _MIPS_SIM == _ABI64
5290        mipsisa64r6el-linux-gnuabi64
5291#  else
5292#   error unknown platform triplet
5293#  endif
5294# elif defined(__mips_hard_float) && defined(__mips_isa_rev) && (__mips_isa_rev >=6)
5295#  if _MIPS_SIM == _ABIO32
5296        mipsisa32r6-linux-gnu
5297#  elif _MIPS_SIM == _ABIN32
5298        mipsisa64r6-linux-gnuabin32
5299#  elif _MIPS_SIM == _ABI64
5300        mipsisa64r6-linux-gnuabi64
5301#  else
5302#   error unknown platform triplet
5303#  endif
5304# elif defined(__mips_hard_float) && defined(_MIPSEL)
5305#  if _MIPS_SIM == _ABIO32
5306        mipsel-linux-gnu
5307#  elif _MIPS_SIM == _ABIN32
5308        mips64el-linux-gnuabin32
5309#  elif _MIPS_SIM == _ABI64
5310        mips64el-linux-gnuabi64
5311#  else
5312#   error unknown platform triplet
5313#  endif
5314# elif defined(__mips_hard_float)
5315#  if _MIPS_SIM == _ABIO32
5316        mips-linux-gnu
5317#  elif _MIPS_SIM == _ABIN32
5318        mips64-linux-gnuabin32
5319#  elif _MIPS_SIM == _ABI64
5320        mips64-linux-gnuabi64
5321#  else
5322#   error unknown platform triplet
5323#  endif
5324# elif defined(__or1k__)
5325        or1k-linux-gnu
5326# elif defined(__powerpc__) && defined(__SPE__)
5327        powerpc-linux-gnuspe
5328# elif defined(__powerpc64__)
5329#  if defined(__LITTLE_ENDIAN__)
5330        powerpc64le-linux-gnu
5331#  else
5332        powerpc64-linux-gnu
5333#  endif
5334# elif defined(__powerpc__)
5335        powerpc-linux-gnu
5336# elif defined(__s390x__)
5337        s390x-linux-gnu
5338# elif defined(__s390__)
5339        s390-linux-gnu
5340# elif defined(__sh__) && defined(__LITTLE_ENDIAN__)
5341        sh4-linux-gnu
5342# elif defined(__sparc__) && defined(__arch64__)
5343        sparc64-linux-gnu
5344# elif defined(__sparc__)
5345        sparc-linux-gnu
5346# elif defined(__riscv)
5347#  if __riscv_xlen == 32
5348        riscv32-linux-gnu
5349#  elif __riscv_xlen == 64
5350        riscv64-linux-gnu
5351#  else
5352#   error unknown platform triplet
5353#  endif
5354# else
5355#   error unknown platform triplet
5356# endif
5357#elif defined(__FreeBSD_kernel__)
5358# if defined(__LP64__)
5359        x86_64-kfreebsd-gnu
5360# elif defined(__i386__)
5361        i386-kfreebsd-gnu
5362# else
5363#   error unknown platform triplet
5364# endif
5365#elif defined(__gnu_hurd__)
5366        i386-gnu
5367#elif defined(__APPLE__)
5368        darwin
5369#elif defined(__VXWORKS__)
5370        vxworks
5371#else
5372# error unknown platform triplet
5373#endif
5374
5375EOF
5376
5377if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then
5378  PLATFORM_TRIPLET=`grep -v '^#' conftest.out | grep -v '^ *$' | tr -d ' 	'`
5379  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PLATFORM_TRIPLET" >&5
5380$as_echo "$PLATFORM_TRIPLET" >&6; }
5381else
5382  { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
5383$as_echo "none" >&6; }
5384fi
5385rm -f conftest.c conftest.out
5386
5387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for multiarch" >&5
5388$as_echo_n "checking for multiarch... " >&6; }
5389case $ac_sys_system in #(
5390  Darwin*) :
5391    MULTIARCH="" ;; #(
5392  FreeBSD*) :
5393    MULTIARCH="" ;; #(
5394  *) :
5395    MULTIARCH=$($CC --print-multiarch 2>/dev/null)
5396 ;;
5397esac
5398
5399{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MULTIARCH" >&5
5400$as_echo "$MULTIARCH" >&6; }
5401
5402if test x$PLATFORM_TRIPLET != x && test x$MULTIARCH != x; then
5403  if test x$PLATFORM_TRIPLET != x$MULTIARCH; then
5404    as_fn_error $? "internal configure error for the platform triplet, please file a bug report" "$LINENO" 5
5405  fi
5406elif test x$PLATFORM_TRIPLET != x && test x$MULTIARCH = x; then
5407  MULTIARCH=$PLATFORM_TRIPLET
5408fi
5409
5410
5411if test x$MULTIARCH != x; then
5412  MULTIARCH_CPPFLAGS="-DMULTIARCH=\\\"$MULTIARCH\\\""
5413fi
5414
5415
5416{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wl,--no-as-needed" >&5
5417$as_echo_n "checking for -Wl,--no-as-needed... " >&6; }
5418save_LDFLAGS="$LDFLAGS"
5419LDFLAGS="$LDFLAGS -Wl,--no-as-needed"
5420
5421cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5422/* end confdefs.h.  */
5423
5424int
5425main ()
5426{
5427
5428  ;
5429  return 0;
5430}
5431_ACEOF
5432if ac_fn_c_try_link "$LINENO"; then :
5433  NO_AS_NEEDED="-Wl,--no-as-needed"
5434   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5435$as_echo "yes" >&6; }
5436else
5437  NO_AS_NEEDED=""
5438   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5439$as_echo "no" >&6; }
5440fi
5441rm -f core conftest.err conftest.$ac_objext \
5442    conftest$ac_exeext conftest.$ac_ext
5443LDFLAGS="$save_LDFLAGS"
5444
5445
5446
5447# checks for UNIX variants that set C preprocessor variables
5448
5449{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5450$as_echo_n "checking for egrep... " >&6; }
5451if ${ac_cv_path_EGREP+:} false; then :
5452  $as_echo_n "(cached) " >&6
5453else
5454  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5455   then ac_cv_path_EGREP="$GREP -E"
5456   else
5457     if test -z "$EGREP"; then
5458  ac_path_EGREP_found=false
5459  # Loop through the user's path and test for each of PROGNAME-LIST
5460  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5461for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5462do
5463  IFS=$as_save_IFS
5464  test -z "$as_dir" && as_dir=.
5465    for ac_prog in egrep; do
5466    for ac_exec_ext in '' $ac_executable_extensions; do
5467      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5468      as_fn_executable_p "$ac_path_EGREP" || continue
5469# Check for GNU ac_path_EGREP and select it if it is found.
5470  # Check for GNU $ac_path_EGREP
5471case `"$ac_path_EGREP" --version 2>&1` in
5472*GNU*)
5473  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5474*)
5475  ac_count=0
5476  $as_echo_n 0123456789 >"conftest.in"
5477  while :
5478  do
5479    cat "conftest.in" "conftest.in" >"conftest.tmp"
5480    mv "conftest.tmp" "conftest.in"
5481    cp "conftest.in" "conftest.nl"
5482    $as_echo 'EGREP' >> "conftest.nl"
5483    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5484    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5485    as_fn_arith $ac_count + 1 && ac_count=$as_val
5486    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5487      # Best one so far, save it but keep looking for a better one
5488      ac_cv_path_EGREP="$ac_path_EGREP"
5489      ac_path_EGREP_max=$ac_count
5490    fi
5491    # 10*(2^10) chars as input seems more than enough
5492    test $ac_count -gt 10 && break
5493  done
5494  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5495esac
5496
5497      $ac_path_EGREP_found && break 3
5498    done
5499  done
5500  done
5501IFS=$as_save_IFS
5502  if test -z "$ac_cv_path_EGREP"; then
5503    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5504  fi
5505else
5506  ac_cv_path_EGREP=$EGREP
5507fi
5508
5509   fi
5510fi
5511{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5512$as_echo "$ac_cv_path_EGREP" >&6; }
5513 EGREP="$ac_cv_path_EGREP"
5514
5515
5516{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5517$as_echo_n "checking for ANSI C header files... " >&6; }
5518if ${ac_cv_header_stdc+:} false; then :
5519  $as_echo_n "(cached) " >&6
5520else
5521  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5522/* end confdefs.h.  */
5523#include <stdlib.h>
5524#include <stdarg.h>
5525#include <string.h>
5526#include <float.h>
5527
5528int
5529main ()
5530{
5531
5532  ;
5533  return 0;
5534}
5535_ACEOF
5536if ac_fn_c_try_compile "$LINENO"; then :
5537  ac_cv_header_stdc=yes
5538else
5539  ac_cv_header_stdc=no
5540fi
5541rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5542
5543if test $ac_cv_header_stdc = yes; then
5544  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5545  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5546/* end confdefs.h.  */
5547#include <string.h>
5548
5549_ACEOF
5550if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5551  $EGREP "memchr" >/dev/null 2>&1; then :
5552
5553else
5554  ac_cv_header_stdc=no
5555fi
5556rm -f conftest*
5557
5558fi
5559
5560if test $ac_cv_header_stdc = yes; then
5561  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5562  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5563/* end confdefs.h.  */
5564#include <stdlib.h>
5565
5566_ACEOF
5567if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5568  $EGREP "free" >/dev/null 2>&1; then :
5569
5570else
5571  ac_cv_header_stdc=no
5572fi
5573rm -f conftest*
5574
5575fi
5576
5577if test $ac_cv_header_stdc = yes; then
5578  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5579  if test "$cross_compiling" = yes; then :
5580  :
5581else
5582  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5583/* end confdefs.h.  */
5584#include <ctype.h>
5585#include <stdlib.h>
5586#if ((' ' & 0x0FF) == 0x020)
5587# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5588# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5589#else
5590# define ISLOWER(c) \
5591		   (('a' <= (c) && (c) <= 'i') \
5592		     || ('j' <= (c) && (c) <= 'r') \
5593		     || ('s' <= (c) && (c) <= 'z'))
5594# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5595#endif
5596
5597#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5598int
5599main ()
5600{
5601  int i;
5602  for (i = 0; i < 256; i++)
5603    if (XOR (islower (i), ISLOWER (i))
5604	|| toupper (i) != TOUPPER (i))
5605      return 2;
5606  return 0;
5607}
5608_ACEOF
5609if ac_fn_c_try_run "$LINENO"; then :
5610
5611else
5612  ac_cv_header_stdc=no
5613fi
5614rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5615  conftest.$ac_objext conftest.beam conftest.$ac_ext
5616fi
5617
5618fi
5619fi
5620{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
5621$as_echo "$ac_cv_header_stdc" >&6; }
5622if test $ac_cv_header_stdc = yes; then
5623
5624$as_echo "#define STDC_HEADERS 1" >>confdefs.h
5625
5626fi
5627
5628# On IRIX 5.3, sys/types and inttypes.h are conflicting.
5629for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5630		  inttypes.h stdint.h unistd.h
5631do :
5632  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5633ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
5634"
5635if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
5636  cat >>confdefs.h <<_ACEOF
5637#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5638_ACEOF
5639
5640fi
5641
5642done
5643
5644
5645
5646  ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
5647if test "x$ac_cv_header_minix_config_h" = xyes; then :
5648  MINIX=yes
5649else
5650  MINIX=
5651fi
5652
5653
5654  if test "$MINIX" = yes; then
5655
5656$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
5657
5658
5659$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
5660
5661
5662$as_echo "#define _MINIX 1" >>confdefs.h
5663
5664  fi
5665
5666
5667  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5668$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5669if ${ac_cv_safe_to_define___extensions__+:} false; then :
5670  $as_echo_n "(cached) " >&6
5671else
5672  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5673/* end confdefs.h.  */
5674
5675#         define __EXTENSIONS__ 1
5676          $ac_includes_default
5677int
5678main ()
5679{
5680
5681  ;
5682  return 0;
5683}
5684_ACEOF
5685if ac_fn_c_try_compile "$LINENO"; then :
5686  ac_cv_safe_to_define___extensions__=yes
5687else
5688  ac_cv_safe_to_define___extensions__=no
5689fi
5690rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5691fi
5692{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5693$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5694  test $ac_cv_safe_to_define___extensions__ = yes &&
5695    $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5696
5697  $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5698
5699  $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5700
5701  $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5702
5703  $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5704
5705
5706
5707{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the Android API level" >&5
5708$as_echo_n "checking for the Android API level... " >&6; }
5709cat >> conftest.c <<EOF
5710#ifdef __ANDROID__
5711android_api = __ANDROID_API__
5712arm_arch = __ARM_ARCH
5713#else
5714#error not Android
5715#endif
5716EOF
5717
5718if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then
5719  ANDROID_API_LEVEL=`sed -n -e '/__ANDROID_API__/d' -e 's/^android_api = //p' conftest.out`
5720  _arm_arch=`sed -n -e '/__ARM_ARCH/d' -e 's/^arm_arch = //p' conftest.out`
5721  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ANDROID_API_LEVEL" >&5
5722$as_echo "$ANDROID_API_LEVEL" >&6; }
5723  if test -z "$ANDROID_API_LEVEL"; then
5724    echo 'Fatal: you must define __ANDROID_API__'
5725    exit 1
5726  fi
5727
5728cat >>confdefs.h <<_ACEOF
5729#define ANDROID_API_LEVEL $ANDROID_API_LEVEL
5730_ACEOF
5731
5732
5733  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the Android arm ABI" >&5
5734$as_echo_n "checking for the Android arm ABI... " >&6; }
5735  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_arm_arch" >&5
5736$as_echo "$_arm_arch" >&6; }
5737  if test "$_arm_arch" = 7; then
5738    BASECFLAGS="${BASECFLAGS} -mfloat-abi=softfp -mfpu=vfpv3-d16"
5739    LDFLAGS="${LDFLAGS} -march=armv7-a -Wl,--fix-cortex-a8"
5740  fi
5741else
5742  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not Android" >&5
5743$as_echo "not Android" >&6; }
5744fi
5745rm -f conftest.c conftest.out
5746
5747# Check for unsupported systems
5748case $ac_sys_system/$ac_sys_release in
5749atheos*|Linux*/1*)
5750   echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
5751   echo See README for details.
5752   exit 1;;
5753esac
5754
5755
5756{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5
5757$as_echo_n "checking for --with-suffix... " >&6; }
5758
5759# Check whether --with-suffix was given.
5760if test "${with_suffix+set}" = set; then :
5761  withval=$with_suffix;
5762	case $withval in
5763	no)	EXEEXT=;;
5764	yes)	EXEEXT=.exe;;
5765	*)	EXEEXT=$withval;;
5766	esac
5767fi
5768
5769{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5
5770$as_echo "$EXEEXT" >&6; }
5771
5772# Test whether we're running on a non-case-sensitive system, in which
5773# case we give a warning if no ext is given
5774
5775{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5
5776$as_echo_n "checking for case-insensitive build directory... " >&6; }
5777if test ! -d CaseSensitiveTestDir; then
5778mkdir CaseSensitiveTestDir
5779fi
5780
5781if test -d casesensitivetestdir
5782then
5783    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5784$as_echo "yes" >&6; }
5785    BUILDEXEEXT=.exe
5786else
5787	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5788$as_echo "no" >&6; }
5789	BUILDEXEEXT=$EXEEXT
5790fi
5791rmdir CaseSensitiveTestDir
5792
5793case $ac_sys_system in
5794hp*|HP*)
5795    case $CC in
5796    cc|*/cc) CC="$CC -Ae";;
5797    esac;;
5798esac
5799
5800
5801{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5
5802$as_echo_n "checking LIBRARY... " >&6; }
5803if test -z "$LIBRARY"
5804then
5805	LIBRARY='libpython$(VERSION)$(ABIFLAGS).a'
5806fi
5807{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5
5808$as_echo "$LIBRARY" >&6; }
5809
5810# LDLIBRARY is the name of the library to link against (as opposed to the
5811# name of the library into which to insert object files). BLDLIBRARY is also
5812# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
5813# is blank as the main program is not linked directly against LDLIBRARY.
5814# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
5815# systems without shared libraries, LDLIBRARY is the same as LIBRARY
5816# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
5817# DLLLIBRARY is the shared (i.e., DLL) library.
5818#
5819# RUNSHARED is used to run shared python without installed libraries
5820#
5821# INSTSONAME is the name of the shared library that will be use to install
5822# on the system - some systems like version suffix, others don't
5823#
5824# LDVERSION is the shared library version number, normally the Python version
5825# with the ABI build flags appended.
5826
5827
5828
5829
5830
5831
5832
5833
5834LDLIBRARY="$LIBRARY"
5835BLDLIBRARY='$(LDLIBRARY)'
5836INSTSONAME='$(LDLIBRARY)'
5837DLLLIBRARY=''
5838LDLIBRARYDIR=''
5839RUNSHARED=''
5840LDVERSION="$VERSION"
5841
5842# LINKCC is the command that links the python executable -- default is $(CC).
5843# If CXX is set, and if it is needed to link a main function that was
5844# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
5845# python might then depend on the C++ runtime
5846
5847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5
5848$as_echo_n "checking LINKCC... " >&6; }
5849if test -z "$LINKCC"
5850then
5851	LINKCC='$(PURIFY) $(MAINCC)'
5852	case $ac_sys_system in
5853	QNX*)
5854	   # qcc must be used because the other compilers do not
5855	   # support -N.
5856	   LINKCC=qcc;;
5857	esac
5858fi
5859{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5
5860$as_echo "$LINKCC" >&6; }
5861
5862# EXPORTSYMS holds the list of exported symbols for AIX.
5863# EXPORTSFROM holds the module name exporting symbols on AIX.
5864EXPORTSYMS=
5865EXPORTSFROM=
5866
5867
5868{ $as_echo "$as_me:${as_lineno-$LINENO}: checking EXPORTSYMS" >&5
5869$as_echo_n "checking EXPORTSYMS... " >&6; }
5870case $ac_sys_system in
5871AIX*)
5872	EXPORTSYMS="Modules/python.exp"
5873	EXPORTSFROM=. # the main executable
5874	;;
5875esac
5876{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPORTSYMS" >&5
5877$as_echo "$EXPORTSYMS" >&6; }
5878
5879# GNULD is set to "yes" if the GNU linker is used.  If this goes wrong
5880# make sure we default having it set to "no": this is used by
5881# distutils.unixccompiler to know if it should add --enable-new-dtags
5882# to linker command lines, and failing to detect GNU ld simply results
5883# in the same bahaviour as before.
5884
5885{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
5886$as_echo_n "checking for GNU ld... " >&6; }
5887ac_prog=ld
5888if test "$GCC" = yes; then
5889       ac_prog=`$CC -print-prog-name=ld`
5890fi
5891case `"$ac_prog" -V 2>&1 < /dev/null` in
5892      *GNU*)
5893          GNULD=yes;;
5894      *)
5895          GNULD=no;;
5896esac
5897{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5
5898$as_echo "$GNULD" >&6; }
5899
5900{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5
5901$as_echo_n "checking for --enable-shared... " >&6; }
5902# Check whether --enable-shared was given.
5903if test "${enable_shared+set}" = set; then :
5904  enableval=$enable_shared;
5905fi
5906
5907
5908if test -z "$enable_shared"
5909then
5910  case $ac_sys_system in
5911  CYGWIN*)
5912    enable_shared="yes";;
5913  *)
5914    enable_shared="no";;
5915  esac
5916fi
5917{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
5918$as_echo "$enable_shared" >&6; }
5919
5920{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5
5921$as_echo_n "checking for --enable-profiling... " >&6; }
5922# Check whether --enable-profiling was given.
5923if test "${enable_profiling+set}" = set; then :
5924  enableval=$enable_profiling;
5925fi
5926
5927if test "x$enable_profiling" = xyes; then
5928  ac_save_cc="$CC"
5929  CC="$CC -pg"
5930  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5931/* end confdefs.h.  */
5932int main() { return 0; }
5933_ACEOF
5934if ac_fn_c_try_link "$LINENO"; then :
5935
5936else
5937  enable_profiling=no
5938fi
5939rm -f core conftest.err conftest.$ac_objext \
5940    conftest$ac_exeext conftest.$ac_ext
5941  CC="$ac_save_cc"
5942else
5943  enable_profiling=no
5944fi
5945{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_profiling" >&5
5946$as_echo "$enable_profiling" >&6; }
5947
5948if test "x$enable_profiling" = xyes; then
5949  BASECFLAGS="-pg $BASECFLAGS"
5950  LDFLAGS="-pg $LDFLAGS"
5951fi
5952
5953{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5
5954$as_echo_n "checking LDLIBRARY... " >&6; }
5955
5956# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
5957# library that we build, but we do not want to link against it (we
5958# will find it with a -framework option). For this reason there is an
5959# extra variable BLDLIBRARY against which Python and the extension
5960# modules are linked, BLDLIBRARY. This is normally the same as
5961# LDLIBRARY, but empty for MacOSX framework builds.
5962if test "$enable_framework"
5963then
5964  LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
5965  RUNSHARED=DYLD_FRAMEWORK_PATH=`pwd`${DYLD_FRAMEWORK_PATH:+:${DYLD_FRAMEWORK_PATH}}
5966  BLDLIBRARY=''
5967else
5968  BLDLIBRARY='$(LDLIBRARY)'
5969fi
5970
5971# Other platforms follow
5972if test $enable_shared = "yes"; then
5973  PY_ENABLE_SHARED=1
5974
5975$as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h
5976
5977  case $ac_sys_system in
5978    CYGWIN*)
5979          LDLIBRARY='libpython$(LDVERSION).dll.a'
5980          DLLLIBRARY='libpython$(LDVERSION).dll'
5981          ;;
5982    SunOS*)
5983	  LDLIBRARY='libpython$(LDVERSION).so'
5984	  BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)'
5985	  RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
5986	  INSTSONAME="$LDLIBRARY".$SOVERSION
5987	  if test "$with_pydebug" != yes
5988	  then
5989	      PY3LIBRARY=libpython3.so
5990	  fi
5991          ;;
5992    Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*|VxWorks*)
5993	  LDLIBRARY='libpython$(LDVERSION).so'
5994	  BLDLIBRARY='-L. -lpython$(LDVERSION)'
5995	  RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
5996	  INSTSONAME="$LDLIBRARY".$SOVERSION
5997	  if test "$with_pydebug" != yes
5998          then
5999	      PY3LIBRARY=libpython3.so
6000	  fi
6001	  ;;
6002    hp*|HP*)
6003	  case `uname -m` in
6004		ia64)
6005			LDLIBRARY='libpython$(LDVERSION).so'
6006			;;
6007		*)
6008			LDLIBRARY='libpython$(LDVERSION).sl'
6009			;;
6010	  esac
6011	  BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(LDVERSION)'
6012	  RUNSHARED=SHLIB_PATH=`pwd`${SHLIB_PATH:+:${SHLIB_PATH}}
6013	  ;;
6014    Darwin*)
6015    	LDLIBRARY='libpython$(LDVERSION).dylib'
6016	BLDLIBRARY='-L. -lpython$(LDVERSION)'
6017	RUNSHARED=DYLD_LIBRARY_PATH=`pwd`${DYLD_LIBRARY_PATH:+:${DYLD_LIBRARY_PATH}}
6018	;;
6019    AIX*)
6020	LDLIBRARY='libpython$(LDVERSION).so'
6021	RUNSHARED=LIBPATH=`pwd`${LIBPATH:+:${LIBPATH}}
6022	;;
6023
6024  esac
6025else # shared is disabled
6026  PY_ENABLE_SHARED=0
6027  case $ac_sys_system in
6028    CYGWIN*)
6029          BLDLIBRARY='$(LIBRARY)'
6030          LDLIBRARY='libpython$(LDVERSION).dll.a'
6031          ;;
6032  esac
6033fi
6034
6035if test "$cross_compiling" = yes; then
6036	RUNSHARED=
6037fi
6038
6039{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5
6040$as_echo "$LDLIBRARY" >&6; }
6041
6042
6043if test -n "$ac_tool_prefix"; then
6044  for ac_prog in ar aal
6045  do
6046    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6047set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6048{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6049$as_echo_n "checking for $ac_word... " >&6; }
6050if ${ac_cv_prog_AR+:} false; then :
6051  $as_echo_n "(cached) " >&6
6052else
6053  if test -n "$AR"; then
6054  ac_cv_prog_AR="$AR" # Let the user override the test.
6055else
6056as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6057for as_dir in $PATH
6058do
6059  IFS=$as_save_IFS
6060  test -z "$as_dir" && as_dir=.
6061    for ac_exec_ext in '' $ac_executable_extensions; do
6062  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6063    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
6064    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6065    break 2
6066  fi
6067done
6068  done
6069IFS=$as_save_IFS
6070
6071fi
6072fi
6073AR=$ac_cv_prog_AR
6074if test -n "$AR"; then
6075  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6076$as_echo "$AR" >&6; }
6077else
6078  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6079$as_echo "no" >&6; }
6080fi
6081
6082
6083    test -n "$AR" && break
6084  done
6085fi
6086if test -z "$AR"; then
6087  ac_ct_AR=$AR
6088  for ac_prog in ar aal
6089do
6090  # Extract the first word of "$ac_prog", so it can be a program name with args.
6091set dummy $ac_prog; ac_word=$2
6092{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6093$as_echo_n "checking for $ac_word... " >&6; }
6094if ${ac_cv_prog_ac_ct_AR+:} false; then :
6095  $as_echo_n "(cached) " >&6
6096else
6097  if test -n "$ac_ct_AR"; then
6098  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6099else
6100as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6101for as_dir in $PATH
6102do
6103  IFS=$as_save_IFS
6104  test -z "$as_dir" && as_dir=.
6105    for ac_exec_ext in '' $ac_executable_extensions; do
6106  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6107    ac_cv_prog_ac_ct_AR="$ac_prog"
6108    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6109    break 2
6110  fi
6111done
6112  done
6113IFS=$as_save_IFS
6114
6115fi
6116fi
6117ac_ct_AR=$ac_cv_prog_ac_ct_AR
6118if test -n "$ac_ct_AR"; then
6119  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6120$as_echo "$ac_ct_AR" >&6; }
6121else
6122  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6123$as_echo "no" >&6; }
6124fi
6125
6126
6127  test -n "$ac_ct_AR" && break
6128done
6129
6130  if test "x$ac_ct_AR" = x; then
6131    AR="ar"
6132  else
6133    case $cross_compiling:$ac_tool_warned in
6134yes:)
6135{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6136$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6137ac_tool_warned=yes ;;
6138esac
6139    AR=$ac_ct_AR
6140  fi
6141fi
6142
6143
6144# tweak ARFLAGS only if the user didn't set it on the command line
6145
6146if test -z "$ARFLAGS"
6147then
6148        ARFLAGS="rcs"
6149fi
6150
6151if test -n "$ac_tool_prefix"; then
6152  for ac_prog in readelf
6153  do
6154    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6155set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6156{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6157$as_echo_n "checking for $ac_word... " >&6; }
6158if ${ac_cv_prog_READELF+:} false; then :
6159  $as_echo_n "(cached) " >&6
6160else
6161  if test -n "$READELF"; then
6162  ac_cv_prog_READELF="$READELF" # Let the user override the test.
6163else
6164as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6165for as_dir in $PATH
6166do
6167  IFS=$as_save_IFS
6168  test -z "$as_dir" && as_dir=.
6169    for ac_exec_ext in '' $ac_executable_extensions; do
6170  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6171    ac_cv_prog_READELF="$ac_tool_prefix$ac_prog"
6172    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6173    break 2
6174  fi
6175done
6176  done
6177IFS=$as_save_IFS
6178
6179fi
6180fi
6181READELF=$ac_cv_prog_READELF
6182if test -n "$READELF"; then
6183  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
6184$as_echo "$READELF" >&6; }
6185else
6186  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6187$as_echo "no" >&6; }
6188fi
6189
6190
6191    test -n "$READELF" && break
6192  done
6193fi
6194if test -z "$READELF"; then
6195  ac_ct_READELF=$READELF
6196  for ac_prog in readelf
6197do
6198  # Extract the first word of "$ac_prog", so it can be a program name with args.
6199set dummy $ac_prog; ac_word=$2
6200{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6201$as_echo_n "checking for $ac_word... " >&6; }
6202if ${ac_cv_prog_ac_ct_READELF+:} false; then :
6203  $as_echo_n "(cached) " >&6
6204else
6205  if test -n "$ac_ct_READELF"; then
6206  ac_cv_prog_ac_ct_READELF="$ac_ct_READELF" # Let the user override the test.
6207else
6208as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6209for as_dir in $PATH
6210do
6211  IFS=$as_save_IFS
6212  test -z "$as_dir" && as_dir=.
6213    for ac_exec_ext in '' $ac_executable_extensions; do
6214  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6215    ac_cv_prog_ac_ct_READELF="$ac_prog"
6216    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6217    break 2
6218  fi
6219done
6220  done
6221IFS=$as_save_IFS
6222
6223fi
6224fi
6225ac_ct_READELF=$ac_cv_prog_ac_ct_READELF
6226if test -n "$ac_ct_READELF"; then
6227  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_READELF" >&5
6228$as_echo "$ac_ct_READELF" >&6; }
6229else
6230  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6231$as_echo "no" >&6; }
6232fi
6233
6234
6235  test -n "$ac_ct_READELF" && break
6236done
6237
6238  if test "x$ac_ct_READELF" = x; then
6239    READELF=":"
6240  else
6241    case $cross_compiling:$ac_tool_warned in
6242yes:)
6243{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6244$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6245ac_tool_warned=yes ;;
6246esac
6247    READELF=$ac_ct_READELF
6248  fi
6249fi
6250
6251if test "$cross_compiling" = yes; then
6252    case "$READELF" in
6253	readelf|:)
6254	as_fn_error $? "readelf for the host is required for cross builds" "$LINENO" 5
6255	;;
6256    esac
6257fi
6258
6259
6260
6261case $MACHDEP in
6262hp*|HP*)
6263	# install -d does not work on HP-UX
6264	if test -z "$INSTALL"
6265	then
6266		INSTALL="${srcdir}/install-sh -c"
6267	fi
6268esac
6269# Find a good install program.  We prefer a C program (faster),
6270# so one script is as good as another.  But avoid the broken or
6271# incompatible versions:
6272# SysV /etc/install, /usr/sbin/install
6273# SunOS /usr/etc/install
6274# IRIX /sbin/install
6275# AIX /bin/install
6276# AmigaOS /C/install, which installs bootblocks on floppy discs
6277# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6278# AFS /usr/afsws/bin/install, which mishandles nonexistent args
6279# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6280# OS/2's system install, which has a completely different semantic
6281# ./install, which can be erroneously created by make from ./install.sh.
6282# Reject install programs that cannot install multiple files.
6283{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
6284$as_echo_n "checking for a BSD-compatible install... " >&6; }
6285if test -z "$INSTALL"; then
6286if ${ac_cv_path_install+:} false; then :
6287  $as_echo_n "(cached) " >&6
6288else
6289  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6290for as_dir in $PATH
6291do
6292  IFS=$as_save_IFS
6293  test -z "$as_dir" && as_dir=.
6294    # Account for people who put trailing slashes in PATH elements.
6295case $as_dir/ in #((
6296  ./ | .// | /[cC]/* | \
6297  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
6298  ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
6299  /usr/ucb/* ) ;;
6300  *)
6301    # OSF1 and SCO ODT 3.0 have their own names for install.
6302    # Don't use installbsd from OSF since it installs stuff as root
6303    # by default.
6304    for ac_prog in ginstall scoinst install; do
6305      for ac_exec_ext in '' $ac_executable_extensions; do
6306	if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
6307	  if test $ac_prog = install &&
6308	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6309	    # AIX install.  It has an incompatible calling convention.
6310	    :
6311	  elif test $ac_prog = install &&
6312	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6313	    # program-specific install script used by HP pwplus--don't use.
6314	    :
6315	  else
6316	    rm -rf conftest.one conftest.two conftest.dir
6317	    echo one > conftest.one
6318	    echo two > conftest.two
6319	    mkdir conftest.dir
6320	    if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
6321	      test -s conftest.one && test -s conftest.two &&
6322	      test -s conftest.dir/conftest.one &&
6323	      test -s conftest.dir/conftest.two
6324	    then
6325	      ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
6326	      break 3
6327	    fi
6328	  fi
6329	fi
6330      done
6331    done
6332    ;;
6333esac
6334
6335  done
6336IFS=$as_save_IFS
6337
6338rm -rf conftest.one conftest.two conftest.dir
6339
6340fi
6341  if test "${ac_cv_path_install+set}" = set; then
6342    INSTALL=$ac_cv_path_install
6343  else
6344    # As a last resort, use the slow shell script.  Don't cache a
6345    # value for INSTALL within a source directory, because that will
6346    # break other packages using the cache if that directory is
6347    # removed, or if the value is a relative name.
6348    INSTALL=$ac_install_sh
6349  fi
6350fi
6351{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
6352$as_echo "$INSTALL" >&6; }
6353
6354# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6355# It thinks the first close brace ends the variable substitution.
6356test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6357
6358test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6359
6360test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6361
6362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
6363$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6364if test -z "$MKDIR_P"; then
6365  if ${ac_cv_path_mkdir+:} false; then :
6366  $as_echo_n "(cached) " >&6
6367else
6368  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6369for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6370do
6371  IFS=$as_save_IFS
6372  test -z "$as_dir" && as_dir=.
6373    for ac_prog in mkdir gmkdir; do
6374	 for ac_exec_ext in '' $ac_executable_extensions; do
6375	   as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
6376	   case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6377	     'mkdir (GNU coreutils) '* | \
6378	     'mkdir (coreutils) '* | \
6379	     'mkdir (fileutils) '4.1*)
6380	       ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6381	       break 3;;
6382	   esac
6383	 done
6384       done
6385  done
6386IFS=$as_save_IFS
6387
6388fi
6389
6390  test -d ./--version && rmdir ./--version
6391  if test "${ac_cv_path_mkdir+set}" = set; then
6392    MKDIR_P="$ac_cv_path_mkdir -p"
6393  else
6394    # As a last resort, use the slow shell script.  Don't cache a
6395    # value for MKDIR_P within a source directory, because that will
6396    # break other packages using the cache if that directory is
6397    # removed, or if the value is a relative name.
6398    MKDIR_P="$ac_install_sh -d"
6399  fi
6400fi
6401{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
6402$as_echo "$MKDIR_P" >&6; }
6403
6404
6405# Not every filesystem supports hard links
6406
6407if test -z "$LN" ; then
6408	case $ac_sys_system in
6409		CYGWIN*) LN="ln -s";;
6410		*) LN=ln;;
6411	esac
6412fi
6413
6414# For calculating the .so ABI tag.
6415
6416ABIFLAGS=""
6417
6418# Check for --with-pydebug
6419{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5
6420$as_echo_n "checking for --with-pydebug... " >&6; }
6421
6422# Check whether --with-pydebug was given.
6423if test "${with_pydebug+set}" = set; then :
6424  withval=$with_pydebug;
6425if test "$withval" != no
6426then
6427
6428$as_echo "#define Py_DEBUG 1" >>confdefs.h
6429
6430  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6431$as_echo "yes" >&6; };
6432  Py_DEBUG='true'
6433  ABIFLAGS="${ABIFLAGS}d"
6434else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6435$as_echo "no" >&6; }; Py_DEBUG='false'
6436fi
6437else
6438  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6439$as_echo "no" >&6; }
6440fi
6441
6442
6443# Check for --with-trace-refs
6444# --with-trace-refs
6445{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-trace-refs" >&5
6446$as_echo_n "checking for --with-trace-refs... " >&6; }
6447
6448# Check whether --with-trace-refs was given.
6449if test "${with_trace_refs+set}" = set; then :
6450  withval=$with_trace_refs;
6451else
6452  with_trace_refs=no
6453fi
6454
6455{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_trace_refs" >&5
6456$as_echo "$with_trace_refs" >&6; }
6457
6458if test "$with_trace_refs" = "yes"
6459then
6460
6461$as_echo "#define Py_TRACE_REFS 1" >>confdefs.h
6462
6463fi
6464
6465# Check for --with-assertions.
6466# This allows enabling assertions without Py_DEBUG.
6467assertions='false'
6468{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-assertions" >&5
6469$as_echo_n "checking for --with-assertions... " >&6; }
6470
6471# Check whether --with-assertions was given.
6472if test "${with_assertions+set}" = set; then :
6473  withval=$with_assertions;
6474if test "$withval" != no
6475then
6476  assertions='true'
6477fi
6478fi
6479
6480if test "$assertions" = 'true'; then
6481  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6482$as_echo "yes" >&6; }
6483elif test "$Py_DEBUG" = 'true'; then
6484  assertions='true'
6485  { $as_echo "$as_me:${as_lineno-$LINENO}: result: implied by --with-pydebug" >&5
6486$as_echo "implied by --with-pydebug" >&6; }
6487else
6488  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6489$as_echo "no" >&6; }
6490fi
6491
6492# Enable optimization flags
6493
6494
6495Py_OPT='false'
6496{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-optimizations" >&5
6497$as_echo_n "checking for --enable-optimizations... " >&6; }
6498# Check whether --enable-optimizations was given.
6499if test "${enable_optimizations+set}" = set; then :
6500  enableval=$enable_optimizations;
6501if test "$enableval" != no
6502then
6503  Py_OPT='true'
6504  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6505$as_echo "yes" >&6; };
6506else
6507  Py_OPT='false'
6508  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6509$as_echo "no" >&6; };
6510fi
6511else
6512  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6513$as_echo "no" >&6; }
6514fi
6515
6516if test "$Py_OPT" = 'true' ; then
6517  # Intentionally not forcing Py_LTO='true' here.  Too many toolchains do not
6518  # compile working code using it and both test_distutils and test_gdb are
6519  # broken when you do manage to get a toolchain that works with it.  People
6520  # who want LTO need to use --with-lto themselves.
6521  DEF_MAKE_ALL_RULE="profile-opt"
6522  REQUIRE_PGO="yes"
6523  DEF_MAKE_RULE="build_all"
6524  case $CC in
6525    *gcc*)
6526      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-semantic-interposition" >&5
6527$as_echo_n "checking whether C compiler accepts -fno-semantic-interposition... " >&6; }
6528if ${ax_cv_check_cflags___fno_semantic_interposition+:} false; then :
6529  $as_echo_n "(cached) " >&6
6530else
6531
6532  ax_check_save_flags=$CFLAGS
6533  CFLAGS="$CFLAGS  -fno-semantic-interposition"
6534  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6535/* end confdefs.h.  */
6536
6537int
6538main ()
6539{
6540
6541  ;
6542  return 0;
6543}
6544_ACEOF
6545if ac_fn_c_try_compile "$LINENO"; then :
6546  ax_cv_check_cflags___fno_semantic_interposition=yes
6547else
6548  ax_cv_check_cflags___fno_semantic_interposition=no
6549fi
6550rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6551  CFLAGS=$ax_check_save_flags
6552fi
6553{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_semantic_interposition" >&5
6554$as_echo "$ax_cv_check_cflags___fno_semantic_interposition" >&6; }
6555if test "x$ax_cv_check_cflags___fno_semantic_interposition" = xyes; then :
6556
6557      CFLAGS_NODIST="$CFLAGS_NODIST -fno-semantic-interposition"
6558      LDFLAGS_NODIST="$LDFLAGS_NODIST -fno-semantic-interposition"
6559
6560else
6561  :
6562fi
6563
6564      ;;
6565  esac
6566
6567
6568else
6569  DEF_MAKE_ALL_RULE="build_all"
6570  REQUIRE_PGO="no"
6571  DEF_MAKE_RULE="all"
6572fi
6573
6574
6575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking PROFILE_TASK" >&5
6576$as_echo_n "checking PROFILE_TASK... " >&6; }
6577if test -z "$PROFILE_TASK"
6578then
6579	PROFILE_TASK='-m test --pgo --timeout=$(TESTTIMEOUT)'
6580fi
6581{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROFILE_TASK" >&5
6582$as_echo "$PROFILE_TASK" >&6; }
6583
6584# Make llvm-relatec checks work on systems where llvm tools are not installed with their
6585# normal names in the default $PATH (ie: Ubuntu).  They exist under the
6586# non-suffixed name in their versioned llvm directory.
6587
6588llvm_bin_dir=''
6589llvm_path="${PATH}"
6590if test "${CC}" = "clang"
6591then
6592  clang_bin=`which clang`
6593  # Some systems install clang elsewhere as a symlink to the real path
6594  # which is where the related llvm tools are located.
6595  if test -L "${clang_bin}"
6596  then
6597    clang_dir=`dirname "${clang_bin}"`
6598    clang_bin=`readlink "${clang_bin}"`
6599    llvm_bin_dir="${clang_dir}/"`dirname "${clang_bin}"`
6600    llvm_path="${llvm_path}${PATH_SEPARATOR}${llvm_bin_dir}"
6601  fi
6602fi
6603
6604# Enable LTO flags
6605{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-lto" >&5
6606$as_echo_n "checking for --with-lto... " >&6; }
6607
6608# Check whether --with-lto was given.
6609if test "${with_lto+set}" = set; then :
6610  withval=$with_lto;
6611if test "$withval" != no
6612then
6613  Py_LTO='true'
6614  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6615$as_echo "yes" >&6; };
6616else
6617  Py_LTO='false'
6618  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6619$as_echo "no" >&6; };
6620fi
6621else
6622  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6623$as_echo "no" >&6; }
6624fi
6625
6626if test "$Py_LTO" = 'true' ; then
6627  case $CC in
6628    *clang*)
6629
6630      if test -n "$ac_tool_prefix"; then
6631  # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args.
6632set dummy ${ac_tool_prefix}llvm-ar; ac_word=$2
6633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6634$as_echo_n "checking for $ac_word... " >&6; }
6635if ${ac_cv_path_LLVM_AR+:} false; then :
6636  $as_echo_n "(cached) " >&6
6637else
6638  case $LLVM_AR in
6639  [\\/]* | ?:[\\/]*)
6640  ac_cv_path_LLVM_AR="$LLVM_AR" # Let the user override the test with a path.
6641  ;;
6642  *)
6643  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6644for as_dir in ${llvm_path}
6645do
6646  IFS=$as_save_IFS
6647  test -z "$as_dir" && as_dir=.
6648    for ac_exec_ext in '' $ac_executable_extensions; do
6649  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6650    ac_cv_path_LLVM_AR="$as_dir/$ac_word$ac_exec_ext"
6651    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6652    break 2
6653  fi
6654done
6655  done
6656IFS=$as_save_IFS
6657
6658  ;;
6659esac
6660fi
6661LLVM_AR=$ac_cv_path_LLVM_AR
6662if test -n "$LLVM_AR"; then
6663  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_AR" >&5
6664$as_echo "$LLVM_AR" >&6; }
6665else
6666  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6667$as_echo "no" >&6; }
6668fi
6669
6670
6671fi
6672if test -z "$ac_cv_path_LLVM_AR"; then
6673  ac_pt_LLVM_AR=$LLVM_AR
6674  # Extract the first word of "llvm-ar", so it can be a program name with args.
6675set dummy llvm-ar; ac_word=$2
6676{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6677$as_echo_n "checking for $ac_word... " >&6; }
6678if ${ac_cv_path_ac_pt_LLVM_AR+:} false; then :
6679  $as_echo_n "(cached) " >&6
6680else
6681  case $ac_pt_LLVM_AR in
6682  [\\/]* | ?:[\\/]*)
6683  ac_cv_path_ac_pt_LLVM_AR="$ac_pt_LLVM_AR" # Let the user override the test with a path.
6684  ;;
6685  *)
6686  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6687for as_dir in ${llvm_path}
6688do
6689  IFS=$as_save_IFS
6690  test -z "$as_dir" && as_dir=.
6691    for ac_exec_ext in '' $ac_executable_extensions; do
6692  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6693    ac_cv_path_ac_pt_LLVM_AR="$as_dir/$ac_word$ac_exec_ext"
6694    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6695    break 2
6696  fi
6697done
6698  done
6699IFS=$as_save_IFS
6700
6701  ;;
6702esac
6703fi
6704ac_pt_LLVM_AR=$ac_cv_path_ac_pt_LLVM_AR
6705if test -n "$ac_pt_LLVM_AR"; then
6706  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LLVM_AR" >&5
6707$as_echo "$ac_pt_LLVM_AR" >&6; }
6708else
6709  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6710$as_echo "no" >&6; }
6711fi
6712
6713  if test "x$ac_pt_LLVM_AR" = x; then
6714    LLVM_AR="''"
6715  else
6716    case $cross_compiling:$ac_tool_warned in
6717yes:)
6718{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6719$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6720ac_tool_warned=yes ;;
6721esac
6722    LLVM_AR=$ac_pt_LLVM_AR
6723  fi
6724else
6725  LLVM_AR="$ac_cv_path_LLVM_AR"
6726fi
6727
6728
6729      if test -n "${LLVM_AR}" -a -x "${LLVM_AR}"
6730      then
6731        LLVM_AR_FOUND="found"
6732      else
6733        LLVM_AR_FOUND="not-found"
6734      fi
6735      if test "$ac_sys_system" = "Darwin" -a "${LLVM_AR_FOUND}" = "not-found"
6736      then
6737        # The Apple-supplied ar in Xcode or the Command Line Tools is apparently sufficient
6738        found_llvm_ar=`/usr/bin/xcrun -find ar 2>/dev/null`
6739        if test -n "${found_llvm_ar}"
6740        then
6741          LLVM_AR='/usr/bin/xcrun ar'
6742          LLVM_AR_FOUND=found
6743          { $as_echo "$as_me:${as_lineno-$LINENO}: llvm-ar found via xcrun: ${LLVM_AR}" >&5
6744$as_echo "$as_me: llvm-ar found via xcrun: ${LLVM_AR}" >&6;}
6745        fi
6746      fi
6747      if test $LLVM_AR_FOUND = not-found
6748      then
6749        LLVM_PROFR_ERR=yes
6750        as_fn_error $? "llvm-ar is required for a --with-lto build with clang but could not be found." "$LINENO" 5
6751      else
6752        LLVM_AR_ERR=no
6753      fi
6754      AR="${LLVM_AR}"
6755      case $ac_sys_system in
6756        Darwin*)
6757          # Any changes made here should be reflected in the GCC+Darwin case below
6758          LTOFLAGS="-flto -Wl,-export_dynamic"
6759          LTOCFLAGS="-flto"
6760          ;;
6761        *)
6762          LTOFLAGS="-flto"
6763          ;;
6764      esac
6765      ;;
6766    *gcc*)
6767      case $ac_sys_system in
6768        Darwin*)
6769          LTOFLAGS="-flto -Wl,-export_dynamic"
6770          LTOCFLAGS="-flto"
6771          ;;
6772        *)
6773          LTOFLAGS="-flto -fuse-linker-plugin -ffat-lto-objects -flto-partition=none"
6774          ;;
6775      esac
6776      ;;
6777  esac
6778
6779  if test "$ac_cv_prog_cc_g" = "yes"
6780  then
6781      # bpo-30345: Add -g to LDFLAGS when compiling with LTO
6782      # to get debug symbols.
6783      LTOFLAGS="$LTOFLAGS -g"
6784  fi
6785
6786  CFLAGS_NODIST="$CFLAGS_NODIST ${LTOCFLAGS-$LTOFLAGS}"
6787  LDFLAGS_NODIST="$LDFLAGS_NODIST $LTOFLAGS"
6788fi
6789
6790# Enable PGO flags.
6791
6792
6793
6794
6795
6796
6797if test -n "$ac_tool_prefix"; then
6798  # Extract the first word of "${ac_tool_prefix}llvm-profdata", so it can be a program name with args.
6799set dummy ${ac_tool_prefix}llvm-profdata; ac_word=$2
6800{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6801$as_echo_n "checking for $ac_word... " >&6; }
6802if ${ac_cv_path_LLVM_PROFDATA+:} false; then :
6803  $as_echo_n "(cached) " >&6
6804else
6805  case $LLVM_PROFDATA in
6806  [\\/]* | ?:[\\/]*)
6807  ac_cv_path_LLVM_PROFDATA="$LLVM_PROFDATA" # Let the user override the test with a path.
6808  ;;
6809  *)
6810  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6811for as_dir in ${llvm_path}
6812do
6813  IFS=$as_save_IFS
6814  test -z "$as_dir" && as_dir=.
6815    for ac_exec_ext in '' $ac_executable_extensions; do
6816  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6817    ac_cv_path_LLVM_PROFDATA="$as_dir/$ac_word$ac_exec_ext"
6818    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6819    break 2
6820  fi
6821done
6822  done
6823IFS=$as_save_IFS
6824
6825  ;;
6826esac
6827fi
6828LLVM_PROFDATA=$ac_cv_path_LLVM_PROFDATA
6829if test -n "$LLVM_PROFDATA"; then
6830  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_PROFDATA" >&5
6831$as_echo "$LLVM_PROFDATA" >&6; }
6832else
6833  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6834$as_echo "no" >&6; }
6835fi
6836
6837
6838fi
6839if test -z "$ac_cv_path_LLVM_PROFDATA"; then
6840  ac_pt_LLVM_PROFDATA=$LLVM_PROFDATA
6841  # Extract the first word of "llvm-profdata", so it can be a program name with args.
6842set dummy llvm-profdata; ac_word=$2
6843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6844$as_echo_n "checking for $ac_word... " >&6; }
6845if ${ac_cv_path_ac_pt_LLVM_PROFDATA+:} false; then :
6846  $as_echo_n "(cached) " >&6
6847else
6848  case $ac_pt_LLVM_PROFDATA in
6849  [\\/]* | ?:[\\/]*)
6850  ac_cv_path_ac_pt_LLVM_PROFDATA="$ac_pt_LLVM_PROFDATA" # Let the user override the test with a path.
6851  ;;
6852  *)
6853  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6854for as_dir in ${llvm_path}
6855do
6856  IFS=$as_save_IFS
6857  test -z "$as_dir" && as_dir=.
6858    for ac_exec_ext in '' $ac_executable_extensions; do
6859  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6860    ac_cv_path_ac_pt_LLVM_PROFDATA="$as_dir/$ac_word$ac_exec_ext"
6861    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6862    break 2
6863  fi
6864done
6865  done
6866IFS=$as_save_IFS
6867
6868  ;;
6869esac
6870fi
6871ac_pt_LLVM_PROFDATA=$ac_cv_path_ac_pt_LLVM_PROFDATA
6872if test -n "$ac_pt_LLVM_PROFDATA"; then
6873  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LLVM_PROFDATA" >&5
6874$as_echo "$ac_pt_LLVM_PROFDATA" >&6; }
6875else
6876  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6877$as_echo "no" >&6; }
6878fi
6879
6880  if test "x$ac_pt_LLVM_PROFDATA" = x; then
6881    LLVM_PROFDATA="''"
6882  else
6883    case $cross_compiling:$ac_tool_warned in
6884yes:)
6885{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6886$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6887ac_tool_warned=yes ;;
6888esac
6889    LLVM_PROFDATA=$ac_pt_LLVM_PROFDATA
6890  fi
6891else
6892  LLVM_PROFDATA="$ac_cv_path_LLVM_PROFDATA"
6893fi
6894
6895
6896if test -n "${LLVM_PROFDATA}" -a -x "${LLVM_PROFDATA}"
6897then
6898  LLVM_PROF_FOUND="found"
6899else
6900  LLVM_PROF_FOUND="not-found"
6901fi
6902if test "$ac_sys_system" = "Darwin" -a "${LLVM_PROF_FOUND}" = "not-found"
6903then
6904  found_llvm_profdata=`/usr/bin/xcrun -find llvm-profdata 2>/dev/null`
6905  if test -n "${found_llvm_profdata}"
6906  then
6907    # llvm-profdata isn't directly in $PATH in some cases.
6908    # https://apple.stackexchange.com/questions/197053/
6909    LLVM_PROFDATA='/usr/bin/xcrun llvm-profdata'
6910    LLVM_PROF_FOUND=found
6911    { $as_echo "$as_me:${as_lineno-$LINENO}: llvm-profdata found via xcrun: ${LLVM_PROFDATA}" >&5
6912$as_echo "$as_me: llvm-profdata found via xcrun: ${LLVM_PROFDATA}" >&6;}
6913  fi
6914fi
6915LLVM_PROF_ERR=no
6916case $CC in
6917  *clang*)
6918    # Any changes made here should be reflected in the GCC+Darwin case below
6919    PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
6920    PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
6921    LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
6922    LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
6923    if test $LLVM_PROF_FOUND = not-found
6924    then
6925      LLVM_PROF_ERR=yes
6926      if test "${REQUIRE_PGO}" = "yes"
6927      then
6928        as_fn_error $? "llvm-profdata is required for a --enable-optimizations build but could not be found." "$LINENO" 5
6929      fi
6930    fi
6931    ;;
6932  *gcc*)
6933    case $ac_sys_system in
6934      Darwin*)
6935        PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
6936        PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
6937        LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
6938        LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
6939        if test "${LLVM_PROF_FOUND}" = "not-found"
6940        then
6941          LLVM_PROF_ERR=yes
6942          if test "${REQUIRE_PGO}" = "yes"
6943	  then
6944	    as_fn_error $? "llvm-profdata is required for a --enable-optimizations build but could not be found." "$LINENO" 5
6945	  fi
6946        fi
6947        ;;
6948      *)
6949        PGO_PROF_GEN_FLAG="-fprofile-generate"
6950        PGO_PROF_USE_FLAG="-fprofile-use -fprofile-correction"
6951        LLVM_PROF_MERGER="true"
6952        LLVM_PROF_FILE=""
6953        ;;
6954    esac
6955    ;;
6956  *icc*)
6957    PGO_PROF_GEN_FLAG="-prof-gen"
6958    PGO_PROF_USE_FLAG="-prof-use"
6959    LLVM_PROF_MERGER="true"
6960    LLVM_PROF_FILE=""
6961    ;;
6962esac
6963
6964# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
6965# merged with this chunk of code?
6966
6967# Optimizer/debugger flags
6968# ------------------------
6969# (The following bit of code is complicated enough - please keep things
6970# indented properly.  Just pretend you're editing Python code. ;-)
6971
6972# There are two parallel sets of case statements below, one that checks to
6973# see if OPT was set and one that does BASECFLAGS setting based upon
6974# compiler and platform.  BASECFLAGS tweaks need to be made even if the
6975# user set OPT.
6976
6977case $CC in
6978    *clang*)
6979        cc_is_clang=1
6980        ;;
6981    *)
6982        if $CC --version 2>&1 | grep -q clang
6983        then
6984            cc_is_clang=1
6985        else
6986            cc_is_clang=
6987        fi
6988esac
6989
6990# tweak OPT based on compiler and platform, only if the user didn't set
6991# it on the command line
6992
6993
6994if test "${OPT-unset}" = "unset"
6995then
6996    case $GCC in
6997    yes)
6998        # For gcc 4.x we need to use -fwrapv so lets check if its supported
6999        if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then
7000           WRAP="-fwrapv"
7001        fi
7002
7003        if test -n "${cc_is_clang}"
7004        then
7005            # Clang also needs -fwrapv
7006            WRAP="-fwrapv"
7007            # bpo-30104: disable strict aliasing to compile correctly dtoa.c,
7008            # see Makefile.pre.in for more information
7009            CFLAGS_ALIASING="-fno-strict-aliasing"
7010        fi
7011
7012	case $ac_cv_prog_cc_g in
7013	yes)
7014	    if test "$Py_DEBUG" = 'true' ; then
7015		# Optimization messes up debuggers, so turn it off for
7016		# debug builds.
7017                if "$CC" -v --help 2>/dev/null |grep -- -Og > /dev/null; then
7018                    OPT="-g -Og -Wall"
7019                else
7020                    OPT="-g -O0 -Wall"
7021                fi
7022	    else
7023		OPT="-g $WRAP -O3 -Wall"
7024	    fi
7025	    ;;
7026	*)
7027	    OPT="-O3 -Wall"
7028	    ;;
7029	esac
7030
7031	case $ac_sys_system in
7032	    SCO_SV*) OPT="$OPT -m486 -DSCO5"
7033	    ;;
7034        esac
7035	;;
7036
7037    *)
7038	OPT="-O"
7039	;;
7040    esac
7041fi
7042
7043
7044
7045
7046
7047# The -arch flags for universal builds on macOS
7048UNIVERSAL_ARCH_FLAGS=
7049
7050
7051# tweak BASECFLAGS based on compiler and platform
7052case $GCC in
7053yes)
7054    CFLAGS_NODIST="$CFLAGS_NODIST -std=c99"
7055
7056    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wextra" >&5
7057$as_echo_n "checking for -Wextra... " >&6; }
7058     ac_save_cc="$CC"
7059     CC="$CC -Wextra -Werror"
7060     if ${ac_cv_extra_warnings+:} false; then :
7061  $as_echo_n "(cached) " >&6
7062else
7063  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7064/* end confdefs.h.  */
7065
7066
7067int
7068main ()
7069{
7070
7071  ;
7072  return 0;
7073}
7074
7075_ACEOF
7076if ac_fn_c_try_compile "$LINENO"; then :
7077
7078           ac_cv_extra_warnings=yes
7079
7080else
7081
7082           ac_cv_extra_warnings=no
7083
7084fi
7085rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7086fi
7087
7088     CC="$ac_save_cc"
7089    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_extra_warnings" >&5
7090$as_echo "$ac_cv_extra_warnings" >&6; }
7091
7092    if test $ac_cv_extra_warnings = yes
7093    then
7094      CFLAGS_NODIST="$CFLAGS_NODIST -Wextra"
7095    fi
7096
7097    # Python doesn't violate C99 aliasing rules, but older versions of
7098    # GCC produce warnings for legal Python code.  Enable
7099    # -fno-strict-aliasing on versions of GCC that support but produce
7100    # warnings.  See Issue3326
7101    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5
7102$as_echo_n "checking whether $CC accepts and needs -fno-strict-aliasing... " >&6; }
7103     ac_save_cc="$CC"
7104     CC="$CC -fno-strict-aliasing"
7105     save_CFLAGS="$CFLAGS"
7106     if ${ac_cv_no_strict_aliasing+:} false; then :
7107  $as_echo_n "(cached) " >&6
7108else
7109  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7110/* end confdefs.h.  */
7111
7112
7113int
7114main ()
7115{
7116
7117  ;
7118  return 0;
7119}
7120
7121_ACEOF
7122if ac_fn_c_try_compile "$LINENO"; then :
7123
7124	   CC="$ac_save_cc -fstrict-aliasing"
7125           CFLAGS="$CFLAGS -Werror -Wstrict-aliasing"
7126           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7127/* end confdefs.h.  */
7128
7129	       void f(int **x) {}
7130int
7131main ()
7132{
7133double *x; f((int **) &x);
7134  ;
7135  return 0;
7136}
7137
7138_ACEOF
7139if ac_fn_c_try_compile "$LINENO"; then :
7140
7141	       ac_cv_no_strict_aliasing=no
7142
7143else
7144
7145               ac_cv_no_strict_aliasing=yes
7146
7147fi
7148rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7149
7150else
7151
7152	   ac_cv_no_strict_aliasing=no
7153
7154fi
7155rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7156fi
7157
7158     CFLAGS="$save_CFLAGS"
7159     CC="$ac_save_cc"
7160    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5
7161$as_echo "$ac_cv_no_strict_aliasing" >&6; }
7162    if test $ac_cv_no_strict_aliasing = yes
7163    then
7164      BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
7165    fi
7166
7167    # ICC doesn't recognize the option, but only emits a warning
7168    ## XXX does it emit an unused result warning and can it be disabled?
7169    case "$CC" in
7170    *icc*)
7171    ac_cv_disable_unused_result_warning=no
7172    ;;
7173    *)
7174    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC unused result warning" >&5
7175$as_echo_n "checking if we can turn off $CC unused result warning... " >&6; }
7176     ac_save_cc="$CC"
7177     CC="$CC -Wunused-result -Werror"
7178     save_CFLAGS="$CFLAGS"
7179     if ${ac_cv_disable_unused_result_warning+:} false; then :
7180  $as_echo_n "(cached) " >&6
7181else
7182  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7183/* end confdefs.h.  */
7184
7185
7186int
7187main ()
7188{
7189
7190  ;
7191  return 0;
7192}
7193
7194_ACEOF
7195if ac_fn_c_try_compile "$LINENO"; then :
7196
7197           ac_cv_disable_unused_result_warning=yes
7198
7199else
7200
7201           ac_cv_disable_unused_result_warning=no
7202
7203fi
7204rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7205fi
7206
7207     CFLAGS="$save_CFLAGS"
7208     CC="$ac_save_cc"
7209    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_unused_result_warning" >&5
7210$as_echo "$ac_cv_disable_unused_result_warning" >&6; }
7211    ;;
7212    esac
7213
7214    if test $ac_cv_disable_unused_result_warning = yes
7215    then
7216      BASECFLAGS="$BASECFLAGS -Wno-unused-result"
7217      CFLAGS_NODIST="$CFLAGS_NODIST -Wno-unused-result"
7218    fi
7219
7220    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC unused parameter warning" >&5
7221$as_echo_n "checking if we can turn off $CC unused parameter warning... " >&6; }
7222     ac_save_cc="$CC"
7223     CC="$CC -Wunused-parameter -Werror"
7224     if ${ac_cv_disable_unused_parameter_warning+:} false; then :
7225  $as_echo_n "(cached) " >&6
7226else
7227  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7228/* end confdefs.h.  */
7229
7230
7231int
7232main ()
7233{
7234
7235  ;
7236  return 0;
7237}
7238
7239_ACEOF
7240if ac_fn_c_try_compile "$LINENO"; then :
7241
7242           ac_cv_disable_unused_parameter_warning=yes
7243
7244else
7245
7246           ac_cv_disable_unused_parameter_warning=no
7247
7248fi
7249rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7250fi
7251
7252     CC="$ac_save_cc"
7253    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_unused_parameter_warning" >&5
7254$as_echo "$ac_cv_disable_unused_parameter_warning" >&6; }
7255
7256    if test $ac_cv_disable_unused_parameter_warning = yes
7257    then
7258      CFLAGS_NODIST="$CFLAGS_NODIST -Wno-unused-parameter"
7259    fi
7260
7261    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC missing field initializers warning" >&5
7262$as_echo_n "checking if we can turn off $CC missing field initializers warning... " >&6; }
7263     ac_save_cc="$CC"
7264     CC="$CC -Wmissing-field-initializers -Werror"
7265     if ${ac_cv_disable_missing_field_initializers+:} false; then :
7266  $as_echo_n "(cached) " >&6
7267else
7268  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7269/* end confdefs.h.  */
7270
7271
7272int
7273main ()
7274{
7275
7276  ;
7277  return 0;
7278}
7279
7280_ACEOF
7281if ac_fn_c_try_compile "$LINENO"; then :
7282
7283           ac_cv_disable_missing_field_initializers=yes
7284
7285else
7286
7287           ac_cv_disable_missing_field_initializers=no
7288
7289fi
7290rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7291fi
7292
7293     CC="$ac_save_cc"
7294    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_missing_field_initializers" >&5
7295$as_echo "$ac_cv_disable_missing_field_initializers" >&6; }
7296
7297    if test $ac_cv_disable_missing_field_initializers = yes
7298    then
7299      CFLAGS_NODIST="$CFLAGS_NODIST -Wno-missing-field-initializers"
7300    fi
7301
7302    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC mixed sign comparison warning" >&5
7303$as_echo_n "checking if we can turn on $CC mixed sign comparison warning... " >&6; }
7304     ac_save_cc="$CC"
7305     CC="$CC -Wsign-compare"
7306     save_CFLAGS="$CFLAGS"
7307     if ${ac_cv_enable_sign_compare_warning+:} false; then :
7308  $as_echo_n "(cached) " >&6
7309else
7310  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7311/* end confdefs.h.  */
7312
7313
7314int
7315main ()
7316{
7317
7318  ;
7319  return 0;
7320}
7321
7322_ACEOF
7323if ac_fn_c_try_compile "$LINENO"; then :
7324
7325           ac_cv_enable_sign_compare_warning=yes
7326
7327else
7328
7329           ac_cv_enable_sign_compare_warning=no
7330
7331fi
7332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7333fi
7334
7335     CFLAGS="$save_CFLAGS"
7336     CC="$ac_save_cc"
7337    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_sign_compare_warning" >&5
7338$as_echo "$ac_cv_enable_sign_compare_warning" >&6; }
7339
7340    if test $ac_cv_enable_sign_compare_warning = yes
7341    then
7342      BASECFLAGS="$BASECFLAGS -Wsign-compare"
7343    fi
7344
7345    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC unreachable code warning" >&5
7346$as_echo_n "checking if we can turn on $CC unreachable code warning... " >&6; }
7347     ac_save_cc="$CC"
7348     CC="$CC -Wunreachable-code"
7349     save_CFLAGS="$CFLAGS"
7350     if ${ac_cv_enable_unreachable_code_warning+:} false; then :
7351  $as_echo_n "(cached) " >&6
7352else
7353  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7354/* end confdefs.h.  */
7355
7356
7357int
7358main ()
7359{
7360
7361  ;
7362  return 0;
7363}
7364
7365_ACEOF
7366if ac_fn_c_try_compile "$LINENO"; then :
7367
7368           ac_cv_enable_unreachable_code_warning=yes
7369
7370else
7371
7372           ac_cv_enable_unreachable_code_warning=no
7373
7374fi
7375rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7376fi
7377
7378     CFLAGS="$save_CFLAGS"
7379     CC="$ac_save_cc"
7380
7381    # Don't enable unreachable code warning in debug mode, since it usually
7382    # results in non-standard code paths.
7383    # Issue #24324: Unfortunately, the unreachable code warning does not work
7384    # correctly on gcc and has been silently removed from the compiler.
7385    # It is supported on clang but on OS X systems gcc may be an alias
7386    # for clang.  Try to determine if the compiler is not really gcc and,
7387    # if so, only then enable the warning.
7388    if test $ac_cv_enable_unreachable_code_warning = yes && \
7389        test "$Py_DEBUG" != "true" && \
7390        test -z "`$CC --version 2>/dev/null | grep 'Free Software Foundation'`"
7391    then
7392      BASECFLAGS="$BASECFLAGS -Wunreachable-code"
7393    else
7394      ac_cv_enable_unreachable_code_warning=no
7395    fi
7396    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_unreachable_code_warning" >&5
7397$as_echo "$ac_cv_enable_unreachable_code_warning" >&6; }
7398
7399    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC strict-prototypes warning" >&5
7400$as_echo_n "checking if we can turn on $CC strict-prototypes warning... " >&6; }
7401     ac_save_cc="$CC"
7402     CC="$CC -Werror -Wstrict-prototypes"
7403     if ${ac_cv_enable_enable_strict_prototypes_warning+:} false; then :
7404  $as_echo_n "(cached) " >&6
7405else
7406  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7407/* end confdefs.h.  */
7408
7409
7410int
7411main ()
7412{
7413
7414  ;
7415  return 0;
7416}
7417
7418_ACEOF
7419if ac_fn_c_try_compile "$LINENO"; then :
7420
7421       ac_cv_enable_strict_prototypes_warning=yes
7422
7423else
7424
7425       ac_cv_enable_strict_prototypes_warning=no
7426
7427fi
7428rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7429fi
7430
7431     CC="$ac_save_cc"
7432    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_strict_prototypes_warning" >&5
7433$as_echo "$ac_cv_enable_strict_prototypes_warning" >&6; }
7434
7435    if test $ac_cv_enable_strict_prototypes_warning = yes
7436    then
7437      CFLAGS_NODIST="$CFLAGS_NODIST -Wstrict-prototypes"
7438    fi
7439
7440    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can make implicit function declaration an error in $CC" >&5
7441$as_echo_n "checking if we can make implicit function declaration an error in $CC... " >&6; }
7442     ac_save_cc="$CC"
7443     CC="$CC -Werror=implicit-function-declaration"
7444     if ${ac_cv_enable_implicit_function_declaration_error+:} false; then :
7445  $as_echo_n "(cached) " >&6
7446else
7447  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7448/* end confdefs.h.  */
7449
7450
7451int
7452main ()
7453{
7454
7455  ;
7456  return 0;
7457}
7458
7459_ACEOF
7460if ac_fn_c_try_compile "$LINENO"; then :
7461
7462           ac_cv_enable_implicit_function_declaration_error=yes
7463
7464else
7465
7466           ac_cv_enable_implicit_function_declaration_error=no
7467
7468fi
7469rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7470fi
7471
7472     CC="$ac_save_cc"
7473    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_implicit_function_declaration_error" >&5
7474$as_echo "$ac_cv_enable_implicit_function_declaration_error" >&6; }
7475
7476    if test $ac_cv_enable_implicit_function_declaration_error = yes
7477    then
7478      CFLAGS_NODIST="$CFLAGS_NODIST -Werror=implicit-function-declaration"
7479    fi
7480
7481    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use visibility in $CC" >&5
7482$as_echo_n "checking if we can use visibility in $CC... " >&6; }
7483     ac_save_cc="$CC"
7484     CC="$CC -fvisibility=hidden"
7485     if ${ac_cv_enable_visibility+:} false; then :
7486  $as_echo_n "(cached) " >&6
7487else
7488  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7489/* end confdefs.h.  */
7490
7491
7492int
7493main ()
7494{
7495
7496  ;
7497  return 0;
7498}
7499
7500_ACEOF
7501if ac_fn_c_try_compile "$LINENO"; then :
7502
7503           ac_cv_enable_visibility=yes
7504
7505else
7506
7507           ac_cv_enable_visibility=no
7508
7509fi
7510rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7511fi
7512
7513     CC="$ac_save_cc"
7514    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_visibility" >&5
7515$as_echo "$ac_cv_enable_visibility" >&6; }
7516
7517    if test $ac_cv_enable_visibility = yes
7518    then
7519      CFLAGS_NODIST="$CFLAGS_NODIST -fvisibility=hidden"
7520    fi
7521
7522    # if using gcc on alpha, use -mieee to get (near) full IEEE 754
7523    # support.  Without this, treatment of subnormals doesn't follow
7524    # the standard.
7525    case $host in
7526         alpha*)
7527                BASECFLAGS="$BASECFLAGS -mieee"
7528                ;;
7529    esac
7530
7531    case $ac_sys_system in
7532	SCO_SV*)
7533	    BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
7534	    ;;
7535
7536    Darwin*)
7537        # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
7538        # used to be here, but non-Apple gcc doesn't accept them.
7539        if test "${CC}" = gcc
7540        then
7541            { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5
7542$as_echo_n "checking which compiler should be used... " >&6; }
7543            case "${UNIVERSALSDK}" in
7544            */MacOSX10.4u.sdk)
7545                # Build using 10.4 SDK, force usage of gcc when the
7546                # compiler is gcc, otherwise the user will get very
7547                # confusing error messages when building on OSX 10.6
7548                CC=gcc-4.0
7549                CPP=cpp-4.0
7550                ;;
7551            esac
7552            { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
7553$as_echo "$CC" >&6; }
7554        fi
7555
7556        LIPO_INTEL64_FLAGS=""
7557        if test "${enable_universalsdk}"
7558        then
7559            case "$UNIVERSAL_ARCHS" in
7560            32-bit)
7561               UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386"
7562               LIPO_32BIT_FLAGS=""
7563               ARCH_RUN_32BIT=""
7564               ;;
7565            64-bit)
7566               UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64"
7567               LIPO_32BIT_FLAGS=""
7568               ARCH_RUN_32BIT="true"
7569               ;;
7570            all)
7571               UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64"
7572               LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386"
7573               ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc"
7574               ;;
7575            universal2)
7576               UNIVERSAL_ARCH_FLAGS="-arch arm64 -arch x86_64"
7577               LIPO_32BIT_FLAGS=""
7578               LIPO_INTEL64_FLAGS="-extract x86_64"
7579               ARCH_RUN_32BIT="true"
7580               ;;
7581            intel)
7582               UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64"
7583               LIPO_32BIT_FLAGS="-extract i386"
7584               ARCH_RUN_32BIT="/usr/bin/arch -i386"
7585               ;;
7586            intel-32)
7587               UNIVERSAL_ARCH_FLAGS="-arch i386"
7588               LIPO_32BIT_FLAGS=""
7589               ARCH_RUN_32BIT=""
7590               ;;
7591            intel-64)
7592               UNIVERSAL_ARCH_FLAGS="-arch x86_64"
7593               LIPO_32BIT_FLAGS=""
7594               ARCH_RUN_32BIT="true"
7595               ;;
7596            3-way)
7597               UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64"
7598               LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386"
7599               ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc"
7600               ;;
7601            *)
7602               as_fn_error $? "proper usage is --with-universal-arch=universal2|32-bit|64-bit|all|intel|3-way" "$LINENO" 5
7603               ;;
7604            esac
7605
7606            if test "${UNIVERSALSDK}" != "/"
7607            then
7608                CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
7609                LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}"
7610                CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}"
7611            else
7612                CFLAGS="${UNIVERSAL_ARCH_FLAGS} ${CFLAGS}"
7613                LDFLAGS="${UNIVERSAL_ARCH_FLAGS} ${LDFLAGS}"
7614            fi
7615        fi
7616
7617        # Calculate an appropriate deployment target for this build:
7618        # The deployment target value is used explicitly to enable certain
7619        # features are enabled (such as builtin libedit support for readline)
7620        # through the use of Apple's Availability Macros and is used as a
7621        # component of the string returned by distutils.get_platform().
7622        #
7623        # Use the value from:
7624        # 1. the MACOSX_DEPLOYMENT_TARGET environment variable if specified
7625        # 2. the operating system version of the build machine if >= 10.6
7626        # 3. If running on OS X 10.3 through 10.5, use the legacy tests
7627        #       below to pick either 10.3, 10.4, or 10.5 as the target.
7628        # 4. If we are running on OS X 10.2 or earlier, good luck!
7629
7630        { $as_echo "$as_me:${as_lineno-$LINENO}: checking which MACOSX_DEPLOYMENT_TARGET to use" >&5
7631$as_echo_n "checking which MACOSX_DEPLOYMENT_TARGET to use... " >&6; }
7632        cur_target_major=`sw_vers -productVersion | \
7633                sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'`
7634        cur_target_minor=`sw_vers -productVersion | \
7635                sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'`
7636        cur_target="${cur_target_major}.${cur_target_minor}"
7637        if test ${cur_target_major} -eq 10 && \
7638           test ${cur_target_minor} -ge 3 && \
7639           test ${cur_target_minor} -le 5
7640        then
7641            # OS X 10.3 through 10.5
7642            cur_target=10.3
7643            if test ${enable_universalsdk}
7644            then
7645                case "$UNIVERSAL_ARCHS" in
7646                all|3-way|intel|64-bit)
7647                    # These configurations were first supported in 10.5
7648                    cur_target='10.5'
7649                    ;;
7650                esac
7651            else
7652                if test `/usr/bin/arch` = "i386"
7653                then
7654                    # 10.4 was the first release to support Intel archs
7655                    cur_target="10.4"
7656                fi
7657            fi
7658        fi
7659        CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
7660
7661        # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
7662        # environment with a value that is the same as what we'll use
7663        # in the Makefile to ensure that we'll get the same compiler
7664        # environment during configure and build time.
7665        MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
7666        export MACOSX_DEPLOYMENT_TARGET
7667        EXPORT_MACOSX_DEPLOYMENT_TARGET=''
7668        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACOSX_DEPLOYMENT_TARGET" >&5
7669$as_echo "$MACOSX_DEPLOYMENT_TARGET" >&6; }
7670
7671        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if specified universal architectures work" >&5
7672$as_echo_n "checking if specified universal architectures work... " >&6; }
7673        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7674/* end confdefs.h.  */
7675#include <stdio.h>
7676int
7677main ()
7678{
7679printf("%d", 42);
7680  ;
7681  return 0;
7682}
7683_ACEOF
7684if ac_fn_c_try_link "$LINENO"; then :
7685  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7686$as_echo "yes" >&6; }
7687else
7688  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7689$as_echo "no" >&6; }
7690             as_fn_error $? "check config.log and use the '--with-universal-archs' option" "$LINENO" 5
7691
7692fi
7693rm -f core conftest.err conftest.$ac_objext \
7694    conftest$ac_exeext conftest.$ac_ext
7695
7696        # end of Darwin* tests
7697        ;;
7698    esac
7699    ;;
7700
7701*)
7702    case $ac_sys_system in
7703    OpenUNIX*|UnixWare*)
7704	BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
7705	;;
7706    SCO_SV*)
7707	BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
7708	;;
7709    esac
7710    ;;
7711esac
7712
7713case "$CC" in
7714*icc*)
7715    # ICC needs -fp-model strict or floats behave badly
7716    CFLAGS_NODIST="$CFLAGS_NODIST -fp-model strict"
7717    ;;
7718*xlc*)
7719    CFLAGS_NODIST="$CFLAGS_NODIST -qalias=noansi -qmaxmem=-1"
7720    ;;
7721esac
7722
7723if test "$assertions" = 'true'; then
7724  :
7725else
7726  OPT="-DNDEBUG $OPT"
7727fi
7728
7729if test "$ac_arch_flags"
7730then
7731	BASECFLAGS="$BASECFLAGS $ac_arch_flags"
7732fi
7733
7734# On some compilers, pthreads are available without further options
7735# (e.g. MacOS X). On some of these systems, the compiler will not
7736# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
7737# So we have to see first whether pthreads are available without
7738# options before we can check whether -Kpthread improves anything.
7739{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5
7740$as_echo_n "checking whether pthreads are available without options... " >&6; }
7741if ${ac_cv_pthread_is_default+:} false; then :
7742  $as_echo_n "(cached) " >&6
7743else
7744  if test "$cross_compiling" = yes; then :
7745  ac_cv_pthread_is_default=no
7746else
7747  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7748/* end confdefs.h.  */
7749
7750#include <stdio.h>
7751#include <pthread.h>
7752
7753void* routine(void* p){return NULL;}
7754
7755int main(){
7756  pthread_t p;
7757  if(pthread_create(&p,NULL,routine,NULL)!=0)
7758    return 1;
7759  (void)pthread_detach(p);
7760  return 0;
7761}
7762
7763_ACEOF
7764if ac_fn_c_try_run "$LINENO"; then :
7765
7766  ac_cv_pthread_is_default=yes
7767  ac_cv_kthread=no
7768  ac_cv_pthread=no
7769
7770else
7771  ac_cv_pthread_is_default=no
7772fi
7773rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7774  conftest.$ac_objext conftest.beam conftest.$ac_ext
7775fi
7776
7777
7778fi
7779
7780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5
7781$as_echo "$ac_cv_pthread_is_default" >&6; }
7782
7783
7784if test $ac_cv_pthread_is_default = yes
7785then
7786  ac_cv_kpthread=no
7787else
7788# -Kpthread, if available, provides the right #defines
7789# and linker options to make pthread_create available
7790# Some compilers won't report that they do not support -Kpthread,
7791# so we need to run a program to see whether it really made the
7792# function available.
7793{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5
7794$as_echo_n "checking whether $CC accepts -Kpthread... " >&6; }
7795if ${ac_cv_kpthread+:} false; then :
7796  $as_echo_n "(cached) " >&6
7797else
7798  ac_save_cc="$CC"
7799CC="$CC -Kpthread"
7800if test "$cross_compiling" = yes; then :
7801  ac_cv_kpthread=no
7802else
7803  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7804/* end confdefs.h.  */
7805
7806#include <stdio.h>
7807#include <pthread.h>
7808
7809void* routine(void* p){return NULL;}
7810
7811int main(){
7812  pthread_t p;
7813  if(pthread_create(&p,NULL,routine,NULL)!=0)
7814    return 1;
7815  (void)pthread_detach(p);
7816  return 0;
7817}
7818
7819_ACEOF
7820if ac_fn_c_try_run "$LINENO"; then :
7821  ac_cv_kpthread=yes
7822else
7823  ac_cv_kpthread=no
7824fi
7825rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7826  conftest.$ac_objext conftest.beam conftest.$ac_ext
7827fi
7828
7829CC="$ac_save_cc"
7830fi
7831
7832{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5
7833$as_echo "$ac_cv_kpthread" >&6; }
7834fi
7835
7836if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no
7837then
7838# -Kthread, if available, provides the right #defines
7839# and linker options to make pthread_create available
7840# Some compilers won't report that they do not support -Kthread,
7841# so we need to run a program to see whether it really made the
7842# function available.
7843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5
7844$as_echo_n "checking whether $CC accepts -Kthread... " >&6; }
7845if ${ac_cv_kthread+:} false; then :
7846  $as_echo_n "(cached) " >&6
7847else
7848  ac_save_cc="$CC"
7849CC="$CC -Kthread"
7850if test "$cross_compiling" = yes; then :
7851  ac_cv_kthread=no
7852else
7853  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7854/* end confdefs.h.  */
7855
7856#include <stdio.h>
7857#include <pthread.h>
7858
7859void* routine(void* p){return NULL;}
7860
7861int main(){
7862  pthread_t p;
7863  if(pthread_create(&p,NULL,routine,NULL)!=0)
7864    return 1;
7865  (void)pthread_detach(p);
7866  return 0;
7867}
7868
7869_ACEOF
7870if ac_fn_c_try_run "$LINENO"; then :
7871  ac_cv_kthread=yes
7872else
7873  ac_cv_kthread=no
7874fi
7875rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7876  conftest.$ac_objext conftest.beam conftest.$ac_ext
7877fi
7878
7879CC="$ac_save_cc"
7880fi
7881
7882{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5
7883$as_echo "$ac_cv_kthread" >&6; }
7884fi
7885
7886if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no
7887then
7888# -pthread, if available, provides the right #defines
7889# and linker options to make pthread_create available
7890# Some compilers won't report that they do not support -pthread,
7891# so we need to run a program to see whether it really made the
7892# function available.
7893{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5
7894$as_echo_n "checking whether $CC accepts -pthread... " >&6; }
7895if ${ac_cv_pthread+:} false; then :
7896  $as_echo_n "(cached) " >&6
7897else
7898  ac_save_cc="$CC"
7899CC="$CC -pthread"
7900if test "$cross_compiling" = yes; then :
7901  ac_cv_pthread=no
7902else
7903  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7904/* end confdefs.h.  */
7905
7906#include <stdio.h>
7907#include <pthread.h>
7908
7909void* routine(void* p){return NULL;}
7910
7911int main(){
7912  pthread_t p;
7913  if(pthread_create(&p,NULL,routine,NULL)!=0)
7914    return 1;
7915  (void)pthread_detach(p);
7916  return 0;
7917}
7918
7919_ACEOF
7920if ac_fn_c_try_run "$LINENO"; then :
7921  ac_cv_pthread=yes
7922else
7923  ac_cv_pthread=no
7924fi
7925rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7926  conftest.$ac_objext conftest.beam conftest.$ac_ext
7927fi
7928
7929CC="$ac_save_cc"
7930fi
7931
7932{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5
7933$as_echo "$ac_cv_pthread" >&6; }
7934fi
7935
7936# If we have set a CC compiler flag for thread support then
7937# check if it works for CXX, too.
7938ac_cv_cxx_thread=no
7939if test ! -z "$CXX"
7940then
7941{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5
7942$as_echo_n "checking whether $CXX also accepts flags for thread support... " >&6; }
7943ac_save_cxx="$CXX"
7944
7945if test "$ac_cv_kpthread" = "yes"
7946then
7947  CXX="$CXX -Kpthread"
7948  ac_cv_cxx_thread=yes
7949elif test "$ac_cv_kthread" = "yes"
7950then
7951  CXX="$CXX -Kthread"
7952  ac_cv_cxx_thread=yes
7953elif test "$ac_cv_pthread" = "yes"
7954then
7955  CXX="$CXX -pthread"
7956  ac_cv_cxx_thread=yes
7957fi
7958
7959if test $ac_cv_cxx_thread = yes
7960then
7961  echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
7962  $CXX -c conftest.$ac_ext 2>&5
7963  if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
7964     && test -s conftest$ac_exeext && ./conftest$ac_exeext
7965  then
7966    ac_cv_cxx_thread=yes
7967  else
7968    ac_cv_cxx_thread=no
7969  fi
7970  rm -fr conftest*
7971fi
7972{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5
7973$as_echo "$ac_cv_cxx_thread" >&6; }
7974fi
7975CXX="$ac_save_cxx"
7976
7977
7978# checks for header files
7979{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7980$as_echo_n "checking for ANSI C header files... " >&6; }
7981if ${ac_cv_header_stdc+:} false; then :
7982  $as_echo_n "(cached) " >&6
7983else
7984  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7985/* end confdefs.h.  */
7986#include <stdlib.h>
7987#include <stdarg.h>
7988#include <string.h>
7989#include <float.h>
7990
7991int
7992main ()
7993{
7994
7995  ;
7996  return 0;
7997}
7998_ACEOF
7999if ac_fn_c_try_compile "$LINENO"; then :
8000  ac_cv_header_stdc=yes
8001else
8002  ac_cv_header_stdc=no
8003fi
8004rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8005
8006if test $ac_cv_header_stdc = yes; then
8007  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8008  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8009/* end confdefs.h.  */
8010#include <string.h>
8011
8012_ACEOF
8013if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8014  $EGREP "memchr" >/dev/null 2>&1; then :
8015
8016else
8017  ac_cv_header_stdc=no
8018fi
8019rm -f conftest*
8020
8021fi
8022
8023if test $ac_cv_header_stdc = yes; then
8024  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8025  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8026/* end confdefs.h.  */
8027#include <stdlib.h>
8028
8029_ACEOF
8030if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8031  $EGREP "free" >/dev/null 2>&1; then :
8032
8033else
8034  ac_cv_header_stdc=no
8035fi
8036rm -f conftest*
8037
8038fi
8039
8040if test $ac_cv_header_stdc = yes; then
8041  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8042  if test "$cross_compiling" = yes; then :
8043  :
8044else
8045  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8046/* end confdefs.h.  */
8047#include <ctype.h>
8048#include <stdlib.h>
8049#if ((' ' & 0x0FF) == 0x020)
8050# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8051# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8052#else
8053# define ISLOWER(c) \
8054		   (('a' <= (c) && (c) <= 'i') \
8055		     || ('j' <= (c) && (c) <= 'r') \
8056		     || ('s' <= (c) && (c) <= 'z'))
8057# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8058#endif
8059
8060#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8061int
8062main ()
8063{
8064  int i;
8065  for (i = 0; i < 256; i++)
8066    if (XOR (islower (i), ISLOWER (i))
8067	|| toupper (i) != TOUPPER (i))
8068      return 2;
8069  return 0;
8070}
8071_ACEOF
8072if ac_fn_c_try_run "$LINENO"; then :
8073
8074else
8075  ac_cv_header_stdc=no
8076fi
8077rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8078  conftest.$ac_objext conftest.beam conftest.$ac_ext
8079fi
8080
8081fi
8082fi
8083{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8084$as_echo "$ac_cv_header_stdc" >&6; }
8085if test $ac_cv_header_stdc = yes; then
8086
8087$as_echo "#define STDC_HEADERS 1" >>confdefs.h
8088
8089fi
8090
8091for ac_header in asm/types.h crypt.h conio.h direct.h dlfcn.h errno.h \
8092fcntl.h grp.h \
8093ieeefp.h io.h langinfo.h libintl.h process.h pthread.h \
8094sched.h shadow.h signal.h stropts.h termios.h \
8095utime.h \
8096poll.h sys/devpoll.h sys/epoll.h sys/poll.h \
8097sys/audioio.h sys/xattr.h sys/bsdtty.h sys/event.h sys/file.h sys/ioctl.h \
8098sys/kern_control.h sys/loadavg.h sys/lock.h sys/mkdev.h sys/modem.h \
8099sys/param.h sys/random.h sys/select.h sys/sendfile.h sys/socket.h sys/statvfs.h \
8100sys/stat.h sys/syscall.h sys/sys_domain.h sys/termio.h sys/time.h \
8101sys/times.h sys/types.h sys/uio.h sys/un.h sys/utsname.h sys/wait.h pty.h \
8102libutil.h sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \
8103linux/tipc.h linux/random.h spawn.h util.h alloca.h endian.h \
8104sys/endian.h sys/sysmacros.h linux/memfd.h linux/wait.h sys/memfd.h \
8105sys/mman.h sys/eventfd.h
8106do :
8107  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8108ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8109if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8110  cat >>confdefs.h <<_ACEOF
8111#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8112_ACEOF
8113
8114fi
8115
8116done
8117
8118ac_header_dirent=no
8119for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
8120  as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
8121{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
8122$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
8123if eval \${$as_ac_Header+:} false; then :
8124  $as_echo_n "(cached) " >&6
8125else
8126  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8127/* end confdefs.h.  */
8128#include <sys/types.h>
8129#include <$ac_hdr>
8130
8131int
8132main ()
8133{
8134if ((DIR *) 0)
8135return 0;
8136  ;
8137  return 0;
8138}
8139_ACEOF
8140if ac_fn_c_try_compile "$LINENO"; then :
8141  eval "$as_ac_Header=yes"
8142else
8143  eval "$as_ac_Header=no"
8144fi
8145rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8146fi
8147eval ac_res=\$$as_ac_Header
8148	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8149$as_echo "$ac_res" >&6; }
8150if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8151  cat >>confdefs.h <<_ACEOF
8152#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
8153_ACEOF
8154
8155ac_header_dirent=$ac_hdr; break
8156fi
8157
8158done
8159# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
8160if test $ac_header_dirent = dirent.h; then
8161  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8162$as_echo_n "checking for library containing opendir... " >&6; }
8163if ${ac_cv_search_opendir+:} false; then :
8164  $as_echo_n "(cached) " >&6
8165else
8166  ac_func_search_save_LIBS=$LIBS
8167cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8168/* end confdefs.h.  */
8169
8170/* Override any GCC internal prototype to avoid an error.
8171   Use char because int might match the return type of a GCC
8172   builtin and then its argument prototype would still apply.  */
8173#ifdef __cplusplus
8174extern "C"
8175#endif
8176char opendir ();
8177int
8178main ()
8179{
8180return opendir ();
8181  ;
8182  return 0;
8183}
8184_ACEOF
8185for ac_lib in '' dir; do
8186  if test -z "$ac_lib"; then
8187    ac_res="none required"
8188  else
8189    ac_res=-l$ac_lib
8190    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8191  fi
8192  if ac_fn_c_try_link "$LINENO"; then :
8193  ac_cv_search_opendir=$ac_res
8194fi
8195rm -f core conftest.err conftest.$ac_objext \
8196    conftest$ac_exeext
8197  if ${ac_cv_search_opendir+:} false; then :
8198  break
8199fi
8200done
8201if ${ac_cv_search_opendir+:} false; then :
8202
8203else
8204  ac_cv_search_opendir=no
8205fi
8206rm conftest.$ac_ext
8207LIBS=$ac_func_search_save_LIBS
8208fi
8209{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8210$as_echo "$ac_cv_search_opendir" >&6; }
8211ac_res=$ac_cv_search_opendir
8212if test "$ac_res" != no; then :
8213  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8214
8215fi
8216
8217else
8218  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
8219$as_echo_n "checking for library containing opendir... " >&6; }
8220if ${ac_cv_search_opendir+:} false; then :
8221  $as_echo_n "(cached) " >&6
8222else
8223  ac_func_search_save_LIBS=$LIBS
8224cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8225/* end confdefs.h.  */
8226
8227/* Override any GCC internal prototype to avoid an error.
8228   Use char because int might match the return type of a GCC
8229   builtin and then its argument prototype would still apply.  */
8230#ifdef __cplusplus
8231extern "C"
8232#endif
8233char opendir ();
8234int
8235main ()
8236{
8237return opendir ();
8238  ;
8239  return 0;
8240}
8241_ACEOF
8242for ac_lib in '' x; do
8243  if test -z "$ac_lib"; then
8244    ac_res="none required"
8245  else
8246    ac_res=-l$ac_lib
8247    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8248  fi
8249  if ac_fn_c_try_link "$LINENO"; then :
8250  ac_cv_search_opendir=$ac_res
8251fi
8252rm -f core conftest.err conftest.$ac_objext \
8253    conftest$ac_exeext
8254  if ${ac_cv_search_opendir+:} false; then :
8255  break
8256fi
8257done
8258if ${ac_cv_search_opendir+:} false; then :
8259
8260else
8261  ac_cv_search_opendir=no
8262fi
8263rm conftest.$ac_ext
8264LIBS=$ac_func_search_save_LIBS
8265fi
8266{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
8267$as_echo "$ac_cv_search_opendir" >&6; }
8268ac_res=$ac_cv_search_opendir
8269if test "$ac_res" != no; then :
8270  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8271
8272fi
8273
8274fi
8275
8276{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5
8277$as_echo_n "checking whether sys/types.h defines makedev... " >&6; }
8278if ${ac_cv_header_sys_types_h_makedev+:} false; then :
8279  $as_echo_n "(cached) " >&6
8280else
8281  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8282/* end confdefs.h.  */
8283#include <sys/types.h>
8284int
8285main ()
8286{
8287return makedev(0, 0);
8288  ;
8289  return 0;
8290}
8291_ACEOF
8292if ac_fn_c_try_link "$LINENO"; then :
8293  ac_cv_header_sys_types_h_makedev=yes
8294else
8295  ac_cv_header_sys_types_h_makedev=no
8296fi
8297rm -f core conftest.err conftest.$ac_objext \
8298    conftest$ac_exeext conftest.$ac_ext
8299
8300fi
8301{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5
8302$as_echo "$ac_cv_header_sys_types_h_makedev" >&6; }
8303
8304if test $ac_cv_header_sys_types_h_makedev = no; then
8305ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
8306if test "x$ac_cv_header_sys_mkdev_h" = xyes; then :
8307
8308$as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h
8309
8310fi
8311
8312
8313
8314  if test $ac_cv_header_sys_mkdev_h = no; then
8315    ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
8316if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then :
8317
8318$as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h
8319
8320fi
8321
8322
8323  fi
8324fi
8325
8326
8327# bluetooth/bluetooth.h has been known to not compile with -std=c99.
8328# http://permalink.gmane.org/gmane.linux.bluez.kernel/22294
8329SAVE_CFLAGS=$CFLAGS
8330CFLAGS="-std=c99 $CFLAGS"
8331for ac_header in bluetooth/bluetooth.h
8332do :
8333  ac_fn_c_check_header_mongrel "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default"
8334if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes; then :
8335  cat >>confdefs.h <<_ACEOF
8336#define HAVE_BLUETOOTH_BLUETOOTH_H 1
8337_ACEOF
8338
8339fi
8340
8341done
8342
8343CFLAGS=$SAVE_CFLAGS
8344
8345# On Darwin (OS X) net/if.h requires sys/socket.h to be imported first.
8346for ac_header in net/if.h
8347do :
8348  ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#include <stdio.h>
8349#ifdef STDC_HEADERS
8350# include <stdlib.h>
8351# include <stddef.h>
8352#else
8353# ifdef HAVE_STDLIB_H
8354#  include <stdlib.h>
8355# endif
8356#endif
8357#ifdef HAVE_SYS_SOCKET_H
8358# include <sys/socket.h>
8359#endif
8360
8361"
8362if test "x$ac_cv_header_net_if_h" = xyes; then :
8363  cat >>confdefs.h <<_ACEOF
8364#define HAVE_NET_IF_H 1
8365_ACEOF
8366
8367fi
8368
8369done
8370
8371
8372# On Linux, netlink.h requires asm/types.h
8373for ac_header in linux/netlink.h
8374do :
8375  ac_fn_c_check_header_compile "$LINENO" "linux/netlink.h" "ac_cv_header_linux_netlink_h" "
8376#ifdef HAVE_ASM_TYPES_H
8377#include <asm/types.h>
8378#endif
8379#ifdef HAVE_SYS_SOCKET_H
8380#include <sys/socket.h>
8381#endif
8382
8383"
8384if test "x$ac_cv_header_linux_netlink_h" = xyes; then :
8385  cat >>confdefs.h <<_ACEOF
8386#define HAVE_LINUX_NETLINK_H 1
8387_ACEOF
8388
8389fi
8390
8391done
8392
8393
8394# On Linux, qrtr.h requires asm/types.h
8395for ac_header in linux/qrtr.h
8396do :
8397  ac_fn_c_check_header_compile "$LINENO" "linux/qrtr.h" "ac_cv_header_linux_qrtr_h" "
8398#ifdef HAVE_ASM_TYPES_H
8399#include <asm/types.h>
8400#endif
8401#ifdef HAVE_SYS_SOCKET_H
8402#include <sys/socket.h>
8403#endif
8404
8405"
8406if test "x$ac_cv_header_linux_qrtr_h" = xyes; then :
8407  cat >>confdefs.h <<_ACEOF
8408#define HAVE_LINUX_QRTR_H 1
8409_ACEOF
8410
8411fi
8412
8413done
8414
8415
8416for ac_header in linux/vm_sockets.h
8417do :
8418  ac_fn_c_check_header_compile "$LINENO" "linux/vm_sockets.h" "ac_cv_header_linux_vm_sockets_h" "
8419#ifdef HAVE_SYS_SOCKET_H
8420#include <sys/socket.h>
8421#endif
8422
8423"
8424if test "x$ac_cv_header_linux_vm_sockets_h" = xyes; then :
8425  cat >>confdefs.h <<_ACEOF
8426#define HAVE_LINUX_VM_SOCKETS_H 1
8427_ACEOF
8428
8429fi
8430
8431done
8432
8433
8434# On Linux, can.h, can/bcm.h, can/j1939.h, can/raw.h require sys/socket.h
8435for ac_header in linux/can.h linux/can/bcm.h linux/can/j1939.h linux/can/raw.h
8436do :
8437  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8438ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
8439#ifdef HAVE_SYS_SOCKET_H
8440#include <sys/socket.h>
8441#endif
8442
8443"
8444if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8445  cat >>confdefs.h <<_ACEOF
8446#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8447_ACEOF
8448
8449fi
8450
8451done
8452
8453
8454# checks for typedefs
8455was_it_defined=no
8456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5
8457$as_echo_n "checking for clock_t in time.h... " >&6; }
8458cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8459/* end confdefs.h.  */
8460#include <time.h>
8461
8462_ACEOF
8463if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8464  $EGREP "clock_t" >/dev/null 2>&1; then :
8465  was_it_defined=yes
8466else
8467
8468
8469$as_echo "#define clock_t long" >>confdefs.h
8470
8471
8472fi
8473rm -f conftest*
8474
8475{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5
8476$as_echo "$was_it_defined" >&6; }
8477
8478{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5
8479$as_echo_n "checking for makedev... " >&6; }
8480cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8481/* end confdefs.h.  */
8482
8483#if defined(MAJOR_IN_MKDEV)
8484#include <sys/mkdev.h>
8485#elif defined(MAJOR_IN_SYSMACROS)
8486#include <sys/sysmacros.h>
8487#else
8488#include <sys/types.h>
8489#endif
8490
8491int
8492main ()
8493{
8494
8495  makedev(0, 0)
8496  ;
8497  return 0;
8498}
8499
8500_ACEOF
8501if ac_fn_c_try_link "$LINENO"; then :
8502  ac_cv_has_makedev=yes
8503else
8504  ac_cv_has_makedev=no
8505fi
8506rm -f core conftest.err conftest.$ac_objext \
8507    conftest$ac_exeext conftest.$ac_ext
8508{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5
8509$as_echo "$ac_cv_has_makedev" >&6; }
8510if test "$ac_cv_has_makedev" = "yes"; then
8511
8512$as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h
8513
8514fi
8515
8516# byte swapping
8517{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for le64toh" >&5
8518$as_echo_n "checking for le64toh... " >&6; }
8519cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8520/* end confdefs.h.  */
8521
8522#ifdef HAVE_ENDIAN_H
8523#include <endian.h>
8524#elif defined(HAVE_SYS_ENDIAN_H)
8525#include <sys/endian.h>
8526#endif
8527
8528int
8529main ()
8530{
8531
8532   le64toh(1)
8533  ;
8534  return 0;
8535}
8536
8537_ACEOF
8538if ac_fn_c_try_link "$LINENO"; then :
8539  ac_cv_has_le64toh=yes
8540else
8541  ac_cv_has_le64toh=no
8542fi
8543rm -f core conftest.err conftest.$ac_objext \
8544    conftest$ac_exeext conftest.$ac_ext
8545{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_le64toh" >&5
8546$as_echo "$ac_cv_has_le64toh" >&6; }
8547if test "$ac_cv_has_le64toh" = "yes"; then
8548
8549$as_echo "#define HAVE_HTOLE64 1" >>confdefs.h
8550
8551fi
8552
8553use_lfs=yes
8554# Don't use largefile support for GNU/Hurd
8555case $ac_sys_system in GNU*)
8556  use_lfs=no
8557esac
8558
8559if test "$use_lfs" = "yes"; then
8560# Two defines needed to enable largefile support on various platforms
8561# These may affect some typedefs
8562case $ac_sys_system/$ac_sys_release in
8563AIX*)
8564
8565$as_echo "#define _LARGE_FILES 1" >>confdefs.h
8566
8567    ;;
8568esac
8569
8570$as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h
8571
8572
8573$as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h
8574
8575fi
8576
8577# Add some code to confdefs.h so that the test for off_t works on SCO
8578cat >> confdefs.h <<\EOF
8579#if defined(SCO_DS)
8580#undef _OFF_T
8581#endif
8582EOF
8583
8584# Type availability checks
8585ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
8586if test "x$ac_cv_type_mode_t" = xyes; then :
8587
8588else
8589
8590cat >>confdefs.h <<_ACEOF
8591#define mode_t int
8592_ACEOF
8593
8594fi
8595
8596ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
8597if test "x$ac_cv_type_off_t" = xyes; then :
8598
8599else
8600
8601cat >>confdefs.h <<_ACEOF
8602#define off_t long int
8603_ACEOF
8604
8605fi
8606
8607ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
8608if test "x$ac_cv_type_pid_t" = xyes; then :
8609
8610else
8611
8612cat >>confdefs.h <<_ACEOF
8613#define pid_t int
8614_ACEOF
8615
8616fi
8617
8618
8619cat >>confdefs.h <<_ACEOF
8620#define RETSIGTYPE void
8621_ACEOF
8622
8623ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
8624if test "x$ac_cv_type_size_t" = xyes; then :
8625
8626else
8627
8628cat >>confdefs.h <<_ACEOF
8629#define size_t unsigned int
8630_ACEOF
8631
8632fi
8633
8634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
8635$as_echo_n "checking for uid_t in sys/types.h... " >&6; }
8636if ${ac_cv_type_uid_t+:} false; then :
8637  $as_echo_n "(cached) " >&6
8638else
8639  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8640/* end confdefs.h.  */
8641#include <sys/types.h>
8642
8643_ACEOF
8644if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8645  $EGREP "uid_t" >/dev/null 2>&1; then :
8646  ac_cv_type_uid_t=yes
8647else
8648  ac_cv_type_uid_t=no
8649fi
8650rm -f conftest*
8651
8652fi
8653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
8654$as_echo "$ac_cv_type_uid_t" >&6; }
8655if test $ac_cv_type_uid_t = no; then
8656
8657$as_echo "#define uid_t int" >>confdefs.h
8658
8659
8660$as_echo "#define gid_t int" >>confdefs.h
8661
8662fi
8663
8664
8665ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
8666if test "x$ac_cv_type_ssize_t" = xyes; then :
8667
8668$as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h
8669
8670fi
8671
8672ac_fn_c_check_type "$LINENO" "__uint128_t" "ac_cv_type___uint128_t" "$ac_includes_default"
8673if test "x$ac_cv_type___uint128_t" = xyes; then :
8674
8675$as_echo "#define HAVE_GCC_UINT128_T 1" >>confdefs.h
8676
8677fi
8678
8679
8680# Sizes and alignments of various common basic types
8681# ANSI C requires sizeof(char) == 1, so no need to check it
8682# The cast to long int works around a bug in the HP C Compiler
8683# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8684# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8685# This bug is HP SR number 8606223364.
8686{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
8687$as_echo_n "checking size of int... " >&6; }
8688if ${ac_cv_sizeof_int+:} false; then :
8689  $as_echo_n "(cached) " >&6
8690else
8691  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
8692
8693else
8694  if test "$ac_cv_type_int" = yes; then
8695     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8696$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8697as_fn_error 77 "cannot compute sizeof (int)
8698See \`config.log' for more details" "$LINENO" 5; }
8699   else
8700     ac_cv_sizeof_int=0
8701   fi
8702fi
8703
8704fi
8705{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
8706$as_echo "$ac_cv_sizeof_int" >&6; }
8707
8708
8709
8710cat >>confdefs.h <<_ACEOF
8711#define SIZEOF_INT $ac_cv_sizeof_int
8712_ACEOF
8713
8714
8715# The cast to long int works around a bug in the HP C Compiler
8716# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8717# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8718# This bug is HP SR number 8606223364.
8719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
8720$as_echo_n "checking size of long... " >&6; }
8721if ${ac_cv_sizeof_long+:} false; then :
8722  $as_echo_n "(cached) " >&6
8723else
8724  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
8725
8726else
8727  if test "$ac_cv_type_long" = yes; then
8728     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8729$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8730as_fn_error 77 "cannot compute sizeof (long)
8731See \`config.log' for more details" "$LINENO" 5; }
8732   else
8733     ac_cv_sizeof_long=0
8734   fi
8735fi
8736
8737fi
8738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
8739$as_echo "$ac_cv_sizeof_long" >&6; }
8740
8741
8742
8743cat >>confdefs.h <<_ACEOF
8744#define SIZEOF_LONG $ac_cv_sizeof_long
8745_ACEOF
8746
8747
8748# The cast to long int works around a bug in the HP C Compiler,
8749# see AC_CHECK_SIZEOF for more information.
8750{ $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long" >&5
8751$as_echo_n "checking alignment of long... " >&6; }
8752if ${ac_cv_alignof_long+:} false; then :
8753  $as_echo_n "(cached) " >&6
8754else
8755  if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long"        "$ac_includes_default
8756#ifndef offsetof
8757# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
8758#endif
8759typedef struct { char x; long y; } ac__type_alignof_;"; then :
8760
8761else
8762  if test "$ac_cv_type_long" = yes; then
8763     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8764$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8765as_fn_error 77 "cannot compute alignment of long
8766See \`config.log' for more details" "$LINENO" 5; }
8767   else
8768     ac_cv_alignof_long=0
8769   fi
8770fi
8771
8772fi
8773{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long" >&5
8774$as_echo "$ac_cv_alignof_long" >&6; }
8775
8776
8777
8778cat >>confdefs.h <<_ACEOF
8779#define ALIGNOF_LONG $ac_cv_alignof_long
8780_ACEOF
8781
8782
8783# The cast to long int works around a bug in the HP C Compiler
8784# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8785# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8786# This bug is HP SR number 8606223364.
8787{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
8788$as_echo_n "checking size of long long... " >&6; }
8789if ${ac_cv_sizeof_long_long+:} false; then :
8790  $as_echo_n "(cached) " >&6
8791else
8792  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"; then :
8793
8794else
8795  if test "$ac_cv_type_long_long" = yes; then
8796     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8797$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8798as_fn_error 77 "cannot compute sizeof (long long)
8799See \`config.log' for more details" "$LINENO" 5; }
8800   else
8801     ac_cv_sizeof_long_long=0
8802   fi
8803fi
8804
8805fi
8806{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
8807$as_echo "$ac_cv_sizeof_long_long" >&6; }
8808
8809
8810
8811cat >>confdefs.h <<_ACEOF
8812#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
8813_ACEOF
8814
8815
8816# The cast to long int works around a bug in the HP C Compiler
8817# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8818# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8819# This bug is HP SR number 8606223364.
8820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
8821$as_echo_n "checking size of void *... " >&6; }
8822if ${ac_cv_sizeof_void_p+:} false; then :
8823  $as_echo_n "(cached) " >&6
8824else
8825  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p"        "$ac_includes_default"; then :
8826
8827else
8828  if test "$ac_cv_type_void_p" = yes; then
8829     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8830$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8831as_fn_error 77 "cannot compute sizeof (void *)
8832See \`config.log' for more details" "$LINENO" 5; }
8833   else
8834     ac_cv_sizeof_void_p=0
8835   fi
8836fi
8837
8838fi
8839{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
8840$as_echo "$ac_cv_sizeof_void_p" >&6; }
8841
8842
8843
8844cat >>confdefs.h <<_ACEOF
8845#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
8846_ACEOF
8847
8848
8849# The cast to long int works around a bug in the HP C Compiler
8850# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8851# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8852# This bug is HP SR number 8606223364.
8853{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
8854$as_echo_n "checking size of short... " >&6; }
8855if ${ac_cv_sizeof_short+:} false; then :
8856  $as_echo_n "(cached) " >&6
8857else
8858  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
8859
8860else
8861  if test "$ac_cv_type_short" = yes; then
8862     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8863$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8864as_fn_error 77 "cannot compute sizeof (short)
8865See \`config.log' for more details" "$LINENO" 5; }
8866   else
8867     ac_cv_sizeof_short=0
8868   fi
8869fi
8870
8871fi
8872{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
8873$as_echo "$ac_cv_sizeof_short" >&6; }
8874
8875
8876
8877cat >>confdefs.h <<_ACEOF
8878#define SIZEOF_SHORT $ac_cv_sizeof_short
8879_ACEOF
8880
8881
8882# The cast to long int works around a bug in the HP C Compiler
8883# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8884# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8885# This bug is HP SR number 8606223364.
8886{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5
8887$as_echo_n "checking size of float... " >&6; }
8888if ${ac_cv_sizeof_float+:} false; then :
8889  $as_echo_n "(cached) " >&6
8890else
8891  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (float))" "ac_cv_sizeof_float"        "$ac_includes_default"; then :
8892
8893else
8894  if test "$ac_cv_type_float" = yes; then
8895     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8896$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8897as_fn_error 77 "cannot compute sizeof (float)
8898See \`config.log' for more details" "$LINENO" 5; }
8899   else
8900     ac_cv_sizeof_float=0
8901   fi
8902fi
8903
8904fi
8905{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5
8906$as_echo "$ac_cv_sizeof_float" >&6; }
8907
8908
8909
8910cat >>confdefs.h <<_ACEOF
8911#define SIZEOF_FLOAT $ac_cv_sizeof_float
8912_ACEOF
8913
8914
8915# The cast to long int works around a bug in the HP C Compiler
8916# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8917# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8918# This bug is HP SR number 8606223364.
8919{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5
8920$as_echo_n "checking size of double... " >&6; }
8921if ${ac_cv_sizeof_double+:} false; then :
8922  $as_echo_n "(cached) " >&6
8923else
8924  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double"        "$ac_includes_default"; then :
8925
8926else
8927  if test "$ac_cv_type_double" = yes; then
8928     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8929$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8930as_fn_error 77 "cannot compute sizeof (double)
8931See \`config.log' for more details" "$LINENO" 5; }
8932   else
8933     ac_cv_sizeof_double=0
8934   fi
8935fi
8936
8937fi
8938{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5
8939$as_echo "$ac_cv_sizeof_double" >&6; }
8940
8941
8942
8943cat >>confdefs.h <<_ACEOF
8944#define SIZEOF_DOUBLE $ac_cv_sizeof_double
8945_ACEOF
8946
8947
8948# The cast to long int works around a bug in the HP C Compiler
8949# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8950# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8951# This bug is HP SR number 8606223364.
8952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5
8953$as_echo_n "checking size of fpos_t... " >&6; }
8954if ${ac_cv_sizeof_fpos_t+:} false; then :
8955  $as_echo_n "(cached) " >&6
8956else
8957  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (fpos_t))" "ac_cv_sizeof_fpos_t"        "$ac_includes_default"; then :
8958
8959else
8960  if test "$ac_cv_type_fpos_t" = yes; then
8961     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8962$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8963as_fn_error 77 "cannot compute sizeof (fpos_t)
8964See \`config.log' for more details" "$LINENO" 5; }
8965   else
8966     ac_cv_sizeof_fpos_t=0
8967   fi
8968fi
8969
8970fi
8971{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5
8972$as_echo "$ac_cv_sizeof_fpos_t" >&6; }
8973
8974
8975
8976cat >>confdefs.h <<_ACEOF
8977#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
8978_ACEOF
8979
8980
8981# The cast to long int works around a bug in the HP C Compiler
8982# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8983# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8984# This bug is HP SR number 8606223364.
8985{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
8986$as_echo_n "checking size of size_t... " >&6; }
8987if ${ac_cv_sizeof_size_t+:} false; then :
8988  $as_echo_n "(cached) " >&6
8989else
8990  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t"        "$ac_includes_default"; then :
8991
8992else
8993  if test "$ac_cv_type_size_t" = yes; then
8994     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8995$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
8996as_fn_error 77 "cannot compute sizeof (size_t)
8997See \`config.log' for more details" "$LINENO" 5; }
8998   else
8999     ac_cv_sizeof_size_t=0
9000   fi
9001fi
9002
9003fi
9004{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
9005$as_echo "$ac_cv_sizeof_size_t" >&6; }
9006
9007
9008
9009cat >>confdefs.h <<_ACEOF
9010#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
9011_ACEOF
9012
9013
9014# The cast to long int works around a bug in the HP C Compiler,
9015# see AC_CHECK_SIZEOF for more information.
9016{ $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of size_t" >&5
9017$as_echo_n "checking alignment of size_t... " >&6; }
9018if ${ac_cv_alignof_size_t+:} false; then :
9019  $as_echo_n "(cached) " >&6
9020else
9021  if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_size_t"        "$ac_includes_default
9022#ifndef offsetof
9023# define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
9024#endif
9025typedef struct { char x; size_t y; } ac__type_alignof_;"; then :
9026
9027else
9028  if test "$ac_cv_type_size_t" = yes; then
9029     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9030$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9031as_fn_error 77 "cannot compute alignment of size_t
9032See \`config.log' for more details" "$LINENO" 5; }
9033   else
9034     ac_cv_alignof_size_t=0
9035   fi
9036fi
9037
9038fi
9039{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_size_t" >&5
9040$as_echo "$ac_cv_alignof_size_t" >&6; }
9041
9042
9043
9044cat >>confdefs.h <<_ACEOF
9045#define ALIGNOF_SIZE_T $ac_cv_alignof_size_t
9046_ACEOF
9047
9048
9049# The cast to long int works around a bug in the HP C Compiler
9050# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9051# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9052# This bug is HP SR number 8606223364.
9053{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5
9054$as_echo_n "checking size of pid_t... " >&6; }
9055if ${ac_cv_sizeof_pid_t+:} false; then :
9056  $as_echo_n "(cached) " >&6
9057else
9058  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pid_t))" "ac_cv_sizeof_pid_t"        "$ac_includes_default"; then :
9059
9060else
9061  if test "$ac_cv_type_pid_t" = yes; then
9062     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9063$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9064as_fn_error 77 "cannot compute sizeof (pid_t)
9065See \`config.log' for more details" "$LINENO" 5; }
9066   else
9067     ac_cv_sizeof_pid_t=0
9068   fi
9069fi
9070
9071fi
9072{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5
9073$as_echo "$ac_cv_sizeof_pid_t" >&6; }
9074
9075
9076
9077cat >>confdefs.h <<_ACEOF
9078#define SIZEOF_PID_T $ac_cv_sizeof_pid_t
9079_ACEOF
9080
9081
9082# The cast to long int works around a bug in the HP C Compiler
9083# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9084# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9085# This bug is HP SR number 8606223364.
9086{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5
9087$as_echo_n "checking size of uintptr_t... " >&6; }
9088if ${ac_cv_sizeof_uintptr_t+:} false; then :
9089  $as_echo_n "(cached) " >&6
9090else
9091  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (uintptr_t))" "ac_cv_sizeof_uintptr_t"        "$ac_includes_default"; then :
9092
9093else
9094  if test "$ac_cv_type_uintptr_t" = yes; then
9095     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9096$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9097as_fn_error 77 "cannot compute sizeof (uintptr_t)
9098See \`config.log' for more details" "$LINENO" 5; }
9099   else
9100     ac_cv_sizeof_uintptr_t=0
9101   fi
9102fi
9103
9104fi
9105{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5
9106$as_echo "$ac_cv_sizeof_uintptr_t" >&6; }
9107
9108
9109
9110cat >>confdefs.h <<_ACEOF
9111#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
9112_ACEOF
9113
9114
9115
9116
9117  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
9118$as_echo_n "checking for long double... " >&6; }
9119if ${ac_cv_type_long_double+:} false; then :
9120  $as_echo_n "(cached) " >&6
9121else
9122  if test "$GCC" = yes; then
9123       ac_cv_type_long_double=yes
9124     else
9125       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9126/* end confdefs.h.  */
9127/* The Stardent Vistra knows sizeof (long double), but does
9128		 not support it.  */
9129	      long double foo = 0.0L;
9130int
9131main ()
9132{
9133static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8.  */
9134	      sizeof (double) <= sizeof (long double))];
9135test_array [0] = 0;
9136return test_array [0];
9137
9138  ;
9139  return 0;
9140}
9141_ACEOF
9142if ac_fn_c_try_compile "$LINENO"; then :
9143  ac_cv_type_long_double=yes
9144else
9145  ac_cv_type_long_double=no
9146fi
9147rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9148     fi
9149fi
9150{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
9151$as_echo "$ac_cv_type_long_double" >&6; }
9152  if test $ac_cv_type_long_double = yes; then
9153
9154$as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
9155
9156  fi
9157
9158# The cast to long int works around a bug in the HP C Compiler
9159# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9160# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9161# This bug is HP SR number 8606223364.
9162{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5
9163$as_echo_n "checking size of long double... " >&6; }
9164if ${ac_cv_sizeof_long_double+:} false; then :
9165  $as_echo_n "(cached) " >&6
9166else
9167  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double"        "$ac_includes_default"; then :
9168
9169else
9170  if test "$ac_cv_type_long_double" = yes; then
9171     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9172$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9173as_fn_error 77 "cannot compute sizeof (long double)
9174See \`config.log' for more details" "$LINENO" 5; }
9175   else
9176     ac_cv_sizeof_long_double=0
9177   fi
9178fi
9179
9180fi
9181{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5
9182$as_echo "$ac_cv_sizeof_long_double" >&6; }
9183
9184
9185
9186cat >>confdefs.h <<_ACEOF
9187#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
9188_ACEOF
9189
9190
9191
9192# The cast to long int works around a bug in the HP C Compiler
9193# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9194# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9195# This bug is HP SR number 8606223364.
9196{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5
9197$as_echo_n "checking size of _Bool... " >&6; }
9198if ${ac_cv_sizeof__Bool+:} false; then :
9199  $as_echo_n "(cached) " >&6
9200else
9201  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (_Bool))" "ac_cv_sizeof__Bool"        "$ac_includes_default"; then :
9202
9203else
9204  if test "$ac_cv_type__Bool" = yes; then
9205     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9206$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9207as_fn_error 77 "cannot compute sizeof (_Bool)
9208See \`config.log' for more details" "$LINENO" 5; }
9209   else
9210     ac_cv_sizeof__Bool=0
9211   fi
9212fi
9213
9214fi
9215{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5
9216$as_echo "$ac_cv_sizeof__Bool" >&6; }
9217
9218
9219
9220cat >>confdefs.h <<_ACEOF
9221#define SIZEOF__BOOL $ac_cv_sizeof__Bool
9222_ACEOF
9223
9224
9225
9226# The cast to long int works around a bug in the HP C Compiler
9227# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9228# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9229# This bug is HP SR number 8606223364.
9230{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
9231$as_echo_n "checking size of off_t... " >&6; }
9232if ${ac_cv_sizeof_off_t+:} false; then :
9233  $as_echo_n "(cached) " >&6
9234else
9235  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t"        "
9236#ifdef HAVE_SYS_TYPES_H
9237#include <sys/types.h>
9238#endif
9239
9240"; then :
9241
9242else
9243  if test "$ac_cv_type_off_t" = yes; then
9244     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9245$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9246as_fn_error 77 "cannot compute sizeof (off_t)
9247See \`config.log' for more details" "$LINENO" 5; }
9248   else
9249     ac_cv_sizeof_off_t=0
9250   fi
9251fi
9252
9253fi
9254{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
9255$as_echo "$ac_cv_sizeof_off_t" >&6; }
9256
9257
9258
9259cat >>confdefs.h <<_ACEOF
9260#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
9261_ACEOF
9262
9263
9264
9265{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5
9266$as_echo_n "checking whether to enable large file support... " >&6; }
9267if test "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
9268	"$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
9269
9270$as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h
9271
9272  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9273$as_echo "yes" >&6; }
9274else
9275  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9276$as_echo "no" >&6; }
9277fi
9278
9279# The cast to long int works around a bug in the HP C Compiler
9280# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9281# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9282# This bug is HP SR number 8606223364.
9283{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
9284$as_echo_n "checking size of time_t... " >&6; }
9285if ${ac_cv_sizeof_time_t+:} false; then :
9286  $as_echo_n "(cached) " >&6
9287else
9288  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "
9289#ifdef HAVE_SYS_TYPES_H
9290#include <sys/types.h>
9291#endif
9292#ifdef HAVE_TIME_H
9293#include <time.h>
9294#endif
9295
9296"; then :
9297
9298else
9299  if test "$ac_cv_type_time_t" = yes; then
9300     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9301$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9302as_fn_error 77 "cannot compute sizeof (time_t)
9303See \`config.log' for more details" "$LINENO" 5; }
9304   else
9305     ac_cv_sizeof_time_t=0
9306   fi
9307fi
9308
9309fi
9310{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
9311$as_echo "$ac_cv_sizeof_time_t" >&6; }
9312
9313
9314
9315cat >>confdefs.h <<_ACEOF
9316#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
9317_ACEOF
9318
9319
9320
9321# if have pthread_t then define SIZEOF_PTHREAD_T
9322ac_save_cc="$CC"
9323if test "$ac_cv_kpthread" = "yes"
9324then CC="$CC -Kpthread"
9325elif test "$ac_cv_kthread" = "yes"
9326then CC="$CC -Kthread"
9327elif test "$ac_cv_pthread" = "yes"
9328then CC="$CC -pthread"
9329fi
9330
9331{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5
9332$as_echo_n "checking for pthread_t... " >&6; }
9333have_pthread_t=no
9334cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9335/* end confdefs.h.  */
9336
9337  #include <pthread.h>
9338int
9339main ()
9340{
9341pthread_t x; x = *(pthread_t*)0;
9342  ;
9343  return 0;
9344}
9345
9346_ACEOF
9347if ac_fn_c_try_compile "$LINENO"; then :
9348  have_pthread_t=yes
9349fi
9350rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9351{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5
9352$as_echo "$have_pthread_t" >&6; }
9353if test "$have_pthread_t" = yes ; then
9354  # The cast to long int works around a bug in the HP C Compiler
9355# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9356# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9357# This bug is HP SR number 8606223364.
9358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
9359$as_echo_n "checking size of pthread_t... " >&6; }
9360if ${ac_cv_sizeof_pthread_t+:} false; then :
9361  $as_echo_n "(cached) " >&6
9362else
9363  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t"        "
9364#ifdef HAVE_PTHREAD_H
9365#include <pthread.h>
9366#endif
9367
9368"; then :
9369
9370else
9371  if test "$ac_cv_type_pthread_t" = yes; then
9372     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9373$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9374as_fn_error 77 "cannot compute sizeof (pthread_t)
9375See \`config.log' for more details" "$LINENO" 5; }
9376   else
9377     ac_cv_sizeof_pthread_t=0
9378   fi
9379fi
9380
9381fi
9382{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
9383$as_echo "$ac_cv_sizeof_pthread_t" >&6; }
9384
9385
9386
9387cat >>confdefs.h <<_ACEOF
9388#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
9389_ACEOF
9390
9391
9392fi
9393
9394# Issue #25658: POSIX hasn't defined that pthread_key_t is compatible with int.
9395# This checking will be unnecessary after removing deprecated TLS API.
9396# The cast to long int works around a bug in the HP C Compiler
9397# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9398# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9399# This bug is HP SR number 8606223364.
9400{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_key_t" >&5
9401$as_echo_n "checking size of pthread_key_t... " >&6; }
9402if ${ac_cv_sizeof_pthread_key_t+:} false; then :
9403  $as_echo_n "(cached) " >&6
9404else
9405  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_key_t))" "ac_cv_sizeof_pthread_key_t"        "#include <pthread.h>
9406"; then :
9407
9408else
9409  if test "$ac_cv_type_pthread_key_t" = yes; then
9410     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9411$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9412as_fn_error 77 "cannot compute sizeof (pthread_key_t)
9413See \`config.log' for more details" "$LINENO" 5; }
9414   else
9415     ac_cv_sizeof_pthread_key_t=0
9416   fi
9417fi
9418
9419fi
9420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_key_t" >&5
9421$as_echo "$ac_cv_sizeof_pthread_key_t" >&6; }
9422
9423
9424
9425cat >>confdefs.h <<_ACEOF
9426#define SIZEOF_PTHREAD_KEY_T $ac_cv_sizeof_pthread_key_t
9427_ACEOF
9428
9429
9430{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_key_t is compatible with int" >&5
9431$as_echo_n "checking whether pthread_key_t is compatible with int... " >&6; }
9432if test "$ac_cv_sizeof_pthread_key_t" -eq "$ac_cv_sizeof_int" ; then
9433  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9434/* end confdefs.h.  */
9435#include <pthread.h>
9436int
9437main ()
9438{
9439pthread_key_t k; k * 1;
9440  ;
9441  return 0;
9442}
9443_ACEOF
9444if ac_fn_c_try_compile "$LINENO"; then :
9445  ac_pthread_key_t_is_arithmetic_type=yes
9446else
9447  ac_pthread_key_t_is_arithmetic_type=no
9448
9449fi
9450rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9451  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pthread_key_t_is_arithmetic_type" >&5
9452$as_echo "$ac_pthread_key_t_is_arithmetic_type" >&6; }
9453  if test "$ac_pthread_key_t_is_arithmetic_type" = yes ; then
9454
9455$as_echo "#define PTHREAD_KEY_T_IS_COMPATIBLE_WITH_INT 1" >>confdefs.h
9456
9457  fi
9458else
9459  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9460$as_echo "no" >&6; }
9461fi
9462CC="$ac_save_cc"
9463
9464
9465case $ac_sys_system/$ac_sys_release in
9466  Darwin/[01567]\..*)
9467    OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000"
9468    ;;
9469  Darwin/*)
9470    OTHER_LIBTOOL_OPT=""
9471    ;;
9472esac
9473
9474
9475
9476case $ac_sys_system/$ac_sys_release in
9477  Darwin/[01567]\..*)
9478    LIBTOOL_CRUFT="-framework System -lcc_dynamic"
9479    if test "${enable_universalsdk}"; then
9480	    :
9481    else
9482        LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`"
9483    fi
9484    LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9485    LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
9486  Darwin/*)
9487    gcc_version=`gcc -dumpversion`
9488    if test ${gcc_version} '<' 4.0
9489        then
9490            LIBTOOL_CRUFT="-lcc_dynamic"
9491        else
9492            LIBTOOL_CRUFT=""
9493    fi
9494    if test "$cross_compiling" = yes; then :
9495  ac_osx_32bit=yes
9496else
9497  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9498/* end confdefs.h.  */
9499
9500    #include <unistd.h>
9501    int main(int argc, char*argv[])
9502    {
9503      if (sizeof(long) == 4) {
9504    	  return 0;
9505      } else {
9506      	  return 1;
9507      }
9508    }
9509
9510_ACEOF
9511if ac_fn_c_try_run "$LINENO"; then :
9512  ac_osx_32bit=yes
9513else
9514  ac_osx_32bit=no
9515fi
9516rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9517  conftest.$ac_objext conftest.beam conftest.$ac_ext
9518fi
9519
9520
9521    if test "${ac_osx_32bit}" = "yes"; then
9522    	case `/usr/bin/arch` in
9523    	i386)
9524    		MACOSX_DEFAULT_ARCH="i386"
9525    		;;
9526    	ppc)
9527    		MACOSX_DEFAULT_ARCH="ppc"
9528    		;;
9529    	*)
9530    		as_fn_error $? "Unexpected output of 'arch' on macOS" "$LINENO" 5
9531    		;;
9532    	esac
9533    else
9534    	case `/usr/bin/arch` in
9535    	i386)
9536    		MACOSX_DEFAULT_ARCH="x86_64"
9537    		;;
9538    	ppc)
9539    		MACOSX_DEFAULT_ARCH="ppc64"
9540		;;
9541    	arm64)
9542    		MACOSX_DEFAULT_ARCH="arm64"
9543    		;;
9544    	*)
9545    		as_fn_error $? "Unexpected output of 'arch' on macOS" "$LINENO" 5
9546    		;;
9547    	esac
9548
9549    fi
9550
9551    LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}"
9552    LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9553    LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
9554esac
9555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5
9556$as_echo_n "checking for --enable-framework... " >&6; }
9557if test "$enable_framework"
9558then
9559	BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
9560	# -F. is needed to allow linking to the framework while
9561	# in the build location.
9562
9563$as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h
9564
9565	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9566$as_echo "yes" >&6; }
9567	if test $enable_shared = "yes"
9568	then
9569		as_fn_error $? "Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" "$LINENO" 5
9570	fi
9571else
9572	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9573$as_echo "no" >&6; }
9574fi
9575
9576{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5
9577$as_echo_n "checking for dyld... " >&6; }
9578case $ac_sys_system/$ac_sys_release in
9579  Darwin/*)
9580
9581$as_echo "#define WITH_DYLD 1" >>confdefs.h
9582
9583  	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5
9584$as_echo "always on for Darwin" >&6; }
9585  	;;
9586  *)
9587	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9588$as_echo "no" >&6; }
9589	;;
9590esac
9591
9592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-address-sanitizer" >&5
9593$as_echo_n "checking for --with-address-sanitizer... " >&6; }
9594
9595# Check whether --with-address_sanitizer was given.
9596if test "${with_address_sanitizer+set}" = set; then :
9597  withval=$with_address_sanitizer;
9598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
9599$as_echo "$withval" >&6; }
9600BASECFLAGS="-fsanitize=address -fno-omit-frame-pointer $BASECFLAGS"
9601LDFLAGS="-fsanitize=address $LDFLAGS"
9602# ASan works by controlling memory allocation, our own malloc interferes.
9603with_pymalloc="no"
9604
9605else
9606  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9607$as_echo "no" >&6; }
9608fi
9609
9610
9611{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-memory-sanitizer" >&5
9612$as_echo_n "checking for --with-memory-sanitizer... " >&6; }
9613
9614# Check whether --with-memory_sanitizer was given.
9615if test "${with_memory_sanitizer+set}" = set; then :
9616  withval=$with_memory_sanitizer;
9617{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
9618$as_echo "$withval" >&6; }
9619{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fsanitize=memory" >&5
9620$as_echo_n "checking whether C compiler accepts -fsanitize=memory... " >&6; }
9621if ${ax_cv_check_cflags___fsanitize_memory+:} false; then :
9622  $as_echo_n "(cached) " >&6
9623else
9624
9625  ax_check_save_flags=$CFLAGS
9626  CFLAGS="$CFLAGS  -fsanitize=memory"
9627  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9628/* end confdefs.h.  */
9629
9630int
9631main ()
9632{
9633
9634  ;
9635  return 0;
9636}
9637_ACEOF
9638if ac_fn_c_try_compile "$LINENO"; then :
9639  ax_cv_check_cflags___fsanitize_memory=yes
9640else
9641  ax_cv_check_cflags___fsanitize_memory=no
9642fi
9643rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9644  CFLAGS=$ax_check_save_flags
9645fi
9646{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fsanitize_memory" >&5
9647$as_echo "$ax_cv_check_cflags___fsanitize_memory" >&6; }
9648if test "x$ax_cv_check_cflags___fsanitize_memory" = xyes; then :
9649
9650BASECFLAGS="-fsanitize=memory -fsanitize-memory-track-origins=2 -fno-omit-frame-pointer $BASECFLAGS"
9651LDFLAGS="-fsanitize=memory -fsanitize-memory-track-origins=2 $LDFLAGS"
9652
9653else
9654  as_fn_error $? "The selected compiler doesn't support memory sanitizer" "$LINENO" 5
9655fi
9656
9657# MSan works by controlling memory allocation, our own malloc interferes.
9658with_pymalloc="no"
9659
9660else
9661  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9662$as_echo "no" >&6; }
9663fi
9664
9665
9666{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-undefined-behavior-sanitizer" >&5
9667$as_echo_n "checking for --with-undefined-behavior-sanitizer... " >&6; }
9668
9669# Check whether --with-undefined_behavior_sanitizer was given.
9670if test "${with_undefined_behavior_sanitizer+set}" = set; then :
9671  withval=$with_undefined_behavior_sanitizer;
9672{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
9673$as_echo "$withval" >&6; }
9674BASECFLAGS="-fsanitize=undefined $BASECFLAGS"
9675LDFLAGS="-fsanitize=undefined $LDFLAGS"
9676with_ubsan="yes"
9677
9678else
9679
9680{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9681$as_echo "no" >&6; }
9682with_ubsan="no"
9683
9684fi
9685
9686
9687# Set info about shared libraries.
9688
9689
9690
9691
9692
9693
9694
9695# SHLIB_SUFFIX is the extension of shared libraries `(including the dot!)
9696# -- usually .so, .sl on HP-UX, .dll on Cygwin
9697{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the extension of shared libraries" >&5
9698$as_echo_n "checking the extension of shared libraries... " >&6; }
9699if test -z "$SHLIB_SUFFIX"; then
9700	case $ac_sys_system in
9701	hp*|HP*)
9702		case `uname -m` in
9703			ia64) SHLIB_SUFFIX=.so;;
9704	  		*)    SHLIB_SUFFIX=.sl;;
9705		esac
9706		;;
9707	CYGWIN*)   SHLIB_SUFFIX=.dll;;
9708	*)	   SHLIB_SUFFIX=.so;;
9709	esac
9710fi
9711{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIB_SUFFIX" >&5
9712$as_echo "$SHLIB_SUFFIX" >&6; }
9713
9714# LDSHARED is the ld *command* used to create shared library
9715# -- "cc -G" on SunOS 5.x.
9716# (Shared libraries in this instance are shared modules to be loaded into
9717# Python, as opposed to building Python itself as a shared library.)
9718{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5
9719$as_echo_n "checking LDSHARED... " >&6; }
9720if test -z "$LDSHARED"
9721then
9722	case $ac_sys_system/$ac_sys_release in
9723	AIX*)
9724		BLDSHARED="Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
9725		LDSHARED="\$(LIBPL)/ld_so_aix \$(CC) -bI:\$(LIBPL)/python.exp"
9726		;;
9727	SunOS/5*)
9728		if test "$GCC" = "yes" ; then
9729			LDSHARED='$(CC) -shared'
9730			LDCXXSHARED='$(CXX) -shared'
9731		else
9732			LDSHARED='$(CC) -G'
9733			LDCXXSHARED='$(CXX) -G'
9734		fi ;;
9735	hp*|HP*)
9736		if test "$GCC" = "yes" ; then
9737			LDSHARED='$(CC) -shared'
9738			LDCXXSHARED='$(CXX) -shared'
9739		else
9740			LDSHARED='$(CC) -b'
9741			LDCXXSHARED='$(CXX) -b'
9742		fi ;;
9743	Darwin/1.3*)
9744		LDSHARED='$(CC) -bundle'
9745		LDCXXSHARED='$(CXX) -bundle'
9746		if test "$enable_framework" ; then
9747			# Link against the framework. All externals should be defined.
9748			BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9749			LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9750			LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9751		else
9752			# No framework. Ignore undefined symbols, assuming they come from Python
9753			LDSHARED="$LDSHARED -undefined suppress"
9754			LDCXXSHARED="$LDCXXSHARED -undefined suppress"
9755		fi ;;
9756	Darwin/1.4*|Darwin/5.*|Darwin/6.*)
9757		LDSHARED='$(CC) -bundle'
9758		LDCXXSHARED='$(CXX) -bundle'
9759		if test "$enable_framework" ; then
9760			# Link against the framework. All externals should be defined.
9761			BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9762			LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9763			LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9764		else
9765			# No framework, use the Python app as bundle-loader
9766			BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
9767			LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
9768			LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
9769		fi ;;
9770	Darwin/*)
9771		# Use -undefined dynamic_lookup whenever possible (10.3 and later).
9772		# This allows an extension to be used in any Python
9773
9774		dep_target_major=`echo ${MACOSX_DEPLOYMENT_TARGET} | \
9775				sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'`
9776		dep_target_minor=`echo ${MACOSX_DEPLOYMENT_TARGET} | \
9777				sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'`
9778		if test ${dep_target_major} -eq 10 && \
9779		   test ${dep_target_minor} -le 2
9780		then
9781			# building for OS X 10.0 through 10.2
9782			as_fn_error $? "MACOSX_DEPLOYMENT_TARGET too old ($MACOSX_DEPLOYMENT_TARGET), only 10.3 or later is supported" "$LINENO" 5
9783		else
9784			# building for OS X 10.3 and later
9785			LDSHARED='$(CC) -bundle -undefined dynamic_lookup'
9786			LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup'
9787			BLDSHARED="$LDSHARED"
9788		fi
9789		;;
9790	Linux*|GNU*|QNX*|VxWorks*)
9791		LDSHARED='$(CC) -shared'
9792		LDCXXSHARED='$(CXX) -shared';;
9793	FreeBSD*)
9794		if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9795		then
9796			LDSHARED='$(CC) -shared'
9797			LDCXXSHARED='$(CXX) -shared'
9798		else
9799			LDSHARED="ld -Bshareable"
9800		fi;;
9801	OpenBSD*)
9802		if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9803		then
9804				LDSHARED='$(CC) -shared $(CCSHARED)'
9805				LDCXXSHARED='$(CXX) -shared $(CCSHARED)'
9806		else
9807				case `uname -r` in
9808				[01].* | 2.[0-7] | 2.[0-7].*)
9809				   LDSHARED="ld -Bshareable ${LDFLAGS}"
9810				   ;;
9811				*)
9812				   LDSHARED='$(CC) -shared $(CCSHARED)'
9813				   LDCXXSHARED='$(CXX) -shared $(CCSHARED)'
9814				   ;;
9815				esac
9816		fi;;
9817	NetBSD*|DragonFly*)
9818		LDSHARED='$(CC) -shared'
9819		LDCXXSHARED='$(CXX) -shared';;
9820	OpenUNIX*|UnixWare*)
9821		if test "$GCC" = "yes" ; then
9822			LDSHARED='$(CC) -shared'
9823			LDCXXSHARED='$(CXX) -shared'
9824		else
9825			LDSHARED='$(CC) -G'
9826			LDCXXSHARED='$(CXX) -G'
9827		fi;;
9828	SCO_SV*)
9829		LDSHARED='$(CC) -Wl,-G,-Bexport'
9830		LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';;
9831	CYGWIN*)
9832		LDSHARED="gcc -shared -Wl,--enable-auto-image-base"
9833		LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";;
9834	*)	LDSHARED="ld";;
9835	esac
9836fi
9837{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5
9838$as_echo "$LDSHARED" >&6; }
9839LDCXXSHARED=${LDCXXSHARED-$LDSHARED}
9840BLDSHARED=${BLDSHARED-$LDSHARED}
9841# CCSHARED are the C *flags* used to create objects to go into a shared
9842# library (module) -- this is only needed for a few systems
9843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5
9844$as_echo_n "checking CCSHARED... " >&6; }
9845if test -z "$CCSHARED"
9846then
9847	case $ac_sys_system/$ac_sys_release in
9848	SunOS*) if test "$GCC" = yes;
9849		then CCSHARED="-fPIC";
9850		elif test `uname -p` = sparc;
9851		then CCSHARED="-xcode=pic32";
9852		else CCSHARED="-Kpic";
9853		fi;;
9854	hp*|HP*) if test "$GCC" = yes;
9855		 then CCSHARED="-fPIC";
9856		 else CCSHARED="+z";
9857		 fi;;
9858	Linux-android*) ;;
9859	Linux*|GNU*) CCSHARED="-fPIC";;
9860	FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
9861	OpenUNIX*|UnixWare*)
9862		if test "$GCC" = "yes"
9863		then CCSHARED="-fPIC"
9864		else CCSHARED="-KPIC"
9865		fi;;
9866	SCO_SV*)
9867		if test "$GCC" = "yes"
9868		then CCSHARED="-fPIC"
9869		else CCSHARED="-Kpic -belf"
9870		fi;;
9871	VxWorks*)
9872		CCSHARED="-fpic -D__SO_PICABILINUX__  -ftls-model=global-dynamic"
9873	esac
9874fi
9875{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5
9876$as_echo "$CCSHARED" >&6; }
9877# LINKFORSHARED are the flags passed to the $(CC) command that links
9878# the python executable -- this is only needed for a few systems
9879{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5
9880$as_echo_n "checking LINKFORSHARED... " >&6; }
9881if test -z "$LINKFORSHARED"
9882then
9883	case $ac_sys_system/$ac_sys_release in
9884	AIX*)	LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
9885	hp*|HP*)
9886	    LINKFORSHARED="-Wl,-E -Wl,+s";;
9887#	    LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
9888	Linux-android*) LINKFORSHARED="-pie -Xlinker -export-dynamic";;
9889	Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
9890	# -u libsys_s pulls in all symbols in libsys
9891	Darwin/*)
9892		LINKFORSHARED="$extra_undefs -framework CoreFoundation"
9893
9894		# Issue #18075: the default maximum stack size (8MBytes) is too
9895		# small for the default recursion limit. Increase the stack size
9896		# to ensure that tests don't crash
9897    stack_size="1000000"  # 16 MB
9898    if test "$with_ubsan" = "yes"
9899    then
9900        # Undefined behavior sanitizer requires an even deeper stack
9901        stack_size="4000000"  # 64 MB
9902    fi
9903
9904    LINKFORSHARED="-Wl,-stack_size,$stack_size $LINKFORSHARED"
9905
9906
9907cat >>confdefs.h <<_ACEOF
9908#define THREAD_STACK_SIZE 0x$stack_size
9909_ACEOF
9910
9911
9912		if test "$enable_framework"
9913		then
9914			LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
9915		fi
9916		LINKFORSHARED="$LINKFORSHARED";;
9917	OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
9918	SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
9919	ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
9920	FreeBSD*|NetBSD*|OpenBSD*|DragonFly*)
9921		if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9922		then
9923			LINKFORSHARED="-Wl,--export-dynamic"
9924		fi;;
9925	SunOS/5*) case $CC in
9926		  *gcc*)
9927		    if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
9928		    then
9929			LINKFORSHARED="-Xlinker --export-dynamic"
9930		    fi;;
9931		  esac;;
9932	CYGWIN*)
9933		if test $enable_shared = "no"
9934		then
9935			LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)'
9936		fi;;
9937	QNX*)
9938		# -Wl,-E causes the symbols to be added to the dynamic
9939		# symbol table so that they can be found when a module
9940		# is loaded.  -N 2048K causes the stack size to be set
9941		# to 2048 kilobytes so that the stack doesn't overflow
9942		# when running test_compile.py.
9943		LINKFORSHARED='-Wl,-E -N 2048K';;
9944	VxWorks*)
9945		LINKFORSHARED='-Wl,-export-dynamic';;
9946	esac
9947fi
9948{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5
9949$as_echo "$LINKFORSHARED" >&6; }
9950
9951
9952
9953{ $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5
9954$as_echo_n "checking CFLAGSFORSHARED... " >&6; }
9955if test ! "$LIBRARY" = "$LDLIBRARY"
9956then
9957	case $ac_sys_system in
9958	CYGWIN*)
9959		# Cygwin needs CCSHARED when building extension DLLs
9960		# but not when building the interpreter DLL.
9961		CFLAGSFORSHARED='';;
9962	*)
9963		CFLAGSFORSHARED='$(CCSHARED)'
9964	esac
9965fi
9966{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5
9967$as_echo "$CFLAGSFORSHARED" >&6; }
9968
9969# SHLIBS are libraries (except -lc and -lm) to link to the python shared
9970# library (with --enable-shared).
9971# For platforms on which shared libraries are not allowed to have unresolved
9972# symbols, this must be set to $(LIBS) (expanded by make). We do this even
9973# if it is not required, since it creates a dependency of the shared library
9974# to LIBS. This, in turn, means that applications linking the shared libpython
9975# don't need to link LIBS explicitly. The default should be only changed
9976# on systems where this approach causes problems.
9977
9978{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5
9979$as_echo_n "checking SHLIBS... " >&6; }
9980case "$ac_sys_system" in
9981	*)
9982		SHLIBS='$(LIBS)';;
9983esac
9984{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5
9985$as_echo "$SHLIBS" >&6; }
9986
9987
9988# checks for libraries
9989{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sendfile in -lsendfile" >&5
9990$as_echo_n "checking for sendfile in -lsendfile... " >&6; }
9991if ${ac_cv_lib_sendfile_sendfile+:} false; then :
9992  $as_echo_n "(cached) " >&6
9993else
9994  ac_check_lib_save_LIBS=$LIBS
9995LIBS="-lsendfile  $LIBS"
9996cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9997/* end confdefs.h.  */
9998
9999/* Override any GCC internal prototype to avoid an error.
10000   Use char because int might match the return type of a GCC
10001   builtin and then its argument prototype would still apply.  */
10002#ifdef __cplusplus
10003extern "C"
10004#endif
10005char sendfile ();
10006int
10007main ()
10008{
10009return sendfile ();
10010  ;
10011  return 0;
10012}
10013_ACEOF
10014if ac_fn_c_try_link "$LINENO"; then :
10015  ac_cv_lib_sendfile_sendfile=yes
10016else
10017  ac_cv_lib_sendfile_sendfile=no
10018fi
10019rm -f core conftest.err conftest.$ac_objext \
10020    conftest$ac_exeext conftest.$ac_ext
10021LIBS=$ac_check_lib_save_LIBS
10022fi
10023{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sendfile_sendfile" >&5
10024$as_echo "$ac_cv_lib_sendfile_sendfile" >&6; }
10025if test "x$ac_cv_lib_sendfile_sendfile" = xyes; then :
10026  cat >>confdefs.h <<_ACEOF
10027#define HAVE_LIBSENDFILE 1
10028_ACEOF
10029
10030  LIBS="-lsendfile $LIBS"
10031
10032fi
10033
10034{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
10035$as_echo_n "checking for dlopen in -ldl... " >&6; }
10036if ${ac_cv_lib_dl_dlopen+:} false; then :
10037  $as_echo_n "(cached) " >&6
10038else
10039  ac_check_lib_save_LIBS=$LIBS
10040LIBS="-ldl  $LIBS"
10041cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10042/* end confdefs.h.  */
10043
10044/* Override any GCC internal prototype to avoid an error.
10045   Use char because int might match the return type of a GCC
10046   builtin and then its argument prototype would still apply.  */
10047#ifdef __cplusplus
10048extern "C"
10049#endif
10050char dlopen ();
10051int
10052main ()
10053{
10054return dlopen ();
10055  ;
10056  return 0;
10057}
10058_ACEOF
10059if ac_fn_c_try_link "$LINENO"; then :
10060  ac_cv_lib_dl_dlopen=yes
10061else
10062  ac_cv_lib_dl_dlopen=no
10063fi
10064rm -f core conftest.err conftest.$ac_objext \
10065    conftest$ac_exeext conftest.$ac_ext
10066LIBS=$ac_check_lib_save_LIBS
10067fi
10068{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
10069$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
10070if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
10071  cat >>confdefs.h <<_ACEOF
10072#define HAVE_LIBDL 1
10073_ACEOF
10074
10075  LIBS="-ldl $LIBS"
10076
10077fi
10078	# Dynamic linking for SunOS/Solaris and SYSV
10079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
10080$as_echo_n "checking for shl_load in -ldld... " >&6; }
10081if ${ac_cv_lib_dld_shl_load+:} false; then :
10082  $as_echo_n "(cached) " >&6
10083else
10084  ac_check_lib_save_LIBS=$LIBS
10085LIBS="-ldld  $LIBS"
10086cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10087/* end confdefs.h.  */
10088
10089/* Override any GCC internal prototype to avoid an error.
10090   Use char because int might match the return type of a GCC
10091   builtin and then its argument prototype would still apply.  */
10092#ifdef __cplusplus
10093extern "C"
10094#endif
10095char shl_load ();
10096int
10097main ()
10098{
10099return shl_load ();
10100  ;
10101  return 0;
10102}
10103_ACEOF
10104if ac_fn_c_try_link "$LINENO"; then :
10105  ac_cv_lib_dld_shl_load=yes
10106else
10107  ac_cv_lib_dld_shl_load=no
10108fi
10109rm -f core conftest.err conftest.$ac_objext \
10110    conftest$ac_exeext conftest.$ac_ext
10111LIBS=$ac_check_lib_save_LIBS
10112fi
10113{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
10114$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
10115if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
10116  cat >>confdefs.h <<_ACEOF
10117#define HAVE_LIBDLD 1
10118_ACEOF
10119
10120  LIBS="-ldld $LIBS"
10121
10122fi
10123	# Dynamic linking for HP-UX
10124
10125# checks for uuid.h location
10126for ac_header in uuid/uuid.h uuid.h
10127do :
10128  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10129ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
10130if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10131  cat >>confdefs.h <<_ACEOF
10132#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10133_ACEOF
10134
10135fi
10136
10137done
10138
10139
10140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate_time_safe" >&5
10141$as_echo_n "checking for uuid_generate_time_safe... " >&6; }
10142cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10143/* end confdefs.h.  */
10144#include <uuid/uuid.h>
10145int
10146main ()
10147{
10148
10149#ifndef uuid_generate_time_safe
10150void *x = uuid_generate_time_safe
10151#endif
10152
10153  ;
10154  return 0;
10155}
10156_ACEOF
10157if ac_fn_c_try_compile "$LINENO"; then :
10158
10159$as_echo "#define HAVE_UUID_GENERATE_TIME_SAFE 1" >>confdefs.h
10160
10161   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10162$as_echo "yes" >&6; }
10163else
10164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10165$as_echo "no" >&6; }
10166
10167fi
10168rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10169
10170# check for libuuid from util-linux
10171save_LIBS=$LIBS
10172{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate_time in -luuid" >&5
10173$as_echo_n "checking for uuid_generate_time in -luuid... " >&6; }
10174if ${ac_cv_lib_uuid_uuid_generate_time+:} false; then :
10175  $as_echo_n "(cached) " >&6
10176else
10177  ac_check_lib_save_LIBS=$LIBS
10178LIBS="-luuid  $LIBS"
10179cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10180/* end confdefs.h.  */
10181
10182/* Override any GCC internal prototype to avoid an error.
10183   Use char because int might match the return type of a GCC
10184   builtin and then its argument prototype would still apply.  */
10185#ifdef __cplusplus
10186extern "C"
10187#endif
10188char uuid_generate_time ();
10189int
10190main ()
10191{
10192return uuid_generate_time ();
10193  ;
10194  return 0;
10195}
10196_ACEOF
10197if ac_fn_c_try_link "$LINENO"; then :
10198  ac_cv_lib_uuid_uuid_generate_time=yes
10199else
10200  ac_cv_lib_uuid_uuid_generate_time=no
10201fi
10202rm -f core conftest.err conftest.$ac_objext \
10203    conftest$ac_exeext conftest.$ac_ext
10204LIBS=$ac_check_lib_save_LIBS
10205fi
10206{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate_time" >&5
10207$as_echo "$ac_cv_lib_uuid_uuid_generate_time" >&6; }
10208if test "x$ac_cv_lib_uuid_uuid_generate_time" = xyes; then :
10209  cat >>confdefs.h <<_ACEOF
10210#define HAVE_LIBUUID 1
10211_ACEOF
10212
10213  LIBS="-luuid $LIBS"
10214
10215fi
10216
10217LIBS=$save_LIBS
10218
10219# AIX provides support for RFC4122 (uuid) in libc.a starting with AIX 6.1 (anno 2007)
10220# FreeBSD and OpenBSD provides support in libc as well.
10221{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_create" >&5
10222$as_echo_n "checking for uuid_create... " >&6; }
10223cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10224/* end confdefs.h.  */
10225#include <uuid.h>
10226int
10227main ()
10228{
10229
10230#ifndef uuid_create
10231void *x = uuid_create
10232#endif
10233
10234  ;
10235  return 0;
10236}
10237_ACEOF
10238if ac_fn_c_try_compile "$LINENO"; then :
10239
10240$as_echo "#define HAVE_UUID_CREATE 1" >>confdefs.h
10241
10242   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10243$as_echo "yes" >&6; }
10244else
10245  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10246$as_echo "no" >&6; }
10247
10248fi
10249rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10250
10251# Little-endian FreeBSD, OpenBSD and NetBSD needs encoding into an octet
10252# stream in big-endian byte-order
10253{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_enc_be" >&5
10254$as_echo_n "checking for uuid_enc_be... " >&6; }
10255cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10256/* end confdefs.h.  */
10257#include <uuid.h>
10258int
10259main ()
10260{
10261
10262#ifndef uuid_enc_be
10263void *x = uuid_enc_be
10264#endif
10265
10266  ;
10267  return 0;
10268}
10269_ACEOF
10270if ac_fn_c_try_compile "$LINENO"; then :
10271
10272$as_echo "#define HAVE_UUID_ENC_BE 1" >>confdefs.h
10273
10274   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10275$as_echo "yes" >&6; }
10276else
10277  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10278$as_echo "no" >&6; }
10279
10280fi
10281rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10282
10283# 'Real Time' functions on Solaris
10284# posix4 on Solaris 2.6
10285# pthread (first!) on Linux
10286{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
10287$as_echo_n "checking for library containing sem_init... " >&6; }
10288if ${ac_cv_search_sem_init+:} false; then :
10289  $as_echo_n "(cached) " >&6
10290else
10291  ac_func_search_save_LIBS=$LIBS
10292cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10293/* end confdefs.h.  */
10294
10295/* Override any GCC internal prototype to avoid an error.
10296   Use char because int might match the return type of a GCC
10297   builtin and then its argument prototype would still apply.  */
10298#ifdef __cplusplus
10299extern "C"
10300#endif
10301char sem_init ();
10302int
10303main ()
10304{
10305return sem_init ();
10306  ;
10307  return 0;
10308}
10309_ACEOF
10310for ac_lib in '' pthread rt posix4; do
10311  if test -z "$ac_lib"; then
10312    ac_res="none required"
10313  else
10314    ac_res=-l$ac_lib
10315    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
10316  fi
10317  if ac_fn_c_try_link "$LINENO"; then :
10318  ac_cv_search_sem_init=$ac_res
10319fi
10320rm -f core conftest.err conftest.$ac_objext \
10321    conftest$ac_exeext
10322  if ${ac_cv_search_sem_init+:} false; then :
10323  break
10324fi
10325done
10326if ${ac_cv_search_sem_init+:} false; then :
10327
10328else
10329  ac_cv_search_sem_init=no
10330fi
10331rm conftest.$ac_ext
10332LIBS=$ac_func_search_save_LIBS
10333fi
10334{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
10335$as_echo "$ac_cv_search_sem_init" >&6; }
10336ac_res=$ac_cv_search_sem_init
10337if test "$ac_res" != no; then :
10338  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10339
10340fi
10341
10342
10343# check if we need libintl for locale functions
10344{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5
10345$as_echo_n "checking for textdomain in -lintl... " >&6; }
10346if ${ac_cv_lib_intl_textdomain+:} false; then :
10347  $as_echo_n "(cached) " >&6
10348else
10349  ac_check_lib_save_LIBS=$LIBS
10350LIBS="-lintl  $LIBS"
10351cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10352/* end confdefs.h.  */
10353
10354/* Override any GCC internal prototype to avoid an error.
10355   Use char because int might match the return type of a GCC
10356   builtin and then its argument prototype would still apply.  */
10357#ifdef __cplusplus
10358extern "C"
10359#endif
10360char textdomain ();
10361int
10362main ()
10363{
10364return textdomain ();
10365  ;
10366  return 0;
10367}
10368_ACEOF
10369if ac_fn_c_try_link "$LINENO"; then :
10370  ac_cv_lib_intl_textdomain=yes
10371else
10372  ac_cv_lib_intl_textdomain=no
10373fi
10374rm -f core conftest.err conftest.$ac_objext \
10375    conftest$ac_exeext conftest.$ac_ext
10376LIBS=$ac_check_lib_save_LIBS
10377fi
10378{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5
10379$as_echo "$ac_cv_lib_intl_textdomain" >&6; }
10380if test "x$ac_cv_lib_intl_textdomain" = xyes; then :
10381
10382$as_echo "#define WITH_LIBINTL 1" >>confdefs.h
10383
10384        LIBS="-lintl $LIBS"
10385fi
10386
10387
10388# checks for system dependent C++ extensions support
10389case "$ac_sys_system" in
10390	AIX*)	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5
10391$as_echo_n "checking for genuine AIX C++ extensions support... " >&6; }
10392		cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10393/* end confdefs.h.  */
10394
10395		  #include <load.h>
10396int
10397main ()
10398{
10399loadAndInit("", 0, "")
10400  ;
10401  return 0;
10402}
10403
10404_ACEOF
10405if ac_fn_c_try_link "$LINENO"; then :
10406
10407
10408$as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h
10409
10410		  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10411$as_echo "yes" >&6; }
10412
10413else
10414
10415		  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10416$as_echo "no" >&6; }
10417
10418fi
10419rm -f core conftest.err conftest.$ac_objext \
10420    conftest$ac_exeext conftest.$ac_ext
10421# BUILD_GNU_TYPE + AIX_BUILDDATE are used to construct the platform_tag
10422# of the AIX system used to build/package Python executable. This tag serves
10423# as a baseline for bdist module packages
10424               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the system builddate" >&5
10425$as_echo_n "checking for the system builddate... " >&6; }
10426               AIX_BUILDDATE=$(lslpp -Lcq bos.mp64 | awk -F:  '{ print $NF }')
10427
10428cat >>confdefs.h <<_ACEOF
10429#define AIX_BUILDDATE $AIX_BUILDDATE
10430_ACEOF
10431
10432               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AIX_BUILDDATE" >&5
10433$as_echo "$AIX_BUILDDATE" >&6; }
10434               ;;
10435	*) ;;
10436esac
10437
10438# check for systems that require aligned memory access
10439{ $as_echo "$as_me:${as_lineno-$LINENO}: checking aligned memory access is required" >&5
10440$as_echo_n "checking aligned memory access is required... " >&6; }
10441if ${ac_cv_aligned_required+:} false; then :
10442  $as_echo_n "(cached) " >&6
10443else
10444  if test "$cross_compiling" = yes; then :
10445  ac_cv_aligned_required=yes
10446else
10447  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10448/* end confdefs.h.  */
10449
10450int main()
10451{
10452    char s[16];
10453    int i, *p1, *p2;
10454    for (i=0; i < 16; i++)
10455        s[i] = i;
10456    p1 = (int*)(s+1);
10457    p2 = (int*)(s+2);
10458    if (*p1 == *p2)
10459        return 1;
10460    return 0;
10461}
10462_ACEOF
10463if ac_fn_c_try_run "$LINENO"; then :
10464  ac_cv_aligned_required=no
10465else
10466  ac_cv_aligned_required=yes
10467fi
10468rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10469  conftest.$ac_objext conftest.beam conftest.$ac_ext
10470fi
10471
10472
10473fi
10474
10475{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_aligned_required" >&5
10476$as_echo "$ac_cv_aligned_required" >&6; }
10477if test "$ac_cv_aligned_required" = yes ; then
10478
10479$as_echo "#define HAVE_ALIGNED_REQUIRED 1" >>confdefs.h
10480
10481fi
10482
10483# str, bytes and memoryview hash algorithm
10484
10485
10486{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-hash-algorithm" >&5
10487$as_echo_n "checking for --with-hash-algorithm... " >&6; }
10488
10489# Check whether --with-hash_algorithm was given.
10490if test "${with_hash_algorithm+set}" = set; then :
10491  withval=$with_hash_algorithm;
10492{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
10493$as_echo "$withval" >&6; }
10494case "$withval" in
10495    siphash24)
10496        $as_echo "#define Py_HASH_ALGORITHM 1" >>confdefs.h
10497
10498        ;;
10499    fnv)
10500        $as_echo "#define Py_HASH_ALGORITHM 2" >>confdefs.h
10501
10502        ;;
10503    *)
10504        as_fn_error $? "unknown hash algorithm '$withval'" "$LINENO" 5
10505        ;;
10506esac
10507
10508else
10509  { $as_echo "$as_me:${as_lineno-$LINENO}: result: default" >&5
10510$as_echo "default" >&6; }
10511fi
10512
10513
10514validate_tzpath() {
10515    # Checks that each element of hte path is an absolute path
10516    if test -z "$1"; then
10517        # Empty string is allowed: it indicates no system TZPATH
10518        return 0
10519    fi
10520
10521    # Bad paths are those that don't start with /
10522        if ( echo $1 | grep '\(^\|:\)\([^/]\|$\)' > /dev/null); then
10523        as_fn_error $? "--with-tzpath must contain only absolute paths, not $1" "$LINENO" 5
10524        return 1;
10525    fi
10526}
10527
10528TZPATH="/usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo"
10529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tzpath" >&5
10530$as_echo_n "checking for --with-tzpath... " >&6; }
10531
10532# Check whether --with-tzpath was given.
10533if test "${with_tzpath+set}" = set; then :
10534  withval=$with_tzpath;
10535case "$withval" in
10536    yes)
10537        as_fn_error $? "--with-tzpath requires a value" "$LINENO" 5
10538        ;;
10539    *)
10540        validate_tzpath "$withval"
10541        TZPATH="$withval"
10542        { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$withval\"" >&5
10543$as_echo "\"$withval\"" >&6; }
10544        ;;
10545esac
10546
10547else
10548  validate_tzpath "$TZPATH"
10549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$TZPATH\"" >&5
10550$as_echo "\"$TZPATH\"" >&6; }
10551fi
10552
10553
10554
10555# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
10556{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5
10557$as_echo_n "checking for t_open in -lnsl... " >&6; }
10558if ${ac_cv_lib_nsl_t_open+:} false; then :
10559  $as_echo_n "(cached) " >&6
10560else
10561  ac_check_lib_save_LIBS=$LIBS
10562LIBS="-lnsl  $LIBS"
10563cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10564/* end confdefs.h.  */
10565
10566/* Override any GCC internal prototype to avoid an error.
10567   Use char because int might match the return type of a GCC
10568   builtin and then its argument prototype would still apply.  */
10569#ifdef __cplusplus
10570extern "C"
10571#endif
10572char t_open ();
10573int
10574main ()
10575{
10576return t_open ();
10577  ;
10578  return 0;
10579}
10580_ACEOF
10581if ac_fn_c_try_link "$LINENO"; then :
10582  ac_cv_lib_nsl_t_open=yes
10583else
10584  ac_cv_lib_nsl_t_open=no
10585fi
10586rm -f core conftest.err conftest.$ac_objext \
10587    conftest$ac_exeext conftest.$ac_ext
10588LIBS=$ac_check_lib_save_LIBS
10589fi
10590{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5
10591$as_echo "$ac_cv_lib_nsl_t_open" >&6; }
10592if test "x$ac_cv_lib_nsl_t_open" = xyes; then :
10593  LIBS="-lnsl $LIBS"
10594fi
10595 # SVR4
10596{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
10597$as_echo_n "checking for socket in -lsocket... " >&6; }
10598if ${ac_cv_lib_socket_socket+:} false; then :
10599  $as_echo_n "(cached) " >&6
10600else
10601  ac_check_lib_save_LIBS=$LIBS
10602LIBS="-lsocket $LIBS $LIBS"
10603cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10604/* end confdefs.h.  */
10605
10606/* Override any GCC internal prototype to avoid an error.
10607   Use char because int might match the return type of a GCC
10608   builtin and then its argument prototype would still apply.  */
10609#ifdef __cplusplus
10610extern "C"
10611#endif
10612char socket ();
10613int
10614main ()
10615{
10616return socket ();
10617  ;
10618  return 0;
10619}
10620_ACEOF
10621if ac_fn_c_try_link "$LINENO"; then :
10622  ac_cv_lib_socket_socket=yes
10623else
10624  ac_cv_lib_socket_socket=no
10625fi
10626rm -f core conftest.err conftest.$ac_objext \
10627    conftest$ac_exeext conftest.$ac_ext
10628LIBS=$ac_check_lib_save_LIBS
10629fi
10630{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
10631$as_echo "$ac_cv_lib_socket_socket" >&6; }
10632if test "x$ac_cv_lib_socket_socket" = xyes; then :
10633  LIBS="-lsocket $LIBS"
10634fi
10635 # SVR4 sockets
10636
10637{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5
10638$as_echo_n "checking for --with-libs... " >&6; }
10639
10640# Check whether --with-libs was given.
10641if test "${with_libs+set}" = set; then :
10642  withval=$with_libs;
10643{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
10644$as_echo "$withval" >&6; }
10645LIBS="$withval $LIBS"
10646
10647else
10648  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10649$as_echo "no" >&6; }
10650fi
10651
10652
10653
10654
10655
10656
10657
10658
10659
10660if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
10661	if test -n "$ac_tool_prefix"; then
10662  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
10663set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
10664{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10665$as_echo_n "checking for $ac_word... " >&6; }
10666if ${ac_cv_path_PKG_CONFIG+:} false; then :
10667  $as_echo_n "(cached) " >&6
10668else
10669  case $PKG_CONFIG in
10670  [\\/]* | ?:[\\/]*)
10671  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10672  ;;
10673  *)
10674  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10675for as_dir in $PATH
10676do
10677  IFS=$as_save_IFS
10678  test -z "$as_dir" && as_dir=.
10679    for ac_exec_ext in '' $ac_executable_extensions; do
10680  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10681    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10682    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10683    break 2
10684  fi
10685done
10686  done
10687IFS=$as_save_IFS
10688
10689  ;;
10690esac
10691fi
10692PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10693if test -n "$PKG_CONFIG"; then
10694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10695$as_echo "$PKG_CONFIG" >&6; }
10696else
10697  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10698$as_echo "no" >&6; }
10699fi
10700
10701
10702fi
10703if test -z "$ac_cv_path_PKG_CONFIG"; then
10704  ac_pt_PKG_CONFIG=$PKG_CONFIG
10705  # Extract the first word of "pkg-config", so it can be a program name with args.
10706set dummy pkg-config; ac_word=$2
10707{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10708$as_echo_n "checking for $ac_word... " >&6; }
10709if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
10710  $as_echo_n "(cached) " >&6
10711else
10712  case $ac_pt_PKG_CONFIG in
10713  [\\/]* | ?:[\\/]*)
10714  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
10715  ;;
10716  *)
10717  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10718for as_dir in $PATH
10719do
10720  IFS=$as_save_IFS
10721  test -z "$as_dir" && as_dir=.
10722    for ac_exec_ext in '' $ac_executable_extensions; do
10723  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10724    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10725    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10726    break 2
10727  fi
10728done
10729  done
10730IFS=$as_save_IFS
10731
10732  ;;
10733esac
10734fi
10735ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
10736if test -n "$ac_pt_PKG_CONFIG"; then
10737  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
10738$as_echo "$ac_pt_PKG_CONFIG" >&6; }
10739else
10740  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10741$as_echo "no" >&6; }
10742fi
10743
10744  if test "x$ac_pt_PKG_CONFIG" = x; then
10745    PKG_CONFIG=""
10746  else
10747    case $cross_compiling:$ac_tool_warned in
10748yes:)
10749{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10750$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10751ac_tool_warned=yes ;;
10752esac
10753    PKG_CONFIG=$ac_pt_PKG_CONFIG
10754  fi
10755else
10756  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
10757fi
10758
10759fi
10760if test -n "$PKG_CONFIG"; then
10761	_pkg_min_version=0.9.0
10762	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
10763$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
10764	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
10765		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10766$as_echo "yes" >&6; }
10767	else
10768		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10769$as_echo "no" >&6; }
10770		PKG_CONFIG=""
10771	fi
10772fi
10773
10774# Check for use of the system expat library
10775{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5
10776$as_echo_n "checking for --with-system-expat... " >&6; }
10777
10778# Check whether --with-system_expat was given.
10779if test "${with_system_expat+set}" = set; then :
10780  withval=$with_system_expat;
10781else
10782  with_system_expat="no"
10783fi
10784
10785
10786{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5
10787$as_echo "$with_system_expat" >&6; }
10788
10789# Check for use of the system libffi library
10790{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5
10791$as_echo_n "checking for --with-system-ffi... " >&6; }
10792
10793# Check whether --with-system_ffi was given.
10794if test "${with_system_ffi+set}" = set; then :
10795  withval=$with_system_ffi;
10796fi
10797
10798
10799if test "$ac_sys_system" = "Darwin"
10800then
10801    case "$with_system_ffi" in
10802        "")
10803            with_system_ffi="no"
10804            ;;
10805        yes|no)
10806            ;;
10807        *)
10808            as_fn_error $? "--with-system-ffi accepts no arguments" "$LINENO" 5
10809            ;;
10810    esac
10811    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5
10812$as_echo "$with_system_ffi" >&6; }
10813else
10814    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10815$as_echo "yes" >&6; }
10816    if test "$with_system_ffi" != ""
10817    then
10818        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with(out)-system-ffi is ignored on this platform" >&5
10819$as_echo "$as_me: WARNING: --with(out)-system-ffi is ignored on this platform" >&2;}
10820    fi
10821    with_system_ffi="yes"
10822fi
10823
10824if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then
10825    LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`"
10826else
10827    LIBFFI_INCLUDEDIR=""
10828fi
10829
10830
10831# Check for use of the system libmpdec library
10832{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-libmpdec" >&5
10833$as_echo_n "checking for --with-system-libmpdec... " >&6; }
10834
10835# Check whether --with-system_libmpdec was given.
10836if test "${with_system_libmpdec+set}" = set; then :
10837  withval=$with_system_libmpdec;
10838else
10839  with_system_libmpdec="no"
10840fi
10841
10842
10843{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_libmpdec" >&5
10844$as_echo "$with_system_libmpdec" >&6; }
10845
10846# Check whether _decimal should use a coroutine-local or thread-local context
10847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-decimal-contextvar" >&5
10848$as_echo_n "checking for --with-decimal-contextvar... " >&6; }
10849
10850# Check whether --with-decimal_contextvar was given.
10851if test "${with_decimal_contextvar+set}" = set; then :
10852  withval=$with_decimal_contextvar;
10853else
10854  with_decimal_contextvar="yes"
10855fi
10856
10857
10858if test "$with_decimal_contextvar" != "no"
10859then
10860
10861$as_echo "#define WITH_DECIMAL_CONTEXTVAR 1" >>confdefs.h
10862
10863fi
10864
10865{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_decimal_contextvar" >&5
10866$as_echo "$with_decimal_contextvar" >&6; }
10867
10868# Check for support for loadable sqlite extensions
10869{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-loadable-sqlite-extensions" >&5
10870$as_echo_n "checking for --enable-loadable-sqlite-extensions... " >&6; }
10871# Check whether --enable-loadable-sqlite-extensions was given.
10872if test "${enable_loadable_sqlite_extensions+set}" = set; then :
10873  enableval=$enable_loadable_sqlite_extensions;
10874else
10875  enable_loadable_sqlite_extensions="no"
10876fi
10877
10878
10879{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_loadable_sqlite_extensions" >&5
10880$as_echo "$enable_loadable_sqlite_extensions" >&6; }
10881
10882# Check for --with-tcltk-includes=path and --with-tcltk-libs=path
10883
10884
10885{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-includes" >&5
10886$as_echo_n "checking for --with-tcltk-includes... " >&6; }
10887
10888# Check whether --with-tcltk-includes was given.
10889if test "${with_tcltk_includes+set}" = set; then :
10890  withval=$with_tcltk_includes;
10891else
10892  with_tcltk_includes="default"
10893fi
10894
10895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_includes" >&5
10896$as_echo "$with_tcltk_includes" >&6; }
10897{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-libs" >&5
10898$as_echo_n "checking for --with-tcltk-libs... " >&6; }
10899
10900# Check whether --with-tcltk-libs was given.
10901if test "${with_tcltk_libs+set}" = set; then :
10902  withval=$with_tcltk_libs;
10903else
10904  with_tcltk_libs="default"
10905fi
10906
10907{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_libs" >&5
10908$as_echo "$with_tcltk_libs" >&6; }
10909if test "x$with_tcltk_includes" = xdefault || test "x$with_tcltk_libs" = xdefault
10910then
10911  if test "x$with_tcltk_includes" != "x$with_tcltk_libs"
10912  then
10913    as_fn_error $? "use both --with-tcltk-includes='...' and --with-tcltk-libs='...' or neither" "$LINENO" 5
10914  fi
10915  if test -n "$PKG_CONFIG" && "$PKG_CONFIG" --exists tcl tk; then
10916    TCLTK_INCLUDES="`"$PKG_CONFIG" tcl tk --cflags-only-I 2>/dev/null`"
10917    TCLTK_LIBS="`"$PKG_CONFIG" tcl tk --libs 2>/dev/null`"
10918  else
10919    TCLTK_INCLUDES=""
10920    TCLTK_LIBS=""
10921  fi
10922else
10923  TCLTK_INCLUDES="$with_tcltk_includes"
10924  TCLTK_LIBS="$with_tcltk_libs"
10925fi
10926
10927# Check for --with-dbmliborder
10928{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5
10929$as_echo_n "checking for --with-dbmliborder... " >&6; }
10930
10931# Check whether --with-dbmliborder was given.
10932if test "${with_dbmliborder+set}" = set; then :
10933  withval=$with_dbmliborder;
10934if test x$with_dbmliborder = xyes
10935then
10936as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5
10937else
10938  for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do
10939    if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb
10940    then
10941      as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5
10942    fi
10943  done
10944fi
10945fi
10946
10947{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5
10948$as_echo "$with_dbmliborder" >&6; }
10949
10950# Templates for things AC_DEFINEd more than once.
10951# For a single AC_DEFINE, no template is needed.
10952
10953
10954if test "$ac_cv_pthread_is_default" = yes
10955then
10956    # Defining _REENTRANT on system with POSIX threads should not hurt.
10957    $as_echo "#define _REENTRANT 1" >>confdefs.h
10958
10959    posix_threads=yes
10960    if test "$ac_sys_system" = "SunOS"; then
10961        CFLAGS="$CFLAGS -D_REENTRANT"
10962    fi
10963elif test "$ac_cv_kpthread" = "yes"
10964then
10965    CC="$CC -Kpthread"
10966    if test "$ac_cv_cxx_thread" = "yes"; then
10967        CXX="$CXX -Kpthread"
10968    fi
10969    posix_threads=yes
10970elif test "$ac_cv_kthread" = "yes"
10971then
10972    CC="$CC -Kthread"
10973    if test "$ac_cv_cxx_thread" = "yes"; then
10974        CXX="$CXX -Kthread"
10975    fi
10976    posix_threads=yes
10977elif test "$ac_cv_pthread" = "yes"
10978then
10979    CC="$CC -pthread"
10980    if test "$ac_cv_cxx_thread" = "yes"; then
10981        CXX="$CXX -pthread"
10982    fi
10983    posix_threads=yes
10984else
10985    if test ! -z "$withval" -a -d "$withval"
10986    then LDFLAGS="$LDFLAGS -L$withval"
10987    fi
10988
10989    # According to the POSIX spec, a pthreads implementation must
10990    # define _POSIX_THREADS in unistd.h. Some apparently don't
10991    # (e.g. gnu pth with pthread emulation)
10992    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5
10993$as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; }
10994    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10995/* end confdefs.h.  */
10996
10997#include <unistd.h>
10998#ifdef _POSIX_THREADS
10999yes
11000#endif
11001
11002_ACEOF
11003if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11004  $EGREP "yes" >/dev/null 2>&1; then :
11005  unistd_defines_pthreads=yes
11006else
11007  unistd_defines_pthreads=no
11008fi
11009rm -f conftest*
11010
11011    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5
11012$as_echo "$unistd_defines_pthreads" >&6; }
11013
11014    $as_echo "#define _REENTRANT 1" >>confdefs.h
11015
11016    # Just looking for pthread_create in libpthread is not enough:
11017    # on HP/UX, pthread.h renames pthread_create to a different symbol name.
11018    # So we really have to include pthread.h, and then link.
11019    _libs=$LIBS
11020    LIBS="$LIBS -lpthread"
11021    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
11022$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
11023    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11024/* end confdefs.h.  */
11025
11026#include <stdio.h>
11027#include <pthread.h>
11028
11029void * start_routine (void *arg) { exit (0); }
11030int
11031main ()
11032{
11033
11034pthread_create (NULL, NULL, start_routine, NULL)
11035  ;
11036  return 0;
11037}
11038_ACEOF
11039if ac_fn_c_try_link "$LINENO"; then :
11040
11041    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11042$as_echo "yes" >&6; }
11043    posix_threads=yes
11044
11045else
11046
11047    LIBS=$_libs
11048    ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach"
11049if test "x$ac_cv_func_pthread_detach" = xyes; then :
11050
11051    posix_threads=yes
11052
11053else
11054
11055    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5
11056$as_echo_n "checking for pthread_create in -lpthreads... " >&6; }
11057if ${ac_cv_lib_pthreads_pthread_create+:} false; then :
11058  $as_echo_n "(cached) " >&6
11059else
11060  ac_check_lib_save_LIBS=$LIBS
11061LIBS="-lpthreads  $LIBS"
11062cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11063/* end confdefs.h.  */
11064
11065/* Override any GCC internal prototype to avoid an error.
11066   Use char because int might match the return type of a GCC
11067   builtin and then its argument prototype would still apply.  */
11068#ifdef __cplusplus
11069extern "C"
11070#endif
11071char pthread_create ();
11072int
11073main ()
11074{
11075return pthread_create ();
11076  ;
11077  return 0;
11078}
11079_ACEOF
11080if ac_fn_c_try_link "$LINENO"; then :
11081  ac_cv_lib_pthreads_pthread_create=yes
11082else
11083  ac_cv_lib_pthreads_pthread_create=no
11084fi
11085rm -f core conftest.err conftest.$ac_objext \
11086    conftest$ac_exeext conftest.$ac_ext
11087LIBS=$ac_check_lib_save_LIBS
11088fi
11089{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5
11090$as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; }
11091if test "x$ac_cv_lib_pthreads_pthread_create" = xyes; then :
11092
11093    posix_threads=yes
11094    LIBS="$LIBS -lpthreads"
11095
11096else
11097
11098    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5
11099$as_echo_n "checking for pthread_create in -lc_r... " >&6; }
11100if ${ac_cv_lib_c_r_pthread_create+:} false; then :
11101  $as_echo_n "(cached) " >&6
11102else
11103  ac_check_lib_save_LIBS=$LIBS
11104LIBS="-lc_r  $LIBS"
11105cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11106/* end confdefs.h.  */
11107
11108/* Override any GCC internal prototype to avoid an error.
11109   Use char because int might match the return type of a GCC
11110   builtin and then its argument prototype would still apply.  */
11111#ifdef __cplusplus
11112extern "C"
11113#endif
11114char pthread_create ();
11115int
11116main ()
11117{
11118return pthread_create ();
11119  ;
11120  return 0;
11121}
11122_ACEOF
11123if ac_fn_c_try_link "$LINENO"; then :
11124  ac_cv_lib_c_r_pthread_create=yes
11125else
11126  ac_cv_lib_c_r_pthread_create=no
11127fi
11128rm -f core conftest.err conftest.$ac_objext \
11129    conftest$ac_exeext conftest.$ac_ext
11130LIBS=$ac_check_lib_save_LIBS
11131fi
11132{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5
11133$as_echo "$ac_cv_lib_c_r_pthread_create" >&6; }
11134if test "x$ac_cv_lib_c_r_pthread_create" = xyes; then :
11135
11136    posix_threads=yes
11137    LIBS="$LIBS -lc_r"
11138
11139else
11140
11141    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5
11142$as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; }
11143if ${ac_cv_lib_pthread___pthread_create_system+:} false; then :
11144  $as_echo_n "(cached) " >&6
11145else
11146  ac_check_lib_save_LIBS=$LIBS
11147LIBS="-lpthread  $LIBS"
11148cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11149/* end confdefs.h.  */
11150
11151/* Override any GCC internal prototype to avoid an error.
11152   Use char because int might match the return type of a GCC
11153   builtin and then its argument prototype would still apply.  */
11154#ifdef __cplusplus
11155extern "C"
11156#endif
11157char __pthread_create_system ();
11158int
11159main ()
11160{
11161return __pthread_create_system ();
11162  ;
11163  return 0;
11164}
11165_ACEOF
11166if ac_fn_c_try_link "$LINENO"; then :
11167  ac_cv_lib_pthread___pthread_create_system=yes
11168else
11169  ac_cv_lib_pthread___pthread_create_system=no
11170fi
11171rm -f core conftest.err conftest.$ac_objext \
11172    conftest$ac_exeext conftest.$ac_ext
11173LIBS=$ac_check_lib_save_LIBS
11174fi
11175{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5
11176$as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; }
11177if test "x$ac_cv_lib_pthread___pthread_create_system" = xyes; then :
11178
11179    posix_threads=yes
11180    LIBS="$LIBS -lpthread"
11181
11182else
11183
11184    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5
11185$as_echo_n "checking for pthread_create in -lcma... " >&6; }
11186if ${ac_cv_lib_cma_pthread_create+:} false; then :
11187  $as_echo_n "(cached) " >&6
11188else
11189  ac_check_lib_save_LIBS=$LIBS
11190LIBS="-lcma  $LIBS"
11191cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11192/* end confdefs.h.  */
11193
11194/* Override any GCC internal prototype to avoid an error.
11195   Use char because int might match the return type of a GCC
11196   builtin and then its argument prototype would still apply.  */
11197#ifdef __cplusplus
11198extern "C"
11199#endif
11200char pthread_create ();
11201int
11202main ()
11203{
11204return pthread_create ();
11205  ;
11206  return 0;
11207}
11208_ACEOF
11209if ac_fn_c_try_link "$LINENO"; then :
11210  ac_cv_lib_cma_pthread_create=yes
11211else
11212  ac_cv_lib_cma_pthread_create=no
11213fi
11214rm -f core conftest.err conftest.$ac_objext \
11215    conftest$ac_exeext conftest.$ac_ext
11216LIBS=$ac_check_lib_save_LIBS
11217fi
11218{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5
11219$as_echo "$ac_cv_lib_cma_pthread_create" >&6; }
11220if test "x$ac_cv_lib_cma_pthread_create" = xyes; then :
11221
11222    posix_threads=yes
11223    LIBS="$LIBS -lcma"
11224
11225else
11226
11227    as_fn_error $? "could not find pthreads on your system" "$LINENO" 5
11228
11229fi
11230
11231
11232fi
11233
11234fi
11235
11236fi
11237
11238fi
11239
11240fi
11241rm -f core conftest.err conftest.$ac_objext \
11242    conftest$ac_exeext conftest.$ac_ext
11243
11244    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5
11245$as_echo_n "checking for usconfig in -lmpc... " >&6; }
11246if ${ac_cv_lib_mpc_usconfig+:} false; then :
11247  $as_echo_n "(cached) " >&6
11248else
11249  ac_check_lib_save_LIBS=$LIBS
11250LIBS="-lmpc  $LIBS"
11251cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11252/* end confdefs.h.  */
11253
11254/* Override any GCC internal prototype to avoid an error.
11255   Use char because int might match the return type of a GCC
11256   builtin and then its argument prototype would still apply.  */
11257#ifdef __cplusplus
11258extern "C"
11259#endif
11260char usconfig ();
11261int
11262main ()
11263{
11264return usconfig ();
11265  ;
11266  return 0;
11267}
11268_ACEOF
11269if ac_fn_c_try_link "$LINENO"; then :
11270  ac_cv_lib_mpc_usconfig=yes
11271else
11272  ac_cv_lib_mpc_usconfig=no
11273fi
11274rm -f core conftest.err conftest.$ac_objext \
11275    conftest$ac_exeext conftest.$ac_ext
11276LIBS=$ac_check_lib_save_LIBS
11277fi
11278{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5
11279$as_echo "$ac_cv_lib_mpc_usconfig" >&6; }
11280if test "x$ac_cv_lib_mpc_usconfig" = xyes; then :
11281
11282    LIBS="$LIBS -lmpc"
11283
11284fi
11285
11286
11287fi
11288
11289if test "$posix_threads" = "yes"; then
11290      if test "$unistd_defines_pthreads" = "no"; then
11291
11292$as_echo "#define _POSIX_THREADS 1" >>confdefs.h
11293
11294      fi
11295
11296      # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8.
11297      case  $ac_sys_system/$ac_sys_release in
11298      SunOS/5.6)
11299$as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h
11300
11301		       ;;
11302      SunOS/5.8)
11303$as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h
11304
11305		       ;;
11306      AIX/*)
11307$as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h
11308
11309		       ;;
11310      esac
11311
11312      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
11313$as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; }
11314      if ${ac_cv_pthread_system_supported+:} false; then :
11315  $as_echo_n "(cached) " >&6
11316else
11317  if test "$cross_compiling" = yes; then :
11318  ac_cv_pthread_system_supported=no
11319else
11320  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11321/* end confdefs.h.  */
11322
11323      #include <stdio.h>
11324      #include <pthread.h>
11325      void *foo(void *parm) {
11326        return NULL;
11327      }
11328      main() {
11329        pthread_attr_t attr;
11330        pthread_t id;
11331        if (pthread_attr_init(&attr)) return (-1);
11332        if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) return (-1);
11333        if (pthread_create(&id, &attr, foo, NULL)) return (-1);
11334        return (0);
11335      }
11336_ACEOF
11337if ac_fn_c_try_run "$LINENO"; then :
11338  ac_cv_pthread_system_supported=yes
11339else
11340  ac_cv_pthread_system_supported=no
11341fi
11342rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11343  conftest.$ac_objext conftest.beam conftest.$ac_ext
11344fi
11345
11346
11347fi
11348
11349      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5
11350$as_echo "$ac_cv_pthread_system_supported" >&6; }
11351      if test "$ac_cv_pthread_system_supported" = "yes"; then
11352
11353$as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h
11354
11355      fi
11356      for ac_func in pthread_sigmask
11357do :
11358  ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask"
11359if test "x$ac_cv_func_pthread_sigmask" = xyes; then :
11360  cat >>confdefs.h <<_ACEOF
11361#define HAVE_PTHREAD_SIGMASK 1
11362_ACEOF
11363 case $ac_sys_system in
11364        CYGWIN*)
11365
11366$as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h
11367
11368            ;;
11369        esac
11370fi
11371done
11372
11373      for ac_func in pthread_getcpuclockid
11374do :
11375  ac_fn_c_check_func "$LINENO" "pthread_getcpuclockid" "ac_cv_func_pthread_getcpuclockid"
11376if test "x$ac_cv_func_pthread_getcpuclockid" = xyes; then :
11377  cat >>confdefs.h <<_ACEOF
11378#define HAVE_PTHREAD_GETCPUCLOCKID 1
11379_ACEOF
11380
11381fi
11382done
11383
11384fi
11385
11386
11387# Check for enable-ipv6
11388
11389{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5
11390$as_echo_n "checking if --enable-ipv6 is specified... " >&6; }
11391# Check whether --enable-ipv6 was given.
11392if test "${enable_ipv6+set}" = set; then :
11393  enableval=$enable_ipv6;  case "$enableval" in
11394  no)
11395       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11396$as_echo "no" >&6; }
11397       ipv6=no
11398       ;;
11399  *)   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11400$as_echo "yes" >&6; }
11401       $as_echo "#define ENABLE_IPV6 1" >>confdefs.h
11402
11403       ipv6=yes
11404       ;;
11405  esac
11406else
11407
11408  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11409/* end confdefs.h.  */
11410 /* AF_INET6 available check */
11411#include <sys/types.h>
11412#include <sys/socket.h>
11413int
11414main ()
11415{
11416int domain = AF_INET6;
11417  ;
11418  return 0;
11419}
11420_ACEOF
11421if ac_fn_c_try_compile "$LINENO"; then :
11422
11423  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11424$as_echo "yes" >&6; }
11425  ipv6=yes
11426
11427else
11428
11429  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11430$as_echo "no" >&6; }
11431  ipv6=no
11432
11433fi
11434rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11435
11436if test "$ipv6" = "yes"; then
11437	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5
11438$as_echo_n "checking if RFC2553 API is available... " >&6; }
11439	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11440/* end confdefs.h.  */
11441
11442	  #include <sys/types.h>
11443#include <netinet/in.h>
11444int
11445main ()
11446{
11447struct sockaddr_in6 x;
11448			    x.sin6_scope_id;
11449  ;
11450  return 0;
11451}
11452
11453_ACEOF
11454if ac_fn_c_try_compile "$LINENO"; then :
11455
11456	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11457$as_echo "yes" >&6; }
11458	  ipv6=yes
11459
11460else
11461
11462	  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11463$as_echo "no" >&6; }
11464	  ipv6=no
11465
11466fi
11467rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11468fi
11469
11470if test "$ipv6" = "yes"; then
11471	$as_echo "#define ENABLE_IPV6 1" >>confdefs.h
11472
11473fi
11474
11475fi
11476
11477
11478ipv6type=unknown
11479ipv6lib=none
11480ipv6trylibc=no
11481
11482if test "$ipv6" = "yes"; then
11483	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5
11484$as_echo_n "checking ipv6 stack type... " >&6; }
11485	for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
11486	do
11487		case $i in
11488		inria)
11489						cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11490/* end confdefs.h.  */
11491
11492#include <netinet/in.h>
11493#ifdef IPV6_INRIA_VERSION
11494yes
11495#endif
11496_ACEOF
11497if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11498  $EGREP "yes" >/dev/null 2>&1; then :
11499  ipv6type=$i
11500fi
11501rm -f conftest*
11502
11503			;;
11504		kame)
11505						cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11506/* end confdefs.h.  */
11507
11508#include <netinet/in.h>
11509#ifdef __KAME__
11510yes
11511#endif
11512_ACEOF
11513if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11514  $EGREP "yes" >/dev/null 2>&1; then :
11515  ipv6type=$i;
11516				ipv6lib=inet6
11517				ipv6libdir=/usr/local/v6/lib
11518				ipv6trylibc=yes
11519fi
11520rm -f conftest*
11521
11522			;;
11523		linux-glibc)
11524						cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11525/* end confdefs.h.  */
11526
11527#include <features.h>
11528#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
11529yes
11530#endif
11531_ACEOF
11532if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11533  $EGREP "yes" >/dev/null 2>&1; then :
11534  ipv6type=$i;
11535				ipv6trylibc=yes
11536fi
11537rm -f conftest*
11538
11539			;;
11540		linux-inet6)
11541						if test -d /usr/inet6; then
11542				ipv6type=$i
11543				ipv6lib=inet6
11544				ipv6libdir=/usr/inet6/lib
11545				BASECFLAGS="-I/usr/inet6/include $BASECFLAGS"
11546			fi
11547			;;
11548		solaris)
11549			if test -f /etc/netconfig; then
11550                          if $GREP -q tcp6 /etc/netconfig; then
11551				ipv6type=$i
11552				ipv6trylibc=yes
11553                          fi
11554                        fi
11555			;;
11556		toshiba)
11557			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11558/* end confdefs.h.  */
11559
11560#include <sys/param.h>
11561#ifdef _TOSHIBA_INET6
11562yes
11563#endif
11564_ACEOF
11565if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11566  $EGREP "yes" >/dev/null 2>&1; then :
11567  ipv6type=$i;
11568				ipv6lib=inet6;
11569				ipv6libdir=/usr/local/v6/lib
11570fi
11571rm -f conftest*
11572
11573			;;
11574		v6d)
11575			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11576/* end confdefs.h.  */
11577
11578#include </usr/local/v6/include/sys/v6config.h>
11579#ifdef __V6D__
11580yes
11581#endif
11582_ACEOF
11583if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11584  $EGREP "yes" >/dev/null 2>&1; then :
11585  ipv6type=$i;
11586				ipv6lib=v6;
11587				ipv6libdir=/usr/local/v6/lib;
11588				BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS"
11589fi
11590rm -f conftest*
11591
11592			;;
11593		zeta)
11594			cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11595/* end confdefs.h.  */
11596
11597#include <sys/param.h>
11598#ifdef _ZETA_MINAMI_INET6
11599yes
11600#endif
11601_ACEOF
11602if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11603  $EGREP "yes" >/dev/null 2>&1; then :
11604  ipv6type=$i;
11605				ipv6lib=inet6;
11606				ipv6libdir=/usr/local/v6/lib
11607fi
11608rm -f conftest*
11609
11610			;;
11611		esac
11612		if test "$ipv6type" != "unknown"; then
11613			break
11614		fi
11615	done
11616	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5
11617$as_echo "$ipv6type" >&6; }
11618fi
11619
11620if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
11621	if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
11622		LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
11623		echo "using lib$ipv6lib"
11624	else
11625		if test $ipv6trylibc = "yes"; then
11626			echo "using libc"
11627		else
11628			echo 'Fatal: no $ipv6lib library found.  cannot continue.'
11629			echo "You need to fetch lib$ipv6lib.a from appropriate"
11630			echo 'ipv6 kit and compile beforehand.'
11631			exit 1
11632		fi
11633	fi
11634fi
11635
11636{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAN_RAW_FD_FRAMES" >&5
11637$as_echo_n "checking for CAN_RAW_FD_FRAMES... " >&6; }
11638cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11639/* end confdefs.h.  */
11640 /* CAN_RAW_FD_FRAMES available check */
11641#include <linux/can/raw.h>
11642int
11643main ()
11644{
11645int can_raw_fd_frames = CAN_RAW_FD_FRAMES;
11646  ;
11647  return 0;
11648}
11649_ACEOF
11650if ac_fn_c_try_compile "$LINENO"; then :
11651
11652
11653$as_echo "#define HAVE_LINUX_CAN_RAW_FD_FRAMES 1" >>confdefs.h
11654
11655  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11656$as_echo "yes" >&6; }
11657
11658else
11659
11660  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11661$as_echo "no" >&6; }
11662
11663fi
11664rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11665
11666{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAN_RAW_JOIN_FILTERS" >&5
11667$as_echo_n "checking for CAN_RAW_JOIN_FILTERS... " >&6; }
11668cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11669/* end confdefs.h.  */
11670
11671#include <linux/can/raw.h>
11672int
11673main ()
11674{
11675int can_raw_join_filters = CAN_RAW_JOIN_FILTERS;
11676  ;
11677  return 0;
11678}
11679_ACEOF
11680if ac_fn_c_try_compile "$LINENO"; then :
11681
11682
11683$as_echo "#define HAVE_LINUX_CAN_RAW_JOIN_FILTERS 1" >>confdefs.h
11684
11685  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11686$as_echo "yes" >&6; }
11687
11688else
11689
11690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11691$as_echo "no" >&6; }
11692
11693fi
11694rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11695
11696# Check for --with-doc-strings
11697{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5
11698$as_echo_n "checking for --with-doc-strings... " >&6; }
11699
11700# Check whether --with-doc-strings was given.
11701if test "${with_doc_strings+set}" = set; then :
11702  withval=$with_doc_strings;
11703fi
11704
11705
11706if test -z "$with_doc_strings"
11707then with_doc_strings="yes"
11708fi
11709if test "$with_doc_strings" != "no"
11710then
11711
11712$as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h
11713
11714fi
11715{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5
11716$as_echo "$with_doc_strings" >&6; }
11717
11718# Check for Python-specific malloc support
11719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5
11720$as_echo_n "checking for --with-pymalloc... " >&6; }
11721
11722# Check whether --with-pymalloc was given.
11723if test "${with_pymalloc+set}" = set; then :
11724  withval=$with_pymalloc;
11725fi
11726
11727
11728if test -z "$with_pymalloc"
11729then
11730    with_pymalloc="yes"
11731fi
11732if test "$with_pymalloc" != "no"
11733then
11734
11735$as_echo "#define WITH_PYMALLOC 1" >>confdefs.h
11736
11737fi
11738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5
11739$as_echo "$with_pymalloc" >&6; }
11740
11741# Check for --with-c-locale-coercion
11742{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-c-locale-coercion" >&5
11743$as_echo_n "checking for --with-c-locale-coercion... " >&6; }
11744
11745# Check whether --with-c-locale-coercion was given.
11746if test "${with_c_locale_coercion+set}" = set; then :
11747  withval=$with_c_locale_coercion;
11748fi
11749
11750
11751if test -z "$with_c_locale_coercion"
11752then
11753    with_c_locale_coercion="yes"
11754fi
11755if test "$with_c_locale_coercion" != "no"
11756then
11757
11758$as_echo "#define PY_COERCE_C_LOCALE 1" >>confdefs.h
11759
11760fi
11761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_c_locale_coercion" >&5
11762$as_echo "$with_c_locale_coercion" >&6; }
11763
11764# Check for Valgrind support
11765{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5
11766$as_echo_n "checking for --with-valgrind... " >&6; }
11767
11768# Check whether --with-valgrind was given.
11769if test "${with_valgrind+set}" = set; then :
11770  withval=$with_valgrind;
11771else
11772  with_valgrind=no
11773fi
11774
11775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5
11776$as_echo "$with_valgrind" >&6; }
11777if test "$with_valgrind" != no; then
11778    ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default"
11779if test "x$ac_cv_header_valgrind_valgrind_h" = xyes; then :
11780
11781$as_echo "#define WITH_VALGRIND 1" >>confdefs.h
11782
11783else
11784  as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5
11785
11786fi
11787
11788
11789    OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT"
11790fi
11791
11792# Check for DTrace support
11793{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dtrace" >&5
11794$as_echo_n "checking for --with-dtrace... " >&6; }
11795
11796# Check whether --with-dtrace was given.
11797if test "${with_dtrace+set}" = set; then :
11798  withval=$with_dtrace;
11799else
11800  with_dtrace=no
11801fi
11802
11803{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dtrace" >&5
11804$as_echo "$with_dtrace" >&6; }
11805
11806
11807
11808
11809
11810DTRACE=
11811DTRACE_HEADERS=
11812DTRACE_OBJS=
11813
11814if test "$with_dtrace" = "yes"
11815then
11816    # Extract the first word of "dtrace", so it can be a program name with args.
11817set dummy dtrace; ac_word=$2
11818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11819$as_echo_n "checking for $ac_word... " >&6; }
11820if ${ac_cv_path_DTRACE+:} false; then :
11821  $as_echo_n "(cached) " >&6
11822else
11823  case $DTRACE in
11824  [\\/]* | ?:[\\/]*)
11825  ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
11826  ;;
11827  *)
11828  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11829for as_dir in $PATH
11830do
11831  IFS=$as_save_IFS
11832  test -z "$as_dir" && as_dir=.
11833    for ac_exec_ext in '' $ac_executable_extensions; do
11834  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11835    ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext"
11836    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11837    break 2
11838  fi
11839done
11840  done
11841IFS=$as_save_IFS
11842
11843  test -z "$ac_cv_path_DTRACE" && ac_cv_path_DTRACE="not found"
11844  ;;
11845esac
11846fi
11847DTRACE=$ac_cv_path_DTRACE
11848if test -n "$DTRACE"; then
11849  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
11850$as_echo "$DTRACE" >&6; }
11851else
11852  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11853$as_echo "no" >&6; }
11854fi
11855
11856
11857    if test "$DTRACE" = "not found"; then
11858        as_fn_error $? "dtrace command not found on \$PATH" "$LINENO" 5
11859    fi
11860
11861$as_echo "#define WITH_DTRACE 1" >>confdefs.h
11862
11863    DTRACE_HEADERS="Include/pydtrace_probes.h"
11864
11865    # On OS X, DTrace providers do not need to be explicitly compiled and
11866    # linked into the binary. Correspondingly, dtrace(1) is missing the ELF
11867    # generation flag '-G'. We check for presence of this flag, rather than
11868    # hardcoding support by OS, in the interest of robustness.
11869    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether DTrace probes require linking" >&5
11870$as_echo_n "checking whether DTrace probes require linking... " >&6; }
11871if ${ac_cv_dtrace_link+:} false; then :
11872  $as_echo_n "(cached) " >&6
11873else
11874              ac_cv_dtrace_link=no
11875            echo 'BEGIN{}' > conftest.d
11876            "$DTRACE" $DFLAGS -G -s conftest.d -o conftest.o > /dev/null 2>&1 && \
11877                ac_cv_dtrace_link=yes
11878
11879fi
11880{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_dtrace_link" >&5
11881$as_echo "$ac_cv_dtrace_link" >&6; }
11882    if test "$ac_cv_dtrace_link" = "yes"; then
11883        DTRACE_OBJS="Python/pydtrace.o"
11884    fi
11885fi
11886
11887# -I${DLINCLDIR} is added to the compile rule for importdl.o
11888
11889DLINCLDIR=.
11890
11891# the dlopen() function means we might want to use dynload_shlib.o. some
11892# platforms have dlopen(), but don't want to use it.
11893for ac_func in dlopen
11894do :
11895  ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
11896if test "x$ac_cv_func_dlopen" = xyes; then :
11897  cat >>confdefs.h <<_ACEOF
11898#define HAVE_DLOPEN 1
11899_ACEOF
11900
11901fi
11902done
11903
11904
11905# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
11906# loading of modules.
11907
11908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5
11909$as_echo_n "checking DYNLOADFILE... " >&6; }
11910if test -z "$DYNLOADFILE"
11911then
11912	case $ac_sys_system/$ac_sys_release in
11913	hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
11914	*)
11915	# use dynload_shlib.c and dlopen() if we have it; otherwise stub
11916	# out any dynamic loading
11917	if test "$ac_cv_func_dlopen" = yes
11918	then DYNLOADFILE="dynload_shlib.o"
11919	else DYNLOADFILE="dynload_stub.o"
11920	fi
11921	;;
11922	esac
11923fi
11924{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5
11925$as_echo "$DYNLOADFILE" >&6; }
11926if test "$DYNLOADFILE" != "dynload_stub.o"
11927then
11928
11929$as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h
11930
11931fi
11932
11933# MACHDEP_OBJS can be set to platform-specific object files needed by Python
11934
11935
11936{ $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5
11937$as_echo_n "checking MACHDEP_OBJS... " >&6; }
11938if test -z "$MACHDEP_OBJS"
11939then
11940	MACHDEP_OBJS=$extra_machdep_objs
11941else
11942	MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
11943fi
11944if test -z "$MACHDEP_OBJS"; then
11945  { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
11946$as_echo "none" >&6; }
11947else
11948  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP_OBJS" >&5
11949$as_echo "$MACHDEP_OBJS" >&6; }
11950fi
11951
11952# checks for library functions
11953for ac_func in alarm accept4 setitimer getitimer bind_textdomain_codeset chown \
11954 clock confstr close_range copy_file_range ctermid dup3 execv explicit_bzero \
11955 explicit_memset faccessat fchmod fchmodat fchown fchownat \
11956 fdwalk fexecve fdopendir fork fpathconf fstatat ftime ftruncate futimesat \
11957 futimens futimes gai_strerror getentropy \
11958 getgrgid_r getgrnam_r \
11959 getgrouplist getgroups getlogin getloadavg getpeername getpgid getpid \
11960 getpriority getresuid getresgid getpwent getpwnam_r getpwuid_r getspnam getspent getsid getwd \
11961 if_nameindex \
11962 initgroups kill killpg lchown lockf linkat lstat lutimes mmap \
11963 memrchr mbrtowc mkdirat mkfifo \
11964 madvise mkfifoat mknod mknodat mktime mremap nice openat pathconf pause pipe2 plock poll \
11965 posix_fallocate posix_fadvise posix_spawn posix_spawnp pread preadv preadv2 \
11966 pthread_condattr_setclock pthread_init pthread_kill pwrite pwritev pwritev2 \
11967 readlink readlinkat readv realpath renameat \
11968 sem_open sem_timedwait sem_clockwait sem_getvalue sem_unlink sendfile setegid seteuid \
11969 setgid sethostname \
11970 setlocale setregid setreuid setresuid setresgid setsid setpgid setpgrp setpriority setuid setvbuf \
11971 sched_get_priority_max sched_setaffinity sched_setscheduler sched_setparam \
11972 sched_rr_get_interval \
11973 sigaction sigaltstack sigfillset siginterrupt sigpending sigrelse \
11974 sigtimedwait sigwait sigwaitinfo snprintf splice strftime strlcpy strsignal symlinkat sync \
11975 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
11976 truncate uname unlinkat utimensat utimes vfork waitid waitpid wait3 wait4 \
11977 wcscoll wcsftime wcsxfrm wmemcmp writev _getpty rtpSpawn
11978do :
11979  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11980ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11981if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
11982  cat >>confdefs.h <<_ACEOF
11983#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11984_ACEOF
11985
11986fi
11987done
11988
11989
11990# Force lchmod off for Linux. Linux disallows changing the mode of symbolic
11991# links. Some libc implementations have a stub lchmod implementation that always
11992# returns an error.
11993if test "$MACHDEP" != linux; then
11994  for ac_func in lchmod
11995do :
11996  ac_fn_c_check_func "$LINENO" "lchmod" "ac_cv_func_lchmod"
11997if test "x$ac_cv_func_lchmod" = xyes; then :
11998  cat >>confdefs.h <<_ACEOF
11999#define HAVE_LCHMOD 1
12000_ACEOF
12001
12002fi
12003done
12004
12005fi
12006
12007ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
12008       #include <dirent.h>
12009"
12010if test "x$ac_cv_have_decl_dirfd" = xyes; then :
12011
12012$as_echo "#define HAVE_DIRFD 1" >>confdefs.h
12013
12014fi
12015
12016
12017# For some functions, having a definition is not sufficient, since
12018# we want to take their address.
12019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5
12020$as_echo_n "checking for chroot... " >&6; }
12021cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12022/* end confdefs.h.  */
12023#include <unistd.h>
12024int
12025main ()
12026{
12027void *x=chroot
12028  ;
12029  return 0;
12030}
12031_ACEOF
12032if ac_fn_c_try_compile "$LINENO"; then :
12033
12034$as_echo "#define HAVE_CHROOT 1" >>confdefs.h
12035
12036   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12037$as_echo "yes" >&6; }
12038else
12039  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12040$as_echo "no" >&6; }
12041
12042fi
12043rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12044{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5
12045$as_echo_n "checking for link... " >&6; }
12046cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12047/* end confdefs.h.  */
12048#include <unistd.h>
12049int
12050main ()
12051{
12052void *x=link
12053  ;
12054  return 0;
12055}
12056_ACEOF
12057if ac_fn_c_try_compile "$LINENO"; then :
12058
12059$as_echo "#define HAVE_LINK 1" >>confdefs.h
12060
12061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12062$as_echo "yes" >&6; }
12063else
12064  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12065$as_echo "no" >&6; }
12066
12067fi
12068rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12069{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5
12070$as_echo_n "checking for symlink... " >&6; }
12071cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12072/* end confdefs.h.  */
12073#include <unistd.h>
12074int
12075main ()
12076{
12077void *x=symlink
12078  ;
12079  return 0;
12080}
12081_ACEOF
12082if ac_fn_c_try_compile "$LINENO"; then :
12083
12084$as_echo "#define HAVE_SYMLINK 1" >>confdefs.h
12085
12086   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12087$as_echo "yes" >&6; }
12088else
12089  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12090$as_echo "no" >&6; }
12091
12092fi
12093rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12094{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5
12095$as_echo_n "checking for fchdir... " >&6; }
12096cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12097/* end confdefs.h.  */
12098#include <unistd.h>
12099int
12100main ()
12101{
12102void *x=fchdir
12103  ;
12104  return 0;
12105}
12106_ACEOF
12107if ac_fn_c_try_compile "$LINENO"; then :
12108
12109$as_echo "#define HAVE_FCHDIR 1" >>confdefs.h
12110
12111   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12112$as_echo "yes" >&6; }
12113else
12114  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12115$as_echo "no" >&6; }
12116
12117fi
12118rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12119{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5
12120$as_echo_n "checking for fsync... " >&6; }
12121cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12122/* end confdefs.h.  */
12123#include <unistd.h>
12124int
12125main ()
12126{
12127void *x=fsync
12128  ;
12129  return 0;
12130}
12131_ACEOF
12132if ac_fn_c_try_compile "$LINENO"; then :
12133
12134$as_echo "#define HAVE_FSYNC 1" >>confdefs.h
12135
12136   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12137$as_echo "yes" >&6; }
12138else
12139  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12140$as_echo "no" >&6; }
12141
12142fi
12143rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12144{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5
12145$as_echo_n "checking for fdatasync... " >&6; }
12146cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12147/* end confdefs.h.  */
12148#include <unistd.h>
12149int
12150main ()
12151{
12152void *x=fdatasync
12153  ;
12154  return 0;
12155}
12156_ACEOF
12157if ac_fn_c_try_compile "$LINENO"; then :
12158
12159$as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h
12160
12161   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12162$as_echo "yes" >&6; }
12163else
12164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12165$as_echo "no" >&6; }
12166
12167fi
12168rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12169{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5
12170$as_echo_n "checking for epoll... " >&6; }
12171cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12172/* end confdefs.h.  */
12173#include <sys/epoll.h>
12174int
12175main ()
12176{
12177void *x=epoll_create
12178  ;
12179  return 0;
12180}
12181_ACEOF
12182if ac_fn_c_try_compile "$LINENO"; then :
12183
12184$as_echo "#define HAVE_EPOLL 1" >>confdefs.h
12185
12186   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12187$as_echo "yes" >&6; }
12188else
12189  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12190$as_echo "no" >&6; }
12191
12192fi
12193rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12194{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll_create1" >&5
12195$as_echo_n "checking for epoll_create1... " >&6; }
12196cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12197/* end confdefs.h.  */
12198#include <sys/epoll.h>
12199int
12200main ()
12201{
12202void *x=epoll_create1
12203  ;
12204  return 0;
12205}
12206_ACEOF
12207if ac_fn_c_try_compile "$LINENO"; then :
12208
12209$as_echo "#define HAVE_EPOLL_CREATE1 1" >>confdefs.h
12210
12211   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12212$as_echo "yes" >&6; }
12213else
12214  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12215$as_echo "no" >&6; }
12216
12217fi
12218rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12219{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5
12220$as_echo_n "checking for kqueue... " >&6; }
12221cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12222/* end confdefs.h.  */
12223
12224#include <sys/types.h>
12225#include <sys/event.h>
12226
12227int
12228main ()
12229{
12230int x=kqueue()
12231  ;
12232  return 0;
12233}
12234_ACEOF
12235if ac_fn_c_try_compile "$LINENO"; then :
12236
12237$as_echo "#define HAVE_KQUEUE 1" >>confdefs.h
12238
12239   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12240$as_echo "yes" >&6; }
12241else
12242  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12243$as_echo "no" >&6; }
12244
12245fi
12246rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for prlimit" >&5
12248$as_echo_n "checking for prlimit... " >&6; }
12249cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12250/* end confdefs.h.  */
12251
12252#include <sys/time.h>
12253#include <sys/resource.h>
12254
12255int
12256main ()
12257{
12258void *x=prlimit
12259  ;
12260  return 0;
12261}
12262_ACEOF
12263if ac_fn_c_try_compile "$LINENO"; then :
12264
12265$as_echo "#define HAVE_PRLIMIT 1" >>confdefs.h
12266
12267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12268$as_echo "yes" >&6; }
12269else
12270  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12271$as_echo "no" >&6; }
12272
12273fi
12274rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12275{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _dyld_shared_cache_contains_path" >&5
12276$as_echo_n "checking for _dyld_shared_cache_contains_path... " >&6; }
12277cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12278/* end confdefs.h.  */
12279#include <mach-o/dyld.h>
12280int
12281main ()
12282{
12283void *x=_dyld_shared_cache_contains_path
12284  ;
12285  return 0;
12286}
12287_ACEOF
12288if ac_fn_c_try_compile "$LINENO"; then :
12289
12290$as_echo "#define HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH 1" >>confdefs.h
12291
12292   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12293$as_echo "yes" >&6; }
12294else
12295  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12296$as_echo "no" >&6; }
12297
12298fi
12299rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12300
12301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for memfd_create" >&5
12302$as_echo_n "checking for memfd_create... " >&6; }
12303cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12304/* end confdefs.h.  */
12305
12306#ifdef HAVE_SYS_MMAN_H
12307#include <sys/mman.h>
12308#endif
12309#ifdef HAVE_SYS_MEMFD_H
12310#include <sys/memfd.h>
12311#endif
12312
12313int
12314main ()
12315{
12316void *x=memfd_create
12317  ;
12318  return 0;
12319}
12320_ACEOF
12321if ac_fn_c_try_compile "$LINENO"; then :
12322
12323$as_echo "#define HAVE_MEMFD_CREATE 1" >>confdefs.h
12324
12325   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12326$as_echo "yes" >&6; }
12327else
12328  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12329$as_echo "no" >&6; }
12330
12331fi
12332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12333
12334{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for eventfd" >&5
12335$as_echo_n "checking for eventfd... " >&6; }
12336cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12337/* end confdefs.h.  */
12338
12339#ifdef HAVE_SYS_EVENTFD_H
12340#include <sys/eventfd.h>
12341#endif
12342
12343int
12344main ()
12345{
12346int x = eventfd(0, EFD_CLOEXEC)
12347  ;
12348  return 0;
12349}
12350_ACEOF
12351if ac_fn_c_try_compile "$LINENO"; then :
12352
12353$as_echo "#define HAVE_EVENTFD 1" >>confdefs.h
12354
12355   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12356$as_echo "yes" >&6; }
12357else
12358  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12359$as_echo "no" >&6; }
12360
12361fi
12362rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12363
12364# On some systems (eg. FreeBSD 5), we would find a definition of the
12365# functions ctermid_r, setgroups in the library, but no prototype
12366# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
12367# address to avoid compiler warnings and potential miscompilations
12368# because of the missing prototypes.
12369
12370{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5
12371$as_echo_n "checking for ctermid_r... " >&6; }
12372cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12373/* end confdefs.h.  */
12374
12375#include <stdio.h>
12376
12377int
12378main ()
12379{
12380void* p = ctermid_r
12381  ;
12382  return 0;
12383}
12384_ACEOF
12385if ac_fn_c_try_compile "$LINENO"; then :
12386
12387$as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h
12388
12389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12390$as_echo "yes" >&6; }
12391else
12392  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12393$as_echo "no" >&6; }
12394
12395fi
12396rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12397
12398{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5
12399$as_echo_n "checking for flock declaration... " >&6; }
12400if ${ac_cv_flock_decl+:} false; then :
12401  $as_echo_n "(cached) " >&6
12402else
12403  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12404/* end confdefs.h.  */
12405#include <sys/file.h>
12406int
12407main ()
12408{
12409void* p = flock
12410
12411  ;
12412  return 0;
12413}
12414_ACEOF
12415if ac_fn_c_try_compile "$LINENO"; then :
12416  ac_cv_flock_decl=yes
12417else
12418  ac_cv_flock_decl=no
12419
12420fi
12421rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12422
12423fi
12424{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5
12425$as_echo "$ac_cv_flock_decl" >&6; }
12426if test "x${ac_cv_flock_decl}" = xyes; then
12427  for ac_func in flock
12428do :
12429  ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock"
12430if test "x$ac_cv_func_flock" = xyes; then :
12431  cat >>confdefs.h <<_ACEOF
12432#define HAVE_FLOCK 1
12433_ACEOF
12434
12435else
12436  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock in -lbsd" >&5
12437$as_echo_n "checking for flock in -lbsd... " >&6; }
12438if ${ac_cv_lib_bsd_flock+:} false; then :
12439  $as_echo_n "(cached) " >&6
12440else
12441  ac_check_lib_save_LIBS=$LIBS
12442LIBS="-lbsd  $LIBS"
12443cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12444/* end confdefs.h.  */
12445
12446/* Override any GCC internal prototype to avoid an error.
12447   Use char because int might match the return type of a GCC
12448   builtin and then its argument prototype would still apply.  */
12449#ifdef __cplusplus
12450extern "C"
12451#endif
12452char flock ();
12453int
12454main ()
12455{
12456return flock ();
12457  ;
12458  return 0;
12459}
12460_ACEOF
12461if ac_fn_c_try_link "$LINENO"; then :
12462  ac_cv_lib_bsd_flock=yes
12463else
12464  ac_cv_lib_bsd_flock=no
12465fi
12466rm -f core conftest.err conftest.$ac_objext \
12467    conftest$ac_exeext conftest.$ac_ext
12468LIBS=$ac_check_lib_save_LIBS
12469fi
12470{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5
12471$as_echo "$ac_cv_lib_bsd_flock" >&6; }
12472if test "x$ac_cv_lib_bsd_flock" = xyes; then :
12473  $as_echo "#define HAVE_FLOCK 1" >>confdefs.h
12474
12475
12476$as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h
12477
12478
12479fi
12480
12481
12482fi
12483done
12484
12485fi
12486
12487{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5
12488$as_echo_n "checking for getpagesize... " >&6; }
12489cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12490/* end confdefs.h.  */
12491
12492#include <unistd.h>
12493
12494int
12495main ()
12496{
12497void* p = getpagesize
12498  ;
12499  return 0;
12500}
12501_ACEOF
12502if ac_fn_c_try_compile "$LINENO"; then :
12503
12504$as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h
12505
12506   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12507$as_echo "yes" >&6; }
12508else
12509  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12510$as_echo "no" >&6; }
12511
12512fi
12513rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12514
12515{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken unsetenv" >&5
12516$as_echo_n "checking for broken unsetenv... " >&6; }
12517cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12518/* end confdefs.h.  */
12519
12520#include <stdlib.h>
12521
12522int
12523main ()
12524{
12525int res = unsetenv("DUMMY")
12526  ;
12527  return 0;
12528}
12529_ACEOF
12530if ac_fn_c_try_compile "$LINENO"; then :
12531  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12532$as_echo "no" >&6; }
12533else
12534
12535$as_echo "#define HAVE_BROKEN_UNSETENV 1" >>confdefs.h
12536
12537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12538$as_echo "yes" >&6; }
12539
12540fi
12541rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12542
12543for ac_prog in true
12544do
12545  # Extract the first word of "$ac_prog", so it can be a program name with args.
12546set dummy $ac_prog; ac_word=$2
12547{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12548$as_echo_n "checking for $ac_word... " >&6; }
12549if ${ac_cv_prog_TRUE+:} false; then :
12550  $as_echo_n "(cached) " >&6
12551else
12552  if test -n "$TRUE"; then
12553  ac_cv_prog_TRUE="$TRUE" # Let the user override the test.
12554else
12555as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12556for as_dir in $PATH
12557do
12558  IFS=$as_save_IFS
12559  test -z "$as_dir" && as_dir=.
12560    for ac_exec_ext in '' $ac_executable_extensions; do
12561  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12562    ac_cv_prog_TRUE="$ac_prog"
12563    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12564    break 2
12565  fi
12566done
12567  done
12568IFS=$as_save_IFS
12569
12570fi
12571fi
12572TRUE=$ac_cv_prog_TRUE
12573if test -n "$TRUE"; then
12574  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5
12575$as_echo "$TRUE" >&6; }
12576else
12577  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12578$as_echo "no" >&6; }
12579fi
12580
12581
12582  test -n "$TRUE" && break
12583done
12584test -n "$TRUE" || TRUE="/bin/true"
12585
12586
12587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5
12588$as_echo_n "checking for inet_aton in -lc... " >&6; }
12589if ${ac_cv_lib_c_inet_aton+:} false; then :
12590  $as_echo_n "(cached) " >&6
12591else
12592  ac_check_lib_save_LIBS=$LIBS
12593LIBS="-lc  $LIBS"
12594cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12595/* end confdefs.h.  */
12596
12597/* Override any GCC internal prototype to avoid an error.
12598   Use char because int might match the return type of a GCC
12599   builtin and then its argument prototype would still apply.  */
12600#ifdef __cplusplus
12601extern "C"
12602#endif
12603char inet_aton ();
12604int
12605main ()
12606{
12607return inet_aton ();
12608  ;
12609  return 0;
12610}
12611_ACEOF
12612if ac_fn_c_try_link "$LINENO"; then :
12613  ac_cv_lib_c_inet_aton=yes
12614else
12615  ac_cv_lib_c_inet_aton=no
12616fi
12617rm -f core conftest.err conftest.$ac_objext \
12618    conftest$ac_exeext conftest.$ac_ext
12619LIBS=$ac_check_lib_save_LIBS
12620fi
12621{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5
12622$as_echo "$ac_cv_lib_c_inet_aton" >&6; }
12623if test "x$ac_cv_lib_c_inet_aton" = xyes; then :
12624  $ac_cv_prog_TRUE
12625else
12626  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5
12627$as_echo_n "checking for inet_aton in -lresolv... " >&6; }
12628if ${ac_cv_lib_resolv_inet_aton+:} false; then :
12629  $as_echo_n "(cached) " >&6
12630else
12631  ac_check_lib_save_LIBS=$LIBS
12632LIBS="-lresolv  $LIBS"
12633cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12634/* end confdefs.h.  */
12635
12636/* Override any GCC internal prototype to avoid an error.
12637   Use char because int might match the return type of a GCC
12638   builtin and then its argument prototype would still apply.  */
12639#ifdef __cplusplus
12640extern "C"
12641#endif
12642char inet_aton ();
12643int
12644main ()
12645{
12646return inet_aton ();
12647  ;
12648  return 0;
12649}
12650_ACEOF
12651if ac_fn_c_try_link "$LINENO"; then :
12652  ac_cv_lib_resolv_inet_aton=yes
12653else
12654  ac_cv_lib_resolv_inet_aton=no
12655fi
12656rm -f core conftest.err conftest.$ac_objext \
12657    conftest$ac_exeext conftest.$ac_ext
12658LIBS=$ac_check_lib_save_LIBS
12659fi
12660{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5
12661$as_echo "$ac_cv_lib_resolv_inet_aton" >&6; }
12662if test "x$ac_cv_lib_resolv_inet_aton" = xyes; then :
12663  cat >>confdefs.h <<_ACEOF
12664#define HAVE_LIBRESOLV 1
12665_ACEOF
12666
12667  LIBS="-lresolv $LIBS"
12668
12669fi
12670
12671
12672fi
12673
12674
12675# On Tru64, chflags seems to be present, but calling it will
12676# exit Python
12677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5
12678$as_echo_n "checking for chflags... " >&6; }
12679if ${ac_cv_have_chflags+:} false; then :
12680  $as_echo_n "(cached) " >&6
12681else
12682  if test "$cross_compiling" = yes; then :
12683  ac_cv_have_chflags=cross
12684else
12685  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12686/* end confdefs.h.  */
12687
12688#include <sys/stat.h>
12689#include <unistd.h>
12690int main(int argc, char*argv[])
12691{
12692  if(chflags(argv[0], 0) != 0)
12693    return 1;
12694  return 0;
12695}
12696
12697_ACEOF
12698if ac_fn_c_try_run "$LINENO"; then :
12699  ac_cv_have_chflags=yes
12700else
12701  ac_cv_have_chflags=no
12702fi
12703rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12704  conftest.$ac_objext conftest.beam conftest.$ac_ext
12705fi
12706
12707
12708fi
12709{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5
12710$as_echo "$ac_cv_have_chflags" >&6; }
12711if test "$ac_cv_have_chflags" = cross ; then
12712  ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags"
12713if test "x$ac_cv_func_chflags" = xyes; then :
12714  ac_cv_have_chflags="yes"
12715else
12716  ac_cv_have_chflags="no"
12717fi
12718
12719fi
12720if test "$ac_cv_have_chflags" = yes ; then
12721
12722$as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h
12723
12724fi
12725
12726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5
12727$as_echo_n "checking for lchflags... " >&6; }
12728if ${ac_cv_have_lchflags+:} false; then :
12729  $as_echo_n "(cached) " >&6
12730else
12731  if test "$cross_compiling" = yes; then :
12732  ac_cv_have_lchflags=cross
12733else
12734  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12735/* end confdefs.h.  */
12736
12737#include <sys/stat.h>
12738#include <unistd.h>
12739int main(int argc, char*argv[])
12740{
12741  if(lchflags(argv[0], 0) != 0)
12742    return 1;
12743  return 0;
12744}
12745
12746_ACEOF
12747if ac_fn_c_try_run "$LINENO"; then :
12748  ac_cv_have_lchflags=yes
12749else
12750  ac_cv_have_lchflags=no
12751fi
12752rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12753  conftest.$ac_objext conftest.beam conftest.$ac_ext
12754fi
12755
12756
12757fi
12758{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5
12759$as_echo "$ac_cv_have_lchflags" >&6; }
12760if test "$ac_cv_have_lchflags" = cross ; then
12761  ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags"
12762if test "x$ac_cv_func_lchflags" = xyes; then :
12763  ac_cv_have_lchflags="yes"
12764else
12765  ac_cv_have_lchflags="no"
12766fi
12767
12768fi
12769if test "$ac_cv_have_lchflags" = yes ; then
12770
12771$as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h
12772
12773fi
12774
12775case $ac_sys_system/$ac_sys_release in
12776Darwin/*)
12777	_CUR_CFLAGS="${CFLAGS}"
12778	_CUR_LDFLAGS="${LDFLAGS}"
12779	CFLAGS="${CFLAGS} -Wl,-search_paths_first"
12780	LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib"
12781	;;
12782esac
12783
12784{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5
12785$as_echo_n "checking for inflateCopy in -lz... " >&6; }
12786if ${ac_cv_lib_z_inflateCopy+:} false; then :
12787  $as_echo_n "(cached) " >&6
12788else
12789  ac_check_lib_save_LIBS=$LIBS
12790LIBS="-lz  $LIBS"
12791cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12792/* end confdefs.h.  */
12793
12794/* Override any GCC internal prototype to avoid an error.
12795   Use char because int might match the return type of a GCC
12796   builtin and then its argument prototype would still apply.  */
12797#ifdef __cplusplus
12798extern "C"
12799#endif
12800char inflateCopy ();
12801int
12802main ()
12803{
12804return inflateCopy ();
12805  ;
12806  return 0;
12807}
12808_ACEOF
12809if ac_fn_c_try_link "$LINENO"; then :
12810  ac_cv_lib_z_inflateCopy=yes
12811else
12812  ac_cv_lib_z_inflateCopy=no
12813fi
12814rm -f core conftest.err conftest.$ac_objext \
12815    conftest$ac_exeext conftest.$ac_ext
12816LIBS=$ac_check_lib_save_LIBS
12817fi
12818{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5
12819$as_echo "$ac_cv_lib_z_inflateCopy" >&6; }
12820if test "x$ac_cv_lib_z_inflateCopy" = xyes; then :
12821
12822$as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h
12823
12824fi
12825
12826
12827case $ac_sys_system/$ac_sys_release in
12828Darwin/*)
12829	CFLAGS="${_CUR_CFLAGS}"
12830	LDFLAGS="${_CUR_LDFLAGS}"
12831	;;
12832esac
12833
12834{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5
12835$as_echo_n "checking for hstrerror... " >&6; }
12836cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12837/* end confdefs.h.  */
12838
12839#include <netdb.h>
12840
12841int
12842main ()
12843{
12844void* p = hstrerror; hstrerror(0)
12845  ;
12846  return 0;
12847}
12848_ACEOF
12849if ac_fn_c_try_link "$LINENO"; then :
12850
12851$as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h
12852
12853   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12854$as_echo "yes" >&6; }
12855else
12856  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12857$as_echo "no" >&6; }
12858
12859fi
12860rm -f core conftest.err conftest.$ac_objext \
12861    conftest$ac_exeext conftest.$ac_ext
12862
12863{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5
12864$as_echo_n "checking for inet_aton... " >&6; }
12865cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12866/* end confdefs.h.  */
12867
12868#include <sys/types.h>
12869#include <sys/socket.h>
12870#include <netinet/in.h>
12871#include <arpa/inet.h>
12872
12873int
12874main ()
12875{
12876void* p = inet_aton;inet_aton(0,0)
12877  ;
12878  return 0;
12879}
12880_ACEOF
12881if ac_fn_c_try_link "$LINENO"; then :
12882
12883$as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
12884
12885   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12886$as_echo "yes" >&6; }
12887else
12888  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12889$as_echo "no" >&6; }
12890
12891fi
12892rm -f core conftest.err conftest.$ac_objext \
12893    conftest$ac_exeext conftest.$ac_ext
12894
12895{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5
12896$as_echo_n "checking for inet_pton... " >&6; }
12897cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12898/* end confdefs.h.  */
12899
12900#include <sys/types.h>
12901#include <sys/socket.h>
12902#include <netinet/in.h>
12903#include <arpa/inet.h>
12904
12905int
12906main ()
12907{
12908void* p = inet_pton
12909  ;
12910  return 0;
12911}
12912_ACEOF
12913if ac_fn_c_try_compile "$LINENO"; then :
12914
12915$as_echo "#define HAVE_INET_PTON 1" >>confdefs.h
12916
12917   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12918$as_echo "yes" >&6; }
12919else
12920  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12921$as_echo "no" >&6; }
12922
12923fi
12924rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12925
12926# On some systems, setgroups is in unistd.h, on others, in grp.h
12927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5
12928$as_echo_n "checking for setgroups... " >&6; }
12929cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12930/* end confdefs.h.  */
12931
12932#include <unistd.h>
12933#ifdef HAVE_GRP_H
12934#include <grp.h>
12935#endif
12936
12937int
12938main ()
12939{
12940void* p = setgroups
12941  ;
12942  return 0;
12943}
12944_ACEOF
12945if ac_fn_c_try_compile "$LINENO"; then :
12946
12947$as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h
12948
12949   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12950$as_echo "yes" >&6; }
12951else
12952  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12953$as_echo "no" >&6; }
12954
12955fi
12956rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12957
12958# check for openpty and forkpty
12959
12960for ac_func in openpty
12961do :
12962  ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty"
12963if test "x$ac_cv_func_openpty" = xyes; then :
12964  cat >>confdefs.h <<_ACEOF
12965#define HAVE_OPENPTY 1
12966_ACEOF
12967
12968else
12969  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5
12970$as_echo_n "checking for openpty in -lutil... " >&6; }
12971if ${ac_cv_lib_util_openpty+:} false; then :
12972  $as_echo_n "(cached) " >&6
12973else
12974  ac_check_lib_save_LIBS=$LIBS
12975LIBS="-lutil  $LIBS"
12976cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12977/* end confdefs.h.  */
12978
12979/* Override any GCC internal prototype to avoid an error.
12980   Use char because int might match the return type of a GCC
12981   builtin and then its argument prototype would still apply.  */
12982#ifdef __cplusplus
12983extern "C"
12984#endif
12985char openpty ();
12986int
12987main ()
12988{
12989return openpty ();
12990  ;
12991  return 0;
12992}
12993_ACEOF
12994if ac_fn_c_try_link "$LINENO"; then :
12995  ac_cv_lib_util_openpty=yes
12996else
12997  ac_cv_lib_util_openpty=no
12998fi
12999rm -f core conftest.err conftest.$ac_objext \
13000    conftest$ac_exeext conftest.$ac_ext
13001LIBS=$ac_check_lib_save_LIBS
13002fi
13003{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5
13004$as_echo "$ac_cv_lib_util_openpty" >&6; }
13005if test "x$ac_cv_lib_util_openpty" = xyes; then :
13006  $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h
13007 LIBS="$LIBS -lutil"
13008else
13009  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5
13010$as_echo_n "checking for openpty in -lbsd... " >&6; }
13011if ${ac_cv_lib_bsd_openpty+:} false; then :
13012  $as_echo_n "(cached) " >&6
13013else
13014  ac_check_lib_save_LIBS=$LIBS
13015LIBS="-lbsd  $LIBS"
13016cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13017/* end confdefs.h.  */
13018
13019/* Override any GCC internal prototype to avoid an error.
13020   Use char because int might match the return type of a GCC
13021   builtin and then its argument prototype would still apply.  */
13022#ifdef __cplusplus
13023extern "C"
13024#endif
13025char openpty ();
13026int
13027main ()
13028{
13029return openpty ();
13030  ;
13031  return 0;
13032}
13033_ACEOF
13034if ac_fn_c_try_link "$LINENO"; then :
13035  ac_cv_lib_bsd_openpty=yes
13036else
13037  ac_cv_lib_bsd_openpty=no
13038fi
13039rm -f core conftest.err conftest.$ac_objext \
13040    conftest$ac_exeext conftest.$ac_ext
13041LIBS=$ac_check_lib_save_LIBS
13042fi
13043{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5
13044$as_echo "$ac_cv_lib_bsd_openpty" >&6; }
13045if test "x$ac_cv_lib_bsd_openpty" = xyes; then :
13046  $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h
13047 LIBS="$LIBS -lbsd"
13048fi
13049
13050
13051fi
13052
13053
13054fi
13055done
13056
13057for ac_func in forkpty
13058do :
13059  ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty"
13060if test "x$ac_cv_func_forkpty" = xyes; then :
13061  cat >>confdefs.h <<_ACEOF
13062#define HAVE_FORKPTY 1
13063_ACEOF
13064
13065else
13066  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5
13067$as_echo_n "checking for forkpty in -lutil... " >&6; }
13068if ${ac_cv_lib_util_forkpty+:} false; then :
13069  $as_echo_n "(cached) " >&6
13070else
13071  ac_check_lib_save_LIBS=$LIBS
13072LIBS="-lutil  $LIBS"
13073cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13074/* end confdefs.h.  */
13075
13076/* Override any GCC internal prototype to avoid an error.
13077   Use char because int might match the return type of a GCC
13078   builtin and then its argument prototype would still apply.  */
13079#ifdef __cplusplus
13080extern "C"
13081#endif
13082char forkpty ();
13083int
13084main ()
13085{
13086return forkpty ();
13087  ;
13088  return 0;
13089}
13090_ACEOF
13091if ac_fn_c_try_link "$LINENO"; then :
13092  ac_cv_lib_util_forkpty=yes
13093else
13094  ac_cv_lib_util_forkpty=no
13095fi
13096rm -f core conftest.err conftest.$ac_objext \
13097    conftest$ac_exeext conftest.$ac_ext
13098LIBS=$ac_check_lib_save_LIBS
13099fi
13100{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5
13101$as_echo "$ac_cv_lib_util_forkpty" >&6; }
13102if test "x$ac_cv_lib_util_forkpty" = xyes; then :
13103  $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h
13104 LIBS="$LIBS -lutil"
13105else
13106  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5
13107$as_echo_n "checking for forkpty in -lbsd... " >&6; }
13108if ${ac_cv_lib_bsd_forkpty+:} false; then :
13109  $as_echo_n "(cached) " >&6
13110else
13111  ac_check_lib_save_LIBS=$LIBS
13112LIBS="-lbsd  $LIBS"
13113cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13114/* end confdefs.h.  */
13115
13116/* Override any GCC internal prototype to avoid an error.
13117   Use char because int might match the return type of a GCC
13118   builtin and then its argument prototype would still apply.  */
13119#ifdef __cplusplus
13120extern "C"
13121#endif
13122char forkpty ();
13123int
13124main ()
13125{
13126return forkpty ();
13127  ;
13128  return 0;
13129}
13130_ACEOF
13131if ac_fn_c_try_link "$LINENO"; then :
13132  ac_cv_lib_bsd_forkpty=yes
13133else
13134  ac_cv_lib_bsd_forkpty=no
13135fi
13136rm -f core conftest.err conftest.$ac_objext \
13137    conftest$ac_exeext conftest.$ac_ext
13138LIBS=$ac_check_lib_save_LIBS
13139fi
13140{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5
13141$as_echo "$ac_cv_lib_bsd_forkpty" >&6; }
13142if test "x$ac_cv_lib_bsd_forkpty" = xyes; then :
13143  $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h
13144 LIBS="$LIBS -lbsd"
13145fi
13146
13147
13148fi
13149
13150
13151fi
13152done
13153
13154
13155# check for long file support functions
13156for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
13157do :
13158  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13159ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13160if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13161  cat >>confdefs.h <<_ACEOF
13162#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13163_ACEOF
13164
13165fi
13166done
13167
13168
13169ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2"
13170if test "x$ac_cv_func_dup2" = xyes; then :
13171  $as_echo "#define HAVE_DUP2 1" >>confdefs.h
13172
13173else
13174  case " $LIBOBJS " in
13175  *" dup2.$ac_objext "* ) ;;
13176  *) LIBOBJS="$LIBOBJS dup2.$ac_objext"
13177 ;;
13178esac
13179
13180fi
13181
13182
13183for ac_func in getpgrp
13184do :
13185  ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp"
13186if test "x$ac_cv_func_getpgrp" = xyes; then :
13187  cat >>confdefs.h <<_ACEOF
13188#define HAVE_GETPGRP 1
13189_ACEOF
13190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13191/* end confdefs.h.  */
13192#include <unistd.h>
13193int
13194main ()
13195{
13196getpgrp(0);
13197  ;
13198  return 0;
13199}
13200_ACEOF
13201if ac_fn_c_try_compile "$LINENO"; then :
13202
13203$as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h
13204
13205fi
13206rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13207
13208fi
13209done
13210
13211for ac_func in setpgrp
13212do :
13213  ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp"
13214if test "x$ac_cv_func_setpgrp" = xyes; then :
13215  cat >>confdefs.h <<_ACEOF
13216#define HAVE_SETPGRP 1
13217_ACEOF
13218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13219/* end confdefs.h.  */
13220#include <unistd.h>
13221int
13222main ()
13223{
13224setpgrp(0,0);
13225  ;
13226  return 0;
13227}
13228_ACEOF
13229if ac_fn_c_try_compile "$LINENO"; then :
13230
13231$as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h
13232
13233fi
13234rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13235
13236fi
13237done
13238
13239
13240# We search for both crypt and crypt_r as one or the other may be defined
13241# This gets us our -lcrypt in LIBS when required on the target platform.
13242{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypt" >&5
13243$as_echo_n "checking for library containing crypt... " >&6; }
13244if ${ac_cv_search_crypt+:} false; then :
13245  $as_echo_n "(cached) " >&6
13246else
13247  ac_func_search_save_LIBS=$LIBS
13248cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13249/* end confdefs.h.  */
13250
13251/* Override any GCC internal prototype to avoid an error.
13252   Use char because int might match the return type of a GCC
13253   builtin and then its argument prototype would still apply.  */
13254#ifdef __cplusplus
13255extern "C"
13256#endif
13257char crypt ();
13258int
13259main ()
13260{
13261return crypt ();
13262  ;
13263  return 0;
13264}
13265_ACEOF
13266for ac_lib in '' crypt; do
13267  if test -z "$ac_lib"; then
13268    ac_res="none required"
13269  else
13270    ac_res=-l$ac_lib
13271    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13272  fi
13273  if ac_fn_c_try_link "$LINENO"; then :
13274  ac_cv_search_crypt=$ac_res
13275fi
13276rm -f core conftest.err conftest.$ac_objext \
13277    conftest$ac_exeext
13278  if ${ac_cv_search_crypt+:} false; then :
13279  break
13280fi
13281done
13282if ${ac_cv_search_crypt+:} false; then :
13283
13284else
13285  ac_cv_search_crypt=no
13286fi
13287rm conftest.$ac_ext
13288LIBS=$ac_func_search_save_LIBS
13289fi
13290{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt" >&5
13291$as_echo "$ac_cv_search_crypt" >&6; }
13292ac_res=$ac_cv_search_crypt
13293if test "$ac_res" != no; then :
13294  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13295
13296fi
13297
13298{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypt_r" >&5
13299$as_echo_n "checking for library containing crypt_r... " >&6; }
13300if ${ac_cv_search_crypt_r+:} false; then :
13301  $as_echo_n "(cached) " >&6
13302else
13303  ac_func_search_save_LIBS=$LIBS
13304cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13305/* end confdefs.h.  */
13306
13307/* Override any GCC internal prototype to avoid an error.
13308   Use char because int might match the return type of a GCC
13309   builtin and then its argument prototype would still apply.  */
13310#ifdef __cplusplus
13311extern "C"
13312#endif
13313char crypt_r ();
13314int
13315main ()
13316{
13317return crypt_r ();
13318  ;
13319  return 0;
13320}
13321_ACEOF
13322for ac_lib in '' crypt; do
13323  if test -z "$ac_lib"; then
13324    ac_res="none required"
13325  else
13326    ac_res=-l$ac_lib
13327    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13328  fi
13329  if ac_fn_c_try_link "$LINENO"; then :
13330  ac_cv_search_crypt_r=$ac_res
13331fi
13332rm -f core conftest.err conftest.$ac_objext \
13333    conftest$ac_exeext
13334  if ${ac_cv_search_crypt_r+:} false; then :
13335  break
13336fi
13337done
13338if ${ac_cv_search_crypt_r+:} false; then :
13339
13340else
13341  ac_cv_search_crypt_r=no
13342fi
13343rm conftest.$ac_ext
13344LIBS=$ac_func_search_save_LIBS
13345fi
13346{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt_r" >&5
13347$as_echo "$ac_cv_search_crypt_r" >&6; }
13348ac_res=$ac_cv_search_crypt_r
13349if test "$ac_res" != no; then :
13350  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13351
13352fi
13353
13354
13355ac_fn_c_check_func "$LINENO" "crypt_r" "ac_cv_func_crypt_r"
13356if test "x$ac_cv_func_crypt_r" = xyes; then :
13357  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13358/* end confdefs.h.  */
13359
13360#define _GNU_SOURCE  /* Required for crypt_r()'s prototype in glibc. */
13361#include <crypt.h>
13362
13363int
13364main ()
13365{
13366
13367struct crypt_data d;
13368char *r = crypt_r("", "", &d);
13369
13370  ;
13371  return 0;
13372}
13373_ACEOF
13374if ac_fn_c_try_compile "$LINENO"; then :
13375
13376$as_echo "#define HAVE_CRYPT_R 1" >>confdefs.h
13377
13378fi
13379rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13380
13381fi
13382
13383
13384for ac_func in clock_gettime
13385do :
13386  ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime"
13387if test "x$ac_cv_func_clock_gettime" = xyes; then :
13388  cat >>confdefs.h <<_ACEOF
13389#define HAVE_CLOCK_GETTIME 1
13390_ACEOF
13391
13392else
13393
13394    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5
13395$as_echo_n "checking for clock_gettime in -lrt... " >&6; }
13396if ${ac_cv_lib_rt_clock_gettime+:} false; then :
13397  $as_echo_n "(cached) " >&6
13398else
13399  ac_check_lib_save_LIBS=$LIBS
13400LIBS="-lrt  $LIBS"
13401cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13402/* end confdefs.h.  */
13403
13404/* Override any GCC internal prototype to avoid an error.
13405   Use char because int might match the return type of a GCC
13406   builtin and then its argument prototype would still apply.  */
13407#ifdef __cplusplus
13408extern "C"
13409#endif
13410char clock_gettime ();
13411int
13412main ()
13413{
13414return clock_gettime ();
13415  ;
13416  return 0;
13417}
13418_ACEOF
13419if ac_fn_c_try_link "$LINENO"; then :
13420  ac_cv_lib_rt_clock_gettime=yes
13421else
13422  ac_cv_lib_rt_clock_gettime=no
13423fi
13424rm -f core conftest.err conftest.$ac_objext \
13425    conftest$ac_exeext conftest.$ac_ext
13426LIBS=$ac_check_lib_save_LIBS
13427fi
13428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5
13429$as_echo "$ac_cv_lib_rt_clock_gettime" >&6; }
13430if test "x$ac_cv_lib_rt_clock_gettime" = xyes; then :
13431
13432        LIBS="$LIBS -lrt"
13433        $as_echo "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
13434
13435
13436$as_echo "#define TIMEMODULE_LIB rt" >>confdefs.h
13437
13438
13439fi
13440
13441
13442fi
13443done
13444
13445
13446for ac_func in clock_getres
13447do :
13448  ac_fn_c_check_func "$LINENO" "clock_getres" "ac_cv_func_clock_getres"
13449if test "x$ac_cv_func_clock_getres" = xyes; then :
13450  cat >>confdefs.h <<_ACEOF
13451#define HAVE_CLOCK_GETRES 1
13452_ACEOF
13453
13454else
13455
13456    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_getres in -lrt" >&5
13457$as_echo_n "checking for clock_getres in -lrt... " >&6; }
13458if ${ac_cv_lib_rt_clock_getres+:} false; then :
13459  $as_echo_n "(cached) " >&6
13460else
13461  ac_check_lib_save_LIBS=$LIBS
13462LIBS="-lrt  $LIBS"
13463cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13464/* end confdefs.h.  */
13465
13466/* Override any GCC internal prototype to avoid an error.
13467   Use char because int might match the return type of a GCC
13468   builtin and then its argument prototype would still apply.  */
13469#ifdef __cplusplus
13470extern "C"
13471#endif
13472char clock_getres ();
13473int
13474main ()
13475{
13476return clock_getres ();
13477  ;
13478  return 0;
13479}
13480_ACEOF
13481if ac_fn_c_try_link "$LINENO"; then :
13482  ac_cv_lib_rt_clock_getres=yes
13483else
13484  ac_cv_lib_rt_clock_getres=no
13485fi
13486rm -f core conftest.err conftest.$ac_objext \
13487    conftest$ac_exeext conftest.$ac_ext
13488LIBS=$ac_check_lib_save_LIBS
13489fi
13490{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_getres" >&5
13491$as_echo "$ac_cv_lib_rt_clock_getres" >&6; }
13492if test "x$ac_cv_lib_rt_clock_getres" = xyes; then :
13493
13494        $as_echo "#define HAVE_CLOCK_GETRES 1" >>confdefs.h
13495
13496
13497fi
13498
13499
13500fi
13501done
13502
13503
13504for ac_func in clock_settime
13505do :
13506  ac_fn_c_check_func "$LINENO" "clock_settime" "ac_cv_func_clock_settime"
13507if test "x$ac_cv_func_clock_settime" = xyes; then :
13508  cat >>confdefs.h <<_ACEOF
13509#define HAVE_CLOCK_SETTIME 1
13510_ACEOF
13511
13512else
13513
13514    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_settime in -lrt" >&5
13515$as_echo_n "checking for clock_settime in -lrt... " >&6; }
13516if ${ac_cv_lib_rt_clock_settime+:} false; then :
13517  $as_echo_n "(cached) " >&6
13518else
13519  ac_check_lib_save_LIBS=$LIBS
13520LIBS="-lrt  $LIBS"
13521cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13522/* end confdefs.h.  */
13523
13524/* Override any GCC internal prototype to avoid an error.
13525   Use char because int might match the return type of a GCC
13526   builtin and then its argument prototype would still apply.  */
13527#ifdef __cplusplus
13528extern "C"
13529#endif
13530char clock_settime ();
13531int
13532main ()
13533{
13534return clock_settime ();
13535  ;
13536  return 0;
13537}
13538_ACEOF
13539if ac_fn_c_try_link "$LINENO"; then :
13540  ac_cv_lib_rt_clock_settime=yes
13541else
13542  ac_cv_lib_rt_clock_settime=no
13543fi
13544rm -f core conftest.err conftest.$ac_objext \
13545    conftest$ac_exeext conftest.$ac_ext
13546LIBS=$ac_check_lib_save_LIBS
13547fi
13548{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_settime" >&5
13549$as_echo "$ac_cv_lib_rt_clock_settime" >&6; }
13550if test "x$ac_cv_lib_rt_clock_settime" = xyes; then :
13551
13552        $as_echo "#define HAVE_CLOCK_SETTIME 1" >>confdefs.h
13553
13554
13555fi
13556
13557
13558fi
13559done
13560
13561
13562{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5
13563$as_echo_n "checking for major... " >&6; }
13564cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13565/* end confdefs.h.  */
13566
13567#if defined(MAJOR_IN_MKDEV)
13568#include <sys/mkdev.h>
13569#elif defined(MAJOR_IN_SYSMACROS)
13570#include <sys/sysmacros.h>
13571#else
13572#include <sys/types.h>
13573#endif
13574
13575int
13576main ()
13577{
13578
13579  makedev(major(0),minor(0));
13580
13581  ;
13582  return 0;
13583}
13584_ACEOF
13585if ac_fn_c_try_link "$LINENO"; then :
13586
13587
13588$as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h
13589
13590  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13591$as_echo "yes" >&6; }
13592
13593else
13594
13595  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13596$as_echo "no" >&6; }
13597
13598fi
13599rm -f core conftest.err conftest.$ac_objext \
13600    conftest$ac_exeext conftest.$ac_ext
13601
13602# On OSF/1 V5.1, getaddrinfo is available, but a define
13603# for [no]getaddrinfo in netdb.h.
13604{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
13605$as_echo_n "checking for getaddrinfo... " >&6; }
13606cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13607/* end confdefs.h.  */
13608
13609#include <sys/types.h>
13610#include <sys/socket.h>
13611#include <netdb.h>
13612#include <stdio.h>
13613
13614int
13615main ()
13616{
13617getaddrinfo(NULL, NULL, NULL, NULL);
13618  ;
13619  return 0;
13620}
13621_ACEOF
13622if ac_fn_c_try_link "$LINENO"; then :
13623  have_getaddrinfo=yes
13624else
13625  have_getaddrinfo=no
13626fi
13627rm -f core conftest.err conftest.$ac_objext \
13628    conftest$ac_exeext conftest.$ac_ext
13629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5
13630$as_echo "$have_getaddrinfo" >&6; }
13631if test $have_getaddrinfo = yes
13632then
13633  { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5
13634$as_echo_n "checking getaddrinfo bug... " >&6; }
13635  if ${ac_cv_buggy_getaddrinfo+:} false; then :
13636  $as_echo_n "(cached) " >&6
13637else
13638  if test "$cross_compiling" = yes; then :
13639
13640if test "${enable_ipv6+set}" = set; then
13641  ac_cv_buggy_getaddrinfo="no -- configured with --(en|dis)able-ipv6"
13642else
13643  ac_cv_buggy_getaddrinfo=yes
13644fi
13645else
13646  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13647/* end confdefs.h.  */
13648
13649#include <stdio.h>
13650#include <sys/types.h>
13651#include <netdb.h>
13652#include <string.h>
13653#include <sys/socket.h>
13654#include <netinet/in.h>
13655
13656int main()
13657{
13658  int passive, gaierr, inet4 = 0, inet6 = 0;
13659  struct addrinfo hints, *ai, *aitop;
13660  char straddr[INET6_ADDRSTRLEN], strport[16];
13661
13662  for (passive = 0; passive <= 1; passive++) {
13663    memset(&hints, 0, sizeof(hints));
13664    hints.ai_family = AF_UNSPEC;
13665    hints.ai_flags = passive ? AI_PASSIVE : 0;
13666    hints.ai_socktype = SOCK_STREAM;
13667    hints.ai_protocol = IPPROTO_TCP;
13668    if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
13669      (void)gai_strerror(gaierr);
13670      goto bad;
13671    }
13672    for (ai = aitop; ai; ai = ai->ai_next) {
13673      if (ai->ai_addr == NULL ||
13674          ai->ai_addrlen == 0 ||
13675          getnameinfo(ai->ai_addr, ai->ai_addrlen,
13676                      straddr, sizeof(straddr), strport, sizeof(strport),
13677                      NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
13678        goto bad;
13679      }
13680      switch (ai->ai_family) {
13681      case AF_INET:
13682        if (strcmp(strport, "54321") != 0) {
13683          goto bad;
13684        }
13685        if (passive) {
13686          if (strcmp(straddr, "0.0.0.0") != 0) {
13687            goto bad;
13688          }
13689        } else {
13690          if (strcmp(straddr, "127.0.0.1") != 0) {
13691            goto bad;
13692          }
13693        }
13694        inet4++;
13695        break;
13696      case AF_INET6:
13697        if (strcmp(strport, "54321") != 0) {
13698          goto bad;
13699        }
13700        if (passive) {
13701          if (strcmp(straddr, "::") != 0) {
13702            goto bad;
13703          }
13704        } else {
13705          if (strcmp(straddr, "::1") != 0) {
13706            goto bad;
13707          }
13708        }
13709        inet6++;
13710        break;
13711      case AF_UNSPEC:
13712        goto bad;
13713        break;
13714      default:
13715        /* another family support? */
13716        break;
13717      }
13718    }
13719    freeaddrinfo(aitop);
13720    aitop = NULL;
13721  }
13722
13723  if (!(inet4 == 0 || inet4 == 2))
13724    goto bad;
13725  if (!(inet6 == 0 || inet6 == 2))
13726    goto bad;
13727
13728  if (aitop)
13729    freeaddrinfo(aitop);
13730  return 0;
13731
13732 bad:
13733  if (aitop)
13734    freeaddrinfo(aitop);
13735  return 1;
13736}
13737
13738_ACEOF
13739if ac_fn_c_try_run "$LINENO"; then :
13740  ac_cv_buggy_getaddrinfo=no
13741else
13742  ac_cv_buggy_getaddrinfo=yes
13743fi
13744rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13745  conftest.$ac_objext conftest.beam conftest.$ac_ext
13746fi
13747
13748fi
13749
13750fi
13751
13752{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5
13753$as_echo "$ac_cv_buggy_getaddrinfo" >&6; }
13754
13755if test $have_getaddrinfo = no || test "$ac_cv_buggy_getaddrinfo" = yes
13756then
13757	if test $ipv6 = yes
13758	then
13759		echo 'Fatal: You must get working getaddrinfo() function.'
13760		echo '       or you can specify "--disable-ipv6"'.
13761		exit 1
13762	fi
13763else
13764
13765$as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
13766
13767fi
13768
13769for ac_func in getnameinfo
13770do :
13771  ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo"
13772if test "x$ac_cv_func_getnameinfo" = xyes; then :
13773  cat >>confdefs.h <<_ACEOF
13774#define HAVE_GETNAMEINFO 1
13775_ACEOF
13776
13777fi
13778done
13779
13780
13781# checks for structures
13782{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
13783$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
13784if ${ac_cv_header_time+:} false; then :
13785  $as_echo_n "(cached) " >&6
13786else
13787  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13788/* end confdefs.h.  */
13789#include <sys/types.h>
13790#include <sys/time.h>
13791#include <time.h>
13792
13793int
13794main ()
13795{
13796if ((struct tm *) 0)
13797return 0;
13798  ;
13799  return 0;
13800}
13801_ACEOF
13802if ac_fn_c_try_compile "$LINENO"; then :
13803  ac_cv_header_time=yes
13804else
13805  ac_cv_header_time=no
13806fi
13807rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13808fi
13809{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
13810$as_echo "$ac_cv_header_time" >&6; }
13811if test $ac_cv_header_time = yes; then
13812
13813$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
13814
13815fi
13816
13817{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
13818$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
13819if ${ac_cv_struct_tm+:} false; then :
13820  $as_echo_n "(cached) " >&6
13821else
13822  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13823/* end confdefs.h.  */
13824#include <sys/types.h>
13825#include <time.h>
13826
13827int
13828main ()
13829{
13830struct tm tm;
13831				     int *p = &tm.tm_sec;
13832				     return !p;
13833  ;
13834  return 0;
13835}
13836_ACEOF
13837if ac_fn_c_try_compile "$LINENO"; then :
13838  ac_cv_struct_tm=time.h
13839else
13840  ac_cv_struct_tm=sys/time.h
13841fi
13842rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13843fi
13844{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
13845$as_echo "$ac_cv_struct_tm" >&6; }
13846if test $ac_cv_struct_tm = sys/time.h; then
13847
13848$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
13849
13850fi
13851
13852ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
13853#include <$ac_cv_struct_tm>
13854
13855"
13856if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
13857
13858cat >>confdefs.h <<_ACEOF
13859#define HAVE_STRUCT_TM_TM_ZONE 1
13860_ACEOF
13861
13862
13863fi
13864
13865if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13866
13867$as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
13868
13869else
13870  ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
13871"
13872if test "x$ac_cv_have_decl_tzname" = xyes; then :
13873  ac_have_decl=1
13874else
13875  ac_have_decl=0
13876fi
13877
13878cat >>confdefs.h <<_ACEOF
13879#define HAVE_DECL_TZNAME $ac_have_decl
13880_ACEOF
13881
13882  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
13883$as_echo_n "checking for tzname... " >&6; }
13884if ${ac_cv_var_tzname+:} false; then :
13885  $as_echo_n "(cached) " >&6
13886else
13887  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13888/* end confdefs.h.  */
13889#include <time.h>
13890#if !HAVE_DECL_TZNAME
13891extern char *tzname[];
13892#endif
13893
13894int
13895main ()
13896{
13897return tzname[0][0];
13898  ;
13899  return 0;
13900}
13901_ACEOF
13902if ac_fn_c_try_link "$LINENO"; then :
13903  ac_cv_var_tzname=yes
13904else
13905  ac_cv_var_tzname=no
13906fi
13907rm -f core conftest.err conftest.$ac_objext \
13908    conftest$ac_exeext conftest.$ac_ext
13909fi
13910{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
13911$as_echo "$ac_cv_var_tzname" >&6; }
13912  if test $ac_cv_var_tzname = yes; then
13913
13914$as_echo "#define HAVE_TZNAME 1" >>confdefs.h
13915
13916  fi
13917fi
13918
13919ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default"
13920if test "x$ac_cv_member_struct_stat_st_rdev" = xyes; then :
13921
13922cat >>confdefs.h <<_ACEOF
13923#define HAVE_STRUCT_STAT_ST_RDEV 1
13924_ACEOF
13925
13926
13927fi
13928
13929ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
13930if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
13931
13932cat >>confdefs.h <<_ACEOF
13933#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13934_ACEOF
13935
13936
13937fi
13938
13939ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default"
13940if test "x$ac_cv_member_struct_stat_st_flags" = xyes; then :
13941
13942cat >>confdefs.h <<_ACEOF
13943#define HAVE_STRUCT_STAT_ST_FLAGS 1
13944_ACEOF
13945
13946
13947fi
13948
13949ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default"
13950if test "x$ac_cv_member_struct_stat_st_gen" = xyes; then :
13951
13952cat >>confdefs.h <<_ACEOF
13953#define HAVE_STRUCT_STAT_ST_GEN 1
13954_ACEOF
13955
13956
13957fi
13958
13959ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default"
13960if test "x$ac_cv_member_struct_stat_st_birthtime" = xyes; then :
13961
13962cat >>confdefs.h <<_ACEOF
13963#define HAVE_STRUCT_STAT_ST_BIRTHTIME 1
13964_ACEOF
13965
13966
13967fi
13968
13969ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
13970if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then :
13971
13972cat >>confdefs.h <<_ACEOF
13973#define HAVE_STRUCT_STAT_ST_BLOCKS 1
13974_ACEOF
13975
13976
13977fi
13978
13979ac_fn_c_check_member "$LINENO" "struct passwd" "pw_gecos" "ac_cv_member_struct_passwd_pw_gecos" "
13980  #include <sys/types.h>
13981  #include <pwd.h>
13982
13983"
13984if test "x$ac_cv_member_struct_passwd_pw_gecos" = xyes; then :
13985
13986cat >>confdefs.h <<_ACEOF
13987#define HAVE_STRUCT_PASSWD_PW_GECOS 1
13988_ACEOF
13989
13990
13991fi
13992ac_fn_c_check_member "$LINENO" "struct passwd" "pw_passwd" "ac_cv_member_struct_passwd_pw_passwd" "
13993  #include <sys/types.h>
13994  #include <pwd.h>
13995
13996"
13997if test "x$ac_cv_member_struct_passwd_pw_passwd" = xyes; then :
13998
13999cat >>confdefs.h <<_ACEOF
14000#define HAVE_STRUCT_PASSWD_PW_PASSWD 1
14001_ACEOF
14002
14003
14004fi
14005
14006# Issue #21085: In Cygwin, siginfo_t does not have si_band field.
14007ac_fn_c_check_member "$LINENO" "siginfo_t" "si_band" "ac_cv_member_siginfo_t_si_band" "#include <signal.h>
14008"
14009if test "x$ac_cv_member_siginfo_t_si_band" = xyes; then :
14010
14011cat >>confdefs.h <<_ACEOF
14012#define HAVE_SIGINFO_T_SI_BAND 1
14013_ACEOF
14014
14015
14016fi
14017
14018
14019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5
14020$as_echo_n "checking for time.h that defines altzone... " >&6; }
14021if ${ac_cv_header_time_altzone+:} false; then :
14022  $as_echo_n "(cached) " >&6
14023else
14024
14025  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14026/* end confdefs.h.  */
14027#include <time.h>
14028int
14029main ()
14030{
14031return altzone;
14032  ;
14033  return 0;
14034}
14035_ACEOF
14036if ac_fn_c_try_compile "$LINENO"; then :
14037  ac_cv_header_time_altzone=yes
14038else
14039  ac_cv_header_time_altzone=no
14040fi
14041rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14042
14043fi
14044
14045{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5
14046$as_echo "$ac_cv_header_time_altzone" >&6; }
14047if test $ac_cv_header_time_altzone = yes; then
14048
14049$as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
14050
14051fi
14052
14053was_it_defined=no
14054{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5
14055$as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; }
14056cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14057/* end confdefs.h.  */
14058
14059#include <sys/types.h>
14060#include <sys/select.h>
14061#include <sys/time.h>
14062
14063int
14064main ()
14065{
14066;
14067  ;
14068  return 0;
14069}
14070_ACEOF
14071if ac_fn_c_try_compile "$LINENO"; then :
14072
14073
14074$as_echo "#define SYS_SELECT_WITH_SYS_TIME 1" >>confdefs.h
14075
14076  was_it_defined=yes
14077
14078fi
14079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5
14081$as_echo "$was_it_defined" >&6; }
14082
14083{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5
14084$as_echo_n "checking for addrinfo... " >&6; }
14085if ${ac_cv_struct_addrinfo+:} false; then :
14086  $as_echo_n "(cached) " >&6
14087else
14088  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14089/* end confdefs.h.  */
14090#include <netdb.h>
14091int
14092main ()
14093{
14094struct addrinfo a
14095  ;
14096  return 0;
14097}
14098_ACEOF
14099if ac_fn_c_try_compile "$LINENO"; then :
14100  ac_cv_struct_addrinfo=yes
14101else
14102  ac_cv_struct_addrinfo=no
14103fi
14104rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14105fi
14106
14107{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5
14108$as_echo "$ac_cv_struct_addrinfo" >&6; }
14109if test $ac_cv_struct_addrinfo = yes; then
14110
14111$as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h
14112
14113fi
14114
14115{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5
14116$as_echo_n "checking for sockaddr_storage... " >&6; }
14117if ${ac_cv_struct_sockaddr_storage+:} false; then :
14118  $as_echo_n "(cached) " >&6
14119else
14120  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14121/* end confdefs.h.  */
14122
14123#		include <sys/types.h>
14124#		include <sys/socket.h>
14125int
14126main ()
14127{
14128struct sockaddr_storage s
14129  ;
14130  return 0;
14131}
14132_ACEOF
14133if ac_fn_c_try_compile "$LINENO"; then :
14134  ac_cv_struct_sockaddr_storage=yes
14135else
14136  ac_cv_struct_sockaddr_storage=no
14137fi
14138rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14139fi
14140
14141{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5
14142$as_echo "$ac_cv_struct_sockaddr_storage" >&6; }
14143if test $ac_cv_struct_sockaddr_storage = yes; then
14144
14145$as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h
14146
14147fi
14148
14149{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_alg" >&5
14150$as_echo_n "checking for sockaddr_alg... " >&6; }
14151if ${ac_cv_struct_sockaddr_alg+:} false; then :
14152  $as_echo_n "(cached) " >&6
14153else
14154  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14155/* end confdefs.h.  */
14156
14157#		include <sys/types.h>
14158#		include <sys/socket.h>
14159#		include <linux/if_alg.h>
14160int
14161main ()
14162{
14163struct sockaddr_alg s
14164  ;
14165  return 0;
14166}
14167_ACEOF
14168if ac_fn_c_try_compile "$LINENO"; then :
14169  ac_cv_struct_sockaddr_alg=yes
14170else
14171  ac_cv_struct_sockaddr_alg=no
14172fi
14173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14174fi
14175
14176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_alg" >&5
14177$as_echo "$ac_cv_struct_sockaddr_alg" >&6; }
14178if test $ac_cv_struct_sockaddr_alg = yes; then
14179
14180$as_echo "#define HAVE_SOCKADDR_ALG 1" >>confdefs.h
14181
14182fi
14183
14184# checks for compiler characteristics
14185
14186{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
14187$as_echo_n "checking whether char is unsigned... " >&6; }
14188if ${ac_cv_c_char_unsigned+:} false; then :
14189  $as_echo_n "(cached) " >&6
14190else
14191  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14192/* end confdefs.h.  */
14193$ac_includes_default
14194int
14195main ()
14196{
14197static int test_array [1 - 2 * !(((char) -1) < 0)];
14198test_array [0] = 0;
14199return test_array [0];
14200
14201  ;
14202  return 0;
14203}
14204_ACEOF
14205if ac_fn_c_try_compile "$LINENO"; then :
14206  ac_cv_c_char_unsigned=no
14207else
14208  ac_cv_c_char_unsigned=yes
14209fi
14210rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14211fi
14212{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
14213$as_echo "$ac_cv_c_char_unsigned" >&6; }
14214if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
14215  $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
14216
14217fi
14218
14219{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
14220$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14221if ${ac_cv_c_const+:} false; then :
14222  $as_echo_n "(cached) " >&6
14223else
14224  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14225/* end confdefs.h.  */
14226
14227int
14228main ()
14229{
14230
14231#ifndef __cplusplus
14232  /* Ultrix mips cc rejects this sort of thing.  */
14233  typedef int charset[2];
14234  const charset cs = { 0, 0 };
14235  /* SunOS 4.1.1 cc rejects this.  */
14236  char const *const *pcpcc;
14237  char **ppc;
14238  /* NEC SVR4.0.2 mips cc rejects this.  */
14239  struct point {int x, y;};
14240  static struct point const zero = {0,0};
14241  /* AIX XL C 1.02.0.0 rejects this.
14242     It does not let you subtract one const X* pointer from another in
14243     an arm of an if-expression whose if-part is not a constant
14244     expression */
14245  const char *g = "string";
14246  pcpcc = &g + (g ? g-g : 0);
14247  /* HPUX 7.0 cc rejects these. */
14248  ++pcpcc;
14249  ppc = (char**) pcpcc;
14250  pcpcc = (char const *const *) ppc;
14251  { /* SCO 3.2v4 cc rejects this sort of thing.  */
14252    char tx;
14253    char *t = &tx;
14254    char const *s = 0 ? (char *) 0 : (char const *) 0;
14255
14256    *t++ = 0;
14257    if (s) return 0;
14258  }
14259  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14260    int x[] = {25, 17};
14261    const int *foo = &x[0];
14262    ++foo;
14263  }
14264  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14265    typedef const int *iptr;
14266    iptr p = 0;
14267    ++p;
14268  }
14269  { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
14270       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14271    struct s { int j; const int *ap[3]; } bx;
14272    struct s *b = &bx; b->j = 5;
14273  }
14274  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14275    const int foo = 10;
14276    if (!foo) return 0;
14277  }
14278  return !cs[0] && !zero.x;
14279#endif
14280
14281  ;
14282  return 0;
14283}
14284_ACEOF
14285if ac_fn_c_try_compile "$LINENO"; then :
14286  ac_cv_c_const=yes
14287else
14288  ac_cv_c_const=no
14289fi
14290rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14291fi
14292{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
14293$as_echo "$ac_cv_c_const" >&6; }
14294if test $ac_cv_c_const = no; then
14295
14296$as_echo "#define const /**/" >>confdefs.h
14297
14298fi
14299
14300
14301works=no
14302{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5
14303$as_echo_n "checking for working signed char... " >&6; }
14304cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14305/* end confdefs.h.  */
14306
14307int
14308main ()
14309{
14310signed char c;
14311  ;
14312  return 0;
14313}
14314_ACEOF
14315if ac_fn_c_try_compile "$LINENO"; then :
14316  works=yes
14317else
14318
14319$as_echo "#define signed /**/" >>confdefs.h
14320
14321
14322fi
14323rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14324{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5
14325$as_echo "$works" >&6; }
14326
14327have_prototypes=no
14328{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5
14329$as_echo_n "checking for prototypes... " >&6; }
14330cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14331/* end confdefs.h.  */
14332int foo(int x) { return 0; }
14333int
14334main ()
14335{
14336return foo(10);
14337  ;
14338  return 0;
14339}
14340_ACEOF
14341if ac_fn_c_try_compile "$LINENO"; then :
14342
14343$as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h
14344
14345   have_prototypes=yes
14346fi
14347rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14348{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5
14349$as_echo "$have_prototypes" >&6; }
14350
14351works=no
14352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5
14353$as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; }
14354cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14355/* end confdefs.h.  */
14356
14357#include <stdarg.h>
14358int foo(int x, ...) {
14359	va_list va;
14360	va_start(va, x);
14361	va_arg(va, int);
14362	va_arg(va, char *);
14363	va_arg(va, double);
14364	return 0;
14365}
14366
14367int
14368main ()
14369{
14370return foo(10, "", 3.14);
14371  ;
14372  return 0;
14373}
14374_ACEOF
14375if ac_fn_c_try_compile "$LINENO"; then :
14376
14377
14378$as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h
14379
14380  works=yes
14381
14382fi
14383rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14384{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5
14385$as_echo "$works" >&6; }
14386
14387# check for socketpair
14388{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5
14389$as_echo_n "checking for socketpair... " >&6; }
14390cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14391/* end confdefs.h.  */
14392
14393#include <sys/types.h>
14394#include <sys/socket.h>
14395
14396int
14397main ()
14398{
14399void *x=socketpair
14400  ;
14401  return 0;
14402}
14403_ACEOF
14404if ac_fn_c_try_compile "$LINENO"; then :
14405
14406$as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h
14407
14408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14409$as_echo "yes" >&6; }
14410else
14411  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14412$as_echo "no" >&6; }
14413
14414fi
14415rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14416
14417# check if sockaddr has sa_len member
14418{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5
14419$as_echo_n "checking if sockaddr has sa_len member... " >&6; }
14420cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14421/* end confdefs.h.  */
14422#include <sys/types.h>
14423#include <sys/socket.h>
14424int
14425main ()
14426{
14427struct sockaddr x;
14428x.sa_len = 0;
14429  ;
14430  return 0;
14431}
14432_ACEOF
14433if ac_fn_c_try_compile "$LINENO"; then :
14434  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14435$as_echo "yes" >&6; }
14436
14437$as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h
14438
14439else
14440  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14441$as_echo "no" >&6; }
14442
14443fi
14444rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14445
14446# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
14447
14448
14449ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r"
14450if test "x$ac_cv_func_gethostbyname_r" = xyes; then :
14451
14452  $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
14453
14454  { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5
14455$as_echo_n "checking gethostbyname_r with 6 args... " >&6; }
14456  OLD_CFLAGS=$CFLAGS
14457  CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
14458  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14459/* end confdefs.h.  */
14460
14461#   include <netdb.h>
14462
14463int
14464main ()
14465{
14466
14467    char *name;
14468    struct hostent *he, *res;
14469    char buffer[2048];
14470    int buflen = 2048;
14471    int h_errnop;
14472
14473    (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
14474
14475  ;
14476  return 0;
14477}
14478_ACEOF
14479if ac_fn_c_try_compile "$LINENO"; then :
14480
14481    $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
14482
14483
14484$as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h
14485
14486    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14487$as_echo "yes" >&6; }
14488
14489else
14490
14491    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14492$as_echo "no" >&6; }
14493    { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5
14494$as_echo_n "checking gethostbyname_r with 5 args... " >&6; }
14495    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14496/* end confdefs.h.  */
14497
14498#       include <netdb.h>
14499
14500int
14501main ()
14502{
14503
14504        char *name;
14505        struct hostent *he;
14506        char buffer[2048];
14507        int buflen = 2048;
14508        int h_errnop;
14509
14510        (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
14511
14512  ;
14513  return 0;
14514}
14515_ACEOF
14516if ac_fn_c_try_compile "$LINENO"; then :
14517
14518        $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
14519
14520
14521$as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h
14522
14523        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14524$as_echo "yes" >&6; }
14525
14526else
14527
14528        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14529$as_echo "no" >&6; }
14530        { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5
14531$as_echo_n "checking gethostbyname_r with 3 args... " >&6; }
14532        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14533/* end confdefs.h.  */
14534
14535#           include <netdb.h>
14536
14537int
14538main ()
14539{
14540
14541            char *name;
14542            struct hostent *he;
14543            struct hostent_data data;
14544
14545            (void) gethostbyname_r(name, he, &data);
14546
14547  ;
14548  return 0;
14549}
14550_ACEOF
14551if ac_fn_c_try_compile "$LINENO"; then :
14552
14553            $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
14554
14555
14556$as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h
14557
14558            { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14559$as_echo "yes" >&6; }
14560
14561else
14562
14563           { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14564$as_echo "no" >&6; }
14565
14566fi
14567rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14568
14569fi
14570rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14571
14572fi
14573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14574  CFLAGS=$OLD_CFLAGS
14575
14576else
14577
14578  for ac_func in gethostbyname
14579do :
14580  ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
14581if test "x$ac_cv_func_gethostbyname" = xyes; then :
14582  cat >>confdefs.h <<_ACEOF
14583#define HAVE_GETHOSTBYNAME 1
14584_ACEOF
14585
14586fi
14587done
14588
14589
14590fi
14591
14592
14593
14594
14595
14596
14597
14598# checks for system services
14599# (none yet)
14600
14601# Linux requires this for correct f.p. operations
14602ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control"
14603if test "x$ac_cv_func___fpu_control" = xyes; then :
14604
14605else
14606  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5
14607$as_echo_n "checking for __fpu_control in -lieee... " >&6; }
14608if ${ac_cv_lib_ieee___fpu_control+:} false; then :
14609  $as_echo_n "(cached) " >&6
14610else
14611  ac_check_lib_save_LIBS=$LIBS
14612LIBS="-lieee  $LIBS"
14613cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14614/* end confdefs.h.  */
14615
14616/* Override any GCC internal prototype to avoid an error.
14617   Use char because int might match the return type of a GCC
14618   builtin and then its argument prototype would still apply.  */
14619#ifdef __cplusplus
14620extern "C"
14621#endif
14622char __fpu_control ();
14623int
14624main ()
14625{
14626return __fpu_control ();
14627  ;
14628  return 0;
14629}
14630_ACEOF
14631if ac_fn_c_try_link "$LINENO"; then :
14632  ac_cv_lib_ieee___fpu_control=yes
14633else
14634  ac_cv_lib_ieee___fpu_control=no
14635fi
14636rm -f core conftest.err conftest.$ac_objext \
14637    conftest$ac_exeext conftest.$ac_ext
14638LIBS=$ac_check_lib_save_LIBS
14639fi
14640{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5
14641$as_echo "$ac_cv_lib_ieee___fpu_control" >&6; }
14642if test "x$ac_cv_lib_ieee___fpu_control" = xyes; then :
14643  cat >>confdefs.h <<_ACEOF
14644#define HAVE_LIBIEEE 1
14645_ACEOF
14646
14647  LIBS="-lieee $LIBS"
14648
14649fi
14650
14651
14652fi
14653
14654
14655# check for --with-libm=...
14656
14657case $ac_sys_system in
14658Darwin) ;;
14659*) LIBM=-lm
14660esac
14661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5
14662$as_echo_n "checking for --with-libm=STRING... " >&6; }
14663
14664# Check whether --with-libm was given.
14665if test "${with_libm+set}" = set; then :
14666  withval=$with_libm;
14667if test "$withval" = no
14668then LIBM=
14669     { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5
14670$as_echo "force LIBM empty" >&6; }
14671elif test "$withval" != yes
14672then LIBM=$withval
14673     { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5
14674$as_echo "set LIBM=\"$withval\"" >&6; }
14675else as_fn_error $? "proper usage is --with-libm=STRING" "$LINENO" 5
14676fi
14677else
14678  { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5
14679$as_echo "default LIBM=\"$LIBM\"" >&6; }
14680fi
14681
14682
14683# check for --with-libc=...
14684
14685{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5
14686$as_echo_n "checking for --with-libc=STRING... " >&6; }
14687
14688# Check whether --with-libc was given.
14689if test "${with_libc+set}" = set; then :
14690  withval=$with_libc;
14691if test "$withval" = no
14692then LIBC=
14693     { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5
14694$as_echo "force LIBC empty" >&6; }
14695elif test "$withval" != yes
14696then LIBC=$withval
14697     { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5
14698$as_echo "set LIBC=\"$withval\"" >&6; }
14699else as_fn_error $? "proper usage is --with-libc=STRING" "$LINENO" 5
14700fi
14701else
14702  { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5
14703$as_echo "default LIBC=\"$LIBC\"" >&6; }
14704fi
14705
14706
14707# **************************************
14708# * Check for gcc x64 inline assembler *
14709# **************************************
14710
14711{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for x64 gcc inline assembler" >&5
14712$as_echo_n "checking for x64 gcc inline assembler... " >&6; }
14713cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14714/* end confdefs.h.  */
14715
14716int
14717main ()
14718{
14719
14720  __asm__ __volatile__ ("movq %rcx, %rax");
14721
14722  ;
14723  return 0;
14724}
14725_ACEOF
14726if ac_fn_c_try_link "$LINENO"; then :
14727  have_gcc_asm_for_x64=yes
14728else
14729  have_gcc_asm_for_x64=no
14730fi
14731rm -f core conftest.err conftest.$ac_objext \
14732    conftest$ac_exeext conftest.$ac_ext
14733{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x64" >&5
14734$as_echo "$have_gcc_asm_for_x64" >&6; }
14735if test "$have_gcc_asm_for_x64" = yes
14736then
14737
14738$as_echo "#define HAVE_GCC_ASM_FOR_X64 1" >>confdefs.h
14739
14740fi
14741
14742# **************************************************
14743# * Check for various properties of floating point *
14744# **************************************************
14745
14746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether float word ordering is bigendian" >&5
14747$as_echo_n "checking whether float word ordering is bigendian... " >&6; }
14748if ${ax_cv_c_float_words_bigendian+:} false; then :
14749  $as_echo_n "(cached) " >&6
14750else
14751
14752
14753ax_cv_c_float_words_bigendian=unknown
14754cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14755/* end confdefs.h.  */
14756
14757
14758double d = 90904234967036810337470478905505011476211692735615632014797120844053488865816695273723469097858056257517020191247487429516932130503560650002327564517570778480236724525140520121371739201496540132640109977779420565776568942592.0;
14759
14760
14761_ACEOF
14762if ac_fn_c_try_compile "$LINENO"; then :
14763
14764
14765if grep noonsees conftest.$ac_objext >/dev/null ; then
14766  ax_cv_c_float_words_bigendian=yes
14767fi
14768if grep seesnoon conftest.$ac_objext >/dev/null ; then
14769  if test "$ax_cv_c_float_words_bigendian" = unknown; then
14770    ax_cv_c_float_words_bigendian=no
14771  else
14772    ax_cv_c_float_words_bigendian=unknown
14773  fi
14774fi
14775
14776
14777fi
14778rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14779fi
14780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_c_float_words_bigendian" >&5
14781$as_echo "$ax_cv_c_float_words_bigendian" >&6; }
14782
14783case $ax_cv_c_float_words_bigendian in
14784  yes)
14785
14786$as_echo "#define FLOAT_WORDS_BIGENDIAN 1" >>confdefs.h
14787 ;;
14788  no)
14789     ;;
14790  *)
14791    as_fn_error $? "
14792
14793Unknown float word ordering. You need to manually preset
14794ax_cv_c_float_words_bigendian=no (or yes) according to your system.
14795
14796    " "$LINENO" 5 ;;
14797esac
14798
14799
14800if test "$ax_cv_c_float_words_bigendian" = "yes"
14801then
14802
14803$as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h
14804
14805elif test "$ax_cv_c_float_words_bigendian" = "no"
14806then
14807
14808$as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h
14809
14810else
14811  # Some ARM platforms use a mixed-endian representation for doubles.
14812  # While Python doesn't currently have full support for these platforms
14813  # (see e.g., issue 1762561), we can at least make sure that float <-> string
14814  # conversions work.
14815  # FLOAT_WORDS_BIGENDIAN doesnt actually detect this case, but if it's not big
14816  # or little, then it must be this?
14817
14818$as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h
14819
14820fi
14821
14822# The short float repr introduced in Python 3.1 requires the
14823# correctly-rounded string <-> double conversion functions from
14824# Python/dtoa.c, which in turn require that the FPU uses 53-bit
14825# rounding; this is a problem on x86, where the x87 FPU has a default
14826# rounding precision of 64 bits.  For gcc/x86, we can fix this by
14827# using inline assembler to get and set the x87 FPU control word.
14828
14829# This inline assembler syntax may also work for suncc and icc,
14830# so we try it on all platforms.
14831
14832{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5
14833$as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; }
14834cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14835/* end confdefs.h.  */
14836
14837int
14838main ()
14839{
14840
14841  unsigned short cw;
14842  __asm__ __volatile__ ("fnstcw %0" : "=m" (cw));
14843  __asm__ __volatile__ ("fldcw %0" : : "m" (cw));
14844
14845  ;
14846  return 0;
14847}
14848_ACEOF
14849if ac_fn_c_try_link "$LINENO"; then :
14850  have_gcc_asm_for_x87=yes
14851else
14852  have_gcc_asm_for_x87=no
14853fi
14854rm -f core conftest.err conftest.$ac_objext \
14855    conftest$ac_exeext conftest.$ac_ext
14856{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5
14857$as_echo "$have_gcc_asm_for_x87" >&6; }
14858if test "$have_gcc_asm_for_x87" = yes
14859then
14860
14861$as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h
14862
14863fi
14864
14865{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set mc68881 fpcr" >&5
14866$as_echo_n "checking whether we can use gcc inline assembler to get and set mc68881 fpcr... " >&6; }
14867cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14868/* end confdefs.h.  */
14869
14870int
14871main ()
14872{
14873
14874  unsigned int fpcr;
14875  __asm__ __volatile__ ("fmove.l %%fpcr,%0" : "=g" (fpcr));
14876  __asm__ __volatile__ ("fmove.l %0,%%fpcr" : : "g" (fpcr));
14877
14878  ;
14879  return 0;
14880}
14881_ACEOF
14882if ac_fn_c_try_link "$LINENO"; then :
14883  have_gcc_asm_for_mc68881=yes
14884else
14885  have_gcc_asm_for_mc68881=no
14886fi
14887rm -f core conftest.err conftest.$ac_objext \
14888    conftest$ac_exeext conftest.$ac_ext
14889{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_mc68881" >&5
14890$as_echo "$have_gcc_asm_for_mc68881" >&6; }
14891if test "$have_gcc_asm_for_mc68881" = yes
14892then
14893
14894$as_echo "#define HAVE_GCC_ASM_FOR_MC68881 1" >>confdefs.h
14895
14896fi
14897
14898# Detect whether system arithmetic is subject to x87-style double
14899# rounding issues.  The result of this test has little meaning on non
14900# IEEE 754 platforms.  On IEEE 754, test should return 1 if rounding
14901# mode is round-to-nearest and double rounding issues are present, and
14902# 0 otherwise.  See http://bugs.python.org/issue2937 for more info.
14903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5
14904$as_echo_n "checking for x87-style double rounding... " >&6; }
14905# $BASECFLAGS may affect the result
14906ac_save_cc="$CC"
14907CC="$CC $BASECFLAGS"
14908if test "$cross_compiling" = yes; then :
14909  ac_cv_x87_double_rounding=no
14910else
14911  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14912/* end confdefs.h.  */
14913
14914#include <stdlib.h>
14915#include <math.h>
14916int main() {
14917    volatile double x, y, z;
14918    /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */
14919    x = 0.99999999999999989; /* 1-2**-53 */
14920    y = 1./x;
14921    if (y != 1.)
14922        exit(0);
14923    /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */
14924    x = 1e16;
14925    y = 2.99999;
14926    z = x + y;
14927    if (z != 1e16+4.)
14928        exit(0);
14929    /* both tests show evidence of double rounding */
14930    exit(1);
14931}
14932
14933_ACEOF
14934if ac_fn_c_try_run "$LINENO"; then :
14935  ac_cv_x87_double_rounding=no
14936else
14937  ac_cv_x87_double_rounding=yes
14938fi
14939rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14940  conftest.$ac_objext conftest.beam conftest.$ac_ext
14941fi
14942
14943CC="$ac_save_cc"
14944{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5
14945$as_echo "$ac_cv_x87_double_rounding" >&6; }
14946if test "$ac_cv_x87_double_rounding" = yes
14947then
14948
14949$as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h
14950
14951fi
14952
14953# ************************************
14954# * Check for mathematical functions *
14955# ************************************
14956
14957LIBS_SAVE=$LIBS
14958LIBS="$LIBS $LIBM"
14959
14960for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma
14961do :
14962  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14963ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14964if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14965  cat >>confdefs.h <<_ACEOF
14966#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14967_ACEOF
14968
14969fi
14970done
14971
14972for ac_func in hypot lgamma log1p log2 round tgamma
14973do :
14974  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14975ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14976if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14977  cat >>confdefs.h <<_ACEOF
14978#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14979_ACEOF
14980
14981fi
14982done
14983
14984ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h>
14985"
14986if test "x$ac_cv_have_decl_isinf" = xyes; then :
14987  ac_have_decl=1
14988else
14989  ac_have_decl=0
14990fi
14991
14992cat >>confdefs.h <<_ACEOF
14993#define HAVE_DECL_ISINF $ac_have_decl
14994_ACEOF
14995ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h>
14996"
14997if test "x$ac_cv_have_decl_isnan" = xyes; then :
14998  ac_have_decl=1
14999else
15000  ac_have_decl=0
15001fi
15002
15003cat >>confdefs.h <<_ACEOF
15004#define HAVE_DECL_ISNAN $ac_have_decl
15005_ACEOF
15006ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h>
15007"
15008if test "x$ac_cv_have_decl_isfinite" = xyes; then :
15009  ac_have_decl=1
15010else
15011  ac_have_decl=0
15012fi
15013
15014cat >>confdefs.h <<_ACEOF
15015#define HAVE_DECL_ISFINITE $ac_have_decl
15016_ACEOF
15017
15018
15019# For multiprocessing module, check that sem_open
15020# actually works.  For FreeBSD versions <= 7.2,
15021# the kernel module that provides POSIX semaphores
15022# isn't loaded by default, so an attempt to call
15023# sem_open results in a 'Signal 12' error.
15024{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5
15025$as_echo_n "checking whether POSIX semaphores are enabled... " >&6; }
15026if ${ac_cv_posix_semaphores_enabled+:} false; then :
15027  $as_echo_n "(cached) " >&6
15028else
15029  if test "$cross_compiling" = yes; then :
15030  ac_cv_posix_semaphores_enabled=yes
15031else
15032  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15033/* end confdefs.h.  */
15034
15035#include <unistd.h>
15036#include <fcntl.h>
15037#include <stdio.h>
15038#include <semaphore.h>
15039#include <sys/stat.h>
15040
15041int main(void) {
15042  sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0);
15043  if (a == SEM_FAILED) {
15044    perror("sem_open");
15045    return 1;
15046  }
15047  sem_close(a);
15048  sem_unlink("/autoconf");
15049  return 0;
15050}
15051
15052_ACEOF
15053if ac_fn_c_try_run "$LINENO"; then :
15054  ac_cv_posix_semaphores_enabled=yes
15055else
15056  ac_cv_posix_semaphores_enabled=no
15057fi
15058rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15059  conftest.$ac_objext conftest.beam conftest.$ac_ext
15060fi
15061
15062
15063fi
15064
15065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5
15066$as_echo "$ac_cv_posix_semaphores_enabled" >&6; }
15067if test $ac_cv_posix_semaphores_enabled = no
15068then
15069
15070$as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h
15071
15072fi
15073
15074# Multiprocessing check for broken sem_getvalue
15075{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5
15076$as_echo_n "checking for broken sem_getvalue... " >&6; }
15077if ${ac_cv_broken_sem_getvalue+:} false; then :
15078  $as_echo_n "(cached) " >&6
15079else
15080  if test "$cross_compiling" = yes; then :
15081  ac_cv_broken_sem_getvalue=yes
15082else
15083  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15084/* end confdefs.h.  */
15085
15086#include <unistd.h>
15087#include <fcntl.h>
15088#include <stdio.h>
15089#include <semaphore.h>
15090#include <sys/stat.h>
15091
15092int main(void){
15093  sem_t *a = sem_open("/autocftw", O_CREAT, S_IRUSR|S_IWUSR, 0);
15094  int count;
15095  int res;
15096  if(a==SEM_FAILED){
15097    perror("sem_open");
15098    return 1;
15099
15100  }
15101  res = sem_getvalue(a, &count);
15102  sem_close(a);
15103  sem_unlink("/autocftw");
15104  return res==-1 ? 1 : 0;
15105}
15106
15107_ACEOF
15108if ac_fn_c_try_run "$LINENO"; then :
15109  ac_cv_broken_sem_getvalue=no
15110else
15111  ac_cv_broken_sem_getvalue=yes
15112fi
15113rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15114  conftest.$ac_objext conftest.beam conftest.$ac_ext
15115fi
15116
15117
15118fi
15119
15120{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5
15121$as_echo "$ac_cv_broken_sem_getvalue" >&6; }
15122if test $ac_cv_broken_sem_getvalue = yes
15123then
15124
15125$as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h
15126
15127fi
15128
15129ac_fn_c_check_decl "$LINENO" "RTLD_LAZY" "ac_cv_have_decl_RTLD_LAZY" "#include <dlfcn.h>
15130"
15131if test "x$ac_cv_have_decl_RTLD_LAZY" = xyes; then :
15132  ac_have_decl=1
15133else
15134  ac_have_decl=0
15135fi
15136
15137cat >>confdefs.h <<_ACEOF
15138#define HAVE_DECL_RTLD_LAZY $ac_have_decl
15139_ACEOF
15140ac_fn_c_check_decl "$LINENO" "RTLD_NOW" "ac_cv_have_decl_RTLD_NOW" "#include <dlfcn.h>
15141"
15142if test "x$ac_cv_have_decl_RTLD_NOW" = xyes; then :
15143  ac_have_decl=1
15144else
15145  ac_have_decl=0
15146fi
15147
15148cat >>confdefs.h <<_ACEOF
15149#define HAVE_DECL_RTLD_NOW $ac_have_decl
15150_ACEOF
15151ac_fn_c_check_decl "$LINENO" "RTLD_GLOBAL" "ac_cv_have_decl_RTLD_GLOBAL" "#include <dlfcn.h>
15152"
15153if test "x$ac_cv_have_decl_RTLD_GLOBAL" = xyes; then :
15154  ac_have_decl=1
15155else
15156  ac_have_decl=0
15157fi
15158
15159cat >>confdefs.h <<_ACEOF
15160#define HAVE_DECL_RTLD_GLOBAL $ac_have_decl
15161_ACEOF
15162ac_fn_c_check_decl "$LINENO" "RTLD_LOCAL" "ac_cv_have_decl_RTLD_LOCAL" "#include <dlfcn.h>
15163"
15164if test "x$ac_cv_have_decl_RTLD_LOCAL" = xyes; then :
15165  ac_have_decl=1
15166else
15167  ac_have_decl=0
15168fi
15169
15170cat >>confdefs.h <<_ACEOF
15171#define HAVE_DECL_RTLD_LOCAL $ac_have_decl
15172_ACEOF
15173ac_fn_c_check_decl "$LINENO" "RTLD_NODELETE" "ac_cv_have_decl_RTLD_NODELETE" "#include <dlfcn.h>
15174"
15175if test "x$ac_cv_have_decl_RTLD_NODELETE" = xyes; then :
15176  ac_have_decl=1
15177else
15178  ac_have_decl=0
15179fi
15180
15181cat >>confdefs.h <<_ACEOF
15182#define HAVE_DECL_RTLD_NODELETE $ac_have_decl
15183_ACEOF
15184ac_fn_c_check_decl "$LINENO" "RTLD_NOLOAD" "ac_cv_have_decl_RTLD_NOLOAD" "#include <dlfcn.h>
15185"
15186if test "x$ac_cv_have_decl_RTLD_NOLOAD" = xyes; then :
15187  ac_have_decl=1
15188else
15189  ac_have_decl=0
15190fi
15191
15192cat >>confdefs.h <<_ACEOF
15193#define HAVE_DECL_RTLD_NOLOAD $ac_have_decl
15194_ACEOF
15195ac_fn_c_check_decl "$LINENO" "RTLD_DEEPBIND" "ac_cv_have_decl_RTLD_DEEPBIND" "#include <dlfcn.h>
15196"
15197if test "x$ac_cv_have_decl_RTLD_DEEPBIND" = xyes; then :
15198  ac_have_decl=1
15199else
15200  ac_have_decl=0
15201fi
15202
15203cat >>confdefs.h <<_ACEOF
15204#define HAVE_DECL_RTLD_DEEPBIND $ac_have_decl
15205_ACEOF
15206ac_fn_c_check_decl "$LINENO" "RTLD_MEMBER" "ac_cv_have_decl_RTLD_MEMBER" "#include <dlfcn.h>
15207"
15208if test "x$ac_cv_have_decl_RTLD_MEMBER" = xyes; then :
15209  ac_have_decl=1
15210else
15211  ac_have_decl=0
15212fi
15213
15214cat >>confdefs.h <<_ACEOF
15215#define HAVE_DECL_RTLD_MEMBER $ac_have_decl
15216_ACEOF
15217
15218
15219# determine what size digit to use for Python's longs
15220{ $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5
15221$as_echo_n "checking digit size for Python's longs... " >&6; }
15222# Check whether --enable-big-digits was given.
15223if test "${enable_big_digits+set}" = set; then :
15224  enableval=$enable_big_digits; case $enable_big_digits in
15225yes)
15226  enable_big_digits=30 ;;
15227no)
15228  enable_big_digits=15 ;;
1522915|30)
15230  ;;
15231*)
15232  as_fn_error $? "bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" "$LINENO" 5 ;;
15233esac
15234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5
15235$as_echo "$enable_big_digits" >&6; }
15236
15237cat >>confdefs.h <<_ACEOF
15238#define PYLONG_BITS_IN_DIGIT $enable_big_digits
15239_ACEOF
15240
15241
15242else
15243  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5
15244$as_echo "no value specified" >&6; }
15245fi
15246
15247
15248# check for wchar.h
15249ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default"
15250if test "x$ac_cv_header_wchar_h" = xyes; then :
15251
15252
15253$as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h
15254
15255  wchar_h="yes"
15256
15257else
15258  wchar_h="no"
15259
15260fi
15261
15262
15263
15264# determine wchar_t size
15265if test "$wchar_h" = yes
15266then
15267  # The cast to long int works around a bug in the HP C Compiler
15268# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15269# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15270# This bug is HP SR number 8606223364.
15271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5
15272$as_echo_n "checking size of wchar_t... " >&6; }
15273if ${ac_cv_sizeof_wchar_t+:} false; then :
15274  $as_echo_n "(cached) " >&6
15275else
15276  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t"        "#include <wchar.h>
15277"; then :
15278
15279else
15280  if test "$ac_cv_type_wchar_t" = yes; then
15281     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15282$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
15283as_fn_error 77 "cannot compute sizeof (wchar_t)
15284See \`config.log' for more details" "$LINENO" 5; }
15285   else
15286     ac_cv_sizeof_wchar_t=0
15287   fi
15288fi
15289
15290fi
15291{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5
15292$as_echo "$ac_cv_sizeof_wchar_t" >&6; }
15293
15294
15295
15296cat >>confdefs.h <<_ACEOF
15297#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
15298_ACEOF
15299
15300
15301fi
15302
15303{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5
15304$as_echo_n "checking for UCS-4 tcl... " >&6; }
15305have_ucs4_tcl=no
15306cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15307/* end confdefs.h.  */
15308
15309#include <tcl.h>
15310#if TCL_UTF_MAX != 6
15311# error "NOT UCS4_TCL"
15312#endif
15313int
15314main ()
15315{
15316
15317  ;
15318  return 0;
15319}
15320_ACEOF
15321if ac_fn_c_try_compile "$LINENO"; then :
15322
15323
15324$as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h
15325
15326  have_ucs4_tcl=yes
15327
15328fi
15329rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15330{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5
15331$as_echo "$have_ucs4_tcl" >&6; }
15332
15333# check whether wchar_t is signed or not
15334if test "$wchar_h" = yes
15335then
15336  # check whether wchar_t is signed or not
15337  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5
15338$as_echo_n "checking whether wchar_t is signed... " >&6; }
15339  if ${ac_cv_wchar_t_signed+:} false; then :
15340  $as_echo_n "(cached) " >&6
15341else
15342
15343  if test "$cross_compiling" = yes; then :
15344  ac_cv_wchar_t_signed=yes
15345else
15346  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15347/* end confdefs.h.  */
15348
15349  #include <wchar.h>
15350  int main()
15351  {
15352	/* Success: exit code 0 */
15353        return ((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1);
15354  }
15355
15356_ACEOF
15357if ac_fn_c_try_run "$LINENO"; then :
15358  ac_cv_wchar_t_signed=yes
15359else
15360  ac_cv_wchar_t_signed=no
15361fi
15362rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15363  conftest.$ac_objext conftest.beam conftest.$ac_ext
15364fi
15365
15366fi
15367
15368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5
15369$as_echo "$ac_cv_wchar_t_signed" >&6; }
15370fi
15371
15372{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is usable" >&5
15373$as_echo_n "checking whether wchar_t is usable... " >&6; }
15374# wchar_t is only usable if it maps to an unsigned type
15375if test "$ac_cv_sizeof_wchar_t" -ge 2 \
15376          -a "$ac_cv_wchar_t_signed" = "no"
15377then
15378
15379$as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h
15380
15381  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15382$as_echo "yes" >&6; }
15383else
15384  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15385$as_echo "no" >&6; }
15386fi
15387
15388case $ac_sys_system/$ac_sys_release in
15389SunOS/*)
15390  if test -f /etc/os-release; then
15391    OS_NAME=$(awk -F= '/^NAME=/ {print substr($2,2,length($2)-2)}' /etc/os-release)
15392    if test "x$OS_NAME" = "xOracle Solaris"; then
15393      # bpo-43667: In Oracle Solaris, the internal form of wchar_t in
15394      # non-Unicode locales is not Unicode and hence cannot be used directly.
15395      # https://docs.oracle.com/cd/E37838_01/html/E61053/gmwke.html
15396
15397$as_echo "#define HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION 1" >>confdefs.h
15398
15399    fi
15400  fi
15401  ;;
15402esac
15403
15404# check for endianness
15405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
15406$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
15407if ${ac_cv_c_bigendian+:} false; then :
15408  $as_echo_n "(cached) " >&6
15409else
15410  ac_cv_c_bigendian=unknown
15411    # See if we're dealing with a universal compiler.
15412    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15413/* end confdefs.h.  */
15414#ifndef __APPLE_CC__
15415	       not a universal capable compiler
15416	     #endif
15417	     typedef int dummy;
15418
15419_ACEOF
15420if ac_fn_c_try_compile "$LINENO"; then :
15421
15422	# Check for potential -arch flags.  It is not universal unless
15423	# there are at least two -arch flags with different values.
15424	ac_arch=
15425	ac_prev=
15426	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
15427	 if test -n "$ac_prev"; then
15428	   case $ac_word in
15429	     i?86 | x86_64 | ppc | ppc64)
15430	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
15431		 ac_arch=$ac_word
15432	       else
15433		 ac_cv_c_bigendian=universal
15434		 break
15435	       fi
15436	       ;;
15437	   esac
15438	   ac_prev=
15439	 elif test "x$ac_word" = "x-arch"; then
15440	   ac_prev=arch
15441	 fi
15442       done
15443fi
15444rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15445    if test $ac_cv_c_bigendian = unknown; then
15446      # See if sys/param.h defines the BYTE_ORDER macro.
15447      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15448/* end confdefs.h.  */
15449#include <sys/types.h>
15450	     #include <sys/param.h>
15451
15452int
15453main ()
15454{
15455#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
15456		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
15457		     && LITTLE_ENDIAN)
15458	      bogus endian macros
15459	     #endif
15460
15461  ;
15462  return 0;
15463}
15464_ACEOF
15465if ac_fn_c_try_compile "$LINENO"; then :
15466  # It does; now see whether it defined to BIG_ENDIAN or not.
15467	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15468/* end confdefs.h.  */
15469#include <sys/types.h>
15470		#include <sys/param.h>
15471
15472int
15473main ()
15474{
15475#if BYTE_ORDER != BIG_ENDIAN
15476		 not big endian
15477		#endif
15478
15479  ;
15480  return 0;
15481}
15482_ACEOF
15483if ac_fn_c_try_compile "$LINENO"; then :
15484  ac_cv_c_bigendian=yes
15485else
15486  ac_cv_c_bigendian=no
15487fi
15488rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15489fi
15490rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15491    fi
15492    if test $ac_cv_c_bigendian = unknown; then
15493      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
15494      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15495/* end confdefs.h.  */
15496#include <limits.h>
15497
15498int
15499main ()
15500{
15501#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
15502	      bogus endian macros
15503	     #endif
15504
15505  ;
15506  return 0;
15507}
15508_ACEOF
15509if ac_fn_c_try_compile "$LINENO"; then :
15510  # It does; now see whether it defined to _BIG_ENDIAN or not.
15511	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15512/* end confdefs.h.  */
15513#include <limits.h>
15514
15515int
15516main ()
15517{
15518#ifndef _BIG_ENDIAN
15519		 not big endian
15520		#endif
15521
15522  ;
15523  return 0;
15524}
15525_ACEOF
15526if ac_fn_c_try_compile "$LINENO"; then :
15527  ac_cv_c_bigendian=yes
15528else
15529  ac_cv_c_bigendian=no
15530fi
15531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15532fi
15533rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15534    fi
15535    if test $ac_cv_c_bigendian = unknown; then
15536      # Compile a test program.
15537      if test "$cross_compiling" = yes; then :
15538  # Try to guess by grepping values from an object file.
15539	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15540/* end confdefs.h.  */
15541short int ascii_mm[] =
15542		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15543		short int ascii_ii[] =
15544		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15545		int use_ascii (int i) {
15546		  return ascii_mm[i] + ascii_ii[i];
15547		}
15548		short int ebcdic_ii[] =
15549		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15550		short int ebcdic_mm[] =
15551		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15552		int use_ebcdic (int i) {
15553		  return ebcdic_mm[i] + ebcdic_ii[i];
15554		}
15555		extern int foo;
15556
15557int
15558main ()
15559{
15560return use_ascii (foo) == use_ebcdic (foo);
15561  ;
15562  return 0;
15563}
15564_ACEOF
15565if ac_fn_c_try_compile "$LINENO"; then :
15566  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
15567	      ac_cv_c_bigendian=yes
15568	    fi
15569	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
15570	      if test "$ac_cv_c_bigendian" = unknown; then
15571		ac_cv_c_bigendian=no
15572	      else
15573		# finding both strings is unlikely to happen, but who knows?
15574		ac_cv_c_bigendian=unknown
15575	      fi
15576	    fi
15577fi
15578rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15579else
15580  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15581/* end confdefs.h.  */
15582$ac_includes_default
15583int
15584main ()
15585{
15586
15587	     /* Are we little or big endian?  From Harbison&Steele.  */
15588	     union
15589	     {
15590	       long int l;
15591	       char c[sizeof (long int)];
15592	     } u;
15593	     u.l = 1;
15594	     return u.c[sizeof (long int) - 1] == 1;
15595
15596  ;
15597  return 0;
15598}
15599_ACEOF
15600if ac_fn_c_try_run "$LINENO"; then :
15601  ac_cv_c_bigendian=no
15602else
15603  ac_cv_c_bigendian=yes
15604fi
15605rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15606  conftest.$ac_objext conftest.beam conftest.$ac_ext
15607fi
15608
15609    fi
15610fi
15611{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
15612$as_echo "$ac_cv_c_bigendian" >&6; }
15613 case $ac_cv_c_bigendian in #(
15614   yes)
15615     $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
15616;; #(
15617   no)
15618      ;; #(
15619   universal)
15620
15621$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
15622
15623     ;; #(
15624   *)
15625     as_fn_error $? "unknown endianness
15626 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
15627 esac
15628
15629
15630# ABI version string for Python extension modules.  This appears between the
15631# periods in shared library file names, e.g. foo.<SOABI>.so.  It is calculated
15632# from the following attributes which affect the ABI of this Python build (in
15633# this order):
15634#
15635# * The Python implementation (always 'cpython-' for us)
15636# * The major and minor version numbers
15637# * --with-pydebug (adds a 'd')
15638#
15639# Thus for example, Python 3.2 built with wide unicode, pydebug, and pymalloc,
15640# would get a shared library ABI version tag of 'cpython-32dmu' and shared
15641# libraries would be named 'foo.cpython-32dmu.so'.
15642#
15643# In Python 3.2 and older, --with-wide-unicode added a 'u' flag.
15644# In Python 3.7 and older, --with-pymalloc added a 'm' flag.
15645
15646{ $as_echo "$as_me:${as_lineno-$LINENO}: checking ABIFLAGS" >&5
15647$as_echo_n "checking ABIFLAGS... " >&6; }
15648{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ABIFLAGS" >&5
15649$as_echo "$ABIFLAGS" >&6; }
15650{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5
15651$as_echo_n "checking SOABI... " >&6; }
15652SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS}${PLATFORM_TRIPLET:+-$PLATFORM_TRIPLET}
15653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5
15654$as_echo "$SOABI" >&6; }
15655
15656# Release and debug (Py_DEBUG) ABI are compatible, but not Py_TRACE_REFS ABI
15657if test "$Py_DEBUG" = 'true' -a "$with_trace_refs" != "yes"; then
15658  # Similar to SOABI but remove "d" flag from ABIFLAGS
15659
15660  ALT_SOABI='cpython-'`echo $VERSION | tr -d .``echo $ABIFLAGS | tr -d d`${PLATFORM_TRIPLET:+-$PLATFORM_TRIPLET}
15661
15662cat >>confdefs.h <<_ACEOF
15663#define ALT_SOABI "${ALT_SOABI}"
15664_ACEOF
15665
15666fi
15667
15668
15669EXT_SUFFIX=.${SOABI}${SHLIB_SUFFIX}
15670
15671{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5
15672$as_echo_n "checking LDVERSION... " >&6; }
15673LDVERSION='$(VERSION)$(ABIFLAGS)'
15674{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5
15675$as_echo "$LDVERSION" >&6; }
15676
15677# On Android and Cygwin the shared libraries must be linked with libpython.
15678
15679if test -n "$ANDROID_API_LEVEL" -o "$MACHDEP" = "cygwin"; then
15680  LIBPYTHON="-lpython${VERSION}${ABIFLAGS}"
15681else
15682  LIBPYTHON=''
15683fi
15684
15685
15686
15687BINLIBDEST='$(LIBDIR)/python$(VERSION)'
15688
15689
15690# Check for --with-platlibdir
15691# /usr/$LIDIRNAME/python$VERSION
15692
15693PLATLIBDIR="lib"
15694{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-platlibdir" >&5
15695$as_echo_n "checking for --with-platlibdir... " >&6; }
15696
15697# Check whether --with-platlibdir was given.
15698if test "${with_platlibdir+set}" = set; then :
15699  withval=$with_platlibdir;
15700# ignore 3 options:
15701#   --with-platlibdir
15702#   --with-platlibdir=
15703#   --without-platlibdir
15704if test -n "$withval" -a "$withval" != yes -a "$withval" != no
15705then
15706  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15707$as_echo "yes" >&6; }
15708  PLATLIBDIR="$withval"
15709  BINLIBDEST='${exec_prefix}/${PLATLIBDIR}/python$(VERSION)'
15710else
15711  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15712$as_echo "no" >&6; }
15713fi
15714else
15715  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15716$as_echo "no" >&6; }
15717fi
15718
15719
15720
15721
15722if test x$PLATFORM_TRIPLET = x; then
15723  LIBPL='$(prefix)'"/${PLATLIBDIR}/python${VERSION}/config-${LDVERSION}"
15724else
15725  LIBPL='$(prefix)'"/${PLATLIBDIR}/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
15726fi
15727
15728
15729# Check for --with-wheel-pkg-dir=PATH
15730
15731WHEEL_PKG_DIR=""
15732{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-wheel-pkg-dir" >&5
15733$as_echo_n "checking for --with-wheel-pkg-dir... " >&6; }
15734
15735# Check whether --with-wheel-pkg-dir was given.
15736if test "${with_wheel_pkg_dir+set}" = set; then :
15737  withval=$with_wheel_pkg_dir;
15738if test -n "$withval"; then
15739  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15740$as_echo "yes" >&6; }
15741  WHEEL_PKG_DIR="$withval"
15742else
15743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15744$as_echo "no" >&6; }
15745fi
15746else
15747  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15748$as_echo "no" >&6; }
15749fi
15750
15751
15752# Check whether right shifting a negative integer extends the sign bit
15753# or fills with zeros (like the Cray J90, according to Tim Peters).
15754{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5
15755$as_echo_n "checking whether right shift extends the sign bit... " >&6; }
15756if ${ac_cv_rshift_extends_sign+:} false; then :
15757  $as_echo_n "(cached) " >&6
15758else
15759
15760if test "$cross_compiling" = yes; then :
15761  ac_cv_rshift_extends_sign=yes
15762else
15763  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15764/* end confdefs.h.  */
15765
15766int main()
15767{
15768	return (((-1)>>3 == -1) ? 0 : 1);
15769}
15770
15771_ACEOF
15772if ac_fn_c_try_run "$LINENO"; then :
15773  ac_cv_rshift_extends_sign=yes
15774else
15775  ac_cv_rshift_extends_sign=no
15776fi
15777rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15778  conftest.$ac_objext conftest.beam conftest.$ac_ext
15779fi
15780
15781fi
15782
15783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5
15784$as_echo "$ac_cv_rshift_extends_sign" >&6; }
15785if test "$ac_cv_rshift_extends_sign" = no
15786then
15787
15788$as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h
15789
15790fi
15791
15792# check for getc_unlocked and related locking functions
15793{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5
15794$as_echo_n "checking for getc_unlocked() and friends... " >&6; }
15795if ${ac_cv_have_getc_unlocked+:} false; then :
15796  $as_echo_n "(cached) " >&6
15797else
15798
15799cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15800/* end confdefs.h.  */
15801#include <stdio.h>
15802int
15803main ()
15804{
15805
15806	FILE *f = fopen("/dev/null", "r");
15807	flockfile(f);
15808	getc_unlocked(f);
15809	funlockfile(f);
15810
15811  ;
15812  return 0;
15813}
15814_ACEOF
15815if ac_fn_c_try_link "$LINENO"; then :
15816  ac_cv_have_getc_unlocked=yes
15817else
15818  ac_cv_have_getc_unlocked=no
15819fi
15820rm -f core conftest.err conftest.$ac_objext \
15821    conftest$ac_exeext conftest.$ac_ext
15822fi
15823
15824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5
15825$as_echo "$ac_cv_have_getc_unlocked" >&6; }
15826if test "$ac_cv_have_getc_unlocked" = yes
15827then
15828
15829$as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h
15830
15831fi
15832
15833
15834# Check whether --with-readline was given.
15835if test "${with_readline+set}" = set; then :
15836  withval=$with_readline;
15837else
15838  with_readline=yes
15839fi
15840
15841
15842# check where readline lives
15843py_cv_lib_readline=no
15844# save the value of LIBS so we don't actually link Python with readline
15845LIBS_no_readline=$LIBS
15846
15847if test "$with_readline" != no; then
15848  case "$with_readline" in
15849  editline|edit)
15850    LIBREADLINE=edit
15851
15852$as_echo "#define WITH_EDITLINE 1" >>confdefs.h
15853
15854    ;;
15855  yes|readline)
15856    LIBREADLINE=readline
15857    ;;
15858  *)
15859    as_fn_error $? "proper usage is --with(out)-readline[=editline]" "$LINENO" 5
15860    ;;
15861  esac
15862
15863  # On some systems we need to link readline to a termcap compatible
15864  # library.  NOTE: Keep the precedence of listed libraries synchronised
15865  # with setup.py.
15866  { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5
15867$as_echo_n "checking how to link readline libs... " >&6; }
15868  for py_libtermcap in "" tinfo ncursesw ncurses curses termcap; do
15869    if test -z "$py_libtermcap"; then
15870      READLINE_LIBS="-l$LIBREADLINE"
15871    else
15872      READLINE_LIBS="-l$LIBREADLINE -l$py_libtermcap"
15873    fi
15874    LIBS="$READLINE_LIBS $LIBS_no_readline"
15875    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15876/* end confdefs.h.  */
15877
15878/* Override any GCC internal prototype to avoid an error.
15879   Use char because int might match the return type of a GCC
15880   builtin and then its argument prototype would still apply.  */
15881#ifdef __cplusplus
15882extern "C"
15883#endif
15884char readline ();
15885int
15886main ()
15887{
15888return readline ();
15889  ;
15890  return 0;
15891}
15892_ACEOF
15893if ac_fn_c_try_link "$LINENO"; then :
15894  py_cv_lib_readline=yes
15895fi
15896rm -f core conftest.err conftest.$ac_objext \
15897    conftest$ac_exeext conftest.$ac_ext
15898    if test $py_cv_lib_readline = yes; then
15899      break
15900    fi
15901  done
15902
15903  # Uncomment this line if you want to use READLINE_LIBS in Makefile or scripts
15904  #AC_SUBST([READLINE_LIBS])
15905  if test $py_cv_lib_readline = no; then
15906    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
15907$as_echo "none" >&6; }
15908  else
15909    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5
15910$as_echo "$READLINE_LIBS" >&6; }
15911
15912$as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
15913
15914  fi
15915fi
15916
15917if test "$py_cv_lib_readline" = yes; then
15918  # check for readline 2.2
15919  ac_fn_c_check_decl "$LINENO" "rl_completion_append_character" "ac_cv_have_decl_rl_completion_append_character" "
15920#include <stdio.h> /* Must be first for Gnu Readline */
15921#ifdef WITH_EDITLINE
15922# include <editline/readline.h>
15923#else
15924# include <readline/readline.h>
15925#endif
15926
15927"
15928if test "x$ac_cv_have_decl_rl_completion_append_character" = xyes; then :
15929
15930$as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h
15931
15932fi
15933
15934  ac_fn_c_check_decl "$LINENO" "rl_completion_suppress_append" "ac_cv_have_decl_rl_completion_suppress_append" "
15935#include <stdio.h> /* Must be first for Gnu Readline */
15936#ifdef WITH_EDITLINE
15937# include <editline/readline.h>
15938#else
15939# include <readline/readline.h>
15940#endif
15941
15942"
15943if test "x$ac_cv_have_decl_rl_completion_suppress_append" = xyes; then :
15944
15945$as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h
15946
15947fi
15948
15949
15950  # check for readline 4.0
15951  as_ac_Lib=`$as_echo "ac_cv_lib_$LIBREADLINE''_rl_pre_input_hook" | $as_tr_sh`
15952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -l$LIBREADLINE" >&5
15953$as_echo_n "checking for rl_pre_input_hook in -l$LIBREADLINE... " >&6; }
15954if eval \${$as_ac_Lib+:} false; then :
15955  $as_echo_n "(cached) " >&6
15956else
15957  ac_check_lib_save_LIBS=$LIBS
15958LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
15959cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15960/* end confdefs.h.  */
15961
15962/* Override any GCC internal prototype to avoid an error.
15963   Use char because int might match the return type of a GCC
15964   builtin and then its argument prototype would still apply.  */
15965#ifdef __cplusplus
15966extern "C"
15967#endif
15968char rl_pre_input_hook ();
15969int
15970main ()
15971{
15972return rl_pre_input_hook ();
15973  ;
15974  return 0;
15975}
15976_ACEOF
15977if ac_fn_c_try_link "$LINENO"; then :
15978  eval "$as_ac_Lib=yes"
15979else
15980  eval "$as_ac_Lib=no"
15981fi
15982rm -f core conftest.err conftest.$ac_objext \
15983    conftest$ac_exeext conftest.$ac_ext
15984LIBS=$ac_check_lib_save_LIBS
15985fi
15986eval ac_res=\$$as_ac_Lib
15987	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15988$as_echo "$ac_res" >&6; }
15989if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
15990
15991$as_echo "#define HAVE_RL_PRE_INPUT_HOOK 1" >>confdefs.h
15992
15993fi
15994
15995
15996  # also in 4.0
15997  as_ac_Lib=`$as_echo "ac_cv_lib_$LIBREADLINE''_rl_completion_display_matches_hook" | $as_tr_sh`
15998{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -l$LIBREADLINE" >&5
15999$as_echo_n "checking for rl_completion_display_matches_hook in -l$LIBREADLINE... " >&6; }
16000if eval \${$as_ac_Lib+:} false; then :
16001  $as_echo_n "(cached) " >&6
16002else
16003  ac_check_lib_save_LIBS=$LIBS
16004LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
16005cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16006/* end confdefs.h.  */
16007
16008/* Override any GCC internal prototype to avoid an error.
16009   Use char because int might match the return type of a GCC
16010   builtin and then its argument prototype would still apply.  */
16011#ifdef __cplusplus
16012extern "C"
16013#endif
16014char rl_completion_display_matches_hook ();
16015int
16016main ()
16017{
16018return rl_completion_display_matches_hook ();
16019  ;
16020  return 0;
16021}
16022_ACEOF
16023if ac_fn_c_try_link "$LINENO"; then :
16024  eval "$as_ac_Lib=yes"
16025else
16026  eval "$as_ac_Lib=no"
16027fi
16028rm -f core conftest.err conftest.$ac_objext \
16029    conftest$ac_exeext conftest.$ac_ext
16030LIBS=$ac_check_lib_save_LIBS
16031fi
16032eval ac_res=\$$as_ac_Lib
16033	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16034$as_echo "$ac_res" >&6; }
16035if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
16036
16037$as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h
16038
16039fi
16040
16041
16042  # also in 4.0, but not in editline
16043  as_ac_Lib=`$as_echo "ac_cv_lib_$LIBREADLINE''_rl_resize_terminal" | $as_tr_sh`
16044{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_resize_terminal in -l$LIBREADLINE" >&5
16045$as_echo_n "checking for rl_resize_terminal in -l$LIBREADLINE... " >&6; }
16046if eval \${$as_ac_Lib+:} false; then :
16047  $as_echo_n "(cached) " >&6
16048else
16049  ac_check_lib_save_LIBS=$LIBS
16050LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
16051cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16052/* end confdefs.h.  */
16053
16054/* Override any GCC internal prototype to avoid an error.
16055   Use char because int might match the return type of a GCC
16056   builtin and then its argument prototype would still apply.  */
16057#ifdef __cplusplus
16058extern "C"
16059#endif
16060char rl_resize_terminal ();
16061int
16062main ()
16063{
16064return rl_resize_terminal ();
16065  ;
16066  return 0;
16067}
16068_ACEOF
16069if ac_fn_c_try_link "$LINENO"; then :
16070  eval "$as_ac_Lib=yes"
16071else
16072  eval "$as_ac_Lib=no"
16073fi
16074rm -f core conftest.err conftest.$ac_objext \
16075    conftest$ac_exeext conftest.$ac_ext
16076LIBS=$ac_check_lib_save_LIBS
16077fi
16078eval ac_res=\$$as_ac_Lib
16079	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16080$as_echo "$ac_res" >&6; }
16081if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
16082
16083$as_echo "#define HAVE_RL_RESIZE_TERMINAL 1" >>confdefs.h
16084
16085fi
16086
16087
16088  # check for readline 4.2
16089  as_ac_Lib=`$as_echo "ac_cv_lib_$LIBREADLINE''_rl_completion_matches" | $as_tr_sh`
16090{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -l$LIBREADLINE" >&5
16091$as_echo_n "checking for rl_completion_matches in -l$LIBREADLINE... " >&6; }
16092if eval \${$as_ac_Lib+:} false; then :
16093  $as_echo_n "(cached) " >&6
16094else
16095  ac_check_lib_save_LIBS=$LIBS
16096LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
16097cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16098/* end confdefs.h.  */
16099
16100/* Override any GCC internal prototype to avoid an error.
16101   Use char because int might match the return type of a GCC
16102   builtin and then its argument prototype would still apply.  */
16103#ifdef __cplusplus
16104extern "C"
16105#endif
16106char rl_completion_matches ();
16107int
16108main ()
16109{
16110return rl_completion_matches ();
16111  ;
16112  return 0;
16113}
16114_ACEOF
16115if ac_fn_c_try_link "$LINENO"; then :
16116  eval "$as_ac_Lib=yes"
16117else
16118  eval "$as_ac_Lib=no"
16119fi
16120rm -f core conftest.err conftest.$ac_objext \
16121    conftest$ac_exeext conftest.$ac_ext
16122LIBS=$ac_check_lib_save_LIBS
16123fi
16124eval ac_res=\$$as_ac_Lib
16125	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16126$as_echo "$ac_res" >&6; }
16127if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
16128
16129$as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h
16130
16131fi
16132
16133
16134  # also in readline 4.2
16135  ac_fn_c_check_decl "$LINENO" "rl_catch_signals" "ac_cv_have_decl_rl_catch_signals" "
16136#include <stdio.h> /* Must be first for Gnu Readline */
16137#ifdef WITH_EDITLINE
16138# include <editline/readline.h>
16139#else
16140# include <readline/readline.h>
16141#endif
16142
16143"
16144if test "x$ac_cv_have_decl_rl_catch_signals" = xyes; then :
16145
16146$as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h
16147
16148fi
16149
16150
16151  as_ac_Lib=`$as_echo "ac_cv_lib_$LIBREADLINE''_append_history" | $as_tr_sh`
16152{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for append_history in -l$LIBREADLINE" >&5
16153$as_echo_n "checking for append_history in -l$LIBREADLINE... " >&6; }
16154if eval \${$as_ac_Lib+:} false; then :
16155  $as_echo_n "(cached) " >&6
16156else
16157  ac_check_lib_save_LIBS=$LIBS
16158LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
16159cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16160/* end confdefs.h.  */
16161
16162/* Override any GCC internal prototype to avoid an error.
16163   Use char because int might match the return type of a GCC
16164   builtin and then its argument prototype would still apply.  */
16165#ifdef __cplusplus
16166extern "C"
16167#endif
16168char append_history ();
16169int
16170main ()
16171{
16172return append_history ();
16173  ;
16174  return 0;
16175}
16176_ACEOF
16177if ac_fn_c_try_link "$LINENO"; then :
16178  eval "$as_ac_Lib=yes"
16179else
16180  eval "$as_ac_Lib=no"
16181fi
16182rm -f core conftest.err conftest.$ac_objext \
16183    conftest$ac_exeext conftest.$ac_ext
16184LIBS=$ac_check_lib_save_LIBS
16185fi
16186eval ac_res=\$$as_ac_Lib
16187	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16188$as_echo "$ac_res" >&6; }
16189if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
16190
16191$as_echo "#define HAVE_RL_APPEND_HISTORY 1" >>confdefs.h
16192
16193fi
16194
16195fi
16196
16197# End of readline checks: restore LIBS
16198LIBS=$LIBS_no_readline
16199
16200{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5
16201$as_echo_n "checking for broken nice()... " >&6; }
16202if ${ac_cv_broken_nice+:} false; then :
16203  $as_echo_n "(cached) " >&6
16204else
16205
16206if test "$cross_compiling" = yes; then :
16207  ac_cv_broken_nice=no
16208else
16209  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16210/* end confdefs.h.  */
16211
16212#include <stdlib.h>
16213#include <unistd.h>
16214int main()
16215{
16216	int val1 = nice(1);
16217	if (val1 != -1 && val1 == nice(2))
16218		exit(0);
16219	exit(1);
16220}
16221
16222_ACEOF
16223if ac_fn_c_try_run "$LINENO"; then :
16224  ac_cv_broken_nice=yes
16225else
16226  ac_cv_broken_nice=no
16227fi
16228rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16229  conftest.$ac_objext conftest.beam conftest.$ac_ext
16230fi
16231
16232fi
16233
16234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5
16235$as_echo "$ac_cv_broken_nice" >&6; }
16236if test "$ac_cv_broken_nice" = yes
16237then
16238
16239$as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h
16240
16241fi
16242
16243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5
16244$as_echo_n "checking for broken poll()... " >&6; }
16245if ${ac_cv_broken_poll+:} false; then :
16246  $as_echo_n "(cached) " >&6
16247else
16248  if test "$cross_compiling" = yes; then :
16249  ac_cv_broken_poll=no
16250else
16251  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16252/* end confdefs.h.  */
16253
16254#include <poll.h>
16255#include <unistd.h>
16256
16257int main()
16258{
16259    struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 };
16260    int poll_test;
16261
16262    close (42);
16263
16264    poll_test = poll(&poll_struct, 1, 0);
16265    if (poll_test < 0)
16266        return 0;
16267    else if (poll_test == 0 && poll_struct.revents != POLLNVAL)
16268        return 0;
16269    else
16270        return 1;
16271}
16272
16273_ACEOF
16274if ac_fn_c_try_run "$LINENO"; then :
16275  ac_cv_broken_poll=yes
16276else
16277  ac_cv_broken_poll=no
16278fi
16279rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16280  conftest.$ac_objext conftest.beam conftest.$ac_ext
16281fi
16282
16283fi
16284
16285{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5
16286$as_echo "$ac_cv_broken_poll" >&6; }
16287if test "$ac_cv_broken_poll" = yes
16288then
16289
16290$as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h
16291
16292fi
16293
16294# check tzset(3) exists and works like we expect it to
16295{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5
16296$as_echo_n "checking for working tzset()... " >&6; }
16297if ${ac_cv_working_tzset+:} false; then :
16298  $as_echo_n "(cached) " >&6
16299else
16300
16301if test "$cross_compiling" = yes; then :
16302  ac_cv_working_tzset=no
16303else
16304  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16305/* end confdefs.h.  */
16306
16307#include <stdlib.h>
16308#include <time.h>
16309#include <string.h>
16310
16311#if HAVE_TZNAME
16312extern char *tzname[];
16313#endif
16314
16315int main()
16316{
16317	/* Note that we need to ensure that not only does tzset(3)
16318	   do 'something' with localtime, but it works as documented
16319	   in the library reference and as expected by the test suite.
16320	   This includes making sure that tzname is set properly if
16321	   tm->tm_zone does not exist since it is the alternative way
16322	   of getting timezone info.
16323
16324	   Red Hat 6.2 doesn't understand the southern hemisphere
16325	   after New Year's Day.
16326	*/
16327
16328	time_t groundhogday = 1044144000; /* GMT-based */
16329	time_t midyear = groundhogday + (365 * 24 * 3600 / 2);
16330
16331	putenv("TZ=UTC+0");
16332	tzset();
16333	if (localtime(&groundhogday)->tm_hour != 0)
16334	    exit(1);
16335#if HAVE_TZNAME
16336	/* For UTC, tzname[1] is sometimes "", sometimes "   " */
16337	if (strcmp(tzname[0], "UTC") ||
16338		(tzname[1][0] != 0 && tzname[1][0] != ' '))
16339	    exit(1);
16340#endif
16341
16342	putenv("TZ=EST+5EDT,M4.1.0,M10.5.0");
16343	tzset();
16344	if (localtime(&groundhogday)->tm_hour != 19)
16345	    exit(1);
16346#if HAVE_TZNAME
16347	if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT"))
16348	    exit(1);
16349#endif
16350
16351	putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0");
16352	tzset();
16353	if (localtime(&groundhogday)->tm_hour != 11)
16354	    exit(1);
16355#if HAVE_TZNAME
16356	if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT"))
16357	    exit(1);
16358#endif
16359
16360#if HAVE_STRUCT_TM_TM_ZONE
16361	if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT"))
16362	    exit(1);
16363	if (strcmp(localtime(&midyear)->tm_zone, "AEST"))
16364	    exit(1);
16365#endif
16366
16367	exit(0);
16368}
16369
16370_ACEOF
16371if ac_fn_c_try_run "$LINENO"; then :
16372  ac_cv_working_tzset=yes
16373else
16374  ac_cv_working_tzset=no
16375fi
16376rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16377  conftest.$ac_objext conftest.beam conftest.$ac_ext
16378fi
16379
16380fi
16381
16382{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5
16383$as_echo "$ac_cv_working_tzset" >&6; }
16384if test "$ac_cv_working_tzset" = yes
16385then
16386
16387$as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h
16388
16389fi
16390
16391# Look for subsecond timestamps in struct stat
16392{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5
16393$as_echo_n "checking for tv_nsec in struct stat... " >&6; }
16394if ${ac_cv_stat_tv_nsec+:} false; then :
16395  $as_echo_n "(cached) " >&6
16396else
16397  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16398/* end confdefs.h.  */
16399#include <sys/stat.h>
16400int
16401main ()
16402{
16403
16404struct stat st;
16405st.st_mtim.tv_nsec = 1;
16406
16407  ;
16408  return 0;
16409}
16410_ACEOF
16411if ac_fn_c_try_compile "$LINENO"; then :
16412  ac_cv_stat_tv_nsec=yes
16413else
16414  ac_cv_stat_tv_nsec=no
16415fi
16416rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16417fi
16418
16419{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5
16420$as_echo "$ac_cv_stat_tv_nsec" >&6; }
16421if test "$ac_cv_stat_tv_nsec" = yes
16422then
16423
16424$as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h
16425
16426fi
16427
16428# Look for BSD style subsecond timestamps in struct stat
16429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5
16430$as_echo_n "checking for tv_nsec2 in struct stat... " >&6; }
16431if ${ac_cv_stat_tv_nsec2+:} false; then :
16432  $as_echo_n "(cached) " >&6
16433else
16434  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16435/* end confdefs.h.  */
16436#include <sys/stat.h>
16437int
16438main ()
16439{
16440
16441struct stat st;
16442st.st_mtimespec.tv_nsec = 1;
16443
16444  ;
16445  return 0;
16446}
16447_ACEOF
16448if ac_fn_c_try_compile "$LINENO"; then :
16449  ac_cv_stat_tv_nsec2=yes
16450else
16451  ac_cv_stat_tv_nsec2=no
16452fi
16453rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16454fi
16455
16456{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5
16457$as_echo "$ac_cv_stat_tv_nsec2" >&6; }
16458if test "$ac_cv_stat_tv_nsec2" = yes
16459then
16460
16461$as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h
16462
16463fi
16464
16465# first curses header check
16466ac_save_cppflags="$CPPFLAGS"
16467if test "$cross_compiling" = no; then
16468  CPPFLAGS="$CPPFLAGS -I/usr/include/ncursesw"
16469fi
16470
16471for ac_header in curses.h ncurses.h
16472do :
16473  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
16474ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
16475if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
16476  cat >>confdefs.h <<_ACEOF
16477#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
16478_ACEOF
16479
16480fi
16481
16482done
16483
16484
16485# On Solaris, term.h requires curses.h
16486for ac_header in term.h
16487do :
16488  ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "
16489#ifdef HAVE_CURSES_H
16490#include <curses.h>
16491#endif
16492
16493"
16494if test "x$ac_cv_header_term_h" = xyes; then :
16495  cat >>confdefs.h <<_ACEOF
16496#define HAVE_TERM_H 1
16497_ACEOF
16498
16499fi
16500
16501done
16502
16503
16504# On HP/UX 11.0, mvwdelch is a block with a return statement
16505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5
16506$as_echo_n "checking whether mvwdelch is an expression... " >&6; }
16507if ${ac_cv_mvwdelch_is_expression+:} false; then :
16508  $as_echo_n "(cached) " >&6
16509else
16510  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16511/* end confdefs.h.  */
16512#include <curses.h>
16513int
16514main ()
16515{
16516
16517  int rtn;
16518  rtn = mvwdelch(0,0,0);
16519
16520  ;
16521  return 0;
16522}
16523_ACEOF
16524if ac_fn_c_try_compile "$LINENO"; then :
16525  ac_cv_mvwdelch_is_expression=yes
16526else
16527  ac_cv_mvwdelch_is_expression=no
16528fi
16529rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16530fi
16531
16532{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5
16533$as_echo "$ac_cv_mvwdelch_is_expression" >&6; }
16534
16535if test "$ac_cv_mvwdelch_is_expression" = yes
16536then
16537
16538$as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h
16539
16540fi
16541
16542# Issue #25720: ncurses has introduced the NCURSES_OPAQUE symbol making opaque
16543# structs since version 5.7.  If the macro is defined as zero before including
16544# [n]curses.h, ncurses will expose fields of the structs regardless of the
16545# configuration.
16546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5
16547$as_echo_n "checking whether WINDOW has _flags... " >&6; }
16548if ${ac_cv_window_has_flags+:} false; then :
16549  $as_echo_n "(cached) " >&6
16550else
16551  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16552/* end confdefs.h.  */
16553
16554  #define NCURSES_OPAQUE 0
16555  #include <curses.h>
16556
16557int
16558main ()
16559{
16560
16561  WINDOW *w;
16562  w->_flags = 0;
16563
16564  ;
16565  return 0;
16566}
16567_ACEOF
16568if ac_fn_c_try_compile "$LINENO"; then :
16569  ac_cv_window_has_flags=yes
16570else
16571  ac_cv_window_has_flags=no
16572fi
16573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16574fi
16575
16576{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5
16577$as_echo "$ac_cv_window_has_flags" >&6; }
16578
16579
16580if test "$ac_cv_window_has_flags" = yes
16581then
16582
16583$as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h
16584
16585fi
16586
16587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_pad" >&5
16588$as_echo_n "checking for is_pad... " >&6; }
16589cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16590/* end confdefs.h.  */
16591#include <curses.h>
16592int
16593main ()
16594{
16595
16596#ifndef is_pad
16597void *x=is_pad
16598#endif
16599
16600  ;
16601  return 0;
16602}
16603_ACEOF
16604if ac_fn_c_try_compile "$LINENO"; then :
16605
16606$as_echo "#define HAVE_CURSES_IS_PAD 1" >>confdefs.h
16607
16608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16609$as_echo "yes" >&6; }
16610else
16611  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16612$as_echo "no" >&6; }
16613
16614fi
16615rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16616
16617{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5
16618$as_echo_n "checking for is_term_resized... " >&6; }
16619cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16620/* end confdefs.h.  */
16621#include <curses.h>
16622int
16623main ()
16624{
16625void *x=is_term_resized
16626  ;
16627  return 0;
16628}
16629_ACEOF
16630if ac_fn_c_try_compile "$LINENO"; then :
16631
16632$as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h
16633
16634   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16635$as_echo "yes" >&6; }
16636else
16637  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16638$as_echo "no" >&6; }
16639
16640fi
16641rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16642
16643{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5
16644$as_echo_n "checking for resize_term... " >&6; }
16645cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16646/* end confdefs.h.  */
16647#include <curses.h>
16648int
16649main ()
16650{
16651void *x=resize_term
16652  ;
16653  return 0;
16654}
16655_ACEOF
16656if ac_fn_c_try_compile "$LINENO"; then :
16657
16658$as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h
16659
16660   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16661$as_echo "yes" >&6; }
16662else
16663  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16664$as_echo "no" >&6; }
16665
16666fi
16667rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16668
16669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5
16670$as_echo_n "checking for resizeterm... " >&6; }
16671cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16672/* end confdefs.h.  */
16673#include <curses.h>
16674int
16675main ()
16676{
16677void *x=resizeterm
16678  ;
16679  return 0;
16680}
16681_ACEOF
16682if ac_fn_c_try_compile "$LINENO"; then :
16683
16684$as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h
16685
16686   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16687$as_echo "yes" >&6; }
16688else
16689  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16690$as_echo "no" >&6; }
16691
16692fi
16693rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16694
16695{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for immedok" >&5
16696$as_echo_n "checking for immedok... " >&6; }
16697cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16698/* end confdefs.h.  */
16699#include <curses.h>
16700int
16701main ()
16702{
16703
16704#ifndef immedok
16705void *x=immedok
16706#endif
16707
16708  ;
16709  return 0;
16710}
16711_ACEOF
16712if ac_fn_c_try_compile "$LINENO"; then :
16713
16714$as_echo "#define HAVE_CURSES_IMMEDOK 1" >>confdefs.h
16715
16716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16717$as_echo "yes" >&6; }
16718else
16719  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16720$as_echo "no" >&6; }
16721
16722fi
16723rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16724
16725{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for syncok" >&5
16726$as_echo_n "checking for syncok... " >&6; }
16727cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16728/* end confdefs.h.  */
16729#include <curses.h>
16730int
16731main ()
16732{
16733
16734#ifndef syncok
16735void *x=syncok
16736#endif
16737
16738  ;
16739  return 0;
16740}
16741_ACEOF
16742if ac_fn_c_try_compile "$LINENO"; then :
16743
16744$as_echo "#define HAVE_CURSES_SYNCOK 1" >>confdefs.h
16745
16746   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16747$as_echo "yes" >&6; }
16748else
16749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16750$as_echo "no" >&6; }
16751
16752fi
16753rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16754
16755{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchgat" >&5
16756$as_echo_n "checking for wchgat... " >&6; }
16757cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16758/* end confdefs.h.  */
16759#include <curses.h>
16760int
16761main ()
16762{
16763
16764#ifndef wchgat
16765void *x=wchgat
16766#endif
16767
16768  ;
16769  return 0;
16770}
16771_ACEOF
16772if ac_fn_c_try_compile "$LINENO"; then :
16773
16774$as_echo "#define HAVE_CURSES_WCHGAT 1" >>confdefs.h
16775
16776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16777$as_echo "yes" >&6; }
16778else
16779  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16780$as_echo "no" >&6; }
16781
16782fi
16783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16784
16785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for filter" >&5
16786$as_echo_n "checking for filter... " >&6; }
16787cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16788/* end confdefs.h.  */
16789#include <curses.h>
16790int
16791main ()
16792{
16793
16794#ifndef filter
16795void *x=filter
16796#endif
16797
16798  ;
16799  return 0;
16800}
16801_ACEOF
16802if ac_fn_c_try_compile "$LINENO"; then :
16803
16804$as_echo "#define HAVE_CURSES_FILTER 1" >>confdefs.h
16805
16806   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16807$as_echo "yes" >&6; }
16808else
16809  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16810$as_echo "no" >&6; }
16811
16812fi
16813rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16814
16815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for has_key" >&5
16816$as_echo_n "checking for has_key... " >&6; }
16817cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16818/* end confdefs.h.  */
16819#include <curses.h>
16820int
16821main ()
16822{
16823
16824#ifndef has_key
16825void *x=has_key
16826#endif
16827
16828  ;
16829  return 0;
16830}
16831_ACEOF
16832if ac_fn_c_try_compile "$LINENO"; then :
16833
16834$as_echo "#define HAVE_CURSES_HAS_KEY 1" >>confdefs.h
16835
16836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16837$as_echo "yes" >&6; }
16838else
16839  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16840$as_echo "no" >&6; }
16841
16842fi
16843rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16844
16845{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for typeahead" >&5
16846$as_echo_n "checking for typeahead... " >&6; }
16847cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16848/* end confdefs.h.  */
16849#include <curses.h>
16850int
16851main ()
16852{
16853
16854#ifndef typeahead
16855void *x=typeahead
16856#endif
16857
16858  ;
16859  return 0;
16860}
16861_ACEOF
16862if ac_fn_c_try_compile "$LINENO"; then :
16863
16864$as_echo "#define HAVE_CURSES_TYPEAHEAD 1" >>confdefs.h
16865
16866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16867$as_echo "yes" >&6; }
16868else
16869  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16870$as_echo "no" >&6; }
16871
16872fi
16873rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16874
16875{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for use_env" >&5
16876$as_echo_n "checking for use_env... " >&6; }
16877cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16878/* end confdefs.h.  */
16879#include <curses.h>
16880int
16881main ()
16882{
16883
16884#ifndef use_env
16885void *x=use_env
16886#endif
16887
16888  ;
16889  return 0;
16890}
16891_ACEOF
16892if ac_fn_c_try_compile "$LINENO"; then :
16893
16894$as_echo "#define HAVE_CURSES_USE_ENV 1" >>confdefs.h
16895
16896   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16897$as_echo "yes" >&6; }
16898else
16899  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16900$as_echo "no" >&6; }
16901
16902fi
16903rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16904# last curses configure check
16905CPPFLAGS=$ac_save_cppflags
16906
16907{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for device files" >&5
16908$as_echo "$as_me: checking for device files" >&6;}
16909
16910if test "x$cross_compiling" = xyes; then
16911  if test "${ac_cv_file__dev_ptmx+set}" != set; then
16912    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5
16913$as_echo_n "checking for /dev/ptmx... " >&6; }
16914    { $as_echo "$as_me:${as_lineno-$LINENO}: result: not set" >&5
16915$as_echo "not set" >&6; }
16916    as_fn_error $? "set ac_cv_file__dev_ptmx to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5
16917  fi
16918  if test "${ac_cv_file__dev_ptc+set}" != set; then
16919    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5
16920$as_echo_n "checking for /dev/ptc... " >&6; }
16921    { $as_echo "$as_me:${as_lineno-$LINENO}: result: not set" >&5
16922$as_echo "not set" >&6; }
16923    as_fn_error $? "set ac_cv_file__dev_ptc to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5
16924  fi
16925fi
16926
16927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5
16928$as_echo_n "checking for /dev/ptmx... " >&6; }
16929if ${ac_cv_file__dev_ptmx+:} false; then :
16930  $as_echo_n "(cached) " >&6
16931else
16932  test "$cross_compiling" = yes &&
16933  as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16934if test -r "/dev/ptmx"; then
16935  ac_cv_file__dev_ptmx=yes
16936else
16937  ac_cv_file__dev_ptmx=no
16938fi
16939fi
16940{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptmx" >&5
16941$as_echo "$ac_cv_file__dev_ptmx" >&6; }
16942if test "x$ac_cv_file__dev_ptmx" = xyes; then :
16943
16944fi
16945
16946if test "x$ac_cv_file__dev_ptmx" = xyes; then
16947
16948$as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
16949
16950fi
16951{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5
16952$as_echo_n "checking for /dev/ptc... " >&6; }
16953if ${ac_cv_file__dev_ptc+:} false; then :
16954  $as_echo_n "(cached) " >&6
16955else
16956  test "$cross_compiling" = yes &&
16957  as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16958if test -r "/dev/ptc"; then
16959  ac_cv_file__dev_ptc=yes
16960else
16961  ac_cv_file__dev_ptc=no
16962fi
16963fi
16964{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptc" >&5
16965$as_echo "$ac_cv_file__dev_ptc" >&6; }
16966if test "x$ac_cv_file__dev_ptc" = xyes; then :
16967
16968fi
16969
16970if test "x$ac_cv_file__dev_ptc" = xyes; then
16971
16972$as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h
16973
16974fi
16975
16976if test $ac_sys_system = Darwin
16977then
16978	LIBS="$LIBS -framework CoreFoundation"
16979fi
16980
16981{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5
16982$as_echo_n "checking for %zd printf() format support... " >&6; }
16983if ${ac_cv_have_size_t_format+:} false; then :
16984  $as_echo_n "(cached) " >&6
16985else
16986  if test "$cross_compiling" = yes; then :
16987  ac_cv_have_size_t_format="cross -- assuming yes"
16988
16989else
16990  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16991/* end confdefs.h.  */
16992
16993#include <stdio.h>
16994#include <stddef.h>
16995#include <string.h>
16996
16997#ifdef HAVE_SYS_TYPES_H
16998#include <sys/types.h>
16999#endif
17000
17001#ifdef HAVE_SSIZE_T
17002typedef ssize_t Py_ssize_t;
17003#elif SIZEOF_VOID_P == SIZEOF_LONG
17004typedef long Py_ssize_t;
17005#else
17006typedef int Py_ssize_t;
17007#endif
17008
17009int main()
17010{
17011    char buffer[256];
17012
17013    if(sprintf(buffer, "%zd", (size_t)123) < 0)
17014       	return 1;
17015
17016    if (strcmp(buffer, "123"))
17017	return 1;
17018
17019    if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
17020       	return 1;
17021
17022    if (strcmp(buffer, "-123"))
17023	return 1;
17024
17025    return 0;
17026}
17027
17028_ACEOF
17029if ac_fn_c_try_run "$LINENO"; then :
17030  ac_cv_have_size_t_format=yes
17031else
17032  ac_cv_have_size_t_format=no
17033fi
17034rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17035  conftest.$ac_objext conftest.beam conftest.$ac_ext
17036fi
17037
17038fi
17039{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5
17040$as_echo "$ac_cv_have_size_t_format" >&6; }
17041if test "$ac_cv_have_size_t_format" != no ; then
17042
17043$as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h
17044
17045fi
17046
17047ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
17048#ifdef HAVE_SYS_TYPES_H
17049#include <sys/types.h>
17050#endif
17051#ifdef HAVE_SYS_SOCKET_H
17052#include <sys/socket.h>
17053#endif
17054
17055"
17056if test "x$ac_cv_type_socklen_t" = xyes; then :
17057
17058else
17059
17060$as_echo "#define socklen_t int" >>confdefs.h
17061
17062fi
17063
17064
17065{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5
17066$as_echo_n "checking for broken mbstowcs... " >&6; }
17067if ${ac_cv_broken_mbstowcs+:} false; then :
17068  $as_echo_n "(cached) " >&6
17069else
17070  if test "$cross_compiling" = yes; then :
17071  ac_cv_broken_mbstowcs=no
17072else
17073  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17074/* end confdefs.h.  */
17075
17076#include <stdio.h>
17077#include<stdlib.h>
17078int main() {
17079    size_t len = -1;
17080    const char *str = "text";
17081    len = mbstowcs(NULL, str, 0);
17082    return (len != 4);
17083}
17084
17085_ACEOF
17086if ac_fn_c_try_run "$LINENO"; then :
17087  ac_cv_broken_mbstowcs=no
17088else
17089  ac_cv_broken_mbstowcs=yes
17090fi
17091rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17092  conftest.$ac_objext conftest.beam conftest.$ac_ext
17093fi
17094
17095fi
17096
17097{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5
17098$as_echo "$ac_cv_broken_mbstowcs" >&6; }
17099if test "$ac_cv_broken_mbstowcs" = yes
17100then
17101
17102$as_echo "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h
17103
17104fi
17105
17106# Check for --with-computed-gotos
17107{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5
17108$as_echo_n "checking for --with-computed-gotos... " >&6; }
17109
17110# Check whether --with-computed-gotos was given.
17111if test "${with_computed_gotos+set}" = set; then :
17112  withval=$with_computed_gotos;
17113if test "$withval" = yes
17114then
17115
17116$as_echo "#define USE_COMPUTED_GOTOS 1" >>confdefs.h
17117
17118  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17119$as_echo "yes" >&6; }
17120fi
17121if test "$withval" = no
17122then
17123
17124$as_echo "#define USE_COMPUTED_GOTOS 0" >>confdefs.h
17125
17126  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17127$as_echo "no" >&6; }
17128fi
17129
17130else
17131  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5
17132$as_echo "no value specified" >&6; }
17133fi
17134
17135
17136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5
17137$as_echo_n "checking whether $CC supports computed gotos... " >&6; }
17138if ${ac_cv_computed_gotos+:} false; then :
17139  $as_echo_n "(cached) " >&6
17140else
17141  if test "$cross_compiling" = yes; then :
17142  if test "${with_computed_gotos+set}" = set; then
17143   ac_cv_computed_gotos="$with_computed_gotos -- configured --with(out)-computed-gotos"
17144 else
17145   ac_cv_computed_gotos=no
17146 fi
17147else
17148  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17149/* end confdefs.h.  */
17150
17151int main(int argc, char **argv)
17152{
17153    static void *targets[1] = { &&LABEL1 };
17154    goto LABEL2;
17155LABEL1:
17156    return 0;
17157LABEL2:
17158    goto *targets[0];
17159    return 1;
17160}
17161
17162_ACEOF
17163if ac_fn_c_try_run "$LINENO"; then :
17164  ac_cv_computed_gotos=yes
17165else
17166  ac_cv_computed_gotos=no
17167fi
17168rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17169  conftest.$ac_objext conftest.beam conftest.$ac_ext
17170fi
17171
17172fi
17173
17174{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5
17175$as_echo "$ac_cv_computed_gotos" >&6; }
17176case "$ac_cv_computed_gotos" in yes*)
17177
17178$as_echo "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h
17179
17180esac
17181
17182case $ac_sys_system in
17183AIX*)
17184
17185$as_echo "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h
17186 ;;
17187esac
17188
17189
17190
17191
17192for h in `(cd $srcdir;echo Python/thread_*.h)`
17193do
17194  THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
17195done
17196
17197
17198SRCDIRS="Parser Objects Python Modules Modules/_io Programs"
17199{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5
17200$as_echo_n "checking for build directories... " >&6; }
17201for dir in $SRCDIRS; do
17202    if test ! -d $dir; then
17203        mkdir $dir
17204    fi
17205done
17206{ $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
17207$as_echo "done" >&6; }
17208
17209# Availability of -O2:
17210{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -O2" >&5
17211$as_echo_n "checking for -O2... " >&6; }
17212saved_cflags="$CFLAGS"
17213CFLAGS="-O2"
17214cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17215/* end confdefs.h.  */
17216
17217int
17218main ()
17219{
17220
17221
17222  ;
17223  return 0;
17224}
17225_ACEOF
17226if ac_fn_c_try_compile "$LINENO"; then :
17227  have_O2=yes
17228else
17229  have_O2=no
17230fi
17231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17232{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_O2" >&5
17233$as_echo "$have_O2" >&6; }
17234CFLAGS="$saved_cflags"
17235
17236# _FORTIFY_SOURCE wrappers for memmove and bcopy are incorrect:
17237# http://sourceware.org/ml/libc-alpha/2010-12/msg00009.html
17238{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glibc _FORTIFY_SOURCE/memmove bug" >&5
17239$as_echo_n "checking for glibc _FORTIFY_SOURCE/memmove bug... " >&6; }
17240saved_cflags="$CFLAGS"
17241CFLAGS="-O2 -D_FORTIFY_SOURCE=2"
17242if test "$have_O2" = no; then
17243    CFLAGS=""
17244fi
17245if test "$cross_compiling" = yes; then :
17246  have_glibc_memmove_bug=undefined
17247else
17248  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17249/* end confdefs.h.  */
17250
17251#include <stdio.h>
17252#include <stdlib.h>
17253#include <string.h>
17254void foo(void *p, void *q) { memmove(p, q, 19); }
17255int main() {
17256  char a[32] = "123456789000000000";
17257  foo(&a[9], a);
17258  if (strcmp(a, "123456789123456789000000000") != 0)
17259    return 1;
17260  foo(a, &a[9]);
17261  if (strcmp(a, "123456789000000000") != 0)
17262    return 1;
17263  return 0;
17264}
17265
17266_ACEOF
17267if ac_fn_c_try_run "$LINENO"; then :
17268  have_glibc_memmove_bug=no
17269else
17270  have_glibc_memmove_bug=yes
17271fi
17272rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17273  conftest.$ac_objext conftest.beam conftest.$ac_ext
17274fi
17275
17276CFLAGS="$saved_cflags"
17277{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_glibc_memmove_bug" >&5
17278$as_echo "$have_glibc_memmove_bug" >&6; }
17279if test "$have_glibc_memmove_bug" = yes; then
17280
17281$as_echo "#define HAVE_GLIBC_MEMMOVE_BUG 1" >>confdefs.h
17282
17283fi
17284
17285if test "$have_gcc_asm_for_x87" = yes; then
17286    # Some versions of gcc miscompile inline asm:
17287    # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46491
17288    # http://gcc.gnu.org/ml/gcc/2010-11/msg00366.html
17289    case $CC in
17290        *gcc*)
17291            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc ipa-pure-const bug" >&5
17292$as_echo_n "checking for gcc ipa-pure-const bug... " >&6; }
17293            saved_cflags="$CFLAGS"
17294            CFLAGS="-O2"
17295            if test "$cross_compiling" = yes; then :
17296  have_ipa_pure_const_bug=undefined
17297else
17298  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17299/* end confdefs.h.  */
17300
17301            __attribute__((noinline)) int
17302            foo(int *p) {
17303              int r;
17304              asm ( "movl \$6, (%1)\n\t"
17305                    "xorl %0, %0\n\t"
17306                    : "=r" (r) : "r" (p) : "memory"
17307              );
17308              return r;
17309            }
17310            int main() {
17311              int p = 8;
17312              if ((foo(&p) ? : p) != 6)
17313                return 1;
17314              return 0;
17315            }
17316
17317_ACEOF
17318if ac_fn_c_try_run "$LINENO"; then :
17319  have_ipa_pure_const_bug=no
17320else
17321  have_ipa_pure_const_bug=yes
17322fi
17323rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17324  conftest.$ac_objext conftest.beam conftest.$ac_ext
17325fi
17326
17327            CFLAGS="$saved_cflags"
17328            { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ipa_pure_const_bug" >&5
17329$as_echo "$have_ipa_pure_const_bug" >&6; }
17330            if test "$have_ipa_pure_const_bug" = yes; then
17331
17332$as_echo "#define HAVE_IPA_PURE_CONST_BUG 1" >>confdefs.h
17333
17334            fi
17335        ;;
17336    esac
17337fi
17338
17339# Check for stdatomic.h
17340{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdatomic.h" >&5
17341$as_echo_n "checking for stdatomic.h... " >&6; }
17342cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17343/* end confdefs.h.  */
17344
17345
17346    #include <stdatomic.h>
17347    atomic_int int_var;
17348    atomic_uintptr_t uintptr_var;
17349    int main() {
17350      atomic_store_explicit(&int_var, 5, memory_order_relaxed);
17351      atomic_store_explicit(&uintptr_var, 0, memory_order_relaxed);
17352      int loaded_value = atomic_load_explicit(&int_var, memory_order_seq_cst);
17353      return 0;
17354    }
17355
17356
17357_ACEOF
17358if ac_fn_c_try_link "$LINENO"; then :
17359  have_stdatomic_h=yes
17360else
17361  have_stdatomic_h=no
17362fi
17363rm -f core conftest.err conftest.$ac_objext \
17364    conftest$ac_exeext conftest.$ac_ext
17365
17366{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_stdatomic_h" >&5
17367$as_echo "$have_stdatomic_h" >&6; }
17368
17369if test "$have_stdatomic_h" = yes; then
17370
17371$as_echo "#define HAVE_STD_ATOMIC 1" >>confdefs.h
17372
17373fi
17374
17375# Check for GCC >= 4.7 and clang __atomic builtin functions
17376{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic_load_n and __atomic_store_n functions" >&5
17377$as_echo_n "checking for builtin __atomic_load_n and __atomic_store_n functions... " >&6; }
17378cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17379/* end confdefs.h.  */
17380
17381
17382    int val;
17383    int main() {
17384      __atomic_store_n(&val, 1, __ATOMIC_SEQ_CST);
17385      (void)__atomic_load_n(&val, __ATOMIC_SEQ_CST);
17386      return 0;
17387    }
17388
17389
17390_ACEOF
17391if ac_fn_c_try_link "$LINENO"; then :
17392  have_builtin_atomic=yes
17393else
17394  have_builtin_atomic=no
17395fi
17396rm -f core conftest.err conftest.$ac_objext \
17397    conftest$ac_exeext conftest.$ac_ext
17398
17399{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_builtin_atomic" >&5
17400$as_echo "$have_builtin_atomic" >&6; }
17401
17402if test "$have_builtin_atomic" = yes; then
17403
17404$as_echo "#define HAVE_BUILTIN_ATOMIC 1" >>confdefs.h
17405
17406fi
17407
17408# ensurepip option
17409{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ensurepip" >&5
17410$as_echo_n "checking for ensurepip... " >&6; }
17411
17412# Check whether --with-ensurepip was given.
17413if test "${with_ensurepip+set}" = set; then :
17414  withval=$with_ensurepip;
17415else
17416  with_ensurepip=upgrade
17417fi
17418
17419case $with_ensurepip in #(
17420  yes|upgrade) :
17421    ENSUREPIP=upgrade ;; #(
17422  install) :
17423    ENSUREPIP=install ;; #(
17424  no) :
17425    ENSUREPIP=no ;; #(
17426  *) :
17427    as_fn_error $? "--with-ensurepip=upgrade|install|no" "$LINENO" 5 ;;
17428esac
17429{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENSUREPIP" >&5
17430$as_echo "$ENSUREPIP" >&6; }
17431
17432
17433# check if the dirent structure of a d_type field and DT_UNKNOWN is defined
17434{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the dirent structure of a d_type field" >&5
17435$as_echo_n "checking if the dirent structure of a d_type field... " >&6; }
17436cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17437/* end confdefs.h.  */
17438
17439
17440    #include <dirent.h>
17441
17442    int main() {
17443      struct dirent entry;
17444      return entry.d_type == DT_UNKNOWN;
17445    }
17446
17447
17448_ACEOF
17449if ac_fn_c_try_link "$LINENO"; then :
17450  have_dirent_d_type=yes
17451else
17452  have_dirent_d_type=no
17453fi
17454rm -f core conftest.err conftest.$ac_objext \
17455    conftest$ac_exeext conftest.$ac_ext
17456{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_dirent_d_type" >&5
17457$as_echo "$have_dirent_d_type" >&6; }
17458
17459if test "$have_dirent_d_type" = yes; then
17460
17461$as_echo "#define HAVE_DIRENT_D_TYPE 1" >>confdefs.h
17462
17463fi
17464
17465# check if the Linux getrandom() syscall is available
17466{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the Linux getrandom() syscall" >&5
17467$as_echo_n "checking for the Linux getrandom() syscall... " >&6; }
17468cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17469/* end confdefs.h.  */
17470
17471
17472    #include <unistd.h>
17473    #include <sys/syscall.h>
17474    #include <linux/random.h>
17475
17476    int main() {
17477        char buffer[1];
17478        const size_t buflen = sizeof(buffer);
17479        const int flags = GRND_NONBLOCK;
17480        /* ignore the result, Python checks for ENOSYS and EAGAIN at runtime */
17481        (void)syscall(SYS_getrandom, buffer, buflen, flags);
17482        return 0;
17483    }
17484
17485
17486_ACEOF
17487if ac_fn_c_try_link "$LINENO"; then :
17488  have_getrandom_syscall=yes
17489else
17490  have_getrandom_syscall=no
17491fi
17492rm -f core conftest.err conftest.$ac_objext \
17493    conftest$ac_exeext conftest.$ac_ext
17494{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getrandom_syscall" >&5
17495$as_echo "$have_getrandom_syscall" >&6; }
17496
17497if test "$have_getrandom_syscall" = yes; then
17498
17499$as_echo "#define HAVE_GETRANDOM_SYSCALL 1" >>confdefs.h
17500
17501fi
17502
17503# check if the getrandom() function is available
17504# the test was written for the Solaris function of <sys/random.h>
17505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for the getrandom() function" >&5
17506$as_echo_n "checking for the getrandom() function... " >&6; }
17507cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17508/* end confdefs.h.  */
17509
17510
17511    #include <sys/random.h>
17512
17513    int main() {
17514        char buffer[1];
17515        const size_t buflen = sizeof(buffer);
17516        const int flags = 0;
17517        /* ignore the result, Python checks for ENOSYS at runtime */
17518        (void)getrandom(buffer, buflen, flags);
17519        return 0;
17520    }
17521
17522
17523_ACEOF
17524if ac_fn_c_try_link "$LINENO"; then :
17525  have_getrandom=yes
17526else
17527  have_getrandom=no
17528fi
17529rm -f core conftest.err conftest.$ac_objext \
17530    conftest$ac_exeext conftest.$ac_ext
17531{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getrandom" >&5
17532$as_echo "$have_getrandom" >&6; }
17533
17534if test "$have_getrandom" = yes; then
17535
17536$as_echo "#define HAVE_GETRANDOM 1" >>confdefs.h
17537
17538fi
17539
17540# checks for POSIX shared memory, used by Modules/_multiprocessing/posixshmem.c
17541# shm_* may only be available if linking against librt
17542save_LIBS="$LIBS"
17543save_includes_default="$ac_includes_default"
17544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_open" >&5
17545$as_echo_n "checking for library containing shm_open... " >&6; }
17546if ${ac_cv_search_shm_open+:} false; then :
17547  $as_echo_n "(cached) " >&6
17548else
17549  ac_func_search_save_LIBS=$LIBS
17550cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17551/* end confdefs.h.  */
17552
17553/* Override any GCC internal prototype to avoid an error.
17554   Use char because int might match the return type of a GCC
17555   builtin and then its argument prototype would still apply.  */
17556#ifdef __cplusplus
17557extern "C"
17558#endif
17559char shm_open ();
17560int
17561main ()
17562{
17563return shm_open ();
17564  ;
17565  return 0;
17566}
17567_ACEOF
17568for ac_lib in '' rt; do
17569  if test -z "$ac_lib"; then
17570    ac_res="none required"
17571  else
17572    ac_res=-l$ac_lib
17573    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17574  fi
17575  if ac_fn_c_try_link "$LINENO"; then :
17576  ac_cv_search_shm_open=$ac_res
17577fi
17578rm -f core conftest.err conftest.$ac_objext \
17579    conftest$ac_exeext
17580  if ${ac_cv_search_shm_open+:} false; then :
17581  break
17582fi
17583done
17584if ${ac_cv_search_shm_open+:} false; then :
17585
17586else
17587  ac_cv_search_shm_open=no
17588fi
17589rm conftest.$ac_ext
17590LIBS=$ac_func_search_save_LIBS
17591fi
17592{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_open" >&5
17593$as_echo "$ac_cv_search_shm_open" >&6; }
17594ac_res=$ac_cv_search_shm_open
17595if test "$ac_res" != no; then :
17596  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17597
17598fi
17599
17600if test "$ac_cv_search_shm_open" = "-lrt"; then
17601
17602$as_echo "#define SHM_NEEDS_LIBRT 1" >>confdefs.h
17603
17604fi
17605for ac_header in sys/mman.h
17606do :
17607  ac_fn_c_check_header_mongrel "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
17608if test "x$ac_cv_header_sys_mman_h" = xyes; then :
17609  cat >>confdefs.h <<_ACEOF
17610#define HAVE_SYS_MMAN_H 1
17611_ACEOF
17612
17613fi
17614
17615done
17616
17617# temporarily override ac_includes_default for AC_CHECK_FUNCS below
17618ac_includes_default="\
17619${ac_includes_default}
17620#ifndef __cplusplus
17621#  ifdef HAVE_SYS_MMAN_H
17622#    include <sys/mman.h>
17623#  endif
17624#endif
17625"
17626for ac_func in shm_open shm_unlink
17627do :
17628  as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17629ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17630if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
17631  cat >>confdefs.h <<_ACEOF
17632#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17633_ACEOF
17634
17635fi
17636done
17637
17638# we don't want to link with librt always, restore LIBS
17639LIBS="$save_LIBS"
17640ac_includes_default="$save_includes_default"
17641
17642# Check for usable OpenSSL
17643
17644    found=false
17645
17646# Check whether --with-openssl was given.
17647if test "${with_openssl+set}" = set; then :
17648  withval=$with_openssl;
17649            case "$withval" in
17650            "" | y | ye | yes | n | no)
17651            as_fn_error $? "Invalid --with-openssl value" "$LINENO" 5
17652              ;;
17653            *) ssldirs="$withval"
17654              ;;
17655            esac
17656
17657else
17658
17659            # if pkg-config is installed and openssl has installed a .pc file,
17660            # then use that information and don't search ssldirs
17661            if test -n "$ac_tool_prefix"; then
17662  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
17663set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
17664{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17665$as_echo_n "checking for $ac_word... " >&6; }
17666if ${ac_cv_prog_PKG_CONFIG+:} false; then :
17667  $as_echo_n "(cached) " >&6
17668else
17669  if test -n "$PKG_CONFIG"; then
17670  ac_cv_prog_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test.
17671else
17672as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17673for as_dir in $PATH
17674do
17675  IFS=$as_save_IFS
17676  test -z "$as_dir" && as_dir=.
17677    for ac_exec_ext in '' $ac_executable_extensions; do
17678  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17679    ac_cv_prog_PKG_CONFIG="${ac_tool_prefix}pkg-config"
17680    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17681    break 2
17682  fi
17683done
17684  done
17685IFS=$as_save_IFS
17686
17687fi
17688fi
17689PKG_CONFIG=$ac_cv_prog_PKG_CONFIG
17690if test -n "$PKG_CONFIG"; then
17691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
17692$as_echo "$PKG_CONFIG" >&6; }
17693else
17694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17695$as_echo "no" >&6; }
17696fi
17697
17698
17699fi
17700if test -z "$ac_cv_prog_PKG_CONFIG"; then
17701  ac_ct_PKG_CONFIG=$PKG_CONFIG
17702  # Extract the first word of "pkg-config", so it can be a program name with args.
17703set dummy pkg-config; ac_word=$2
17704{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17705$as_echo_n "checking for $ac_word... " >&6; }
17706if ${ac_cv_prog_ac_ct_PKG_CONFIG+:} false; then :
17707  $as_echo_n "(cached) " >&6
17708else
17709  if test -n "$ac_ct_PKG_CONFIG"; then
17710  ac_cv_prog_ac_ct_PKG_CONFIG="$ac_ct_PKG_CONFIG" # Let the user override the test.
17711else
17712as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17713for as_dir in $PATH
17714do
17715  IFS=$as_save_IFS
17716  test -z "$as_dir" && as_dir=.
17717    for ac_exec_ext in '' $ac_executable_extensions; do
17718  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17719    ac_cv_prog_ac_ct_PKG_CONFIG="pkg-config"
17720    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17721    break 2
17722  fi
17723done
17724  done
17725IFS=$as_save_IFS
17726
17727fi
17728fi
17729ac_ct_PKG_CONFIG=$ac_cv_prog_ac_ct_PKG_CONFIG
17730if test -n "$ac_ct_PKG_CONFIG"; then
17731  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PKG_CONFIG" >&5
17732$as_echo "$ac_ct_PKG_CONFIG" >&6; }
17733else
17734  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17735$as_echo "no" >&6; }
17736fi
17737
17738  if test "x$ac_ct_PKG_CONFIG" = x; then
17739    PKG_CONFIG=""
17740  else
17741    case $cross_compiling:$ac_tool_warned in
17742yes:)
17743{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17744$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17745ac_tool_warned=yes ;;
17746esac
17747    PKG_CONFIG=$ac_ct_PKG_CONFIG
17748  fi
17749else
17750  PKG_CONFIG="$ac_cv_prog_PKG_CONFIG"
17751fi
17752
17753            if test x"$PKG_CONFIG" != x""; then
17754                OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
17755                if test $? = 0; then
17756                    OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
17757                    OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
17758                    found=true
17759                fi
17760            fi
17761
17762            # no such luck; use some default ssldirs
17763            if ! $found; then
17764                ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
17765            fi
17766
17767
17768fi
17769
17770
17771
17772    # note that we #include <openssl/foo.h>, so the OpenSSL headers have to be in
17773    # an 'openssl' subdirectory
17774
17775    if ! $found; then
17776        OPENSSL_INCLUDES=
17777        for ssldir in $ssldirs; do
17778            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl/ssl.h in $ssldir" >&5
17779$as_echo_n "checking for openssl/ssl.h in $ssldir... " >&6; }
17780            if test -f "$ssldir/include/openssl/ssl.h"; then
17781                OPENSSL_INCLUDES="-I$ssldir/include"
17782                OPENSSL_LDFLAGS="-L$ssldir/lib"
17783                OPENSSL_LIBS="-lssl -lcrypto"
17784                found=true
17785                { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17786$as_echo "yes" >&6; }
17787                break
17788            else
17789                { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17790$as_echo "no" >&6; }
17791            fi
17792        done
17793
17794        # if the file wasn't found, well, go ahead and try the link anyway -- maybe
17795        # it will just work!
17796    fi
17797
17798    # try the preprocessor and linker with our new flags,
17799    # being careful not to pollute the global LIBS, LDFLAGS, and CPPFLAGS
17800
17801    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiling and linking against OpenSSL works" >&5
17802$as_echo_n "checking whether compiling and linking against OpenSSL works... " >&6; }
17803    echo "Trying link with OPENSSL_LDFLAGS=$OPENSSL_LDFLAGS;" \
17804        "OPENSSL_LIBS=$OPENSSL_LIBS; OPENSSL_INCLUDES=$OPENSSL_INCLUDES" >&5
17805
17806    save_LIBS="$LIBS"
17807    save_LDFLAGS="$LDFLAGS"
17808    save_CPPFLAGS="$CPPFLAGS"
17809    LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS"
17810    LIBS="$OPENSSL_LIBS $LIBS"
17811    CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS"
17812    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17813/* end confdefs.h.  */
17814#include <openssl/ssl.h>
17815int
17816main ()
17817{
17818SSL_new(NULL)
17819  ;
17820  return 0;
17821}
17822_ACEOF
17823if ac_fn_c_try_link "$LINENO"; then :
17824
17825            { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17826$as_echo "yes" >&6; }
17827            have_openssl=yes
17828
17829else
17830
17831            { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17832$as_echo "no" >&6; }
17833            have_openssl=no
17834
17835fi
17836rm -f core conftest.err conftest.$ac_objext \
17837    conftest$ac_exeext conftest.$ac_ext
17838    CPPFLAGS="$save_CPPFLAGS"
17839    LDFLAGS="$save_LDFLAGS"
17840    LIBS="$save_LIBS"
17841
17842
17843
17844
17845
17846
17847# rpath to libssl and libcrypto
17848{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-openssl-rpath" >&5
17849$as_echo_n "checking for --with-openssl-rpath... " >&6; }
17850
17851# Check whether --with-openssl-rpath was given.
17852if test "${with_openssl_rpath+set}" = set; then :
17853  withval=$with_openssl_rpath;
17854else
17855  with_openssl_rpath=no
17856
17857fi
17858
17859case $with_openssl_rpath in #(
17860  auto|yes) :
17861    OPENSSL_RPATH=auto ;; #(
17862  no) :
17863    OPENSSL_RPATH= ;; #(
17864  *) :
17865    if test -d "$with_openssl_rpath"; then :
17866  OPENSSL_RPATH="$with_openssl_rpath"
17867else
17868  as_fn_error $? "--with-openssl-rpath \"$with_openssl_rpath\" is not a directory" "$LINENO" 5
17869fi
17870
17871 ;;
17872esac
17873{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENSSL_RPATH" >&5
17874$as_echo "$OPENSSL_RPATH" >&6; }
17875
17876
17877# check if OpenSSL libraries work as expected
17878{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL provides required APIs" >&5
17879$as_echo_n "checking whether OpenSSL provides required APIs... " >&6; }
17880save_LIBS="$LIBS"
17881save_CFLAGS="$CFLAGS"
17882save_LDFLAGS="$LDFLAGS"
17883LIBS="$LIBS $OPENSSL_LIBS"
17884CFLAGS="$CFLAGS_NODIST $OPENSSL_INCLUDES"
17885LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS"
17886
17887cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17888/* end confdefs.h.  */
17889
17890#include <openssl/opensslv.h>
17891#include <openssl/evp.h>
17892#include <openssl/ssl.h>
17893
17894#if OPENSSL_VERSION_NUMBER < 0x10101000L
17895#error "OpenSSL >= 1.1.1 is required"
17896#endif
17897
17898static void keylog_cb(const SSL *ssl, const char *line) {}
17899
17900int
17901main ()
17902{
17903
17904/* SSL APIs */
17905SSL_CTX *ctx = SSL_CTX_new(TLS_client_method());
17906SSL_CTX_set_keylog_callback(ctx, keylog_cb);
17907SSL *ssl = SSL_new(ctx);
17908X509_VERIFY_PARAM *param = SSL_get0_param(ssl);
17909X509_VERIFY_PARAM_set1_host(param, "python.org", 0);
17910SSL_free(ssl);
17911SSL_CTX_free(ctx);
17912
17913/* hashlib APIs */
17914OBJ_nid2sn(NID_md5);
17915OBJ_nid2sn(NID_sha1);
17916OBJ_nid2sn(NID_sha3_512);
17917OBJ_nid2sn(NID_blake2b512);
17918EVP_PBE_scrypt(NULL, 0, NULL, 0, 2, 8, 1, 0, NULL, 0);
17919
17920  ;
17921  return 0;
17922}
17923_ACEOF
17924if ac_fn_c_try_link "$LINENO"; then :
17925  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17926$as_echo "yes" >&6; }
17927else
17928  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17929$as_echo "no" >&6; }
17930fi
17931rm -f core conftest.err conftest.$ac_objext \
17932    conftest$ac_exeext conftest.$ac_ext
17933LIBS="$save_LIBS"
17934CFLAGS="$save_CFLAGS"
17935LDFLAGS="$save_LDFLAGS"
17936
17937# ssl module default cipher suite string
17938
17939
17940
17941{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-ssl-default-suites" >&5
17942$as_echo_n "checking for --with-ssl-default-suites... " >&6; }
17943
17944# Check whether --with-ssl-default-suites was given.
17945if test "${with_ssl_default_suites+set}" = set; then :
17946  withval=$with_ssl_default_suites;
17947{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
17948$as_echo "$withval" >&6; }
17949case "$withval" in
17950    python)
17951        $as_echo "#define PY_SSL_DEFAULT_CIPHERS 1" >>confdefs.h
17952
17953        ;;
17954    openssl)
17955        $as_echo "#define PY_SSL_DEFAULT_CIPHERS 2" >>confdefs.h
17956
17957        ;;
17958    *)
17959        $as_echo "#define PY_SSL_DEFAULT_CIPHERS 0" >>confdefs.h
17960
17961        cat >>confdefs.h <<_ACEOF
17962#define PY_SSL_DEFAULT_CIPHER_STRING "$withval"
17963_ACEOF
17964
17965        ;;
17966esac
17967
17968else
17969
17970{ $as_echo "$as_me:${as_lineno-$LINENO}: result: python" >&5
17971$as_echo "python" >&6; }
17972$as_echo "#define PY_SSL_DEFAULT_CIPHERS 1" >>confdefs.h
17973
17974
17975fi
17976
17977
17978# builtin hash modules
17979default_hashlib_hashes="md5,sha1,sha256,sha512,sha3,blake2"
17980
17981$as_echo "#define PY_BUILTIN_HASHLIB_HASHES /**/" >>confdefs.h
17982
17983{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-builtin-hashlib-hashes" >&5
17984$as_echo_n "checking for --with-builtin-hashlib-hashes... " >&6; }
17985
17986# Check whether --with-builtin-hashlib-hashes was given.
17987if test "${with_builtin_hashlib_hashes+set}" = set; then :
17988  withval=$with_builtin_hashlib_hashes;
17989case "$withval" in
17990    yes)
17991        withval=$default_hashlib_hashes
17992        ;;
17993    no)
17994        withval=""
17995        ;;
17996esac
17997{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
17998$as_echo "$withval" >&6; }
17999cat >>confdefs.h <<_ACEOF
18000#define PY_BUILTIN_HASHLIB_HASHES "$withval"
18001_ACEOF
18002
18003
18004else
18005
18006{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $default_hashlib_hashes" >&5
18007$as_echo "$default_hashlib_hashes" >&6; };
18008cat >>confdefs.h <<_ACEOF
18009#define PY_BUILTIN_HASHLIB_HASHES "$default_hashlib_hashes"
18010_ACEOF
18011
18012
18013fi
18014
18015
18016# --with-experimental-isolated-subinterpreters
18017
18018{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-experimental-isolated-subinterpreters" >&5
18019$as_echo_n "checking for --with-experimental-isolated-subinterpreters... " >&6; }
18020
18021# Check whether --with-experimental-isolated-subinterpreters was given.
18022if test "${with_experimental_isolated_subinterpreters+set}" = set; then :
18023  withval=$with_experimental_isolated_subinterpreters;
18024if test "$withval" != no
18025then
18026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18027$as_echo "yes" >&6; };
18028  $as_echo "#define EXPERIMENTAL_ISOLATED_SUBINTERPRETERS 1" >>confdefs.h
18029
18030else
18031  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18032$as_echo "no" >&6; };
18033fi
18034else
18035  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18036$as_echo "no" >&6; }
18037fi
18038
18039
18040# --with-static-libpython
18041STATIC_LIBPYTHON=1
18042{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-static-libpython" >&5
18043$as_echo_n "checking for --with-static-libpython... " >&6; }
18044
18045# Check whether --with-static-libpython was given.
18046if test "${with_static_libpython+set}" = set; then :
18047  withval=$with_static_libpython;
18048if test "$withval" = no
18049then
18050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18051$as_echo "no" >&6; };
18052  STATIC_LIBPYTHON=0
18053else
18054  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18055$as_echo "yes" >&6; };
18056fi
18057else
18058  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18059$as_echo "yes" >&6; }
18060fi
18061
18062LIBRARY_DEPS='$(PY3LIBRARY) $(EXPORTSYMS)'
18063if test "$PY_ENABLE_SHARED" = 1 || test "$enable_framework" ; then
18064    LIBRARY_DEPS="\$(LDLIBRARY) $LIBRARY_DEPS"
18065    if test "$STATIC_LIBPYTHON" = 1; then
18066        LIBRARY_DEPS="\$(LIBRARY) $LIBRARY_DEPS"
18067    fi
18068else
18069    LIBRARY_DEPS="\$(LIBRARY) $LIBRARY_DEPS"
18070fi
18071
18072
18073
18074# Check whether to disable test modules. Once set, setup.py will not build
18075# test extension modules and "make install" will not install test suites.
18076{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --disable-test-modules" >&5
18077$as_echo_n "checking for --disable-test-modules... " >&6; }
18078# Check whether --enable-test-modules was given.
18079if test "${enable_test_modules+set}" = set; then :
18080  enableval=$enable_test_modules;
18081fi
18082
18083if test "$enable_test_modules" = no; then
18084    TEST_MODULES=no
18085    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18086$as_echo "yes" >&6; }
18087else
18088    TEST_MODULES=yes
18089    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18090$as_echo "no" >&6; }
18091fi
18092
18093
18094
18095# generate output files
18096ac_config_files="$ac_config_files Makefile.pre Misc/python.pc Misc/python-embed.pc Misc/python-config.sh"
18097
18098ac_config_files="$ac_config_files Modules/ld_so_aix"
18099
18100cat >confcache <<\_ACEOF
18101# This file is a shell script that caches the results of configure
18102# tests run on this system so they can be shared between configure
18103# scripts and configure runs, see configure's option --config-cache.
18104# It is not useful on other systems.  If it contains results you don't
18105# want to keep, you may remove or edit it.
18106#
18107# config.status only pays attention to the cache file if you give it
18108# the --recheck option to rerun configure.
18109#
18110# `ac_cv_env_foo' variables (set or unset) will be overridden when
18111# loading this file, other *unset* `ac_cv_foo' will be assigned the
18112# following values.
18113
18114_ACEOF
18115
18116# The following way of writing the cache mishandles newlines in values,
18117# but we know of no workaround that is simple, portable, and efficient.
18118# So, we kill variables containing newlines.
18119# Ultrix sh set writes to stderr and can't be redirected directly,
18120# and sets the high bit in the cache file unless we assign to the vars.
18121(
18122  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
18123    eval ac_val=\$$ac_var
18124    case $ac_val in #(
18125    *${as_nl}*)
18126      case $ac_var in #(
18127      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
18128$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
18129      esac
18130      case $ac_var in #(
18131      _ | IFS | as_nl) ;; #(
18132      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
18133      *) { eval $ac_var=; unset $ac_var;} ;;
18134      esac ;;
18135    esac
18136  done
18137
18138  (set) 2>&1 |
18139    case $as_nl`(ac_space=' '; set) 2>&1` in #(
18140    *${as_nl}ac_space=\ *)
18141      # `set' does not quote correctly, so add quotes: double-quote
18142      # substitution turns \\\\ into \\, and sed turns \\ into \.
18143      sed -n \
18144	"s/'/'\\\\''/g;
18145	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18146      ;; #(
18147    *)
18148      # `set' quotes correctly as required by POSIX, so do not add quotes.
18149      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
18150      ;;
18151    esac |
18152    sort
18153) |
18154  sed '
18155     /^ac_cv_env_/b end
18156     t clear
18157     :clear
18158     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18159     t end
18160     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18161     :end' >>confcache
18162if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
18163  if test -w "$cache_file"; then
18164    if test "x$cache_file" != "x/dev/null"; then
18165      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
18166$as_echo "$as_me: updating cache $cache_file" >&6;}
18167      if test ! -f "$cache_file" || test -h "$cache_file"; then
18168	cat confcache >"$cache_file"
18169      else
18170        case $cache_file in #(
18171        */* | ?:*)
18172	  mv -f confcache "$cache_file"$$ &&
18173	  mv -f "$cache_file"$$ "$cache_file" ;; #(
18174        *)
18175	  mv -f confcache "$cache_file" ;;
18176	esac
18177      fi
18178    fi
18179  else
18180    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
18181$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
18182  fi
18183fi
18184rm -f confcache
18185
18186test "x$prefix" = xNONE && prefix=$ac_default_prefix
18187# Let make expand exec_prefix.
18188test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
18189
18190DEFS=-DHAVE_CONFIG_H
18191
18192ac_libobjs=
18193ac_ltlibobjs=
18194U=
18195for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18196  # 1. Remove the extension, and $U if already installed.
18197  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
18198  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
18199  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
18200  #    will be set to the directory where LIBOBJS objects are built.
18201  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
18202  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
18203done
18204LIBOBJS=$ac_libobjs
18205
18206LTLIBOBJS=$ac_ltlibobjs
18207
18208
18209
18210
18211: "${CONFIG_STATUS=./config.status}"
18212ac_write_fail=0
18213ac_clean_files_save=$ac_clean_files
18214ac_clean_files="$ac_clean_files $CONFIG_STATUS"
18215{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
18216$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
18217as_write_fail=0
18218cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
18219#! $SHELL
18220# Generated by $as_me.
18221# Run this file to recreate the current configuration.
18222# Compiler output produced by configure, useful for debugging
18223# configure, is in config.log if it exists.
18224
18225debug=false
18226ac_cs_recheck=false
18227ac_cs_silent=false
18228
18229SHELL=\${CONFIG_SHELL-$SHELL}
18230export SHELL
18231_ASEOF
18232cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
18233## -------------------- ##
18234## M4sh Initialization. ##
18235## -------------------- ##
18236
18237# Be more Bourne compatible
18238DUALCASE=1; export DUALCASE # for MKS sh
18239if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18240  emulate sh
18241  NULLCMD=:
18242  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
18243  # is contrary to our usage.  Disable this feature.
18244  alias -g '${1+"$@"}'='"$@"'
18245  setopt NO_GLOB_SUBST
18246else
18247  case `(set -o) 2>/dev/null` in #(
18248  *posix*) :
18249    set -o posix ;; #(
18250  *) :
18251     ;;
18252esac
18253fi
18254
18255
18256as_nl='
18257'
18258export as_nl
18259# Printing a long string crashes Solaris 7 /usr/bin/printf.
18260as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
18261as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
18262as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
18263# Prefer a ksh shell builtin over an external printf program on Solaris,
18264# but without wasting forks for bash or zsh.
18265if test -z "$BASH_VERSION$ZSH_VERSION" \
18266    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
18267  as_echo='print -r --'
18268  as_echo_n='print -rn --'
18269elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
18270  as_echo='printf %s\n'
18271  as_echo_n='printf %s'
18272else
18273  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
18274    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
18275    as_echo_n='/usr/ucb/echo -n'
18276  else
18277    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
18278    as_echo_n_body='eval
18279      arg=$1;
18280      case $arg in #(
18281      *"$as_nl"*)
18282	expr "X$arg" : "X\\(.*\\)$as_nl";
18283	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
18284      esac;
18285      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
18286    '
18287    export as_echo_n_body
18288    as_echo_n='sh -c $as_echo_n_body as_echo'
18289  fi
18290  export as_echo_body
18291  as_echo='sh -c $as_echo_body as_echo'
18292fi
18293
18294# The user is always right.
18295if test "${PATH_SEPARATOR+set}" != set; then
18296  PATH_SEPARATOR=:
18297  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
18298    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
18299      PATH_SEPARATOR=';'
18300  }
18301fi
18302
18303
18304# IFS
18305# We need space, tab and new line, in precisely that order.  Quoting is
18306# there to prevent editors from complaining about space-tab.
18307# (If _AS_PATH_WALK were called with IFS unset, it would disable word
18308# splitting by setting IFS to empty value.)
18309IFS=" ""	$as_nl"
18310
18311# Find who we are.  Look in the path if we contain no directory separator.
18312as_myself=
18313case $0 in #((
18314  *[\\/]* ) as_myself=$0 ;;
18315  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18316for as_dir in $PATH
18317do
18318  IFS=$as_save_IFS
18319  test -z "$as_dir" && as_dir=.
18320    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18321  done
18322IFS=$as_save_IFS
18323
18324     ;;
18325esac
18326# We did not find ourselves, most probably we were run as `sh COMMAND'
18327# in which case we are not to be found in the path.
18328if test "x$as_myself" = x; then
18329  as_myself=$0
18330fi
18331if test ! -f "$as_myself"; then
18332  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
18333  exit 1
18334fi
18335
18336# Unset variables that we do not need and which cause bugs (e.g. in
18337# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
18338# suppresses any "Segmentation fault" message there.  '((' could
18339# trigger a bug in pdksh 5.2.14.
18340for as_var in BASH_ENV ENV MAIL MAILPATH
18341do eval test x\${$as_var+set} = xset \
18342  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
18343done
18344PS1='$ '
18345PS2='> '
18346PS4='+ '
18347
18348# NLS nuisances.
18349LC_ALL=C
18350export LC_ALL
18351LANGUAGE=C
18352export LANGUAGE
18353
18354# CDPATH.
18355(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
18356
18357
18358# as_fn_error STATUS ERROR [LINENO LOG_FD]
18359# ----------------------------------------
18360# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
18361# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
18362# script with STATUS, using 1 if that was 0.
18363as_fn_error ()
18364{
18365  as_status=$1; test $as_status -eq 0 && as_status=1
18366  if test "$4"; then
18367    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
18368    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
18369  fi
18370  $as_echo "$as_me: error: $2" >&2
18371  as_fn_exit $as_status
18372} # as_fn_error
18373
18374
18375# as_fn_set_status STATUS
18376# -----------------------
18377# Set $? to STATUS, without forking.
18378as_fn_set_status ()
18379{
18380  return $1
18381} # as_fn_set_status
18382
18383# as_fn_exit STATUS
18384# -----------------
18385# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
18386as_fn_exit ()
18387{
18388  set +e
18389  as_fn_set_status $1
18390  exit $1
18391} # as_fn_exit
18392
18393# as_fn_unset VAR
18394# ---------------
18395# Portably unset VAR.
18396as_fn_unset ()
18397{
18398  { eval $1=; unset $1;}
18399}
18400as_unset=as_fn_unset
18401# as_fn_append VAR VALUE
18402# ----------------------
18403# Append the text in VALUE to the end of the definition contained in VAR. Take
18404# advantage of any shell optimizations that allow amortized linear growth over
18405# repeated appends, instead of the typical quadratic growth present in naive
18406# implementations.
18407if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
18408  eval 'as_fn_append ()
18409  {
18410    eval $1+=\$2
18411  }'
18412else
18413  as_fn_append ()
18414  {
18415    eval $1=\$$1\$2
18416  }
18417fi # as_fn_append
18418
18419# as_fn_arith ARG...
18420# ------------------
18421# Perform arithmetic evaluation on the ARGs, and store the result in the
18422# global $as_val. Take advantage of shells that can avoid forks. The arguments
18423# must be portable across $(()) and expr.
18424if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
18425  eval 'as_fn_arith ()
18426  {
18427    as_val=$(( $* ))
18428  }'
18429else
18430  as_fn_arith ()
18431  {
18432    as_val=`expr "$@" || test $? -eq 1`
18433  }
18434fi # as_fn_arith
18435
18436
18437if expr a : '\(a\)' >/dev/null 2>&1 &&
18438   test "X`expr 00001 : '.*\(...\)'`" = X001; then
18439  as_expr=expr
18440else
18441  as_expr=false
18442fi
18443
18444if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
18445  as_basename=basename
18446else
18447  as_basename=false
18448fi
18449
18450if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
18451  as_dirname=dirname
18452else
18453  as_dirname=false
18454fi
18455
18456as_me=`$as_basename -- "$0" ||
18457$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18458	 X"$0" : 'X\(//\)$' \| \
18459	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
18460$as_echo X/"$0" |
18461    sed '/^.*\/\([^/][^/]*\)\/*$/{
18462	    s//\1/
18463	    q
18464	  }
18465	  /^X\/\(\/\/\)$/{
18466	    s//\1/
18467	    q
18468	  }
18469	  /^X\/\(\/\).*/{
18470	    s//\1/
18471	    q
18472	  }
18473	  s/.*/./; q'`
18474
18475# Avoid depending upon Character Ranges.
18476as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18477as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18478as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18479as_cr_digits='0123456789'
18480as_cr_alnum=$as_cr_Letters$as_cr_digits
18481
18482ECHO_C= ECHO_N= ECHO_T=
18483case `echo -n x` in #(((((
18484-n*)
18485  case `echo 'xy\c'` in
18486  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
18487  xy)  ECHO_C='\c';;
18488  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
18489       ECHO_T='	';;
18490  esac;;
18491*)
18492  ECHO_N='-n';;
18493esac
18494
18495rm -f conf$$ conf$$.exe conf$$.file
18496if test -d conf$$.dir; then
18497  rm -f conf$$.dir/conf$$.file
18498else
18499  rm -f conf$$.dir
18500  mkdir conf$$.dir 2>/dev/null
18501fi
18502if (echo >conf$$.file) 2>/dev/null; then
18503  if ln -s conf$$.file conf$$ 2>/dev/null; then
18504    as_ln_s='ln -s'
18505    # ... but there are two gotchas:
18506    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
18507    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
18508    # In both cases, we have to default to `cp -pR'.
18509    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
18510      as_ln_s='cp -pR'
18511  elif ln conf$$.file conf$$ 2>/dev/null; then
18512    as_ln_s=ln
18513  else
18514    as_ln_s='cp -pR'
18515  fi
18516else
18517  as_ln_s='cp -pR'
18518fi
18519rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
18520rmdir conf$$.dir 2>/dev/null
18521
18522
18523# as_fn_mkdir_p
18524# -------------
18525# Create "$as_dir" as a directory, including parents if necessary.
18526as_fn_mkdir_p ()
18527{
18528
18529  case $as_dir in #(
18530  -*) as_dir=./$as_dir;;
18531  esac
18532  test -d "$as_dir" || eval $as_mkdir_p || {
18533    as_dirs=
18534    while :; do
18535      case $as_dir in #(
18536      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
18537      *) as_qdir=$as_dir;;
18538      esac
18539      as_dirs="'$as_qdir' $as_dirs"
18540      as_dir=`$as_dirname -- "$as_dir" ||
18541$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
18542	 X"$as_dir" : 'X\(//\)[^/]' \| \
18543	 X"$as_dir" : 'X\(//\)$' \| \
18544	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
18545$as_echo X"$as_dir" |
18546    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
18547	    s//\1/
18548	    q
18549	  }
18550	  /^X\(\/\/\)[^/].*/{
18551	    s//\1/
18552	    q
18553	  }
18554	  /^X\(\/\/\)$/{
18555	    s//\1/
18556	    q
18557	  }
18558	  /^X\(\/\).*/{
18559	    s//\1/
18560	    q
18561	  }
18562	  s/.*/./; q'`
18563      test -d "$as_dir" && break
18564    done
18565    test -z "$as_dirs" || eval "mkdir $as_dirs"
18566  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
18567
18568
18569} # as_fn_mkdir_p
18570if mkdir -p . 2>/dev/null; then
18571  as_mkdir_p='mkdir -p "$as_dir"'
18572else
18573  test -d ./-p && rmdir ./-p
18574  as_mkdir_p=false
18575fi
18576
18577
18578# as_fn_executable_p FILE
18579# -----------------------
18580# Test if FILE is an executable regular file.
18581as_fn_executable_p ()
18582{
18583  test -f "$1" && test -x "$1"
18584} # as_fn_executable_p
18585as_test_x='test -x'
18586as_executable_p=as_fn_executable_p
18587
18588# Sed expression to map a string onto a valid CPP name.
18589as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
18590
18591# Sed expression to map a string onto a valid variable name.
18592as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
18593
18594
18595exec 6>&1
18596## ----------------------------------- ##
18597## Main body of $CONFIG_STATUS script. ##
18598## ----------------------------------- ##
18599_ASEOF
18600test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
18601
18602cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18603# Save the log message, to keep $0 and so on meaningful, and to
18604# report actual input values of CONFIG_FILES etc. instead of their
18605# values after options handling.
18606ac_log="
18607This file was extended by python $as_me 3.10, which was
18608generated by GNU Autoconf 2.69.  Invocation command line was
18609
18610  CONFIG_FILES    = $CONFIG_FILES
18611  CONFIG_HEADERS  = $CONFIG_HEADERS
18612  CONFIG_LINKS    = $CONFIG_LINKS
18613  CONFIG_COMMANDS = $CONFIG_COMMANDS
18614  $ $0 $@
18615
18616on `(hostname || uname -n) 2>/dev/null | sed 1q`
18617"
18618
18619_ACEOF
18620
18621case $ac_config_files in *"
18622"*) set x $ac_config_files; shift; ac_config_files=$*;;
18623esac
18624
18625case $ac_config_headers in *"
18626"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
18627esac
18628
18629
18630cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18631# Files that config.status was made for.
18632config_files="$ac_config_files"
18633config_headers="$ac_config_headers"
18634
18635_ACEOF
18636
18637cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18638ac_cs_usage="\
18639\`$as_me' instantiates files and other configuration actions
18640from templates according to the current configuration.  Unless the files
18641and actions are specified as TAGs, all are instantiated by default.
18642
18643Usage: $0 [OPTION]... [TAG]...
18644
18645  -h, --help       print this help, then exit
18646  -V, --version    print version number and configuration settings, then exit
18647      --config     print configuration, then exit
18648  -q, --quiet, --silent
18649                   do not print progress messages
18650  -d, --debug      don't remove temporary files
18651      --recheck    update $as_me by reconfiguring in the same conditions
18652      --file=FILE[:TEMPLATE]
18653                   instantiate the configuration file FILE
18654      --header=FILE[:TEMPLATE]
18655                   instantiate the configuration header FILE
18656
18657Configuration files:
18658$config_files
18659
18660Configuration headers:
18661$config_headers
18662
18663Report bugs to <https://bugs.python.org/>."
18664
18665_ACEOF
18666cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18667ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
18668ac_cs_version="\\
18669python config.status 3.10
18670configured by $0, generated by GNU Autoconf 2.69,
18671  with options \\"\$ac_cs_config\\"
18672
18673Copyright (C) 2012 Free Software Foundation, Inc.
18674This config.status script is free software; the Free Software Foundation
18675gives unlimited permission to copy, distribute and modify it."
18676
18677ac_pwd='$ac_pwd'
18678srcdir='$srcdir'
18679INSTALL='$INSTALL'
18680MKDIR_P='$MKDIR_P'
18681test -n "\$AWK" || AWK=awk
18682_ACEOF
18683
18684cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18685# The default lists apply if the user does not specify any file.
18686ac_need_defaults=:
18687while test $# != 0
18688do
18689  case $1 in
18690  --*=?*)
18691    ac_option=`expr "X$1" : 'X\([^=]*\)='`
18692    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
18693    ac_shift=:
18694    ;;
18695  --*=)
18696    ac_option=`expr "X$1" : 'X\([^=]*\)='`
18697    ac_optarg=
18698    ac_shift=:
18699    ;;
18700  *)
18701    ac_option=$1
18702    ac_optarg=$2
18703    ac_shift=shift
18704    ;;
18705  esac
18706
18707  case $ac_option in
18708  # Handling of the options.
18709  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18710    ac_cs_recheck=: ;;
18711  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
18712    $as_echo "$ac_cs_version"; exit ;;
18713  --config | --confi | --conf | --con | --co | --c )
18714    $as_echo "$ac_cs_config"; exit ;;
18715  --debug | --debu | --deb | --de | --d | -d )
18716    debug=: ;;
18717  --file | --fil | --fi | --f )
18718    $ac_shift
18719    case $ac_optarg in
18720    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18721    '') as_fn_error $? "missing file argument" ;;
18722    esac
18723    as_fn_append CONFIG_FILES " '$ac_optarg'"
18724    ac_need_defaults=false;;
18725  --header | --heade | --head | --hea )
18726    $ac_shift
18727    case $ac_optarg in
18728    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
18729    esac
18730    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
18731    ac_need_defaults=false;;
18732  --he | --h)
18733    # Conflict between --help and --header
18734    as_fn_error $? "ambiguous option: \`$1'
18735Try \`$0 --help' for more information.";;
18736  --help | --hel | -h )
18737    $as_echo "$ac_cs_usage"; exit ;;
18738  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
18739  | -silent | --silent | --silen | --sile | --sil | --si | --s)
18740    ac_cs_silent=: ;;
18741
18742  # This is an error.
18743  -*) as_fn_error $? "unrecognized option: \`$1'
18744Try \`$0 --help' for more information." ;;
18745
18746  *) as_fn_append ac_config_targets " $1"
18747     ac_need_defaults=false ;;
18748
18749  esac
18750  shift
18751done
18752
18753ac_configure_extra_args=
18754
18755if $ac_cs_silent; then
18756  exec 6>/dev/null
18757  ac_configure_extra_args="$ac_configure_extra_args --silent"
18758fi
18759
18760_ACEOF
18761cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18762if \$ac_cs_recheck; then
18763  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
18764  shift
18765  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
18766  CONFIG_SHELL='$SHELL'
18767  export CONFIG_SHELL
18768  exec "\$@"
18769fi
18770
18771_ACEOF
18772cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18773exec 5>>config.log
18774{
18775  echo
18776  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18777## Running $as_me. ##
18778_ASBOX
18779  $as_echo "$ac_log"
18780} >&5
18781
18782_ACEOF
18783cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18784_ACEOF
18785
18786cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18787
18788# Handling of arguments.
18789for ac_config_target in $ac_config_targets
18790do
18791  case $ac_config_target in
18792    "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
18793    "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;;
18794    "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;;
18795    "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;;
18796    "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;;
18797    "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
18798    "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;;
18799    "Misc/python-embed.pc") CONFIG_FILES="$CONFIG_FILES Misc/python-embed.pc" ;;
18800    "Misc/python-config.sh") CONFIG_FILES="$CONFIG_FILES Misc/python-config.sh" ;;
18801    "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;;
18802
18803  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
18804  esac
18805done
18806
18807
18808# If the user did not use the arguments to specify the items to instantiate,
18809# then the envvar interface is used.  Set only those that are not.
18810# We use the long form for the default assignment because of an extremely
18811# bizarre bug on SunOS 4.1.3.
18812if $ac_need_defaults; then
18813  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
18814  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
18815fi
18816
18817# Have a temporary directory for convenience.  Make it in the build tree
18818# simply because there is no reason against having it here, and in addition,
18819# creating and moving files from /tmp can sometimes cause problems.
18820# Hook for its removal unless debugging.
18821# Note that there is a small window in which the directory will not be cleaned:
18822# after its creation but before its name has been assigned to `$tmp'.
18823$debug ||
18824{
18825  tmp= ac_tmp=
18826  trap 'exit_status=$?
18827  : "${ac_tmp:=$tmp}"
18828  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
18829' 0
18830  trap 'as_fn_exit 1' 1 2 13 15
18831}
18832# Create a (secure) tmp directory for tmp files.
18833
18834{
18835  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
18836  test -d "$tmp"
18837}  ||
18838{
18839  tmp=./conf$$-$RANDOM
18840  (umask 077 && mkdir "$tmp")
18841} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
18842ac_tmp=$tmp
18843
18844# Set up the scripts for CONFIG_FILES section.
18845# No need to generate them if there are no CONFIG_FILES.
18846# This happens for instance with `./config.status config.h'.
18847if test -n "$CONFIG_FILES"; then
18848
18849
18850ac_cr=`echo X | tr X '\015'`
18851# On cygwin, bash can eat \r inside `` if the user requested igncr.
18852# But we know of no other shell where ac_cr would be empty at this
18853# point, so we can use a bashism as a fallback.
18854if test "x$ac_cr" = x; then
18855  eval ac_cr=\$\'\\r\'
18856fi
18857ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
18858if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
18859  ac_cs_awk_cr='\\r'
18860else
18861  ac_cs_awk_cr=$ac_cr
18862fi
18863
18864echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
18865_ACEOF
18866
18867
18868{
18869  echo "cat >conf$$subs.awk <<_ACEOF" &&
18870  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
18871  echo "_ACEOF"
18872} >conf$$subs.sh ||
18873  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18874ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
18875ac_delim='%!_!# '
18876for ac_last_try in false false false false false :; do
18877  . ./conf$$subs.sh ||
18878    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18879
18880  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
18881  if test $ac_delim_n = $ac_delim_num; then
18882    break
18883  elif $ac_last_try; then
18884    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
18885  else
18886    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
18887  fi
18888done
18889rm -f conf$$subs.sh
18890
18891cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18892cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
18893_ACEOF
18894sed -n '
18895h
18896s/^/S["/; s/!.*/"]=/
18897p
18898g
18899s/^[^!]*!//
18900:repl
18901t repl
18902s/'"$ac_delim"'$//
18903t delim
18904:nl
18905h
18906s/\(.\{148\}\)..*/\1/
18907t more1
18908s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
18909p
18910n
18911b repl
18912:more1
18913s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18914p
18915g
18916s/.\{148\}//
18917t nl
18918:delim
18919h
18920s/\(.\{148\}\)..*/\1/
18921t more2
18922s/["\\]/\\&/g; s/^/"/; s/$/"/
18923p
18924b
18925:more2
18926s/["\\]/\\&/g; s/^/"/; s/$/"\\/
18927p
18928g
18929s/.\{148\}//
18930t delim
18931' <conf$$subs.awk | sed '
18932/^[^""]/{
18933  N
18934  s/\n//
18935}
18936' >>$CONFIG_STATUS || ac_write_fail=1
18937rm -f conf$$subs.awk
18938cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
18939_ACAWK
18940cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
18941  for (key in S) S_is_set[key] = 1
18942  FS = ""
18943
18944}
18945{
18946  line = $ 0
18947  nfields = split(line, field, "@")
18948  substed = 0
18949  len = length(field[1])
18950  for (i = 2; i < nfields; i++) {
18951    key = field[i]
18952    keylen = length(key)
18953    if (S_is_set[key]) {
18954      value = S[key]
18955      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
18956      len += length(value) + length(field[++i])
18957      substed = 1
18958    } else
18959      len += 1 + keylen
18960  }
18961
18962  print line
18963}
18964
18965_ACAWK
18966_ACEOF
18967cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
18968if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
18969  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
18970else
18971  cat
18972fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
18973  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
18974_ACEOF
18975
18976# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
18977# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
18978# trailing colons and then remove the whole line if VPATH becomes empty
18979# (actually we leave an empty line to preserve line numbers).
18980if test "x$srcdir" = x.; then
18981  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
18982h
18983s///
18984s/^/:/
18985s/[	 ]*$/:/
18986s/:\$(srcdir):/:/g
18987s/:\${srcdir}:/:/g
18988s/:@srcdir@:/:/g
18989s/^:*//
18990s/:*$//
18991x
18992s/\(=[	 ]*\).*/\1/
18993G
18994s/\n//
18995s/^[^=]*=[	 ]*$//
18996}'
18997fi
18998
18999cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19000fi # test -n "$CONFIG_FILES"
19001
19002# Set up the scripts for CONFIG_HEADERS section.
19003# No need to generate them if there are no CONFIG_HEADERS.
19004# This happens for instance with `./config.status Makefile'.
19005if test -n "$CONFIG_HEADERS"; then
19006cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
19007BEGIN {
19008_ACEOF
19009
19010# Transform confdefs.h into an awk script `defines.awk', embedded as
19011# here-document in config.status, that substitutes the proper values into
19012# config.h.in to produce config.h.
19013
19014# Create a delimiter string that does not exist in confdefs.h, to ease
19015# handling of long lines.
19016ac_delim='%!_!# '
19017for ac_last_try in false false :; do
19018  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
19019  if test -z "$ac_tt"; then
19020    break
19021  elif $ac_last_try; then
19022    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
19023  else
19024    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19025  fi
19026done
19027
19028# For the awk script, D is an array of macro values keyed by name,
19029# likewise P contains macro parameters if any.  Preserve backslash
19030# newline sequences.
19031
19032ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
19033sed -n '
19034s/.\{148\}/&'"$ac_delim"'/g
19035t rset
19036:rset
19037s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
19038t def
19039d
19040:def
19041s/\\$//
19042t bsnl
19043s/["\\]/\\&/g
19044s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
19045D["\1"]=" \3"/p
19046s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
19047d
19048:bsnl
19049s/["\\]/\\&/g
19050s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
19051D["\1"]=" \3\\\\\\n"\\/p
19052t cont
19053s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
19054t cont
19055d
19056:cont
19057n
19058s/.\{148\}/&'"$ac_delim"'/g
19059t clear
19060:clear
19061s/\\$//
19062t bsnlc
19063s/["\\]/\\&/g; s/^/"/; s/$/"/p
19064d
19065:bsnlc
19066s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
19067b cont
19068' <confdefs.h | sed '
19069s/'"$ac_delim"'/"\\\
19070"/g' >>$CONFIG_STATUS || ac_write_fail=1
19071
19072cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19073  for (key in D) D_is_set[key] = 1
19074  FS = ""
19075}
19076/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
19077  line = \$ 0
19078  split(line, arg, " ")
19079  if (arg[1] == "#") {
19080    defundef = arg[2]
19081    mac1 = arg[3]
19082  } else {
19083    defundef = substr(arg[1], 2)
19084    mac1 = arg[2]
19085  }
19086  split(mac1, mac2, "(") #)
19087  macro = mac2[1]
19088  prefix = substr(line, 1, index(line, defundef) - 1)
19089  if (D_is_set[macro]) {
19090    # Preserve the white space surrounding the "#".
19091    print prefix "define", macro P[macro] D[macro]
19092    next
19093  } else {
19094    # Replace #undef with comments.  This is necessary, for example,
19095    # in the case of _POSIX_SOURCE, which is predefined and required
19096    # on some systems where configure will not decide to define it.
19097    if (defundef == "undef") {
19098      print "/*", prefix defundef, macro, "*/"
19099      next
19100    }
19101  }
19102}
19103{ print }
19104_ACAWK
19105_ACEOF
19106cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19107  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
19108fi # test -n "$CONFIG_HEADERS"
19109
19110
19111eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
19112shift
19113for ac_tag
19114do
19115  case $ac_tag in
19116  :[FHLC]) ac_mode=$ac_tag; continue;;
19117  esac
19118  case $ac_mode$ac_tag in
19119  :[FHL]*:*);;
19120  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
19121  :[FH]-) ac_tag=-:-;;
19122  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
19123  esac
19124  ac_save_IFS=$IFS
19125  IFS=:
19126  set x $ac_tag
19127  IFS=$ac_save_IFS
19128  shift
19129  ac_file=$1
19130  shift
19131
19132  case $ac_mode in
19133  :L) ac_source=$1;;
19134  :[FH])
19135    ac_file_inputs=
19136    for ac_f
19137    do
19138      case $ac_f in
19139      -) ac_f="$ac_tmp/stdin";;
19140      *) # Look for the file first in the build tree, then in the source tree
19141	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
19142	 # because $ac_f cannot contain `:'.
19143	 test -f "$ac_f" ||
19144	   case $ac_f in
19145	   [\\/$]*) false;;
19146	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
19147	   esac ||
19148	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
19149      esac
19150      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
19151      as_fn_append ac_file_inputs " '$ac_f'"
19152    done
19153
19154    # Let's still pretend it is `configure' which instantiates (i.e., don't
19155    # use $as_me), people would be surprised to read:
19156    #    /* config.h.  Generated by config.status.  */
19157    configure_input='Generated from '`
19158	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
19159	`' by configure.'
19160    if test x"$ac_file" != x-; then
19161      configure_input="$ac_file.  $configure_input"
19162      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
19163$as_echo "$as_me: creating $ac_file" >&6;}
19164    fi
19165    # Neutralize special characters interpreted by sed in replacement strings.
19166    case $configure_input in #(
19167    *\&* | *\|* | *\\* )
19168       ac_sed_conf_input=`$as_echo "$configure_input" |
19169       sed 's/[\\\\&|]/\\\\&/g'`;; #(
19170    *) ac_sed_conf_input=$configure_input;;
19171    esac
19172
19173    case $ac_tag in
19174    *:-:* | *:-) cat >"$ac_tmp/stdin" \
19175      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
19176    esac
19177    ;;
19178  esac
19179
19180  ac_dir=`$as_dirname -- "$ac_file" ||
19181$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19182	 X"$ac_file" : 'X\(//\)[^/]' \| \
19183	 X"$ac_file" : 'X\(//\)$' \| \
19184	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
19185$as_echo X"$ac_file" |
19186    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19187	    s//\1/
19188	    q
19189	  }
19190	  /^X\(\/\/\)[^/].*/{
19191	    s//\1/
19192	    q
19193	  }
19194	  /^X\(\/\/\)$/{
19195	    s//\1/
19196	    q
19197	  }
19198	  /^X\(\/\).*/{
19199	    s//\1/
19200	    q
19201	  }
19202	  s/.*/./; q'`
19203  as_dir="$ac_dir"; as_fn_mkdir_p
19204  ac_builddir=.
19205
19206case "$ac_dir" in
19207.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
19208*)
19209  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
19210  # A ".." for each directory in $ac_dir_suffix.
19211  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
19212  case $ac_top_builddir_sub in
19213  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
19214  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
19215  esac ;;
19216esac
19217ac_abs_top_builddir=$ac_pwd
19218ac_abs_builddir=$ac_pwd$ac_dir_suffix
19219# for backward compatibility:
19220ac_top_builddir=$ac_top_build_prefix
19221
19222case $srcdir in
19223  .)  # We are building in place.
19224    ac_srcdir=.
19225    ac_top_srcdir=$ac_top_builddir_sub
19226    ac_abs_top_srcdir=$ac_pwd ;;
19227  [\\/]* | ?:[\\/]* )  # Absolute name.
19228    ac_srcdir=$srcdir$ac_dir_suffix;
19229    ac_top_srcdir=$srcdir
19230    ac_abs_top_srcdir=$srcdir ;;
19231  *) # Relative name.
19232    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
19233    ac_top_srcdir=$ac_top_build_prefix$srcdir
19234    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
19235esac
19236ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
19237
19238
19239  case $ac_mode in
19240  :F)
19241  #
19242  # CONFIG_FILE
19243  #
19244
19245  case $INSTALL in
19246  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
19247  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
19248  esac
19249  ac_MKDIR_P=$MKDIR_P
19250  case $MKDIR_P in
19251  [\\/$]* | ?:[\\/]* ) ;;
19252  */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
19253  esac
19254_ACEOF
19255
19256cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19257# If the template does not know about datarootdir, expand it.
19258# FIXME: This hack should be removed a few years after 2.60.
19259ac_datarootdir_hack=; ac_datarootdir_seen=
19260ac_sed_dataroot='
19261/datarootdir/ {
19262  p
19263  q
19264}
19265/@datadir@/p
19266/@docdir@/p
19267/@infodir@/p
19268/@localedir@/p
19269/@mandir@/p'
19270case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
19271*datarootdir*) ac_datarootdir_seen=yes;;
19272*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
19273  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
19274$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
19275_ACEOF
19276cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19277  ac_datarootdir_hack='
19278  s&@datadir@&$datadir&g
19279  s&@docdir@&$docdir&g
19280  s&@infodir@&$infodir&g
19281  s&@localedir@&$localedir&g
19282  s&@mandir@&$mandir&g
19283  s&\\\${datarootdir}&$datarootdir&g' ;;
19284esac
19285_ACEOF
19286
19287# Neutralize VPATH when `$srcdir' = `.'.
19288# Shell code in configure.ac might set extrasub.
19289# FIXME: do we really want to maintain this feature?
19290cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19291ac_sed_extra="$ac_vpsub
19292$extrasub
19293_ACEOF
19294cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19295:t
19296/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
19297s|@configure_input@|$ac_sed_conf_input|;t t
19298s&@top_builddir@&$ac_top_builddir_sub&;t t
19299s&@top_build_prefix@&$ac_top_build_prefix&;t t
19300s&@srcdir@&$ac_srcdir&;t t
19301s&@abs_srcdir@&$ac_abs_srcdir&;t t
19302s&@top_srcdir@&$ac_top_srcdir&;t t
19303s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
19304s&@builddir@&$ac_builddir&;t t
19305s&@abs_builddir@&$ac_abs_builddir&;t t
19306s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
19307s&@INSTALL@&$ac_INSTALL&;t t
19308s&@MKDIR_P@&$ac_MKDIR_P&;t t
19309$ac_datarootdir_hack
19310"
19311eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
19312  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19313
19314test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
19315  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
19316  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
19317      "$ac_tmp/out"`; test -z "$ac_out"; } &&
19318  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19319which seems to be undefined.  Please make sure it is defined" >&5
19320$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
19321which seems to be undefined.  Please make sure it is defined" >&2;}
19322
19323  rm -f "$ac_tmp/stdin"
19324  case $ac_file in
19325  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
19326  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
19327  esac \
19328  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19329 ;;
19330  :H)
19331  #
19332  # CONFIG_HEADER
19333  #
19334  if test x"$ac_file" != x-; then
19335    {
19336      $as_echo "/* $configure_input  */" \
19337      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
19338    } >"$ac_tmp/config.h" \
19339      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
19340    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
19341      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
19342$as_echo "$as_me: $ac_file is unchanged" >&6;}
19343    else
19344      rm -f "$ac_file"
19345      mv "$ac_tmp/config.h" "$ac_file" \
19346	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
19347    fi
19348  else
19349    $as_echo "/* $configure_input  */" \
19350      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
19351      || as_fn_error $? "could not create -" "$LINENO" 5
19352  fi
19353 ;;
19354
19355
19356  esac
19357
19358
19359  case $ac_file$ac_mode in
19360    "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;;
19361
19362  esac
19363done # for ac_tag
19364
19365
19366as_fn_exit 0
19367_ACEOF
19368ac_clean_files=$ac_clean_files_save
19369
19370test $ac_write_fail = 0 ||
19371  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
19372
19373
19374# configure is writing to config.log, and then calls config.status.
19375# config.status does its own redirection, appending to config.log.
19376# Unfortunately, on DOS this fails, as config.log is still kept open
19377# by configure, so config.status won't be able to write to it; its
19378# output is simply discarded.  So we exec the FD to /dev/null,
19379# effectively closing config.log, so it can be properly (re)opened and
19380# appended to by config.status.  When coming back to configure, we
19381# need to make the FD available again.
19382if test "$no_create" != yes; then
19383  ac_cs_success=:
19384  ac_config_status_args=
19385  test "$silent" = yes &&
19386    ac_config_status_args="$ac_config_status_args --quiet"
19387  exec 5>/dev/null
19388  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
19389  exec 5>>config.log
19390  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19391  # would make configure fail if this is the last instruction.
19392  $ac_cs_success || as_fn_exit 1
19393fi
19394if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
19395  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
19396$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
19397fi
19398
19399
19400echo "creating Modules/Setup.local" >&6
19401if test ! -f Modules/Setup.local
19402then
19403	echo "# Edit this file for local setup changes" >Modules/Setup.local
19404fi
19405
19406echo "creating Makefile" >&6
19407$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
19408			-s Modules \
19409			Modules/Setup.local $srcdir/Modules/Setup
19410mv config.c Modules
19411
19412if test "$Py_OPT" = 'false' -a "$Py_DEBUG" != 'true'; then
19413    echo "" >&6
19414    echo "" >&6
19415    echo "If you want a release build with all stable optimizations active (PGO, etc)," >&6
19416    echo "please run ./configure --enable-optimizations" >&6
19417    echo "" >&6
19418    echo "" >&6
19419fi
19420