blob: 6c4da49b6c856f9bf6cbfa4f860ffcb5777eb560 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Guido van Rossum627b2d71993-12-24 10:39:16 +00002# Guess values for system-dependent variables and create Makefiles.
Pablo Galindoba421752021-05-03 20:33:17 +01003# Generated by GNU Autoconf 2.71 for python 3.10.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004#
Benjamin Petersonc2fcbf42016-08-03 22:01:32 -07005# Report bugs to <https://bugs.python.org/>.
Martin v. Löwis1d459062005-03-14 21:23:33 +00006#
Matthias Kloseb9621712010-04-24 17:59:49 +00007#
Pablo Galindoba421752021-05-03 20:33:17 +01008# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
9# Inc.
Matthias Kloseb9621712010-04-24 17:59:49 +000010#
11#
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012# This configure script is free software; the Free Software Foundation
13# gives unlimited permission to copy, distribute and modify it.
Matthias Kloseb9621712010-04-24 17:59:49 +000014## -------------------- ##
15## M4sh Initialization. ##
16## -------------------- ##
Martin v. Löwis11437992002-04-12 09:54:03 +000017
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018# Be more Bourne compatible
19DUALCASE=1; export DUALCASE # for MKS sh
Pablo Galindoba421752021-05-03 20:33:17 +010020as_nop=:
21if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
22then :
Martin v. Löwis11437992002-04-12 09:54:03 +000023 emulate sh
24 NULLCMD=:
Matthias Kloseb9621712010-04-24 17:59:49 +000025 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
Skip Montanaro6dead952003-09-25 14:50:04 +000026 # is contrary to our usage. Disable this feature.
27 alias -g '${1+"$@"}'='"$@"'
Thomas Wouters47b49bf2007-08-30 22:15:33 +000028 setopt NO_GLOB_SUBST
Pablo Galindoba421752021-05-03 20:33:17 +010029else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000030 case `(set -o) 2>/dev/null` in #(
31 *posix*) :
32 set -o posix ;; #(
33 *) :
34 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000035esac
Martin v. Löwis11437992002-04-12 09:54:03 +000036fi
Thomas Wouters89f507f2006-12-13 04:49:30 +000037
38
Pablo Galindoba421752021-05-03 20:33:17 +010039
40# Reset variables that may have inherited troublesome values from
41# the environment.
42
43# IFS needs to be set, to space, tab, and newline, in precisely that order.
44# (If _AS_PATH_WALK were called with IFS unset, it would have the
45# side effect of setting IFS to empty, thus disabling word splitting.)
46# Quoting is to prevent editors from complaining about space-tab.
Matthias Kloseb9621712010-04-24 17:59:49 +000047as_nl='
48'
49export as_nl
Pablo Galindoba421752021-05-03 20:33:17 +010050IFS=" "" $as_nl"
51
52PS1='$ '
53PS2='> '
54PS4='+ '
55
56# Ensure predictable behavior from utilities with locale-dependent output.
57LC_ALL=C
58export LC_ALL
59LANGUAGE=C
60export LANGUAGE
61
62# We cannot yet rely on "unset" to work, but we need these variables
63# to be unset--not just set to an empty or harmless value--now, to
64# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
65# also avoids known problems related to "unset" and subshell syntax
66# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
67for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
68do eval test \${$as_var+y} \
69 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
70done
71
72# Ensure that fds 0, 1, and 2 are open.
73if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
74if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
75if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
Martin v. Löwis11437992002-04-12 09:54:03 +000076
77# The user is always right.
Pablo Galindoba421752021-05-03 20:33:17 +010078if ${PATH_SEPARATOR+false} :; then
Matthias Kloseb9621712010-04-24 17:59:49 +000079 PATH_SEPARATOR=:
80 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
81 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
82 PATH_SEPARATOR=';'
83 }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000084fi
Martin v. Löwis11437992002-04-12 09:54:03 +000085
Thomas Wouters47b49bf2007-08-30 22:15:33 +000086
Thomas Wouters47b49bf2007-08-30 22:15:33 +000087# Find who we are. Look in the path if we contain no directory separator.
Victor Stinnere0be4232011-10-25 13:06:09 +020088as_myself=
Matthias Kloseb9621712010-04-24 17:59:49 +000089case $0 in #((
Thomas Wouters47b49bf2007-08-30 22:15:33 +000090 *[\\/]* ) as_myself=$0 ;;
91 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +000092for as_dir in $PATH
93do
94 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010095 case $as_dir in #(((
96 '') as_dir=./ ;;
97 */) ;;
98 *) as_dir=$as_dir/ ;;
99 esac
100 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
Matthias Kloseb9621712010-04-24 17:59:49 +0000101 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000102IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +0000103
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000104 ;;
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
Pablo Galindoba421752021-05-03 20:33:17 +0100112 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Matthias Kloseb9621712010-04-24 17:59:49 +0000113 exit 1
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000114fi
115
Matthias Kloseb9621712010-04-24 17:59:49 +0000116
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000117# Use a proper internal environment variable to ensure we don't fall
118 # into an infinite loop, continuously re-executing ourselves.
119 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
120 _as_can_reexec=no; export _as_can_reexec;
121 # We cannot yet assume a decent shell, so we have to provide a
122# neutralization value for shells without unset; and this also
123# works around shells that cannot unset nonexistent variables.
124# Preserve -v and -x to the replacement shell.
125BASH_ENV=/dev/null
126ENV=/dev/null
127(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
128case $- in # ((((
129 *v*x* | *x*v* ) as_opts=-vx ;;
130 *v* ) as_opts=-v ;;
131 *x* ) as_opts=-x ;;
132 * ) as_opts= ;;
133esac
134exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
135# Admittedly, this is quite paranoid, since all the known shells bail
136# out after a failed `exec'.
Pablo Galindoba421752021-05-03 20:33:17 +0100137printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
138exit 255
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000139 fi
140 # We don't want this to propagate to other subprocesses.
141 { _as_can_reexec=; unset _as_can_reexec;}
Matthias Kloseb9621712010-04-24 17:59:49 +0000142if test "x$CONFIG_SHELL" = x; then
Pablo Galindoba421752021-05-03 20:33:17 +0100143 as_bourne_compatible="as_nop=:
144if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
145then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000146 emulate sh
147 NULLCMD=:
148 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
149 # is contrary to our usage. Disable this feature.
150 alias -g '\${1+\"\$@\"}'='\"\$@\"'
151 setopt NO_GLOB_SUBST
Pablo Galindoba421752021-05-03 20:33:17 +0100152else \$as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000153 case \`(set -o) 2>/dev/null\` in #(
154 *posix*) :
155 set -o posix ;; #(
156 *) :
157 ;;
158esac
159fi
160"
161 as_required="as_fn_return () { (exit \$1); }
162as_fn_success () { as_fn_return 0; }
163as_fn_failure () { as_fn_return 1; }
164as_fn_ret_success () { return 0; }
165as_fn_ret_failure () { return 1; }
166
167exitcode=0
168as_fn_success || { exitcode=1; echo as_fn_success failed.; }
169as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
170as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
171as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
Pablo Galindoba421752021-05-03 20:33:17 +0100172if ( set x; as_fn_ret_success y && test x = \"\$1\" )
173then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000174
Pablo Galindoba421752021-05-03 20:33:17 +0100175else \$as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000176 exitcode=1; echo positional parameters were not saved.
177fi
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000178test x\$exitcode = x0 || exit 1
Pablo Galindoba421752021-05-03 20:33:17 +0100179blah=\$(echo \$(echo blah))
180test x\"\$blah\" = xblah || exit 1
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000181test -x / || exit 1"
Matthias Kloseb9621712010-04-24 17:59:49 +0000182 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
183 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
184 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
185 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
186test \$(( 1 + 1 )) = 2 || exit 1"
Pablo Galindoba421752021-05-03 20:33:17 +0100187 if (eval "$as_required") 2>/dev/null
188then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000189 as_have_required=yes
Pablo Galindoba421752021-05-03 20:33:17 +0100190else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000191 as_have_required=no
192fi
Pablo Galindoba421752021-05-03 20:33:17 +0100193 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
194then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000195
Pablo Galindoba421752021-05-03 20:33:17 +0100196else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000197 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
198as_found=false
199for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
200do
201 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +0100202 case $as_dir in #(((
203 '') as_dir=./ ;;
204 */) ;;
205 *) as_dir=$as_dir/ ;;
206 esac
Matthias Kloseb9621712010-04-24 17:59:49 +0000207 as_found=:
208 case $as_dir in #(
209 /*)
210 for as_base in sh bash ksh sh5; do
211 # Try only shells that exist, to save several forks.
Pablo Galindoba421752021-05-03 20:33:17 +0100212 as_shell=$as_dir$as_base
Matthias Kloseb9621712010-04-24 17:59:49 +0000213 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
Pablo Galindoba421752021-05-03 20:33:17 +0100214 as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
215then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000216 CONFIG_SHELL=$as_shell as_have_required=yes
Pablo Galindoba421752021-05-03 20:33:17 +0100217 if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
218then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000219 break 2
220fi
221fi
222 done;;
223 esac
224 as_found=false
225done
Christian Heimes39258d32021-04-17 11:36:35 +0200226IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +0100227if $as_found
228then :
229
230else $as_nop
231 if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232 as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
233then :
234 CONFIG_SHELL=$SHELL as_have_required=yes
235fi
236fi
Matthias Kloseb9621712010-04-24 17:59:49 +0000237
238
Pablo Galindoba421752021-05-03 20:33:17 +0100239 if test "x$CONFIG_SHELL" != x
240then :
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000241 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'.
Pablo Galindoba421752021-05-03 20:33:17 +0100258printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000259exit 255
Matthias Kloseb9621712010-04-24 17:59:49 +0000260fi
261
Pablo Galindoba421752021-05-03 20:33:17 +0100262 if test x$as_have_required = xno
263then :
264 printf "%s\n" "$0: This script requires a shell more modern than all"
265 printf "%s\n" "$0: the shells that I found on your system."
266 if test ${ZSH_VERSION+y} ; then
267 printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
268 printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
Matthias Kloseb9621712010-04-24 17:59:49 +0000269 else
Pablo Galindoba421752021-05-03 20:33:17 +0100270 printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and
Benjamin Petersonc2fcbf42016-08-03 22:01:32 -0700271$0: https://bugs.python.org/ about your system, including
Matthias Kloseb9621712010-04-24 17:59:49 +0000272$0: any error possibly output before this message. Then
273$0: install a modern shell, or manually run the script
274$0: under such a shell if you do have one."
275 fi
276 exit 1
277fi
278fi
279fi
280SHELL=${CONFIG_SHELL-/bin/sh}
281export SHELL
282# Unset more variables known to interfere with behavior of common tools.
283CLICOLOR_FORCE= GREP_OPTIONS=
284unset CLICOLOR_FORCE GREP_OPTIONS
285
286## --------------------- ##
287## M4sh Shell Functions. ##
288## --------------------- ##
289# as_fn_unset VAR
290# ---------------
291# Portably unset VAR.
292as_fn_unset ()
293{
294 { eval $1=; unset $1;}
295}
296as_unset=as_fn_unset
297
Pablo Galindoba421752021-05-03 20:33:17 +0100298
Matthias Kloseb9621712010-04-24 17:59:49 +0000299# as_fn_set_status STATUS
300# -----------------------
301# Set $? to STATUS, without forking.
302as_fn_set_status ()
303{
304 return $1
305} # as_fn_set_status
306
307# as_fn_exit STATUS
308# -----------------
309# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
310as_fn_exit ()
311{
312 set +e
313 as_fn_set_status $1
314 exit $1
315} # as_fn_exit
Pablo Galindoba421752021-05-03 20:33:17 +0100316# as_fn_nop
317# ---------
318# Do nothing but, unlike ":", preserve the value of $?.
319as_fn_nop ()
320{
321 return $?
322}
323as_nop=as_fn_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000324
325# as_fn_mkdir_p
326# -------------
327# Create "$as_dir" as a directory, including parents if necessary.
328as_fn_mkdir_p ()
329{
330
331 case $as_dir in #(
332 -*) as_dir=./$as_dir;;
333 esac
334 test -d "$as_dir" || eval $as_mkdir_p || {
335 as_dirs=
336 while :; do
337 case $as_dir in #(
Pablo Galindoba421752021-05-03 20:33:17 +0100338 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
Matthias Kloseb9621712010-04-24 17:59:49 +0000339 *) as_qdir=$as_dir;;
340 esac
341 as_dirs="'$as_qdir' $as_dirs"
342 as_dir=`$as_dirname -- "$as_dir" ||
343$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
344 X"$as_dir" : 'X\(//\)[^/]' \| \
345 X"$as_dir" : 'X\(//\)$' \| \
346 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +0100347printf "%s\n" X"$as_dir" |
Matthias Kloseb9621712010-04-24 17:59:49 +0000348 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
349 s//\1/
350 q
351 }
352 /^X\(\/\/\)[^/].*/{
353 s//\1/
354 q
355 }
356 /^X\(\/\/\)$/{
357 s//\1/
358 q
359 }
360 /^X\(\/\).*/{
361 s//\1/
362 q
363 }
364 s/.*/./; q'`
365 test -d "$as_dir" && break
366 done
367 test -z "$as_dirs" || eval "mkdir $as_dirs"
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200368 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
Matthias Kloseb9621712010-04-24 17:59:49 +0000369
370
371} # as_fn_mkdir_p
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000372
373# as_fn_executable_p FILE
374# -----------------------
375# Test if FILE is an executable regular file.
376as_fn_executable_p ()
377{
378 test -f "$1" && test -x "$1"
379} # as_fn_executable_p
Matthias Kloseb9621712010-04-24 17:59:49 +0000380# as_fn_append VAR VALUE
381# ----------------------
382# Append the text in VALUE to the end of the definition contained in VAR. Take
383# advantage of any shell optimizations that allow amortized linear growth over
384# repeated appends, instead of the typical quadratic growth present in naive
385# implementations.
Pablo Galindoba421752021-05-03 20:33:17 +0100386if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
387then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000388 eval 'as_fn_append ()
389 {
390 eval $1+=\$2
391 }'
Pablo Galindoba421752021-05-03 20:33:17 +0100392else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000393 as_fn_append ()
394 {
395 eval $1=\$$1\$2
396 }
397fi # as_fn_append
398
399# as_fn_arith ARG...
400# ------------------
401# Perform arithmetic evaluation on the ARGs, and store the result in the
402# global $as_val. Take advantage of shells that can avoid forks. The arguments
403# must be portable across $(()) and expr.
Pablo Galindoba421752021-05-03 20:33:17 +0100404if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
405then :
Matthias Kloseb9621712010-04-24 17:59:49 +0000406 eval 'as_fn_arith ()
407 {
408 as_val=$(( $* ))
409 }'
Pablo Galindoba421752021-05-03 20:33:17 +0100410else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000411 as_fn_arith ()
412 {
413 as_val=`expr "$@" || test $? -eq 1`
414 }
415fi # as_fn_arith
416
Pablo Galindoba421752021-05-03 20:33:17 +0100417# as_fn_nop
418# ---------
419# Do nothing but, unlike ":", preserve the value of $?.
420as_fn_nop ()
421{
422 return $?
423}
424as_nop=as_fn_nop
Matthias Kloseb9621712010-04-24 17:59:49 +0000425
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200426# as_fn_error STATUS ERROR [LINENO LOG_FD]
427# ----------------------------------------
Matthias Kloseb9621712010-04-24 17:59:49 +0000428# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
429# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200430# script with STATUS, using 1 if that was 0.
Matthias Kloseb9621712010-04-24 17:59:49 +0000431as_fn_error ()
432{
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200433 as_status=$1; test $as_status -eq 0 && as_status=1
434 if test "$4"; then
435 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +0100436 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
Matthias Kloseb9621712010-04-24 17:59:49 +0000437 fi
Pablo Galindoba421752021-05-03 20:33:17 +0100438 printf "%s\n" "$as_me: error: $2" >&2
Matthias Kloseb9621712010-04-24 17:59:49 +0000439 as_fn_exit $as_status
440} # as_fn_error
441
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000442if expr a : '\(a\)' >/dev/null 2>&1 &&
443 test "X`expr 00001 : '.*\(...\)'`" = X001; then
444 as_expr=expr
445else
446 as_expr=false
447fi
448
449if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
450 as_basename=basename
451else
452 as_basename=false
453fi
454
Matthias Kloseb9621712010-04-24 17:59:49 +0000455if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
456 as_dirname=dirname
457else
458 as_dirname=false
459fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000460
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000461as_me=`$as_basename -- "$0" ||
462$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
463 X"$0" : 'X\(//\)$' \| \
464 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +0100465printf "%s\n" X/"$0" |
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000466 sed '/^.*\/\([^/][^/]*\)\/*$/{
467 s//\1/
468 q
469 }
470 /^X\/\(\/\/\)$/{
471 s//\1/
472 q
473 }
474 /^X\/\(\/\).*/{
475 s//\1/
476 q
477 }
478 s/.*/./; q'`
479
Matthias Kloseb9621712010-04-24 17:59:49 +0000480# Avoid depending upon Character Ranges.
481as_cr_letters='abcdefghijklmnopqrstuvwxyz'
482as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
483as_cr_Letters=$as_cr_letters$as_cr_LETTERS
484as_cr_digits='0123456789'
485as_cr_alnum=$as_cr_Letters$as_cr_digits
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000486
487
Matthias Kloseb9621712010-04-24 17:59:49 +0000488 as_lineno_1=$LINENO as_lineno_1a=$LINENO
489 as_lineno_2=$LINENO as_lineno_2a=$LINENO
490 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
491 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
492 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000493 sed -n '
494 p
495 /[$]LINENO/=
496 ' <$as_myself |
Martin v. Löwis11437992002-04-12 09:54:03 +0000497 sed '
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000498 s/[$]LINENO.*/&-/
499 t lineno
500 b
501 :lineno
Martin v. Löwis11437992002-04-12 09:54:03 +0000502 N
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000503 :loop
504 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
Martin v. Löwis11437992002-04-12 09:54:03 +0000505 t loop
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000506 s/-\n.*//
Martin v. Löwis11437992002-04-12 09:54:03 +0000507 ' >$as_me.lineno &&
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000508 chmod +x "$as_me.lineno" ||
Pablo Galindoba421752021-05-03 20:33:17 +0100509 { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
Martin v. Löwis11437992002-04-12 09:54:03 +0000510
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000511 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
512 # already done that, so ensure we don't try to do so again and fall
513 # in an infinite loop. This has already happened in practice.
514 _as_can_reexec=no; export _as_can_reexec
Martin v. Löwis11437992002-04-12 09:54:03 +0000515 # Don't try to exec as it changes $[0], causing all sort of problems
516 # (the dirname of $[0] is not the place where we might find the
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000517 # original and so on. Autoconf is especially sensitive to this).
518 . "./$as_me.lineno"
Martin v. Löwis11437992002-04-12 09:54:03 +0000519 # Exit status is that of the last command.
520 exit
521}
522
Pablo Galindoba421752021-05-03 20:33:17 +0100523
524# Determine whether it's possible to make 'echo' print without a newline.
525# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
526# for compatibility with existing Makefiles.
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000527ECHO_C= ECHO_N= ECHO_T=
Matthias Kloseb9621712010-04-24 17:59:49 +0000528case `echo -n x` in #(((((
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000529-n*)
Matthias Kloseb9621712010-04-24 17:59:49 +0000530 case `echo 'xy\c'` in
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000531 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
Matthias Kloseb9621712010-04-24 17:59:49 +0000532 xy) ECHO_C='\c';;
533 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
534 ECHO_T=' ';;
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000535 esac;;
536*)
537 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +0000538esac
Ronald Oussoren74f29b42009-09-20 20:09:26 +0000539
Pablo Galindoba421752021-05-03 20:33:17 +0100540# For backward compatibility with old third-party macros, we provide
541# the shell variables $as_echo and $as_echo_n. New code should use
542# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
543as_echo='printf %s\n'
544as_echo_n='printf %s'
545
546
Martin v. Löwis11437992002-04-12 09:54:03 +0000547rm -f conf$$ conf$$.exe conf$$.file
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000548if test -d conf$$.dir; then
549 rm -f conf$$.dir/conf$$.file
550else
551 rm -f conf$$.dir
Matthias Kloseb9621712010-04-24 17:59:49 +0000552 mkdir conf$$.dir 2>/dev/null
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000553fi
Matthias Kloseb9621712010-04-24 17:59:49 +0000554if (echo >conf$$.file) 2>/dev/null; then
555 if ln -s conf$$.file conf$$ 2>/dev/null; then
556 as_ln_s='ln -s'
557 # ... but there are two gotchas:
558 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
559 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000560 # In both cases, we have to default to `cp -pR'.
Matthias Kloseb9621712010-04-24 17:59:49 +0000561 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000562 as_ln_s='cp -pR'
Matthias Kloseb9621712010-04-24 17:59:49 +0000563 elif ln conf$$.file conf$$ 2>/dev/null; then
564 as_ln_s=ln
565 else
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000566 as_ln_s='cp -pR'
Matthias Kloseb9621712010-04-24 17:59:49 +0000567 fi
Martin v. Löwis11437992002-04-12 09:54:03 +0000568else
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000569 as_ln_s='cp -pR'
Martin v. Löwis11437992002-04-12 09:54:03 +0000570fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000571rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
572rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +0000573
Skip Montanaro6dead952003-09-25 14:50:04 +0000574if mkdir -p . 2>/dev/null; then
Matthias Kloseb9621712010-04-24 17:59:49 +0000575 as_mkdir_p='mkdir -p "$as_dir"'
Skip Montanaro6dead952003-09-25 14:50:04 +0000576else
Skip Montanarof0d5f792004-08-15 14:08:23 +0000577 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +0000578 as_mkdir_p=false
579fi
580
Ross Lagerwall1b863eb2012-10-29 17:31:54 +0000581as_test_x='test -x'
582as_executable_p=as_fn_executable_p
Martin v. Löwis11437992002-04-12 09:54:03 +0000583
584# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000585as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +0000586
587# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000588as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +0000589
590
Matthias Kloseb9621712010-04-24 17:59:49 +0000591test -n "$DJDIR" || exec 7<&0 </dev/null
592exec 6>&1
Martin v. Löwis11437992002-04-12 09:54:03 +0000593
594# Name of the host.
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200595# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
Martin v. Löwis11437992002-04-12 09:54:03 +0000596# so uname gets run too.
597ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
598
Martin v. Löwis11437992002-04-12 09:54:03 +0000599#
600# Initializations.
601#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000602ac_default_prefix=/usr/local
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000603ac_clean_files=
Skip Montanaro6dead952003-09-25 14:50:04 +0000604ac_config_libobj_dir=.
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000605LIBOBJS=
Martin v. Löwis11437992002-04-12 09:54:03 +0000606cross_compiling=no
607subdirs=
608MFLAGS=
609MAKEFLAGS=
Martin v. Löwis11437992002-04-12 09:54:03 +0000610
Martin v. Löwis11437992002-04-12 09:54:03 +0000611# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000612PACKAGE_NAME='python'
613PACKAGE_TARNAME='python'
Pablo Galindod4fe0982020-05-19 03:33:01 +0100614PACKAGE_VERSION='3.10'
615PACKAGE_STRING='python 3.10'
Benjamin Petersonc2fcbf42016-08-03 22:01:32 -0700616PACKAGE_BUGREPORT='https://bugs.python.org/'
Matthias Kloseb9621712010-04-24 17:59:49 +0000617PACKAGE_URL=''
Martin v. Löwis11437992002-04-12 09:54:03 +0000618
619ac_unique_file="Include/object.h"
620# Factoring default headers for most tests.
621ac_includes_default="\
Pablo Galindoba421752021-05-03 20:33:17 +0100622#include <stddef.h>
623#ifdef HAVE_STDIO_H
624# include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +0000625#endif
Pablo Galindoba421752021-05-03 20:33:17 +0100626#ifdef HAVE_STDLIB_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000627# include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +0000628#endif
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000629#ifdef HAVE_STRING_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000630# include <string.h>
631#endif
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000632#ifdef HAVE_INTTYPES_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000633# include <inttypes.h>
Thomas Wouters477c8d52006-05-27 19:21:47 +0000634#endif
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000635#ifdef HAVE_STDINT_H
636# include <stdint.h>
637#endif
Pablo Galindoba421752021-05-03 20:33:17 +0100638#ifdef HAVE_STRINGS_H
639# include <strings.h>
640#endif
641#ifdef HAVE_SYS_TYPES_H
642# include <sys/types.h>
643#endif
644#ifdef HAVE_SYS_STAT_H
645# include <sys/stat.h>
646#endif
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000647#ifdef HAVE_UNISTD_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000648# include <unistd.h>
649#endif"
650
Pablo Galindoba421752021-05-03 20:33:17 +0100651ac_header_c_list=
Matthias Kloseb9621712010-04-24 17:59:49 +0000652ac_subst_vars='LTLIBOBJS
pxinwr277ce302020-12-30 20:50:39 +0800653TEST_MODULES
Victor Stinner801bb0b2021-02-17 11:14:42 +0100654LIBRARY_DEPS
655STATIC_LIBPYTHON
Christian Heimes32eba612021-03-19 10:29:25 +0100656OPENSSL_RPATH
Christian Heimesff5be6e2018-01-20 13:19:21 +0100657OPENSSL_LDFLAGS
658OPENSSL_LIBS
659OPENSSL_INCLUDES
Ned Deily322f5ba2013-11-21 23:01:59 -0800660ENSUREPIP
Ronald Oussoren74f29b42009-09-20 20:09:26 +0000661SRCDIRS
Matthias Kloseb9621712010-04-24 17:59:49 +0000662THREADHEADERS
Victor Stinner75e59a92021-01-20 17:07:21 +0100663WHEEL_PKG_DIR
doko@python.org87421192013-01-26 11:39:31 +0100664LIBPL
665PY_ENABLE_SHARED
Victor Stinner8510f432020-03-10 09:53:09 +0100666PLATLIBDIR
Victor Stinner51ae31e2020-06-09 15:32:43 +0200667BINLIBDEST
xdegaye254b3092019-04-29 09:27:40 +0200668LIBPYTHON
doko@ubuntu.comd5537d02013-03-21 13:21:49 -0700669EXT_SUFFIX
Victor Stinner5422e3c2019-04-26 01:40:00 +0200670ALT_SOABI
Barry Warsaw35f3a2c2010-09-03 18:30:30 +0000671SOABI
Matthias Kloseb9621712010-04-24 17:59:49 +0000672LIBC
673LIBM
674HAVE_GETHOSTBYNAME
675HAVE_GETHOSTBYNAME_R
676HAVE_GETHOSTBYNAME_R_3_ARG
677HAVE_GETHOSTBYNAME_R_5_ARG
678HAVE_GETHOSTBYNAME_R_6_ARG
679LIBOBJS
680TRUE
681MACHDEP_OBJS
682DYNLOADFILE
683DLINCLDIR
Łukasz Langaa785c872016-09-09 17:37:37 -0700684DTRACE_OBJS
685DTRACE_HEADERS
686DFLAGS
687DTRACE
Ned Deilyd819b932013-09-06 01:07:05 -0700688TCLTK_LIBS
689TCLTK_INCLUDES
Matthias Kloseb9621712010-04-24 17:59:49 +0000690LIBFFI_INCLUDEDIR
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +0800691PKG_CONFIG_LIBDIR
692PKG_CONFIG_PATH
693PKG_CONFIG
Paul Ganssle62972d92020-05-16 04:20:06 -0400694TZPATH
Matthias Kloseb9621712010-04-24 17:59:49 +0000695SHLIBS
696CFLAGSFORSHARED
697LINKFORSHARED
698CCSHARED
699BLDSHARED
700LDCXXSHARED
701LDSHARED
doko@ubuntu.comd5537d02013-03-21 13:21:49 -0700702SHLIB_SUFFIX
Matthias Kloseb9621712010-04-24 17:59:49 +0000703LIBTOOL_CRUFT
704OTHER_LIBTOOL_OPT
Pablo Galindoba421752021-05-03 20:33:17 +0100705EGREP
Matthias Kloseb9621712010-04-24 17:59:49 +0000706UNIVERSAL_ARCH_FLAGS
stratakiscf10a752018-12-19 18:19:01 +0100707LDFLAGS_NODIST
Benjamin Petersonacb8c522014-08-09 20:01:49 -0700708CFLAGS_NODIST
Matthias Kloseb9621712010-04-24 17:59:49 +0000709BASECFLAGS
Victor Stinner826f83f2017-04-28 15:07:10 +0200710CFLAGS_ALIASING
Matthias Kloseb9621712010-04-24 17:59:49 +0000711OPT
Brett Cannon7188a3e2015-09-18 15:13:44 -0700712LLVM_PROF_FOUND
Gregory P. Smith799520c2016-09-07 16:10:00 -0700713LLVM_PROFDATA
Brett Cannon7188a3e2015-09-18 15:13:44 -0700714LLVM_PROF_ERR
715LLVM_PROF_FILE
716LLVM_PROF_MERGER
717PGO_PROF_USE_FLAG
718PGO_PROF_GEN_FLAG
serge-sans-paille5ad36f92018-10-25 01:54:22 +0200719LLVM_AR_FOUND
serge-sans-paille5ad36f92018-10-25 01:54:22 +0200720LLVM_AR
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -0700721PROFILE_TASK
Brett Cannon63d98bc2016-09-06 17:12:40 -0700722DEF_MAKE_RULE
723DEF_MAKE_ALL_RULE
Barry Warsaw8cf4eae2010-10-16 01:04:07 +0000724ABIFLAGS
Matthias Kloseb9621712010-04-24 17:59:49 +0000725LN
Matthias Klose93a0ef12012-03-15 18:08:34 +0100726MKDIR_P
Matthias Kloseb9621712010-04-24 17:59:49 +0000727INSTALL_DATA
728INSTALL_SCRIPT
729INSTALL_PROGRAM
doko@ubuntu.com58844492012-06-30 18:25:32 +0200730ac_ct_READELF
731READELF
Matthias Kloseb9621712010-04-24 17:59:49 +0000732ARFLAGS
doko@ubuntu.com51f65942012-06-30 14:42:46 +0200733ac_ct_AR
Matthias Kloseb9621712010-04-24 17:59:49 +0000734AR
Matthias Kloseb9621712010-04-24 17:59:49 +0000735GNULD
Stefan Krahe6dcd372020-08-29 17:00:08 +0200736EXPORTSFROM
737EXPORTSYMS
Matthias Kloseb9621712010-04-24 17:59:49 +0000738LINKCC
Barry Warsaw8cf4eae2010-10-16 01:04:07 +0000739LDVERSION
Matthias Kloseb9621712010-04-24 17:59:49 +0000740RUNSHARED
741INSTSONAME
742LDLIBRARYDIR
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000743PY3LIBRARY
Matthias Kloseb9621712010-04-24 17:59:49 +0000744BLDLIBRARY
745DLLLIBRARY
746LDLIBRARY
747LIBRARY
748BUILDEXEEXT
Martin v. Löwis48e14d32011-05-09 07:37:45 +0200749NO_AS_NEEDED
doko@ubuntu.com55532312016-06-14 08:55:19 +0200750MULTIARCH_CPPFLAGS
doko@ubuntu.comd3899c12015-04-15 20:23:14 +0200751PLATFORM_TRIPLET
752MULTIARCH
doko@ubuntu.com51f65942012-06-30 14:42:46 +0200753ac_ct_CXX
Matthias Kloseb9621712010-04-24 17:59:49 +0000754MAINCC
755CXX
Łukasz Langaa785c872016-09-09 17:37:37 -0700756SED
doko@ubuntu.comd3899c12015-04-15 20:23:14 +0200757GREP
758CPP
Matthias Kloseb9621712010-04-24 17:59:49 +0000759OBJEXT
760EXEEXT
761ac_ct_CC
762CPPFLAGS
763LDFLAGS
764CFLAGS
765CC
766EXPORT_MACOSX_DEPLOYMENT_TARGET
767CONFIGURE_MACOSX_DEPLOYMENT_TARGET
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200768_PYTHON_HOST_PLATFORM
Matthias Kloseb9621712010-04-24 17:59:49 +0000769MACHDEP
Ronald Oussoren86b33c82010-04-30 11:41:56 +0000770FRAMEWORKINSTALLAPPSPREFIX
Matthias Kloseb9621712010-04-24 17:59:49 +0000771FRAMEWORKUNIXTOOLSPREFIX
Ned Deilyb8f944f2013-11-21 22:42:25 -0800772FRAMEWORKPYTHONW
Matthias Kloseb9621712010-04-24 17:59:49 +0000773FRAMEWORKALTINSTALLLAST
774FRAMEWORKALTINSTALLFIRST
775FRAMEWORKINSTALLLAST
776FRAMEWORKINSTALLFIRST
777PYTHONFRAMEWORKINSTALLDIR
778PYTHONFRAMEWORKPREFIX
779PYTHONFRAMEWORKDIR
780PYTHONFRAMEWORKIDENTIFIER
781PYTHONFRAMEWORK
Ned Deily0cb33da2021-05-02 04:48:29 -0400782LIPO_INTEL64_FLAGS
Matthias Kloseb9621712010-04-24 17:59:49 +0000783LIPO_32BIT_FLAGS
784ARCH_RUN_32BIT
785UNIVERSALSDK
786CONFIG_ARGS
787SOVERSION
788VERSION
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200789PYTHON_FOR_BUILD
Victor Stinnera5c62a82017-05-03 18:21:48 +0200790PYTHON_FOR_REGEN
Matthias Kloseca2f6ec2012-03-15 21:30:11 +0100791host_os
792host_vendor
793host_cpu
794host
795build_os
796build_vendor
797build_cpu
798build
Ned Deily5c4b0d02017-03-04 00:19:55 -0500799HAS_GIT
800GITBRANCH
801GITTAG
802GITVERSION
Trent Nelson4d4ec652012-10-16 08:51:24 -0400803BASECPPFLAGS
Matthias Kloseb9621712010-04-24 17:59:49 +0000804target_alias
805host_alias
806build_alias
807LIBS
808ECHO_T
809ECHO_N
810ECHO_C
811DEFS
812mandir
813localedir
814libdir
815psdir
816pdfdir
817dvidir
818htmldir
819infodir
820docdir
821oldincludedir
822includedir
Pablo Galindoba421752021-05-03 20:33:17 +0100823runstatedir
Matthias Kloseb9621712010-04-24 17:59:49 +0000824localstatedir
825sharedstatedir
826sysconfdir
827datadir
828datarootdir
829libexecdir
830sbindir
831bindir
832program_transform_name
833prefix
834exec_prefix
835PACKAGE_URL
836PACKAGE_BUGREPORT
837PACKAGE_STRING
838PACKAGE_VERSION
839PACKAGE_TARNAME
840PACKAGE_NAME
841PATH_SEPARATOR
842SHELL'
Skip Montanaro6dead952003-09-25 14:50:04 +0000843ac_subst_files=''
Matthias Kloseb9621712010-04-24 17:59:49 +0000844ac_user_opts='
845enable_option_checking
846enable_universalsdk
847with_universal_archs
848with_framework_name
849enable_framework
Matthias Kloseb9621712010-04-24 17:59:49 +0000850with_cxx_main
851with_suffix
852enable_shared
853enable_profiling
854with_pydebug
Victor Stinnerf4e47032019-04-25 00:56:28 +0200855with_trace_refs
T. Woutersddbfa2c2017-05-23 01:30:49 +0200856with_assertions
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +0000857enable_optimizations
Gregory P. Smithd82da9f2016-04-15 16:57:04 -0700858with_lto
Christian Heimes985ecdc2013-11-20 11:46:18 +0100859with_hash_algorithm
Paul Ganssle62972d92020-05-16 04:20:06 -0400860with_tzpath
Charles-François Natalid30b0222014-05-08 23:08:51 +0100861with_address_sanitizer
Gregory P. Smith1584a002018-11-12 12:07:14 -0800862with_memory_sanitizer
863with_undefined_behavior_sanitizer
Matthias Kloseb9621712010-04-24 17:59:49 +0000864with_libs
865with_system_expat
866with_system_ffi
Stefan Krah60187b52012-03-23 19:06:27 +0100867with_system_libmpdec
Stefan Krah815280e2020-02-29 19:43:42 +0100868with_decimal_contextvar
Benjamin Peterson076ed002010-10-31 17:11:02 +0000869enable_loadable_sqlite_extensions
Ned Deilyd819b932013-09-06 01:07:05 -0700870with_tcltk_includes
871with_tcltk_libs
Matthias Kloseb9621712010-04-24 17:59:49 +0000872with_dbmliborder
Matthias Kloseb9621712010-04-24 17:59:49 +0000873enable_ipv6
874with_doc_strings
Matthias Kloseb9621712010-04-24 17:59:49 +0000875with_pymalloc
Nick Coghlan6ea41862017-06-11 13:16:15 +1000876with_c_locale_coercion
Matthias Kloseb9621712010-04-24 17:59:49 +0000877with_valgrind
Łukasz Langaa785c872016-09-09 17:37:37 -0700878with_dtrace
Matthias Kloseb9621712010-04-24 17:59:49 +0000879with_libm
880with_libc
881enable_big_digits
Victor Stinner8510f432020-03-10 09:53:09 +0100882with_platlibdir
Victor Stinner75e59a92021-01-20 17:07:21 +0100883with_wheel_pkg_dir
Roland Hiebere1f77692021-02-09 02:05:25 +0100884with_readline
Matthias Kloseb9621712010-04-24 17:59:49 +0000885with_computed_gotos
Ned Deily322f5ba2013-11-21 23:01:59 -0800886with_ensurepip
Christian Heimesff5be6e2018-01-20 13:19:21 +0100887with_openssl
Christian Heimes32eba612021-03-19 10:29:25 +0100888with_openssl_rpath
Christian Heimes892d66e2018-01-29 14:10:18 +0100889with_ssl_default_suites
Christian Heimes9b60e552020-05-15 23:54:53 +0200890with_builtin_hashlib_hashes
Victor Stinnerc5fa3642020-05-05 16:41:11 +0200891with_experimental_isolated_subinterpreters
Victor Stinner801bb0b2021-02-17 11:14:42 +0100892with_static_libpython
pxinwr277ce302020-12-30 20:50:39 +0800893enable_test_modules
Matthias Kloseb9621712010-04-24 17:59:49 +0000894'
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000895 ac_precious_vars='build_alias
896host_alias
897target_alias
doko@python.orgeab42bf2013-01-26 18:57:19 +0100898MACHDEP
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000899CC
900CFLAGS
901LDFLAGS
902LIBS
903CPPFLAGS
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +0800904CPP
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -0700905PROFILE_TASK
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +0800906PKG_CONFIG
907PKG_CONFIG_PATH
908PKG_CONFIG_LIBDIR'
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000909
Guido van Rossum627b2d71993-12-24 10:39:16 +0000910
Guido van Rossum7f43da71994-08-01 12:15:30 +0000911# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000912ac_init_help=
913ac_init_version=false
Matthias Kloseb9621712010-04-24 17:59:49 +0000914ac_unrecognized_opts=
915ac_unrecognized_sep=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000916# The variables have the same names as the options, with
917# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000918cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000919exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000920no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000921no_recursion=
922prefix=NONE
923program_prefix=NONE
924program_suffix=NONE
925program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000926silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000927site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000928srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000929verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000930x_includes=NONE
931x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000932
933# Installation directory options.
934# These are left unexpanded so users can "make install exec_prefix=/foo"
935# and all the variables that are supposed to be based on exec_prefix
936# by default will actually change.
937# Use braces instead of parens because sh, perl, etc. also accept them.
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000938# (The list follows the same order as the GNU Coding Standards.)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000939bindir='${exec_prefix}/bin'
940sbindir='${exec_prefix}/sbin'
941libexecdir='${exec_prefix}/libexec'
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000942datarootdir='${prefix}/share'
943datadir='${datarootdir}'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000944sysconfdir='${prefix}/etc'
945sharedstatedir='${prefix}/com'
946localstatedir='${prefix}/var'
Pablo Galindoba421752021-05-03 20:33:17 +0100947runstatedir='${localstatedir}/run'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000948includedir='${prefix}/include'
949oldincludedir='/usr/include'
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000950docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
951infodir='${datarootdir}/info'
952htmldir='${docdir}'
953dvidir='${docdir}'
954pdfdir='${docdir}'
955psdir='${docdir}'
956libdir='${exec_prefix}/lib'
957localedir='${datarootdir}/locale'
958mandir='${datarootdir}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000959
Guido van Rossum7f43da71994-08-01 12:15:30 +0000960ac_prev=
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000961ac_dashdash=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000962for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000963do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000964 # If the previous option needs an argument, assign it.
965 if test -n "$ac_prev"; then
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000966 eval $ac_prev=\$ac_option
Guido van Rossum7f43da71994-08-01 12:15:30 +0000967 ac_prev=
968 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000969 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000970
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000971 case $ac_option in
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +0200972 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
973 *=) ac_optarg= ;;
974 *) ac_optarg=yes ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000975 esac
Guido van Rossum7f43da71994-08-01 12:15:30 +0000976
Thomas Wouters47b49bf2007-08-30 22:15:33 +0000977 case $ac_dashdash$ac_option in
978 --)
979 ac_dashdash=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000980
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000981 -bindir | --bindir | --bindi | --bind | --bin | --bi)
982 ac_prev=bindir ;;
983 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000984 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000985
986 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000987 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000988 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000989 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000990
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000991 -cache-file | --cache-file | --cache-fil | --cache-fi \
992 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
993 ac_prev=cache_file ;;
994 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
995 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000996 cache_file=$ac_optarg ;;
997
998 --config-cache | -C)
999 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001000
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001001 -datadir | --datadir | --datadi | --datad)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001002 ac_prev=datadir ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001003 -datadir=* | --datadir=* | --datadi=* | --datad=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001004 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001005
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001006 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1007 | --dataroo | --dataro | --datar)
1008 ac_prev=datarootdir ;;
1009 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1010 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1011 datarootdir=$ac_optarg ;;
1012
Guido van Rossum7f43da71994-08-01 12:15:30 +00001013 -disable-* | --disable-*)
Matthias Kloseb9621712010-04-24 17:59:49 +00001014 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001015 # Reject names that are not valid shell variable names.
Matthias Kloseb9621712010-04-24 17:59:49 +00001016 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
Pablo Galindoba421752021-05-03 20:33:17 +01001017 as_fn_error $? "invalid feature name: \`$ac_useropt'"
Matthias Kloseb9621712010-04-24 17:59:49 +00001018 ac_useropt_orig=$ac_useropt
Pablo Galindoba421752021-05-03 20:33:17 +01001019 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
Matthias Kloseb9621712010-04-24 17:59:49 +00001020 case $ac_user_opts in
1021 *"
1022"enable_$ac_useropt"
1023"*) ;;
1024 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1025 ac_unrecognized_sep=', ';;
1026 esac
1027 eval enable_$ac_useropt=no ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001028
1029 -docdir | --docdir | --docdi | --doc | --do)
1030 ac_prev=docdir ;;
1031 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1032 docdir=$ac_optarg ;;
1033
1034 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1035 ac_prev=dvidir ;;
1036 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1037 dvidir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001038
1039 -enable-* | --enable-*)
Matthias Kloseb9621712010-04-24 17:59:49 +00001040 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001041 # Reject names that are not valid shell variable names.
Matthias Kloseb9621712010-04-24 17:59:49 +00001042 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
Pablo Galindoba421752021-05-03 20:33:17 +01001043 as_fn_error $? "invalid feature name: \`$ac_useropt'"
Matthias Kloseb9621712010-04-24 17:59:49 +00001044 ac_useropt_orig=$ac_useropt
Pablo Galindoba421752021-05-03 20:33:17 +01001045 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
Matthias Kloseb9621712010-04-24 17:59:49 +00001046 case $ac_user_opts in
1047 *"
1048"enable_$ac_useropt"
1049"*) ;;
1050 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1051 ac_unrecognized_sep=', ';;
1052 esac
1053 eval enable_$ac_useropt=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001054
Guido van Rossum7f43da71994-08-01 12:15:30 +00001055 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1056 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1057 | --exec | --exe | --ex)
1058 ac_prev=exec_prefix ;;
1059 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1060 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1061 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001062 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001063
1064 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001065 # Obsolete; use --with-gas.
1066 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001067
Martin v. Löwis11437992002-04-12 09:54:03 +00001068 -help | --help | --hel | --he | -h)
1069 ac_init_help=long ;;
1070 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1071 ac_init_help=recursive ;;
1072 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1073 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001074
1075 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +00001076 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001077 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001078 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001079
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001080 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1081 ac_prev=htmldir ;;
1082 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1083 | --ht=*)
1084 htmldir=$ac_optarg ;;
1085
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001086 -includedir | --includedir | --includedi | --included | --include \
1087 | --includ | --inclu | --incl | --inc)
1088 ac_prev=includedir ;;
1089 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1090 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001091 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001092
1093 -infodir | --infodir | --infodi | --infod | --info | --inf)
1094 ac_prev=infodir ;;
1095 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001096 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001097
1098 -libdir | --libdir | --libdi | --libd)
1099 ac_prev=libdir ;;
1100 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001101 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001102
1103 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1104 | --libexe | --libex | --libe)
1105 ac_prev=libexecdir ;;
1106 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1107 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001108 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001109
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001110 -localedir | --localedir | --localedi | --localed | --locale)
1111 ac_prev=localedir ;;
1112 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1113 localedir=$ac_optarg ;;
1114
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001115 -localstatedir | --localstatedir | --localstatedi | --localstated \
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001116 | --localstate | --localstat | --localsta | --localst | --locals)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001117 ac_prev=localstatedir ;;
1118 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001119 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001120 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001121
1122 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1123 ac_prev=mandir ;;
1124 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001125 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001126
Guido van Rossum7f43da71994-08-01 12:15:30 +00001127 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001128 # Obsolete; use --without-fp.
1129 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001130
1131 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +00001133 no_create=yes ;;
1134
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001135 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1136 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1137 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001138
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001139 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1140 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1141 | --oldin | --oldi | --old | --ol | --o)
1142 ac_prev=oldincludedir ;;
1143 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1144 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1145 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001146 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001147
Guido van Rossum7f43da71994-08-01 12:15:30 +00001148 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1149 ac_prev=prefix ;;
1150 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001151 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001152
1153 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1154 | --program-pre | --program-pr | --program-p)
1155 ac_prev=program_prefix ;;
1156 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1157 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001158 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001159
1160 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1161 | --program-suf | --program-su | --program-s)
1162 ac_prev=program_suffix ;;
1163 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1164 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001165 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001166
1167 -program-transform-name | --program-transform-name \
1168 | --program-transform-nam | --program-transform-na \
1169 | --program-transform-n | --program-transform- \
1170 | --program-transform | --program-transfor \
1171 | --program-transfo | --program-transf \
1172 | --program-trans | --program-tran \
1173 | --progr-tra | --program-tr | --program-t)
1174 ac_prev=program_transform_name ;;
1175 -program-transform-name=* | --program-transform-name=* \
1176 | --program-transform-nam=* | --program-transform-na=* \
1177 | --program-transform-n=* | --program-transform-=* \
1178 | --program-transform=* | --program-transfor=* \
1179 | --program-transfo=* | --program-transf=* \
1180 | --program-trans=* | --program-tran=* \
1181 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001182 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001183
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001184 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1185 ac_prev=pdfdir ;;
1186 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1187 pdfdir=$ac_optarg ;;
1188
1189 -psdir | --psdir | --psdi | --psd | --ps)
1190 ac_prev=psdir ;;
1191 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1192 psdir=$ac_optarg ;;
1193
Guido van Rossum7f43da71994-08-01 12:15:30 +00001194 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1195 | -silent | --silent | --silen | --sile | --sil)
1196 silent=yes ;;
1197
Pablo Galindoba421752021-05-03 20:33:17 +01001198 -runstatedir | --runstatedir | --runstatedi | --runstated \
1199 | --runstate | --runstat | --runsta | --runst | --runs \
1200 | --run | --ru | --r)
1201 ac_prev=runstatedir ;;
1202 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1203 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1204 | --run=* | --ru=* | --r=*)
1205 runstatedir=$ac_optarg ;;
1206
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001207 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1208 ac_prev=sbindir ;;
1209 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1210 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001211 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001212
1213 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1214 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1215 | --sharedst | --shareds | --shared | --share | --shar \
1216 | --sha | --sh)
1217 ac_prev=sharedstatedir ;;
1218 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1219 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1220 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1221 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001222 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001223
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001224 -site | --site | --sit)
1225 ac_prev=site ;;
1226 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001227 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001228
Guido van Rossum7f43da71994-08-01 12:15:30 +00001229 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1230 ac_prev=srcdir ;;
1231 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001232 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001233
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001234 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1235 | --syscon | --sysco | --sysc | --sys | --sy)
1236 ac_prev=sysconfdir ;;
1237 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1238 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001239 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001240
Guido van Rossum7f43da71994-08-01 12:15:30 +00001241 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +00001242 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001243 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001244 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001245
1246 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1247 verbose=yes ;;
1248
Martin v. Löwis11437992002-04-12 09:54:03 +00001249 -version | --version | --versio | --versi | --vers | -V)
1250 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001251
1252 -with-* | --with-*)
Matthias Kloseb9621712010-04-24 17:59:49 +00001253 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001254 # Reject names that are not valid shell variable names.
Matthias Kloseb9621712010-04-24 17:59:49 +00001255 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
Pablo Galindoba421752021-05-03 20:33:17 +01001256 as_fn_error $? "invalid package name: \`$ac_useropt'"
Matthias Kloseb9621712010-04-24 17:59:49 +00001257 ac_useropt_orig=$ac_useropt
Pablo Galindoba421752021-05-03 20:33:17 +01001258 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
Matthias Kloseb9621712010-04-24 17:59:49 +00001259 case $ac_user_opts in
1260 *"
1261"with_$ac_useropt"
1262"*) ;;
1263 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1264 ac_unrecognized_sep=', ';;
1265 esac
1266 eval with_$ac_useropt=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001267
1268 -without-* | --without-*)
Matthias Kloseb9621712010-04-24 17:59:49 +00001269 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001270 # Reject names that are not valid shell variable names.
Matthias Kloseb9621712010-04-24 17:59:49 +00001271 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
Pablo Galindoba421752021-05-03 20:33:17 +01001272 as_fn_error $? "invalid package name: \`$ac_useropt'"
Matthias Kloseb9621712010-04-24 17:59:49 +00001273 ac_useropt_orig=$ac_useropt
Pablo Galindoba421752021-05-03 20:33:17 +01001274 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
Matthias Kloseb9621712010-04-24 17:59:49 +00001275 case $ac_user_opts in
1276 *"
1277"with_$ac_useropt"
1278"*) ;;
1279 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1280 ac_unrecognized_sep=', ';;
1281 esac
1282 eval with_$ac_useropt=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001283
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001284 --x)
1285 # Obsolete; use --with-x.
1286 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001287
1288 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1289 | --x-incl | --x-inc | --x-in | --x-i)
1290 ac_prev=x_includes ;;
1291 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1292 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001293 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001294
1295 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1296 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1297 ac_prev=x_libraries ;;
1298 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1299 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001300 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001301
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001302 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1303Try \`$0 --help' for more information"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001304 ;;
1305
Martin v. Löwis11437992002-04-12 09:54:03 +00001306 *=*)
1307 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1308 # Reject names that are not valid shell variable names.
Matthias Kloseb9621712010-04-24 17:59:49 +00001309 case $ac_envvar in #(
1310 '' | [0-9]* | *[!_$as_cr_alnum]* )
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001311 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
Matthias Kloseb9621712010-04-24 17:59:49 +00001312 esac
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001313 eval $ac_envvar=\$ac_optarg
Martin v. Löwis11437992002-04-12 09:54:03 +00001314 export $ac_envvar ;;
1315
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001316 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001317 # FIXME: should be removed in autoconf 3.0.
Pablo Galindoba421752021-05-03 20:33:17 +01001318 printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001319 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
Pablo Galindoba421752021-05-03 20:33:17 +01001320 printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
Victor Stinnere0be4232011-10-25 13:06:09 +02001321 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001322 ;;
1323
1324 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +00001325done
1326
Guido van Rossum7f43da71994-08-01 12:15:30 +00001327if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001328 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001329 as_fn_error $? "missing argument to $ac_option"
Guido van Rossum7f43da71994-08-01 12:15:30 +00001330fi
1331
Matthias Kloseb9621712010-04-24 17:59:49 +00001332if test -n "$ac_unrecognized_opts"; then
1333 case $enable_option_checking in
1334 no) ;;
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001335 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
Pablo Galindoba421752021-05-03 20:33:17 +01001336 *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
Matthias Kloseb9621712010-04-24 17:59:49 +00001337 esac
1338fi
1339
1340# Check all directory arguments for consistency.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001341for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1342 datadir sysconfdir sharedstatedir localstatedir includedir \
1343 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
Pablo Galindoba421752021-05-03 20:33:17 +01001344 libdir localedir mandir runstatedir
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001345do
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001346 eval ac_val=\$$ac_var
Matthias Kloseb9621712010-04-24 17:59:49 +00001347 # Remove trailing slashes.
1348 case $ac_val in
1349 */ )
1350 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1351 eval $ac_var=\$ac_val;;
1352 esac
1353 # Be sure to have absolute directory names.
Martin v. Löwis11437992002-04-12 09:54:03 +00001354 case $ac_val in
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001355 [\\/$]* | ?:[\\/]* ) continue;;
1356 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001357 esac
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001358 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
Martin v. Löwis11437992002-04-12 09:54:03 +00001359done
Guido van Rossum627b2d71993-12-24 10:39:16 +00001360
Martin v. Löwis11437992002-04-12 09:54:03 +00001361# There might be people who depend on the old broken behavior: `$host'
1362# used to hold the argument of --host etc.
1363# FIXME: To remove some day.
1364build=$build_alias
1365host=$host_alias
1366target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +00001367
Martin v. Löwis11437992002-04-12 09:54:03 +00001368# FIXME: To remove some day.
1369if test "x$host_alias" != x; then
1370 if test "x$build_alias" = x; then
1371 cross_compiling=maybe
Martin v. Löwis11437992002-04-12 09:54:03 +00001372 elif test "x$build_alias" != "x$host_alias"; then
1373 cross_compiling=yes
1374 fi
1375fi
1376
1377ac_tool_prefix=
1378test -n "$host_alias" && ac_tool_prefix=$host_alias-
1379
1380test "$silent" = yes && exec 6>/dev/null
1381
Guido van Rossum627b2d71993-12-24 10:39:16 +00001382
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001383ac_pwd=`pwd` && test -n "$ac_pwd" &&
1384ac_ls_di=`ls -di .` &&
1385ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001386 as_fn_error $? "working directory cannot be determined"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001387test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001388 as_fn_error $? "pwd does not report name of working directory"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001389
1390
Guido van Rossum627b2d71993-12-24 10:39:16 +00001391# Find the source files, if location was not specified.
1392if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00001393 ac_srcdir_defaulted=yes
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001394 # Try the directory containing this script, then the parent directory.
Matthias Kloseb9621712010-04-24 17:59:49 +00001395 ac_confdir=`$as_dirname -- "$as_myself" ||
1396$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1397 X"$as_myself" : 'X\(//\)[^/]' \| \
1398 X"$as_myself" : 'X\(//\)$' \| \
1399 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +01001400printf "%s\n" X"$as_myself" |
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001401 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1402 s//\1/
1403 q
1404 }
1405 /^X\(\/\/\)[^/].*/{
1406 s//\1/
1407 q
1408 }
1409 /^X\(\/\/\)$/{
1410 s//\1/
1411 q
1412 }
1413 /^X\(\/\).*/{
1414 s//\1/
1415 q
1416 }
1417 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001418 srcdir=$ac_confdir
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001419 if test ! -r "$srcdir/$ac_unique_file"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001420 srcdir=..
1421 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001422else
1423 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001424fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001425if test ! -r "$srcdir/$ac_unique_file"; then
1426 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001427 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
Thomas Wouters477c8d52006-05-27 19:21:47 +00001428fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001429ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1430ac_abs_confdir=`(
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001431 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001432 pwd)`
1433# When building in place, set srcdir=.
1434if test "$ac_abs_confdir" = "$ac_pwd"; then
1435 srcdir=.
1436fi
1437# Remove unnecessary trailing slashes from srcdir.
1438# Double slashes in file names in object file debugging info
1439# mess up M-x gdb in Emacs.
1440case $srcdir in
1441*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1442esac
1443for ac_var in $ac_precious_vars; do
1444 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1445 eval ac_env_${ac_var}_value=\$${ac_var}
1446 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1447 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1448done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001449
Martin v. Löwis11437992002-04-12 09:54:03 +00001450#
1451# Report the --help message.
1452#
1453if test "$ac_init_help" = "long"; then
1454 # Omit some internal or obsolete options to make the list less imposing.
1455 # This message is too long to be a string in the A/UX 3.1 sh.
1456 cat <<_ACEOF
Pablo Galindod4fe0982020-05-19 03:33:01 +01001457\`configure' configures python 3.10 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +00001458
1459Usage: $0 [OPTION]... [VAR=VALUE]...
1460
1461To assign environment variables (e.g., CC, CFLAGS...), specify them as
1462VAR=VALUE. See below for descriptions of some of the useful variables.
1463
1464Defaults for the options are specified in brackets.
1465
1466Configuration:
1467 -h, --help display this help and exit
1468 --help=short display options specific to this package
1469 --help=recursive display the short help of all the included packages
1470 -V, --version display version information and exit
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02001471 -q, --quiet, --silent do not print \`checking ...' messages
Martin v. Löwis11437992002-04-12 09:54:03 +00001472 --cache-file=FILE cache test results in FILE [disabled]
1473 -C, --config-cache alias for \`--cache-file=config.cache'
1474 -n, --no-create do not create output files
1475 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1476
Martin v. Löwis11437992002-04-12 09:54:03 +00001477Installation directories:
1478 --prefix=PREFIX install architecture-independent files in PREFIX
Matthias Kloseb9621712010-04-24 17:59:49 +00001479 [$ac_default_prefix]
Martin v. Löwis11437992002-04-12 09:54:03 +00001480 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
Matthias Kloseb9621712010-04-24 17:59:49 +00001481 [PREFIX]
Martin v. Löwis11437992002-04-12 09:54:03 +00001482
1483By default, \`make install' will install all the files in
1484\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1485an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1486for instance \`--prefix=\$HOME'.
1487
1488For better control, use the options below.
1489
1490Fine tuning of the installation directories:
Matthias Kloseb9621712010-04-24 17:59:49 +00001491 --bindir=DIR user executables [EPREFIX/bin]
1492 --sbindir=DIR system admin executables [EPREFIX/sbin]
1493 --libexecdir=DIR program executables [EPREFIX/libexec]
1494 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1495 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1496 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
Pablo Galindoba421752021-05-03 20:33:17 +01001497 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
Matthias Kloseb9621712010-04-24 17:59:49 +00001498 --libdir=DIR object code libraries [EPREFIX/lib]
1499 --includedir=DIR C header files [PREFIX/include]
1500 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1501 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1502 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1503 --infodir=DIR info documentation [DATAROOTDIR/info]
1504 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1505 --mandir=DIR man documentation [DATAROOTDIR/man]
1506 --docdir=DIR documentation root [DATAROOTDIR/doc/python]
1507 --htmldir=DIR html documentation [DOCDIR]
1508 --dvidir=DIR dvi documentation [DOCDIR]
1509 --pdfdir=DIR pdf documentation [DOCDIR]
1510 --psdir=DIR ps documentation [DOCDIR]
Martin v. Löwis11437992002-04-12 09:54:03 +00001511_ACEOF
1512
1513 cat <<\_ACEOF
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01001514
1515System types:
1516 --build=BUILD configure for building on BUILD [guessed]
1517 --host=HOST cross-compile to build programs to run on HOST [BUILD]
Martin v. Löwis11437992002-04-12 09:54:03 +00001518_ACEOF
1519fi
1520
1521if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +00001522 case $ac_init_help in
Pablo Galindod4fe0982020-05-19 03:33:01 +01001523 short | recursive ) echo "Configuration of python 3.10:";;
Martin v. Löwis88afe662002-10-26 13:47:44 +00001524 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001525 cat <<\_ACEOF
1526
1527Optional Features:
Matthias Kloseb9621712010-04-24 17:59:49 +00001528 --disable-option-checking ignore unrecognized --enable/--with options
Martin v. Löwis11437992002-04-12 09:54:03 +00001529 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1530 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Christian Heimes68f5fbe2008-02-14 08:27:37 +00001531 --enable-universalsdk[=SDKDIR]
Anthony Shaw2de064e2020-01-14 17:40:10 +11001532 create a universal binary build. SDKDIR specifies
1533 which macOS SDK should be used to perform the build,
1534 see Mac/README.rst. (default is no)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001535 --enable-framework[=INSTALLDIR]
Anthony Shaw2de064e2020-01-14 17:40:10 +11001536 create a Python.framework rather than a traditional
1537 Unix install. optional INSTALLDIR specifies the
1538 installation path. see Mac/README.rst (default is
1539 no)
1540 --enable-shared enable building a shared Python library (default is
1541 no)
1542 --enable-profiling enable C-level code profiling with gprof (default is
1543 no)
1544 --enable-optimizations enable expensive, stable optimizations (PGO, etc.)
1545 (default is no)
Benjamin Peterson076ed002010-10-31 17:11:02 +00001546 --enable-loadable-sqlite-extensions
Anthony Shaw2de064e2020-01-14 17:40:10 +11001547 support loadable extensions in _sqlite module, see
1548 Doc/library/sqlite3.rst (default is no)
1549 --enable-ipv6 enable ipv6 (with ipv4) support, see
1550 Doc/library/socket.rst (default is yes if supported)
1551 --enable-big-digits[=15|30]
1552 use big digits (30 or 15 bits) for Python longs
1553 (default is system-dependent)]
pxinwr277ce302020-12-30 20:50:39 +08001554 --disable-test-modules don't build nor install test modules
Martin v. Löwis11437992002-04-12 09:54:03 +00001555
1556Optional Packages:
1557 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1558 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Benjamin Peterson14ae9592008-07-16 02:20:15 +00001559 --with-universal-archs=ARCH
Ned Deily0cb33da2021-05-02 04:48:29 -04001560 specify the kind of macOS universal binary that
1561 should be created. This option is only valid when
Anthony Shaw2de064e2020-01-14 17:40:10 +11001562 --enable-universalsdk is set; options are:
Ned Deily0cb33da2021-05-02 04:48:29 -04001563 ("universal2", "intel-64", "intel-32", "intel",
1564 "32-bit", "64-bit", "3-way", or "all") see
1565 Mac/README.rst
Christian Heimes81ee3ef2008-05-04 22:42:01 +00001566 --with-framework-name=FRAMEWORK
Anthony Shaw2de064e2020-01-14 17:40:10 +11001567 specify the name for the python framework on macOS
1568 only valid when --enable-framework is set. see
1569 Mac/README.rst (default is 'Python')
1570 --with-cxx-main[=COMPILER]
1571 compile main() and link Python executable with C++
1572 compiler specified in COMPILER (default is $CXX)
1573 --with-suffix=SUFFIX set executable suffix to SUFFIX (default is '.exe')
1574 --with-pydebug build with Py_DEBUG defined (default is no)
Victor Stinnerf4e47032019-04-25 00:56:28 +02001575 --with-trace-refs enable tracing references for debugging purpose
Anthony Shaw2de064e2020-01-14 17:40:10 +11001576 (default is no)
1577 --with-assertions build with C assertions enabled (default is no)
1578 --with-lto enable Link-Time-Optimization in any build (default
1579 is no)
Christian Heimes985ecdc2013-11-20 11:46:18 +01001580 --with-hash-algorithm=[fnv|siphash24]
Anthony Shaw2de064e2020-01-14 17:40:10 +11001581 select hash algorithm for use in Python/pyhash.c
1582 (default is SipHash24)
Paul Ganssle62972d92020-05-16 04:20:06 -04001583 --with-tzpath=<list of absolute paths separated by pathsep>
1584 Select the default time zone search path for zoneinfo.TZPATH
1585
Charles-François Natalid30b0222014-05-08 23:08:51 +01001586 --with-address-sanitizer
Anthony Shaw2de064e2020-01-14 17:40:10 +11001587 enable AddressSanitizer memory error detector,
1588 'asan' (default is no)
1589 --with-memory-sanitizer enable MemorySanitizer allocation error detector,
1590 'msan' (default is no)
Gregory P. Smith1584a002018-11-12 12:07:14 -08001591 --with-undefined-behavior-sanitizer
Anthony Shaw2de064e2020-01-14 17:40:10 +11001592 enable UndefinedBehaviorSanitizer undefined
1593 behaviour detector, 'ubsan' (default is no)
1594 --with-libs='lib1 ...' link against additional libs (default is no)
Benjamin Petersonb2d90462009-12-31 03:23:10 +00001595 --with-system-expat build pyexpat module using an installed expat
Anthony Shaw2de064e2020-01-14 17:40:10 +11001596 library, see Doc/library/pyexpat.rst (default is no)
1597 --with-system-ffi build _ctypes module using an installed ffi library,
1598 see Doc/library/ctypes.rst (default is
1599 system-dependent)
Stefan Krah60187b52012-03-23 19:06:27 +01001600 --with-system-libmpdec build _decimal module using an installed libmpdec
Anthony Shaw2de064e2020-01-14 17:40:10 +11001601 library, see Doc/library/decimal.rst (default is no)
Stefan Krah815280e2020-02-29 19:43:42 +01001602 --with-decimal-contextvar
1603 build _decimal module using a coroutine-local rather
1604 than a thread-local context (default is yes)
Ned Deilyd819b932013-09-06 01:07:05 -07001605 --with-tcltk-includes='-I...'
1606 override search for Tcl and Tk include files
1607 --with-tcltk-libs='-L...'
1608 override search for Tcl and Tk libs
Matthias Klose55708cc2009-04-30 08:06:49 +00001609 --with-dbmliborder=db1:db2:...
Anthony Shaw2de064e2020-01-14 17:40:10 +11001610 override order to check db backends for dbm; a valid
1611 value is a colon separated string with the backend
1612 names `ndbm', `gdbm' and `bdb'.
1613 --with-doc-strings enable documentation strings (default is yes)
1614 --with-pymalloc enable specialized mallocs (default is yes)
1615 --with-c-locale-coercion
1616 enable C locale coercion to a UTF-8 based locale
1617 (default is yes)
1618 --with-valgrind enable Valgrind support (default is no)
1619 --with-dtrace enable DTrace support (default is no)
1620 --with-libm=STRING override libm math library to STRING (default is
1621 system-dependent)
1622 --with-libc=STRING override libc C library to STRING (default is
1623 system-dependent)
Victor Stinner8510f432020-03-10 09:53:09 +01001624 --with-platlibdir=DIRNAME
1625 Python library directory name (default is "lib")
Victor Stinner75e59a92021-01-20 17:07:21 +01001626 --with-wheel-pkg-dir=PATH
1627 Directory of wheel packages used by ensurepip
1628 (default: none)
Roland Hiebere1f77692021-02-09 02:05:25 +01001629 --with(out)-readline[=editline]
1630 use Editline for backend or disable readline module
Anthony Shaw2de064e2020-01-14 17:40:10 +11001631 --with-computed-gotos enable computed gotos in evaluation loop (enabled by
Antoine Pitrou042b1282010-08-13 21:15:58 +00001632 default on supported compilers)
Anthony Shaw2de064e2020-01-14 17:40:10 +11001633 --with-ensurepip[=install|upgrade|no]
1634 "install" or "upgrade" using bundled pip (default is
1635 upgrade)
Christian Heimes5d6e8c12021-03-27 14:44:04 +01001636 --with-openssl=DIR root of the OpenSSL directory
Christian Heimes32eba612021-03-19 10:29:25 +01001637 --with-openssl-rpath=[DIR|auto|no]
1638 Set runtime library directory (rpath) for OpenSSL
1639 libraries, no (default): don't set rpath, auto:
1640 auto-detect rpath from --with-openssl and
1641 pkg-config, DIR: set an explicit rpath
Christian Heimes892d66e2018-01-29 14:10:18 +01001642 --with-ssl-default-suites=[python|openssl|STRING]
Anthony Shaw2de064e2020-01-14 17:40:10 +11001643 override default cipher suites string, python: use
Christian Heimes892d66e2018-01-29 14:10:18 +01001644 Python's preferred selection (default), openssl:
1645 leave OpenSSL's defaults untouched, STRING: use a
Christian Heimese9832522021-05-01 20:53:10 +02001646 custom string, python and STRING also set TLS 1.2 as
1647 minimum TLS version
Christian Heimes9b60e552020-05-15 23:54:53 +02001648 --with-builtin-hashlib-hashes=md5,sha1,sha256,sha512,sha3,blake2
1649 builtin hash modules, md5, sha1, sha256, sha512,
1650 sha3 (with shake), blake2
Victor Stinnerc5fa3642020-05-05 16:41:11 +02001651 --with-experimental-isolated-subinterpreters
1652 better isolate subinterpreters, experimental build
1653 mode (default is no)
Victor Stinner801bb0b2021-02-17 11:14:42 +01001654 --without-static-libpython
1655 do not build libpythonMAJOR.MINOR.a and do not
1656 install python.o (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +00001657
1658Some influential environment variables:
doko@python.orgeab42bf2013-01-26 18:57:19 +01001659 MACHDEP name for machine-dependent library files
Martin v. Löwis11437992002-04-12 09:54:03 +00001660 CC C compiler command
1661 CFLAGS C compiler flags
1662 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1663 nonstandard directory <lib dir>
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001664 LIBS libraries to pass to the linker, e.g. -l<library>
Matthias Kloseb9621712010-04-24 17:59:49 +00001665 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001666 you have headers in a nonstandard directory <include dir>
Martin v. Löwis11437992002-04-12 09:54:03 +00001667 CPP C preprocessor
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -07001668 PROFILE_TASK
1669 Python args for PGO generation task
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +08001670 PKG_CONFIG path to pkg-config utility
1671 PKG_CONFIG_PATH
1672 directories to add to pkg-config's search path
1673 PKG_CONFIG_LIBDIR
1674 path overriding pkg-config's built-in search path
Martin v. Löwis11437992002-04-12 09:54:03 +00001675
1676Use these variables to override the choices made by `configure' or to help
1677it to find libraries and programs with nonstandard names/locations.
1678
Benjamin Petersonc2fcbf42016-08-03 22:01:32 -07001679Report bugs to <https://bugs.python.org/>.
Martin v. Löwis11437992002-04-12 09:54:03 +00001680_ACEOF
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001681ac_status=$?
Martin v. Löwis11437992002-04-12 09:54:03 +00001682fi
1683
1684if test "$ac_init_help" = "recursive"; then
1685 # If there are subdirs, report their specific --help.
Martin v. Löwis11437992002-04-12 09:54:03 +00001686 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
Matthias Kloseb9621712010-04-24 17:59:49 +00001687 test -d "$ac_dir" ||
1688 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1689 continue
Martin v. Löwis11437992002-04-12 09:54:03 +00001690 ac_builddir=.
1691
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001692case "$ac_dir" in
1693.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1694*)
Pablo Galindoba421752021-05-03 20:33:17 +01001695 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001696 # A ".." for each directory in $ac_dir_suffix.
Pablo Galindoba421752021-05-03 20:33:17 +01001697 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001698 case $ac_top_builddir_sub in
1699 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1700 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1701 esac ;;
1702esac
1703ac_abs_top_builddir=$ac_pwd
1704ac_abs_builddir=$ac_pwd$ac_dir_suffix
1705# for backward compatibility:
1706ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +00001707
1708case $srcdir in
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001709 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +00001710 ac_srcdir=.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001711 ac_top_srcdir=$ac_top_builddir_sub
1712 ac_abs_top_srcdir=$ac_pwd ;;
1713 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +00001714 ac_srcdir=$srcdir$ac_dir_suffix;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001715 ac_top_srcdir=$srcdir
1716 ac_abs_top_srcdir=$srcdir ;;
1717 *) # Relative name.
1718 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1719 ac_top_srcdir=$ac_top_build_prefix$srcdir
1720 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001721esac
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001722ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +00001723
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001724 cd "$ac_dir" || { ac_status=$?; continue; }
Pablo Galindoba421752021-05-03 20:33:17 +01001725 # Check for configure.gnu first; this name is used for a wrapper for
1726 # Metaconfig's "Configure" on case-insensitive file systems.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001727 if test -f "$ac_srcdir/configure.gnu"; then
1728 echo &&
1729 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1730 elif test -f "$ac_srcdir/configure"; then
1731 echo &&
1732 $SHELL "$ac_srcdir/configure" --help=recursive
Martin v. Löwis11437992002-04-12 09:54:03 +00001733 else
Pablo Galindoba421752021-05-03 20:33:17 +01001734 printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001735 fi || ac_status=$?
1736 cd "$ac_pwd" || { ac_status=$?; break; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001737 done
1738fi
1739
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001740test -n "$ac_init_help" && exit $ac_status
Martin v. Löwis11437992002-04-12 09:54:03 +00001741if $ac_init_version; then
1742 cat <<\_ACEOF
Pablo Galindod4fe0982020-05-19 03:33:01 +01001743python configure 3.10
Pablo Galindoba421752021-05-03 20:33:17 +01001744generated by GNU Autoconf 2.71
Martin v. Löwis11437992002-04-12 09:54:03 +00001745
Pablo Galindoba421752021-05-03 20:33:17 +01001746Copyright (C) 2021 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +00001747This configure script is free software; the Free Software Foundation
1748gives unlimited permission to copy, distribute and modify it.
1749_ACEOF
Thomas Wouters47b49bf2007-08-30 22:15:33 +00001750 exit
Martin v. Löwis11437992002-04-12 09:54:03 +00001751fi
Matthias Kloseb9621712010-04-24 17:59:49 +00001752
1753## ------------------------ ##
1754## Autoconf initialization. ##
1755## ------------------------ ##
1756
1757# ac_fn_c_try_compile LINENO
1758# --------------------------
1759# Try to compile conftest.$ac_ext, and return whether this succeeded.
1760ac_fn_c_try_compile ()
1761{
1762 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01001763 rm -f conftest.$ac_objext conftest.beam
Matthias Kloseb9621712010-04-24 17:59:49 +00001764 if { { ac_try="$ac_compile"
1765case "(($ac_try" in
1766 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1767 *) ac_try_echo=$ac_try;;
1768esac
1769eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01001770printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001771 (eval "$ac_compile") 2>conftest.err
1772 ac_status=$?
1773 if test -s conftest.err; then
1774 grep -v '^ *+' conftest.err >conftest.er1
1775 cat conftest.er1 >&5
1776 mv -f conftest.er1 conftest.err
1777 fi
Pablo Galindoba421752021-05-03 20:33:17 +01001778 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001779 test $ac_status = 0; } && {
1780 test -z "$ac_c_werror_flag" ||
1781 test ! -s conftest.err
Pablo Galindoba421752021-05-03 20:33:17 +01001782 } && test -s conftest.$ac_objext
1783then :
Matthias Kloseb9621712010-04-24 17:59:49 +00001784 ac_retval=0
Pablo Galindoba421752021-05-03 20:33:17 +01001785else $as_nop
1786 printf "%s\n" "$as_me: failed program was:" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001787sed 's/^/| /' conftest.$ac_ext >&5
1788
1789 ac_retval=1
1790fi
Victor Stinnere0be4232011-10-25 13:06:09 +02001791 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00001792 as_fn_set_status $ac_retval
1793
1794} # ac_fn_c_try_compile
1795
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02001796# ac_fn_c_try_cpp LINENO
1797# ----------------------
1798# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1799ac_fn_c_try_cpp ()
1800{
1801 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1802 if { { ac_try="$ac_cpp conftest.$ac_ext"
1803case "(($ac_try" in
1804 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1805 *) ac_try_echo=$ac_try;;
1806esac
1807eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01001808printf "%s\n" "$ac_try_echo"; } >&5
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02001809 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1810 ac_status=$?
1811 if test -s conftest.err; then
1812 grep -v '^ *+' conftest.err >conftest.er1
1813 cat conftest.er1 >&5
1814 mv -f conftest.er1 conftest.err
1815 fi
Pablo Galindoba421752021-05-03 20:33:17 +01001816 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02001817 test $ac_status = 0; } > conftest.i && {
1818 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1819 test ! -s conftest.err
Pablo Galindoba421752021-05-03 20:33:17 +01001820 }
1821then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02001822 ac_retval=0
Pablo Galindoba421752021-05-03 20:33:17 +01001823else $as_nop
1824 printf "%s\n" "$as_me: failed program was:" >&5
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02001825sed 's/^/| /' conftest.$ac_ext >&5
1826
1827 ac_retval=1
1828fi
1829 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1830 as_fn_set_status $ac_retval
1831
1832} # ac_fn_c_try_cpp
1833
Matthias Kloseb9621712010-04-24 17:59:49 +00001834# ac_fn_c_try_link LINENO
1835# -----------------------
1836# Try to link conftest.$ac_ext, and return whether this succeeded.
1837ac_fn_c_try_link ()
1838{
1839 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01001840 rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
Matthias Kloseb9621712010-04-24 17:59:49 +00001841 if { { ac_try="$ac_link"
1842case "(($ac_try" in
1843 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1844 *) ac_try_echo=$ac_try;;
1845esac
1846eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01001847printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001848 (eval "$ac_link") 2>conftest.err
1849 ac_status=$?
1850 if test -s conftest.err; then
1851 grep -v '^ *+' conftest.err >conftest.er1
1852 cat conftest.er1 >&5
1853 mv -f conftest.er1 conftest.err
1854 fi
Pablo Galindoba421752021-05-03 20:33:17 +01001855 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001856 test $ac_status = 0; } && {
1857 test -z "$ac_c_werror_flag" ||
1858 test ! -s conftest.err
1859 } && test -s conftest$ac_exeext && {
1860 test "$cross_compiling" = yes ||
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00001861 test -x conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +01001862 }
1863then :
Matthias Kloseb9621712010-04-24 17:59:49 +00001864 ac_retval=0
Pablo Galindoba421752021-05-03 20:33:17 +01001865else $as_nop
1866 printf "%s\n" "$as_me: failed program was:" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001867sed 's/^/| /' conftest.$ac_ext >&5
1868
1869 ac_retval=1
1870fi
1871 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1872 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1873 # interfere with the next link command; also delete a directory that is
1874 # left behind by Apple's compiler. We do this before executing the actions.
1875 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
Victor Stinnere0be4232011-10-25 13:06:09 +02001876 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00001877 as_fn_set_status $ac_retval
1878
1879} # ac_fn_c_try_link
1880
Pablo Galindoba421752021-05-03 20:33:17 +01001881# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
Matthias Kloseb9621712010-04-24 17:59:49 +00001882# -------------------------------------------------------
Pablo Galindoba421752021-05-03 20:33:17 +01001883# Tests whether HEADER exists and can be compiled using the include files in
1884# INCLUDES, setting the cache variable VAR accordingly.
1885ac_fn_c_check_header_compile ()
Matthias Kloseb9621712010-04-24 17:59:49 +00001886{
1887 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01001888 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1889printf %s "checking for $2... " >&6; }
1890if eval test \${$3+y}
1891then :
1892 printf %s "(cached) " >&6
1893else $as_nop
1894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00001895/* end confdefs.h. */
1896$4
1897#include <$2>
1898_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01001899if ac_fn_c_try_compile "$LINENO"
1900then :
1901 eval "$3=yes"
1902else $as_nop
1903 eval "$3=no"
Matthias Kloseb9621712010-04-24 17:59:49 +00001904fi
Pablo Galindoba421752021-05-03 20:33:17 +01001905rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00001906fi
1907eval ac_res=\$$3
Pablo Galindoba421752021-05-03 20:33:17 +01001908 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1909printf "%s\n" "$ac_res" >&6; }
Victor Stinnere0be4232011-10-25 13:06:09 +02001910 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00001911
Pablo Galindoba421752021-05-03 20:33:17 +01001912} # ac_fn_c_check_header_compile
Matthias Kloseb9621712010-04-24 17:59:49 +00001913
1914# ac_fn_c_try_run LINENO
1915# ----------------------
Pablo Galindoba421752021-05-03 20:33:17 +01001916# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
1917# executables *can* be run.
Matthias Kloseb9621712010-04-24 17:59:49 +00001918ac_fn_c_try_run ()
1919{
1920 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1921 if { { ac_try="$ac_link"
1922case "(($ac_try" in
1923 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1924 *) ac_try_echo=$ac_try;;
1925esac
1926eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01001927printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001928 (eval "$ac_link") 2>&5
1929 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01001930 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001931 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1932 { { case "(($ac_try" in
1933 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1934 *) ac_try_echo=$ac_try;;
1935esac
1936eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01001937printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001938 (eval "$ac_try") 2>&5
1939 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01001940 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1941 test $ac_status = 0; }; }
1942then :
Matthias Kloseb9621712010-04-24 17:59:49 +00001943 ac_retval=0
Pablo Galindoba421752021-05-03 20:33:17 +01001944else $as_nop
1945 printf "%s\n" "$as_me: program exited with status $ac_status" >&5
1946 printf "%s\n" "$as_me: failed program was:" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00001947sed 's/^/| /' conftest.$ac_ext >&5
1948
1949 ac_retval=$ac_status
1950fi
1951 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
Victor Stinnere0be4232011-10-25 13:06:09 +02001952 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00001953 as_fn_set_status $ac_retval
1954
1955} # ac_fn_c_try_run
1956
Matthias Kloseb9621712010-04-24 17:59:49 +00001957# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1958# -------------------------------------------
1959# Tests whether TYPE exists after having included INCLUDES, setting cache
1960# variable VAR accordingly.
1961ac_fn_c_check_type ()
1962{
1963 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01001964 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1965printf %s "checking for $2... " >&6; }
1966if eval test \${$3+y}
1967then :
1968 printf %s "(cached) " >&6
1969else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00001970 eval "$3=no"
1971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1972/* end confdefs.h. */
1973$4
1974int
Pablo Galindoba421752021-05-03 20:33:17 +01001975main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00001976{
1977if (sizeof ($2))
1978 return 0;
1979 ;
1980 return 0;
1981}
1982_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01001983if ac_fn_c_try_compile "$LINENO"
1984then :
Matthias Kloseb9621712010-04-24 17:59:49 +00001985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1986/* end confdefs.h. */
1987$4
1988int
Pablo Galindoba421752021-05-03 20:33:17 +01001989main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00001990{
1991if (sizeof (($2)))
1992 return 0;
1993 ;
1994 return 0;
1995}
1996_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01001997if ac_fn_c_try_compile "$LINENO"
1998then :
Matthias Kloseb9621712010-04-24 17:59:49 +00001999
Pablo Galindoba421752021-05-03 20:33:17 +01002000else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002001 eval "$3=yes"
2002fi
Pablo Galindoba421752021-05-03 20:33:17 +01002003rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002004fi
Pablo Galindoba421752021-05-03 20:33:17 +01002005rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002006fi
2007eval ac_res=\$$3
Pablo Galindoba421752021-05-03 20:33:17 +01002008 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2009printf "%s\n" "$ac_res" >&6; }
Victor Stinnere0be4232011-10-25 13:06:09 +02002010 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00002011
2012} # ac_fn_c_check_type
2013
Matthias Kloseb9621712010-04-24 17:59:49 +00002014# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2015# --------------------------------------------
2016# Tries to find the compile-time value of EXPR in a program that includes
2017# INCLUDES, setting VAR accordingly. Returns whether the value could be
2018# computed
2019ac_fn_c_compute_int ()
2020{
2021 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2022 if test "$cross_compiling" = yes; then
2023 # Depending upon the size, compute the lo and hi bounds.
2024cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2025/* end confdefs.h. */
2026$4
2027int
Pablo Galindoba421752021-05-03 20:33:17 +01002028main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002029{
2030static int test_array [1 - 2 * !(($2) >= 0)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00002031test_array [0] = 0;
2032return test_array [0];
Matthias Kloseb9621712010-04-24 17:59:49 +00002033
2034 ;
2035 return 0;
2036}
2037_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002038if ac_fn_c_try_compile "$LINENO"
2039then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002040 ac_lo=0 ac_mid=0
2041 while :; do
2042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2043/* end confdefs.h. */
2044$4
2045int
Pablo Galindoba421752021-05-03 20:33:17 +01002046main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002047{
2048static int test_array [1 - 2 * !(($2) <= $ac_mid)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00002049test_array [0] = 0;
2050return test_array [0];
Matthias Kloseb9621712010-04-24 17:59:49 +00002051
2052 ;
2053 return 0;
2054}
2055_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002056if ac_fn_c_try_compile "$LINENO"
2057then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002058 ac_hi=$ac_mid; break
Pablo Galindoba421752021-05-03 20:33:17 +01002059else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002060 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2061 if test $ac_lo -le $ac_mid; then
2062 ac_lo= ac_hi=
2063 break
2064 fi
2065 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2066fi
Pablo Galindoba421752021-05-03 20:33:17 +01002067rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002068 done
Pablo Galindoba421752021-05-03 20:33:17 +01002069else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2071/* end confdefs.h. */
2072$4
2073int
Pablo Galindoba421752021-05-03 20:33:17 +01002074main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002075{
2076static int test_array [1 - 2 * !(($2) < 0)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00002077test_array [0] = 0;
2078return test_array [0];
Matthias Kloseb9621712010-04-24 17:59:49 +00002079
2080 ;
2081 return 0;
2082}
2083_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002084if ac_fn_c_try_compile "$LINENO"
2085then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002086 ac_hi=-1 ac_mid=-1
2087 while :; do
2088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2089/* end confdefs.h. */
2090$4
2091int
Pablo Galindoba421752021-05-03 20:33:17 +01002092main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002093{
2094static int test_array [1 - 2 * !(($2) >= $ac_mid)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00002095test_array [0] = 0;
2096return test_array [0];
Matthias Kloseb9621712010-04-24 17:59:49 +00002097
2098 ;
2099 return 0;
2100}
2101_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002102if ac_fn_c_try_compile "$LINENO"
2103then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002104 ac_lo=$ac_mid; break
Pablo Galindoba421752021-05-03 20:33:17 +01002105else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002106 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2107 if test $ac_mid -le $ac_hi; then
2108 ac_lo= ac_hi=
2109 break
2110 fi
2111 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2112fi
Pablo Galindoba421752021-05-03 20:33:17 +01002113rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002114 done
Pablo Galindoba421752021-05-03 20:33:17 +01002115else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002116 ac_lo= ac_hi=
2117fi
Pablo Galindoba421752021-05-03 20:33:17 +01002118rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002119fi
Pablo Galindoba421752021-05-03 20:33:17 +01002120rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002121# Binary search between lo and hi bounds.
2122while test "x$ac_lo" != "x$ac_hi"; do
2123 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2125/* end confdefs.h. */
2126$4
2127int
Pablo Galindoba421752021-05-03 20:33:17 +01002128main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002129{
2130static int test_array [1 - 2 * !(($2) <= $ac_mid)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00002131test_array [0] = 0;
2132return test_array [0];
Matthias Kloseb9621712010-04-24 17:59:49 +00002133
2134 ;
2135 return 0;
2136}
2137_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002138if ac_fn_c_try_compile "$LINENO"
2139then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002140 ac_hi=$ac_mid
Pablo Galindoba421752021-05-03 20:33:17 +01002141else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002142 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2143fi
Pablo Galindoba421752021-05-03 20:33:17 +01002144rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002145done
2146case $ac_lo in #((
2147?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2148'') ac_retval=1 ;;
2149esac
2150 else
2151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2152/* end confdefs.h. */
2153$4
Pablo Galindoba421752021-05-03 20:33:17 +01002154static long int longval (void) { return $2; }
2155static unsigned long int ulongval (void) { return $2; }
Matthias Kloseb9621712010-04-24 17:59:49 +00002156#include <stdio.h>
2157#include <stdlib.h>
2158int
Pablo Galindoba421752021-05-03 20:33:17 +01002159main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002160{
2161
2162 FILE *f = fopen ("conftest.val", "w");
2163 if (! f)
2164 return 1;
2165 if (($2) < 0)
2166 {
2167 long int i = longval ();
2168 if (i != ($2))
2169 return 1;
2170 fprintf (f, "%ld", i);
2171 }
2172 else
2173 {
2174 unsigned long int i = ulongval ();
2175 if (i != ($2))
2176 return 1;
2177 fprintf (f, "%lu", i);
2178 }
2179 /* Do not output a trailing newline, as this causes \r\n confusion
2180 on some platforms. */
2181 return ferror (f) || fclose (f) != 0;
2182
2183 ;
2184 return 0;
2185}
2186_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002187if ac_fn_c_try_run "$LINENO"
2188then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002189 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
Pablo Galindoba421752021-05-03 20:33:17 +01002190else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002191 ac_retval=1
2192fi
2193rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2194 conftest.$ac_objext conftest.beam conftest.$ac_ext
2195rm -f conftest.val
2196
2197 fi
Victor Stinnere0be4232011-10-25 13:06:09 +02002198 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00002199 as_fn_set_status $ac_retval
2200
2201} # ac_fn_c_compute_int
2202
2203# ac_fn_c_check_func LINENO FUNC VAR
2204# ----------------------------------
2205# Tests whether FUNC exists, setting the cache variable VAR accordingly
2206ac_fn_c_check_func ()
2207{
2208 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01002209 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2210printf %s "checking for $2... " >&6; }
2211if eval test \${$3+y}
2212then :
2213 printf %s "(cached) " >&6
2214else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2216/* end confdefs.h. */
2217/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2218 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2219#define $2 innocuous_$2
2220
2221/* System header to define __stub macros and hopefully few prototypes,
Pablo Galindoba421752021-05-03 20:33:17 +01002222 which can conflict with char $2 (); below. */
Matthias Kloseb9621712010-04-24 17:59:49 +00002223
Pablo Galindoba421752021-05-03 20:33:17 +01002224#include <limits.h>
Matthias Kloseb9621712010-04-24 17:59:49 +00002225#undef $2
2226
2227/* Override any GCC internal prototype to avoid an error.
2228 Use char because int might match the return type of a GCC
2229 builtin and then its argument prototype would still apply. */
2230#ifdef __cplusplus
2231extern "C"
2232#endif
2233char $2 ();
2234/* The GNU C library defines this for functions which it implements
2235 to always fail with ENOSYS. Some functions are actually named
2236 something starting with __ and the normal name is an alias. */
2237#if defined __stub_$2 || defined __stub___$2
2238choke me
2239#endif
2240
2241int
Pablo Galindoba421752021-05-03 20:33:17 +01002242main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002243{
2244return $2 ();
2245 ;
2246 return 0;
2247}
2248_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002249if ac_fn_c_try_link "$LINENO"
2250then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002251 eval "$3=yes"
Pablo Galindoba421752021-05-03 20:33:17 +01002252else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002253 eval "$3=no"
2254fi
Pablo Galindoba421752021-05-03 20:33:17 +01002255rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +00002256 conftest$ac_exeext conftest.$ac_ext
2257fi
2258eval ac_res=\$$3
Pablo Galindoba421752021-05-03 20:33:17 +01002259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2260printf "%s\n" "$ac_res" >&6; }
Victor Stinnere0be4232011-10-25 13:06:09 +02002261 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00002262
2263} # ac_fn_c_check_func
2264
Pablo Galindoba421752021-05-03 20:33:17 +01002265# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR
2266# ------------------------------------------------------------------
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002267# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
Pablo Galindoba421752021-05-03 20:33:17 +01002268# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR.
2269ac_fn_check_decl ()
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002270{
2271 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2272 as_decl_name=`echo $2|sed 's/ *(.*//'`
Pablo Galindoba421752021-05-03 20:33:17 +01002273 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2274printf %s "checking whether $as_decl_name is declared... " >&6; }
2275if eval test \${$3+y}
2276then :
2277 printf %s "(cached) " >&6
2278else $as_nop
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002279 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
Pablo Galindoba421752021-05-03 20:33:17 +01002280 eval ac_save_FLAGS=\$$6
2281 as_fn_append $6 " $5"
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2283/* end confdefs.h. */
2284$4
2285int
Pablo Galindoba421752021-05-03 20:33:17 +01002286main (void)
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002287{
2288#ifndef $as_decl_name
2289#ifdef __cplusplus
2290 (void) $as_decl_use;
2291#else
2292 (void) $as_decl_name;
2293#endif
2294#endif
2295
2296 ;
2297 return 0;
2298}
2299_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002300if ac_fn_c_try_compile "$LINENO"
2301then :
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002302 eval "$3=yes"
Pablo Galindoba421752021-05-03 20:33:17 +01002303else $as_nop
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002304 eval "$3=no"
2305fi
Pablo Galindoba421752021-05-03 20:33:17 +01002306rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2307 eval $6=\$ac_save_FLAGS
2308
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002309fi
2310eval ac_res=\$$3
Pablo Galindoba421752021-05-03 20:33:17 +01002311 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2312printf "%s\n" "$ac_res" >&6; }
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002313 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2314
Pablo Galindoba421752021-05-03 20:33:17 +01002315} # ac_fn_check_decl
Gregory P. Smithdf300d52012-01-21 18:20:15 -08002316
Matthias Kloseb9621712010-04-24 17:59:49 +00002317# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2318# ----------------------------------------------------
2319# Tries to find if the field MEMBER exists in type AGGR, after including
2320# INCLUDES, setting cache variable VAR accordingly.
2321ac_fn_c_check_member ()
2322{
2323 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +01002324 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2325printf %s "checking for $2.$3... " >&6; }
2326if eval test \${$4+y}
2327then :
2328 printf %s "(cached) " >&6
2329else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2331/* end confdefs.h. */
2332$5
2333int
Pablo Galindoba421752021-05-03 20:33:17 +01002334main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002335{
2336static $2 ac_aggr;
2337if (ac_aggr.$3)
2338return 0;
2339 ;
2340 return 0;
2341}
2342_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002343if ac_fn_c_try_compile "$LINENO"
2344then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002345 eval "$4=yes"
Pablo Galindoba421752021-05-03 20:33:17 +01002346else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002347 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2348/* end confdefs.h. */
2349$5
2350int
Pablo Galindoba421752021-05-03 20:33:17 +01002351main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00002352{
2353static $2 ac_aggr;
2354if (sizeof ac_aggr.$3)
2355return 0;
2356 ;
2357 return 0;
2358}
2359_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01002360if ac_fn_c_try_compile "$LINENO"
2361then :
Matthias Kloseb9621712010-04-24 17:59:49 +00002362 eval "$4=yes"
Pablo Galindoba421752021-05-03 20:33:17 +01002363else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00002364 eval "$4=no"
2365fi
Pablo Galindoba421752021-05-03 20:33:17 +01002366rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002367fi
Pablo Galindoba421752021-05-03 20:33:17 +01002368rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00002369fi
2370eval ac_res=\$$4
Pablo Galindoba421752021-05-03 20:33:17 +01002371 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2372printf "%s\n" "$ac_res" >&6; }
Victor Stinnere0be4232011-10-25 13:06:09 +02002373 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
Matthias Kloseb9621712010-04-24 17:59:49 +00002374
2375} # ac_fn_c_check_member
Pablo Galindoba421752021-05-03 20:33:17 +01002376ac_configure_args_raw=
2377for ac_arg
2378do
2379 case $ac_arg in
2380 *\'*)
2381 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2382 esac
2383 as_fn_append ac_configure_args_raw " '$ac_arg'"
2384done
2385
2386case $ac_configure_args_raw in
2387 *$as_nl*)
2388 ac_safe_unquote= ;;
2389 *)
2390 ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab.
2391 ac_unsafe_a="$ac_unsafe_z#~"
2392 ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
2393 ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
2394esac
2395
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002396cat >config.log <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +00002397This file contains any messages produced by compilers while
2398running configure, to aid debugging if configure makes a mistake.
2399
Pablo Galindod4fe0982020-05-19 03:33:01 +01002400It was created by python $as_me 3.10, which was
Pablo Galindoba421752021-05-03 20:33:17 +01002401generated by GNU Autoconf 2.71. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +00002402
Pablo Galindoba421752021-05-03 20:33:17 +01002403 $ $0$ac_configure_args_raw
Martin v. Löwis11437992002-04-12 09:54:03 +00002404
2405_ACEOF
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002406exec 5>>config.log
Martin v. Löwis11437992002-04-12 09:54:03 +00002407{
2408cat <<_ASUNAME
2409## --------- ##
2410## Platform. ##
2411## --------- ##
2412
2413hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2414uname -m = `(uname -m) 2>/dev/null || echo unknown`
2415uname -r = `(uname -r) 2>/dev/null || echo unknown`
2416uname -s = `(uname -s) 2>/dev/null || echo unknown`
2417uname -v = `(uname -v) 2>/dev/null || echo unknown`
2418
2419/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2420/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2421
2422/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2423/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2424/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002425/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
Martin v. Löwis11437992002-04-12 09:54:03 +00002426/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2427/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2428/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2429
2430_ASUNAME
2431
2432as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2433for as_dir in $PATH
2434do
2435 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01002436 case $as_dir in #(((
2437 '') as_dir=./ ;;
2438 */) ;;
2439 *) as_dir=$as_dir/ ;;
2440 esac
2441 printf "%s\n" "PATH: $as_dir"
Matthias Kloseb9621712010-04-24 17:59:49 +00002442 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002443IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002444
2445} >&5
2446
2447cat >&5 <<_ACEOF
2448
2449
2450## ----------- ##
2451## Core tests. ##
2452## ----------- ##
2453
2454_ACEOF
2455
2456
2457# Keep a trace of the command line.
2458# Strip out --no-create and --no-recursion so they do not pile up.
Skip Montanaro6dead952003-09-25 14:50:04 +00002459# Strip out --silent because we don't want to record it for future runs.
Martin v. Löwis11437992002-04-12 09:54:03 +00002460# Also quote any args containing shell meta-characters.
Skip Montanaro6dead952003-09-25 14:50:04 +00002461# Make two passes to allow for proper duplicate-argument suppression.
Martin v. Löwis11437992002-04-12 09:54:03 +00002462ac_configure_args=
Skip Montanaro6dead952003-09-25 14:50:04 +00002463ac_configure_args0=
2464ac_configure_args1=
Skip Montanaro6dead952003-09-25 14:50:04 +00002465ac_must_keep_next=false
2466for ac_pass in 1 2
Martin v. Löwis11437992002-04-12 09:54:03 +00002467do
Skip Montanaro6dead952003-09-25 14:50:04 +00002468 for ac_arg
2469 do
2470 case $ac_arg in
2471 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2472 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2473 | -silent | --silent | --silen | --sile | --sil)
2474 continue ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002475 *\'*)
Pablo Galindoba421752021-05-03 20:33:17 +01002476 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002477 esac
2478 case $ac_pass in
Matthias Kloseb9621712010-04-24 17:59:49 +00002479 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002480 2)
Matthias Kloseb9621712010-04-24 17:59:49 +00002481 as_fn_append ac_configure_args1 " '$ac_arg'"
Skip Montanaro6dead952003-09-25 14:50:04 +00002482 if test $ac_must_keep_next = true; then
Skip Montanarof0d5f792004-08-15 14:08:23 +00002483 ac_must_keep_next=false # Got value, back to normal.
Skip Montanaro6dead952003-09-25 14:50:04 +00002484 else
Skip Montanarof0d5f792004-08-15 14:08:23 +00002485 case $ac_arg in
2486 *=* | --config-cache | -C | -disable-* | --disable-* \
2487 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2488 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2489 | -with-* | --with-* | -without-* | --without-* | --x)
2490 case "$ac_configure_args0 " in
2491 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2492 esac
2493 ;;
2494 -* ) ac_must_keep_next=true ;;
2495 esac
Skip Montanaro6dead952003-09-25 14:50:04 +00002496 fi
Matthias Kloseb9621712010-04-24 17:59:49 +00002497 as_fn_append ac_configure_args " '$ac_arg'"
Skip Montanaro6dead952003-09-25 14:50:04 +00002498 ;;
2499 esac
2500 done
Martin v. Löwis11437992002-04-12 09:54:03 +00002501done
Matthias Kloseb9621712010-04-24 17:59:49 +00002502{ ac_configure_args0=; unset ac_configure_args0;}
2503{ ac_configure_args1=; unset ac_configure_args1;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002504
2505# When interrupted or exit'd, cleanup temporary files, and complete
2506# config.log. We remove comments because anyway the quotes in there
2507# would cause problems or look ugly.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002508# WARNING: Use '\'' to represent an apostrophe within the trap.
2509# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
Martin v. Löwis11437992002-04-12 09:54:03 +00002510trap 'exit_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01002511 # Sanitize IFS.
2512 IFS=" "" $as_nl"
Martin v. Löwis11437992002-04-12 09:54:03 +00002513 # Save into config.log some information that might help in debugging.
2514 {
2515 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00002516
Pablo Galindoba421752021-05-03 20:33:17 +01002517 printf "%s\n" "## ---------------- ##
Martin v. Löwis11437992002-04-12 09:54:03 +00002518## Cache variables. ##
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002519## ---------------- ##"
Martin v. Löwis11437992002-04-12 09:54:03 +00002520 echo
2521 # The following way of writing the cache mishandles newlines in values,
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002522(
2523 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2524 eval ac_val=\$$ac_var
2525 case $ac_val in #(
2526 *${as_nl}*)
2527 case $ac_var in #(
Pablo Galindoba421752021-05-03 20:33:17 +01002528 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2529printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002530 esac
2531 case $ac_var in #(
2532 _ | IFS | as_nl) ;; #(
Matthias Kloseb9621712010-04-24 17:59:49 +00002533 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2534 *) { eval $ac_var=; unset $ac_var;} ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002535 esac ;;
2536 esac
2537 done
Martin v. Löwis11437992002-04-12 09:54:03 +00002538 (set) 2>&1 |
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002539 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2540 *${as_nl}ac_space=\ *)
Martin v. Löwis11437992002-04-12 09:54:03 +00002541 sed -n \
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002542 "s/'\''/'\''\\\\'\'''\''/g;
2543 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2544 ;; #(
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00002545 *)
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002546 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00002547 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002548 esac |
2549 sort
2550)
Martin v. Löwis11437992002-04-12 09:54:03 +00002551 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00002552
Pablo Galindoba421752021-05-03 20:33:17 +01002553 printf "%s\n" "## ----------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00002554## Output variables. ##
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002555## ----------------- ##"
Skip Montanaro6dead952003-09-25 14:50:04 +00002556 echo
2557 for ac_var in $ac_subst_vars
2558 do
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002559 eval ac_val=\$$ac_var
2560 case $ac_val in
Pablo Galindoba421752021-05-03 20:33:17 +01002561 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002562 esac
Pablo Galindoba421752021-05-03 20:33:17 +01002563 printf "%s\n" "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00002564 done | sort
2565 echo
2566
2567 if test -n "$ac_subst_files"; then
Pablo Galindoba421752021-05-03 20:33:17 +01002568 printf "%s\n" "## ------------------- ##
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002569## File substitutions. ##
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002570## ------------------- ##"
Skip Montanaro6dead952003-09-25 14:50:04 +00002571 echo
2572 for ac_var in $ac_subst_files
2573 do
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002574 eval ac_val=\$$ac_var
2575 case $ac_val in
Pablo Galindoba421752021-05-03 20:33:17 +01002576 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002577 esac
Pablo Galindoba421752021-05-03 20:33:17 +01002578 printf "%s\n" "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00002579 done | sort
2580 echo
2581 fi
2582
Martin v. Löwis11437992002-04-12 09:54:03 +00002583 if test -s confdefs.h; then
Pablo Galindoba421752021-05-03 20:33:17 +01002584 printf "%s\n" "## ----------- ##
Martin v. Löwis11437992002-04-12 09:54:03 +00002585## confdefs.h. ##
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002586## ----------- ##"
Martin v. Löwis11437992002-04-12 09:54:03 +00002587 echo
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002588 cat confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002589 echo
2590 fi
2591 test "$ac_signal" != 0 &&
Pablo Galindoba421752021-05-03 20:33:17 +01002592 printf "%s\n" "$as_me: caught signal $ac_signal"
2593 printf "%s\n" "$as_me: exit $exit_status"
Martin v. Löwis11437992002-04-12 09:54:03 +00002594 } >&5
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002595 rm -f core *.core core.conftest.* &&
2596 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
Martin v. Löwis11437992002-04-12 09:54:03 +00002597 exit $exit_status
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002598' 0
Martin v. Löwis11437992002-04-12 09:54:03 +00002599for ac_signal in 1 2 13 15; do
Matthias Kloseb9621712010-04-24 17:59:49 +00002600 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00002601done
2602ac_signal=0
2603
2604# confdefs.h avoids OS command line length limits that DEFS can exceed.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002605rm -f -r conftest* confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002606
Pablo Galindoba421752021-05-03 20:33:17 +01002607printf "%s\n" "/* confdefs.h */" > confdefs.h
Matthias Kloseb9621712010-04-24 17:59:49 +00002608
Martin v. Löwis11437992002-04-12 09:54:03 +00002609# Predefined preprocessor variables.
2610
Pablo Galindoba421752021-05-03 20:33:17 +01002611printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002612
Pablo Galindoba421752021-05-03 20:33:17 +01002613printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002614
Pablo Galindoba421752021-05-03 20:33:17 +01002615printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002616
Pablo Galindoba421752021-05-03 20:33:17 +01002617printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002618
Pablo Galindoba421752021-05-03 20:33:17 +01002619printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00002620
Pablo Galindoba421752021-05-03 20:33:17 +01002621printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
Matthias Kloseb9621712010-04-24 17:59:49 +00002622
Martin v. Löwis11437992002-04-12 09:54:03 +00002623
2624# Let the site file select an alternate cache file if it wants to.
Matthias Kloseb9621712010-04-24 17:59:49 +00002625# Prefer an explicitly selected file to automatically selected ones.
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002626if test -n "$CONFIG_SITE"; then
Pablo Galindoba421752021-05-03 20:33:17 +01002627 ac_site_files="$CONFIG_SITE"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002628elif test "x$prefix" != xNONE; then
Pablo Galindoba421752021-05-03 20:33:17 +01002629 ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002630else
Pablo Galindoba421752021-05-03 20:33:17 +01002631 ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002632fi
Pablo Galindoba421752021-05-03 20:33:17 +01002633
2634for ac_site_file in $ac_site_files
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002635do
Pablo Galindoba421752021-05-03 20:33:17 +01002636 case $ac_site_file in #(
2637 */*) :
2638 ;; #(
2639 *) :
2640 ac_site_file=./$ac_site_file ;;
2641esac
2642 if test -f "$ac_site_file" && test -r "$ac_site_file"; then
2643 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2644printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002645 sed 's/^/| /' "$ac_site_file" >&5
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002646 . "$ac_site_file" \
Pablo Galindoba421752021-05-03 20:33:17 +01002647 || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2648printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02002649as_fn_error $? "failed to load site script $ac_site_file
Victor Stinnere0be4232011-10-25 13:06:09 +02002650See \`config.log' for more details" "$LINENO" 5; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002651 fi
2652done
2653
2654if test -r "$cache_file"; then
Matthias Kloseb9621712010-04-24 17:59:49 +00002655 # Some versions of bash will fail to source /dev/null (special files
2656 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2657 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
Pablo Galindoba421752021-05-03 20:33:17 +01002658 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2659printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002660 case $cache_file in
Thomas Wouters47b49bf2007-08-30 22:15:33 +00002661 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2662 *) . "./$cache_file";;
Martin v. Löwis11437992002-04-12 09:54:03 +00002663 esac
2664 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002665else
Pablo Galindoba421752021-05-03 20:33:17 +01002666 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2667printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002668 >$cache_file
2669fi
2670
Pablo Galindoba421752021-05-03 20:33:17 +01002671# Test code for whether the C compiler supports C89 (global declarations)
2672ac_c_conftest_c89_globals='
2673/* Does the compiler advertise C89 conformance?
2674 Do not test the value of __STDC__, because some compilers set it to 0
2675 while being otherwise adequately conformant. */
2676#if !defined __STDC__
2677# error "Compiler does not advertise C89 conformance"
2678#endif
2679
2680#include <stddef.h>
2681#include <stdarg.h>
2682struct stat;
2683/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
2684struct buf { int x; };
2685struct buf * (*rcsopen) (struct buf *, struct stat *, int);
2686static char *e (p, i)
2687 char **p;
2688 int i;
2689{
2690 return p[i];
2691}
2692static char *f (char * (*g) (char **, int), char **p, ...)
2693{
2694 char *s;
2695 va_list v;
2696 va_start (v,p);
2697 s = g (p, va_arg (v,int));
2698 va_end (v);
2699 return s;
2700}
2701
2702/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
2703 function prototypes and stuff, but not \xHH hex character constants.
2704 These do not provoke an error unfortunately, instead are silently treated
2705 as an "x". The following induces an error, until -std is added to get
2706 proper ANSI mode. Curiously \x00 != x always comes out true, for an
2707 array size at least. It is necessary to write \x00 == 0 to get something
2708 that is true only with -std. */
2709int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
2710
2711/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2712 inside strings and character constants. */
2713#define FOO(x) '\''x'\''
2714int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
2715
2716int test (int i, double x);
2717struct s1 {int (*f) (int a);};
2718struct s2 {int (*f) (double a);};
2719int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
2720 int, int);'
2721
2722# Test code for whether the C compiler supports C89 (body of main).
2723ac_c_conftest_c89_main='
2724ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
2725'
2726
2727# Test code for whether the C compiler supports C99 (global declarations)
2728ac_c_conftest_c99_globals='
2729// Does the compiler advertise C99 conformance?
2730#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
2731# error "Compiler does not advertise C99 conformance"
2732#endif
2733
2734#include <stdbool.h>
2735extern int puts (const char *);
2736extern int printf (const char *, ...);
2737extern int dprintf (int, const char *, ...);
2738extern void *malloc (size_t);
2739
2740// Check varargs macros. These examples are taken from C99 6.10.3.5.
2741// dprintf is used instead of fprintf to avoid needing to declare
2742// FILE and stderr.
2743#define debug(...) dprintf (2, __VA_ARGS__)
2744#define showlist(...) puts (#__VA_ARGS__)
2745#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
2746static void
2747test_varargs_macros (void)
2748{
2749 int x = 1234;
2750 int y = 5678;
2751 debug ("Flag");
2752 debug ("X = %d\n", x);
2753 showlist (The first, second, and third items.);
2754 report (x>y, "x is %d but y is %d", x, y);
2755}
2756
2757// Check long long types.
2758#define BIG64 18446744073709551615ull
2759#define BIG32 4294967295ul
2760#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
2761#if !BIG_OK
2762 #error "your preprocessor is broken"
2763#endif
2764#if BIG_OK
2765#else
2766 #error "your preprocessor is broken"
2767#endif
2768static long long int bignum = -9223372036854775807LL;
2769static unsigned long long int ubignum = BIG64;
2770
2771struct incomplete_array
2772{
2773 int datasize;
2774 double data[];
2775};
2776
2777struct named_init {
2778 int number;
2779 const wchar_t *name;
2780 double average;
2781};
2782
2783typedef const char *ccp;
2784
2785static inline int
2786test_restrict (ccp restrict text)
2787{
2788 // See if C++-style comments work.
2789 // Iterate through items via the restricted pointer.
2790 // Also check for declarations in for loops.
2791 for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
2792 continue;
2793 return 0;
2794}
2795
2796// Check varargs and va_copy.
2797static bool
2798test_varargs (const char *format, ...)
2799{
2800 va_list args;
2801 va_start (args, format);
2802 va_list args_copy;
2803 va_copy (args_copy, args);
2804
2805 const char *str = "";
2806 int number = 0;
2807 float fnumber = 0;
2808
2809 while (*format)
2810 {
2811 switch (*format++)
2812 {
2813 case '\''s'\'': // string
2814 str = va_arg (args_copy, const char *);
2815 break;
2816 case '\''d'\'': // int
2817 number = va_arg (args_copy, int);
2818 break;
2819 case '\''f'\'': // float
2820 fnumber = va_arg (args_copy, double);
2821 break;
2822 default:
2823 break;
2824 }
2825 }
2826 va_end (args_copy);
2827 va_end (args);
2828
2829 return *str && number && fnumber;
2830}
2831'
2832
2833# Test code for whether the C compiler supports C99 (body of main).
2834ac_c_conftest_c99_main='
2835 // Check bool.
2836 _Bool success = false;
2837 success |= (argc != 0);
2838
2839 // Check restrict.
2840 if (test_restrict ("String literal") == 0)
2841 success = true;
2842 char *restrict newvar = "Another string";
2843
2844 // Check varargs.
2845 success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
2846 test_varargs_macros ();
2847
2848 // Check flexible array members.
2849 struct incomplete_array *ia =
2850 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
2851 ia->datasize = 10;
2852 for (int i = 0; i < ia->datasize; ++i)
2853 ia->data[i] = i * 1.234;
2854
2855 // Check named initializers.
2856 struct named_init ni = {
2857 .number = 34,
2858 .name = L"Test wide string",
2859 .average = 543.34343,
2860 };
2861
2862 ni.number = 58;
2863
2864 int dynamic_array[ni.number];
2865 dynamic_array[0] = argv[0][0];
2866 dynamic_array[ni.number - 1] = 543;
2867
2868 // work around unused variable warnings
2869 ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
2870 || dynamic_array[ni.number - 1] != 543);
2871'
2872
2873# Test code for whether the C compiler supports C11 (global declarations)
2874ac_c_conftest_c11_globals='
2875// Does the compiler advertise C11 conformance?
2876#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
2877# error "Compiler does not advertise C11 conformance"
2878#endif
2879
2880// Check _Alignas.
2881char _Alignas (double) aligned_as_double;
2882char _Alignas (0) no_special_alignment;
2883extern char aligned_as_int;
2884char _Alignas (0) _Alignas (int) aligned_as_int;
2885
2886// Check _Alignof.
2887enum
2888{
2889 int_alignment = _Alignof (int),
2890 int_array_alignment = _Alignof (int[100]),
2891 char_alignment = _Alignof (char)
2892};
2893_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
2894
2895// Check _Noreturn.
2896int _Noreturn does_not_return (void) { for (;;) continue; }
2897
2898// Check _Static_assert.
2899struct test_static_assert
2900{
2901 int x;
2902 _Static_assert (sizeof (int) <= sizeof (long int),
2903 "_Static_assert does not work in struct");
2904 long int y;
2905};
2906
2907// Check UTF-8 literals.
2908#define u8 syntax error!
2909char const utf8_literal[] = u8"happens to be ASCII" "another string";
2910
2911// Check duplicate typedefs.
2912typedef long *long_ptr;
2913typedef long int *long_ptr;
2914typedef long_ptr long_ptr;
2915
2916// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
2917struct anonymous
2918{
2919 union {
2920 struct { int i; int j; };
2921 struct { int k; long int l; } w;
2922 };
2923 int m;
2924} v1;
2925'
2926
2927# Test code for whether the C compiler supports C11 (body of main).
2928ac_c_conftest_c11_main='
2929 _Static_assert ((offsetof (struct anonymous, i)
2930 == offsetof (struct anonymous, w.k)),
2931 "Anonymous union alignment botch");
2932 v1.i = 2;
2933 v1.w.k = 5;
2934 ok |= v1.i != 5;
2935'
2936
2937# Test code for whether the C compiler supports C11 (complete).
2938ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
2939${ac_c_conftest_c99_globals}
2940${ac_c_conftest_c11_globals}
2941
2942int
2943main (int argc, char **argv)
2944{
2945 int ok = 0;
2946 ${ac_c_conftest_c89_main}
2947 ${ac_c_conftest_c99_main}
2948 ${ac_c_conftest_c11_main}
2949 return ok;
2950}
2951"
2952
2953# Test code for whether the C compiler supports C99 (complete).
2954ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
2955${ac_c_conftest_c99_globals}
2956
2957int
2958main (int argc, char **argv)
2959{
2960 int ok = 0;
2961 ${ac_c_conftest_c89_main}
2962 ${ac_c_conftest_c99_main}
2963 return ok;
2964}
2965"
2966
2967# Test code for whether the C compiler supports C89 (complete).
2968ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
2969
2970int
2971main (int argc, char **argv)
2972{
2973 int ok = 0;
2974 ${ac_c_conftest_c89_main}
2975 return ok;
2976}
2977"
2978
2979as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
2980as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
2981as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
2982as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
2983as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
2984as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
2985as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
2986as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
2987as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
2988as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H"
2989as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H"
2990as_fn_append ac_header_c_list " sys/time.h sys_time_h HAVE_SYS_TIME_H"
2991
2992# Auxiliary files required by this configure script.
2993ac_aux_files="install-sh config.guess config.sub"
2994
2995# Locations in which to look for auxiliary files.
2996ac_aux_dir_candidates="${srcdir}${PATH_SEPARATOR}${srcdir}/..${PATH_SEPARATOR}${srcdir}/../.."
2997
2998# Search for a directory containing all of the required auxiliary files,
2999# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates.
3000# If we don't find one directory that contains all the files we need,
3001# we report the set of missing files from the *first* directory in
3002# $ac_aux_dir_candidates and give up.
3003ac_missing_aux_files=""
3004ac_first_candidate=:
3005printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5
3006as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3007as_found=false
3008for as_dir in $ac_aux_dir_candidates
3009do
3010 IFS=$as_save_IFS
3011 case $as_dir in #(((
3012 '') as_dir=./ ;;
3013 */) ;;
3014 *) as_dir=$as_dir/ ;;
3015 esac
3016 as_found=:
3017
3018 printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5
3019 ac_aux_dir_found=yes
3020 ac_install_sh=
3021 for ac_aux in $ac_aux_files
3022 do
3023 # As a special case, if "install-sh" is required, that requirement
3024 # can be satisfied by any of "install-sh", "install.sh", or "shtool",
3025 # and $ac_install_sh is set appropriately for whichever one is found.
3026 if test x"$ac_aux" = x"install-sh"
3027 then
3028 if test -f "${as_dir}install-sh"; then
3029 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5
3030 ac_install_sh="${as_dir}install-sh -c"
3031 elif test -f "${as_dir}install.sh"; then
3032 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5
3033 ac_install_sh="${as_dir}install.sh -c"
3034 elif test -f "${as_dir}shtool"; then
3035 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5
3036 ac_install_sh="${as_dir}shtool install -c"
3037 else
3038 ac_aux_dir_found=no
3039 if $ac_first_candidate; then
3040 ac_missing_aux_files="${ac_missing_aux_files} install-sh"
3041 else
3042 break
3043 fi
3044 fi
3045 else
3046 if test -f "${as_dir}${ac_aux}"; then
3047 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5
3048 else
3049 ac_aux_dir_found=no
3050 if $ac_first_candidate; then
3051 ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}"
3052 else
3053 break
3054 fi
3055 fi
3056 fi
3057 done
3058 if test "$ac_aux_dir_found" = yes; then
3059 ac_aux_dir="$as_dir"
3060 break
3061 fi
3062 ac_first_candidate=false
3063
3064 as_found=false
3065done
3066IFS=$as_save_IFS
3067if $as_found
3068then :
3069
3070else $as_nop
3071 as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5
3072fi
3073
3074
3075# These three variables are undocumented and unsupported,
3076# and are intended to be withdrawn in a future Autoconf release.
3077# They can cause serious problems if a builder's source tree is in a directory
3078# whose full name contains unusual characters.
3079if test -f "${ac_aux_dir}config.guess"; then
3080 ac_config_guess="$SHELL ${ac_aux_dir}config.guess"
3081fi
3082if test -f "${ac_aux_dir}config.sub"; then
3083 ac_config_sub="$SHELL ${ac_aux_dir}config.sub"
3084fi
3085if test -f "$ac_aux_dir/configure"; then
3086 ac_configure="$SHELL ${ac_aux_dir}configure"
3087fi
3088
Martin v. Löwis11437992002-04-12 09:54:03 +00003089# Check that the precious variables saved in the cache have kept the same
3090# value.
3091ac_cache_corrupted=false
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003092for ac_var in $ac_precious_vars; do
Martin v. Löwis11437992002-04-12 09:54:03 +00003093 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3094 eval ac_new_set=\$ac_env_${ac_var}_set
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003095 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3096 eval ac_new_val=\$ac_env_${ac_var}_value
Martin v. Löwis11437992002-04-12 09:54:03 +00003097 case $ac_old_set,$ac_new_set in
3098 set,)
Pablo Galindoba421752021-05-03 20:33:17 +01003099 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3100printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00003101 ac_cache_corrupted=: ;;
3102 ,set)
Pablo Galindoba421752021-05-03 20:33:17 +01003103 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3104printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00003105 ac_cache_corrupted=: ;;
3106 ,);;
3107 *)
3108 if test "x$ac_old_val" != "x$ac_new_val"; then
Matthias Kloseb9621712010-04-24 17:59:49 +00003109 # differences in whitespace do not lead to failure.
3110 ac_old_val_w=`echo x $ac_old_val`
3111 ac_new_val_w=`echo x $ac_new_val`
3112 if test "$ac_old_val_w" != "$ac_new_val_w"; then
Pablo Galindoba421752021-05-03 20:33:17 +01003113 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3114printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
Matthias Kloseb9621712010-04-24 17:59:49 +00003115 ac_cache_corrupted=:
3116 else
Pablo Galindoba421752021-05-03 20:33:17 +01003117 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3118printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
Matthias Kloseb9621712010-04-24 17:59:49 +00003119 eval $ac_var=\$ac_old_val
3120 fi
Pablo Galindoba421752021-05-03 20:33:17 +01003121 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3122printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;}
3123 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3124printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00003125 fi;;
3126 esac
3127 # Pass precious variables to config.status.
3128 if test "$ac_new_set" = set; then
3129 case $ac_new_val in
Pablo Galindoba421752021-05-03 20:33:17 +01003130 *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00003131 *) ac_arg=$ac_var=$ac_new_val ;;
3132 esac
3133 case " $ac_configure_args " in
3134 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
Matthias Kloseb9621712010-04-24 17:59:49 +00003135 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00003136 esac
3137 fi
3138done
3139if $ac_cache_corrupted; then
Pablo Galindoba421752021-05-03 20:33:17 +01003140 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3141printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3142 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3143printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
3144 as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
3145 and start over" "$LINENO" 5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003146fi
Matthias Kloseb9621712010-04-24 17:59:49 +00003147## -------------------- ##
3148## Main body of script. ##
3149## -------------------- ##
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003150
Guido van Rossum7f43da71994-08-01 12:15:30 +00003151ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003152ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00003153ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3154ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3155ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003156
Guido van Rossum627b2d71993-12-24 10:39:16 +00003157
Michael W. Hudson54241132001-12-07 15:38:26 +00003158
Trent Nelson4d4ec652012-10-16 08:51:24 -04003159
Christian Heimesff5be6e2018-01-20 13:19:21 +01003160
3161
Martin Panterc5ee3ca2016-09-12 01:32:03 +00003162if test "$srcdir" != . -a "$srcdir" != "$(pwd)"; then
Trent Nelson4d4ec652012-10-16 08:51:24 -04003163 # If we're building out-of-tree, we need to make sure the following
3164 # resources get picked up before their $srcdir counterparts.
3165 # Objects/ -> typeslots.inc
Victor Stinner94faa072021-03-23 20:47:40 +01003166 # Include/ -> Python.h
Trent Nelson4d4ec652012-10-16 08:51:24 -04003167 # Python/ -> importlib.h
3168 # (A side effect of this is that these resources will automatically be
3169 # regenerated when building out-of-tree, regardless of whether or not
3170 # the $srcdir counterpart is up-to-date. This is an acceptable trade
3171 # off.)
3172 BASECPPFLAGS="-IObjects -IInclude -IPython"
3173else
3174 BASECPPFLAGS=""
3175fi
3176
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003177
3178
3179
3180
Victor Stinner9ed34a82017-05-02 22:35:58 +02003181if test -e $srcdir/.git
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003182then
Ned Deily5c4b0d02017-03-04 00:19:55 -05003183# Extract the first word of "git", so it can be a program name with args.
3184set dummy git; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01003185{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3186printf %s "checking for $ac_word... " >&6; }
3187if test ${ac_cv_prog_HAS_GIT+y}
3188then :
3189 printf %s "(cached) " >&6
3190else $as_nop
Ned Deily5c4b0d02017-03-04 00:19:55 -05003191 if test -n "$HAS_GIT"; then
3192 ac_cv_prog_HAS_GIT="$HAS_GIT" # Let the user override the test.
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003193else
3194as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3195for as_dir in $PATH
3196do
3197 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01003198 case $as_dir in #(((
3199 '') as_dir=./ ;;
3200 */) ;;
3201 *) as_dir=$as_dir/ ;;
3202 esac
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003203 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01003204 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Ned Deily5c4b0d02017-03-04 00:19:55 -05003205 ac_cv_prog_HAS_GIT="found"
Pablo Galindoba421752021-05-03 20:33:17 +01003206 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003207 break 2
3208 fi
3209done
3210 done
3211IFS=$as_save_IFS
3212
Ned Deily5c4b0d02017-03-04 00:19:55 -05003213 test -z "$ac_cv_prog_HAS_GIT" && ac_cv_prog_HAS_GIT="not-found"
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003214fi
3215fi
Ned Deily5c4b0d02017-03-04 00:19:55 -05003216HAS_GIT=$ac_cv_prog_HAS_GIT
3217if test -n "$HAS_GIT"; then
Pablo Galindoba421752021-05-03 20:33:17 +01003218 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $HAS_GIT" >&5
3219printf "%s\n" "$HAS_GIT" >&6; }
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003220else
Pablo Galindoba421752021-05-03 20:33:17 +01003221 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3222printf "%s\n" "no" >&6; }
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003223fi
3224
3225
3226else
Ned Deily5c4b0d02017-03-04 00:19:55 -05003227HAS_GIT=no-repository
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003228fi
Ned Deily5c4b0d02017-03-04 00:19:55 -05003229if test $HAS_GIT = found
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003230then
Xiang Zhang4c855572018-08-20 22:36:19 +08003231 GITVERSION="git --git-dir \$(srcdir)/.git rev-parse --short HEAD"
3232 GITTAG="git --git-dir \$(srcdir)/.git describe --all --always --dirty"
3233 GITBRANCH="git --git-dir \$(srcdir)/.git name-rev --name-only HEAD"
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003234else
Ned Deily5c4b0d02017-03-04 00:19:55 -05003235 GITVERSION=""
3236 GITTAG=""
3237 GITBRANCH=""
Benjamin Peterson8c6f88e2011-05-31 20:52:17 -05003238fi
3239
3240
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003241ac_config_headers="$ac_config_headers pyconfig.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00003242
3243
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003244
3245
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003246
Pablo Galindoba421752021-05-03 20:33:17 +01003247 # Make sure we can run config.sub.
3248$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 ||
3249 as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5
3250
3251{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3252printf %s "checking build system type... " >&6; }
3253if test ${ac_cv_build+y}
3254then :
3255 printf %s "(cached) " >&6
3256else $as_nop
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003257 ac_build_alias=$build_alias
3258test "x$ac_build_alias" = x &&
Pablo Galindoba421752021-05-03 20:33:17 +01003259 ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003260test "x$ac_build_alias" = x &&
3261 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
Pablo Galindoba421752021-05-03 20:33:17 +01003262ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
3263 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003264
3265fi
Pablo Galindoba421752021-05-03 20:33:17 +01003266{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3267printf "%s\n" "$ac_cv_build" >&6; }
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003268case $ac_cv_build in
3269*-*-*) ;;
3270*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3271esac
3272build=$ac_cv_build
3273ac_save_IFS=$IFS; IFS='-'
3274set x $ac_cv_build
3275shift
3276build_cpu=$1
3277build_vendor=$2
3278shift; shift
3279# Remember, the first character of IFS is used to create $*,
3280# except with old shells:
3281build_os=$*
3282IFS=$ac_save_IFS
3283case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3284
3285
Pablo Galindoba421752021-05-03 20:33:17 +01003286{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3287printf %s "checking host system type... " >&6; }
3288if test ${ac_cv_host+y}
3289then :
3290 printf %s "(cached) " >&6
3291else $as_nop
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003292 if test "x$host_alias" = x; then
3293 ac_cv_host=$ac_cv_build
3294else
Pablo Galindoba421752021-05-03 20:33:17 +01003295 ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
3296 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003297fi
3298
3299fi
Pablo Galindoba421752021-05-03 20:33:17 +01003300{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3301printf "%s\n" "$ac_cv_host" >&6; }
Matthias Kloseca2f6ec2012-03-15 21:30:11 +01003302case $ac_cv_host in
3303*-*-*) ;;
3304*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3305esac
3306host=$ac_cv_host
3307ac_save_IFS=$IFS; IFS='-'
3308set x $ac_cv_host
3309shift
3310host_cpu=$1
3311host_vendor=$2
3312shift; shift
3313# Remember, the first character of IFS is used to create $*,
3314# except with old shells:
3315host_os=$*
3316IFS=$ac_save_IFS
3317case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3318
3319
3320
doko@python.orga10e4a92013-01-25 18:45:12 +01003321
3322
Ned Deilyfcbc2462014-08-22 13:32:49 -07003323# pybuilddir.txt will be created by --generate-posix-vars in the Makefile
3324rm -f pybuilddir.txt
3325
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003326for ac_prog in python$PACKAGE_VERSION python3 python
3327do
3328 # Extract the first word of "$ac_prog", so it can be a program name with args.
3329set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01003330{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3331printf %s "checking for $ac_word... " >&6; }
3332if test ${ac_cv_prog_PYTHON_FOR_REGEN+y}
3333then :
3334 printf %s "(cached) " >&6
3335else $as_nop
Victor Stinnera5c62a82017-05-03 18:21:48 +02003336 if test -n "$PYTHON_FOR_REGEN"; then
3337 ac_cv_prog_PYTHON_FOR_REGEN="$PYTHON_FOR_REGEN" # Let the user override the test.
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003338else
3339as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3340for as_dir in $PATH
3341do
3342 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01003343 case $as_dir in #(((
3344 '') as_dir=./ ;;
3345 */) ;;
3346 *) as_dir=$as_dir/ ;;
3347 esac
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003348 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01003349 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Victor Stinnera5c62a82017-05-03 18:21:48 +02003350 ac_cv_prog_PYTHON_FOR_REGEN="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01003351 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003352 break 2
3353 fi
3354done
3355 done
3356IFS=$as_save_IFS
3357
3358fi
3359fi
Victor Stinnera5c62a82017-05-03 18:21:48 +02003360PYTHON_FOR_REGEN=$ac_cv_prog_PYTHON_FOR_REGEN
3361if test -n "$PYTHON_FOR_REGEN"; then
Pablo Galindoba421752021-05-03 20:33:17 +01003362 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PYTHON_FOR_REGEN" >&5
3363printf "%s\n" "$PYTHON_FOR_REGEN" >&6; }
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003364else
Pablo Galindoba421752021-05-03 20:33:17 +01003365 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3366printf "%s\n" "no" >&6; }
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003367fi
3368
3369
Victor Stinnera5c62a82017-05-03 18:21:48 +02003370 test -n "$PYTHON_FOR_REGEN" && break
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003371done
Victor Stinnera5c62a82017-05-03 18:21:48 +02003372test -n "$PYTHON_FOR_REGEN" || PYTHON_FOR_REGEN="python3"
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003373
Xavier de Gayefd0d5932016-07-26 12:48:08 +02003374
3375
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003376if test "$cross_compiling" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01003377 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for python interpreter for cross build" >&5
3378printf %s "checking for python interpreter for cross build... " >&6; }
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003379 if test -z "$PYTHON_FOR_BUILD"; then
3380 for interp in python$PACKAGE_VERSION python3 python; do
3381 which $interp >/dev/null 2>&1 || continue
Xavier de Gaye4afd1432016-07-07 18:00:22 +02003382 if $interp -c "import sys;sys.exit(not '.'.join(str(n) for n in sys.version_info[:2]) == '$PACKAGE_VERSION')"; then
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003383 break
3384 fi
3385 interp=
3386 done
3387 if test x$interp = x; then
3388 as_fn_error $? "python$PACKAGE_VERSION interpreter not found" "$LINENO" 5
3389 fi
Pablo Galindoba421752021-05-03 20:33:17 +01003390 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $interp" >&5
3391printf "%s\n" "$interp" >&6; }
Xavier de Gaye92dec542016-09-11 22:22:24 +02003392 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
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003393 fi
Christian Heimes954ac032012-12-12 13:10:21 +01003394elif test "$cross_compiling" = maybe; then
3395 as_fn_error $? "Cross compiling required --host=HOST-TUPLE and --build=ARCH" "$LINENO" 5
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003396else
3397 PYTHON_FOR_BUILD='./$(BUILDPYTHON) -E'
3398fi
3399
3400
Martin v. Löwis11437992002-04-12 09:54:03 +00003401
Benjamin Petersond23f8222009-04-05 19:13:16 +00003402if test "$prefix" != "/"; then
3403 prefix=`echo "$prefix" | sed -e 's/\/$//g'`
3404fi
3405
3406
Martin v. Löwis11437992002-04-12 09:54:03 +00003407
3408
Martin v. Löwis8316feb2003-06-14 07:48:07 +00003409# We don't use PACKAGE_ variables, and they cause conflicts
3410# with other autoconf-based packages that include Python.h
3411grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new
3412rm confdefs.h
3413mv confdefs.h.new confdefs.h
3414
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00003415
Pablo Galindod4fe0982020-05-19 03:33:01 +01003416VERSION=3.10
Guido van Rossum1fd74a71997-07-19 19:36:02 +00003417
Benjamin Petersond7f73e92010-09-05 00:09:07 +00003418# Version number of Python's own shared library file.
Martin v. Löwis1142de32002-03-29 16:28:31 +00003419
3420SOVERSION=1.0
3421
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00003422# The later defininition of _XOPEN_SOURCE disables certain features
3423# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
3424
Pablo Galindoba421752021-05-03 20:33:17 +01003425printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00003426
3427
Martin v. Löwisbcd93962003-05-03 10:32:18 +00003428# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
3429# certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable
3430# them.
3431
Pablo Galindoba421752021-05-03 20:33:17 +01003432printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
Martin v. Löwisbcd93962003-05-03 10:32:18 +00003433
3434
Andrew MacIntyreabccf412003-07-02 13:53:25 +00003435# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
3436# certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable
3437# them.
3438
Pablo Galindoba421752021-05-03 20:33:17 +01003439printf "%s\n" "#define __BSD_VISIBLE 1" >>confdefs.h
Andrew MacIntyreabccf412003-07-02 13:53:25 +00003440
3441
Martin v. Löwisd6320502004-08-12 13:45:08 +00003442# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003443# certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable
3444# them.
3445
Pablo Galindoba421752021-05-03 20:33:17 +01003446printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003447
3448
3449
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003450define_xopen_source=yes
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00003451
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00003452# Arguments passed to configure.
3453
3454CONFIG_ARGS="$ac_configure_args"
3455
Pablo Galindoba421752021-05-03 20:33:17 +01003456{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5
3457printf %s "checking for --enable-universalsdk... " >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003458# Check whether --enable-universalsdk was given.
Pablo Galindoba421752021-05-03 20:33:17 +01003459if test ${enable_universalsdk+y}
3460then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003461 enableval=$enable_universalsdk;
Thomas Wouters477c8d52006-05-27 19:21:47 +00003462 case $enableval in
3463 yes)
Serhiy Storchaka88cc3392018-06-04 08:20:25 +03003464 # Locate the best usable SDK, see Mac/README for more
Ned Deilycbfb9a52012-06-23 16:02:19 -07003465 # information
3466 enableval="`/usr/bin/xcodebuild -version -sdk macosx Path 2>/dev/null`"
Ned Deily87adb6e2013-10-18 21:09:56 -07003467 if ! ( echo $enableval | grep -E '\.sdk' 1>/dev/null )
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003468 then
Ned Deilycbfb9a52012-06-23 16:02:19 -07003469 enableval=/Developer/SDKs/MacOSX10.4u.sdk
3470 if test ! -d "${enableval}"
3471 then
3472 enableval=/
3473 fi
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003474 fi
Thomas Wouters477c8d52006-05-27 19:21:47 +00003475 ;;
3476 esac
3477 case $enableval in
3478 no)
3479 UNIVERSALSDK=
3480 enable_universalsdk=
3481 ;;
3482 *)
3483 UNIVERSALSDK=$enableval
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003484 if test ! -d "${UNIVERSALSDK}"
3485 then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02003486 as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003487 fi
Thomas Wouters477c8d52006-05-27 19:21:47 +00003488 ;;
3489 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00003490
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003491
Pablo Galindoba421752021-05-03 20:33:17 +01003492else $as_nop
Thomas Wouters477c8d52006-05-27 19:21:47 +00003493
3494 UNIVERSALSDK=
3495 enable_universalsdk=
3496
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003497fi
Thomas Wouters477c8d52006-05-27 19:21:47 +00003498
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003499if test -n "${UNIVERSALSDK}"
3500then
Pablo Galindoba421752021-05-03 20:33:17 +01003501 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5
3502printf "%s\n" "${UNIVERSALSDK}" >&6; }
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003503else
Pablo Galindoba421752021-05-03 20:33:17 +01003504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3505printf "%s\n" "no" >&6; }
Ronald Oussoren8af24c12010-02-07 12:03:42 +00003506fi
Thomas Wouters477c8d52006-05-27 19:21:47 +00003507
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003508
Benjamin Peterson6794aa32008-07-16 20:33:37 +00003509
Ned Deily87adb6e2013-10-18 21:09:56 -07003510ARCH_RUN_32BIT=""
Benjamin Peterson6794aa32008-07-16 20:33:37 +00003511
Ned Deilycbfb9a52012-06-23 16:02:19 -07003512# For backward compatibility reasons we prefer to select '32-bit' if available,
3513# otherwise use 'intel'
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003514UNIVERSAL_ARCHS="32-bit"
Ned Deilycbfb9a52012-06-23 16:02:19 -07003515if test "`uname -s`" = "Darwin"
3516then
3517 if test -n "${UNIVERSALSDK}"
3518 then
Ned Deily87adb6e2013-10-18 21:09:56 -07003519 if test -z "`/usr/bin/file -L "${UNIVERSALSDK}/usr/lib/libSystem.dylib" | grep ppc`"
Ned Deilycbfb9a52012-06-23 16:02:19 -07003520 then
3521 UNIVERSAL_ARCHS="intel"
3522 fi
3523 fi
3524fi
3525
Ronald Oussoren6f6c5622009-12-24 14:03:19 +00003526
Ned Deily0cb33da2021-05-02 04:48:29 -04003527
Pablo Galindoba421752021-05-03 20:33:17 +01003528{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5
3529printf %s "checking for --with-universal-archs... " >&6; }
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003530
3531# Check whether --with-universal-archs was given.
Pablo Galindoba421752021-05-03 20:33:17 +01003532if test ${with_universal_archs+y}
3533then :
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003534 withval=$with_universal_archs;
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003535 UNIVERSAL_ARCHS="$withval"
3536
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003537fi
3538
Ned Deily87adb6e2013-10-18 21:09:56 -07003539if test -n "${UNIVERSALSDK}"
3540then
Pablo Galindoba421752021-05-03 20:33:17 +01003541 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSAL_ARCHS}" >&5
3542printf "%s\n" "${UNIVERSAL_ARCHS}" >&6; }
Ned Deily87adb6e2013-10-18 21:09:56 -07003543else
Pablo Galindoba421752021-05-03 20:33:17 +01003544 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3545printf "%s\n" "no" >&6; }
Ned Deily87adb6e2013-10-18 21:09:56 -07003546fi
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003547
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003548
3549# Check whether --with-framework-name was given.
Pablo Galindoba421752021-05-03 20:33:17 +01003550if test ${with_framework_name+y}
3551then :
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003552 withval=$with_framework_name;
3553 PYTHONFRAMEWORK=${withval}
3554 PYTHONFRAMEWORKDIR=${withval}.framework
3555 PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'`
3556
Pablo Galindoba421752021-05-03 20:33:17 +01003557else $as_nop
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003558
3559 PYTHONFRAMEWORK=Python
3560 PYTHONFRAMEWORKDIR=Python.framework
3561 PYTHONFRAMEWORKIDENTIFIER=org.python.python
3562
3563fi
3564
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003565# Check whether --enable-framework was given.
Pablo Galindoba421752021-05-03 20:33:17 +01003566if test ${enable_framework+y}
3567then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003568 enableval=$enable_framework;
Jack Jansene578a632001-08-15 01:27:14 +00003569 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00003570 yes)
Jack Jansene578a632001-08-15 01:27:14 +00003571 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00003572 esac
3573 case $enableval in
3574 no)
3575 PYTHONFRAMEWORK=
3576 PYTHONFRAMEWORKDIR=no-framework
3577 PYTHONFRAMEWORKPREFIX=
3578 PYTHONFRAMEWORKINSTALLDIR=
Thomas Wouters477c8d52006-05-27 19:21:47 +00003579 FRAMEWORKINSTALLFIRST=
3580 FRAMEWORKINSTALLLAST=
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003581 FRAMEWORKALTINSTALLFIRST=
3582 FRAMEWORKALTINSTALLLAST=
Ned Deilyb8f944f2013-11-21 22:42:25 -08003583 FRAMEWORKPYTHONW=
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003584 if test "x${prefix}" = "xNONE"; then
3585 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
3586 else
3587 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3588 fi
Jack Jansen127e56e2001-09-11 14:41:54 +00003589 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00003590 ;;
3591 *)
Ronald Oussoren86b33c82010-04-30 11:41:56 +00003592 PYTHONFRAMEWORKPREFIX="${enableval}"
Jack Jansen127e56e2001-09-11 14:41:54 +00003593 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
Thomas Wouters477c8d52006-05-27 19:21:47 +00003594 FRAMEWORKINSTALLFIRST="frameworkinstallstructure"
Ronald Oussorenf6ccbf62009-06-02 10:55:56 +00003595 FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure "
Ronald Oussoren6f6c5622009-12-24 14:03:19 +00003596 FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools"
3597 FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools"
Ned Deilyb8f944f2013-11-21 22:42:25 -08003598 FRAMEWORKPYTHONW="frameworkpythonw"
Ronald Oussoren86b33c82010-04-30 11:41:56 +00003599 FRAMEWORKINSTALLAPPSPREFIX="/Applications"
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003600
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003601 if test "x${prefix}" = "xNONE" ; then
3602 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
Ronald Oussoren86b33c82010-04-30 11:41:56 +00003603
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003604 else
3605 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3606 fi
Ronald Oussoren86b33c82010-04-30 11:41:56 +00003607
3608 case "${enableval}" in
3609 /System*)
3610 FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3611 if test "${prefix}" = "NONE" ; then
3612 # See below
3613 FRAMEWORKUNIXTOOLSPREFIX="/usr"
3614 fi
3615 ;;
3616
3617 /Library*)
3618 FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3619 ;;
3620
3621 */Library/Frameworks)
3622 MDIR="`dirname "${enableval}"`"
3623 MDIR="`dirname "${MDIR}"`"
3624 FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications"
3625
3626 if test "${prefix}" = "NONE"; then
3627 # User hasn't specified the
3628 # --prefix option, but wants to install
3629 # the framework in a non-default location,
3630 # ensure that the compatibility links get
3631 # installed relative to that prefix as well
3632 # instead of in /usr/local.
3633 FRAMEWORKUNIXTOOLSPREFIX="${MDIR}"
3634 fi
3635 ;;
3636
3637 *)
3638 FRAMEWORKINSTALLAPPSPREFIX="/Applications"
3639 ;;
3640 esac
3641
Jack Jansen127e56e2001-09-11 14:41:54 +00003642 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Thomas Wouters477c8d52006-05-27 19:21:47 +00003643
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003644 # Add files for Mac specific code to the list of output
Thomas Wouters477c8d52006-05-27 19:21:47 +00003645 # files:
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003646 ac_config_files="$ac_config_files Mac/Makefile"
Thomas Wouters477c8d52006-05-27 19:21:47 +00003647
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003648 ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile"
Thomas Wouters477c8d52006-05-27 19:21:47 +00003649
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003650 ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist"
3651
3652 ac_config_files="$ac_config_files Mac/Resources/app/Info.plist"
3653
Jack Jansene578a632001-08-15 01:27:14 +00003654 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00003655
Pablo Galindoba421752021-05-03 20:33:17 +01003656else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00003657
Jack Jansene578a632001-08-15 01:27:14 +00003658 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00003659 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00003660 PYTHONFRAMEWORKPREFIX=
3661 PYTHONFRAMEWORKINSTALLDIR=
Thomas Wouters477c8d52006-05-27 19:21:47 +00003662 FRAMEWORKINSTALLFIRST=
3663 FRAMEWORKINSTALLLAST=
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003664 FRAMEWORKALTINSTALLFIRST=
3665 FRAMEWORKALTINSTALLLAST=
Ned Deilyb8f944f2013-11-21 22:42:25 -08003666 FRAMEWORKPYTHONW=
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003667 if test "x${prefix}" = "xNONE" ; then
3668 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
3669 else
3670 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
3671 fi
Jack Jansene578a632001-08-15 01:27:14 +00003672 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003673
Benjamin Peterson14ae9592008-07-16 02:20:15 +00003674
Thomas Wouters47b49bf2007-08-30 22:15:33 +00003675fi
3676
Thomas Wouters477c8d52006-05-27 19:21:47 +00003677
3678
Michael W. Hudson54241132001-12-07 15:38:26 +00003679
3680
3681
3682
Jack Jansene578a632001-08-15 01:27:14 +00003683
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00003684
3685
3686
Christian Heimes81ee3ef2008-05-04 22:42:01 +00003687
Ronald Oussoren86b33c82010-04-30 11:41:56 +00003688
Ned Deilyb8f944f2013-11-21 22:42:25 -08003689
INADA Naokia8f8d5b2017-06-29 00:31:53 +09003690
Pablo Galindoba421752021-05-03 20:33:17 +01003691printf "%s\n" "#define _PYTHONFRAMEWORK \"${PYTHONFRAMEWORK}\"" >>confdefs.h
INADA Naokia8f8d5b2017-06-29 00:31:53 +09003692
3693
Jack Jansene578a632001-08-15 01:27:14 +00003694##AC_ARG_WITH(dyld,
Matthias Klose2b8733f2010-04-25 18:34:36 +00003695## AS_HELP_STRING([--with-dyld],
Anthony Shaw2de064e2020-01-14 17:40:10 +11003696## [use (OpenStep|Rhapsody) dynamic linker]))
Jack Jansene578a632001-08-15 01:27:14 +00003697##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003698# Set name for machine-dependent library files
3699
Pablo Galindoba421752021-05-03 20:33:17 +01003700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5
3701printf %s "checking MACHDEP... " >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003702if test -z "$MACHDEP"
3703then
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003704 # avoid using uname for cross builds
3705 if test "$cross_compiling" = yes; then
doko@python.org44bbbda2013-01-25 14:44:00 +01003706 # ac_sys_system and ac_sys_release are used for setting
3707 # a lot of different things including 'define_xopen_source'
3708 # in the case statement below.
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003709 case "$host" in
Xavier de Gaye2a352b62017-01-04 21:51:16 +01003710 *-*-linux-android*)
3711 ac_sys_system=Linux-android
3712 ;;
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003713 *-*-linux*)
3714 ac_sys_system=Linux
3715 ;;
3716 *-*-cygwin*)
3717 ac_sys_system=Cygwin
3718 ;;
pxinwr32f5fdd2019-02-27 19:09:28 +08003719 *-*-vxworks*)
3720 ac_sys_system=VxWorks
3721 ;;
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003722 *)
3723 # for now, limit cross builds to known configurations
3724 MACHDEP="unknown"
3725 as_fn_error $? "cross build not supported for $host" "$LINENO" 5
3726 esac
3727 ac_sys_release=
3728 else
Guido van Rossum563e7081996-09-10 18:20:48 +00003729 ac_sys_system=`uname -s`
Benjamin Peterson8719ad52009-09-11 22:24:02 +00003730 if test "$ac_sys_system" = "AIX" \
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003731 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00003732 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003733 else
Guido van Rossum563e7081996-09-10 18:20:48 +00003734 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003735 fi
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003736 fi
3737 ac_md_system=`echo $ac_sys_system |
3738 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
3739 ac_md_release=`echo $ac_sys_release |
3740 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
3741 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00003742
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003743 case $MACHDEP in
Michael Felt9d949f72019-04-12 16:15:32 +02003744 aix*) MACHDEP="aix";;
Victor Stinner7209ff22011-08-21 00:00:16 +02003745 linux*) MACHDEP="linux";;
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00003746 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00003747 darwin*) MACHDEP="darwin";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00003748 '') MACHDEP="unknown";;
Matthias Klosedf2aecb2012-03-15 22:19:28 +01003749 esac
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003750fi
Pablo Galindoba421752021-05-03 20:33:17 +01003751{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \"$MACHDEP\"" >&5
3752printf "%s\n" "\"$MACHDEP\"" >&6; }
Guido van Rossum91922671997-10-09 20:24:13 +00003753
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003754
3755if test "$cross_compiling" = yes; then
3756 case "$host" in
3757 *-*-linux*)
3758 case "$host_cpu" in
3759 arm*)
3760 _host_cpu=arm
3761 ;;
3762 *)
3763 _host_cpu=$host_cpu
3764 esac
3765 ;;
3766 *-*-cygwin*)
3767 _host_cpu=
3768 ;;
pxinwr32f5fdd2019-02-27 19:09:28 +08003769 *-*-vxworks*)
3770 _host_cpu=$host_cpu
3771 ;;
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02003772 *)
3773 # for now, limit cross builds to known configurations
3774 MACHDEP="unknown"
3775 as_fn_error $? "cross build not supported for $host" "$LINENO" 5
3776 esac
3777 _PYTHON_HOST_PLATFORM="$MACHDEP${_host_cpu:+-$_host_cpu}"
3778fi
3779
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003780# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
3781# disable features if it is defined, without any means to access these
3782# features as extensions. For these systems, we skip the definition of
3783# _XOPEN_SOURCE. Before adding a system to the list to gain access to
3784# some feature, make sure there is no alternative way to access this
3785# feature. Also, when using wildcards, make sure you have verified the
3786# need for not defining _XOPEN_SOURCE on all systems matching the
3787# wildcard, and that the wildcard does not include future systems
3788# (which may remove their limitations).
3789case $ac_sys_system/$ac_sys_release in
3790 # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
3791 # even though select is a POSIX function. Reported by J. Ribbens.
Martin v. Löwis76bafc62003-10-03 13:47:44 +00003792 # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish.
Martin v. Löwis19ed3c82010-02-15 21:45:06 +00003793 # In addition, Stefan Krah confirms that issue #1244610 exists through
3794 # OpenBSD 4.6, but is fixed in 4.7.
Charles-François Natali54ef40b2011-07-22 23:52:02 +02003795 OpenBSD/2.* | OpenBSD/3.* | OpenBSD/4.[0123456])
Christian Heimes5b5e81c2007-12-31 16:14:33 +00003796 define_xopen_source=no
3797 # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
3798 # also defined. This can be overridden by defining _BSD_SOURCE
3799 # As this has a different meaning on Linux, only define it on OpenBSD
3800
Pablo Galindoba421752021-05-03 20:33:17 +01003801printf "%s\n" "#define _BSD_SOURCE 1" >>confdefs.h
Christian Heimes5b5e81c2007-12-31 16:14:33 +00003802
3803 ;;
Charles-François Natali54ef40b2011-07-22 23:52:02 +02003804 OpenBSD/*)
Martin v. Löwis7671efc2010-02-15 08:35:16 +00003805 # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
3806 # also defined. This can be overridden by defining _BSD_SOURCE
3807 # As this has a different meaning on Linux, only define it on OpenBSD
3808
Pablo Galindoba421752021-05-03 20:33:17 +01003809printf "%s\n" "#define _BSD_SOURCE 1" >>confdefs.h
Martin v. Löwis7671efc2010-02-15 08:35:16 +00003810
3811 ;;
Thomas Wouters89f507f2006-12-13 04:49:30 +00003812 # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of
3813 # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by
3814 # Marc Recht
Benjamin Petersonf608c612008-11-16 18:33:53 +00003815 NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S])
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003816 define_xopen_source=no;;
Martin v. Löwis1a415762010-05-28 15:44:20 +00003817 # From the perspective of Solaris, _XOPEN_SOURCE is not so much a
3818 # request to enable features supported by the standard as a request
3819 # to disable features not supported by the standard. The best way
3820 # for Python to use Solaris is simply to leave _XOPEN_SOURCE out
3821 # entirely and define __EXTENSIONS__ instead.
3822 SunOS/*)
Martin v. Löwisa9d71422003-03-28 18:43:31 +00003823 define_xopen_source=no;;
Martin v. Löwisc2409b42003-05-11 05:53:41 +00003824 # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
3825 # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
Jack Jansen6b08a402004-06-03 12:41:45 +00003826 # Reconfirmed for 7.1.4 by Martin v. Loewis.
Martin v. Löwis253d1f42004-05-07 19:14:14 +00003827 OpenUNIX/8.0.0| UnixWare/7.1.[0-4])
Martin v. Löwisc2409b42003-05-11 05:53:41 +00003828 define_xopen_source=no;;
3829 # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
Martin v. Löwis53e73c32003-05-05 05:13:18 +00003830 # but used in struct sockaddr.sa_family. Reported by Tim Rice.
Martin v. Löwisc2409b42003-05-11 05:53:41 +00003831 SCO_SV/3.2)
Martin v. Löwis53e73c32003-05-05 05:13:18 +00003832 define_xopen_source=no;;
Martin v. Löwisb37509b2008-11-04 20:45:29 +00003833 # On MacOS X 10.2, a bug in ncurses.h means that it craps out if
3834 # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which
3835 # identifies itself as Darwin/7.*
3836 # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
3837 # disables platform specific features beyond repair.
3838 # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
3839 # has no effect, don't bother defining them
3840 Darwin/[6789].*)
Anthony Baxter6169c6b2003-10-04 07:46:23 +00003841 define_xopen_source=no;;
Ronald Oussoren8ea63532020-06-25 16:55:48 +02003842 Darwin/[12][0-9].*)
Ronald Oussorenb8f11a62010-03-08 07:02:03 +00003843 define_xopen_source=no;;
Benjamin Petersonde9c8692008-07-01 18:23:09 +00003844 # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from
3845 # defining NI_NUMERICHOST.
3846 QNX/6.3.2)
3847 define_xopen_source=no
3848 ;;
pxinwr32f5fdd2019-02-27 19:09:28 +08003849 # On VxWorks, defining _XOPEN_SOURCE causes compile failures
3850 # in network headers still using system V types.
3851 VxWorks/*)
3852 define_xopen_source=no
3853 ;;
Bob Ippolito7026a0a2005-03-28 23:23:47 +00003854
Ian Nortona9edf442020-02-14 03:09:11 +00003855 # On HP-UX, defining _XOPEN_SOURCE to 600 or greater hides
3856 # chroot() and other functions
3857 hp*|HP*)
3858 define_xopen_source=no
3859 ;;
3860
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003861esac
3862
3863if test $define_xopen_source = yes
3864then
Victor Stinner14d098d2011-09-07 22:29:43 +02003865 # X/Open 7, incorporating POSIX.1-2008
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00003866
Pablo Galindoba421752021-05-03 20:33:17 +01003867printf "%s\n" "#define _XOPEN_SOURCE 700" >>confdefs.h
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003868
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00003869
3870 # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
3871 # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
3872 # several APIs are not declared. Since this is also needed in some
3873 # cases for HP-UX, we define it globally.
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00003874
Pablo Galindoba421752021-05-03 20:33:17 +01003875printf "%s\n" "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00003876
3877
Bob Ippolito7026a0a2005-03-28 23:23:47 +00003878
Pablo Galindoba421752021-05-03 20:33:17 +01003879printf "%s\n" "#define _POSIX_C_SOURCE 200809L" >>confdefs.h
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00003880
Martin v. Löwis35195ad2002-11-11 13:26:51 +00003881fi
3882
Christian Heimes647cd872013-12-07 23:39:33 +01003883# On HP-UX mbstate_t requires _INCLUDE__STDC_A1_SOURCE
3884case $ac_sys_system in
Christian Heimesb02bcae2013-12-08 15:21:08 +01003885 hp*|HP*)
3886 define_stdc_a1=yes;;
3887 *)
3888 define_stdc_a1=no;;
3889esac
3890
3891if test $define_stdc_a1 = yes
3892then
Christian Heimes647cd872013-12-07 23:39:33 +01003893
Pablo Galindoba421752021-05-03 20:33:17 +01003894printf "%s\n" "#define _INCLUDE__STDC_A1_SOURCE 1" >>confdefs.h
Christian Heimes647cd872013-12-07 23:39:33 +01003895
Christian Heimesb02bcae2013-12-08 15:21:08 +01003896fi
Christian Heimes647cd872013-12-07 23:39:33 +01003897
Jack Jansen6b08a402004-06-03 12:41:45 +00003898# Record the configure-time value of MACOSX_DEPLOYMENT_TARGET,
3899# it may influence the way we can build extensions, so distutils
3900# needs to check it
3901
Thomas Wouters477c8d52006-05-27 19:21:47 +00003902
Jack Jansen6b08a402004-06-03 12:41:45 +00003903CONFIGURE_MACOSX_DEPLOYMENT_TARGET=
Thomas Wouters477c8d52006-05-27 19:21:47 +00003904EXPORT_MACOSX_DEPLOYMENT_TARGET='#'
Jack Jansen6b08a402004-06-03 12:41:45 +00003905
Guido van Rossum627b2d71993-12-24 10:39:16 +00003906# checks for alternative programs
Skip Montanarodecc6a42003-01-01 20:07:49 +00003907
3908# compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just
3909# for debug/optimization stuff. BASECFLAGS is for flags that are required
3910# just to get things to compile and link. Users are free to override OPT
3911# when running configure or make. The build should not break if they do.
3912# BASECFLAGS should generally not be messed with, however.
3913
Guido van Rossum8b131c51995-03-09 14:10:13 +00003914# If the user switches compilers, we can't believe the cache
3915if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
3916then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02003917 as_fn_error $? "cached CC is different -- throw away $cache_file
Matthias Kloseb9621712010-04-24 17:59:49 +00003918(it is also a good idea to do 'make clean' before compiling)" "$LINENO" 5
Guido van Rossum8b131c51995-03-09 14:10:13 +00003919fi
3920
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +00003921# Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2
3922# when the compiler supports them, but we don't always want -O2, and
3923# we set -g later.
3924if test -z "$CFLAGS"; then
3925 CFLAGS=
3926fi
Ned Deilycbfb9a52012-06-23 16:02:19 -07003927
3928if test "$ac_sys_system" = "Darwin"
3929then
3930 # Compiler selection on MacOSX is more complicated than
Serhiy Storchaka88cc3392018-06-04 08:20:25 +03003931 # AC_PROG_CC can handle, see Mac/README for more
Ned Deilycbfb9a52012-06-23 16:02:19 -07003932 # information
3933 if test -z "${CC}"
3934 then
3935 found_gcc=
3936 found_clang=
3937 as_save_IFS=$IFS; IFS=:
3938 for as_dir in $PATH
3939 do
3940 IFS=$as_save_IFS
Ned Deily14aa00b2017-10-09 13:53:27 -04003941 if test -x "${as_dir}/gcc"; then
Ned Deilycbfb9a52012-06-23 16:02:19 -07003942 if test -z "${found_gcc}"; then
Ned Deily14aa00b2017-10-09 13:53:27 -04003943 found_gcc="${as_dir}/gcc"
Ned Deilycbfb9a52012-06-23 16:02:19 -07003944 fi
3945 fi
Ned Deily14aa00b2017-10-09 13:53:27 -04003946 if test -x "${as_dir}/clang"; then
Ned Deilycbfb9a52012-06-23 16:02:19 -07003947 if test -z "${found_clang}"; then
Ned Deily14aa00b2017-10-09 13:53:27 -04003948 found_clang="${as_dir}/clang"
Ned Deilycbfb9a52012-06-23 16:02:19 -07003949 fi
3950 fi
3951 done
3952 IFS=$as_save_IFS
3953
3954 if test -n "$found_gcc" -a -n "$found_clang"
3955 then
3956 if test -n "`"$found_gcc" --version | grep llvm-gcc`"
3957 then
Pablo Galindoba421752021-05-03 20:33:17 +01003958 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: Detected llvm-gcc, falling back to clang" >&5
3959printf "%s\n" "$as_me: Detected llvm-gcc, falling back to clang" >&6;}
Ned Deilycbfb9a52012-06-23 16:02:19 -07003960 CC="$found_clang"
3961 CXX="$found_clang++"
3962 fi
3963
3964
3965 elif test -z "$found_gcc" -a -n "$found_clang"
3966 then
Pablo Galindoba421752021-05-03 20:33:17 +01003967 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: No GCC found, use CLANG" >&5
3968printf "%s\n" "$as_me: No GCC found, use CLANG" >&6;}
Ned Deilycbfb9a52012-06-23 16:02:19 -07003969 CC="$found_clang"
3970 CXX="$found_clang++"
3971
3972 elif test -z "$found_gcc" -a -z "$found_clang"
3973 then
3974 found_clang=`/usr/bin/xcrun -find clang 2>/dev/null`
3975 if test -n "${found_clang}"
3976 then
Pablo Galindoba421752021-05-03 20:33:17 +01003977 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: Using clang from Xcode.app" >&5
3978printf "%s\n" "$as_me: Using clang from Xcode.app" >&6;}
Ned Deilycbfb9a52012-06-23 16:02:19 -07003979 CC="${found_clang}"
3980 CXX="`/usr/bin/xcrun -find clang++`"
3981
3982 # else: use default behaviour
3983 fi
3984 fi
3985 fi
3986fi
Pablo Galindoba421752021-05-03 20:33:17 +01003987
3988
3989
3990
3991
3992
3993
3994
3995
Martin v. Löwis11437992002-04-12 09:54:03 +00003996ac_ext=c
3997ac_cpp='$CPP $CPPFLAGS'
3998ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3999ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4000ac_compiler_gnu=$ac_cv_c_compiler_gnu
4001if test -n "$ac_tool_prefix"; then
4002 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4003set dummy ${ac_tool_prefix}gcc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004004{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4005printf %s "checking for $ac_word... " >&6; }
4006if test ${ac_cv_prog_CC+y}
4007then :
4008 printf %s "(cached) " >&6
4009else $as_nop
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004010 if test -n "$CC"; then
4011 ac_cv_prog_CC="$CC" # Let the user override the test.
4012else
Martin v. Löwis11437992002-04-12 09:54:03 +00004013as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4014for as_dir in $PATH
4015do
4016 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004017 case $as_dir in #(((
4018 '') as_dir=./ ;;
4019 */) ;;
4020 *) as_dir=$as_dir/ ;;
4021 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004022 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004023 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004024 ac_cv_prog_CC="${ac_tool_prefix}gcc"
Pablo Galindoba421752021-05-03 20:33:17 +01004025 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004026 break 2
4027 fi
4028done
Matthias Kloseb9621712010-04-24 17:59:49 +00004029 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004030IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00004031
Jack Jansendd19cf82001-12-06 22:36:17 +00004032fi
4033fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004034CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00004035if test -n "$CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004036 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4037printf "%s\n" "$CC" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00004038else
Pablo Galindoba421752021-05-03 20:33:17 +01004039 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4040printf "%s\n" "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004041fi
4042
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004043
Martin v. Löwis11437992002-04-12 09:54:03 +00004044fi
4045if test -z "$ac_cv_prog_CC"; then
4046 ac_ct_CC=$CC
4047 # Extract the first word of "gcc", so it can be a program name with args.
4048set dummy gcc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004049{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4050printf %s "checking for $ac_word... " >&6; }
4051if test ${ac_cv_prog_ac_ct_CC+y}
4052then :
4053 printf %s "(cached) " >&6
4054else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00004055 if test -n "$ac_ct_CC"; then
4056 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4057else
4058as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4059for as_dir in $PATH
4060do
4061 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004062 case $as_dir in #(((
4063 '') as_dir=./ ;;
4064 */) ;;
4065 *) as_dir=$as_dir/ ;;
4066 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004067 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004068 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004069 ac_cv_prog_ac_ct_CC="gcc"
Pablo Galindoba421752021-05-03 20:33:17 +01004070 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004071 break 2
4072 fi
4073done
Matthias Kloseb9621712010-04-24 17:59:49 +00004074 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004075IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00004076
4077fi
4078fi
4079ac_ct_CC=$ac_cv_prog_ac_ct_CC
4080if test -n "$ac_ct_CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004081 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4082printf "%s\n" "$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004083else
Pablo Galindoba421752021-05-03 20:33:17 +01004084 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4085printf "%s\n" "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004086fi
4087
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004088 if test "x$ac_ct_CC" = x; then
4089 CC=""
4090 else
4091 case $cross_compiling:$ac_tool_warned in
4092yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01004093{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4094printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004095ac_tool_warned=yes ;;
4096esac
4097 CC=$ac_ct_CC
4098 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004099else
4100 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00004101fi
4102
Jack Jansendd19cf82001-12-06 22:36:17 +00004103if test -z "$CC"; then
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004104 if test -n "$ac_tool_prefix"; then
4105 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
Martin v. Löwis11437992002-04-12 09:54:03 +00004106set dummy ${ac_tool_prefix}cc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004107{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4108printf %s "checking for $ac_word... " >&6; }
4109if test ${ac_cv_prog_CC+y}
4110then :
4111 printf %s "(cached) " >&6
4112else $as_nop
Jack Jansendd19cf82001-12-06 22:36:17 +00004113 if test -n "$CC"; then
4114 ac_cv_prog_CC="$CC" # Let the user override the test.
4115else
Martin v. Löwis11437992002-04-12 09:54:03 +00004116as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4117for as_dir in $PATH
4118do
4119 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004120 case $as_dir in #(((
4121 '') as_dir=./ ;;
4122 */) ;;
4123 *) as_dir=$as_dir/ ;;
4124 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004125 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004126 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004127 ac_cv_prog_CC="${ac_tool_prefix}cc"
Pablo Galindoba421752021-05-03 20:33:17 +01004128 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004129 break 2
4130 fi
4131done
Matthias Kloseb9621712010-04-24 17:59:49 +00004132 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004133IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00004134
4135fi
4136fi
4137CC=$ac_cv_prog_CC
4138if test -n "$CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004139 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4140printf "%s\n" "$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004141else
Pablo Galindoba421752021-05-03 20:33:17 +01004142 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4143printf "%s\n" "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004144fi
4145
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004146
Martin v. Löwis11437992002-04-12 09:54:03 +00004147 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004148fi
4149if test -z "$CC"; then
4150 # Extract the first word of "cc", so it can be a program name with args.
4151set dummy cc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4153printf %s "checking for $ac_word... " >&6; }
4154if test ${ac_cv_prog_CC+y}
4155then :
4156 printf %s "(cached) " >&6
4157else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00004158 if test -n "$CC"; then
4159 ac_cv_prog_CC="$CC" # Let the user override the test.
4160else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004161 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004162as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4163for as_dir in $PATH
4164do
4165 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004166 case $as_dir in #(((
4167 '') as_dir=./ ;;
4168 */) ;;
4169 *) as_dir=$as_dir/ ;;
4170 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004171 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004172 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4173 if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004174 ac_prog_rejected=yes
4175 continue
4176 fi
4177 ac_cv_prog_CC="cc"
Pablo Galindoba421752021-05-03 20:33:17 +01004178 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004179 break 2
4180 fi
4181done
Matthias Kloseb9621712010-04-24 17:59:49 +00004182 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004183IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00004184
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004185if test $ac_prog_rejected = yes; then
4186 # We found a bogon in the path, so make sure we never use it.
4187 set dummy $ac_cv_prog_CC
4188 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00004189 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004190 # We chose a different compiler from the bogus one.
4191 # However, it has the same basename, so the bogon will be chosen
4192 # first if we set CC to just the basename; use the full file name.
4193 shift
Pablo Galindoba421752021-05-03 20:33:17 +01004194 ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004195 fi
4196fi
4197fi
4198fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004199CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004200if test -n "$CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004201 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4202printf "%s\n" "$CC" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004203else
Pablo Galindoba421752021-05-03 20:33:17 +01004204 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4205printf "%s\n" "no" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004206fi
4207
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004208
Martin v. Löwis11437992002-04-12 09:54:03 +00004209fi
4210if test -z "$CC"; then
4211 if test -n "$ac_tool_prefix"; then
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004212 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00004213 do
4214 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4215set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004216{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4217printf %s "checking for $ac_word... " >&6; }
4218if test ${ac_cv_prog_CC+y}
4219then :
4220 printf %s "(cached) " >&6
4221else $as_nop
Guido van Rossume6c2cf11999-01-08 21:08:33 +00004222 if test -n "$CC"; then
4223 ac_cv_prog_CC="$CC" # Let the user override the test.
4224else
Martin v. Löwis11437992002-04-12 09:54:03 +00004225as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4226for as_dir in $PATH
4227do
4228 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004229 case $as_dir in #(((
4230 '') as_dir=./ ;;
4231 */) ;;
4232 *) as_dir=$as_dir/ ;;
4233 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004234 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004235 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004236 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01004237 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004238 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00004239 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004240done
Matthias Kloseb9621712010-04-24 17:59:49 +00004241 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004242IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00004243
4244fi
4245fi
4246CC=$ac_cv_prog_CC
4247if test -n "$CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004248 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4249printf "%s\n" "$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004250else
Pablo Galindoba421752021-05-03 20:33:17 +01004251 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4252printf "%s\n" "no" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00004253fi
4254
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004255
Martin v. Löwis11437992002-04-12 09:54:03 +00004256 test -n "$CC" && break
4257 done
4258fi
4259if test -z "$CC"; then
4260 ac_ct_CC=$CC
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004261 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00004262do
4263 # Extract the first word of "$ac_prog", so it can be a program name with args.
4264set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004265{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4266printf %s "checking for $ac_word... " >&6; }
4267if test ${ac_cv_prog_ac_ct_CC+y}
4268then :
4269 printf %s "(cached) " >&6
4270else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00004271 if test -n "$ac_ct_CC"; then
4272 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4273else
4274as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4275for as_dir in $PATH
4276do
4277 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01004278 case $as_dir in #(((
4279 '') as_dir=./ ;;
4280 */) ;;
4281 *) as_dir=$as_dir/ ;;
4282 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004283 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01004284 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004285 ac_cv_prog_ac_ct_CC="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01004286 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004287 break 2
4288 fi
4289done
Matthias Kloseb9621712010-04-24 17:59:49 +00004290 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004291IFS=$as_save_IFS
Jack Jansendd19cf82001-12-06 22:36:17 +00004292
Martin v. Löwis11437992002-04-12 09:54:03 +00004293fi
4294fi
4295ac_ct_CC=$ac_cv_prog_ac_ct_CC
4296if test -n "$ac_ct_CC"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4298printf "%s\n" "$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004299else
Pablo Galindoba421752021-05-03 20:33:17 +01004300 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4301printf "%s\n" "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004302fi
Michael W. Hudson54241132001-12-07 15:38:26 +00004303
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004304
Martin v. Löwis11437992002-04-12 09:54:03 +00004305 test -n "$ac_ct_CC" && break
4306done
Michael W. Hudson54241132001-12-07 15:38:26 +00004307
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004308 if test "x$ac_ct_CC" = x; then
4309 CC=""
4310 else
4311 case $cross_compiling:$ac_tool_warned in
4312yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01004313{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4314printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004315ac_tool_warned=yes ;;
4316esac
4317 CC=$ac_ct_CC
4318 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004319fi
4320
4321fi
Pablo Galindoba421752021-05-03 20:33:17 +01004322if test -z "$CC"; then
4323 if test -n "$ac_tool_prefix"; then
4324 # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
4325set dummy ${ac_tool_prefix}clang; ac_word=$2
4326{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4327printf %s "checking for $ac_word... " >&6; }
4328if test ${ac_cv_prog_CC+y}
4329then :
4330 printf %s "(cached) " >&6
4331else $as_nop
4332 if test -n "$CC"; then
4333 ac_cv_prog_CC="$CC" # Let the user override the test.
4334else
4335as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4336for as_dir in $PATH
4337do
4338 IFS=$as_save_IFS
4339 case $as_dir in #(((
4340 '') as_dir=./ ;;
4341 */) ;;
4342 *) as_dir=$as_dir/ ;;
4343 esac
4344 for ac_exec_ext in '' $ac_executable_extensions; do
4345 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4346 ac_cv_prog_CC="${ac_tool_prefix}clang"
4347 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4348 break 2
4349 fi
4350done
4351 done
4352IFS=$as_save_IFS
4353
4354fi
4355fi
4356CC=$ac_cv_prog_CC
4357if test -n "$CC"; then
4358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4359printf "%s\n" "$CC" >&6; }
4360else
4361 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4362printf "%s\n" "no" >&6; }
4363fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004364
4365
Pablo Galindoba421752021-05-03 20:33:17 +01004366fi
4367if test -z "$ac_cv_prog_CC"; then
4368 ac_ct_CC=$CC
4369 # Extract the first word of "clang", so it can be a program name with args.
4370set dummy clang; ac_word=$2
4371{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4372printf %s "checking for $ac_word... " >&6; }
4373if test ${ac_cv_prog_ac_ct_CC+y}
4374then :
4375 printf %s "(cached) " >&6
4376else $as_nop
4377 if test -n "$ac_ct_CC"; then
4378 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4379else
4380as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4381for as_dir in $PATH
4382do
4383 IFS=$as_save_IFS
4384 case $as_dir in #(((
4385 '') as_dir=./ ;;
4386 */) ;;
4387 *) as_dir=$as_dir/ ;;
4388 esac
4389 for ac_exec_ext in '' $ac_executable_extensions; do
4390 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4391 ac_cv_prog_ac_ct_CC="clang"
4392 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4393 break 2
4394 fi
4395done
4396 done
4397IFS=$as_save_IFS
4398
4399fi
4400fi
4401ac_ct_CC=$ac_cv_prog_ac_ct_CC
4402if test -n "$ac_ct_CC"; then
4403 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4404printf "%s\n" "$ac_ct_CC" >&6; }
4405else
4406 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4407printf "%s\n" "no" >&6; }
4408fi
4409
4410 if test "x$ac_ct_CC" = x; then
4411 CC=""
4412 else
4413 case $cross_compiling:$ac_tool_warned in
4414yes:)
4415{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4416printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4417ac_tool_warned=yes ;;
4418esac
4419 CC=$ac_ct_CC
4420 fi
4421else
4422 CC="$ac_cv_prog_CC"
4423fi
4424
4425fi
4426
4427
4428test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4429printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02004430as_fn_error $? "no acceptable C compiler found in \$PATH
Victor Stinnere0be4232011-10-25 13:06:09 +02004431See \`config.log' for more details" "$LINENO" 5; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004432
4433# Provide some information about the compiler.
Pablo Galindoba421752021-05-03 20:33:17 +01004434printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004435set X $ac_compile
4436ac_compiler=$2
Pablo Galindoba421752021-05-03 20:33:17 +01004437for ac_option in --version -v -V -qversion -version; do
Matthias Kloseb9621712010-04-24 17:59:49 +00004438 { { ac_try="$ac_compiler $ac_option >&5"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004439case "(($ac_try" in
4440 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4441 *) ac_try_echo=$ac_try;;
4442esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004443eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004444printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004445 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00004446 ac_status=$?
Matthias Kloseb9621712010-04-24 17:59:49 +00004447 if test -s conftest.err; then
4448 sed '10a\
4449... rest of stderr output deleted ...
4450 10q' conftest.err >conftest.er1
4451 cat conftest.er1 >&5
4452 fi
4453 rm -f conftest.er1 conftest.err
Pablo Galindoba421752021-05-03 20:33:17 +01004454 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004455 test $ac_status = 0; }
4456done
Martin v. Löwis11437992002-04-12 09:54:03 +00004457
Matthias Kloseb9621712010-04-24 17:59:49 +00004458cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00004459/* end confdefs.h. */
Jack Jansendd19cf82001-12-06 22:36:17 +00004460
Martin v. Löwis11437992002-04-12 09:54:03 +00004461int
Pablo Galindoba421752021-05-03 20:33:17 +01004462main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00004463{
4464
4465 ;
4466 return 0;
4467}
4468_ACEOF
4469ac_clean_files_save=$ac_clean_files
Matthias Kloseb9621712010-04-24 17:59:49 +00004470ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
Martin v. Löwis11437992002-04-12 09:54:03 +00004471# Try to create an executable without -o first, disregard a.out.
4472# It will help us diagnose broken compilers, and finding out an intuition
4473# of exeext.
Pablo Galindoba421752021-05-03 20:33:17 +01004474{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4475printf %s "checking whether the C compiler works... " >&6; }
4476ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
Matthias Kloseb9621712010-04-24 17:59:49 +00004477
4478# The possible output files:
4479ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4480
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004481ac_rmfiles=
4482for ac_file in $ac_files
4483do
4484 case $ac_file in
Matthias Kloseb9621712010-04-24 17:59:49 +00004485 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004486 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4487 esac
4488done
4489rm -f $ac_rmfiles
4490
Matthias Kloseb9621712010-04-24 17:59:49 +00004491if { { ac_try="$ac_link_default"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004492case "(($ac_try" in
4493 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4494 *) ac_try_echo=$ac_try;;
4495esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004496eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004497printf "%s\n" "$ac_try_echo"; } >&5
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004498 (eval "$ac_link_default") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004499 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01004500 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4501 test $ac_status = 0; }
4502then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004503 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4504# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4505# in a Makefile. We should not override ac_cv_exeext if it was cached,
4506# so that the user can short-circuit this test for compilers unknown to
4507# Autoconf.
4508for ac_file in $ac_files ''
Skip Montanaro6dead952003-09-25 14:50:04 +00004509do
4510 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00004511 case $ac_file in
Matthias Kloseb9621712010-04-24 17:59:49 +00004512 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004513 ;;
4514 [ab].out )
4515 # We found the default executable, but exeext='' is most
4516 # certainly right.
4517 break;;
4518 *.* )
Pablo Galindoba421752021-05-03 20:33:17 +01004519 if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004520 then :; else
4521 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4522 fi
4523 # We set ac_cv_exeext here because the later test for it is not
4524 # safe: cross compilers may not add the suffix if given an `-o'
4525 # argument, so we may need to know it at that point already.
4526 # Even if this section looks crufty: it has the advantage of
4527 # actually working.
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004528 break;;
4529 * )
4530 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00004531 esac
4532done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004533test "$ac_cv_exeext" = no && ac_cv_exeext=
4534
Pablo Galindoba421752021-05-03 20:33:17 +01004535else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004536 ac_file=''
4537fi
Pablo Galindoba421752021-05-03 20:33:17 +01004538if test -z "$ac_file"
4539then :
4540 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4541printf "%s\n" "no" >&6; }
4542printf "%s\n" "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00004543sed 's/^/| /' conftest.$ac_ext >&5
4544
Pablo Galindoba421752021-05-03 20:33:17 +01004545{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4546printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02004547as_fn_error 77 "C compiler cannot create executables
Victor Stinnere0be4232011-10-25 13:06:09 +02004548See \`config.log' for more details" "$LINENO" 5; }
Pablo Galindoba421752021-05-03 20:33:17 +01004549else $as_nop
4550 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4551printf "%s\n" "yes" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004552fi
Pablo Galindoba421752021-05-03 20:33:17 +01004553{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4554printf %s "checking for C compiler default output file name... " >&6; }
4555{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4556printf "%s\n" "$ac_file" >&6; }
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004557ac_exeext=$ac_cv_exeext
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004558
Matthias Kloseb9621712010-04-24 17:59:49 +00004559rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004560ac_clean_files=$ac_clean_files_save
Pablo Galindoba421752021-05-03 20:33:17 +01004561{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4562printf %s "checking for suffix of executables... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +00004563if { { ac_try="$ac_link"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004564case "(($ac_try" in
4565 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4566 *) ac_try_echo=$ac_try;;
4567esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004568eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004569printf "%s\n" "$ac_try_echo"; } >&5
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004570 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004571 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01004572 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4573 test $ac_status = 0; }
4574then :
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004575 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4576# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4577# work properly (i.e., refer to `conftest.exe'), while it won't with
4578# `rm'.
4579for ac_file in conftest.exe conftest conftest.*; do
4580 test -f "$ac_file" || continue
4581 case $ac_file in
Matthias Kloseb9621712010-04-24 17:59:49 +00004582 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004583 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4584 break;;
4585 * ) break;;
4586 esac
4587done
Pablo Galindoba421752021-05-03 20:33:17 +01004588else $as_nop
4589 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4590printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02004591as_fn_error $? "cannot compute suffix of executables: cannot compile and link
Victor Stinnere0be4232011-10-25 13:06:09 +02004592See \`config.log' for more details" "$LINENO" 5; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004593fi
Matthias Kloseb9621712010-04-24 17:59:49 +00004594rm -f conftest conftest$ac_cv_exeext
Pablo Galindoba421752021-05-03 20:33:17 +01004595{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4596printf "%s\n" "$ac_cv_exeext" >&6; }
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004597
4598rm -f conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00004599EXEEXT=$ac_cv_exeext
4600ac_exeext=$EXEEXT
Matthias Kloseb9621712010-04-24 17:59:49 +00004601cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4602/* end confdefs.h. */
4603#include <stdio.h>
4604int
Pablo Galindoba421752021-05-03 20:33:17 +01004605main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00004606{
4607FILE *f = fopen ("conftest.out", "w");
4608 return ferror (f) || fclose (f) != 0;
4609
4610 ;
4611 return 0;
4612}
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004613_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +00004614ac_clean_files="$ac_clean_files conftest.out"
4615# Check that the compiler produces executables we can run. If not, either
4616# the compiler is broken, or we cross compile.
Pablo Galindoba421752021-05-03 20:33:17 +01004617{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4618printf %s "checking whether we are cross compiling... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +00004619if test "$cross_compiling" != yes; then
4620 { { ac_try="$ac_link"
4621case "(($ac_try" in
4622 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4623 *) ac_try_echo=$ac_try;;
4624esac
4625eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004626printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004627 (eval "$ac_link") 2>&5
4628 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01004629 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004630 test $ac_status = 0; }
4631 if { ac_try='./conftest$ac_cv_exeext'
4632 { { case "(($ac_try" in
4633 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4634 *) ac_try_echo=$ac_try;;
4635esac
4636eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004637printf "%s\n" "$ac_try_echo"; } >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004638 (eval "$ac_try") 2>&5
4639 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01004640 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
Matthias Kloseb9621712010-04-24 17:59:49 +00004641 test $ac_status = 0; }; }; then
4642 cross_compiling=no
4643 else
4644 if test "$cross_compiling" = maybe; then
4645 cross_compiling=yes
4646 else
Pablo Galindoba421752021-05-03 20:33:17 +01004647 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4648printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4649as_fn_error 77 "cannot run C compiled programs.
Matthias Kloseb9621712010-04-24 17:59:49 +00004650If you meant to cross compile, use \`--host'.
Victor Stinnere0be4232011-10-25 13:06:09 +02004651See \`config.log' for more details" "$LINENO" 5; }
Matthias Kloseb9621712010-04-24 17:59:49 +00004652 fi
4653 fi
4654fi
Pablo Galindoba421752021-05-03 20:33:17 +01004655{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4656printf "%s\n" "$cross_compiling" >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +00004657
4658rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4659ac_clean_files=$ac_clean_files_save
Pablo Galindoba421752021-05-03 20:33:17 +01004660{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4661printf %s "checking for suffix of object files... " >&6; }
4662if test ${ac_cv_objext+y}
4663then :
4664 printf %s "(cached) " >&6
4665else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00004666 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004667/* end confdefs.h. */
4668
4669int
Pablo Galindoba421752021-05-03 20:33:17 +01004670main (void)
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004671{
4672
4673 ;
4674 return 0;
4675}
4676_ACEOF
4677rm -f conftest.o conftest.obj
Matthias Kloseb9621712010-04-24 17:59:49 +00004678if { { ac_try="$ac_compile"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004679case "(($ac_try" in
4680 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4681 *) ac_try_echo=$ac_try;;
4682esac
Matthias Kloseb9621712010-04-24 17:59:49 +00004683eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
Pablo Galindoba421752021-05-03 20:33:17 +01004684printf "%s\n" "$ac_try_echo"; } >&5
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004685 (eval "$ac_compile") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004686 ac_status=$?
Pablo Galindoba421752021-05-03 20:33:17 +01004687 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4688 test $ac_status = 0; }
4689then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004690 for ac_file in conftest.o conftest.obj conftest.*; do
4691 test -f "$ac_file" || continue;
Martin v. Löwis11437992002-04-12 09:54:03 +00004692 case $ac_file in
Matthias Kloseb9621712010-04-24 17:59:49 +00004693 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00004694 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4695 break;;
4696 esac
4697done
Pablo Galindoba421752021-05-03 20:33:17 +01004698else $as_nop
4699 printf "%s\n" "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00004700sed 's/^/| /' conftest.$ac_ext >&5
4701
Pablo Galindoba421752021-05-03 20:33:17 +01004702{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4703printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02004704as_fn_error $? "cannot compute suffix of object files: cannot compile
Victor Stinnere0be4232011-10-25 13:06:09 +02004705See \`config.log' for more details" "$LINENO" 5; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004706fi
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +00004707rm -f conftest.$ac_cv_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00004708fi
Pablo Galindoba421752021-05-03 20:33:17 +01004709{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4710printf "%s\n" "$ac_cv_objext" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004711OBJEXT=$ac_cv_objext
4712ac_objext=$OBJEXT
Pablo Galindoba421752021-05-03 20:33:17 +01004713{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
4714printf %s "checking whether the compiler supports GNU C... " >&6; }
4715if test ${ac_cv_c_compiler_gnu+y}
4716then :
4717 printf %s "(cached) " >&6
4718else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00004719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00004720/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004721
Martin v. Löwis11437992002-04-12 09:54:03 +00004722int
Pablo Galindoba421752021-05-03 20:33:17 +01004723main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00004724{
4725#ifndef __GNUC__
4726 choke me
4727#endif
4728
4729 ;
4730 return 0;
4731}
4732_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01004733if ac_fn_c_try_compile "$LINENO"
4734then :
Martin v. Löwis11437992002-04-12 09:54:03 +00004735 ac_compiler_gnu=yes
Pablo Galindoba421752021-05-03 20:33:17 +01004736else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00004737 ac_compiler_gnu=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004738fi
Pablo Galindoba421752021-05-03 20:33:17 +01004739rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00004740ac_cv_c_compiler_gnu=$ac_compiler_gnu
4741
4742fi
Pablo Galindoba421752021-05-03 20:33:17 +01004743{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4744printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
4745ac_compiler_gnu=$ac_cv_c_compiler_gnu
4746
Matthias Kloseb9621712010-04-24 17:59:49 +00004747if test $ac_compiler_gnu = yes; then
4748 GCC=yes
4749else
4750 GCC=
4751fi
Pablo Galindoba421752021-05-03 20:33:17 +01004752ac_test_CFLAGS=${CFLAGS+y}
Martin v. Löwis11437992002-04-12 09:54:03 +00004753ac_save_CFLAGS=$CFLAGS
Pablo Galindoba421752021-05-03 20:33:17 +01004754{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4755printf %s "checking whether $CC accepts -g... " >&6; }
4756if test ${ac_cv_prog_cc_g+y}
4757then :
4758 printf %s "(cached) " >&6
4759else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004760 ac_save_c_werror_flag=$ac_c_werror_flag
4761 ac_c_werror_flag=yes
4762 ac_cv_prog_cc_g=no
4763 CFLAGS="-g"
Matthias Kloseb9621712010-04-24 17:59:49 +00004764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00004765/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004766
Martin v. Löwis11437992002-04-12 09:54:03 +00004767int
Pablo Galindoba421752021-05-03 20:33:17 +01004768main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00004769{
4770
4771 ;
4772 return 0;
4773}
4774_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01004775if ac_fn_c_try_compile "$LINENO"
4776then :
Guido van Rossumf78abae1997-01-21 22:02:36 +00004777 ac_cv_prog_cc_g=yes
Pablo Galindoba421752021-05-03 20:33:17 +01004778else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00004779 CFLAGS=""
4780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004781/* end confdefs.h. */
4782
4783int
Pablo Galindoba421752021-05-03 20:33:17 +01004784main (void)
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004785{
4786
4787 ;
4788 return 0;
4789}
4790_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01004791if ac_fn_c_try_compile "$LINENO"
4792then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004793
Pablo Galindoba421752021-05-03 20:33:17 +01004794else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00004795 ac_c_werror_flag=$ac_save_c_werror_flag
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004796 CFLAGS="-g"
Matthias Kloseb9621712010-04-24 17:59:49 +00004797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004798/* end confdefs.h. */
4799
4800int
Pablo Galindoba421752021-05-03 20:33:17 +01004801main (void)
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004802{
4803
4804 ;
4805 return 0;
4806}
4807_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01004808if ac_fn_c_try_compile "$LINENO"
4809then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004810 ac_cv_prog_cc_g=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004811fi
Pablo Galindoba421752021-05-03 20:33:17 +01004812rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004813fi
Pablo Galindoba421752021-05-03 20:33:17 +01004814rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004815fi
Pablo Galindoba421752021-05-03 20:33:17 +01004816rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004817 ac_c_werror_flag=$ac_save_c_werror_flag
4818fi
Pablo Galindoba421752021-05-03 20:33:17 +01004819{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4820printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
4821if test $ac_test_CFLAGS; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004822 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00004823elif test $ac_cv_prog_cc_g = yes; then
4824 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00004825 CFLAGS="-g -O2"
4826 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00004827 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004828 fi
4829else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00004830 if test "$GCC" = yes; then
4831 CFLAGS="-O2"
4832 else
4833 CFLAGS=
4834 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004835fi
Pablo Galindoba421752021-05-03 20:33:17 +01004836ac_prog_cc_stdc=no
4837if test x$ac_prog_cc_stdc = xno
4838then :
4839 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
4840printf %s "checking for $CC option to enable C11 features... " >&6; }
4841if test ${ac_cv_prog_cc_c11+y}
4842then :
4843 printf %s "(cached) " >&6
4844else $as_nop
4845 ac_cv_prog_cc_c11=no
4846ac_save_CC=$CC
4847cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4848/* end confdefs.h. */
4849$ac_c_conftest_c11_program
4850_ACEOF
4851for ac_arg in '' -std=gnu11
4852do
4853 CC="$ac_save_CC $ac_arg"
4854 if ac_fn_c_try_compile "$LINENO"
4855then :
4856 ac_cv_prog_cc_c11=$ac_arg
4857fi
4858rm -f core conftest.err conftest.$ac_objext conftest.beam
4859 test "x$ac_cv_prog_cc_c11" != "xno" && break
4860done
4861rm -f conftest.$ac_ext
4862CC=$ac_save_CC
4863fi
4864
4865if test "x$ac_cv_prog_cc_c11" = xno
4866then :
4867 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4868printf "%s\n" "unsupported" >&6; }
4869else $as_nop
4870 if test "x$ac_cv_prog_cc_c11" = x
4871then :
4872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4873printf "%s\n" "none needed" >&6; }
4874else $as_nop
4875 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
4876printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
4877 CC="$CC $ac_cv_prog_cc_c11"
4878fi
4879 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
4880 ac_prog_cc_stdc=c11
4881fi
4882fi
4883if test x$ac_prog_cc_stdc = xno
4884then :
4885 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
4886printf %s "checking for $CC option to enable C99 features... " >&6; }
4887if test ${ac_cv_prog_cc_c99+y}
4888then :
4889 printf %s "(cached) " >&6
4890else $as_nop
4891 ac_cv_prog_cc_c99=no
4892ac_save_CC=$CC
4893cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4894/* end confdefs.h. */
4895$ac_c_conftest_c99_program
4896_ACEOF
4897for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
4898do
4899 CC="$ac_save_CC $ac_arg"
4900 if ac_fn_c_try_compile "$LINENO"
4901then :
4902 ac_cv_prog_cc_c99=$ac_arg
4903fi
4904rm -f core conftest.err conftest.$ac_objext conftest.beam
4905 test "x$ac_cv_prog_cc_c99" != "xno" && break
4906done
4907rm -f conftest.$ac_ext
4908CC=$ac_save_CC
4909fi
4910
4911if test "x$ac_cv_prog_cc_c99" = xno
4912then :
4913 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4914printf "%s\n" "unsupported" >&6; }
4915else $as_nop
4916 if test "x$ac_cv_prog_cc_c99" = x
4917then :
4918 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4919printf "%s\n" "none needed" >&6; }
4920else $as_nop
4921 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4922printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
4923 CC="$CC $ac_cv_prog_cc_c99"
4924fi
4925 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
4926 ac_prog_cc_stdc=c99
4927fi
4928fi
4929if test x$ac_prog_cc_stdc = xno
4930then :
4931 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
4932printf %s "checking for $CC option to enable C89 features... " >&6; }
4933if test ${ac_cv_prog_cc_c89+y}
4934then :
4935 printf %s "(cached) " >&6
4936else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004937 ac_cv_prog_cc_c89=no
Skip Montanaro6dead952003-09-25 14:50:04 +00004938ac_save_CC=$CC
Matthias Kloseb9621712010-04-24 17:59:49 +00004939cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00004940/* end confdefs.h. */
Pablo Galindoba421752021-05-03 20:33:17 +01004941$ac_c_conftest_c89_program
Skip Montanaro6dead952003-09-25 14:50:04 +00004942_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01004943for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
Skip Montanaro6dead952003-09-25 14:50:04 +00004944do
4945 CC="$ac_save_CC $ac_arg"
Pablo Galindoba421752021-05-03 20:33:17 +01004946 if ac_fn_c_try_compile "$LINENO"
4947then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004948 ac_cv_prog_cc_c89=$ac_arg
Skip Montanaro6dead952003-09-25 14:50:04 +00004949fi
Pablo Galindoba421752021-05-03 20:33:17 +01004950rm -f core conftest.err conftest.$ac_objext conftest.beam
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004951 test "x$ac_cv_prog_cc_c89" != "xno" && break
Skip Montanaro6dead952003-09-25 14:50:04 +00004952done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00004953rm -f conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00004954CC=$ac_save_CC
Pablo Galindo53e55292021-04-05 17:38:40 +01004955fi
Christian Heimes39258d32021-04-17 11:36:35 +02004956
Pablo Galindoba421752021-05-03 20:33:17 +01004957if test "x$ac_cv_prog_cc_c89" = xno
4958then :
4959 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4960printf "%s\n" "unsupported" >&6; }
4961else $as_nop
4962 if test "x$ac_cv_prog_cc_c89" = x
4963then :
4964 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4965printf "%s\n" "none needed" >&6; }
4966else $as_nop
4967 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4968printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
4969 CC="$CC $ac_cv_prog_cc_c89"
4970fi
4971 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
4972 ac_prog_cc_stdc=c89
4973fi
Matthias Kloseb9621712010-04-24 17:59:49 +00004974fi
Skip Montanaro6dead952003-09-25 14:50:04 +00004975
Martin v. Löwis11437992002-04-12 09:54:03 +00004976ac_ext=c
4977ac_cpp='$CPP $CPPFLAGS'
4978ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4979ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4980ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004981
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02004982ac_ext=c
4983ac_cpp='$CPP $CPPFLAGS'
4984ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4985ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4986ac_compiler_gnu=$ac_cv_c_compiler_gnu
Pablo Galindoba421752021-05-03 20:33:17 +01004987{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4988printf %s "checking how to run the C preprocessor... " >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02004989# On Suns, sometimes $CPP names a directory.
4990if test -n "$CPP" && test -d "$CPP"; then
4991 CPP=
4992fi
4993if test -z "$CPP"; then
Pablo Galindoba421752021-05-03 20:33:17 +01004994 if test ${ac_cv_prog_CPP+y}
4995then :
4996 printf %s "(cached) " >&6
4997else $as_nop
4998 # Double quotes because $CC needs to be expanded
4999 for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005000 do
5001 ac_preproc_ok=false
5002for ac_c_preproc_warn_flag in '' yes
5003do
5004 # Use a header file that comes with gcc, so configuring glibc
5005 # with a fresh cross-compiler works.
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005006 # On the NeXT, cc -E runs the code through the compiler's parser,
5007 # not just through cpp. "Syntax error" is here to catch this case.
5008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5009/* end confdefs.h. */
Pablo Galindoba421752021-05-03 20:33:17 +01005010#include <limits.h>
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005011 Syntax error
5012_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01005013if ac_fn_c_try_cpp "$LINENO"
5014then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005015
Pablo Galindoba421752021-05-03 20:33:17 +01005016else $as_nop
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005017 # Broken: fails on valid input.
5018continue
5019fi
5020rm -f conftest.err conftest.i conftest.$ac_ext
5021
5022 # OK, works on sane cases. Now check whether nonexistent headers
5023 # can be detected and how.
5024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5025/* end confdefs.h. */
5026#include <ac_nonexistent.h>
5027_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01005028if ac_fn_c_try_cpp "$LINENO"
5029then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005030 # Broken: success on invalid input.
5031continue
Pablo Galindoba421752021-05-03 20:33:17 +01005032else $as_nop
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005033 # Passes both tests.
5034ac_preproc_ok=:
5035break
5036fi
5037rm -f conftest.err conftest.i conftest.$ac_ext
5038
5039done
5040# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5041rm -f conftest.i conftest.err conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +01005042if $ac_preproc_ok
5043then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005044 break
5045fi
5046
5047 done
5048 ac_cv_prog_CPP=$CPP
5049
5050fi
5051 CPP=$ac_cv_prog_CPP
5052else
5053 ac_cv_prog_CPP=$CPP
5054fi
Pablo Galindoba421752021-05-03 20:33:17 +01005055{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5056printf "%s\n" "$CPP" >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005057ac_preproc_ok=false
5058for ac_c_preproc_warn_flag in '' yes
5059do
5060 # Use a header file that comes with gcc, so configuring glibc
5061 # with a fresh cross-compiler works.
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005062 # On the NeXT, cc -E runs the code through the compiler's parser,
5063 # not just through cpp. "Syntax error" is here to catch this case.
5064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5065/* end confdefs.h. */
Pablo Galindoba421752021-05-03 20:33:17 +01005066#include <limits.h>
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005067 Syntax error
5068_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01005069if ac_fn_c_try_cpp "$LINENO"
5070then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005071
Pablo Galindoba421752021-05-03 20:33:17 +01005072else $as_nop
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005073 # Broken: fails on valid input.
5074continue
5075fi
5076rm -f conftest.err conftest.i conftest.$ac_ext
5077
5078 # OK, works on sane cases. Now check whether nonexistent headers
5079 # can be detected and how.
5080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5081/* end confdefs.h. */
5082#include <ac_nonexistent.h>
5083_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01005084if ac_fn_c_try_cpp "$LINENO"
5085then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005086 # Broken: success on invalid input.
5087continue
Pablo Galindoba421752021-05-03 20:33:17 +01005088else $as_nop
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005089 # Passes both tests.
5090ac_preproc_ok=:
5091break
5092fi
5093rm -f conftest.err conftest.i conftest.$ac_ext
5094
5095done
5096# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5097rm -f conftest.i conftest.err conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +01005098if $ac_preproc_ok
5099then :
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005100
Pablo Galindoba421752021-05-03 20:33:17 +01005101else $as_nop
5102 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5103printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005104as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5105See \`config.log' for more details" "$LINENO" 5; }
5106fi
5107
5108ac_ext=c
5109ac_cpp='$CPP $CPPFLAGS'
5110ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5111ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5112ac_compiler_gnu=$ac_cv_c_compiler_gnu
5113
Pablo Galindoba421752021-05-03 20:33:17 +01005114{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5115printf %s "checking for grep that handles long lines and -e... " >&6; }
5116if test ${ac_cv_path_GREP+y}
5117then :
5118 printf %s "(cached) " >&6
5119else $as_nop
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005120 if test -z "$GREP"; then
5121 ac_path_GREP_found=false
5122 # Loop through the user's path and test for each of PROGNAME-LIST
5123 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5124for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5125do
5126 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005127 case $as_dir in #(((
5128 '') as_dir=./ ;;
5129 */) ;;
5130 *) as_dir=$as_dir/ ;;
5131 esac
5132 for ac_prog in grep ggrep
5133 do
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005134 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005135 ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005136 as_fn_executable_p "$ac_path_GREP" || continue
5137# Check for GNU ac_path_GREP and select it if it is found.
5138 # Check for GNU $ac_path_GREP
5139case `"$ac_path_GREP" --version 2>&1` in
5140*GNU*)
5141 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5142*)
5143 ac_count=0
Pablo Galindoba421752021-05-03 20:33:17 +01005144 printf %s 0123456789 >"conftest.in"
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005145 while :
5146 do
5147 cat "conftest.in" "conftest.in" >"conftest.tmp"
5148 mv "conftest.tmp" "conftest.in"
5149 cp "conftest.in" "conftest.nl"
Pablo Galindoba421752021-05-03 20:33:17 +01005150 printf "%s\n" 'GREP' >> "conftest.nl"
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005151 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5152 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5153 as_fn_arith $ac_count + 1 && ac_count=$as_val
5154 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5155 # Best one so far, save it but keep looking for a better one
5156 ac_cv_path_GREP="$ac_path_GREP"
5157 ac_path_GREP_max=$ac_count
5158 fi
5159 # 10*(2^10) chars as input seems more than enough
5160 test $ac_count -gt 10 && break
5161 done
5162 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5163esac
5164
5165 $ac_path_GREP_found && break 3
5166 done
5167 done
5168 done
5169IFS=$as_save_IFS
5170 if test -z "$ac_cv_path_GREP"; then
5171 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5172 fi
5173else
5174 ac_cv_path_GREP=$GREP
5175fi
5176
5177fi
Pablo Galindoba421752021-05-03 20:33:17 +01005178{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5179printf "%s\n" "$ac_cv_path_GREP" >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005180 GREP="$ac_cv_path_GREP"
5181
5182
Pablo Galindoba421752021-05-03 20:33:17 +01005183{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
5184printf %s "checking for a sed that does not truncate output... " >&6; }
5185if test ${ac_cv_path_SED+y}
5186then :
5187 printf %s "(cached) " >&6
5188else $as_nop
Łukasz Langaa785c872016-09-09 17:37:37 -07005189 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
5190 for ac_i in 1 2 3 4 5 6 7; do
5191 ac_script="$ac_script$as_nl$ac_script"
5192 done
5193 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
5194 { ac_script=; unset ac_script;}
5195 if test -z "$SED"; then
5196 ac_path_SED_found=false
5197 # Loop through the user's path and test for each of PROGNAME-LIST
5198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5199for as_dir in $PATH
5200do
5201 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005202 case $as_dir in #(((
5203 '') as_dir=./ ;;
5204 */) ;;
5205 *) as_dir=$as_dir/ ;;
5206 esac
5207 for ac_prog in sed gsed
5208 do
Łukasz Langaa785c872016-09-09 17:37:37 -07005209 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005210 ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
Łukasz Langaa785c872016-09-09 17:37:37 -07005211 as_fn_executable_p "$ac_path_SED" || continue
5212# Check for GNU ac_path_SED and select it if it is found.
5213 # Check for GNU $ac_path_SED
5214case `"$ac_path_SED" --version 2>&1` in
5215*GNU*)
5216 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
5217*)
5218 ac_count=0
Pablo Galindoba421752021-05-03 20:33:17 +01005219 printf %s 0123456789 >"conftest.in"
Łukasz Langaa785c872016-09-09 17:37:37 -07005220 while :
5221 do
5222 cat "conftest.in" "conftest.in" >"conftest.tmp"
5223 mv "conftest.tmp" "conftest.in"
5224 cp "conftest.in" "conftest.nl"
Pablo Galindoba421752021-05-03 20:33:17 +01005225 printf "%s\n" '' >> "conftest.nl"
Łukasz Langaa785c872016-09-09 17:37:37 -07005226 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
5227 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5228 as_fn_arith $ac_count + 1 && ac_count=$as_val
5229 if test $ac_count -gt ${ac_path_SED_max-0}; then
5230 # Best one so far, save it but keep looking for a better one
5231 ac_cv_path_SED="$ac_path_SED"
5232 ac_path_SED_max=$ac_count
5233 fi
5234 # 10*(2^10) chars as input seems more than enough
5235 test $ac_count -gt 10 && break
5236 done
5237 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5238esac
5239
5240 $ac_path_SED_found && break 3
5241 done
5242 done
5243 done
5244IFS=$as_save_IFS
5245 if test -z "$ac_cv_path_SED"; then
5246 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
5247 fi
5248else
5249 ac_cv_path_SED=$SED
5250fi
5251
5252fi
Pablo Galindoba421752021-05-03 20:33:17 +01005253{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
5254printf "%s\n" "$ac_cv_path_SED" >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -07005255 SED="$ac_cv_path_SED"
5256 rm -f conftest.sed
5257
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00005258
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005259
5260
Pablo Galindoba421752021-05-03 20:33:17 +01005261{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5
5262printf %s "checking for --with-cxx-main=<compiler>... " >&6; }
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005263
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005264# Check whether --with-cxx_main was given.
Pablo Galindoba421752021-05-03 20:33:17 +01005265if test ${with_cxx_main+y}
5266then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005267 withval=$with_cxx_main;
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005268
5269 case $withval in
5270 no) with_cxx_main=no
5271 MAINCC='$(CC)';;
5272 yes) with_cxx_main=yes
5273 MAINCC='$(CXX)';;
5274 *) with_cxx_main=yes
5275 MAINCC=$withval
5276 if test -z "$CXX"
5277 then
5278 CXX=$withval
5279 fi;;
5280 esac
Pablo Galindoba421752021-05-03 20:33:17 +01005281else $as_nop
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005282
5283 with_cxx_main=no
5284 MAINCC='$(CC)'
5285
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005286fi
5287
Pablo Galindoba421752021-05-03 20:33:17 +01005288{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5
5289printf "%s\n" "$with_cxx_main" >&6; }
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005290
5291preset_cxx="$CXX"
5292if test -z "$CXX"
5293then
5294 case "$CC" in
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005295 gcc) if test -n "$ac_tool_prefix"; then
5296 # Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args.
5297set dummy ${ac_tool_prefix}g++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005298{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5299printf %s "checking for $ac_word... " >&6; }
5300if test ${ac_cv_path_CXX+y}
5301then :
5302 printf %s "(cached) " >&6
5303else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005304 case $CXX in
5305 [\\/]* | ?:[\\/]*)
5306 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
5307 ;;
5308 *)
5309 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5310for as_dir in notfound
5311do
5312 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005313 case $as_dir in #(((
5314 '') as_dir=./ ;;
5315 */) ;;
5316 *) as_dir=$as_dir/ ;;
5317 esac
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005318 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005319 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5320 ac_cv_path_CXX="$as_dir$ac_word$ac_exec_ext"
5321 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005322 break 2
5323 fi
5324done
5325 done
5326IFS=$as_save_IFS
5327
5328 ;;
5329esac
5330fi
5331CXX=$ac_cv_path_CXX
5332if test -n "$CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005333 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5334printf "%s\n" "$CXX" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005335else
Pablo Galindoba421752021-05-03 20:33:17 +01005336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5337printf "%s\n" "no" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005338fi
5339
5340
5341fi
5342if test -z "$ac_cv_path_CXX"; then
5343 ac_pt_CXX=$CXX
5344 # Extract the first word of "g++", so it can be a program name with args.
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005345set dummy g++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005346{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5347printf %s "checking for $ac_word... " >&6; }
5348if test ${ac_cv_path_ac_pt_CXX+y}
5349then :
5350 printf %s "(cached) " >&6
5351else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005352 case $ac_pt_CXX in
5353 [\\/]* | ?:[\\/]*)
5354 ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
5355 ;;
5356 *)
5357 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5358for as_dir in notfound
5359do
5360 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005361 case $as_dir in #(((
5362 '') as_dir=./ ;;
5363 */) ;;
5364 *) as_dir=$as_dir/ ;;
5365 esac
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005366 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005367 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5368 ac_cv_path_ac_pt_CXX="$as_dir$ac_word$ac_exec_ext"
5369 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005370 break 2
5371 fi
5372done
5373 done
5374IFS=$as_save_IFS
5375
5376 ;;
5377esac
5378fi
5379ac_pt_CXX=$ac_cv_path_ac_pt_CXX
5380if test -n "$ac_pt_CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005381 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
5382printf "%s\n" "$ac_pt_CXX" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005383else
Pablo Galindoba421752021-05-03 20:33:17 +01005384 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5385printf "%s\n" "no" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005386fi
5387
5388 if test "x$ac_pt_CXX" = x; then
5389 CXX="g++"
5390 else
5391 case $cross_compiling:$ac_tool_warned in
5392yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01005393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5394printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005395ac_tool_warned=yes ;;
5396esac
5397 CXX=$ac_pt_CXX
5398 fi
5399else
5400 CXX="$ac_cv_path_CXX"
5401fi
5402 ;;
5403 cc) if test -n "$ac_tool_prefix"; then
5404 # Extract the first word of "${ac_tool_prefix}c++", so it can be a program name with args.
5405set dummy ${ac_tool_prefix}c++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005406{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5407printf %s "checking for $ac_word... " >&6; }
5408if test ${ac_cv_path_CXX+y}
5409then :
5410 printf %s "(cached) " >&6
5411else $as_nop
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005412 case $CXX in
5413 [\\/]* | ?:[\\/]*)
5414 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
5415 ;;
5416 *)
5417 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5418for as_dir in notfound
5419do
5420 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005421 case $as_dir in #(((
5422 '') as_dir=./ ;;
5423 */) ;;
5424 *) as_dir=$as_dir/ ;;
5425 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00005426 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005427 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5428 ac_cv_path_CXX="$as_dir$ac_word$ac_exec_ext"
5429 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005430 break 2
5431 fi
5432done
Matthias Kloseb9621712010-04-24 17:59:49 +00005433 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005434IFS=$as_save_IFS
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005435
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005436 ;;
5437esac
5438fi
5439CXX=$ac_cv_path_CXX
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00005440if test -n "$CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005441 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5442printf "%s\n" "$CXX" >&6; }
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00005443else
Pablo Galindoba421752021-05-03 20:33:17 +01005444 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5445printf "%s\n" "no" >&6; }
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00005446fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005447
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005448
5449fi
5450if test -z "$ac_cv_path_CXX"; then
5451 ac_pt_CXX=$CXX
5452 # Extract the first word of "c++", so it can be a program name with args.
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005453set dummy c++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005454{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5455printf %s "checking for $ac_word... " >&6; }
5456if test ${ac_cv_path_ac_pt_CXX+y}
5457then :
5458 printf %s "(cached) " >&6
5459else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005460 case $ac_pt_CXX in
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005461 [\\/]* | ?:[\\/]*)
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005462 ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005463 ;;
5464 *)
5465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5466for as_dir in notfound
5467do
5468 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005469 case $as_dir in #(((
5470 '') as_dir=./ ;;
5471 */) ;;
5472 *) as_dir=$as_dir/ ;;
5473 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00005474 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005475 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5476 ac_cv_path_ac_pt_CXX="$as_dir$ac_word$ac_exec_ext"
5477 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005478 break 2
5479 fi
5480done
Matthias Kloseb9621712010-04-24 17:59:49 +00005481 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005482IFS=$as_save_IFS
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005483
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005484 ;;
5485esac
5486fi
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005487ac_pt_CXX=$ac_cv_path_ac_pt_CXX
5488if test -n "$ac_pt_CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005489 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
5490printf "%s\n" "$ac_pt_CXX" >&6; }
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00005491else
Pablo Galindoba421752021-05-03 20:33:17 +01005492 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5493printf "%s\n" "no" >&6; }
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00005494fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005495
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005496 if test "x$ac_pt_CXX" = x; then
5497 CXX="c++"
5498 else
5499 case $cross_compiling:$ac_tool_warned in
5500yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01005501{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5502printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005503ac_tool_warned=yes ;;
5504esac
5505 CXX=$ac_pt_CXX
5506 fi
5507else
5508 CXX="$ac_cv_path_CXX"
5509fi
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005510 ;;
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005511 clang|*/clang) if test -n "$ac_tool_prefix"; then
5512 # Extract the first word of "${ac_tool_prefix}clang++", so it can be a program name with args.
5513set dummy ${ac_tool_prefix}clang++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005514{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5515printf %s "checking for $ac_word... " >&6; }
5516if test ${ac_cv_path_CXX+y}
5517then :
5518 printf %s "(cached) " >&6
5519else $as_nop
Ned Deilycbfb9a52012-06-23 16:02:19 -07005520 case $CXX in
5521 [\\/]* | ?:[\\/]*)
5522 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
5523 ;;
5524 *)
5525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5526for as_dir in notfound
5527do
5528 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005529 case $as_dir in #(((
5530 '') as_dir=./ ;;
5531 */) ;;
5532 *) as_dir=$as_dir/ ;;
5533 esac
Ned Deilycbfb9a52012-06-23 16:02:19 -07005534 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005535 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5536 ac_cv_path_CXX="$as_dir$ac_word$ac_exec_ext"
5537 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Ned Deilycbfb9a52012-06-23 16:02:19 -07005538 break 2
5539 fi
5540done
5541 done
5542IFS=$as_save_IFS
5543
Ned Deilycbfb9a52012-06-23 16:02:19 -07005544 ;;
5545esac
5546fi
5547CXX=$ac_cv_path_CXX
5548if test -n "$CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005549 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5550printf "%s\n" "$CXX" >&6; }
Ned Deilycbfb9a52012-06-23 16:02:19 -07005551else
Pablo Galindoba421752021-05-03 20:33:17 +01005552 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5553printf "%s\n" "no" >&6; }
Ned Deilycbfb9a52012-06-23 16:02:19 -07005554fi
5555
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005556
5557fi
5558if test -z "$ac_cv_path_CXX"; then
5559 ac_pt_CXX=$CXX
5560 # Extract the first word of "clang++", so it can be a program name with args.
5561set dummy clang++; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005562{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5563printf %s "checking for $ac_word... " >&6; }
5564if test ${ac_cv_path_ac_pt_CXX+y}
5565then :
5566 printf %s "(cached) " >&6
5567else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005568 case $ac_pt_CXX in
5569 [\\/]* | ?:[\\/]*)
5570 ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
5571 ;;
5572 *)
5573 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5574for as_dir in notfound
5575do
5576 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005577 case $as_dir in #(((
5578 '') as_dir=./ ;;
5579 */) ;;
5580 *) as_dir=$as_dir/ ;;
5581 esac
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005582 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005583 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5584 ac_cv_path_ac_pt_CXX="$as_dir$ac_word$ac_exec_ext"
5585 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005586 break 2
5587 fi
5588done
5589 done
5590IFS=$as_save_IFS
5591
5592 ;;
5593esac
5594fi
5595ac_pt_CXX=$ac_cv_path_ac_pt_CXX
5596if test -n "$ac_pt_CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005597 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
5598printf "%s\n" "$ac_pt_CXX" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005599else
Pablo Galindoba421752021-05-03 20:33:17 +01005600 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5601printf "%s\n" "no" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005602fi
5603
5604 if test "x$ac_pt_CXX" = x; then
5605 CXX="clang++"
5606 else
5607 case $cross_compiling:$ac_tool_warned in
5608yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01005609{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5610printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005611ac_tool_warned=yes ;;
5612esac
5613 CXX=$ac_pt_CXX
5614 fi
5615else
5616 CXX="$ac_cv_path_CXX"
5617fi
Ned Deilycbfb9a52012-06-23 16:02:19 -07005618 ;;
Zachary Ware5af85642015-12-21 12:09:17 -06005619 icc|*/icc) if test -n "$ac_tool_prefix"; then
5620 # Extract the first word of "${ac_tool_prefix}icpc", so it can be a program name with args.
5621set dummy ${ac_tool_prefix}icpc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005622{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5623printf %s "checking for $ac_word... " >&6; }
5624if test ${ac_cv_path_CXX+y}
5625then :
5626 printf %s "(cached) " >&6
5627else $as_nop
Zachary Ware5af85642015-12-21 12:09:17 -06005628 case $CXX in
5629 [\\/]* | ?:[\\/]*)
5630 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
5631 ;;
5632 *)
5633 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5634for as_dir in notfound
5635do
5636 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005637 case $as_dir in #(((
5638 '') as_dir=./ ;;
5639 */) ;;
5640 *) as_dir=$as_dir/ ;;
5641 esac
Zachary Ware5af85642015-12-21 12:09:17 -06005642 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005643 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5644 ac_cv_path_CXX="$as_dir$ac_word$ac_exec_ext"
5645 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Zachary Ware5af85642015-12-21 12:09:17 -06005646 break 2
5647 fi
5648done
5649 done
5650IFS=$as_save_IFS
5651
5652 ;;
5653esac
5654fi
5655CXX=$ac_cv_path_CXX
5656if test -n "$CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005657 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5658printf "%s\n" "$CXX" >&6; }
Zachary Ware5af85642015-12-21 12:09:17 -06005659else
Pablo Galindoba421752021-05-03 20:33:17 +01005660 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5661printf "%s\n" "no" >&6; }
Zachary Ware5af85642015-12-21 12:09:17 -06005662fi
5663
5664
5665fi
5666if test -z "$ac_cv_path_CXX"; then
5667 ac_pt_CXX=$CXX
5668 # Extract the first word of "icpc", so it can be a program name with args.
5669set dummy icpc; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005670{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5671printf %s "checking for $ac_word... " >&6; }
5672if test ${ac_cv_path_ac_pt_CXX+y}
5673then :
5674 printf %s "(cached) " >&6
5675else $as_nop
Zachary Ware5af85642015-12-21 12:09:17 -06005676 case $ac_pt_CXX in
5677 [\\/]* | ?:[\\/]*)
5678 ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path.
5679 ;;
5680 *)
5681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5682for as_dir in notfound
5683do
5684 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005685 case $as_dir in #(((
5686 '') as_dir=./ ;;
5687 */) ;;
5688 *) as_dir=$as_dir/ ;;
5689 esac
Zachary Ware5af85642015-12-21 12:09:17 -06005690 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005691 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5692 ac_cv_path_ac_pt_CXX="$as_dir$ac_word$ac_exec_ext"
5693 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Zachary Ware5af85642015-12-21 12:09:17 -06005694 break 2
5695 fi
5696done
5697 done
5698IFS=$as_save_IFS
5699
5700 ;;
5701esac
5702fi
5703ac_pt_CXX=$ac_cv_path_ac_pt_CXX
5704if test -n "$ac_pt_CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005705 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5
5706printf "%s\n" "$ac_pt_CXX" >&6; }
Zachary Ware5af85642015-12-21 12:09:17 -06005707else
Pablo Galindoba421752021-05-03 20:33:17 +01005708 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5709printf "%s\n" "no" >&6; }
Zachary Ware5af85642015-12-21 12:09:17 -06005710fi
5711
5712 if test "x$ac_pt_CXX" = x; then
5713 CXX="icpc"
5714 else
5715 case $cross_compiling:$ac_tool_warned in
5716yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01005717{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5718printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Zachary Ware5af85642015-12-21 12:09:17 -06005719ac_tool_warned=yes ;;
5720esac
5721 CXX=$ac_pt_CXX
5722 fi
5723else
5724 CXX="$ac_cv_path_CXX"
5725fi
5726 ;;
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005727 esac
5728 if test "$CXX" = "notfound"
5729 then
5730 CXX=""
5731 fi
5732fi
5733if test -z "$CXX"
5734then
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005735 if test -n "$ac_tool_prefix"; then
5736 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
5737 do
5738 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5739set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005740{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5741printf %s "checking for $ac_word... " >&6; }
5742if test ${ac_cv_prog_CXX+y}
5743then :
5744 printf %s "(cached) " >&6
5745else $as_nop
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005746 if test -n "$CXX"; then
5747 ac_cv_prog_CXX="$CXX" # Let the user override the test.
5748else
5749as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5750for as_dir in $PATH
5751do
5752 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005753 case $as_dir in #(((
5754 '') as_dir=./ ;;
5755 */) ;;
5756 *) as_dir=$as_dir/ ;;
5757 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00005758 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005759 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005760 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01005761 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005762 break 2
5763 fi
5764done
Matthias Kloseb9621712010-04-24 17:59:49 +00005765 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005766IFS=$as_save_IFS
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005767
5768fi
5769fi
5770CXX=$ac_cv_prog_CXX
5771if test -n "$CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005772 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
5773printf "%s\n" "$CXX" >&6; }
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005774else
Pablo Galindoba421752021-05-03 20:33:17 +01005775 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5776printf "%s\n" "no" >&6; }
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005777fi
5778
Thomas Wouters47b49bf2007-08-30 22:15:33 +00005779
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005780 test -n "$CXX" && break
5781 done
5782fi
5783if test -z "$CXX"; then
5784 ac_ct_CXX=$CXX
5785 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
5786do
5787 # Extract the first word of "$ac_prog", so it can be a program name with args.
5788set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01005789{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5790printf %s "checking for $ac_word... " >&6; }
5791if test ${ac_cv_prog_ac_ct_CXX+y}
5792then :
5793 printf %s "(cached) " >&6
5794else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005795 if test -n "$ac_ct_CXX"; then
5796 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
5797else
5798as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5799for as_dir in $PATH
5800do
5801 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01005802 case $as_dir in #(((
5803 '') as_dir=./ ;;
5804 */) ;;
5805 *) as_dir=$as_dir/ ;;
5806 esac
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005807 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01005808 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005809 ac_cv_prog_ac_ct_CXX="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01005810 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005811 break 2
5812 fi
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005813done
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005814 done
5815IFS=$as_save_IFS
5816
5817fi
5818fi
5819ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
5820if test -n "$ac_ct_CXX"; then
Pablo Galindoba421752021-05-03 20:33:17 +01005821 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
5822printf "%s\n" "$ac_ct_CXX" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005823else
Pablo Galindoba421752021-05-03 20:33:17 +01005824 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5825printf "%s\n" "no" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005826fi
5827
5828
5829 test -n "$ac_ct_CXX" && break
5830done
5831
5832 if test "x$ac_ct_CXX" = x; then
5833 CXX="notfound"
5834 else
5835 case $cross_compiling:$ac_tool_warned in
5836yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01005837{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5838printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com51f65942012-06-30 14:42:46 +02005839ac_tool_warned=yes ;;
5840esac
5841 CXX=$ac_ct_CXX
5842 fi
5843fi
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005844
5845 if test "$CXX" = "notfound"
5846 then
5847 CXX=""
5848 fi
5849fi
5850if test "$preset_cxx" != "$CXX"
5851then
Pablo Galindoba421752021-05-03 20:33:17 +01005852 { printf "%s\n" "$as_me:${as_lineno-$LINENO}:
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005853
5854 By default, distutils will build C++ extension modules with \"$CXX\".
5855 If this is not intended, then set CXX on the configure command line.
5856 " >&5
Pablo Galindoba421752021-05-03 20:33:17 +01005857printf "%s\n" "$as_me:
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005858
5859 By default, distutils will build C++ extension modules with \"$CXX\".
5860 If this is not intended, then set CXX on the configure command line.
Christian Heimesfe32aec2013-11-20 01:18:26 +01005861 " >&6;}
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00005862fi
5863
5864
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005865MULTIARCH=$($CC --print-multiarch 2>/dev/null)
5866
5867
Pablo Galindoba421752021-05-03 20:33:17 +01005868{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the platform triplet based on compiler characteristics" >&5
5869printf %s "checking for the platform triplet based on compiler characteristics... " >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005870cat >> conftest.c <<EOF
doko@ubuntu.com5cc9c4f2015-04-19 14:44:05 +02005871#undef bfin
5872#undef cris
5873#undef fr30
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005874#undef linux
doko@ubuntu.com5cc9c4f2015-04-19 14:44:05 +02005875#undef hppa
5876#undef hpux
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005877#undef i386
doko@ubuntu.com5cc9c4f2015-04-19 14:44:05 +02005878#undef mips
doko@ubuntu.com9abe0492015-04-15 23:31:02 +02005879#undef powerpc
doko@ubuntu.com5cc9c4f2015-04-19 14:44:05 +02005880#undef sparc
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005881#undef unix
doko@ubuntu.com5c38cb22016-09-01 22:05:20 +02005882#if defined(__ANDROID__)
Xavier de Gaye32cf1ac2016-12-10 17:31:28 +01005883 # Android is not a multiarch system.
doko@ubuntu.com5c38cb22016-09-01 22:05:20 +02005884#elif defined(__linux__)
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005885# if defined(__x86_64__) && defined(__LP64__)
5886 x86_64-linux-gnu
5887# elif defined(__x86_64__) && defined(__ILP32__)
5888 x86_64-linux-gnux32
5889# elif defined(__i386__)
5890 i386-linux-gnu
5891# elif defined(__aarch64__) && defined(__AARCH64EL__)
5892# if defined(__ILP32__)
5893 aarch64_ilp32-linux-gnu
5894# else
5895 aarch64-linux-gnu
5896# endif
5897# elif defined(__aarch64__) && defined(__AARCH64EB__)
5898# if defined(__ILP32__)
5899 aarch64_be_ilp32-linux-gnu
5900# else
5901 aarch64_be-linux-gnu
5902# endif
5903# elif defined(__alpha__)
5904 alpha-linux-gnu
5905# elif defined(__ARM_EABI__) && defined(__ARM_PCS_VFP)
5906# if defined(__ARMEL__)
5907 arm-linux-gnueabihf
5908# else
5909 armeb-linux-gnueabihf
5910# endif
5911# elif defined(__ARM_EABI__) && !defined(__ARM_PCS_VFP)
5912# if defined(__ARMEL__)
5913 arm-linux-gnueabi
5914# else
5915 armeb-linux-gnueabi
5916# endif
5917# elif defined(__hppa__)
5918 hppa-linux-gnu
5919# elif defined(__ia64__)
5920 ia64-linux-gnu
5921# elif defined(__m68k__) && !defined(__mcoldfire__)
5922 m68k-linux-gnu
Matthias Kloseddbe9762018-04-30 19:22:16 +02005923# elif defined(__mips_hard_float) && defined(__mips_isa_rev) && (__mips_isa_rev >=6) && defined(_MIPSEL)
5924# if _MIPS_SIM == _ABIO32
5925 mipsisa32r6el-linux-gnu
5926# elif _MIPS_SIM == _ABIN32
5927 mipsisa64r6el-linux-gnuabin32
5928# elif _MIPS_SIM == _ABI64
5929 mipsisa64r6el-linux-gnuabi64
5930# else
5931# error unknown platform triplet
5932# endif
5933# elif defined(__mips_hard_float) && defined(__mips_isa_rev) && (__mips_isa_rev >=6)
5934# if _MIPS_SIM == _ABIO32
5935 mipsisa32r6-linux-gnu
5936# elif _MIPS_SIM == _ABIN32
5937 mipsisa64r6-linux-gnuabin32
5938# elif _MIPS_SIM == _ABI64
5939 mipsisa64r6-linux-gnuabi64
5940# else
5941# error unknown platform triplet
5942# endif
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005943# elif defined(__mips_hard_float) && defined(_MIPSEL)
5944# if _MIPS_SIM == _ABIO32
5945 mipsel-linux-gnu
5946# elif _MIPS_SIM == _ABIN32
5947 mips64el-linux-gnuabin32
5948# elif _MIPS_SIM == _ABI64
5949 mips64el-linux-gnuabi64
5950# else
5951# error unknown platform triplet
5952# endif
5953# elif defined(__mips_hard_float)
5954# if _MIPS_SIM == _ABIO32
5955 mips-linux-gnu
5956# elif _MIPS_SIM == _ABIN32
5957 mips64-linux-gnuabin32
5958# elif _MIPS_SIM == _ABI64
5959 mips64-linux-gnuabi64
5960# else
5961# error unknown platform triplet
5962# endif
5963# elif defined(__or1k__)
5964 or1k-linux-gnu
5965# elif defined(__powerpc__) && defined(__SPE__)
5966 powerpc-linux-gnuspe
5967# elif defined(__powerpc64__)
5968# if defined(__LITTLE_ENDIAN__)
5969 powerpc64le-linux-gnu
5970# else
5971 powerpc64-linux-gnu
5972# endif
5973# elif defined(__powerpc__)
5974 powerpc-linux-gnu
5975# elif defined(__s390x__)
5976 s390x-linux-gnu
5977# elif defined(__s390__)
5978 s390-linux-gnu
5979# elif defined(__sh__) && defined(__LITTLE_ENDIAN__)
5980 sh4-linux-gnu
5981# elif defined(__sparc__) && defined(__arch64__)
5982 sparc64-linux-gnu
5983# elif defined(__sparc__)
5984 sparc-linux-gnu
Matthias Kloseddbe9762018-04-30 19:22:16 +02005985# elif defined(__riscv)
5986# if __riscv_xlen == 32
5987 riscv32-linux-gnu
5988# elif __riscv_xlen == 64
5989 riscv64-linux-gnu
5990# else
5991# error unknown platform triplet
5992# endif
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02005993# else
5994# error unknown platform triplet
5995# endif
5996#elif defined(__FreeBSD_kernel__)
5997# if defined(__LP64__)
5998 x86_64-kfreebsd-gnu
5999# elif defined(__i386__)
6000 i386-kfreebsd-gnu
6001# else
6002# error unknown platform triplet
6003# endif
6004#elif defined(__gnu_hurd__)
6005 i386-gnu
Ned Deily3b812482015-04-15 17:11:47 -07006006#elif defined(__APPLE__)
6007 darwin
pxinwr32f5fdd2019-02-27 19:09:28 +08006008#elif defined(__VXWORKS__)
6009 vxworks
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006010#else
6011# error unknown platform triplet
6012#endif
6013
6014EOF
6015
Xavier de Gaye3a32bdf2016-07-30 11:28:35 +02006016if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006017 PLATFORM_TRIPLET=`grep -v '^#' conftest.out | grep -v '^ *$' | tr -d ' '`
Pablo Galindoba421752021-05-03 20:33:17 +01006018 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PLATFORM_TRIPLET" >&5
6019printf "%s\n" "$PLATFORM_TRIPLET" >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006020else
Pablo Galindoba421752021-05-03 20:33:17 +01006021 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
6022printf "%s\n" "none" >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006023fi
6024rm -f conftest.c conftest.out
6025
6026if test x$PLATFORM_TRIPLET != x && test x$MULTIARCH != x; then
6027 if test x$PLATFORM_TRIPLET != x$MULTIARCH; then
6028 as_fn_error $? "internal configure error for the platform triplet, please file a bug report" "$LINENO" 5
6029 fi
doko@ubuntu.com75b1cb12016-08-29 20:03:25 +02006030elif test x$PLATFORM_TRIPLET != x && test x$MULTIARCH = x; then
6031 MULTIARCH=$PLATFORM_TRIPLET
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006032fi
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006033
doko@ubuntu.com55532312016-06-14 08:55:19 +02006034if test x$MULTIARCH != x; then
6035 MULTIARCH_CPPFLAGS="-DMULTIARCH=\\\"$MULTIARCH\\\""
6036fi
doko@ubuntu.comd3899c12015-04-15 20:23:14 +02006037
6038
Pablo Galindoba421752021-05-03 20:33:17 +01006039{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -Wl,--no-as-needed" >&5
6040printf %s "checking for -Wl,--no-as-needed... " >&6; }
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006041save_LDFLAGS="$LDFLAGS"
6042LDFLAGS="$LDFLAGS -Wl,--no-as-needed"
Martin v. Löwis11437992002-04-12 09:54:03 +00006043
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006044cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6045/* end confdefs.h. */
6046
6047int
Pablo Galindoba421752021-05-03 20:33:17 +01006048main (void)
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006049{
6050
6051 ;
6052 return 0;
6053}
6054_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01006055if ac_fn_c_try_link "$LINENO"
6056then :
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006057 NO_AS_NEEDED="-Wl,--no-as-needed"
Pablo Galindoba421752021-05-03 20:33:17 +01006058 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6059printf "%s\n" "yes" >&6; }
6060else $as_nop
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006061 NO_AS_NEEDED=""
Pablo Galindoba421752021-05-03 20:33:17 +01006062 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6063printf "%s\n" "no" >&6; }
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006064fi
Pablo Galindoba421752021-05-03 20:33:17 +01006065rm -f core conftest.err conftest.$ac_objext conftest.beam \
Martin v. Löwis48e14d32011-05-09 07:37:45 +02006066 conftest$ac_exeext conftest.$ac_ext
6067LDFLAGS="$save_LDFLAGS"
6068
6069
6070
6071# checks for UNIX variants that set C preprocessor variables
Pablo Galindoba421752021-05-03 20:33:17 +01006072ac_header= ac_cache=
6073for ac_item in $ac_header_c_list
Thomas Wouters47b49bf2007-08-30 22:15:33 +00006074do
Pablo Galindoba421752021-05-03 20:33:17 +01006075 if test $ac_cache; then
6076 ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
6077 if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
6078 printf "%s\n" "#define $ac_item 1" >> confdefs.h
Thomas Wouters47b49bf2007-08-30 22:15:33 +00006079 fi
Pablo Galindoba421752021-05-03 20:33:17 +01006080 ac_header= ac_cache=
6081 elif test $ac_header; then
6082 ac_cache=$ac_item
6083 else
6084 ac_header=$ac_item
Matthias Kloseb9621712010-04-24 17:59:49 +00006085 fi
Matthias Kloseb9621712010-04-24 17:59:49 +00006086done
6087
6088
6089
Pablo Galindoba421752021-05-03 20:33:17 +01006090
6091
6092
6093
6094
6095if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
6096then :
6097
6098printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
6099
Matthias Kloseb9621712010-04-24 17:59:49 +00006100fi
6101
6102
Matthias Kloseb9621712010-04-24 17:59:49 +00006103
6104
Matthias Kloseb9621712010-04-24 17:59:49 +00006105
6106
Pablo Galindoba421752021-05-03 20:33:17 +01006107 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6108printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6109if test ${ac_cv_safe_to_define___extensions__+y}
6110then :
6111 printf %s "(cached) " >&6
6112else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00006113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6114/* end confdefs.h. */
6115
Ross Lagerwall1b863eb2012-10-29 17:31:54 +00006116# define __EXTENSIONS__ 1
6117 $ac_includes_default
Matthias Kloseb9621712010-04-24 17:59:49 +00006118int
Pablo Galindoba421752021-05-03 20:33:17 +01006119main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +00006120{
6121
6122 ;
6123 return 0;
6124}
6125_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01006126if ac_fn_c_try_compile "$LINENO"
6127then :
Matthias Kloseb9621712010-04-24 17:59:49 +00006128 ac_cv_safe_to_define___extensions__=yes
Pablo Galindoba421752021-05-03 20:33:17 +01006129else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00006130 ac_cv_safe_to_define___extensions__=no
6131fi
Pablo Galindoba421752021-05-03 20:33:17 +01006132rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +00006133fi
Pablo Galindoba421752021-05-03 20:33:17 +01006134{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6135printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +00006136
Pablo Galindoba421752021-05-03 20:33:17 +01006137 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6138printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6139if test ${ac_cv_should_define__xopen_source+y}
6140then :
6141 printf %s "(cached) " >&6
6142else $as_nop
6143 ac_cv_should_define__xopen_source=no
6144 if test $ac_cv_header_wchar_h = yes
6145then :
6146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6147/* end confdefs.h. */
Matthias Kloseb9621712010-04-24 17:59:49 +00006148
Pablo Galindoba421752021-05-03 20:33:17 +01006149 #include <wchar.h>
6150 mbstate_t x;
6151int
6152main (void)
6153{
Matthias Kloseb9621712010-04-24 17:59:49 +00006154
Pablo Galindoba421752021-05-03 20:33:17 +01006155 ;
6156 return 0;
6157}
6158_ACEOF
6159if ac_fn_c_try_compile "$LINENO"
6160then :
Matthias Kloseb9621712010-04-24 17:59:49 +00006161
Pablo Galindoba421752021-05-03 20:33:17 +01006162else $as_nop
6163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6164/* end confdefs.h. */
6165
6166 #define _XOPEN_SOURCE 500
6167 #include <wchar.h>
6168 mbstate_t x;
6169int
6170main (void)
6171{
6172
6173 ;
6174 return 0;
6175}
6176_ACEOF
6177if ac_fn_c_try_compile "$LINENO"
6178then :
6179 ac_cv_should_define__xopen_source=yes
6180fi
6181rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6182fi
6183rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6184fi
6185fi
6186{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6187printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; }
6188
6189 printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h
6190
6191 printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6192
6193 printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
6194
6195 printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h
6196
6197 printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
6198
6199 printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h
6200
6201 printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6202
6203 printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
6204
6205 printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
6206
6207 printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
6208
6209 printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
6210
6211 printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
6212
6213 printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
6214
6215 printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
6216
6217 printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h
6218
6219 if test $ac_cv_header_minix_config_h = yes
6220then :
6221 MINIX=yes
6222 printf "%s\n" "#define _MINIX 1" >>confdefs.h
6223
6224 printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h
6225
6226 printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h
6227
6228else $as_nop
6229 MINIX=
6230fi
6231 if test $ac_cv_safe_to_define___extensions__ = yes
6232then :
6233 printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h
6234
6235fi
6236 if test $ac_cv_should_define__xopen_source = yes
6237then :
6238 printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h
6239
6240fi
Matthias Kloseb9621712010-04-24 17:59:49 +00006241
6242
Pablo Galindoba421752021-05-03 20:33:17 +01006243{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the Android API level" >&5
6244printf %s "checking for the Android API level... " >&6; }
Xavier de Gaye95750b12016-07-09 11:05:42 +02006245cat >> conftest.c <<EOF
6246#ifdef __ANDROID__
Xavier de Gaye2a352b62017-01-04 21:51:16 +01006247android_api = __ANDROID_API__
6248arm_arch = __ARM_ARCH
Xavier de Gaye95750b12016-07-09 11:05:42 +02006249#else
6250#error not Android
6251#endif
6252EOF
6253
6254if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then
Xavier de Gaye2a352b62017-01-04 21:51:16 +01006255 ANDROID_API_LEVEL=`sed -n -e '/__ANDROID_API__/d' -e 's/^android_api = //p' conftest.out`
6256 _arm_arch=`sed -n -e '/__ARM_ARCH/d' -e 's/^arm_arch = //p' conftest.out`
Pablo Galindoba421752021-05-03 20:33:17 +01006257 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ANDROID_API_LEVEL" >&5
6258printf "%s\n" "$ANDROID_API_LEVEL" >&6; }
xdegayec06c22e2017-11-23 11:44:38 +01006259 if test -z "$ANDROID_API_LEVEL"; then
6260 echo 'Fatal: you must define __ANDROID_API__'
6261 exit 1
6262 fi
Xavier de Gaye95750b12016-07-09 11:05:42 +02006263
Pablo Galindoba421752021-05-03 20:33:17 +01006264printf "%s\n" "#define ANDROID_API_LEVEL $ANDROID_API_LEVEL" >>confdefs.h
Xavier de Gaye95750b12016-07-09 11:05:42 +02006265
Xavier de Gaye2a352b62017-01-04 21:51:16 +01006266
Pablo Galindoba421752021-05-03 20:33:17 +01006267 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the Android arm ABI" >&5
6268printf %s "checking for the Android arm ABI... " >&6; }
6269 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $_arm_arch" >&5
6270printf "%s\n" "$_arm_arch" >&6; }
Xavier de Gaye2a352b62017-01-04 21:51:16 +01006271 if test "$_arm_arch" = 7; then
6272 BASECFLAGS="${BASECFLAGS} -mfloat-abi=softfp -mfpu=vfpv3-d16"
6273 LDFLAGS="${LDFLAGS} -march=armv7-a -Wl,--fix-cortex-a8"
6274 fi
Xavier de Gaye95750b12016-07-09 11:05:42 +02006275else
Pablo Galindoba421752021-05-03 20:33:17 +01006276 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not Android" >&5
6277printf "%s\n" "not Android" >&6; }
Xavier de Gaye95750b12016-07-09 11:05:42 +02006278fi
6279rm -f conftest.c conftest.out
6280
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006281# Check for unsupported systems
6282case $ac_sys_system/$ac_sys_release in
6283atheos*|Linux*/1*)
6284 echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
6285 echo See README for details.
6286 exit 1;;
6287esac
6288
6289
Pablo Galindoba421752021-05-03 20:33:17 +01006290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5
6291printf %s "checking for --with-suffix... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006292
6293# Check whether --with-suffix was given.
Pablo Galindoba421752021-05-03 20:33:17 +01006294if test ${with_suffix+y}
6295then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006296 withval=$with_suffix;
6297 case $withval in
6298 no) EXEEXT=;;
6299 yes) EXEEXT=.exe;;
6300 *) EXEEXT=$withval;;
6301 esac
6302fi
6303
Pablo Galindoba421752021-05-03 20:33:17 +01006304{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5
6305printf "%s\n" "$EXEEXT" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006306
6307# Test whether we're running on a non-case-sensitive system, in which
6308# case we give a warning if no ext is given
6309
Pablo Galindoba421752021-05-03 20:33:17 +01006310{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5
6311printf %s "checking for case-insensitive build directory... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006312if test ! -d CaseSensitiveTestDir; then
6313mkdir CaseSensitiveTestDir
6314fi
6315
6316if test -d casesensitivetestdir
6317then
Pablo Galindoba421752021-05-03 20:33:17 +01006318 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6319printf "%s\n" "yes" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006320 BUILDEXEEXT=.exe
6321else
Pablo Galindoba421752021-05-03 20:33:17 +01006322 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6323printf "%s\n" "no" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006324 BUILDEXEEXT=$EXEEXT
6325fi
6326rmdir CaseSensitiveTestDir
6327
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006328case $ac_sys_system in
6329hp*|HP*)
6330 case $CC in
6331 cc|*/cc) CC="$CC -Ae";;
6332 esac;;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006333esac
6334
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006335
Pablo Galindoba421752021-05-03 20:33:17 +01006336{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5
6337printf %s "checking LIBRARY... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006338if test -z "$LIBRARY"
6339then
Barry Warsawf040d7d2010-10-18 17:09:07 +00006340 LIBRARY='libpython$(VERSION)$(ABIFLAGS).a'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006341fi
Pablo Galindoba421752021-05-03 20:33:17 +01006342{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5
6343printf "%s\n" "$LIBRARY" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006344
6345# LDLIBRARY is the name of the library to link against (as opposed to the
6346# name of the library into which to insert object files). BLDLIBRARY is also
6347# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
6348# is blank as the main program is not linked directly against LDLIBRARY.
6349# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
6350# systems without shared libraries, LDLIBRARY is the same as LIBRARY
6351# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
6352# DLLLIBRARY is the shared (i.e., DLL) library.
6353#
6354# RUNSHARED is used to run shared python without installed libraries
6355#
6356# INSTSONAME is the name of the shared library that will be use to install
6357# on the system - some systems like version suffix, others don't
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006358#
6359# LDVERSION is the shared library version number, normally the Python version
6360# with the ABI build flags appended.
6361
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006362
6363
6364
6365
6366
6367
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +00006368
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006369LDLIBRARY="$LIBRARY"
6370BLDLIBRARY='$(LDLIBRARY)'
6371INSTSONAME='$(LDLIBRARY)'
6372DLLLIBRARY=''
6373LDLIBRARYDIR=''
6374RUNSHARED=''
Barry Warsaw14d98ac2010-11-24 19:43:47 +00006375LDVERSION="$VERSION"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006376
6377# LINKCC is the command that links the python executable -- default is $(CC).
6378# If CXX is set, and if it is needed to link a main function that was
6379# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
6380# python might then depend on the C++ runtime
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006381
Pablo Galindoba421752021-05-03 20:33:17 +01006382{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5
6383printf %s "checking LINKCC... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006384if test -z "$LINKCC"
6385then
6386 LINKCC='$(PURIFY) $(MAINCC)'
6387 case $ac_sys_system in
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006388 QNX*)
6389 # qcc must be used because the other compilers do not
6390 # support -N.
6391 LINKCC=qcc;;
6392 esac
6393fi
Pablo Galindoba421752021-05-03 20:33:17 +01006394{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5
6395printf "%s\n" "$LINKCC" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006396
Stefan Krahe6dcd372020-08-29 17:00:08 +02006397# EXPORTSYMS holds the list of exported symbols for AIX.
6398# EXPORTSFROM holds the module name exporting symbols on AIX.
6399EXPORTSYMS=
6400EXPORTSFROM=
6401
6402
Pablo Galindoba421752021-05-03 20:33:17 +01006403{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking EXPORTSYMS" >&5
6404printf %s "checking EXPORTSYMS... " >&6; }
Stefan Krahe6dcd372020-08-29 17:00:08 +02006405case $ac_sys_system in
6406AIX*)
6407 EXPORTSYMS="Modules/python.exp"
Kevin Adlerc79667f2020-11-16 09:16:10 -06006408 EXPORTSFROM=. # the main executable
Stefan Krahe6dcd372020-08-29 17:00:08 +02006409 ;;
6410esac
Pablo Galindoba421752021-05-03 20:33:17 +01006411{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $EXPORTSYMS" >&5
6412printf "%s\n" "$EXPORTSYMS" >&6; }
Stefan Krahe6dcd372020-08-29 17:00:08 +02006413
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006414# GNULD is set to "yes" if the GNU linker is used. If this goes wrong
6415# make sure we default having it set to "no": this is used by
6416# distutils.unixccompiler to know if it should add --enable-new-dtags
6417# to linker command lines, and failing to detect GNU ld simply results
6418# in the same bahaviour as before.
6419
Pablo Galindoba421752021-05-03 20:33:17 +01006420{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
6421printf %s "checking for GNU ld... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006422ac_prog=ld
6423if test "$GCC" = yes; then
6424 ac_prog=`$CC -print-prog-name=ld`
6425fi
6426case `"$ac_prog" -V 2>&1 < /dev/null` in
6427 *GNU*)
6428 GNULD=yes;;
6429 *)
6430 GNULD=no;;
6431esac
Pablo Galindoba421752021-05-03 20:33:17 +01006432{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5
6433printf "%s\n" "$GNULD" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006434
Pablo Galindoba421752021-05-03 20:33:17 +01006435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5
6436printf %s "checking for --enable-shared... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006437# Check whether --enable-shared was given.
Pablo Galindoba421752021-05-03 20:33:17 +01006438if test ${enable_shared+y}
6439then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006440 enableval=$enable_shared;
6441fi
6442
6443
6444if test -z "$enable_shared"
6445then
6446 case $ac_sys_system in
Antoine Pitrou6103ab12009-10-24 20:11:21 +00006447 CYGWIN*)
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006448 enable_shared="yes";;
6449 *)
6450 enable_shared="no";;
6451 esac
6452fi
Pablo Galindoba421752021-05-03 20:33:17 +01006453{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
6454printf "%s\n" "$enable_shared" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006455
Pablo Galindoba421752021-05-03 20:33:17 +01006456{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5
6457printf %s "checking for --enable-profiling... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006458# Check whether --enable-profiling was given.
Pablo Galindoba421752021-05-03 20:33:17 +01006459if test ${enable_profiling+y}
6460then :
doko@ubuntu.comba015832012-06-30 16:52:05 +02006461 enableval=$enable_profiling;
6462fi
6463
6464if test "x$enable_profiling" = xyes; then
6465 ac_save_cc="$CC"
Benjamin Peterson615ea1a2013-03-26 08:55:37 -04006466 CC="$CC -pg"
Matthias Kloseb9621712010-04-24 17:59:49 +00006467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006468/* end confdefs.h. */
6469int main() { return 0; }
6470_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01006471if ac_fn_c_try_link "$LINENO"
6472then :
doko@ubuntu.comba015832012-06-30 16:52:05 +02006473
Pablo Galindoba421752021-05-03 20:33:17 +01006474else $as_nop
doko@ubuntu.comba015832012-06-30 16:52:05 +02006475 enable_profiling=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006476fi
Pablo Galindoba421752021-05-03 20:33:17 +01006477rm -f core conftest.err conftest.$ac_objext conftest.beam \
doko@ubuntu.comba015832012-06-30 16:52:05 +02006478 conftest$ac_exeext conftest.$ac_ext
6479 CC="$ac_save_cc"
6480else
6481 enable_profiling=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006482fi
Pablo Galindoba421752021-05-03 20:33:17 +01006483{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_profiling" >&5
6484printf "%s\n" "$enable_profiling" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006485
doko@ubuntu.comba015832012-06-30 16:52:05 +02006486if test "x$enable_profiling" = xyes; then
6487 BASECFLAGS="-pg $BASECFLAGS"
6488 LDFLAGS="-pg $LDFLAGS"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006489fi
6490
Pablo Galindoba421752021-05-03 20:33:17 +01006491{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5
6492printf %s "checking LDLIBRARY... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006493
6494# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
6495# library that we build, but we do not want to link against it (we
6496# will find it with a -framework option). For this reason there is an
6497# extra variable BLDLIBRARY against which Python and the extension
6498# modules are linked, BLDLIBRARY. This is normally the same as
6499# LDLIBRARY, but empty for MacOSX framework builds.
6500if test "$enable_framework"
6501then
6502 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006503 RUNSHARED=DYLD_FRAMEWORK_PATH=`pwd`${DYLD_FRAMEWORK_PATH:+:${DYLD_FRAMEWORK_PATH}}
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006504 BLDLIBRARY=''
6505else
6506 BLDLIBRARY='$(LDLIBRARY)'
6507fi
6508
6509# Other platforms follow
6510if test $enable_shared = "yes"; then
doko@python.org87421192013-01-26 11:39:31 +01006511 PY_ENABLE_SHARED=1
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006512
Pablo Galindoba421752021-05-03 20:33:17 +01006513printf "%s\n" "#define Py_ENABLE_SHARED 1" >>confdefs.h
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006514
6515 case $ac_sys_system in
6516 CYGWIN*)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006517 LDLIBRARY='libpython$(LDVERSION).dll.a'
6518 DLLLIBRARY='libpython$(LDVERSION).dll'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006519 ;;
6520 SunOS*)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006521 LDLIBRARY='libpython$(LDVERSION).so'
6522 BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006523 RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006524 INSTSONAME="$LDLIBRARY".$SOVERSION
Martin v. Löwis9b142aa2011-02-05 20:26:52 +00006525 if test "$with_pydebug" != yes
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +00006526 then
6527 PY3LIBRARY=libpython3.so
6528 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006529 ;;
pxinwrc1174262020-12-15 06:14:43 +08006530 Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*|VxWorks*)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006531 LDLIBRARY='libpython$(LDVERSION).so'
6532 BLDLIBRARY='-L. -lpython$(LDVERSION)'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006533 RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006534 INSTSONAME="$LDLIBRARY".$SOVERSION
Martin v. Löwis9b142aa2011-02-05 20:26:52 +00006535 if test "$with_pydebug" != yes
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +00006536 then
6537 PY3LIBRARY=libpython3.so
6538 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006539 ;;
6540 hp*|HP*)
6541 case `uname -m` in
6542 ia64)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006543 LDLIBRARY='libpython$(LDVERSION).so'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006544 ;;
6545 *)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006546 LDLIBRARY='libpython$(LDVERSION).sl'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006547 ;;
6548 esac
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006549 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(LDVERSION)'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006550 RUNSHARED=SHLIB_PATH=`pwd`${SHLIB_PATH:+:${SHLIB_PATH}}
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006551 ;;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006552 Darwin*)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006553 LDLIBRARY='libpython$(LDVERSION).dylib'
6554 BLDLIBRARY='-L. -lpython$(LDVERSION)'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006555 RUNSHARED=DYLD_LIBRARY_PATH=`pwd`${DYLD_LIBRARY_PATH:+:${DYLD_LIBRARY_PATH}}
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006556 ;;
Antoine Pitrou8e6b4072010-09-10 19:44:44 +00006557 AIX*)
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006558 LDLIBRARY='libpython$(LDVERSION).so'
doko@ubuntu.come5de66e2014-05-07 12:57:44 +02006559 RUNSHARED=LIBPATH=`pwd`${LIBPATH:+:${LIBPATH}}
Antoine Pitrou8e6b4072010-09-10 19:44:44 +00006560 ;;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006561
6562 esac
6563else # shared is disabled
doko@python.org87421192013-01-26 11:39:31 +01006564 PY_ENABLE_SHARED=0
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006565 case $ac_sys_system in
6566 CYGWIN*)
6567 BLDLIBRARY='$(LIBRARY)'
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006568 LDLIBRARY='libpython$(LDVERSION).dll.a'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006569 ;;
6570 esac
6571fi
6572
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02006573if test "$cross_compiling" = yes; then
6574 RUNSHARED=
6575fi
6576
Pablo Galindoba421752021-05-03 20:33:17 +01006577{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5
6578printf "%s\n" "$LDLIBRARY" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006579
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006580
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006581if test -n "$ac_tool_prefix"; then
6582 for ac_prog in ar aal
6583 do
6584 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6585set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01006586{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6587printf %s "checking for $ac_word... " >&6; }
6588if test ${ac_cv_prog_AR+y}
6589then :
6590 printf %s "(cached) " >&6
6591else $as_nop
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006592 if test -n "$AR"; then
6593 ac_cv_prog_AR="$AR" # Let the user override the test.
6594else
6595as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6596for as_dir in $PATH
6597do
6598 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006599 case $as_dir in #(((
6600 '') as_dir=./ ;;
6601 */) ;;
6602 *) as_dir=$as_dir/ ;;
6603 esac
Matthias Kloseb9621712010-04-24 17:59:49 +00006604 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006605 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006606 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01006607 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006608 break 2
6609 fi
6610done
Matthias Kloseb9621712010-04-24 17:59:49 +00006611 done
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006612IFS=$as_save_IFS
6613
6614fi
6615fi
6616AR=$ac_cv_prog_AR
6617if test -n "$AR"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006618 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6619printf "%s\n" "$AR" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006620else
Pablo Galindoba421752021-05-03 20:33:17 +01006621 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6622printf "%s\n" "no" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006623fi
6624
6625
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006626 test -n "$AR" && break
6627 done
6628fi
6629if test -z "$AR"; then
6630 ac_ct_AR=$AR
6631 for ac_prog in ar aal
6632do
6633 # Extract the first word of "$ac_prog", so it can be a program name with args.
6634set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01006635{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6636printf %s "checking for $ac_word... " >&6; }
6637if test ${ac_cv_prog_ac_ct_AR+y}
6638then :
6639 printf %s "(cached) " >&6
6640else $as_nop
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006641 if test -n "$ac_ct_AR"; then
6642 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6643else
6644as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6645for as_dir in $PATH
6646do
6647 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006648 case $as_dir in #(((
6649 '') as_dir=./ ;;
6650 */) ;;
6651 *) as_dir=$as_dir/ ;;
6652 esac
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006653 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006654 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006655 ac_cv_prog_ac_ct_AR="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01006656 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006657 break 2
6658 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006659done
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006660 done
6661IFS=$as_save_IFS
6662
6663fi
6664fi
6665ac_ct_AR=$ac_cv_prog_ac_ct_AR
6666if test -n "$ac_ct_AR"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006667 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6668printf "%s\n" "$ac_ct_AR" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006669else
Pablo Galindoba421752021-05-03 20:33:17 +01006670 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6671printf "%s\n" "no" >&6; }
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006672fi
6673
6674
6675 test -n "$ac_ct_AR" && break
6676done
6677
6678 if test "x$ac_ct_AR" = x; then
6679 AR="ar"
6680 else
6681 case $cross_compiling:$ac_tool_warned in
6682yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01006683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6684printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com51f65942012-06-30 14:42:46 +02006685ac_tool_warned=yes ;;
6686esac
6687 AR=$ac_ct_AR
6688 fi
6689fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006690
6691
6692# tweak ARFLAGS only if the user didn't set it on the command line
6693
6694if test -z "$ARFLAGS"
6695then
Benjamin Petersond15108a2017-09-29 08:42:41 -07006696 ARFLAGS="rcs"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006697fi
6698
doko@ubuntu.com58844492012-06-30 18:25:32 +02006699if test -n "$ac_tool_prefix"; then
6700 for ac_prog in readelf
6701 do
6702 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6703set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01006704{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6705printf %s "checking for $ac_word... " >&6; }
6706if test ${ac_cv_prog_READELF+y}
6707then :
6708 printf %s "(cached) " >&6
6709else $as_nop
doko@ubuntu.com58844492012-06-30 18:25:32 +02006710 if test -n "$READELF"; then
6711 ac_cv_prog_READELF="$READELF" # Let the user override the test.
6712else
6713as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6714for as_dir in $PATH
6715do
6716 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006717 case $as_dir in #(((
6718 '') as_dir=./ ;;
6719 */) ;;
6720 *) as_dir=$as_dir/ ;;
6721 esac
doko@ubuntu.com58844492012-06-30 18:25:32 +02006722 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006723 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com58844492012-06-30 18:25:32 +02006724 ac_cv_prog_READELF="$ac_tool_prefix$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01006725 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com58844492012-06-30 18:25:32 +02006726 break 2
6727 fi
6728done
6729 done
6730IFS=$as_save_IFS
6731
6732fi
6733fi
6734READELF=$ac_cv_prog_READELF
6735if test -n "$READELF"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006736 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
6737printf "%s\n" "$READELF" >&6; }
doko@ubuntu.com58844492012-06-30 18:25:32 +02006738else
Pablo Galindoba421752021-05-03 20:33:17 +01006739 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6740printf "%s\n" "no" >&6; }
doko@ubuntu.com58844492012-06-30 18:25:32 +02006741fi
6742
6743
6744 test -n "$READELF" && break
6745 done
6746fi
6747if test -z "$READELF"; then
6748 ac_ct_READELF=$READELF
6749 for ac_prog in readelf
6750do
6751 # Extract the first word of "$ac_prog", so it can be a program name with args.
6752set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01006753{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6754printf %s "checking for $ac_word... " >&6; }
6755if test ${ac_cv_prog_ac_ct_READELF+y}
6756then :
6757 printf %s "(cached) " >&6
6758else $as_nop
doko@ubuntu.com58844492012-06-30 18:25:32 +02006759 if test -n "$ac_ct_READELF"; then
6760 ac_cv_prog_ac_ct_READELF="$ac_ct_READELF" # Let the user override the test.
6761else
6762as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6763for as_dir in $PATH
6764do
6765 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006766 case $as_dir in #(((
6767 '') as_dir=./ ;;
6768 */) ;;
6769 *) as_dir=$as_dir/ ;;
6770 esac
doko@ubuntu.com58844492012-06-30 18:25:32 +02006771 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006772 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
doko@ubuntu.com58844492012-06-30 18:25:32 +02006773 ac_cv_prog_ac_ct_READELF="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +01006774 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
doko@ubuntu.com58844492012-06-30 18:25:32 +02006775 break 2
6776 fi
6777done
6778 done
6779IFS=$as_save_IFS
6780
6781fi
6782fi
6783ac_ct_READELF=$ac_cv_prog_ac_ct_READELF
6784if test -n "$ac_ct_READELF"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006785 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_READELF" >&5
6786printf "%s\n" "$ac_ct_READELF" >&6; }
doko@ubuntu.com58844492012-06-30 18:25:32 +02006787else
Pablo Galindoba421752021-05-03 20:33:17 +01006788 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6789printf "%s\n" "no" >&6; }
doko@ubuntu.com58844492012-06-30 18:25:32 +02006790fi
6791
6792
6793 test -n "$ac_ct_READELF" && break
6794done
6795
6796 if test "x$ac_ct_READELF" = x; then
6797 READELF=":"
6798 else
6799 case $cross_compiling:$ac_tool_warned in
6800yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01006801{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6802printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
doko@ubuntu.com58844492012-06-30 18:25:32 +02006803ac_tool_warned=yes ;;
6804esac
6805 READELF=$ac_ct_READELF
6806 fi
6807fi
6808
6809if test "$cross_compiling" = yes; then
6810 case "$READELF" in
6811 readelf|:)
6812 as_fn_error $? "readelf for the host is required for cross builds" "$LINENO" 5
6813 ;;
6814 esac
6815fi
6816
6817
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006818
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006819case $MACHDEP in
Benjamin Peterson288d1da2017-09-28 22:44:27 -07006820hp*|HP*)
6821 # install -d does not work on HP-UX
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006822 if test -z "$INSTALL"
6823 then
6824 INSTALL="${srcdir}/install-sh -c"
6825 fi
6826esac
Pablo Galindoba421752021-05-03 20:33:17 +01006827
6828 # Find a good install program. We prefer a C program (faster),
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006829# so one script is as good as another. But avoid the broken or
6830# incompatible versions:
6831# SysV /etc/install, /usr/sbin/install
6832# SunOS /usr/etc/install
6833# IRIX /sbin/install
6834# AIX /bin/install
6835# AmigaOS /C/install, which installs bootblocks on floppy discs
6836# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6837# AFS /usr/afsws/bin/install, which mishandles nonexistent args
6838# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6839# OS/2's system install, which has a completely different semantic
6840# ./install, which can be erroneously created by make from ./install.sh.
Matthias Kloseb9621712010-04-24 17:59:49 +00006841# Reject install programs that cannot install multiple files.
Pablo Galindoba421752021-05-03 20:33:17 +01006842{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
6843printf %s "checking for a BSD-compatible install... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006844if test -z "$INSTALL"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006845if test ${ac_cv_path_install+y}
6846then :
6847 printf %s "(cached) " >&6
6848else $as_nop
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6850for as_dir in $PATH
6851do
6852 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006853 case $as_dir in #(((
6854 '') as_dir=./ ;;
6855 */) ;;
6856 *) as_dir=$as_dir/ ;;
6857 esac
6858 # Account for fact that we put trailing slashes in our PATH walk.
6859case $as_dir in #((
6860 ./ | /[cC]/* | \
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006861 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
Matthias Kloseb9621712010-04-24 17:59:49 +00006862 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006863 /usr/ucb/* ) ;;
6864 *)
6865 # OSF1 and SCO ODT 3.0 have their own names for install.
6866 # Don't use installbsd from OSF since it installs stuff as root
6867 # by default.
6868 for ac_prog in ginstall scoinst install; do
6869 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006870 if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006871 if test $ac_prog = install &&
Pablo Galindoba421752021-05-03 20:33:17 +01006872 grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006873 # AIX install. It has an incompatible calling convention.
6874 :
6875 elif test $ac_prog = install &&
Pablo Galindoba421752021-05-03 20:33:17 +01006876 grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006877 # program-specific install script used by HP pwplus--don't use.
6878 :
6879 else
Matthias Kloseb9621712010-04-24 17:59:49 +00006880 rm -rf conftest.one conftest.two conftest.dir
6881 echo one > conftest.one
6882 echo two > conftest.two
6883 mkdir conftest.dir
Pablo Galindoba421752021-05-03 20:33:17 +01006884 if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" &&
Matthias Kloseb9621712010-04-24 17:59:49 +00006885 test -s conftest.one && test -s conftest.two &&
6886 test -s conftest.dir/conftest.one &&
6887 test -s conftest.dir/conftest.two
6888 then
Pablo Galindoba421752021-05-03 20:33:17 +01006889 ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c"
Matthias Kloseb9621712010-04-24 17:59:49 +00006890 break 3
6891 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006892 fi
6893 fi
6894 done
6895 done
6896 ;;
6897esac
Matthias Kloseb9621712010-04-24 17:59:49 +00006898
6899 done
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006900IFS=$as_save_IFS
6901
Matthias Kloseb9621712010-04-24 17:59:49 +00006902rm -rf conftest.one conftest.two conftest.dir
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006903
6904fi
Pablo Galindoba421752021-05-03 20:33:17 +01006905 if test ${ac_cv_path_install+y}; then
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006906 INSTALL=$ac_cv_path_install
6907 else
6908 # As a last resort, use the slow shell script. Don't cache a
6909 # value for INSTALL within a source directory, because that will
6910 # break other packages using the cache if that directory is
6911 # removed, or if the value is a relative name.
6912 INSTALL=$ac_install_sh
6913 fi
6914fi
Pablo Galindoba421752021-05-03 20:33:17 +01006915{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
6916printf "%s\n" "$INSTALL" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006917
6918# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6919# It thinks the first close brace ends the variable substitution.
6920test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6921
6922test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6923
6924test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6925
Pablo Galindoba421752021-05-03 20:33:17 +01006926
6927 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5
6928printf %s "checking for a race-free mkdir -p... " >&6; }
Matthias Klose93a0ef12012-03-15 18:08:34 +01006929if test -z "$MKDIR_P"; then
Pablo Galindoba421752021-05-03 20:33:17 +01006930 if test ${ac_cv_path_mkdir+y}
6931then :
6932 printf %s "(cached) " >&6
6933else $as_nop
Matthias Klose93a0ef12012-03-15 18:08:34 +01006934 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6935for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6936do
6937 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01006938 case $as_dir in #(((
6939 '') as_dir=./ ;;
6940 */) ;;
6941 *) as_dir=$as_dir/ ;;
6942 esac
Matthias Klose93a0ef12012-03-15 18:08:34 +01006943 for ac_prog in mkdir gmkdir; do
6944 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01006945 as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue
6946 case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #(
6947 'mkdir ('*'coreutils) '* | \
6948 'BusyBox '* | \
Matthias Klose93a0ef12012-03-15 18:08:34 +01006949 'mkdir (fileutils) '4.1*)
Pablo Galindoba421752021-05-03 20:33:17 +01006950 ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext
Matthias Klose93a0ef12012-03-15 18:08:34 +01006951 break 3;;
6952 esac
6953 done
6954 done
6955 done
6956IFS=$as_save_IFS
6957
6958fi
6959
6960 test -d ./--version && rmdir ./--version
Pablo Galindoba421752021-05-03 20:33:17 +01006961 if test ${ac_cv_path_mkdir+y}; then
Matthias Klose93a0ef12012-03-15 18:08:34 +01006962 MKDIR_P="$ac_cv_path_mkdir -p"
6963 else
6964 # As a last resort, use the slow shell script. Don't cache a
6965 # value for MKDIR_P within a source directory, because that will
6966 # break other packages using the cache if that directory is
6967 # removed, or if the value is a relative name.
6968 MKDIR_P="$ac_install_sh -d"
6969 fi
6970fi
Pablo Galindoba421752021-05-03 20:33:17 +01006971{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
6972printf "%s\n" "$MKDIR_P" >&6; }
Matthias Klose93a0ef12012-03-15 18:08:34 +01006973
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006974
6975# Not every filesystem supports hard links
6976
6977if test -z "$LN" ; then
6978 case $ac_sys_system in
6979 CYGWIN*) LN="ln -s";;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006980 *) LN=ln;;
6981 esac
6982fi
6983
Barry Warsaw35f3a2c2010-09-03 18:30:30 +00006984# For calculating the .so ABI tag.
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00006985
6986ABIFLAGS=""
Barry Warsaw35f3a2c2010-09-03 18:30:30 +00006987
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006988# Check for --with-pydebug
Pablo Galindoba421752021-05-03 20:33:17 +01006989{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5
6990printf %s "checking for --with-pydebug... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006991
6992# Check whether --with-pydebug was given.
Pablo Galindoba421752021-05-03 20:33:17 +01006993if test ${with_pydebug+y}
6994then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00006995 withval=$with_pydebug;
6996if test "$withval" != no
6997then
6998
Pablo Galindoba421752021-05-03 20:33:17 +01006999printf "%s\n" "#define Py_DEBUG 1" >>confdefs.h
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007000
Pablo Galindoba421752021-05-03 20:33:17 +01007001 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7002printf "%s\n" "yes" >&6; };
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007003 Py_DEBUG='true'
Barry Warsaw8cf4eae2010-10-16 01:04:07 +00007004 ABIFLAGS="${ABIFLAGS}d"
Pablo Galindoba421752021-05-03 20:33:17 +01007005else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7006printf "%s\n" "no" >&6; }; Py_DEBUG='false'
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007007fi
Pablo Galindoba421752021-05-03 20:33:17 +01007008else $as_nop
7009 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7010printf "%s\n" "no" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007011fi
7012
7013
Victor Stinnerf4e47032019-04-25 00:56:28 +02007014# Check for --with-trace-refs
7015# --with-trace-refs
Pablo Galindoba421752021-05-03 20:33:17 +01007016{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-trace-refs" >&5
7017printf %s "checking for --with-trace-refs... " >&6; }
Victor Stinnerf4e47032019-04-25 00:56:28 +02007018
7019# Check whether --with-trace-refs was given.
Pablo Galindoba421752021-05-03 20:33:17 +01007020if test ${with_trace_refs+y}
7021then :
Victor Stinnerf4e47032019-04-25 00:56:28 +02007022 withval=$with_trace_refs;
Pablo Galindoba421752021-05-03 20:33:17 +01007023else $as_nop
Victor Stinnerf4e47032019-04-25 00:56:28 +02007024 with_trace_refs=no
7025fi
7026
Pablo Galindoba421752021-05-03 20:33:17 +01007027{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_trace_refs" >&5
7028printf "%s\n" "$with_trace_refs" >&6; }
Victor Stinnerf4e47032019-04-25 00:56:28 +02007029
7030if test "$with_trace_refs" = "yes"
7031then
7032
Pablo Galindoba421752021-05-03 20:33:17 +01007033printf "%s\n" "#define Py_TRACE_REFS 1" >>confdefs.h
Victor Stinnerf4e47032019-04-25 00:56:28 +02007034
7035fi
7036
7037# Check for --with-assertions.
7038# This allows enabling assertions without Py_DEBUG.
T. Woutersddbfa2c2017-05-23 01:30:49 +02007039assertions='false'
Pablo Galindoba421752021-05-03 20:33:17 +01007040{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-assertions" >&5
7041printf %s "checking for --with-assertions... " >&6; }
T. Woutersddbfa2c2017-05-23 01:30:49 +02007042
7043# Check whether --with-assertions was given.
Pablo Galindoba421752021-05-03 20:33:17 +01007044if test ${with_assertions+y}
7045then :
T. Woutersddbfa2c2017-05-23 01:30:49 +02007046 withval=$with_assertions;
7047if test "$withval" != no
7048then
7049 assertions='true'
7050fi
7051fi
7052
7053if test "$assertions" = 'true'; then
Pablo Galindoba421752021-05-03 20:33:17 +01007054 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7055printf "%s\n" "yes" >&6; }
T. Woutersddbfa2c2017-05-23 01:30:49 +02007056elif test "$Py_DEBUG" = 'true'; then
7057 assertions='true'
Pablo Galindoba421752021-05-03 20:33:17 +01007058 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: implied by --with-pydebug" >&5
7059printf "%s\n" "implied by --with-pydebug" >&6; }
T. Woutersddbfa2c2017-05-23 01:30:49 +02007060else
Pablo Galindoba421752021-05-03 20:33:17 +01007061 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7062printf "%s\n" "no" >&6; }
T. Woutersddbfa2c2017-05-23 01:30:49 +02007063fi
7064
Brett Cannon63d98bc2016-09-06 17:12:40 -07007065# Enable optimization flags
7066
7067
7068Py_OPT='false'
Pablo Galindoba421752021-05-03 20:33:17 +01007069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-optimizations" >&5
7070printf %s "checking for --enable-optimizations... " >&6; }
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +00007071# Check whether --enable-optimizations was given.
Pablo Galindoba421752021-05-03 20:33:17 +01007072if test ${enable_optimizations+y}
7073then :
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +00007074 enableval=$enable_optimizations;
Alex Wang8cea5922017-03-28 08:50:51 -04007075if test "$enableval" != no
Brett Cannon63d98bc2016-09-06 17:12:40 -07007076then
7077 Py_OPT='true'
Pablo Galindoba421752021-05-03 20:33:17 +01007078 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7079printf "%s\n" "yes" >&6; };
Brett Cannon63d98bc2016-09-06 17:12:40 -07007080else
7081 Py_OPT='false'
Pablo Galindoba421752021-05-03 20:33:17 +01007082 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7083printf "%s\n" "no" >&6; };
Brett Cannon63d98bc2016-09-06 17:12:40 -07007084fi
Pablo Galindoba421752021-05-03 20:33:17 +01007085else $as_nop
7086 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7087printf "%s\n" "no" >&6; }
Brett Cannon63d98bc2016-09-06 17:12:40 -07007088fi
7089
7090if test "$Py_OPT" = 'true' ; then
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)14c7f712016-09-08 22:38:46 +00007091 # Intentionally not forcing Py_LTO='true' here. Too many toolchains do not
7092 # compile working code using it and both test_distutils and test_gdb are
Brett Cannon1d8f7552016-11-03 16:20:00 -07007093 # broken when you do manage to get a toolchain that works with it. People
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)14c7f712016-09-08 22:38:46 +00007094 # who want LTO need to use --with-lto themselves.
Brett Cannon63d98bc2016-09-06 17:12:40 -07007095 DEF_MAKE_ALL_RULE="profile-opt"
Gregory P. Smith799520c2016-09-07 16:10:00 -07007096 REQUIRE_PGO="yes"
Brett Cannon63d98bc2016-09-06 17:12:40 -07007097 DEF_MAKE_RULE="build_all"
Pablo Galindob451b0e2020-10-21 22:46:52 +01007098 case $CC in
7099 *gcc*)
Pablo Galindoba421752021-05-03 20:33:17 +01007100 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-semantic-interposition" >&5
7101printf %s "checking whether C compiler accepts -fno-semantic-interposition... " >&6; }
7102if test ${ax_cv_check_cflags___fno_semantic_interposition+y}
7103then :
7104 printf %s "(cached) " >&6
7105else $as_nop
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007106
7107 ax_check_save_flags=$CFLAGS
7108 CFLAGS="$CFLAGS -fno-semantic-interposition"
7109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7110/* end confdefs.h. */
7111
7112int
Pablo Galindoba421752021-05-03 20:33:17 +01007113main (void)
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007114{
7115
7116 ;
7117 return 0;
7118}
7119_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007120if ac_fn_c_try_compile "$LINENO"
7121then :
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007122 ax_cv_check_cflags___fno_semantic_interposition=yes
Pablo Galindoba421752021-05-03 20:33:17 +01007123else $as_nop
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007124 ax_cv_check_cflags___fno_semantic_interposition=no
7125fi
Pablo Galindoba421752021-05-03 20:33:17 +01007126rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007127 CFLAGS=$ax_check_save_flags
7128fi
Pablo Galindoba421752021-05-03 20:33:17 +01007129{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_semantic_interposition" >&5
7130printf "%s\n" "$ax_cv_check_cflags___fno_semantic_interposition" >&6; }
7131if test "x$ax_cv_check_cflags___fno_semantic_interposition" = xyes
7132then :
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007133
Pablo Galindob451b0e2020-10-21 22:46:52 +01007134 CFLAGS_NODIST="$CFLAGS_NODIST -fno-semantic-interposition"
7135 LDFLAGS_NODIST="$LDFLAGS_NODIST -fno-semantic-interposition"
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007136
Pablo Galindoba421752021-05-03 20:33:17 +01007137else $as_nop
Petr Viktorinc6d7e822020-10-22 18:11:53 +02007138 :
7139fi
7140
Pablo Galindob451b0e2020-10-21 22:46:52 +01007141 ;;
7142 esac
7143
7144
Brett Cannon63d98bc2016-09-06 17:12:40 -07007145else
7146 DEF_MAKE_ALL_RULE="build_all"
Gregory P. Smith799520c2016-09-07 16:10:00 -07007147 REQUIRE_PGO="no"
Brett Cannon63d98bc2016-09-06 17:12:40 -07007148 DEF_MAKE_RULE="all"
7149fi
7150
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -07007151
Pablo Galindoba421752021-05-03 20:33:17 +01007152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking PROFILE_TASK" >&5
7153printf %s "checking PROFILE_TASK... " >&6; }
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -07007154if test -z "$PROFILE_TASK"
7155then
Victor Stinner67900052021-01-27 11:16:15 +01007156 PROFILE_TASK='-m test --pgo --timeout=$(TESTTIMEOUT)'
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -07007157fi
Pablo Galindoba421752021-05-03 20:33:17 +01007158{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PROFILE_TASK" >&5
7159printf "%s\n" "$PROFILE_TASK" >&6; }
Neil Schemenauer4e16a4a2019-07-22 12:54:25 -07007160
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007161# Make llvm-relatec checks work on systems where llvm tools are not installed with their
7162# normal names in the default $PATH (ie: Ubuntu). They exist under the
7163# non-suffixed name in their versioned llvm directory.
7164
7165llvm_bin_dir=''
7166llvm_path="${PATH}"
7167if test "${CC}" = "clang"
7168then
7169 clang_bin=`which clang`
7170 # Some systems install clang elsewhere as a symlink to the real path
7171 # which is where the related llvm tools are located.
7172 if test -L "${clang_bin}"
7173 then
7174 clang_dir=`dirname "${clang_bin}"`
7175 clang_bin=`readlink "${clang_bin}"`
7176 llvm_bin_dir="${clang_dir}/"`dirname "${clang_bin}"`
7177 llvm_path="${llvm_path}${PATH_SEPARATOR}${llvm_bin_dir}"
7178 fi
7179fi
7180
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007181# Enable LTO flags
Pablo Galindoba421752021-05-03 20:33:17 +01007182{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-lto" >&5
7183printf %s "checking for --with-lto... " >&6; }
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007184
7185# Check whether --with-lto was given.
Pablo Galindoba421752021-05-03 20:33:17 +01007186if test ${with_lto+y}
7187then :
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007188 withval=$with_lto;
7189if test "$withval" != no
7190then
7191 Py_LTO='true'
Pablo Galindoba421752021-05-03 20:33:17 +01007192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7193printf "%s\n" "yes" >&6; };
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007194else
7195 Py_LTO='false'
Pablo Galindoba421752021-05-03 20:33:17 +01007196 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7197printf "%s\n" "no" >&6; };
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007198fi
Pablo Galindoba421752021-05-03 20:33:17 +01007199else $as_nop
7200 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7201printf "%s\n" "no" >&6; }
Gregory P. Smithd82da9f2016-04-15 16:57:04 -07007202fi
7203
7204if test "$Py_LTO" = 'true' ; then
7205 case $CC in
7206 *clang*)
Victor Stinner06fe77a2018-06-19 18:24:58 +02007207
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007208 if test -n "$ac_tool_prefix"; then
7209 # Extract the first word of "${ac_tool_prefix}llvm-ar", so it can be a program name with args.
7210set dummy ${ac_tool_prefix}llvm-ar; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01007211{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7212printf %s "checking for $ac_word... " >&6; }
7213if test ${ac_cv_path_LLVM_AR+y}
7214then :
7215 printf %s "(cached) " >&6
7216else $as_nop
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007217 case $LLVM_AR in
7218 [\\/]* | ?:[\\/]*)
7219 ac_cv_path_LLVM_AR="$LLVM_AR" # Let the user override the test with a path.
7220 ;;
7221 *)
7222 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7223for as_dir in ${llvm_path}
7224do
7225 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01007226 case $as_dir in #(((
7227 '') as_dir=./ ;;
7228 */) ;;
7229 *) as_dir=$as_dir/ ;;
7230 esac
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007231 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01007232 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7233 ac_cv_path_LLVM_AR="$as_dir$ac_word$ac_exec_ext"
7234 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007235 break 2
7236 fi
7237done
7238 done
7239IFS=$as_save_IFS
7240
7241 ;;
7242esac
7243fi
7244LLVM_AR=$ac_cv_path_LLVM_AR
7245if test -n "$LLVM_AR"; then
Pablo Galindoba421752021-05-03 20:33:17 +01007246 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LLVM_AR" >&5
7247printf "%s\n" "$LLVM_AR" >&6; }
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007248else
Pablo Galindoba421752021-05-03 20:33:17 +01007249 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7250printf "%s\n" "no" >&6; }
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007251fi
7252
7253
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007254fi
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007255if test -z "$ac_cv_path_LLVM_AR"; then
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007256 ac_pt_LLVM_AR=$LLVM_AR
7257 # Extract the first word of "llvm-ar", so it can be a program name with args.
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007258set dummy llvm-ar; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01007259{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7260printf %s "checking for $ac_word... " >&6; }
7261if test ${ac_cv_path_ac_pt_LLVM_AR+y}
7262then :
7263 printf %s "(cached) " >&6
7264else $as_nop
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007265 case $ac_pt_LLVM_AR in
7266 [\\/]* | ?:[\\/]*)
7267 ac_cv_path_ac_pt_LLVM_AR="$ac_pt_LLVM_AR" # Let the user override the test with a path.
7268 ;;
7269 *)
7270 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7271for as_dir in ${llvm_path}
7272do
7273 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01007274 case $as_dir in #(((
7275 '') as_dir=./ ;;
7276 */) ;;
7277 *) as_dir=$as_dir/ ;;
7278 esac
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007279 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01007280 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7281 ac_cv_path_ac_pt_LLVM_AR="$as_dir$ac_word$ac_exec_ext"
7282 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007283 break 2
7284 fi
7285done
7286 done
7287IFS=$as_save_IFS
7288
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007289 ;;
7290esac
7291fi
7292ac_pt_LLVM_AR=$ac_cv_path_ac_pt_LLVM_AR
7293if test -n "$ac_pt_LLVM_AR"; then
Pablo Galindoba421752021-05-03 20:33:17 +01007294 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LLVM_AR" >&5
7295printf "%s\n" "$ac_pt_LLVM_AR" >&6; }
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007296else
Pablo Galindoba421752021-05-03 20:33:17 +01007297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7298printf "%s\n" "no" >&6; }
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007299fi
7300
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007301 if test "x$ac_pt_LLVM_AR" = x; then
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007302 LLVM_AR="''"
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007303 else
7304 case $cross_compiling:$ac_tool_warned in
7305yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01007306{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7307printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007308ac_tool_warned=yes ;;
7309esac
7310 LLVM_AR=$ac_pt_LLVM_AR
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007311 fi
7312else
7313 LLVM_AR="$ac_cv_path_LLVM_AR"
7314fi
7315
7316
7317 if test -n "${LLVM_AR}" -a -x "${LLVM_AR}"
7318 then
7319 LLVM_AR_FOUND="found"
7320 else
7321 LLVM_AR_FOUND="not-found"
7322 fi
7323 if test "$ac_sys_system" = "Darwin" -a "${LLVM_AR_FOUND}" = "not-found"
7324 then
Miss Islington (bot)25a9cf12021-05-24 21:18:53 -07007325 # The Apple-supplied ar in Xcode or the Command Line Tools is apparently sufficient
7326 found_llvm_ar=`/usr/bin/xcrun -find ar 2>/dev/null`
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007327 if test -n "${found_llvm_ar}"
7328 then
Miss Islington (bot)25a9cf12021-05-24 21:18:53 -07007329 LLVM_AR='/usr/bin/xcrun ar'
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007330 LLVM_AR_FOUND=found
Pablo Galindoba421752021-05-03 20:33:17 +01007331 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: llvm-ar found via xcrun: ${LLVM_AR}" >&5
7332printf "%s\n" "$as_me: llvm-ar found via xcrun: ${LLVM_AR}" >&6;}
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007333 fi
7334 fi
7335 if test $LLVM_AR_FOUND = not-found
7336 then
7337 LLVM_PROFR_ERR=yes
7338 as_fn_error $? "llvm-ar is required for a --with-lto build with clang but could not be found." "$LINENO" 5
7339 else
7340 LLVM_AR_ERR=no
7341 fi
7342 AR="${LLVM_AR}"
7343 case $ac_sys_system in
7344 Darwin*)
7345 # Any changes made here should be reflected in the GCC+Darwin case below
7346 LTOFLAGS="-flto -Wl,-export_dynamic"
Miss Islington (bot)25a9cf12021-05-24 21:18:53 -07007347 LTOCFLAGS="-flto"
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007348 ;;
7349 *)
7350 LTOFLAGS="-flto"
7351 ;;
7352 esac
7353 ;;
7354 *gcc*)
7355 case $ac_sys_system in
7356 Darwin*)
7357 LTOFLAGS="-flto -Wl,-export_dynamic"
Miss Islington (bot)25a9cf12021-05-24 21:18:53 -07007358 LTOCFLAGS="-flto"
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007359 ;;
7360 *)
7361 LTOFLAGS="-flto -fuse-linker-plugin -ffat-lto-objects -flto-partition=none"
7362 ;;
7363 esac
7364 ;;
7365 esac
7366
7367 if test "$ac_cv_prog_cc_g" = "yes"
7368 then
7369 # bpo-30345: Add -g to LDFLAGS when compiling with LTO
7370 # to get debug symbols.
7371 LTOFLAGS="$LTOFLAGS -g"
7372 fi
7373
Miss Islington (bot)25a9cf12021-05-24 21:18:53 -07007374 CFLAGS_NODIST="$CFLAGS_NODIST ${LTOCFLAGS-$LTOFLAGS}"
stratakiscf10a752018-12-19 18:19:01 +01007375 LDFLAGS_NODIST="$LDFLAGS_NODIST $LTOFLAGS"
serge-sans-paille5ad36f92018-10-25 01:54:22 +02007376fi
7377
7378# Enable PGO flags.
7379
7380
7381
7382
7383
7384
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007385if test -n "$ac_tool_prefix"; then
7386 # Extract the first word of "${ac_tool_prefix}llvm-profdata", so it can be a program name with args.
7387set dummy ${ac_tool_prefix}llvm-profdata; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01007388{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7389printf %s "checking for $ac_word... " >&6; }
7390if test ${ac_cv_path_LLVM_PROFDATA+y}
7391then :
7392 printf %s "(cached) " >&6
7393else $as_nop
Gregory P. Smith799520c2016-09-07 16:10:00 -07007394 case $LLVM_PROFDATA in
7395 [\\/]* | ?:[\\/]*)
7396 ac_cv_path_LLVM_PROFDATA="$LLVM_PROFDATA" # Let the user override the test with a path.
7397 ;;
7398 *)
7399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7400for as_dir in ${llvm_path}
Brett Cannon7188a3e2015-09-18 15:13:44 -07007401do
7402 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01007403 case $as_dir in #(((
7404 '') as_dir=./ ;;
7405 */) ;;
7406 *) as_dir=$as_dir/ ;;
7407 esac
Brett Cannon7188a3e2015-09-18 15:13:44 -07007408 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01007409 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7410 ac_cv_path_LLVM_PROFDATA="$as_dir$ac_word$ac_exec_ext"
7411 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Brett Cannon7188a3e2015-09-18 15:13:44 -07007412 break 2
7413 fi
7414done
7415 done
7416IFS=$as_save_IFS
7417
Gregory P. Smith799520c2016-09-07 16:10:00 -07007418 ;;
7419esac
Brett Cannon7188a3e2015-09-18 15:13:44 -07007420fi
Gregory P. Smith799520c2016-09-07 16:10:00 -07007421LLVM_PROFDATA=$ac_cv_path_LLVM_PROFDATA
7422if test -n "$LLVM_PROFDATA"; then
Pablo Galindoba421752021-05-03 20:33:17 +01007423 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LLVM_PROFDATA" >&5
7424printf "%s\n" "$LLVM_PROFDATA" >&6; }
Brett Cannon7188a3e2015-09-18 15:13:44 -07007425else
Pablo Galindoba421752021-05-03 20:33:17 +01007426 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7427printf "%s\n" "no" >&6; }
Brett Cannon7188a3e2015-09-18 15:13:44 -07007428fi
7429
7430
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007431fi
Gregory P. Smith799520c2016-09-07 16:10:00 -07007432if test -z "$ac_cv_path_LLVM_PROFDATA"; then
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007433 ac_pt_LLVM_PROFDATA=$LLVM_PROFDATA
7434 # Extract the first word of "llvm-profdata", so it can be a program name with args.
Gregory P. Smith799520c2016-09-07 16:10:00 -07007435set dummy llvm-profdata; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +01007436{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7437printf %s "checking for $ac_word... " >&6; }
7438if test ${ac_cv_path_ac_pt_LLVM_PROFDATA+y}
7439then :
7440 printf %s "(cached) " >&6
7441else $as_nop
Gregory P. Smith799520c2016-09-07 16:10:00 -07007442 case $ac_pt_LLVM_PROFDATA in
7443 [\\/]* | ?:[\\/]*)
7444 ac_cv_path_ac_pt_LLVM_PROFDATA="$ac_pt_LLVM_PROFDATA" # Let the user override the test with a path.
7445 ;;
7446 *)
7447 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7448for as_dir in ${llvm_path}
7449do
7450 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +01007451 case $as_dir in #(((
7452 '') as_dir=./ ;;
7453 */) ;;
7454 *) as_dir=$as_dir/ ;;
7455 esac
Gregory P. Smith799520c2016-09-07 16:10:00 -07007456 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +01007457 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7458 ac_cv_path_ac_pt_LLVM_PROFDATA="$as_dir$ac_word$ac_exec_ext"
7459 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Gregory P. Smith799520c2016-09-07 16:10:00 -07007460 break 2
7461 fi
7462done
7463 done
7464IFS=$as_save_IFS
7465
Gregory P. Smith799520c2016-09-07 16:10:00 -07007466 ;;
7467esac
7468fi
7469ac_pt_LLVM_PROFDATA=$ac_cv_path_ac_pt_LLVM_PROFDATA
7470if test -n "$ac_pt_LLVM_PROFDATA"; then
Pablo Galindoba421752021-05-03 20:33:17 +01007471 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LLVM_PROFDATA" >&5
7472printf "%s\n" "$ac_pt_LLVM_PROFDATA" >&6; }
Gregory P. Smith799520c2016-09-07 16:10:00 -07007473else
Pablo Galindoba421752021-05-03 20:33:17 +01007474 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7475printf "%s\n" "no" >&6; }
Gregory P. Smith799520c2016-09-07 16:10:00 -07007476fi
7477
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007478 if test "x$ac_pt_LLVM_PROFDATA" = x; then
Gregory P. Smith799520c2016-09-07 16:10:00 -07007479 LLVM_PROFDATA="''"
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007480 else
7481 case $cross_compiling:$ac_tool_warned in
7482yes:)
Pablo Galindoba421752021-05-03 20:33:17 +01007483{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7484printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Benjamin Petersonf3095b02019-09-13 15:30:36 +01007485ac_tool_warned=yes ;;
7486esac
7487 LLVM_PROFDATA=$ac_pt_LLVM_PROFDATA
Gregory P. Smith799520c2016-09-07 16:10:00 -07007488 fi
7489else
7490 LLVM_PROFDATA="$ac_cv_path_LLVM_PROFDATA"
7491fi
7492
7493
7494if test -n "${LLVM_PROFDATA}" -a -x "${LLVM_PROFDATA}"
7495then
7496 LLVM_PROF_FOUND="found"
7497else
7498 LLVM_PROF_FOUND="not-found"
7499fi
7500if test "$ac_sys_system" = "Darwin" -a "${LLVM_PROF_FOUND}" = "not-found"
7501then
7502 found_llvm_profdata=`/usr/bin/xcrun -find llvm-profdata 2>/dev/null`
7503 if test -n "${found_llvm_profdata}"
7504 then
7505 # llvm-profdata isn't directly in $PATH in some cases.
7506 # https://apple.stackexchange.com/questions/197053/
7507 LLVM_PROFDATA='/usr/bin/xcrun llvm-profdata'
7508 LLVM_PROF_FOUND=found
Pablo Galindoba421752021-05-03 20:33:17 +01007509 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: llvm-profdata found via xcrun: ${LLVM_PROFDATA}" >&5
7510printf "%s\n" "$as_me: llvm-profdata found via xcrun: ${LLVM_PROFDATA}" >&6;}
Gregory P. Smith799520c2016-09-07 16:10:00 -07007511 fi
7512fi
Brett Cannon7188a3e2015-09-18 15:13:44 -07007513LLVM_PROF_ERR=no
7514case $CC in
7515 *clang*)
7516 # Any changes made here should be reflected in the GCC+Darwin case below
7517 PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
7518 PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
Gregory P. Smith799520c2016-09-07 16:10:00 -07007519 LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
Brett Cannon7188a3e2015-09-18 15:13:44 -07007520 LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
7521 if test $LLVM_PROF_FOUND = not-found
7522 then
7523 LLVM_PROF_ERR=yes
Gregory P. Smith799520c2016-09-07 16:10:00 -07007524 if test "${REQUIRE_PGO}" = "yes"
7525 then
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +00007526 as_fn_error $? "llvm-profdata is required for a --enable-optimizations build but could not be found." "$LINENO" 5
Gregory P. Smith799520c2016-09-07 16:10:00 -07007527 fi
Brett Cannon7188a3e2015-09-18 15:13:44 -07007528 fi
7529 ;;
7530 *gcc*)
7531 case $ac_sys_system in
7532 Darwin*)
7533 PGO_PROF_GEN_FLAG="-fprofile-instr-generate"
7534 PGO_PROF_USE_FLAG="-fprofile-instr-use=code.profclangd"
Gregory P. Smith799520c2016-09-07 16:10:00 -07007535 LLVM_PROF_MERGER="${LLVM_PROFDATA} merge -output=code.profclangd *.profclangr"
Brett Cannon7188a3e2015-09-18 15:13:44 -07007536 LLVM_PROF_FILE="LLVM_PROFILE_FILE=\"code-%p.profclangr\""
Gregory P. Smith799520c2016-09-07 16:10:00 -07007537 if test "${LLVM_PROF_FOUND}" = "not-found"
Brett Cannon7188a3e2015-09-18 15:13:44 -07007538 then
7539 LLVM_PROF_ERR=yes
Gregory P. Smith799520c2016-09-07 16:10:00 -07007540 if test "${REQUIRE_PGO}" = "yes"
7541 then
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +00007542 as_fn_error $? "llvm-profdata is required for a --enable-optimizations build but could not be found." "$LINENO" 5
Gregory P. Smith799520c2016-09-07 16:10:00 -07007543 fi
Brett Cannon7188a3e2015-09-18 15:13:44 -07007544 fi
7545 ;;
7546 *)
7547 PGO_PROF_GEN_FLAG="-fprofile-generate"
7548 PGO_PROF_USE_FLAG="-fprofile-use -fprofile-correction"
7549 LLVM_PROF_MERGER="true"
7550 LLVM_PROF_FILE=""
7551 ;;
7552 esac
7553 ;;
Zachary Ware5af85642015-12-21 12:09:17 -06007554 *icc*)
7555 PGO_PROF_GEN_FLAG="-prof-gen"
7556 PGO_PROF_USE_FLAG="-prof-use"
7557 LLVM_PROF_MERGER="true"
7558 LLVM_PROF_FILE=""
7559 ;;
Brett Cannon7188a3e2015-09-18 15:13:44 -07007560esac
7561
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007562# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
7563# merged with this chunk of code?
7564
7565# Optimizer/debugger flags
7566# ------------------------
7567# (The following bit of code is complicated enough - please keep things
7568# indented properly. Just pretend you're editing Python code. ;-)
7569
7570# There are two parallel sets of case statements below, one that checks to
7571# see if OPT was set and one that does BASECFLAGS setting based upon
7572# compiler and platform. BASECFLAGS tweaks need to be made even if the
7573# user set OPT.
7574
Victor Stinner23a683a2019-04-12 21:27:37 +02007575case $CC in
7576 *clang*)
7577 cc_is_clang=1
7578 ;;
7579 *)
7580 if $CC --version 2>&1 | grep -q clang
7581 then
7582 cc_is_clang=1
7583 else
7584 cc_is_clang=
7585 fi
7586esac
7587
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007588# tweak OPT based on compiler and platform, only if the user didn't set
7589# it on the command line
7590
Victor Stinner9ed34a82017-05-02 22:35:58 +02007591
Benjamin Peterson65b4ec52010-03-23 21:02:34 +00007592if test "${OPT-unset}" = "unset"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007593then
7594 case $GCC in
7595 yes)
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007596 # For gcc 4.x we need to use -fwrapv so lets check if its supported
7597 if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then
7598 WRAP="-fwrapv"
7599 fi
Stefan Krah962055d2011-09-14 15:14:08 +02007600
Victor Stinner35f3d242017-04-21 12:35:24 +02007601 if test -n "${cc_is_clang}"
7602 then
7603 # Clang also needs -fwrapv
7604 WRAP="-fwrapv"
Victor Stinner9ed34a82017-05-02 22:35:58 +02007605 # bpo-30104: disable strict aliasing to compile correctly dtoa.c,
7606 # see Makefile.pre.in for more information
Victor Stinner826f83f2017-04-28 15:07:10 +02007607 CFLAGS_ALIASING="-fno-strict-aliasing"
Victor Stinner35f3d242017-04-21 12:35:24 +02007608 fi
7609
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007610 case $ac_cv_prog_cc_g in
7611 yes)
7612 if test "$Py_DEBUG" = 'true' ; then
7613 # Optimization messes up debuggers, so turn it off for
7614 # debug builds.
Antoine Pitrou3d6c7842015-02-11 19:39:16 +01007615 if "$CC" -v --help 2>/dev/null |grep -- -Og > /dev/null; then
Victor Stinner28205b22017-04-21 11:24:34 +02007616 OPT="-g -Og -Wall"
Antoine Pitrou3d6c7842015-02-11 19:39:16 +01007617 else
Victor Stinner28205b22017-04-21 11:24:34 +02007618 OPT="-g -O0 -Wall"
Antoine Pitrou3d6c7842015-02-11 19:39:16 +01007619 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007620 else
Victor Stinner28205b22017-04-21 11:24:34 +02007621 OPT="-g $WRAP -O3 -Wall"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007622 fi
7623 ;;
7624 *)
Victor Stinner28205b22017-04-21 11:24:34 +02007625 OPT="-O3 -Wall"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007626 ;;
7627 esac
Victor Stinner28205b22017-04-21 11:24:34 +02007628
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007629 case $ac_sys_system in
7630 SCO_SV*) OPT="$OPT -m486 -DSCO5"
7631 ;;
7632 esac
7633 ;;
7634
7635 *)
7636 OPT="-O"
7637 ;;
7638 esac
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007639fi
7640
7641
7642
Benjamin Petersonacb8c522014-08-09 20:01:49 -07007643
stratakiscf10a752018-12-19 18:19:01 +01007644
Ronald Oussoren41761932020-11-08 10:05:27 +01007645# The -arch flags for universal builds on macOS
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007646UNIVERSAL_ARCH_FLAGS=
7647
7648
7649# tweak BASECFLAGS based on compiler and platform
7650case $GCC in
7651yes)
Benjamin Peterson050af5d2016-09-10 17:53:13 -07007652 CFLAGS_NODIST="$CFLAGS_NODIST -std=c99"
Benjamin Petersond1702562016-09-07 12:00:06 -07007653
Pablo Galindoba421752021-05-03 20:33:17 +01007654 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -Wextra" >&5
7655printf %s "checking for -Wextra... " >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007656 ac_save_cc="$CC"
7657 CC="$CC -Wextra -Werror"
Pablo Galindoba421752021-05-03 20:33:17 +01007658 if test ${ac_cv_extra_warnings+y}
7659then :
7660 printf %s "(cached) " >&6
7661else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7663/* end confdefs.h. */
7664
7665
7666int
Pablo Galindoba421752021-05-03 20:33:17 +01007667main (void)
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007668{
7669
7670 ;
7671 return 0;
7672}
7673
7674_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007675if ac_fn_c_try_compile "$LINENO"
7676then :
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007677
7678 ac_cv_extra_warnings=yes
7679
Pablo Galindoba421752021-05-03 20:33:17 +01007680else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007681
7682 ac_cv_extra_warnings=no
7683
7684fi
Pablo Galindoba421752021-05-03 20:33:17 +01007685rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007686fi
7687
7688 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007689 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_extra_warnings" >&5
7690printf "%s\n" "$ac_cv_extra_warnings" >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007691
7692 if test $ac_cv_extra_warnings = yes
7693 then
7694 CFLAGS_NODIST="$CFLAGS_NODIST -Wextra"
7695 fi
7696
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007697 # Python doesn't violate C99 aliasing rules, but older versions of
7698 # GCC produce warnings for legal Python code. Enable
7699 # -fno-strict-aliasing on versions of GCC that support but produce
7700 # warnings. See Issue3326
Pablo Galindoba421752021-05-03 20:33:17 +01007701 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5
7702printf %s "checking whether $CC accepts and needs -fno-strict-aliasing... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007703 ac_save_cc="$CC"
7704 CC="$CC -fno-strict-aliasing"
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007705 save_CFLAGS="$CFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +01007706 if test ${ac_cv_no_strict_aliasing+y}
7707then :
7708 printf %s "(cached) " >&6
7709else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00007710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007711/* end confdefs.h. */
Gregory P. Smithe0450c62009-11-01 21:11:36 +00007712
Matthias Kloseb159a552010-04-25 21:00:44 +00007713
Gregory P. Smithe0450c62009-11-01 21:11:36 +00007714int
Pablo Galindoba421752021-05-03 20:33:17 +01007715main (void)
Gregory P. Smithe0450c62009-11-01 21:11:36 +00007716{
Mark Dickinson8c2b6f12010-05-11 09:23:07 +00007717
Gregory P. Smithe0450c62009-11-01 21:11:36 +00007718 ;
7719 return 0;
7720}
Matthias Kloseb159a552010-04-25 21:00:44 +00007721
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007722_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007723if ac_fn_c_try_compile "$LINENO"
7724then :
Matthias Kloseb159a552010-04-25 21:00:44 +00007725
7726 CC="$ac_save_cc -fstrict-aliasing"
7727 CFLAGS="$CFLAGS -Werror -Wstrict-aliasing"
7728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007729/* end confdefs.h. */
7730
Mark Dickinson8c2b6f12010-05-11 09:23:07 +00007731 void f(int **x) {}
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007732int
Pablo Galindoba421752021-05-03 20:33:17 +01007733main (void)
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007734{
Mark Dickinson8c2b6f12010-05-11 09:23:07 +00007735double *x; f((int **) &x);
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007736 ;
7737 return 0;
7738}
Matthias Kloseb159a552010-04-25 21:00:44 +00007739
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007740_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007741if ac_fn_c_try_compile "$LINENO"
7742then :
Matthias Kloseb159a552010-04-25 21:00:44 +00007743
7744 ac_cv_no_strict_aliasing=no
7745
Pablo Galindoba421752021-05-03 20:33:17 +01007746else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +00007747
7748 ac_cv_no_strict_aliasing=yes
7749
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007750fi
Pablo Galindoba421752021-05-03 20:33:17 +01007751rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb159a552010-04-25 21:00:44 +00007752
Pablo Galindoba421752021-05-03 20:33:17 +01007753else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +00007754
7755 ac_cv_no_strict_aliasing=no
7756
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007757fi
Pablo Galindoba421752021-05-03 20:33:17 +01007758rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +00007759fi
7760
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007761 CFLAGS="$save_CFLAGS"
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007762 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5
7764printf "%s\n" "$ac_cv_no_strict_aliasing" >&6; }
Benjamin Petersone6c9d242010-03-30 17:34:47 +00007765 if test $ac_cv_no_strict_aliasing = yes
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00007766 then
7767 BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
7768 fi
7769
Zachary Ware5af85642015-12-21 12:09:17 -06007770 # ICC doesn't recognize the option, but only emits a warning
7771 ## XXX does it emit an unused result warning and can it be disabled?
7772 case "$CC" in
7773 *icc*)
7774 ac_cv_disable_unused_result_warning=no
7775 ;;
7776 *)
Pablo Galindoba421752021-05-03 20:33:17 +01007777 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC unused result warning" >&5
7778printf %s "checking if we can turn off $CC unused result warning... " >&6; }
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007779 ac_save_cc="$CC"
7780 CC="$CC -Wunused-result -Werror"
7781 save_CFLAGS="$CFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +01007782 if test ${ac_cv_disable_unused_result_warning+y}
7783then :
7784 printf %s "(cached) " >&6
7785else $as_nop
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7787/* end confdefs.h. */
7788
7789
7790int
Pablo Galindoba421752021-05-03 20:33:17 +01007791main (void)
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007792{
7793
7794 ;
7795 return 0;
7796}
7797
7798_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007799if ac_fn_c_try_compile "$LINENO"
7800then :
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007801
7802 ac_cv_disable_unused_result_warning=yes
7803
Pablo Galindoba421752021-05-03 20:33:17 +01007804else $as_nop
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007805
7806 ac_cv_disable_unused_result_warning=no
7807
7808fi
Pablo Galindoba421752021-05-03 20:33:17 +01007809rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007810fi
7811
7812 CFLAGS="$save_CFLAGS"
7813 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007814 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_unused_result_warning" >&5
7815printf "%s\n" "$ac_cv_disable_unused_result_warning" >&6; }
Zachary Ware5af85642015-12-21 12:09:17 -06007816 ;;
7817 esac
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007818
7819 if test $ac_cv_disable_unused_result_warning = yes
7820 then
7821 BASECFLAGS="$BASECFLAGS -Wno-unused-result"
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007822 CFLAGS_NODIST="$CFLAGS_NODIST -Wno-unused-result"
7823 fi
7824
Pablo Galindoba421752021-05-03 20:33:17 +01007825 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC unused parameter warning" >&5
7826printf %s "checking if we can turn off $CC unused parameter warning... " >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007827 ac_save_cc="$CC"
7828 CC="$CC -Wunused-parameter -Werror"
Pablo Galindoba421752021-05-03 20:33:17 +01007829 if test ${ac_cv_disable_unused_parameter_warning+y}
7830then :
7831 printf %s "(cached) " >&6
7832else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7834/* end confdefs.h. */
7835
7836
7837int
Pablo Galindoba421752021-05-03 20:33:17 +01007838main (void)
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007839{
7840
7841 ;
7842 return 0;
7843}
7844
7845_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007846if ac_fn_c_try_compile "$LINENO"
7847then :
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007848
7849 ac_cv_disable_unused_parameter_warning=yes
7850
Pablo Galindoba421752021-05-03 20:33:17 +01007851else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007852
7853 ac_cv_disable_unused_parameter_warning=no
7854
7855fi
Pablo Galindoba421752021-05-03 20:33:17 +01007856rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007857fi
7858
7859 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007860 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_unused_parameter_warning" >&5
7861printf "%s\n" "$ac_cv_disable_unused_parameter_warning" >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007862
7863 if test $ac_cv_disable_unused_parameter_warning = yes
7864 then
7865 CFLAGS_NODIST="$CFLAGS_NODIST -Wno-unused-parameter"
7866 fi
7867
Pablo Galindoba421752021-05-03 20:33:17 +01007868 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC missing field initializers warning" >&5
7869printf %s "checking if we can turn off $CC missing field initializers warning... " >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007870 ac_save_cc="$CC"
7871 CC="$CC -Wmissing-field-initializers -Werror"
Pablo Galindoba421752021-05-03 20:33:17 +01007872 if test ${ac_cv_disable_missing_field_initializers+y}
7873then :
7874 printf %s "(cached) " >&6
7875else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7877/* end confdefs.h. */
7878
7879
7880int
Pablo Galindoba421752021-05-03 20:33:17 +01007881main (void)
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007882{
7883
7884 ;
7885 return 0;
7886}
7887
7888_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007889if ac_fn_c_try_compile "$LINENO"
7890then :
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007891
7892 ac_cv_disable_missing_field_initializers=yes
7893
Pablo Galindoba421752021-05-03 20:33:17 +01007894else $as_nop
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007895
7896 ac_cv_disable_missing_field_initializers=no
7897
7898fi
Pablo Galindoba421752021-05-03 20:33:17 +01007899rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007900fi
7901
7902 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007903 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_missing_field_initializers" >&5
7904printf "%s\n" "$ac_cv_disable_missing_field_initializers" >&6; }
Serhiy Storchakaea80ffb2016-09-11 21:56:32 +03007905
7906 if test $ac_cv_disable_missing_field_initializers = yes
7907 then
7908 CFLAGS_NODIST="$CFLAGS_NODIST -Wno-missing-field-initializers"
Benjamin Peterson7ddbf102011-09-23 13:23:22 -04007909 fi
7910
Pablo Galindoba421752021-05-03 20:33:17 +01007911 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC mixed sign comparison warning" >&5
7912printf %s "checking if we can turn on $CC mixed sign comparison warning... " >&6; }
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007913 ac_save_cc="$CC"
7914 CC="$CC -Wsign-compare"
7915 save_CFLAGS="$CFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +01007916 if test ${ac_cv_enable_sign_compare_warning+y}
7917then :
7918 printf %s "(cached) " >&6
7919else $as_nop
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7921/* end confdefs.h. */
7922
7923
7924int
Pablo Galindoba421752021-05-03 20:33:17 +01007925main (void)
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007926{
7927
7928 ;
7929 return 0;
7930}
7931
7932_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007933if ac_fn_c_try_compile "$LINENO"
7934then :
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007935
7936 ac_cv_enable_sign_compare_warning=yes
7937
Pablo Galindoba421752021-05-03 20:33:17 +01007938else $as_nop
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007939
7940 ac_cv_enable_sign_compare_warning=no
7941
7942fi
Pablo Galindoba421752021-05-03 20:33:17 +01007943rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007944fi
7945
7946 CFLAGS="$save_CFLAGS"
7947 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01007948 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_sign_compare_warning" >&5
7949printf "%s\n" "$ac_cv_enable_sign_compare_warning" >&6; }
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007950
7951 if test $ac_cv_enable_sign_compare_warning = yes
7952 then
7953 BASECFLAGS="$BASECFLAGS -Wsign-compare"
7954 fi
7955
Pablo Galindoba421752021-05-03 20:33:17 +01007956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC unreachable code warning" >&5
7957printf %s "checking if we can turn on $CC unreachable code warning... " >&6; }
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007958 ac_save_cc="$CC"
7959 CC="$CC -Wunreachable-code"
7960 save_CFLAGS="$CFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +01007961 if test ${ac_cv_enable_unreachable_code_warning+y}
7962then :
7963 printf %s "(cached) " >&6
7964else $as_nop
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7966/* end confdefs.h. */
7967
7968
7969int
Pablo Galindoba421752021-05-03 20:33:17 +01007970main (void)
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007971{
7972
7973 ;
7974 return 0;
7975}
7976
7977_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01007978if ac_fn_c_try_compile "$LINENO"
7979then :
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007980
7981 ac_cv_enable_unreachable_code_warning=yes
7982
Pablo Galindoba421752021-05-03 20:33:17 +01007983else $as_nop
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007984
7985 ac_cv_enable_unreachable_code_warning=no
7986
7987fi
Pablo Galindoba421752021-05-03 20:33:17 +01007988rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007989fi
7990
7991 CFLAGS="$save_CFLAGS"
7992 CC="$ac_save_cc"
Charles-François Natali7f9cc932014-08-01 21:57:49 +01007993
7994 # Don't enable unreachable code warning in debug mode, since it usually
7995 # results in non-standard code paths.
Ned Deilybec699e2016-03-08 00:28:37 -05007996 # Issue #24324: Unfortunately, the unreachable code warning does not work
7997 # correctly on gcc and has been silently removed from the compiler.
7998 # It is supported on clang but on OS X systems gcc may be an alias
7999 # for clang. Try to determine if the compiler is not really gcc and,
8000 # if so, only then enable the warning.
8001 if test $ac_cv_enable_unreachable_code_warning = yes && \
8002 test "$Py_DEBUG" != "true" && \
8003 test -z "`$CC --version 2>/dev/null | grep 'Free Software Foundation'`"
Charles-François Natali7f9cc932014-08-01 21:57:49 +01008004 then
8005 BASECFLAGS="$BASECFLAGS -Wunreachable-code"
Ned Deilybec699e2016-03-08 00:28:37 -05008006 else
8007 ac_cv_enable_unreachable_code_warning=no
Charles-François Natali7f9cc932014-08-01 21:57:49 +01008008 fi
Pablo Galindoba421752021-05-03 20:33:17 +01008009 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_unreachable_code_warning" >&5
8010printf "%s\n" "$ac_cv_enable_unreachable_code_warning" >&6; }
Charles-François Natali7f9cc932014-08-01 21:57:49 +01008011
Pablo Galindoba421752021-05-03 20:33:17 +01008012 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC strict-prototypes warning" >&5
8013printf %s "checking if we can turn on $CC strict-prototypes warning... " >&6; }
INADA Naokie3364842018-06-05 20:40:53 +09008014 ac_save_cc="$CC"
8015 CC="$CC -Werror -Wstrict-prototypes"
Pablo Galindoba421752021-05-03 20:33:17 +01008016 if test ${ac_cv_enable_enable_strict_prototypes_warning+y}
8017then :
8018 printf %s "(cached) " >&6
8019else $as_nop
INADA Naokie3364842018-06-05 20:40:53 +09008020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8021/* end confdefs.h. */
8022
8023
8024int
Pablo Galindoba421752021-05-03 20:33:17 +01008025main (void)
INADA Naokie3364842018-06-05 20:40:53 +09008026{
8027
8028 ;
8029 return 0;
8030}
8031
8032_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008033if ac_fn_c_try_compile "$LINENO"
8034then :
INADA Naokie3364842018-06-05 20:40:53 +09008035
8036 ac_cv_enable_strict_prototypes_warning=yes
8037
Pablo Galindoba421752021-05-03 20:33:17 +01008038else $as_nop
INADA Naokie3364842018-06-05 20:40:53 +09008039
8040 ac_cv_enable_strict_prototypes_warning=no
8041
8042fi
Pablo Galindoba421752021-05-03 20:33:17 +01008043rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
INADA Naokie3364842018-06-05 20:40:53 +09008044fi
8045
8046 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01008047 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_strict_prototypes_warning" >&5
8048printf "%s\n" "$ac_cv_enable_strict_prototypes_warning" >&6; }
INADA Naokie3364842018-06-05 20:40:53 +09008049
8050 if test $ac_cv_enable_strict_prototypes_warning = yes
8051 then
8052 CFLAGS_NODIST="$CFLAGS_NODIST -Wstrict-prototypes"
8053 fi
8054
Pablo Galindoba421752021-05-03 20:33:17 +01008055 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can make implicit function declaration an error in $CC" >&5
8056printf %s "checking if we can make implicit function declaration an error in $CC... " >&6; }
Victor Stinner193ee0a2017-02-06 14:24:00 +01008057 ac_save_cc="$CC"
8058 CC="$CC -Werror=implicit-function-declaration"
Pablo Galindoba421752021-05-03 20:33:17 +01008059 if test ${ac_cv_enable_implicit_function_declaration_error+y}
8060then :
8061 printf %s "(cached) " >&6
8062else $as_nop
Victor Stinner193ee0a2017-02-06 14:24:00 +01008063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8064/* end confdefs.h. */
8065
8066
8067int
Pablo Galindoba421752021-05-03 20:33:17 +01008068main (void)
Victor Stinner193ee0a2017-02-06 14:24:00 +01008069{
8070
8071 ;
8072 return 0;
8073}
8074
8075_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008076if ac_fn_c_try_compile "$LINENO"
8077then :
Victor Stinner193ee0a2017-02-06 14:24:00 +01008078
8079 ac_cv_enable_implicit_function_declaration_error=yes
8080
Pablo Galindoba421752021-05-03 20:33:17 +01008081else $as_nop
Victor Stinner193ee0a2017-02-06 14:24:00 +01008082
8083 ac_cv_enable_implicit_function_declaration_error=no
8084
8085fi
Pablo Galindoba421752021-05-03 20:33:17 +01008086rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Victor Stinner193ee0a2017-02-06 14:24:00 +01008087fi
8088
8089 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01008090 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_implicit_function_declaration_error" >&5
8091printf "%s\n" "$ac_cv_enable_implicit_function_declaration_error" >&6; }
Victor Stinner193ee0a2017-02-06 14:24:00 +01008092
8093 if test $ac_cv_enable_implicit_function_declaration_error = yes
8094 then
8095 CFLAGS_NODIST="$CFLAGS_NODIST -Werror=implicit-function-declaration"
8096 fi
8097
Pablo Galindoba421752021-05-03 20:33:17 +01008098 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can use visibility in $CC" >&5
8099printf %s "checking if we can use visibility in $CC... " >&6; }
Vinay Sajip0b60f642019-10-15 08:26:12 +01008100 ac_save_cc="$CC"
8101 CC="$CC -fvisibility=hidden"
Pablo Galindoba421752021-05-03 20:33:17 +01008102 if test ${ac_cv_enable_visibility+y}
8103then :
8104 printf %s "(cached) " >&6
8105else $as_nop
Vinay Sajip0b60f642019-10-15 08:26:12 +01008106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8107/* end confdefs.h. */
8108
8109
8110int
Pablo Galindoba421752021-05-03 20:33:17 +01008111main (void)
Vinay Sajip0b60f642019-10-15 08:26:12 +01008112{
8113
8114 ;
8115 return 0;
8116}
8117
8118_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008119if ac_fn_c_try_compile "$LINENO"
8120then :
Vinay Sajip0b60f642019-10-15 08:26:12 +01008121
8122 ac_cv_enable_visibility=yes
8123
Pablo Galindoba421752021-05-03 20:33:17 +01008124else $as_nop
Vinay Sajip0b60f642019-10-15 08:26:12 +01008125
8126 ac_cv_enable_visibility=no
8127
8128fi
Pablo Galindoba421752021-05-03 20:33:17 +01008129rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Vinay Sajip0b60f642019-10-15 08:26:12 +01008130fi
8131
8132 CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +01008133 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_visibility" >&5
8134printf "%s\n" "$ac_cv_enable_visibility" >&6; }
Vinay Sajip0b60f642019-10-15 08:26:12 +01008135
8136 if test $ac_cv_enable_visibility = yes
8137 then
8138 CFLAGS_NODIST="$CFLAGS_NODIST -fvisibility=hidden"
8139 fi
8140
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008141 # if using gcc on alpha, use -mieee to get (near) full IEEE 754
8142 # support. Without this, treatment of subnormals doesn't follow
8143 # the standard.
Matthias Klosedf2aecb2012-03-15 22:19:28 +01008144 case $host in
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008145 alpha*)
8146 BASECFLAGS="$BASECFLAGS -mieee"
8147 ;;
8148 esac
8149
8150 case $ac_sys_system in
8151 SCO_SV*)
8152 BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
8153 ;;
Ned Deily87adb6e2013-10-18 21:09:56 -07008154
Ned Deily87adb6e2013-10-18 21:09:56 -07008155 Darwin*)
8156 # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
8157 # used to be here, but non-Apple gcc doesn't accept them.
8158 if test "${CC}" = gcc
8159 then
Pablo Galindoba421752021-05-03 20:33:17 +01008160 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5
8161printf %s "checking which compiler should be used... " >&6; }
Ned Deily87adb6e2013-10-18 21:09:56 -07008162 case "${UNIVERSALSDK}" in
8163 */MacOSX10.4u.sdk)
8164 # Build using 10.4 SDK, force usage of gcc when the
8165 # compiler is gcc, otherwise the user will get very
8166 # confusing error messages when building on OSX 10.6
8167 CC=gcc-4.0
8168 CPP=cpp-4.0
8169 ;;
8170 esac
Pablo Galindoba421752021-05-03 20:33:17 +01008171 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
8172printf "%s\n" "$CC" >&6; }
Ned Deily87adb6e2013-10-18 21:09:56 -07008173 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008174
Ned Deily0cb33da2021-05-02 04:48:29 -04008175 LIPO_INTEL64_FLAGS=""
Ned Deily87adb6e2013-10-18 21:09:56 -07008176 if test "${enable_universalsdk}"
8177 then
8178 case "$UNIVERSAL_ARCHS" in
8179 32-bit)
8180 UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386"
8181 LIPO_32BIT_FLAGS=""
8182 ARCH_RUN_32BIT=""
8183 ;;
8184 64-bit)
8185 UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64"
8186 LIPO_32BIT_FLAGS=""
8187 ARCH_RUN_32BIT="true"
8188 ;;
8189 all)
8190 UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64"
8191 LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386"
8192 ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc"
8193 ;;
Ronald Oussoren41761932020-11-08 10:05:27 +01008194 universal2)
8195 UNIVERSAL_ARCH_FLAGS="-arch arm64 -arch x86_64"
8196 LIPO_32BIT_FLAGS=""
Ned Deily0cb33da2021-05-02 04:48:29 -04008197 LIPO_INTEL64_FLAGS="-extract x86_64"
Ronald Oussoren41761932020-11-08 10:05:27 +01008198 ARCH_RUN_32BIT="true"
Ned Deily0cb33da2021-05-02 04:48:29 -04008199 ;;
Ned Deily87adb6e2013-10-18 21:09:56 -07008200 intel)
8201 UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64"
8202 LIPO_32BIT_FLAGS="-extract i386"
8203 ARCH_RUN_32BIT="/usr/bin/arch -i386"
8204 ;;
8205 intel-32)
8206 UNIVERSAL_ARCH_FLAGS="-arch i386"
8207 LIPO_32BIT_FLAGS=""
8208 ARCH_RUN_32BIT=""
8209 ;;
Ned Deily8c9bb722018-01-30 07:42:14 -05008210 intel-64)
8211 UNIVERSAL_ARCH_FLAGS="-arch x86_64"
8212 LIPO_32BIT_FLAGS=""
8213 ARCH_RUN_32BIT="true"
8214 ;;
Ned Deily87adb6e2013-10-18 21:09:56 -07008215 3-way)
8216 UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64"
8217 LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386"
8218 ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc"
8219 ;;
8220 *)
Ronald Oussoren41761932020-11-08 10:05:27 +01008221 as_fn_error $? "proper usage is --with-universal-arch=universal2|32-bit|64-bit|all|intel|3-way" "$LINENO" 5
Ned Deily87adb6e2013-10-18 21:09:56 -07008222 ;;
8223 esac
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008224
Ned Deily87adb6e2013-10-18 21:09:56 -07008225 if test "${UNIVERSALSDK}" != "/"
8226 then
Ned Deily8c9bb722018-01-30 07:42:14 -05008227 CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
8228 LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}"
Ned Deily87adb6e2013-10-18 21:09:56 -07008229 CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}"
Ned Deily8c9bb722018-01-30 07:42:14 -05008230 else
8231 CFLAGS="${UNIVERSAL_ARCH_FLAGS} ${CFLAGS}"
8232 LDFLAGS="${UNIVERSAL_ARCH_FLAGS} ${LDFLAGS}"
Ned Deily87adb6e2013-10-18 21:09:56 -07008233 fi
8234 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008235
Ned Deily87adb6e2013-10-18 21:09:56 -07008236 # Calculate an appropriate deployment target for this build:
8237 # The deployment target value is used explicitly to enable certain
8238 # features are enabled (such as builtin libedit support for readline)
Raymond Hettinger15f44ab2016-08-30 10:47:49 -07008239 # through the use of Apple's Availability Macros and is used as a
Ned Deily87adb6e2013-10-18 21:09:56 -07008240 # component of the string returned by distutils.get_platform().
8241 #
8242 # Use the value from:
8243 # 1. the MACOSX_DEPLOYMENT_TARGET environment variable if specified
8244 # 2. the operating system version of the build machine if >= 10.6
8245 # 3. If running on OS X 10.3 through 10.5, use the legacy tests
8246 # below to pick either 10.3, 10.4, or 10.5 as the target.
8247 # 4. If we are running on OS X 10.2 or earlier, good luck!
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008248
Pablo Galindoba421752021-05-03 20:33:17 +01008249 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which MACOSX_DEPLOYMENT_TARGET to use" >&5
8250printf %s "checking which MACOSX_DEPLOYMENT_TARGET to use... " >&6; }
Ned Deily36820b62014-06-25 13:44:22 -07008251 cur_target_major=`sw_vers -productVersion | \
8252 sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'`
8253 cur_target_minor=`sw_vers -productVersion | \
8254 sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'`
8255 cur_target="${cur_target_major}.${cur_target_minor}"
8256 if test ${cur_target_major} -eq 10 && \
8257 test ${cur_target_minor} -ge 3 && \
8258 test ${cur_target_minor} -le 5
Ned Deily87adb6e2013-10-18 21:09:56 -07008259 then
Ned Deily36820b62014-06-25 13:44:22 -07008260 # OS X 10.3 through 10.5
Ned Deily87adb6e2013-10-18 21:09:56 -07008261 cur_target=10.3
8262 if test ${enable_universalsdk}
8263 then
8264 case "$UNIVERSAL_ARCHS" in
8265 all|3-way|intel|64-bit)
8266 # These configurations were first supported in 10.5
8267 cur_target='10.5'
8268 ;;
8269 esac
8270 else
8271 if test `/usr/bin/arch` = "i386"
8272 then
8273 # 10.4 was the first release to support Intel archs
8274 cur_target="10.4"
8275 fi
8276 fi
8277 fi
8278 CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
Ronald Oussoren3c064c12009-09-08 07:12:42 +00008279
Ned Deily87adb6e2013-10-18 21:09:56 -07008280 # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
8281 # environment with a value that is the same as what we'll use
8282 # in the Makefile to ensure that we'll get the same compiler
8283 # environment during configure and build time.
8284 MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
8285 export MACOSX_DEPLOYMENT_TARGET
8286 EXPORT_MACOSX_DEPLOYMENT_TARGET=''
Pablo Galindoba421752021-05-03 20:33:17 +01008287 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MACOSX_DEPLOYMENT_TARGET" >&5
8288printf "%s\n" "$MACOSX_DEPLOYMENT_TARGET" >&6; }
Ronald Oussoren3c064c12009-09-08 07:12:42 +00008289
Pablo Galindoba421752021-05-03 20:33:17 +01008290 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if specified universal architectures work" >&5
8291printf %s "checking if specified universal architectures work... " >&6; }
Ronald Oussoren0f20bd92020-11-22 02:13:11 +01008292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8293/* end confdefs.h. */
8294#include <stdio.h>
8295int
Pablo Galindoba421752021-05-03 20:33:17 +01008296main (void)
Ronald Oussoren0f20bd92020-11-22 02:13:11 +01008297{
8298printf("%d", 42);
8299 ;
8300 return 0;
8301}
8302_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008303if ac_fn_c_try_link "$LINENO"
8304then :
8305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8306printf "%s\n" "yes" >&6; }
8307else $as_nop
8308 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8309printf "%s\n" "no" >&6; }
Ronald Oussoren0f20bd92020-11-22 02:13:11 +01008310 as_fn_error $? "check config.log and use the '--with-universal-archs' option" "$LINENO" 5
8311
8312fi
Pablo Galindoba421752021-05-03 20:33:17 +01008313rm -f core conftest.err conftest.$ac_objext conftest.beam \
Ronald Oussoren0f20bd92020-11-22 02:13:11 +01008314 conftest$ac_exeext conftest.$ac_ext
8315
Ned Deily87adb6e2013-10-18 21:09:56 -07008316 # end of Darwin* tests
8317 ;;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008318 esac
8319 ;;
8320
8321*)
8322 case $ac_sys_system in
8323 OpenUNIX*|UnixWare*)
8324 BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
8325 ;;
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008326 SCO_SV*)
8327 BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
8328 ;;
8329 esac
8330 ;;
8331esac
8332
Zachary Ware5af85642015-12-21 12:09:17 -06008333case "$CC" in
8334*icc*)
Stefan Krah84a79172020-09-04 22:33:17 +02008335 # ICC needs -fp-model strict or floats behave badly
Zachary Ware5af85642015-12-21 12:09:17 -06008336 CFLAGS_NODIST="$CFLAGS_NODIST -fp-model strict"
8337 ;;
Stefan Krah84a79172020-09-04 22:33:17 +02008338*xlc*)
8339 CFLAGS_NODIST="$CFLAGS_NODIST -qalias=noansi -qmaxmem=-1"
8340 ;;
Zachary Ware5af85642015-12-21 12:09:17 -06008341esac
8342
T. Woutersddbfa2c2017-05-23 01:30:49 +02008343if test "$assertions" = 'true'; then
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008344 :
8345else
8346 OPT="-DNDEBUG $OPT"
8347fi
8348
8349if test "$ac_arch_flags"
8350then
8351 BASECFLAGS="$BASECFLAGS $ac_arch_flags"
8352fi
8353
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008354# On some compilers, pthreads are available without further options
8355# (e.g. MacOS X). On some of these systems, the compiler will not
8356# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
8357# So we have to see first whether pthreads are available without
8358# options before we can check whether -Kpthread improves anything.
Pablo Galindoba421752021-05-03 20:33:17 +01008359{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5
8360printf %s "checking whether pthreads are available without options... " >&6; }
8361if test ${ac_cv_pthread_is_default+y}
8362then :
8363 printf %s "(cached) " >&6
8364else $as_nop
8365 if test "$cross_compiling" = yes
8366then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008367 ac_cv_pthread_is_default=no
Pablo Galindoba421752021-05-03 20:33:17 +01008368else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008370/* end confdefs.h. */
8371
Stefan Krah7dba5942012-11-22 22:49:11 +01008372#include <stdio.h>
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008373#include <pthread.h>
8374
8375void* routine(void* p){return NULL;}
8376
8377int main(){
8378 pthread_t p;
8379 if(pthread_create(&p,NULL,routine,NULL)!=0)
8380 return 1;
8381 (void)pthread_detach(p);
8382 return 0;
8383}
8384
8385_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008386if ac_fn_c_try_run "$LINENO"
8387then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008388
8389 ac_cv_pthread_is_default=yes
8390 ac_cv_kthread=no
8391 ac_cv_pthread=no
8392
Pablo Galindoba421752021-05-03 20:33:17 +01008393else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008394 ac_cv_pthread_is_default=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008395fi
Matthias Kloseb9621712010-04-24 17:59:49 +00008396rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8397 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008398fi
8399
8400
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008401fi
8402
Pablo Galindoba421752021-05-03 20:33:17 +01008403{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5
8404printf "%s\n" "$ac_cv_pthread_is_default" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008405
8406
8407if test $ac_cv_pthread_is_default = yes
8408then
8409 ac_cv_kpthread=no
8410else
8411# -Kpthread, if available, provides the right #defines
8412# and linker options to make pthread_create available
8413# Some compilers won't report that they do not support -Kpthread,
8414# so we need to run a program to see whether it really made the
8415# function available.
Pablo Galindoba421752021-05-03 20:33:17 +01008416{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5
8417printf %s "checking whether $CC accepts -Kpthread... " >&6; }
8418if test ${ac_cv_kpthread+y}
8419then :
8420 printf %s "(cached) " >&6
8421else $as_nop
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008422 ac_save_cc="$CC"
8423CC="$CC -Kpthread"
Pablo Galindoba421752021-05-03 20:33:17 +01008424if test "$cross_compiling" = yes
8425then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008426 ac_cv_kpthread=no
Pablo Galindoba421752021-05-03 20:33:17 +01008427else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008429/* end confdefs.h. */
8430
Stefan Krah7dba5942012-11-22 22:49:11 +01008431#include <stdio.h>
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008432#include <pthread.h>
8433
8434void* routine(void* p){return NULL;}
8435
8436int main(){
8437 pthread_t p;
8438 if(pthread_create(&p,NULL,routine,NULL)!=0)
8439 return 1;
8440 (void)pthread_detach(p);
8441 return 0;
8442}
8443
8444_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008445if ac_fn_c_try_run "$LINENO"
8446then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008447 ac_cv_kpthread=yes
Pablo Galindoba421752021-05-03 20:33:17 +01008448else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008449 ac_cv_kpthread=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008450fi
Matthias Kloseb9621712010-04-24 17:59:49 +00008451rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8452 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008453fi
8454
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008455CC="$ac_save_cc"
8456fi
8457
Pablo Galindoba421752021-05-03 20:33:17 +01008458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5
8459printf "%s\n" "$ac_cv_kpthread" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008460fi
8461
8462if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no
8463then
8464# -Kthread, if available, provides the right #defines
8465# and linker options to make pthread_create available
8466# Some compilers won't report that they do not support -Kthread,
8467# so we need to run a program to see whether it really made the
8468# function available.
Pablo Galindoba421752021-05-03 20:33:17 +01008469{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5
8470printf %s "checking whether $CC accepts -Kthread... " >&6; }
8471if test ${ac_cv_kthread+y}
8472then :
8473 printf %s "(cached) " >&6
8474else $as_nop
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008475 ac_save_cc="$CC"
8476CC="$CC -Kthread"
Pablo Galindoba421752021-05-03 20:33:17 +01008477if test "$cross_compiling" = yes
8478then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008479 ac_cv_kthread=no
Pablo Galindoba421752021-05-03 20:33:17 +01008480else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008482/* end confdefs.h. */
8483
Stefan Krah7dba5942012-11-22 22:49:11 +01008484#include <stdio.h>
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008485#include <pthread.h>
8486
8487void* routine(void* p){return NULL;}
8488
8489int main(){
8490 pthread_t p;
8491 if(pthread_create(&p,NULL,routine,NULL)!=0)
8492 return 1;
8493 (void)pthread_detach(p);
8494 return 0;
8495}
8496
8497_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008498if ac_fn_c_try_run "$LINENO"
8499then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008500 ac_cv_kthread=yes
Pablo Galindoba421752021-05-03 20:33:17 +01008501else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008502 ac_cv_kthread=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008503fi
Matthias Kloseb9621712010-04-24 17:59:49 +00008504rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8505 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008506fi
8507
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008508CC="$ac_save_cc"
8509fi
8510
Pablo Galindoba421752021-05-03 20:33:17 +01008511{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5
8512printf "%s\n" "$ac_cv_kthread" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008513fi
8514
8515if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no
8516then
8517# -pthread, if available, provides the right #defines
8518# and linker options to make pthread_create available
8519# Some compilers won't report that they do not support -pthread,
8520# so we need to run a program to see whether it really made the
8521# function available.
Pablo Galindoba421752021-05-03 20:33:17 +01008522{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5
8523printf %s "checking whether $CC accepts -pthread... " >&6; }
8524if test ${ac_cv_pthread+y}
8525then :
8526 printf %s "(cached) " >&6
8527else $as_nop
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008528 ac_save_cc="$CC"
8529CC="$CC -pthread"
Pablo Galindoba421752021-05-03 20:33:17 +01008530if test "$cross_compiling" = yes
8531then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008532 ac_cv_pthread=no
Pablo Galindoba421752021-05-03 20:33:17 +01008533else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008535/* end confdefs.h. */
8536
Stefan Krah7dba5942012-11-22 22:49:11 +01008537#include <stdio.h>
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008538#include <pthread.h>
8539
8540void* routine(void* p){return NULL;}
8541
8542int main(){
8543 pthread_t p;
8544 if(pthread_create(&p,NULL,routine,NULL)!=0)
8545 return 1;
8546 (void)pthread_detach(p);
8547 return 0;
8548}
8549
8550_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01008551if ac_fn_c_try_run "$LINENO"
8552then :
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008553 ac_cv_pthread=yes
Pablo Galindoba421752021-05-03 20:33:17 +01008554else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00008555 ac_cv_pthread=no
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008556fi
Matthias Kloseb9621712010-04-24 17:59:49 +00008557rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8558 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008559fi
8560
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008561CC="$ac_save_cc"
8562fi
8563
Pablo Galindoba421752021-05-03 20:33:17 +01008564{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5
8565printf "%s\n" "$ac_cv_pthread" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008566fi
8567
8568# If we have set a CC compiler flag for thread support then
8569# check if it works for CXX, too.
8570ac_cv_cxx_thread=no
8571if test ! -z "$CXX"
8572then
Pablo Galindoba421752021-05-03 20:33:17 +01008573{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5
8574printf %s "checking whether $CXX also accepts flags for thread support... " >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008575ac_save_cxx="$CXX"
8576
8577if test "$ac_cv_kpthread" = "yes"
8578then
8579 CXX="$CXX -Kpthread"
8580 ac_cv_cxx_thread=yes
8581elif test "$ac_cv_kthread" = "yes"
8582then
8583 CXX="$CXX -Kthread"
8584 ac_cv_cxx_thread=yes
8585elif test "$ac_cv_pthread" = "yes"
8586then
8587 CXX="$CXX -pthread"
8588 ac_cv_cxx_thread=yes
8589fi
8590
8591if test $ac_cv_cxx_thread = yes
8592then
8593 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
8594 $CXX -c conftest.$ac_ext 2>&5
8595 if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
8596 && test -s conftest$ac_exeext && ./conftest$ac_exeext
8597 then
8598 ac_cv_cxx_thread=yes
8599 else
8600 ac_cv_cxx_thread=no
8601 fi
8602 rm -fr conftest*
8603fi
Pablo Galindoba421752021-05-03 20:33:17 +01008604{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5
8605printf "%s\n" "$ac_cv_cxx_thread" >&6; }
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008606fi
8607CXX="$ac_save_cxx"
8608
8609
8610# checks for header files
Pablo Galindoba421752021-05-03 20:33:17 +01008611# Autoupdate added the next two lines to ensure that your configure
8612# script's behavior did not change. They are probably safe to remove.
8613
8614{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
8615printf %s "checking for egrep... " >&6; }
8616if test ${ac_cv_path_EGREP+y}
8617then :
8618 printf %s "(cached) " >&6
8619else $as_nop
8620 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
8621 then ac_cv_path_EGREP="$GREP -E"
8622 else
8623 if test -z "$EGREP"; then
8624 ac_path_EGREP_found=false
8625 # Loop through the user's path and test for each of PROGNAME-LIST
8626 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8627for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8628do
8629 IFS=$as_save_IFS
8630 case $as_dir in #(((
8631 '') as_dir=./ ;;
8632 */) ;;
8633 *) as_dir=$as_dir/ ;;
8634 esac
8635 for ac_prog in egrep
8636 do
8637 for ac_exec_ext in '' $ac_executable_extensions; do
8638 ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
8639 as_fn_executable_p "$ac_path_EGREP" || continue
8640# Check for GNU ac_path_EGREP and select it if it is found.
8641 # Check for GNU $ac_path_EGREP
8642case `"$ac_path_EGREP" --version 2>&1` in
8643*GNU*)
8644 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
8645*)
8646 ac_count=0
8647 printf %s 0123456789 >"conftest.in"
8648 while :
8649 do
8650 cat "conftest.in" "conftest.in" >"conftest.tmp"
8651 mv "conftest.tmp" "conftest.in"
8652 cp "conftest.in" "conftest.nl"
8653 printf "%s\n" 'EGREP' >> "conftest.nl"
8654 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8655 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8656 as_fn_arith $ac_count + 1 && ac_count=$as_val
8657 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
8658 # Best one so far, save it but keep looking for a better one
8659 ac_cv_path_EGREP="$ac_path_EGREP"
8660 ac_path_EGREP_max=$ac_count
8661 fi
8662 # 10*(2^10) chars as input seems more than enough
8663 test $ac_count -gt 10 && break
8664 done
8665 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8666esac
8667
8668 $ac_path_EGREP_found && break 3
8669 done
8670 done
8671 done
8672IFS=$as_save_IFS
8673 if test -z "$ac_cv_path_EGREP"; then
8674 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8675 fi
Alexandre Vassalotti302825b2009-07-17 07:49:53 +00008676else
Pablo Galindoba421752021-05-03 20:33:17 +01008677 ac_cv_path_EGREP=$EGREP
Pablo Galindo53e55292021-04-05 17:38:40 +01008678fi
Pablo Galindo53e55292021-04-05 17:38:40 +01008679
Pablo Galindoba421752021-05-03 20:33:17 +01008680 fi
Pablo Galindo53e55292021-04-05 17:38:40 +01008681fi
Pablo Galindoba421752021-05-03 20:33:17 +01008682{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
8683printf "%s\n" "$ac_cv_path_EGREP" >&6; }
8684 EGREP="$ac_cv_path_EGREP"
8685
8686
8687
8688ac_fn_c_check_header_compile "$LINENO" "asm/types.h" "ac_cv_header_asm_types_h" "$ac_includes_default"
8689if test "x$ac_cv_header_asm_types_h" = xyes
8690then :
8691 printf "%s\n" "#define HAVE_ASM_TYPES_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01008692
8693fi
Pablo Galindoba421752021-05-03 20:33:17 +01008694ac_fn_c_check_header_compile "$LINENO" "crypt.h" "ac_cv_header_crypt_h" "$ac_includes_default"
8695if test "x$ac_cv_header_crypt_h" = xyes
8696then :
8697 printf "%s\n" "#define HAVE_CRYPT_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01008698
8699fi
Pablo Galindoba421752021-05-03 20:33:17 +01008700ac_fn_c_check_header_compile "$LINENO" "conio.h" "ac_cv_header_conio_h" "$ac_includes_default"
8701if test "x$ac_cv_header_conio_h" = xyes
8702then :
8703 printf "%s\n" "#define HAVE_CONIO_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01008704
8705fi
Pablo Galindoba421752021-05-03 20:33:17 +01008706ac_fn_c_check_header_compile "$LINENO" "direct.h" "ac_cv_header_direct_h" "$ac_includes_default"
8707if test "x$ac_cv_header_direct_h" = xyes
8708then :
8709 printf "%s\n" "#define HAVE_DIRECT_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01008710
8711fi
Pablo Galindoba421752021-05-03 20:33:17 +01008712ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
8713if test "x$ac_cv_header_dlfcn_h" = xyes
8714then :
8715 printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01008716
Pablo Galindoba421752021-05-03 20:33:17 +01008717fi
8718ac_fn_c_check_header_compile "$LINENO" "errno.h" "ac_cv_header_errno_h" "$ac_includes_default"
8719if test "x$ac_cv_header_errno_h" = xyes
8720then :
8721 printf "%s\n" "#define HAVE_ERRNO_H 1" >>confdefs.h
8722
8723fi
8724ac_fn_c_check_header_compile "$LINENO" "fcntl.h" "ac_cv_header_fcntl_h" "$ac_includes_default"
8725if test "x$ac_cv_header_fcntl_h" = xyes
8726then :
8727 printf "%s\n" "#define HAVE_FCNTL_H 1" >>confdefs.h
8728
8729fi
8730ac_fn_c_check_header_compile "$LINENO" "grp.h" "ac_cv_header_grp_h" "$ac_includes_default"
8731if test "x$ac_cv_header_grp_h" = xyes
8732then :
8733 printf "%s\n" "#define HAVE_GRP_H 1" >>confdefs.h
8734
8735fi
8736ac_fn_c_check_header_compile "$LINENO" "ieeefp.h" "ac_cv_header_ieeefp_h" "$ac_includes_default"
8737if test "x$ac_cv_header_ieeefp_h" = xyes
8738then :
8739 printf "%s\n" "#define HAVE_IEEEFP_H 1" >>confdefs.h
8740
8741fi
8742ac_fn_c_check_header_compile "$LINENO" "io.h" "ac_cv_header_io_h" "$ac_includes_default"
8743if test "x$ac_cv_header_io_h" = xyes
8744then :
8745 printf "%s\n" "#define HAVE_IO_H 1" >>confdefs.h
8746
8747fi
8748ac_fn_c_check_header_compile "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default"
8749if test "x$ac_cv_header_langinfo_h" = xyes
8750then :
8751 printf "%s\n" "#define HAVE_LANGINFO_H 1" >>confdefs.h
8752
8753fi
8754ac_fn_c_check_header_compile "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
8755if test "x$ac_cv_header_libintl_h" = xyes
8756then :
8757 printf "%s\n" "#define HAVE_LIBINTL_H 1" >>confdefs.h
8758
8759fi
8760ac_fn_c_check_header_compile "$LINENO" "process.h" "ac_cv_header_process_h" "$ac_includes_default"
8761if test "x$ac_cv_header_process_h" = xyes
8762then :
8763 printf "%s\n" "#define HAVE_PROCESS_H 1" >>confdefs.h
8764
8765fi
8766ac_fn_c_check_header_compile "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
8767if test "x$ac_cv_header_pthread_h" = xyes
8768then :
8769 printf "%s\n" "#define HAVE_PTHREAD_H 1" >>confdefs.h
8770
8771fi
8772ac_fn_c_check_header_compile "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default"
8773if test "x$ac_cv_header_sched_h" = xyes
8774then :
8775 printf "%s\n" "#define HAVE_SCHED_H 1" >>confdefs.h
8776
8777fi
8778ac_fn_c_check_header_compile "$LINENO" "shadow.h" "ac_cv_header_shadow_h" "$ac_includes_default"
8779if test "x$ac_cv_header_shadow_h" = xyes
8780then :
8781 printf "%s\n" "#define HAVE_SHADOW_H 1" >>confdefs.h
8782
8783fi
8784ac_fn_c_check_header_compile "$LINENO" "signal.h" "ac_cv_header_signal_h" "$ac_includes_default"
8785if test "x$ac_cv_header_signal_h" = xyes
8786then :
8787 printf "%s\n" "#define HAVE_SIGNAL_H 1" >>confdefs.h
8788
8789fi
8790ac_fn_c_check_header_compile "$LINENO" "stropts.h" "ac_cv_header_stropts_h" "$ac_includes_default"
8791if test "x$ac_cv_header_stropts_h" = xyes
8792then :
8793 printf "%s\n" "#define HAVE_STROPTS_H 1" >>confdefs.h
8794
8795fi
8796ac_fn_c_check_header_compile "$LINENO" "termios.h" "ac_cv_header_termios_h" "$ac_includes_default"
8797if test "x$ac_cv_header_termios_h" = xyes
8798then :
8799 printf "%s\n" "#define HAVE_TERMIOS_H 1" >>confdefs.h
8800
8801fi
8802ac_fn_c_check_header_compile "$LINENO" "utime.h" "ac_cv_header_utime_h" "$ac_includes_default"
8803if test "x$ac_cv_header_utime_h" = xyes
8804then :
8805 printf "%s\n" "#define HAVE_UTIME_H 1" >>confdefs.h
8806
8807fi
8808ac_fn_c_check_header_compile "$LINENO" "poll.h" "ac_cv_header_poll_h" "$ac_includes_default"
8809if test "x$ac_cv_header_poll_h" = xyes
8810then :
8811 printf "%s\n" "#define HAVE_POLL_H 1" >>confdefs.h
8812
8813fi
8814ac_fn_c_check_header_compile "$LINENO" "sys/devpoll.h" "ac_cv_header_sys_devpoll_h" "$ac_includes_default"
8815if test "x$ac_cv_header_sys_devpoll_h" = xyes
8816then :
8817 printf "%s\n" "#define HAVE_SYS_DEVPOLL_H 1" >>confdefs.h
8818
8819fi
8820ac_fn_c_check_header_compile "$LINENO" "sys/epoll.h" "ac_cv_header_sys_epoll_h" "$ac_includes_default"
8821if test "x$ac_cv_header_sys_epoll_h" = xyes
8822then :
8823 printf "%s\n" "#define HAVE_SYS_EPOLL_H 1" >>confdefs.h
8824
8825fi
8826ac_fn_c_check_header_compile "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default"
8827if test "x$ac_cv_header_sys_poll_h" = xyes
8828then :
8829 printf "%s\n" "#define HAVE_SYS_POLL_H 1" >>confdefs.h
8830
8831fi
8832ac_fn_c_check_header_compile "$LINENO" "sys/audioio.h" "ac_cv_header_sys_audioio_h" "$ac_includes_default"
8833if test "x$ac_cv_header_sys_audioio_h" = xyes
8834then :
8835 printf "%s\n" "#define HAVE_SYS_AUDIOIO_H 1" >>confdefs.h
8836
8837fi
8838ac_fn_c_check_header_compile "$LINENO" "sys/xattr.h" "ac_cv_header_sys_xattr_h" "$ac_includes_default"
8839if test "x$ac_cv_header_sys_xattr_h" = xyes
8840then :
8841 printf "%s\n" "#define HAVE_SYS_XATTR_H 1" >>confdefs.h
8842
8843fi
8844ac_fn_c_check_header_compile "$LINENO" "sys/bsdtty.h" "ac_cv_header_sys_bsdtty_h" "$ac_includes_default"
8845if test "x$ac_cv_header_sys_bsdtty_h" = xyes
8846then :
8847 printf "%s\n" "#define HAVE_SYS_BSDTTY_H 1" >>confdefs.h
8848
8849fi
8850ac_fn_c_check_header_compile "$LINENO" "sys/event.h" "ac_cv_header_sys_event_h" "$ac_includes_default"
8851if test "x$ac_cv_header_sys_event_h" = xyes
8852then :
8853 printf "%s\n" "#define HAVE_SYS_EVENT_H 1" >>confdefs.h
8854
8855fi
8856ac_fn_c_check_header_compile "$LINENO" "sys/file.h" "ac_cv_header_sys_file_h" "$ac_includes_default"
8857if test "x$ac_cv_header_sys_file_h" = xyes
8858then :
8859 printf "%s\n" "#define HAVE_SYS_FILE_H 1" >>confdefs.h
8860
8861fi
8862ac_fn_c_check_header_compile "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
8863if test "x$ac_cv_header_sys_ioctl_h" = xyes
8864then :
8865 printf "%s\n" "#define HAVE_SYS_IOCTL_H 1" >>confdefs.h
8866
8867fi
8868ac_fn_c_check_header_compile "$LINENO" "sys/kern_control.h" "ac_cv_header_sys_kern_control_h" "$ac_includes_default"
8869if test "x$ac_cv_header_sys_kern_control_h" = xyes
8870then :
8871 printf "%s\n" "#define HAVE_SYS_KERN_CONTROL_H 1" >>confdefs.h
8872
8873fi
8874ac_fn_c_check_header_compile "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
8875if test "x$ac_cv_header_sys_loadavg_h" = xyes
8876then :
8877 printf "%s\n" "#define HAVE_SYS_LOADAVG_H 1" >>confdefs.h
8878
8879fi
8880ac_fn_c_check_header_compile "$LINENO" "sys/lock.h" "ac_cv_header_sys_lock_h" "$ac_includes_default"
8881if test "x$ac_cv_header_sys_lock_h" = xyes
8882then :
8883 printf "%s\n" "#define HAVE_SYS_LOCK_H 1" >>confdefs.h
8884
8885fi
8886ac_fn_c_check_header_compile "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
8887if test "x$ac_cv_header_sys_mkdev_h" = xyes
8888then :
8889 printf "%s\n" "#define HAVE_SYS_MKDEV_H 1" >>confdefs.h
8890
8891fi
8892ac_fn_c_check_header_compile "$LINENO" "sys/modem.h" "ac_cv_header_sys_modem_h" "$ac_includes_default"
8893if test "x$ac_cv_header_sys_modem_h" = xyes
8894then :
8895 printf "%s\n" "#define HAVE_SYS_MODEM_H 1" >>confdefs.h
8896
8897fi
8898ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
8899if test "x$ac_cv_header_sys_param_h" = xyes
8900then :
8901 printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h
8902
8903fi
8904ac_fn_c_check_header_compile "$LINENO" "sys/random.h" "ac_cv_header_sys_random_h" "$ac_includes_default"
8905if test "x$ac_cv_header_sys_random_h" = xyes
8906then :
8907 printf "%s\n" "#define HAVE_SYS_RANDOM_H 1" >>confdefs.h
8908
8909fi
8910ac_fn_c_check_header_compile "$LINENO" "sys/select.h" "ac_cv_header_sys_select_h" "$ac_includes_default"
8911if test "x$ac_cv_header_sys_select_h" = xyes
8912then :
8913 printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h
8914
8915fi
8916ac_fn_c_check_header_compile "$LINENO" "sys/sendfile.h" "ac_cv_header_sys_sendfile_h" "$ac_includes_default"
8917if test "x$ac_cv_header_sys_sendfile_h" = xyes
8918then :
8919 printf "%s\n" "#define HAVE_SYS_SENDFILE_H 1" >>confdefs.h
8920
8921fi
8922ac_fn_c_check_header_compile "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
8923if test "x$ac_cv_header_sys_socket_h" = xyes
8924then :
8925 printf "%s\n" "#define HAVE_SYS_SOCKET_H 1" >>confdefs.h
8926
8927fi
8928ac_fn_c_check_header_compile "$LINENO" "sys/statvfs.h" "ac_cv_header_sys_statvfs_h" "$ac_includes_default"
8929if test "x$ac_cv_header_sys_statvfs_h" = xyes
8930then :
8931 printf "%s\n" "#define HAVE_SYS_STATVFS_H 1" >>confdefs.h
8932
8933fi
8934ac_fn_c_check_header_compile "$LINENO" "sys/stat.h" "ac_cv_header_sys_stat_h" "$ac_includes_default"
8935if test "x$ac_cv_header_sys_stat_h" = xyes
8936then :
8937 printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h
8938
8939fi
8940ac_fn_c_check_header_compile "$LINENO" "sys/syscall.h" "ac_cv_header_sys_syscall_h" "$ac_includes_default"
8941if test "x$ac_cv_header_sys_syscall_h" = xyes
8942then :
8943 printf "%s\n" "#define HAVE_SYS_SYSCALL_H 1" >>confdefs.h
8944
8945fi
8946ac_fn_c_check_header_compile "$LINENO" "sys/sys_domain.h" "ac_cv_header_sys_sys_domain_h" "$ac_includes_default"
8947if test "x$ac_cv_header_sys_sys_domain_h" = xyes
8948then :
8949 printf "%s\n" "#define HAVE_SYS_SYS_DOMAIN_H 1" >>confdefs.h
8950
8951fi
8952ac_fn_c_check_header_compile "$LINENO" "sys/termio.h" "ac_cv_header_sys_termio_h" "$ac_includes_default"
8953if test "x$ac_cv_header_sys_termio_h" = xyes
8954then :
8955 printf "%s\n" "#define HAVE_SYS_TERMIO_H 1" >>confdefs.h
8956
8957fi
8958ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default"
8959if test "x$ac_cv_header_sys_time_h" = xyes
8960then :
8961 printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h
8962
8963fi
8964ac_fn_c_check_header_compile "$LINENO" "sys/times.h" "ac_cv_header_sys_times_h" "$ac_includes_default"
8965if test "x$ac_cv_header_sys_times_h" = xyes
8966then :
8967 printf "%s\n" "#define HAVE_SYS_TIMES_H 1" >>confdefs.h
8968
8969fi
8970ac_fn_c_check_header_compile "$LINENO" "sys/types.h" "ac_cv_header_sys_types_h" "$ac_includes_default"
8971if test "x$ac_cv_header_sys_types_h" = xyes
8972then :
8973 printf "%s\n" "#define HAVE_SYS_TYPES_H 1" >>confdefs.h
8974
8975fi
8976ac_fn_c_check_header_compile "$LINENO" "sys/uio.h" "ac_cv_header_sys_uio_h" "$ac_includes_default"
8977if test "x$ac_cv_header_sys_uio_h" = xyes
8978then :
8979 printf "%s\n" "#define HAVE_SYS_UIO_H 1" >>confdefs.h
8980
8981fi
8982ac_fn_c_check_header_compile "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
8983if test "x$ac_cv_header_sys_un_h" = xyes
8984then :
8985 printf "%s\n" "#define HAVE_SYS_UN_H 1" >>confdefs.h
8986
8987fi
8988ac_fn_c_check_header_compile "$LINENO" "sys/utsname.h" "ac_cv_header_sys_utsname_h" "$ac_includes_default"
8989if test "x$ac_cv_header_sys_utsname_h" = xyes
8990then :
8991 printf "%s\n" "#define HAVE_SYS_UTSNAME_H 1" >>confdefs.h
8992
8993fi
8994ac_fn_c_check_header_compile "$LINENO" "sys/wait.h" "ac_cv_header_sys_wait_h" "$ac_includes_default"
8995if test "x$ac_cv_header_sys_wait_h" = xyes
8996then :
8997 printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8998
8999fi
9000ac_fn_c_check_header_compile "$LINENO" "pty.h" "ac_cv_header_pty_h" "$ac_includes_default"
9001if test "x$ac_cv_header_pty_h" = xyes
9002then :
9003 printf "%s\n" "#define HAVE_PTY_H 1" >>confdefs.h
9004
9005fi
9006ac_fn_c_check_header_compile "$LINENO" "libutil.h" "ac_cv_header_libutil_h" "$ac_includes_default"
9007if test "x$ac_cv_header_libutil_h" = xyes
9008then :
9009 printf "%s\n" "#define HAVE_LIBUTIL_H 1" >>confdefs.h
9010
9011fi
9012ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "$ac_includes_default"
9013if test "x$ac_cv_header_sys_resource_h" = xyes
9014then :
9015 printf "%s\n" "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h
9016
9017fi
9018ac_fn_c_check_header_compile "$LINENO" "netpacket/packet.h" "ac_cv_header_netpacket_packet_h" "$ac_includes_default"
9019if test "x$ac_cv_header_netpacket_packet_h" = xyes
9020then :
9021 printf "%s\n" "#define HAVE_NETPACKET_PACKET_H 1" >>confdefs.h
9022
9023fi
9024ac_fn_c_check_header_compile "$LINENO" "sysexits.h" "ac_cv_header_sysexits_h" "$ac_includes_default"
9025if test "x$ac_cv_header_sysexits_h" = xyes
9026then :
9027 printf "%s\n" "#define HAVE_SYSEXITS_H 1" >>confdefs.h
9028
9029fi
9030ac_fn_c_check_header_compile "$LINENO" "bluetooth.h" "ac_cv_header_bluetooth_h" "$ac_includes_default"
9031if test "x$ac_cv_header_bluetooth_h" = xyes
9032then :
9033 printf "%s\n" "#define HAVE_BLUETOOTH_H 1" >>confdefs.h
9034
9035fi
9036ac_fn_c_check_header_compile "$LINENO" "linux/tipc.h" "ac_cv_header_linux_tipc_h" "$ac_includes_default"
9037if test "x$ac_cv_header_linux_tipc_h" = xyes
9038then :
9039 printf "%s\n" "#define HAVE_LINUX_TIPC_H 1" >>confdefs.h
9040
9041fi
9042ac_fn_c_check_header_compile "$LINENO" "linux/random.h" "ac_cv_header_linux_random_h" "$ac_includes_default"
9043if test "x$ac_cv_header_linux_random_h" = xyes
9044then :
9045 printf "%s\n" "#define HAVE_LINUX_RANDOM_H 1" >>confdefs.h
9046
9047fi
9048ac_fn_c_check_header_compile "$LINENO" "spawn.h" "ac_cv_header_spawn_h" "$ac_includes_default"
9049if test "x$ac_cv_header_spawn_h" = xyes
9050then :
9051 printf "%s\n" "#define HAVE_SPAWN_H 1" >>confdefs.h
9052
9053fi
9054ac_fn_c_check_header_compile "$LINENO" "util.h" "ac_cv_header_util_h" "$ac_includes_default"
9055if test "x$ac_cv_header_util_h" = xyes
9056then :
9057 printf "%s\n" "#define HAVE_UTIL_H 1" >>confdefs.h
9058
9059fi
9060ac_fn_c_check_header_compile "$LINENO" "alloca.h" "ac_cv_header_alloca_h" "$ac_includes_default"
9061if test "x$ac_cv_header_alloca_h" = xyes
9062then :
9063 printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
9064
9065fi
9066ac_fn_c_check_header_compile "$LINENO" "endian.h" "ac_cv_header_endian_h" "$ac_includes_default"
9067if test "x$ac_cv_header_endian_h" = xyes
9068then :
9069 printf "%s\n" "#define HAVE_ENDIAN_H 1" >>confdefs.h
9070
9071fi
9072ac_fn_c_check_header_compile "$LINENO" "sys/endian.h" "ac_cv_header_sys_endian_h" "$ac_includes_default"
9073if test "x$ac_cv_header_sys_endian_h" = xyes
9074then :
9075 printf "%s\n" "#define HAVE_SYS_ENDIAN_H 1" >>confdefs.h
9076
9077fi
9078ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
9079if test "x$ac_cv_header_sys_sysmacros_h" = xyes
9080then :
9081 printf "%s\n" "#define HAVE_SYS_SYSMACROS_H 1" >>confdefs.h
9082
9083fi
9084ac_fn_c_check_header_compile "$LINENO" "linux/memfd.h" "ac_cv_header_linux_memfd_h" "$ac_includes_default"
9085if test "x$ac_cv_header_linux_memfd_h" = xyes
9086then :
9087 printf "%s\n" "#define HAVE_LINUX_MEMFD_H 1" >>confdefs.h
9088
9089fi
9090ac_fn_c_check_header_compile "$LINENO" "linux/wait.h" "ac_cv_header_linux_wait_h" "$ac_includes_default"
9091if test "x$ac_cv_header_linux_wait_h" = xyes
9092then :
9093 printf "%s\n" "#define HAVE_LINUX_WAIT_H 1" >>confdefs.h
9094
9095fi
9096ac_fn_c_check_header_compile "$LINENO" "sys/memfd.h" "ac_cv_header_sys_memfd_h" "$ac_includes_default"
9097if test "x$ac_cv_header_sys_memfd_h" = xyes
9098then :
9099 printf "%s\n" "#define HAVE_SYS_MEMFD_H 1" >>confdefs.h
9100
9101fi
9102ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
9103if test "x$ac_cv_header_sys_mman_h" = xyes
9104then :
9105 printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h
9106
9107fi
9108ac_fn_c_check_header_compile "$LINENO" "sys/eventfd.h" "ac_cv_header_sys_eventfd_h" "$ac_includes_default"
9109if test "x$ac_cv_header_sys_eventfd_h" = xyes
9110then :
9111 printf "%s\n" "#define HAVE_SYS_EVENTFD_H 1" >>confdefs.h
9112
9113fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00009114
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009115ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009116for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
Pablo Galindoba421752021-05-03 20:33:17 +01009117 as_ac_Header=`printf "%s\n" "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
9118{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
9119printf %s "checking for $ac_hdr that defines DIR... " >&6; }
9120if eval test \${$as_ac_Header+y}
9121then :
9122 printf %s "(cached) " >&6
9123else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009125/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009126#include <sys/types.h>
9127#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00009128
Martin v. Löwis11437992002-04-12 09:54:03 +00009129int
Pablo Galindoba421752021-05-03 20:33:17 +01009130main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00009131{
9132if ((DIR *) 0)
9133return 0;
9134 ;
9135 return 0;
9136}
9137_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009138if ac_fn_c_try_compile "$LINENO"
9139then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009140 eval "$as_ac_Header=yes"
Pablo Galindoba421752021-05-03 20:33:17 +01009141else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009142 eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009143fi
Pablo Galindoba421752021-05-03 20:33:17 +01009144rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00009145fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009146eval ac_res=\$$as_ac_Header
Pablo Galindoba421752021-05-03 20:33:17 +01009147 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9148printf "%s\n" "$ac_res" >&6; }
9149if eval test \"x\$"$as_ac_Header"\" = x"yes"
9150then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009151 cat >>confdefs.h <<_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009152#define `printf "%s\n" "HAVE_$ac_hdr" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009153_ACEOF
9154
9155ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00009156fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009157
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009158done
9159# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
9160if test $ac_header_dirent = dirent.h; then
Pablo Galindoba421752021-05-03 20:33:17 +01009161 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
9162printf %s "checking for library containing opendir... " >&6; }
9163if test ${ac_cv_search_opendir+y}
9164then :
9165 printf %s "(cached) " >&6
9166else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009167 ac_func_search_save_LIBS=$LIBS
Matthias Kloseb9621712010-04-24 17:59:49 +00009168cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009169/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009170
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009171/* Override any GCC internal prototype to avoid an error.
9172 Use char because int might match the return type of a GCC
9173 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009174char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00009175int
Pablo Galindoba421752021-05-03 20:33:17 +01009176main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00009177{
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009178return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00009179 ;
9180 return 0;
9181}
9182_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009183for ac_lib in '' dir
9184do
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009185 if test -z "$ac_lib"; then
9186 ac_res="none required"
9187 else
9188 ac_res=-l$ac_lib
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00009189 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009190 fi
Pablo Galindoba421752021-05-03 20:33:17 +01009191 if ac_fn_c_try_link "$LINENO"
9192then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009193 ac_cv_search_opendir=$ac_res
Thomas Wouters477c8d52006-05-27 19:21:47 +00009194fi
Pablo Galindoba421752021-05-03 20:33:17 +01009195rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +00009196 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +01009197 if test ${ac_cv_search_opendir+y}
9198then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009199 break
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00009200fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009201done
Pablo Galindoba421752021-05-03 20:33:17 +01009202if test ${ac_cv_search_opendir+y}
9203then :
Matthias Kloseb9621712010-04-24 17:59:49 +00009204
Pablo Galindoba421752021-05-03 20:33:17 +01009205else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009206 ac_cv_search_opendir=no
9207fi
9208rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009209LIBS=$ac_func_search_save_LIBS
9210fi
Pablo Galindoba421752021-05-03 20:33:17 +01009211{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
9212printf "%s\n" "$ac_cv_search_opendir" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009213ac_res=$ac_cv_search_opendir
Pablo Galindoba421752021-05-03 20:33:17 +01009214if test "$ac_res" != no
9215then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009216 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00009217
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009218fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009219
Michael W. Hudson54241132001-12-07 15:38:26 +00009220else
Pablo Galindoba421752021-05-03 20:33:17 +01009221 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
9222printf %s "checking for library containing opendir... " >&6; }
9223if test ${ac_cv_search_opendir+y}
9224then :
9225 printf %s "(cached) " >&6
9226else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009227 ac_func_search_save_LIBS=$LIBS
Matthias Kloseb9621712010-04-24 17:59:49 +00009228cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009229/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009230
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009231/* Override any GCC internal prototype to avoid an error.
9232 Use char because int might match the return type of a GCC
9233 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009234char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00009235int
Pablo Galindoba421752021-05-03 20:33:17 +01009236main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +00009237{
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009238return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00009239 ;
9240 return 0;
9241}
9242_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009243for ac_lib in '' x
9244do
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009245 if test -z "$ac_lib"; then
9246 ac_res="none required"
9247 else
9248 ac_res=-l$ac_lib
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00009249 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009250 fi
Pablo Galindoba421752021-05-03 20:33:17 +01009251 if ac_fn_c_try_link "$LINENO"
9252then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009253 ac_cv_search_opendir=$ac_res
Thomas Wouters477c8d52006-05-27 19:21:47 +00009254fi
Pablo Galindoba421752021-05-03 20:33:17 +01009255rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +00009256 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +01009257 if test ${ac_cv_search_opendir+y}
9258then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009259 break
Skip Montanaroeb33e5a2007-08-17 12:57:41 +00009260fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009261done
Pablo Galindoba421752021-05-03 20:33:17 +01009262if test ${ac_cv_search_opendir+y}
9263then :
Matthias Kloseb9621712010-04-24 17:59:49 +00009264
Pablo Galindoba421752021-05-03 20:33:17 +01009265else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009266 ac_cv_search_opendir=no
9267fi
9268rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009269LIBS=$ac_func_search_save_LIBS
9270fi
Pablo Galindoba421752021-05-03 20:33:17 +01009271{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
9272printf "%s\n" "$ac_cv_search_opendir" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009273ac_res=$ac_cv_search_opendir
Pablo Galindoba421752021-05-03 20:33:17 +01009274if test "$ac_res" != no
9275then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009276 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009277
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009278fi
9279
9280fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00009281
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009282
Pablo Galindoba421752021-05-03 20:33:17 +01009283ac_fn_c_check_header_compile "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
9284if test "x$ac_cv_header_sys_mkdev_h" = xyes
9285then :
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009286
Pablo Galindoba421752021-05-03 20:33:17 +01009287printf "%s\n" "#define MAJOR_IN_MKDEV 1" >>confdefs.h
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009288
9289fi
9290
Pablo Galindoba421752021-05-03 20:33:17 +01009291if test $ac_cv_header_sys_mkdev_h = no; then
9292 ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
9293if test "x$ac_cv_header_sys_sysmacros_h" = xyes
9294then :
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009295
Pablo Galindoba421752021-05-03 20:33:17 +01009296printf "%s\n" "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009297
9298fi
9299
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00009300fi
9301
Michael W. Hudson54241132001-12-07 15:38:26 +00009302
Benjamin Peterson93b2dee2016-09-09 10:22:45 -07009303# bluetooth/bluetooth.h has been known to not compile with -std=c99.
9304# http://permalink.gmane.org/gmane.linux.bluez.kernel/22294
9305SAVE_CFLAGS=$CFLAGS
9306CFLAGS="-std=c99 $CFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +01009307ac_fn_c_check_header_compile "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default"
9308if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes
9309then :
9310 printf "%s\n" "#define HAVE_BLUETOOTH_BLUETOOTH_H 1" >>confdefs.h
Benjamin Peterson93b2dee2016-09-09 10:22:45 -07009311
9312fi
9313
Benjamin Peterson93b2dee2016-09-09 10:22:45 -07009314CFLAGS=$SAVE_CFLAGS
9315
Gregory P. Smith3b1f2c32011-05-15 12:18:23 -07009316# On Darwin (OS X) net/if.h requires sys/socket.h to be imported first.
Pablo Galindoba421752021-05-03 20:33:17 +01009317ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#include <stdio.h>
Gregory P. Smith3b1f2c32011-05-15 12:18:23 -07009318#ifdef STDC_HEADERS
9319# include <stdlib.h>
9320# include <stddef.h>
9321#else
9322# ifdef HAVE_STDLIB_H
9323# include <stdlib.h>
9324# endif
9325#endif
9326#ifdef HAVE_SYS_SOCKET_H
9327# include <sys/socket.h>
9328#endif
9329
9330"
Pablo Galindoba421752021-05-03 20:33:17 +01009331if test "x$ac_cv_header_net_if_h" = xyes
9332then :
9333 printf "%s\n" "#define HAVE_NET_IF_H 1" >>confdefs.h
Gregory P. Smith3b1f2c32011-05-15 12:18:23 -07009334
9335fi
9336
Gregory P. Smith3b1f2c32011-05-15 12:18:23 -07009337
Martin v. Löwis11017b12006-01-14 18:12:57 +00009338# On Linux, netlink.h requires asm/types.h
Pablo Galindoba421752021-05-03 20:33:17 +01009339ac_fn_c_check_header_compile "$LINENO" "linux/netlink.h" "ac_cv_header_linux_netlink_h" "
Martin v. Löwis11017b12006-01-14 18:12:57 +00009340#ifdef HAVE_ASM_TYPES_H
9341#include <asm/types.h>
9342#endif
9343#ifdef HAVE_SYS_SOCKET_H
9344#include <sys/socket.h>
9345#endif
9346
Matthias Kloseb9621712010-04-24 17:59:49 +00009347"
Pablo Galindoba421752021-05-03 20:33:17 +01009348if test "x$ac_cv_header_linux_netlink_h" = xyes
9349then :
9350 printf "%s\n" "#define HAVE_LINUX_NETLINK_H 1" >>confdefs.h
Martin v. Löwis11017b12006-01-14 18:12:57 +00009351
9352fi
9353
Martin v. Löwis11017b12006-01-14 18:12:57 +00009354
Bjorn Anderssonbb816512018-09-26 06:47:52 -07009355# On Linux, qrtr.h requires asm/types.h
Pablo Galindoba421752021-05-03 20:33:17 +01009356ac_fn_c_check_header_compile "$LINENO" "linux/qrtr.h" "ac_cv_header_linux_qrtr_h" "
Bjorn Anderssonbb816512018-09-26 06:47:52 -07009357#ifdef HAVE_ASM_TYPES_H
9358#include <asm/types.h>
9359#endif
9360#ifdef HAVE_SYS_SOCKET_H
9361#include <sys/socket.h>
9362#endif
9363
9364"
Pablo Galindoba421752021-05-03 20:33:17 +01009365if test "x$ac_cv_header_linux_qrtr_h" = xyes
9366then :
9367 printf "%s\n" "#define HAVE_LINUX_QRTR_H 1" >>confdefs.h
Bjorn Anderssonbb816512018-09-26 06:47:52 -07009368
9369fi
9370
Bjorn Anderssonbb816512018-09-26 06:47:52 -07009371
Pablo Galindoba421752021-05-03 20:33:17 +01009372ac_fn_c_check_header_compile "$LINENO" "linux/vm_sockets.h" "ac_cv_header_linux_vm_sockets_h" "
caaveryeffc12f2017-09-06 18:18:10 -04009373#ifdef HAVE_SYS_SOCKET_H
9374#include <sys/socket.h>
9375#endif
9376
9377"
Pablo Galindoba421752021-05-03 20:33:17 +01009378if test "x$ac_cv_header_linux_vm_sockets_h" = xyes
9379then :
9380 printf "%s\n" "#define HAVE_LINUX_VM_SOCKETS_H 1" >>confdefs.h
caaveryeffc12f2017-09-06 18:18:10 -04009381
9382fi
9383
caaveryeffc12f2017-09-06 18:18:10 -04009384
karl ding360371f2020-04-29 15:31:19 -07009385# On Linux, can.h, can/bcm.h, can/j1939.h, can/raw.h require sys/socket.h
Pablo Galindoba421752021-05-03 20:33:17 +01009386ac_fn_c_check_header_compile "$LINENO" "linux/can.h" "ac_cv_header_linux_can_h" "
Charles-François Natali47413c12011-10-06 19:47:44 +02009387#ifdef HAVE_SYS_SOCKET_H
9388#include <sys/socket.h>
9389#endif
9390
9391"
Pablo Galindoba421752021-05-03 20:33:17 +01009392if test "x$ac_cv_header_linux_can_h" = xyes
9393then :
9394 printf "%s\n" "#define HAVE_LINUX_CAN_H 1" >>confdefs.h
Charles-François Natali47413c12011-10-06 19:47:44 +02009395
9396fi
Pablo Galindoba421752021-05-03 20:33:17 +01009397ac_fn_c_check_header_compile "$LINENO" "linux/can/bcm.h" "ac_cv_header_linux_can_bcm_h" "
9398#ifdef HAVE_SYS_SOCKET_H
9399#include <sys/socket.h>
9400#endif
Charles-François Natali47413c12011-10-06 19:47:44 +02009401
Pablo Galindoba421752021-05-03 20:33:17 +01009402"
9403if test "x$ac_cv_header_linux_can_bcm_h" = xyes
9404then :
9405 printf "%s\n" "#define HAVE_LINUX_CAN_BCM_H 1" >>confdefs.h
9406
9407fi
9408ac_fn_c_check_header_compile "$LINENO" "linux/can/j1939.h" "ac_cv_header_linux_can_j1939_h" "
9409#ifdef HAVE_SYS_SOCKET_H
9410#include <sys/socket.h>
9411#endif
9412
9413"
9414if test "x$ac_cv_header_linux_can_j1939_h" = xyes
9415then :
9416 printf "%s\n" "#define HAVE_LINUX_CAN_J1939_H 1" >>confdefs.h
9417
9418fi
9419ac_fn_c_check_header_compile "$LINENO" "linux/can/raw.h" "ac_cv_header_linux_can_raw_h" "
9420#ifdef HAVE_SYS_SOCKET_H
9421#include <sys/socket.h>
9422#endif
9423
9424"
9425if test "x$ac_cv_header_linux_can_raw_h" = xyes
9426then :
9427 printf "%s\n" "#define HAVE_LINUX_CAN_RAW_H 1" >>confdefs.h
9428
9429fi
Charles-François Natali47413c12011-10-06 19:47:44 +02009430
9431
Guido van Rossum627b2d71993-12-24 10:39:16 +00009432# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00009433was_it_defined=no
Pablo Galindoba421752021-05-03 20:33:17 +01009434{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5
9435printf %s "checking for clock_t in time.h... " >&6; }
9436
Matthias Kloseb9621712010-04-24 17:59:49 +00009437cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009438/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009439#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009440
9441_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009442if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +01009443 $EGREP "clock_t" >/dev/null 2>&1
9444then :
Guido van Rossumda88dad1995-01-26 00:46:29 +00009445 was_it_defined=yes
Pablo Galindoba421752021-05-03 20:33:17 +01009446else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009447
9448
Pablo Galindoba421752021-05-03 20:33:17 +01009449printf "%s\n" "#define clock_t long" >>confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00009450
Martin v. Löwisc45929e2002-04-06 10:10:49 +00009451
Guido van Rossum627b2d71993-12-24 10:39:16 +00009452fi
Pablo Galindoba421752021-05-03 20:33:17 +01009453rm -rf conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00009454
Pablo Galindoba421752021-05-03 20:33:17 +01009455{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5
9456printf "%s\n" "$was_it_defined" >&6; }
Guido van Rossumda88dad1995-01-26 00:46:29 +00009457
Pablo Galindoba421752021-05-03 20:33:17 +01009458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5
9459printf %s "checking for makedev... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +00009460cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009461/* end confdefs.h. */
Matthias Kloseb159a552010-04-25 21:00:44 +00009462
Jesus Cea740f53a2010-04-28 11:35:30 +00009463#if defined(MAJOR_IN_MKDEV)
9464#include <sys/mkdev.h>
9465#elif defined(MAJOR_IN_SYSMACROS)
9466#include <sys/sysmacros.h>
9467#else
9468#include <sys/types.h>
9469#endif
9470
Neal Norwitz11690112002-07-30 01:08:28 +00009471int
Pablo Galindoba421752021-05-03 20:33:17 +01009472main (void)
Neal Norwitz11690112002-07-30 01:08:28 +00009473{
Jesus Cea740f53a2010-04-28 11:35:30 +00009474
9475 makedev(0, 0)
Neal Norwitz11690112002-07-30 01:08:28 +00009476 ;
9477 return 0;
9478}
Matthias Kloseb159a552010-04-25 21:00:44 +00009479
Neal Norwitz11690112002-07-30 01:08:28 +00009480_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009481if ac_fn_c_try_link "$LINENO"
9482then :
Neal Norwitz11690112002-07-30 01:08:28 +00009483 ac_cv_has_makedev=yes
Pablo Galindoba421752021-05-03 20:33:17 +01009484else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009485 ac_cv_has_makedev=no
Neal Norwitz11690112002-07-30 01:08:28 +00009486fi
Pablo Galindoba421752021-05-03 20:33:17 +01009487rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +00009488 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +01009489{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5
9490printf "%s\n" "$ac_cv_has_makedev" >&6; }
Neal Norwitz11690112002-07-30 01:08:28 +00009491if test "$ac_cv_has_makedev" = "yes"; then
9492
Pablo Galindoba421752021-05-03 20:33:17 +01009493printf "%s\n" "#define HAVE_MAKEDEV 1" >>confdefs.h
Neal Norwitz11690112002-07-30 01:08:28 +00009494
9495fi
9496
Christian Heimes985ecdc2013-11-20 11:46:18 +01009497# byte swapping
Pablo Galindoba421752021-05-03 20:33:17 +01009498{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for le64toh" >&5
9499printf %s "checking for le64toh... " >&6; }
Christian Heimes985ecdc2013-11-20 11:46:18 +01009500cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9501/* end confdefs.h. */
9502
9503#ifdef HAVE_ENDIAN_H
9504#include <endian.h>
9505#elif defined(HAVE_SYS_ENDIAN_H)
9506#include <sys/endian.h>
9507#endif
9508
9509int
Pablo Galindoba421752021-05-03 20:33:17 +01009510main (void)
Christian Heimes985ecdc2013-11-20 11:46:18 +01009511{
9512
9513 le64toh(1)
9514 ;
9515 return 0;
9516}
9517
9518_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009519if ac_fn_c_try_link "$LINENO"
9520then :
Christian Heimes985ecdc2013-11-20 11:46:18 +01009521 ac_cv_has_le64toh=yes
Pablo Galindoba421752021-05-03 20:33:17 +01009522else $as_nop
Christian Heimes985ecdc2013-11-20 11:46:18 +01009523 ac_cv_has_le64toh=no
9524fi
Pablo Galindoba421752021-05-03 20:33:17 +01009525rm -f core conftest.err conftest.$ac_objext conftest.beam \
Christian Heimes985ecdc2013-11-20 11:46:18 +01009526 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +01009527{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_le64toh" >&5
9528printf "%s\n" "$ac_cv_has_le64toh" >&6; }
Christian Heimes985ecdc2013-11-20 11:46:18 +01009529if test "$ac_cv_has_le64toh" = "yes"; then
9530
Pablo Galindoba421752021-05-03 20:33:17 +01009531printf "%s\n" "#define HAVE_HTOLE64 1" >>confdefs.h
Christian Heimes985ecdc2013-11-20 11:46:18 +01009532
9533fi
9534
Martin v. Löwis399a6892002-10-04 10:22:02 +00009535use_lfs=yes
doko@ubuntu.com006a56c2016-06-14 10:15:25 +02009536# Don't use largefile support for GNU/Hurd
9537case $ac_sys_system in GNU*)
9538 use_lfs=no
9539esac
9540
Martin v. Löwis399a6892002-10-04 10:22:02 +00009541if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00009542# Two defines needed to enable largefile support on various platforms
9543# These may affect some typedefs
Georg Brandl216e4042011-02-19 08:58:23 +00009544case $ac_sys_system/$ac_sys_release in
9545AIX*)
9546
Pablo Galindoba421752021-05-03 20:33:17 +01009547printf "%s\n" "#define _LARGE_FILES 1" >>confdefs.h
Georg Brandl216e4042011-02-19 08:58:23 +00009548
9549 ;;
9550esac
Guido van Rossum810cc512001-09-09 23:51:39 +00009551
Pablo Galindoba421752021-05-03 20:33:17 +01009552printf "%s\n" "#define _LARGEFILE_SOURCE 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00009553
9554
Pablo Galindoba421752021-05-03 20:33:17 +01009555printf "%s\n" "#define _FILE_OFFSET_BITS 64" >>confdefs.h
Guido van Rossum810cc512001-09-09 23:51:39 +00009556
Martin v. Löwis399a6892002-10-04 10:22:02 +00009557fi
Michael W. Hudson54241132001-12-07 15:38:26 +00009558
Guido van Rossum84e7b241996-08-19 21:59:00 +00009559# Add some code to confdefs.h so that the test for off_t works on SCO
9560cat >> confdefs.h <<\EOF
9561#if defined(SCO_DS)
9562#undef _OFF_T
9563#endif
9564EOF
9565
Guido van Rossumef2255b2000-03-10 22:30:29 +00009566# Type availability checks
Matthias Kloseb9621712010-04-24 17:59:49 +00009567ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +01009568if test "x$ac_cv_type_mode_t" = xyes
9569then :
Skip Montanaro6dead952003-09-25 14:50:04 +00009570
Pablo Galindoba421752021-05-03 20:33:17 +01009571else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009572
Pablo Galindoba421752021-05-03 20:33:17 +01009573printf "%s\n" "#define mode_t int" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00009574
9575fi
9576
Matthias Kloseb9621712010-04-24 17:59:49 +00009577ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +01009578if test "x$ac_cv_type_off_t" = xyes
9579then :
Skip Montanaro6dead952003-09-25 14:50:04 +00009580
Pablo Galindoba421752021-05-03 20:33:17 +01009581else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009582
Pablo Galindoba421752021-05-03 20:33:17 +01009583printf "%s\n" "#define off_t long int" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +01009584
9585fi
9586
9587
Pablo Galindoba421752021-05-03 20:33:17 +01009588 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default
9589"
9590if test "x$ac_cv_type_pid_t" = xyes
9591then :
9592
9593else $as_nop
9594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9595/* end confdefs.h. */
9596
9597 #if defined _WIN64 && !defined __CYGWIN__
9598 LLP64
9599 #endif
9600
9601int
9602main (void)
9603{
9604
9605 ;
9606 return 0;
9607}
9608
Christian Heimes39258d32021-04-17 11:36:35 +02009609_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +01009610if ac_fn_c_try_compile "$LINENO"
9611then :
9612 ac_pid_type='int'
9613else $as_nop
9614 ac_pid_type='__int64'
9615fi
9616rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9617
9618printf "%s\n" "#define pid_t $ac_pid_type" >>confdefs.h
9619
9620
9621fi
9622
9623
9624
9625printf "%s\n" "#define RETSIGTYPE void" >>confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00009626
Matthias Kloseb9621712010-04-24 17:59:49 +00009627ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +01009628if test "x$ac_cv_type_size_t" = xyes
9629then :
Skip Montanaro6dead952003-09-25 14:50:04 +00009630
Pablo Galindoba421752021-05-03 20:33:17 +01009631else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +00009632
Pablo Galindoba421752021-05-03 20:33:17 +01009633printf "%s\n" "#define size_t unsigned int" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00009634
9635fi
9636
Pablo Galindoba421752021-05-03 20:33:17 +01009637{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
9638printf %s "checking for uid_t in sys/types.h... " >&6; }
9639if test ${ac_cv_type_uid_t+y}
9640then :
9641 printf %s "(cached) " >&6
9642else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00009644/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009645#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009646
9647_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009648if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +01009649 $EGREP "uid_t" >/dev/null 2>&1
9650then :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009651 ac_cv_type_uid_t=yes
Pablo Galindoba421752021-05-03 20:33:17 +01009652else $as_nop
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009653 ac_cv_type_uid_t=no
9654fi
Pablo Galindoba421752021-05-03 20:33:17 +01009655rm -rf conftest*
Guido van Rossum627b2d71993-12-24 10:39:16 +00009656
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009657fi
Pablo Galindoba421752021-05-03 20:33:17 +01009658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
9659printf "%s\n" "$ac_cv_type_uid_t" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00009660if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009661
Pablo Galindoba421752021-05-03 20:33:17 +01009662printf "%s\n" "#define uid_t int" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00009663
9664
Pablo Galindoba421752021-05-03 20:33:17 +01009665printf "%s\n" "#define gid_t int" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009666
9667fi
9668
Mark Dickinson983bc162012-12-02 12:11:38 +00009669
Matthias Kloseb9621712010-04-24 17:59:49 +00009670ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +01009671if test "x$ac_cv_type_ssize_t" = xyes
9672then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009673
Pablo Galindoba421752021-05-03 20:33:17 +01009674printf "%s\n" "#define HAVE_SSIZE_T 1" >>confdefs.h
Martin v. Löwis18e16552006-02-15 17:27:45 +00009675
9676fi
9677
Stefan Krah1919b7e2012-03-21 18:25:23 +01009678ac_fn_c_check_type "$LINENO" "__uint128_t" "ac_cv_type___uint128_t" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +01009679if test "x$ac_cv_type___uint128_t" = xyes
9680then :
Stefan Krah1919b7e2012-03-21 18:25:23 +01009681
Pablo Galindoba421752021-05-03 20:33:17 +01009682printf "%s\n" "#define HAVE_GCC_UINT128_T 1" >>confdefs.h
Stefan Krah1919b7e2012-03-21 18:25:23 +01009683
9684fi
9685
Jack Jansendd19cf82001-12-06 22:36:17 +00009686
Jessica Clarkedec07572021-03-31 11:12:39 +01009687# Sizes and alignments of various common basic types
Skip Montanarob9820a32004-01-17 00:16:12 +00009688# ANSI C requires sizeof(char) == 1, so no need to check it
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009689# The cast to long int works around a bug in the HP C Compiler
9690# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9691# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9692# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009693{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
9694printf %s "checking size of int... " >&6; }
9695if test ${ac_cv_sizeof_int+y}
9696then :
9697 printf %s "(cached) " >&6
9698else $as_nop
9699 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"
9700then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009701
Pablo Galindoba421752021-05-03 20:33:17 +01009702else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009703 if test "$ac_cv_type_int" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009704 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9705printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009706as_fn_error 77 "cannot compute sizeof (int)
Victor Stinnere0be4232011-10-25 13:06:09 +02009707See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009708 else
9709 ac_cv_sizeof_int=0
9710 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009711fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009712
Martin v. Löwis11437992002-04-12 09:54:03 +00009713fi
Pablo Galindoba421752021-05-03 20:33:17 +01009714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
9715printf "%s\n" "$ac_cv_sizeof_int" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009716
9717
9718
Pablo Galindoba421752021-05-03 20:33:17 +01009719printf "%s\n" "#define SIZEOF_INT $ac_cv_sizeof_int" >>confdefs.h
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009720
9721
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009722# The cast to long int works around a bug in the HP C Compiler
9723# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9724# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9725# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009726{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
9727printf %s "checking size of long... " >&6; }
9728if test ${ac_cv_sizeof_long+y}
9729then :
9730 printf %s "(cached) " >&6
9731else $as_nop
9732 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"
9733then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009734
Pablo Galindoba421752021-05-03 20:33:17 +01009735else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009736 if test "$ac_cv_type_long" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009737 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9738printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009739as_fn_error 77 "cannot compute sizeof (long)
Victor Stinnere0be4232011-10-25 13:06:09 +02009740See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009741 else
9742 ac_cv_sizeof_long=0
9743 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009744fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009745
Martin v. Löwis11437992002-04-12 09:54:03 +00009746fi
Pablo Galindoba421752021-05-03 20:33:17 +01009747{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
9748printf "%s\n" "$ac_cv_sizeof_long" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009749
9750
9751
Pablo Galindoba421752021-05-03 20:33:17 +01009752printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009753
9754
Jessica Clarkedec07572021-03-31 11:12:39 +01009755# The cast to long int works around a bug in the HP C Compiler,
9756# see AC_CHECK_SIZEOF for more information.
Pablo Galindoba421752021-05-03 20:33:17 +01009757{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking alignment of long" >&5
9758printf %s "checking alignment of long... " >&6; }
9759if test ${ac_cv_alignof_long+y}
9760then :
9761 printf %s "(cached) " >&6
9762else $as_nop
Jessica Clarkedec07572021-03-31 11:12:39 +01009763 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long" "$ac_includes_default
Pablo Galindoba421752021-05-03 20:33:17 +01009764typedef struct { char x; long y; } ac__type_alignof_;"
9765then :
Jessica Clarkedec07572021-03-31 11:12:39 +01009766
Pablo Galindoba421752021-05-03 20:33:17 +01009767else $as_nop
Jessica Clarkedec07572021-03-31 11:12:39 +01009768 if test "$ac_cv_type_long" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009769 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9770printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Jessica Clarkedec07572021-03-31 11:12:39 +01009771as_fn_error 77 "cannot compute alignment of long
9772See \`config.log' for more details" "$LINENO" 5; }
9773 else
9774 ac_cv_alignof_long=0
9775 fi
9776fi
9777
9778fi
Pablo Galindoba421752021-05-03 20:33:17 +01009779{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long" >&5
9780printf "%s\n" "$ac_cv_alignof_long" >&6; }
Jessica Clarkedec07572021-03-31 11:12:39 +01009781
9782
9783
Pablo Galindoba421752021-05-03 20:33:17 +01009784printf "%s\n" "#define ALIGNOF_LONG $ac_cv_alignof_long" >>confdefs.h
Jessica Clarkedec07572021-03-31 11:12:39 +01009785
9786
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009787# The cast to long int works around a bug in the HP C Compiler
9788# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9789# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9790# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009791{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
9792printf %s "checking size of long long... " >&6; }
9793if test ${ac_cv_sizeof_long_long+y}
9794then :
9795 printf %s "(cached) " >&6
9796else $as_nop
9797 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"
9798then :
Benjamin Petersoned4aa832016-09-05 17:44:18 -07009799
Pablo Galindoba421752021-05-03 20:33:17 +01009800else $as_nop
Benjamin Petersoned4aa832016-09-05 17:44:18 -07009801 if test "$ac_cv_type_long_long" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009802 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9803printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Benjamin Petersoned4aa832016-09-05 17:44:18 -07009804as_fn_error 77 "cannot compute sizeof (long long)
9805See \`config.log' for more details" "$LINENO" 5; }
9806 else
9807 ac_cv_sizeof_long_long=0
9808 fi
9809fi
9810
9811fi
Pablo Galindoba421752021-05-03 20:33:17 +01009812{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
9813printf "%s\n" "$ac_cv_sizeof_long_long" >&6; }
Benjamin Petersoned4aa832016-09-05 17:44:18 -07009814
9815
9816
Pablo Galindoba421752021-05-03 20:33:17 +01009817printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h
Benjamin Petersoned4aa832016-09-05 17:44:18 -07009818
9819
9820# The cast to long int works around a bug in the HP C Compiler
9821# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9822# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9823# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009824{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
9825printf %s "checking size of void *... " >&6; }
9826if test ${ac_cv_sizeof_void_p+y}
9827then :
9828 printf %s "(cached) " >&6
9829else $as_nop
9830 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"
9831then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009832
Pablo Galindoba421752021-05-03 20:33:17 +01009833else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009834 if test "$ac_cv_type_void_p" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009835 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9836printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009837as_fn_error 77 "cannot compute sizeof (void *)
Victor Stinnere0be4232011-10-25 13:06:09 +02009838See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009839 else
9840 ac_cv_sizeof_void_p=0
9841 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009842fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009843
Martin v. Löwis11437992002-04-12 09:54:03 +00009844fi
Pablo Galindoba421752021-05-03 20:33:17 +01009845{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
9846printf "%s\n" "$ac_cv_sizeof_void_p" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009847
9848
9849
Pablo Galindoba421752021-05-03 20:33:17 +01009850printf "%s\n" "#define SIZEOF_VOID_P $ac_cv_sizeof_void_p" >>confdefs.h
Guido van Rossumad678af1998-10-02 14:42:15 +00009851
9852
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009853# The cast to long int works around a bug in the HP C Compiler
9854# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9855# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9856# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009857{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
9858printf %s "checking size of short... " >&6; }
9859if test ${ac_cv_sizeof_short+y}
9860then :
9861 printf %s "(cached) " >&6
9862else $as_nop
9863 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"
9864then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009865
Pablo Galindoba421752021-05-03 20:33:17 +01009866else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009867 if test "$ac_cv_type_short" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009868 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9869printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009870as_fn_error 77 "cannot compute sizeof (short)
Victor Stinnere0be4232011-10-25 13:06:09 +02009871See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009872 else
9873 ac_cv_sizeof_short=0
9874 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009875fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009876
Martin v. Löwis11437992002-04-12 09:54:03 +00009877fi
Pablo Galindoba421752021-05-03 20:33:17 +01009878{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
9879printf "%s\n" "$ac_cv_sizeof_short" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009880
9881
9882
Pablo Galindoba421752021-05-03 20:33:17 +01009883printf "%s\n" "#define SIZEOF_SHORT $ac_cv_sizeof_short" >>confdefs.h
Guido van Rossumef2255b2000-03-10 22:30:29 +00009884
9885
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009886# The cast to long int works around a bug in the HP C Compiler
9887# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9888# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9889# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009890{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of float" >&5
9891printf %s "checking size of float... " >&6; }
9892if test ${ac_cv_sizeof_float+y}
9893then :
9894 printf %s "(cached) " >&6
9895else $as_nop
9896 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (float))" "ac_cv_sizeof_float" "$ac_includes_default"
9897then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009898
Pablo Galindoba421752021-05-03 20:33:17 +01009899else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009900 if test "$ac_cv_type_float" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009901 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9902printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009903as_fn_error 77 "cannot compute sizeof (float)
Victor Stinnere0be4232011-10-25 13:06:09 +02009904See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009905 else
9906 ac_cv_sizeof_float=0
9907 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009908fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009909
Martin v. Löwis11437992002-04-12 09:54:03 +00009910fi
Pablo Galindoba421752021-05-03 20:33:17 +01009911{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5
9912printf "%s\n" "$ac_cv_sizeof_float" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009913
9914
9915
Pablo Galindoba421752021-05-03 20:33:17 +01009916printf "%s\n" "#define SIZEOF_FLOAT $ac_cv_sizeof_float" >>confdefs.h
Guido van Rossumef2255b2000-03-10 22:30:29 +00009917
9918
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009919# The cast to long int works around a bug in the HP C Compiler
9920# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9921# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9922# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009923{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of double" >&5
9924printf %s "checking size of double... " >&6; }
9925if test ${ac_cv_sizeof_double+y}
9926then :
9927 printf %s "(cached) " >&6
9928else $as_nop
9929 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"
9930then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009931
Pablo Galindoba421752021-05-03 20:33:17 +01009932else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009933 if test "$ac_cv_type_double" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009934 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9935printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009936as_fn_error 77 "cannot compute sizeof (double)
Victor Stinnere0be4232011-10-25 13:06:09 +02009937See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009938 else
9939 ac_cv_sizeof_double=0
9940 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009941fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009942
Martin v. Löwis11437992002-04-12 09:54:03 +00009943fi
Pablo Galindoba421752021-05-03 20:33:17 +01009944{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5
9945printf "%s\n" "$ac_cv_sizeof_double" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009946
9947
9948
Pablo Galindoba421752021-05-03 20:33:17 +01009949printf "%s\n" "#define SIZEOF_DOUBLE $ac_cv_sizeof_double" >>confdefs.h
Guido van Rossumef2255b2000-03-10 22:30:29 +00009950
9951
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009952# The cast to long int works around a bug in the HP C Compiler
9953# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9954# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9955# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009956{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5
9957printf %s "checking size of fpos_t... " >&6; }
9958if test ${ac_cv_sizeof_fpos_t+y}
9959then :
9960 printf %s "(cached) " >&6
9961else $as_nop
9962 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (fpos_t))" "ac_cv_sizeof_fpos_t" "$ac_includes_default"
9963then :
Martin v. Löwis11437992002-04-12 09:54:03 +00009964
Pablo Galindoba421752021-05-03 20:33:17 +01009965else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009966 if test "$ac_cv_type_fpos_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +01009967 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9968printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +02009969as_fn_error 77 "cannot compute sizeof (fpos_t)
Victor Stinnere0be4232011-10-25 13:06:09 +02009970See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009971 else
9972 ac_cv_sizeof_fpos_t=0
9973 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009974fi
Matthias Kloseb9621712010-04-24 17:59:49 +00009975
Martin v. Löwis11437992002-04-12 09:54:03 +00009976fi
Pablo Galindoba421752021-05-03 20:33:17 +01009977{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5
9978printf "%s\n" "$ac_cv_sizeof_fpos_t" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009979
9980
9981
Pablo Galindoba421752021-05-03 20:33:17 +01009982printf "%s\n" "#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t" >>confdefs.h
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009983
Michael W. Hudson54241132001-12-07 15:38:26 +00009984
Thomas Wouters47b49bf2007-08-30 22:15:33 +00009985# The cast to long int works around a bug in the HP C Compiler
9986# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9987# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9988# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +01009989{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
9990printf %s "checking size of size_t... " >&6; }
9991if test ${ac_cv_sizeof_size_t+y}
9992then :
9993 printf %s "(cached) " >&6
9994else $as_nop
9995 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"
9996then :
Martin v. Löwis18e16552006-02-15 17:27:45 +00009997
Pablo Galindoba421752021-05-03 20:33:17 +01009998else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +00009999 if test "$ac_cv_type_size_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010000 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10001printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010002as_fn_error 77 "cannot compute sizeof (size_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020010003See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010004 else
10005 ac_cv_sizeof_size_t=0
10006 fi
Martin v. Löwis18e16552006-02-15 17:27:45 +000010007fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010008
Martin v. Löwis18e16552006-02-15 17:27:45 +000010009fi
Pablo Galindoba421752021-05-03 20:33:17 +010010010{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
10011printf "%s\n" "$ac_cv_sizeof_size_t" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010012
10013
10014
Pablo Galindoba421752021-05-03 20:33:17 +010010015printf "%s\n" "#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t" >>confdefs.h
Martin v. Löwis18e16552006-02-15 17:27:45 +000010016
10017
Jessica Clarkedec07572021-03-31 11:12:39 +010010018# The cast to long int works around a bug in the HP C Compiler,
10019# see AC_CHECK_SIZEOF for more information.
Pablo Galindoba421752021-05-03 20:33:17 +010010020{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking alignment of size_t" >&5
10021printf %s "checking alignment of size_t... " >&6; }
10022if test ${ac_cv_alignof_size_t+y}
10023then :
10024 printf %s "(cached) " >&6
10025else $as_nop
Jessica Clarkedec07572021-03-31 11:12:39 +010010026 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_size_t" "$ac_includes_default
Pablo Galindoba421752021-05-03 20:33:17 +010010027typedef struct { char x; size_t y; } ac__type_alignof_;"
10028then :
Jessica Clarkedec07572021-03-31 11:12:39 +010010029
Pablo Galindoba421752021-05-03 20:33:17 +010010030else $as_nop
Jessica Clarkedec07572021-03-31 11:12:39 +010010031 if test "$ac_cv_type_size_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010032 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10033printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Jessica Clarkedec07572021-03-31 11:12:39 +010010034as_fn_error 77 "cannot compute alignment of size_t
10035See \`config.log' for more details" "$LINENO" 5; }
10036 else
10037 ac_cv_alignof_size_t=0
10038 fi
10039fi
10040
10041fi
Pablo Galindoba421752021-05-03 20:33:17 +010010042{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_size_t" >&5
10043printf "%s\n" "$ac_cv_alignof_size_t" >&6; }
Jessica Clarkedec07572021-03-31 11:12:39 +010010044
10045
10046
Pablo Galindoba421752021-05-03 20:33:17 +010010047printf "%s\n" "#define ALIGNOF_SIZE_T $ac_cv_alignof_size_t" >>confdefs.h
Jessica Clarkedec07572021-03-31 11:12:39 +010010048
10049
Christian Heimes400adb02008-02-01 08:12:03 +000010050# The cast to long int works around a bug in the HP C Compiler
10051# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10052# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10053# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010054{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5
10055printf %s "checking size of pid_t... " >&6; }
10056if test ${ac_cv_sizeof_pid_t+y}
10057then :
10058 printf %s "(cached) " >&6
10059else $as_nop
10060 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pid_t))" "ac_cv_sizeof_pid_t" "$ac_includes_default"
10061then :
Christian Heimes400adb02008-02-01 08:12:03 +000010062
Pablo Galindoba421752021-05-03 20:33:17 +010010063else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010064 if test "$ac_cv_type_pid_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010065 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10066printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010067as_fn_error 77 "cannot compute sizeof (pid_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020010068See \`config.log' for more details" "$LINENO" 5; }
Christian Heimes400adb02008-02-01 08:12:03 +000010069 else
10070 ac_cv_sizeof_pid_t=0
10071 fi
10072fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010073
Christian Heimes400adb02008-02-01 08:12:03 +000010074fi
Pablo Galindoba421752021-05-03 20:33:17 +010010075{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5
10076printf "%s\n" "$ac_cv_sizeof_pid_t" >&6; }
Christian Heimes400adb02008-02-01 08:12:03 +000010077
10078
10079
Pablo Galindoba421752021-05-03 20:33:17 +010010080printf "%s\n" "#define SIZEOF_PID_T $ac_cv_sizeof_pid_t" >>confdefs.h
Christian Heimes400adb02008-02-01 08:12:03 +000010081
10082
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010083# The cast to long int works around a bug in the HP C Compiler
10084# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10085# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10086# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010087{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5
10088printf %s "checking size of uintptr_t... " >&6; }
10089if test ${ac_cv_sizeof_uintptr_t+y}
10090then :
10091 printf %s "(cached) " >&6
10092else $as_nop
10093 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (uintptr_t))" "ac_cv_sizeof_uintptr_t" "$ac_includes_default"
10094then :
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010095
Pablo Galindoba421752021-05-03 20:33:17 +010010096else $as_nop
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010097 if test "$ac_cv_type_uintptr_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010098 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10099printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010100as_fn_error 77 "cannot compute sizeof (uintptr_t)
10101See \`config.log' for more details" "$LINENO" 5; }
10102 else
10103 ac_cv_sizeof_uintptr_t=0
10104 fi
10105fi
10106
10107fi
Pablo Galindoba421752021-05-03 20:33:17 +010010108{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5
10109printf "%s\n" "$ac_cv_sizeof_uintptr_t" >&6; }
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010110
10111
10112
Pablo Galindoba421752021-05-03 20:33:17 +010010113printf "%s\n" "#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t" >>confdefs.h
Benjamin Petersondf6ff7b2016-09-06 13:53:14 -070010114
10115
Michael W. Hudson54241132001-12-07 15:38:26 +000010116
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010117
Pablo Galindoba421752021-05-03 20:33:17 +010010118 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
10119printf %s "checking for long double... " >&6; }
10120if test ${ac_cv_type_long_double+y}
10121then :
10122 printf %s "(cached) " >&6
10123else $as_nop
Eitan Adler3055c942018-05-15 22:58:09 -070010124 if test "$GCC" = yes; then
10125 ac_cv_type_long_double=yes
10126 else
10127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10128/* end confdefs.h. */
10129/* The Stardent Vistra knows sizeof (long double), but does
10130 not support it. */
10131 long double foo = 0.0L;
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010132int
Pablo Galindoba421752021-05-03 20:33:17 +010010133main (void)
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010134{
Eitan Adler3055c942018-05-15 22:58:09 -070010135static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8. */
10136 sizeof (double) <= sizeof (long double))];
10137test_array [0] = 0;
10138return test_array [0];
10139
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010140 ;
10141 return 0;
10142}
10143_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010144if ac_fn_c_try_compile "$LINENO"
10145then :
Eitan Adler3055c942018-05-15 22:58:09 -070010146 ac_cv_type_long_double=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010147else $as_nop
Eitan Adler3055c942018-05-15 22:58:09 -070010148 ac_cv_type_long_double=no
10149fi
Pablo Galindoba421752021-05-03 20:33:17 +010010150rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Eitan Adler3055c942018-05-15 22:58:09 -070010151 fi
10152fi
Pablo Galindoba421752021-05-03 20:33:17 +010010153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
10154printf "%s\n" "$ac_cv_type_long_double" >&6; }
Eitan Adler3055c942018-05-15 22:58:09 -070010155 if test $ac_cv_type_long_double = yes; then
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010156
Pablo Galindoba421752021-05-03 20:33:17 +010010157printf "%s\n" "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010158
Eitan Adler3055c942018-05-15 22:58:09 -070010159 fi
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010160
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010161# The cast to long int works around a bug in the HP C Compiler
10162# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10163# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10164# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010165{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5
10166printf %s "checking size of long double... " >&6; }
10167if test ${ac_cv_sizeof_long_double+y}
10168then :
10169 printf %s "(cached) " >&6
10170else $as_nop
10171 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double" "$ac_includes_default"
10172then :
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010173
Pablo Galindoba421752021-05-03 20:33:17 +010010174else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010175 if test "$ac_cv_type_long_double" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010176 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10177printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010178as_fn_error 77 "cannot compute sizeof (long double)
Victor Stinnere0be4232011-10-25 13:06:09 +020010179See \`config.log' for more details" "$LINENO" 5; }
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010180 else
10181 ac_cv_sizeof_long_double=0
10182 fi
10183fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010184
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010185fi
Pablo Galindoba421752021-05-03 20:33:17 +010010186{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5
10187printf "%s\n" "$ac_cv_sizeof_long_double" >&6; }
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010188
10189
10190
Pablo Galindoba421752021-05-03 20:33:17 +010010191printf "%s\n" "#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double" >>confdefs.h
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010192
10193
Travis E. Oliphant9b307842007-10-12 22:06:37 +000010194
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010195# The cast to long int works around a bug in the HP C Compiler
10196# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10197# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10198# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010199{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5
10200printf %s "checking size of _Bool... " >&6; }
10201if test ${ac_cv_sizeof__Bool+y}
10202then :
10203 printf %s "(cached) " >&6
10204else $as_nop
10205 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (_Bool))" "ac_cv_sizeof__Bool" "$ac_includes_default"
10206then :
Thomas Woutersb2137042007-02-01 18:02:27 +000010207
Pablo Galindoba421752021-05-03 20:33:17 +010010208else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010209 if test "$ac_cv_type__Bool" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010210 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10211printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010212as_fn_error 77 "cannot compute sizeof (_Bool)
Victor Stinnere0be4232011-10-25 13:06:09 +020010213See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010214 else
10215 ac_cv_sizeof__Bool=0
10216 fi
Thomas Woutersb2137042007-02-01 18:02:27 +000010217fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010218
Thomas Woutersb2137042007-02-01 18:02:27 +000010219fi
Pablo Galindoba421752021-05-03 20:33:17 +010010220{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5
10221printf "%s\n" "$ac_cv_sizeof__Bool" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010222
10223
10224
Pablo Galindoba421752021-05-03 20:33:17 +010010225printf "%s\n" "#define SIZEOF__BOOL $ac_cv_sizeof__Bool" >>confdefs.h
Thomas Woutersb2137042007-02-01 18:02:27 +000010226
10227
Thomas Woutersb2137042007-02-01 18:02:27 +000010228
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010229# The cast to long int works around a bug in the HP C Compiler
10230# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10231# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10232# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010233{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
10234printf %s "checking size of off_t... " >&6; }
10235if test ${ac_cv_sizeof_off_t+y}
10236then :
10237 printf %s "(cached) " >&6
10238else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010239 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010240#ifdef HAVE_SYS_TYPES_H
10241#include <sys/types.h>
10242#endif
10243
Pablo Galindoba421752021-05-03 20:33:17 +010010244"
10245then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010246
Pablo Galindoba421752021-05-03 20:33:17 +010010247else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010248 if test "$ac_cv_type_off_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010249 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10250printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010251as_fn_error 77 "cannot compute sizeof (off_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020010252See \`config.log' for more details" "$LINENO" 5; }
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010253 else
10254 ac_cv_sizeof_off_t=0
10255 fi
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010256fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010257
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010258fi
Pablo Galindoba421752021-05-03 20:33:17 +010010259{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
10260printf "%s\n" "$ac_cv_sizeof_off_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000010261
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010262
10263
Pablo Galindoba421752021-05-03 20:33:17 +010010264printf "%s\n" "#define SIZEOF_OFF_T $ac_cv_sizeof_off_t" >>confdefs.h
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010265
Michael W. Hudson54241132001-12-07 15:38:26 +000010266
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010267
Pablo Galindoba421752021-05-03 20:33:17 +010010268{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5
10269printf %s "checking whether to enable large file support... " >&6; }
Mark Dickinson2df5d282009-12-31 21:22:50 +000010270if test "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
Guido van Rossum96f2eb91999-04-10 16:02:18 +000010271 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010272
Pablo Galindoba421752021-05-03 20:33:17 +010010273printf "%s\n" "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000010274
Pablo Galindoba421752021-05-03 20:33:17 +010010275 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10276printf "%s\n" "yes" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010277else
Pablo Galindoba421752021-05-03 20:33:17 +010010278 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10279printf "%s\n" "no" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000010280fi
10281
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010282# The cast to long int works around a bug in the HP C Compiler
10283# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10284# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10285# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010286{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
10287printf %s "checking size of time_t... " >&6; }
10288if test ${ac_cv_sizeof_time_t+y}
10289then :
10290 printf %s "(cached) " >&6
10291else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010292 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010293#ifdef HAVE_SYS_TYPES_H
10294#include <sys/types.h>
10295#endif
10296#ifdef HAVE_TIME_H
10297#include <time.h>
10298#endif
10299
Pablo Galindoba421752021-05-03 20:33:17 +010010300"
10301then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010302
Pablo Galindoba421752021-05-03 20:33:17 +010010303else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010304 if test "$ac_cv_type_time_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010305 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10306printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010307as_fn_error 77 "cannot compute sizeof (time_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020010308See \`config.log' for more details" "$LINENO" 5; }
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010309 else
10310 ac_cv_sizeof_time_t=0
10311 fi
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010312fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010313
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010314fi
Pablo Galindoba421752021-05-03 20:33:17 +010010315{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
10316printf "%s\n" "$ac_cv_sizeof_time_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000010317
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010318
10319
Pablo Galindoba421752021-05-03 20:33:17 +010010320printf "%s\n" "#define SIZEOF_TIME_T $ac_cv_sizeof_time_t" >>confdefs.h
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010321
Michael W. Hudson54241132001-12-07 15:38:26 +000010322
10323
Trent Mick635f6fb2000-08-23 21:33:05 +000010324# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +000010325ac_save_cc="$CC"
10326if test "$ac_cv_kpthread" = "yes"
10327then CC="$CC -Kpthread"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000010328elif test "$ac_cv_kthread" = "yes"
10329then CC="$CC -Kthread"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000010330elif test "$ac_cv_pthread" = "yes"
10331then CC="$CC -pthread"
Martin v. Löwis123cbd22001-07-19 14:21:10 +000010332fi
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010333
Pablo Galindoba421752021-05-03 20:33:17 +010010334{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5
10335printf %s "checking for pthread_t... " >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000010336have_pthread_t=no
Matthias Kloseb9621712010-04-24 17:59:49 +000010337cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000010338/* end confdefs.h. */
Matthias Kloseb159a552010-04-25 21:00:44 +000010339
10340 #include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010341int
Pablo Galindoba421752021-05-03 20:33:17 +010010342main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000010343{
Guido van Rossum12580492000-09-24 16:47:19 +000010344pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +000010345 ;
10346 return 0;
10347}
Matthias Kloseb159a552010-04-25 21:00:44 +000010348
Martin v. Löwis11437992002-04-12 09:54:03 +000010349_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010350if ac_fn_c_try_compile "$LINENO"
10351then :
Trent Mick635f6fb2000-08-23 21:33:05 +000010352 have_pthread_t=yes
Trent Mick635f6fb2000-08-23 21:33:05 +000010353fi
Pablo Galindoba421752021-05-03 20:33:17 +010010354rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10355{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5
10356printf "%s\n" "$have_pthread_t" >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000010357if test "$have_pthread_t" = yes ; then
Matthias Kloseb9621712010-04-24 17:59:49 +000010358 # The cast to long int works around a bug in the HP C Compiler
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010359# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10360# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10361# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010362{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
10363printf %s "checking size of pthread_t... " >&6; }
10364if test ${ac_cv_sizeof_pthread_t+y}
10365then :
10366 printf %s "(cached) " >&6
10367else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010368 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" "
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010369#ifdef HAVE_PTHREAD_H
10370#include <pthread.h>
10371#endif
10372
Pablo Galindoba421752021-05-03 20:33:17 +010010373"
10374then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010375
Pablo Galindoba421752021-05-03 20:33:17 +010010376else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010377 if test "$ac_cv_type_pthread_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010378 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10379printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010380as_fn_error 77 "cannot compute sizeof (pthread_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020010381See \`config.log' for more details" "$LINENO" 5; }
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010382 else
10383 ac_cv_sizeof_pthread_t=0
10384 fi
Trent Mick635f6fb2000-08-23 21:33:05 +000010385fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010386
Trent Mick635f6fb2000-08-23 21:33:05 +000010387fi
Pablo Galindoba421752021-05-03 20:33:17 +010010388{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
10389printf "%s\n" "$ac_cv_sizeof_pthread_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000010390
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010391
10392
Pablo Galindoba421752021-05-03 20:33:17 +010010393printf "%s\n" "#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t" >>confdefs.h
Trent Mick635f6fb2000-08-23 21:33:05 +000010394
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000010395
Trent Mick635f6fb2000-08-23 21:33:05 +000010396fi
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010397
10398# Issue #25658: POSIX hasn't defined that pthread_key_t is compatible with int.
10399# This checking will be unnecessary after removing deprecated TLS API.
10400# The cast to long int works around a bug in the HP C Compiler
10401# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10402# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10403# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010010404{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of pthread_key_t" >&5
10405printf %s "checking size of pthread_key_t... " >&6; }
10406if test ${ac_cv_sizeof_pthread_key_t+y}
10407then :
10408 printf %s "(cached) " >&6
10409else $as_nop
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010410 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_key_t))" "ac_cv_sizeof_pthread_key_t" "#include <pthread.h>
Pablo Galindoba421752021-05-03 20:33:17 +010010411"
10412then :
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010413
Pablo Galindoba421752021-05-03 20:33:17 +010010414else $as_nop
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010415 if test "$ac_cv_type_pthread_key_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010010416 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10417printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010418as_fn_error 77 "cannot compute sizeof (pthread_key_t)
10419See \`config.log' for more details" "$LINENO" 5; }
10420 else
10421 ac_cv_sizeof_pthread_key_t=0
10422 fi
10423fi
10424
10425fi
Pablo Galindoba421752021-05-03 20:33:17 +010010426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_key_t" >&5
10427printf "%s\n" "$ac_cv_sizeof_pthread_key_t" >&6; }
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010428
10429
10430
Pablo Galindoba421752021-05-03 20:33:17 +010010431printf "%s\n" "#define SIZEOF_PTHREAD_KEY_T $ac_cv_sizeof_pthread_key_t" >>confdefs.h
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010432
10433
Pablo Galindoba421752021-05-03 20:33:17 +010010434{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_key_t is compatible with int" >&5
10435printf %s "checking whether pthread_key_t is compatible with int... " >&6; }
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010436if test "$ac_cv_sizeof_pthread_key_t" -eq "$ac_cv_sizeof_int" ; then
10437 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10438/* end confdefs.h. */
10439#include <pthread.h>
10440int
Pablo Galindoba421752021-05-03 20:33:17 +010010441main (void)
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010442{
10443pthread_key_t k; k * 1;
10444 ;
10445 return 0;
10446}
10447_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010448if ac_fn_c_try_compile "$LINENO"
10449then :
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010450 ac_pthread_key_t_is_arithmetic_type=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010451else $as_nop
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010452 ac_pthread_key_t_is_arithmetic_type=no
10453
10454fi
Pablo Galindoba421752021-05-03 20:33:17 +010010455rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10456 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pthread_key_t_is_arithmetic_type" >&5
10457printf "%s\n" "$ac_pthread_key_t_is_arithmetic_type" >&6; }
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010458 if test "$ac_pthread_key_t_is_arithmetic_type" = yes ; then
10459
Pablo Galindoba421752021-05-03 20:33:17 +010010460printf "%s\n" "#define PTHREAD_KEY_T_IS_COMPATIBLE_WITH_INT 1" >>confdefs.h
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010461
10462 fi
10463else
Pablo Galindoba421752021-05-03 20:33:17 +010010464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10465printf "%s\n" "no" >&6; }
Masayuki Yamamoto731e1892017-10-06 19:41:34 +090010466fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +000010467CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +000010468
Michael W. Hudson54241132001-12-07 15:38:26 +000010469
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010470case $ac_sys_system/$ac_sys_release in
Thomas Wouters49fd7fa2006-04-21 10:40:58 +000010471 Darwin/[01567]\..*)
Bob Ippolito7026a0a2005-03-28 23:23:47 +000010472 OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000"
10473 ;;
10474 Darwin/*)
10475 OTHER_LIBTOOL_OPT=""
10476 ;;
10477esac
10478
10479
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010480
Bob Ippolito7026a0a2005-03-28 23:23:47 +000010481case $ac_sys_system/$ac_sys_release in
Thomas Wouters49fd7fa2006-04-21 10:40:58 +000010482 Darwin/[01567]\..*)
Thomas Wouters477c8d52006-05-27 19:21:47 +000010483 LIBTOOL_CRUFT="-framework System -lcc_dynamic"
10484 if test "${enable_universalsdk}"; then
10485 :
10486 else
Ronald Oussorene3da75a2010-02-11 13:38:58 +000010487 LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`"
Thomas Wouters477c8d52006-05-27 19:21:47 +000010488 fi
Jack Jansenb36687a2004-07-16 08:43:47 +000010489 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000010490 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +000010491 Darwin/*)
Ronald Oussoren9812a6c2010-02-07 11:53:18 +000010492 gcc_version=`gcc -dumpversion`
Bob Ippolito7026a0a2005-03-28 23:23:47 +000010493 if test ${gcc_version} '<' 4.0
10494 then
10495 LIBTOOL_CRUFT="-lcc_dynamic"
10496 else
10497 LIBTOOL_CRUFT=""
10498 fi
Pablo Galindoba421752021-05-03 20:33:17 +010010499 if test "$cross_compiling" = yes
10500then :
Ronald Oussoren3c064c12009-09-08 07:12:42 +000010501 ac_osx_32bit=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010502else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010504/* end confdefs.h. */
Ronald Oussoren3c064c12009-09-08 07:12:42 +000010505
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010506 #include <unistd.h>
10507 int main(int argc, char*argv[])
10508 {
10509 if (sizeof(long) == 4) {
10510 return 0;
10511 } else {
10512 return 1;
10513 }
Ronald Oussoren3c064c12009-09-08 07:12:42 +000010514 }
10515
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010516_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010517if ac_fn_c_try_run "$LINENO"
10518then :
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010519 ac_osx_32bit=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010520else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010521 ac_osx_32bit=no
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010522fi
Matthias Kloseb9621712010-04-24 17:59:49 +000010523rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10524 conftest.$ac_objext conftest.beam conftest.$ac_ext
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010525fi
10526
10527
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010528 if test "${ac_osx_32bit}" = "yes"; then
Ronald Oussorene3da75a2010-02-11 13:38:58 +000010529 case `/usr/bin/arch` in
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010530 i386)
10531 MACOSX_DEFAULT_ARCH="i386"
10532 ;;
10533 ppc)
10534 MACOSX_DEFAULT_ARCH="ppc"
10535 ;;
10536 *)
Ronald Oussoren41761932020-11-08 10:05:27 +010010537 as_fn_error $? "Unexpected output of 'arch' on macOS" "$LINENO" 5
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010538 ;;
10539 esac
10540 else
Ronald Oussorene3da75a2010-02-11 13:38:58 +000010541 case `/usr/bin/arch` in
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010542 i386)
10543 MACOSX_DEFAULT_ARCH="x86_64"
10544 ;;
10545 ppc)
10546 MACOSX_DEFAULT_ARCH="ppc64"
Ronald Oussoren41761932020-11-08 10:05:27 +010010547 ;;
10548 arm64)
10549 MACOSX_DEFAULT_ARCH="arm64"
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010550 ;;
10551 *)
Ronald Oussoren41761932020-11-08 10:05:27 +010010552 as_fn_error $? "Unexpected output of 'arch' on macOS" "$LINENO" 5
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010553 ;;
10554 esac
10555
Ronald Oussoren5bbab3e2009-09-06 11:01:15 +000010556 fi
10557
10558 LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}"
Jack Jansenb36687a2004-07-16 08:43:47 +000010559 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000010560 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010561esac
Pablo Galindoba421752021-05-03 20:33:17 +010010562{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5
10563printf %s "checking for --enable-framework... " >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000010564if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010565then
Skip Montanarodecc6a42003-01-01 20:07:49 +000010566 BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +000010567 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +000010568 # in the build location.
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010569
Pablo Galindoba421752021-05-03 20:33:17 +010010570printf "%s\n" "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000010571
Pablo Galindoba421752021-05-03 20:33:17 +010010572 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10573printf "%s\n" "yes" >&6; }
Ronald Oussoren99aab652009-06-08 21:22:57 +000010574 if test $enable_shared = "yes"
10575 then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020010576 as_fn_error $? "Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" "$LINENO" 5
Ronald Oussoren99aab652009-06-08 21:22:57 +000010577 fi
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010578else
Pablo Galindoba421752021-05-03 20:33:17 +010010579 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10580printf "%s\n" "no" >&6; }
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010581fi
10582
Pablo Galindoba421752021-05-03 20:33:17 +010010583{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5
10584printf %s "checking for dyld... " >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000010585case $ac_sys_system/$ac_sys_release in
10586 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010587
Pablo Galindoba421752021-05-03 20:33:17 +010010588printf "%s\n" "#define WITH_DYLD 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000010589
Pablo Galindoba421752021-05-03 20:33:17 +010010590 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5
10591printf "%s\n" "always on for Darwin" >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000010592 ;;
10593 *)
Pablo Galindoba421752021-05-03 20:33:17 +010010594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10595printf "%s\n" "no" >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000010596 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +000010597esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010598
Guido van Rossum0a516c91994-09-12 10:58:40 +000010599# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +000010600
Michael W. Hudson54241132001-12-07 15:38:26 +000010601
10602
10603
10604
Benjamin Peterson99f03762010-04-11 22:15:28 +000010605
Thomas Wouters477c8d52006-05-27 19:21:47 +000010606
doko@ubuntu.comd5537d02013-03-21 13:21:49 -070010607# SHLIB_SUFFIX is the extension of shared libraries `(including the dot!)
10608# -- usually .so, .sl on HP-UX, .dll on Cygwin
Pablo Galindoba421752021-05-03 20:33:17 +010010609{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the extension of shared libraries" >&5
10610printf %s "checking the extension of shared libraries... " >&6; }
doko@ubuntu.comd5537d02013-03-21 13:21:49 -070010611if test -z "$SHLIB_SUFFIX"; then
10612 case $ac_sys_system in
10613 hp*|HP*)
10614 case `uname -m` in
10615 ia64) SHLIB_SUFFIX=.so;;
10616 *) SHLIB_SUFFIX=.sl;;
10617 esac
10618 ;;
10619 CYGWIN*) SHLIB_SUFFIX=.dll;;
10620 *) SHLIB_SUFFIX=.so;;
10621 esac
10622fi
Pablo Galindoba421752021-05-03 20:33:17 +010010623{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SHLIB_SUFFIX" >&5
10624printf "%s\n" "$SHLIB_SUFFIX" >&6; }
Thomas Wouters477c8d52006-05-27 19:21:47 +000010625
Guido van Rossum0a516c91994-09-12 10:58:40 +000010626# LDSHARED is the ld *command* used to create shared library
Benjamin Peterson06930632017-09-04 16:36:05 -070010627# -- "cc -G" on SunOS 5.x.
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010628# (Shared libraries in this instance are shared modules to be loaded into
10629# Python, as opposed to building Python itself as a shared library.)
Pablo Galindoba421752021-05-03 20:33:17 +010010630{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5
10631printf %s "checking LDSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000010632if test -z "$LDSHARED"
10633then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010634 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010635 AIX*)
Martin Panter395733d2016-11-20 07:56:37 +000010636 BLDSHARED="Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Martin Panter5de141f2016-08-27 04:00:19 +000010637 LDSHARED="\$(LIBPL)/ld_so_aix \$(CC) -bI:\$(LIBPL)/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010638 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000010639 SunOS/5*)
Benjamin Peterson99f03762010-04-11 22:15:28 +000010640 if test "$GCC" = "yes" ; then
10641 LDSHARED='$(CC) -shared'
10642 LDCXXSHARED='$(CXX) -shared'
10643 else
10644 LDSHARED='$(CC) -G'
10645 LDCXXSHARED='$(CXX) -G'
Greg Ward57c9a6632000-05-26 12:22:54 +000010646 fi ;;
Thomas Hellerf44b9a12008-04-04 10:18:23 +000010647 hp*|HP*)
Benjamin Peterson99f03762010-04-11 22:15:28 +000010648 if test "$GCC" = "yes" ; then
10649 LDSHARED='$(CC) -shared'
10650 LDCXXSHARED='$(CXX) -shared'
10651 else
Rob Boehne9d25bd12017-12-06 11:58:17 -060010652 LDSHARED='$(CC) -b'
Benjamin Peterson62ed6be2017-12-21 21:43:09 -080010653 LDCXXSHARED='$(CXX) -b'
Thomas Hellerf44b9a12008-04-04 10:18:23 +000010654 fi ;;
Jack Jansen418c3b12001-11-14 10:59:57 +000010655 Darwin/1.3*)
Antoine Pitroud4958c22010-10-13 17:01:10 +000010656 LDSHARED='$(CC) -bundle'
10657 LDCXXSHARED='$(CXX) -bundle'
Jack Jansena3891ea2001-09-07 14:25:12 +000010658 if test "$enable_framework" ; then
10659 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000010660 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
10661 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Benjamin Peterson99f03762010-04-11 22:15:28 +000010662 LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000010663 else
10664 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +000010665 LDSHARED="$LDSHARED -undefined suppress"
Benjamin Peterson99f03762010-04-11 22:15:28 +000010666 LDCXXSHARED="$LDCXXSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +000010667 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000010668 Darwin/1.4*|Darwin/5.*|Darwin/6.*)
Antoine Pitroud4958c22010-10-13 17:01:10 +000010669 LDSHARED='$(CC) -bundle'
10670 LDCXXSHARED='$(CXX) -bundle'
Jack Jansene578a632001-08-15 01:27:14 +000010671 if test "$enable_framework" ; then
10672 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000010673 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
10674 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Benjamin Peterson99f03762010-04-11 22:15:28 +000010675 LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000010676 else
Michael W. Hudson594bc802002-03-07 09:59:15 +000010677 # No framework, use the Python app as bundle-loader
10678 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
Jack Jansenc28fc372003-02-25 13:14:43 +000010679 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
Benjamin Peterson99f03762010-04-11 22:15:28 +000010680 LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010681 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000010682 Darwin/*)
10683 # Use -undefined dynamic_lookup whenever possible (10.3 and later).
10684 # This allows an extension to be used in any Python
Thomas Wouters89d996e2007-09-08 17:39:28 +000010685
Ned Deily36820b62014-06-25 13:44:22 -070010686 dep_target_major=`echo ${MACOSX_DEPLOYMENT_TARGET} | \
10687 sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'`
10688 dep_target_minor=`echo ${MACOSX_DEPLOYMENT_TARGET} | \
10689 sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'`
10690 if test ${dep_target_major} -eq 10 && \
10691 test ${dep_target_minor} -le 2
Jack Jansen6b08a402004-06-03 12:41:45 +000010692 then
Ned Deily36820b62014-06-25 13:44:22 -070010693 # building for OS X 10.0 through 10.2
Ned Deily87031782021-05-02 20:28:43 -040010694 as_fn_error $? "MACOSX_DEPLOYMENT_TARGET too old ($MACOSX_DEPLOYMENT_TARGET), only 10.3 or later is supported" "$LINENO" 5
Ned Deily36820b62014-06-25 13:44:22 -070010695 else
10696 # building for OS X 10.3 and later
10697 LDSHARED='$(CC) -bundle -undefined dynamic_lookup'
10698 LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup'
10699 BLDSHARED="$LDSHARED"
Jack Jansen6b08a402004-06-03 12:41:45 +000010700 fi
10701 ;;
pxinwr32f5fdd2019-02-27 19:09:28 +080010702 Linux*|GNU*|QNX*|VxWorks*)
Benjamin Peterson99f03762010-04-11 22:15:28 +000010703 LDSHARED='$(CC) -shared'
10704 LDCXXSHARED='$(CXX) -shared';;
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +000010705 FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +000010706 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +000010707 then
Antoine Pitroud4958c22010-10-13 17:01:10 +000010708 LDSHARED='$(CC) -shared'
10709 LDCXXSHARED='$(CXX) -shared'
Guido van Rossum0286ae82000-08-29 15:06:49 +000010710 else
Antoine Pitroud4958c22010-10-13 17:01:10 +000010711 LDSHARED="ld -Bshareable"
Guido van Rossum0286ae82000-08-29 15:06:49 +000010712 fi;;
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +000010713 OpenBSD*)
10714 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
10715 then
Antoine Pitroud4958c22010-10-13 17:01:10 +000010716 LDSHARED='$(CC) -shared $(CCSHARED)'
10717 LDCXXSHARED='$(CXX) -shared $(CCSHARED)'
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +000010718 else
10719 case `uname -r` in
10720 [01].* | 2.[0-7] | 2.[0-7].*)
10721 LDSHARED="ld -Bshareable ${LDFLAGS}"
10722 ;;
10723 *)
Antoine Pitroud4958c22010-10-13 17:01:10 +000010724 LDSHARED='$(CC) -shared $(CCSHARED)'
10725 LDCXXSHARED='$(CXX) -shared $(CCSHARED)'
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +000010726 ;;
10727 esac
10728 fi;;
Benjamin Peterson99f03762010-04-11 22:15:28 +000010729 NetBSD*|DragonFly*)
Antoine Pitrouece919e2011-01-02 20:45:21 +000010730 LDSHARED='$(CC) -shared'
10731 LDCXXSHARED='$(CXX) -shared';;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010732 OpenUNIX*|UnixWare*)
Benjamin Peterson99f03762010-04-11 22:15:28 +000010733 if test "$GCC" = "yes" ; then
10734 LDSHARED='$(CC) -shared'
10735 LDCXXSHARED='$(CXX) -shared'
10736 else
10737 LDSHARED='$(CC) -G'
10738 LDCXXSHARED='$(CXX) -G'
Martin v. Löwisbec19582001-03-21 15:57:54 +000010739 fi;;
Benjamin Peterson99f03762010-04-11 22:15:28 +000010740 SCO_SV*)
10741 LDSHARED='$(CC) -Wl,-G,-Bexport'
10742 LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';;
10743 CYGWIN*)
10744 LDSHARED="gcc -shared -Wl,--enable-auto-image-base"
10745 LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010746 *) LDSHARED="ld";;
10747 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010748fi
Pablo Galindoba421752021-05-03 20:33:17 +010010749{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5
10750printf "%s\n" "$LDSHARED" >&6; }
Benjamin Peterson99f03762010-04-11 22:15:28 +000010751LDCXXSHARED=${LDCXXSHARED-$LDSHARED}
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010752BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +000010753# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010754# library (module) -- this is only needed for a few systems
Pablo Galindoba421752021-05-03 20:33:17 +010010755{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5
10756printf %s "checking CCSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000010757if test -z "$CCSHARED"
10758then
Guido van Rossum07397971997-04-29 21:49:50 +000010759 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +000010760 SunOS*) if test "$GCC" = yes;
Skip Montanaroeb33e5a2007-08-17 12:57:41 +000010761 then CCSHARED="-fPIC";
10762 elif test `uname -p` = sparc;
10763 then CCSHARED="-xcode=pic32";
10764 else CCSHARED="-Kpic";
10765 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +000010766 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +000010767 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +000010768 else CCSHARED="+z";
10769 fi;;
Xavier de Gaye2a352b62017-01-04 21:51:16 +010010770 Linux-android*) ;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010771 Linux*|GNU*) CCSHARED="-fPIC";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000010772 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010773 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000010774 if test "$GCC" = "yes"
10775 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010776 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +000010777 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000010778 SCO_SV*)
10779 if test "$GCC" = "yes"
10780 then CCSHARED="-fPIC"
10781 else CCSHARED="-Kpic -belf"
10782 fi;;
pxinwr32f5fdd2019-02-27 19:09:28 +080010783 VxWorks*)
10784 CCSHARED="-fpic -D__SO_PICABILINUX__ -ftls-model=global-dynamic"
Guido van Rossum0a516c91994-09-12 10:58:40 +000010785 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010786fi
Pablo Galindoba421752021-05-03 20:33:17 +010010787{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5
10788printf "%s\n" "$CCSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000010789# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010790# the python executable -- this is only needed for a few systems
Pablo Galindoba421752021-05-03 20:33:17 +010010791{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5
10792printf %s "checking LINKFORSHARED... " >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000010793if test -z "$LINKFORSHARED"
10794then
Guido van Rossum07397971997-04-29 21:49:50 +000010795 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010796 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +000010797 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +000010798 LINKFORSHARED="-Wl,-E -Wl,+s";;
10799# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Xavier de Gaye2a352b62017-01-04 21:51:16 +010010800 Linux-android*) LINKFORSHARED="-pie -Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010801 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010802 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +000010803 Darwin/*)
Benjamin Peterson9c80cac2009-05-23 16:34:23 +000010804 LINKFORSHARED="$extra_undefs -framework CoreFoundation"
Ned Deily5bbbc732019-07-02 03:12:18 -040010805
10806 # Issue #18075: the default maximum stack size (8MBytes) is too
10807 # small for the default recursion limit. Increase the stack size
10808 # to ensure that tests don't crash
Ronald Oussoren1a057ba2019-08-01 07:43:07 +020010809 # Note: This matches the value of THREAD_STACK_SIZE in
10810 # thread_pthread.h
Ned Deily5bbbc732019-07-02 03:12:18 -040010811 LINKFORSHARED="-Wl,-stack_size,1000000 $LINKFORSHARED"
10812
Jack Jansene578a632001-08-15 01:27:14 +000010813 if test "$enable_framework"
10814 then
Jack Jansenda49e192005-01-07 13:08:22 +000010815 LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000010816 fi
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000010817 LINKFORSHARED="$LINKFORSHARED";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010818 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000010819 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +000010820 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000010821 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*)
Guido van Rossumdf693651999-01-07 21:50:41 +000010822 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
10823 then
10824 LINKFORSHARED="-Wl,--export-dynamic"
10825 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010826 SunOS/5*) case $CC in
10827 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +000010828 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +000010829 then
10830 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010831 fi;;
10832 esac;;
Jason Tishler30765592003-09-04 11:04:06 +000010833 CYGWIN*)
10834 if test $enable_shared = "no"
10835 then
10836 LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)'
10837 fi;;
Benjamin Petersonde9c8692008-07-01 18:23:09 +000010838 QNX*)
10839 # -Wl,-E causes the symbols to be added to the dynamic
10840 # symbol table so that they can be found when a module
10841 # is loaded. -N 2048K causes the stack size to be set
10842 # to 2048 kilobytes so that the stack doesn't overflow
10843 # when running test_compile.py.
10844 LINKFORSHARED='-Wl,-E -N 2048K';;
pxinwr32f5fdd2019-02-27 19:09:28 +080010845 VxWorks*)
pxinwrc1174262020-12-15 06:14:43 +080010846 LINKFORSHARED='-Wl,-export-dynamic';;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010847 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010848fi
Pablo Galindoba421752021-05-03 20:33:17 +010010849{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5
10850printf "%s\n" "$LINKFORSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000010851
Michael W. Hudson54241132001-12-07 15:38:26 +000010852
Benjamin Peterson8f95cc22008-07-16 02:23:25 +000010853
Pablo Galindoba421752021-05-03 20:33:17 +010010854{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5
10855printf %s "checking CFLAGSFORSHARED... " >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010856if test ! "$LIBRARY" = "$LDLIBRARY"
10857then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +000010858 case $ac_sys_system in
10859 CYGWIN*)
10860 # Cygwin needs CCSHARED when building extension DLLs
10861 # but not when building the interpreter DLL.
10862 CFLAGSFORSHARED='';;
10863 *)
10864 CFLAGSFORSHARED='$(CCSHARED)'
10865 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010866fi
Pablo Galindoba421752021-05-03 20:33:17 +010010867{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5
10868printf "%s\n" "$CFLAGSFORSHARED" >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010869
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010870# SHLIBS are libraries (except -lc and -lm) to link to the python shared
10871# library (with --enable-shared).
10872# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +000010873# symbols, this must be set to $(LIBS) (expanded by make). We do this even
10874# if it is not required, since it creates a dependency of the shared library
10875# to LIBS. This, in turn, means that applications linking the shared libpython
10876# don't need to link LIBS explicitly. The default should be only changed
10877# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010878
Pablo Galindoba421752021-05-03 20:33:17 +010010879{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5
10880printf %s "checking SHLIBS... " >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010881case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010882 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +000010883 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010884esac
Pablo Galindoba421752021-05-03 20:33:17 +010010885{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5
10886printf "%s\n" "$SHLIBS" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010887
10888
Guido van Rossum627b2d71993-12-24 10:39:16 +000010889# checks for libraries
Pablo Galindoba421752021-05-03 20:33:17 +010010890{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sendfile in -lsendfile" >&5
10891printf %s "checking for sendfile in -lsendfile... " >&6; }
10892if test ${ac_cv_lib_sendfile_sendfile+y}
10893then :
10894 printf %s "(cached) " >&6
10895else $as_nop
Georg Brandl941f9562011-02-25 15:21:47 +000010896 ac_check_lib_save_LIBS=$LIBS
10897LIBS="-lsendfile $LIBS"
10898cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10899/* end confdefs.h. */
10900
10901/* Override any GCC internal prototype to avoid an error.
10902 Use char because int might match the return type of a GCC
10903 builtin and then its argument prototype would still apply. */
Georg Brandl941f9562011-02-25 15:21:47 +000010904char sendfile ();
10905int
Pablo Galindoba421752021-05-03 20:33:17 +010010906main (void)
Georg Brandl941f9562011-02-25 15:21:47 +000010907{
10908return sendfile ();
10909 ;
10910 return 0;
10911}
10912_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010913if ac_fn_c_try_link "$LINENO"
10914then :
Georg Brandl941f9562011-02-25 15:21:47 +000010915 ac_cv_lib_sendfile_sendfile=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010916else $as_nop
Georg Brandl941f9562011-02-25 15:21:47 +000010917 ac_cv_lib_sendfile_sendfile=no
10918fi
Pablo Galindoba421752021-05-03 20:33:17 +010010919rm -f core conftest.err conftest.$ac_objext conftest.beam \
Georg Brandl941f9562011-02-25 15:21:47 +000010920 conftest$ac_exeext conftest.$ac_ext
10921LIBS=$ac_check_lib_save_LIBS
10922fi
Pablo Galindoba421752021-05-03 20:33:17 +010010923{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sendfile_sendfile" >&5
10924printf "%s\n" "$ac_cv_lib_sendfile_sendfile" >&6; }
10925if test "x$ac_cv_lib_sendfile_sendfile" = xyes
10926then :
10927 printf "%s\n" "#define HAVE_LIBSENDFILE 1" >>confdefs.h
Georg Brandl941f9562011-02-25 15:21:47 +000010928
10929 LIBS="-lsendfile $LIBS"
10930
10931fi
10932
Pablo Galindoba421752021-05-03 20:33:17 +010010933{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
10934printf %s "checking for dlopen in -ldl... " >&6; }
10935if test ${ac_cv_lib_dl_dlopen+y}
10936then :
10937 printf %s "(cached) " >&6
10938else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000010939 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010940LIBS="-ldl $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000010941cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000010942/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010943
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010944/* Override any GCC internal prototype to avoid an error.
10945 Use char because int might match the return type of a GCC
10946 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010947char dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010948int
Pablo Galindoba421752021-05-03 20:33:17 +010010949main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000010950{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010951return dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010952 ;
10953 return 0;
10954}
10955_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010956if ac_fn_c_try_link "$LINENO"
10957then :
Martin v. Löwis11437992002-04-12 09:54:03 +000010958 ac_cv_lib_dl_dlopen=yes
Pablo Galindoba421752021-05-03 20:33:17 +010010959else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000010960 ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000010961fi
Pablo Galindoba421752021-05-03 20:33:17 +010010962rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000010963 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010964LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000010965fi
Pablo Galindoba421752021-05-03 20:33:17 +010010966{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
10967printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
10968if test "x$ac_cv_lib_dl_dlopen" = xyes
10969then :
10970 printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +000010971
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010972 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +000010973
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010974fi
10975 # Dynamic linking for SunOS/Solaris and SYSV
Pablo Galindoba421752021-05-03 20:33:17 +010010976{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
10977printf %s "checking for shl_load in -ldld... " >&6; }
10978if test ${ac_cv_lib_dld_shl_load+y}
10979then :
10980 printf %s "(cached) " >&6
10981else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000010982 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010983LIBS="-ldld $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000010984cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000010985/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010986
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010987/* Override any GCC internal prototype to avoid an error.
10988 Use char because int might match the return type of a GCC
10989 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010990char shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010991int
Pablo Galindoba421752021-05-03 20:33:17 +010010992main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000010993{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000010994return shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010995 ;
10996 return 0;
10997}
10998_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010010999if ac_fn_c_try_link "$LINENO"
11000then :
Martin v. Löwis11437992002-04-12 09:54:03 +000011001 ac_cv_lib_dld_shl_load=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011002else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000011003 ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000011004fi
Pablo Galindoba421752021-05-03 20:33:17 +010011005rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000011006 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011007LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000011008fi
Pablo Galindoba421752021-05-03 20:33:17 +010011009{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
11010printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
11011if test "x$ac_cv_lib_dld_shl_load" = xyes
11012then :
11013 printf "%s\n" "#define HAVE_LIBDLD 1" >>confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +000011014
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011015 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011016
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011017fi
11018 # Dynamic linking for HP-UX
Martin v. Löwis519adae2003-09-20 10:47:47 +000011019
Michael Felt0d3ccb42017-12-30 22:39:20 +010011020# checks for uuid.h location
Pablo Galindoba421752021-05-03 20:33:17 +010011021ac_fn_c_check_header_compile "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
11022if test "x$ac_cv_header_uuid_uuid_h" = xyes
11023then :
11024 printf "%s\n" "#define HAVE_UUID_UUID_H 1" >>confdefs.h
11025
11026fi
11027ac_fn_c_check_header_compile "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
11028if test "x$ac_cv_header_uuid_h" = xyes
11029then :
11030 printf "%s\n" "#define HAVE_UUID_H 1" >>confdefs.h
Michael Felt0d3ccb42017-12-30 22:39:20 +010011031
11032fi
11033
Michael Felt0d3ccb42017-12-30 22:39:20 +010011034
Pablo Galindoba421752021-05-03 20:33:17 +010011035{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uuid_generate_time_safe" >&5
11036printf %s "checking for uuid_generate_time_safe... " >&6; }
Berker Peksag9a10ff42017-11-08 23:09:16 +030011037cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11038/* end confdefs.h. */
11039#include <uuid/uuid.h>
11040int
Pablo Galindoba421752021-05-03 20:33:17 +010011041main (void)
Berker Peksag9a10ff42017-11-08 23:09:16 +030011042{
11043
11044#ifndef uuid_generate_time_safe
Berker Peksag0e163d22017-11-09 00:43:14 +030011045void *x = uuid_generate_time_safe
Berker Peksag9a10ff42017-11-08 23:09:16 +030011046#endif
11047
11048 ;
11049 return 0;
11050}
11051_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011052if ac_fn_c_try_compile "$LINENO"
11053then :
Berker Peksag9a10ff42017-11-08 23:09:16 +030011054
Pablo Galindoba421752021-05-03 20:33:17 +010011055printf "%s\n" "#define HAVE_UUID_GENERATE_TIME_SAFE 1" >>confdefs.h
Berker Peksag9a10ff42017-11-08 23:09:16 +030011056
Pablo Galindoba421752021-05-03 20:33:17 +010011057 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11058printf "%s\n" "yes" >&6; }
11059else $as_nop
11060 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11061printf "%s\n" "no" >&6; }
Berker Peksag9a10ff42017-11-08 23:09:16 +030011062
11063fi
Pablo Galindoba421752021-05-03 20:33:17 +010011064rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Berker Peksag9a10ff42017-11-08 23:09:16 +030011065
Michael Felt0d3ccb42017-12-30 22:39:20 +010011066# AIX provides support for RFC4122 (uuid) in libc.a starting with AIX 6.1 (anno 2007)
David Carlierb4ebaa72018-01-09 19:38:07 +000011067# FreeBSD and OpenBSD provides support as well
Pablo Galindoba421752021-05-03 20:33:17 +010011068{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uuid_create" >&5
11069printf %s "checking for uuid_create... " >&6; }
Michael Felt0d3ccb42017-12-30 22:39:20 +010011070cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11071/* end confdefs.h. */
11072#include <uuid.h>
11073int
Pablo Galindoba421752021-05-03 20:33:17 +010011074main (void)
Michael Felt0d3ccb42017-12-30 22:39:20 +010011075{
11076
11077#ifndef uuid_create
11078void *x = uuid_create
11079#endif
11080
11081 ;
11082 return 0;
11083}
11084_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011085if ac_fn_c_try_compile "$LINENO"
11086then :
Michael Felt0d3ccb42017-12-30 22:39:20 +010011087
Pablo Galindoba421752021-05-03 20:33:17 +010011088printf "%s\n" "#define HAVE_UUID_CREATE 1" >>confdefs.h
Michael Felt0d3ccb42017-12-30 22:39:20 +010011089
Pablo Galindoba421752021-05-03 20:33:17 +010011090 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11091printf "%s\n" "yes" >&6; }
11092else $as_nop
11093 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11094printf "%s\n" "no" >&6; }
Michael Felt0d3ccb42017-12-30 22:39:20 +010011095
11096fi
Pablo Galindoba421752021-05-03 20:33:17 +010011097rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Michael Felt0d3ccb42017-12-30 22:39:20 +010011098
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011099# Little-endian FreeBSD, OpenBSD and NetBSD needs encoding into an octet
11100# stream in big-endian byte-order
Pablo Galindoba421752021-05-03 20:33:17 +010011101{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uuid_enc_be" >&5
11102printf %s "checking for uuid_enc_be... " >&6; }
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011103cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11104/* end confdefs.h. */
11105#include <uuid.h>
11106int
Pablo Galindoba421752021-05-03 20:33:17 +010011107main (void)
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011108{
11109
11110#ifndef uuid_enc_be
Ned Deilyced0adb2018-06-09 18:19:57 -040011111void *x = uuid_enc_be
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011112#endif
11113
11114 ;
11115 return 0;
11116}
11117_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011118if ac_fn_c_try_compile "$LINENO"
11119then :
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011120
Pablo Galindoba421752021-05-03 20:33:17 +010011121printf "%s\n" "#define HAVE_UUID_ENC_BE 1" >>confdefs.h
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011122
Pablo Galindoba421752021-05-03 20:33:17 +010011123 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11124printf "%s\n" "yes" >&6; }
11125else $as_nop
11126 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11127printf "%s\n" "no" >&6; }
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011128
11129fi
Pablo Galindoba421752021-05-03 20:33:17 +010011130rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchaka17d88302018-05-25 01:45:09 +030011131
Serhiy Storchaka9e78dc22017-11-11 19:18:28 +020011132# 'Real Time' functions on Solaris
11133# posix4 on Solaris 2.6
11134# pthread (first!) on Linux
Pablo Galindoba421752021-05-03 20:33:17 +010011135{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
11136printf %s "checking for library containing sem_init... " >&6; }
11137if test ${ac_cv_search_sem_init+y}
11138then :
11139 printf %s "(cached) " >&6
11140else $as_nop
Martin v. Löwis82c19a72002-10-06 11:48:09 +000011141 ac_func_search_save_LIBS=$LIBS
Matthias Kloseb9621712010-04-24 17:59:49 +000011142cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011143/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011144
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011145/* Override any GCC internal prototype to avoid an error.
11146 Use char because int might match the return type of a GCC
11147 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011148char sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011149int
Pablo Galindoba421752021-05-03 20:33:17 +010011150main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000011151{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011152return sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011153 ;
11154 return 0;
11155}
11156_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011157for ac_lib in '' pthread rt posix4
11158do
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011159 if test -z "$ac_lib"; then
11160 ac_res="none required"
11161 else
11162 ac_res=-l$ac_lib
Skip Montanaroeb33e5a2007-08-17 12:57:41 +000011163 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011164 fi
Pablo Galindoba421752021-05-03 20:33:17 +010011165 if ac_fn_c_try_link "$LINENO"
11166then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011167 ac_cv_search_sem_init=$ac_res
Thomas Wouters477c8d52006-05-27 19:21:47 +000011168fi
Pablo Galindoba421752021-05-03 20:33:17 +010011169rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000011170 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +010011171 if test ${ac_cv_search_sem_init+y}
11172then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011173 break
Skip Montanaroeb33e5a2007-08-17 12:57:41 +000011174fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011175done
Pablo Galindoba421752021-05-03 20:33:17 +010011176if test ${ac_cv_search_sem_init+y}
11177then :
Matthias Kloseb9621712010-04-24 17:59:49 +000011178
Pablo Galindoba421752021-05-03 20:33:17 +010011179else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011180 ac_cv_search_sem_init=no
11181fi
11182rm conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +000011183LIBS=$ac_func_search_save_LIBS
11184fi
Pablo Galindoba421752021-05-03 20:33:17 +010011185{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
11186printf "%s\n" "$ac_cv_search_sem_init" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011187ac_res=$ac_cv_search_sem_init
Pablo Galindoba421752021-05-03 20:33:17 +010011188if test "$ac_res" != no
11189then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011190 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +000011191
Martin v. Löwis41933dd2002-03-21 15:10:58 +000011192fi
Serhiy Storchaka9e78dc22017-11-11 19:18:28 +020011193
Martin v. Löwis519adae2003-09-20 10:47:47 +000011194
Martin v. Löwis19d17342003-06-14 21:03:05 +000011195# check if we need libintl for locale functions
Pablo Galindoba421752021-05-03 20:33:17 +010011196{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5
11197printf %s "checking for textdomain in -lintl... " >&6; }
11198if test ${ac_cv_lib_intl_textdomain+y}
11199then :
11200 printf %s "(cached) " >&6
11201else $as_nop
Martin v. Löwis19d17342003-06-14 21:03:05 +000011202 ac_check_lib_save_LIBS=$LIBS
11203LIBS="-lintl $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000011204cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011205/* end confdefs.h. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000011206
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011207/* Override any GCC internal prototype to avoid an error.
11208 Use char because int might match the return type of a GCC
11209 builtin and then its argument prototype would still apply. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000011210char textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000011211int
Pablo Galindoba421752021-05-03 20:33:17 +010011212main (void)
Martin v. Löwis19d17342003-06-14 21:03:05 +000011213{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011214return textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000011215 ;
11216 return 0;
11217}
11218_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011219if ac_fn_c_try_link "$LINENO"
11220then :
Martin v. Löwis19d17342003-06-14 21:03:05 +000011221 ac_cv_lib_intl_textdomain=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011222else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000011223 ac_cv_lib_intl_textdomain=no
Martin v. Löwis19d17342003-06-14 21:03:05 +000011224fi
Pablo Galindoba421752021-05-03 20:33:17 +010011225rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000011226 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis19d17342003-06-14 21:03:05 +000011227LIBS=$ac_check_lib_save_LIBS
11228fi
Pablo Galindoba421752021-05-03 20:33:17 +010011229{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5
11230printf "%s\n" "$ac_cv_lib_intl_textdomain" >&6; }
11231if test "x$ac_cv_lib_intl_textdomain" = xyes
11232then :
Martin v. Löwis19d17342003-06-14 21:03:05 +000011233
Pablo Galindoba421752021-05-03 20:33:17 +010011234printf "%s\n" "#define WITH_LIBINTL 1" >>confdefs.h
Martin v. Löwis19d17342003-06-14 21:03:05 +000011235
Brett Cannonc6d936e2009-06-07 20:09:53 +000011236 LIBS="-lintl $LIBS"
Martin v. Löwis19d17342003-06-14 21:03:05 +000011237fi
11238
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000011239
11240# checks for system dependent C++ extensions support
11241case "$ac_sys_system" in
Pablo Galindoba421752021-05-03 20:33:17 +010011242 AIX*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5
11243printf %s "checking for genuine AIX C++ extensions support... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000011244 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011245/* end confdefs.h. */
Matthias Kloseb159a552010-04-25 21:00:44 +000011246
Georg Brandl59e87bd2011-02-15 19:48:59 +000011247 #include <load.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011248int
Pablo Galindoba421752021-05-03 20:33:17 +010011249main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000011250{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000011251loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +000011252 ;
11253 return 0;
11254}
Matthias Kloseb159a552010-04-25 21:00:44 +000011255
Martin v. Löwis11437992002-04-12 09:54:03 +000011256_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011257if ac_fn_c_try_link "$LINENO"
11258then :
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000011259
Matthias Kloseb159a552010-04-25 21:00:44 +000011260
Pablo Galindoba421752021-05-03 20:33:17 +010011261printf "%s\n" "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000011262
Pablo Galindoba421752021-05-03 20:33:17 +010011263 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11264printf "%s\n" "yes" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000011265
Pablo Galindoba421752021-05-03 20:33:17 +010011266else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +000011267
Pablo Galindoba421752021-05-03 20:33:17 +010011268 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11269printf "%s\n" "no" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000011270
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000011271fi
Pablo Galindoba421752021-05-03 20:33:17 +010011272rm -f core conftest.err conftest.$ac_objext conftest.beam \
Michael Felt39afa2d2019-12-15 15:17:53 +010011273 conftest$ac_exeext conftest.$ac_ext
11274# BUILD_GNU_TYPE + AIX_BUILDDATE are used to construct the platform_tag
11275# of the AIX system used to build/package Python executable. This tag serves
11276# as a baseline for bdist module packages
Pablo Galindoba421752021-05-03 20:33:17 +010011277 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the system builddate" >&5
11278printf %s "checking for the system builddate... " >&6; }
Michael Felt39afa2d2019-12-15 15:17:53 +010011279 AIX_BUILDDATE=$(lslpp -Lcq bos.mp64 | awk -F: '{ print $NF }')
11280
Pablo Galindoba421752021-05-03 20:33:17 +010011281printf "%s\n" "#define AIX_BUILDDATE $AIX_BUILDDATE" >>confdefs.h
Michael Felt39afa2d2019-12-15 15:17:53 +010011282
Pablo Galindoba421752021-05-03 20:33:17 +010011283 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AIX_BUILDDATE" >&5
11284printf "%s\n" "$AIX_BUILDDATE" >&6; }
Michael Felt39afa2d2019-12-15 15:17:53 +010011285 ;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000011286 *) ;;
11287esac
11288
Christian Heimes985ecdc2013-11-20 11:46:18 +010011289# check for systems that require aligned memory access
Pablo Galindoba421752021-05-03 20:33:17 +010011290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking aligned memory access is required" >&5
11291printf %s "checking aligned memory access is required... " >&6; }
11292if test ${ac_cv_aligned_required+y}
11293then :
11294 printf %s "(cached) " >&6
11295else $as_nop
11296 if test "$cross_compiling" = yes
11297then :
Benjamin Petersone4f961b2017-04-14 09:36:45 -070011298 ac_cv_aligned_required=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011299else $as_nop
Christian Heimes985ecdc2013-11-20 11:46:18 +010011300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11301/* end confdefs.h. */
11302
11303int main()
11304{
11305 char s[16];
11306 int i, *p1, *p2;
11307 for (i=0; i < 16; i++)
11308 s[i] = i;
11309 p1 = (int*)(s+1);
11310 p2 = (int*)(s+2);
11311 if (*p1 == *p2)
11312 return 1;
11313 return 0;
11314}
Christian Heimes985ecdc2013-11-20 11:46:18 +010011315_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011316if ac_fn_c_try_run "$LINENO"
11317then :
Benjamin Petersone4f961b2017-04-14 09:36:45 -070011318 ac_cv_aligned_required=no
Pablo Galindoba421752021-05-03 20:33:17 +010011319else $as_nop
Benjamin Petersone4f961b2017-04-14 09:36:45 -070011320 ac_cv_aligned_required=yes
Christian Heimes985ecdc2013-11-20 11:46:18 +010011321fi
11322rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11323 conftest.$ac_objext conftest.beam conftest.$ac_ext
11324fi
11325
11326
Benjamin Petersone4f961b2017-04-14 09:36:45 -070011327fi
11328
Pablo Galindoba421752021-05-03 20:33:17 +010011329{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_aligned_required" >&5
11330printf "%s\n" "$ac_cv_aligned_required" >&6; }
Benjamin Petersone4f961b2017-04-14 09:36:45 -070011331if test "$ac_cv_aligned_required" = yes ; then
Christian Heimes985ecdc2013-11-20 11:46:18 +010011332
Pablo Galindoba421752021-05-03 20:33:17 +010011333printf "%s\n" "#define HAVE_ALIGNED_REQUIRED 1" >>confdefs.h
Christian Heimes985ecdc2013-11-20 11:46:18 +010011334
11335fi
Christian Heimes985ecdc2013-11-20 11:46:18 +010011336
11337# str, bytes and memoryview hash algorithm
11338
11339
Pablo Galindoba421752021-05-03 20:33:17 +010011340{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-hash-algorithm" >&5
11341printf %s "checking for --with-hash-algorithm... " >&6; }
Christian Heimes985ecdc2013-11-20 11:46:18 +010011342
11343# Check whether --with-hash_algorithm was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011344if test ${with_hash_algorithm+y}
11345then :
Christian Heimes985ecdc2013-11-20 11:46:18 +010011346 withval=$with_hash_algorithm;
Pablo Galindoba421752021-05-03 20:33:17 +010011347{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
11348printf "%s\n" "$withval" >&6; }
Christian Heimes985ecdc2013-11-20 11:46:18 +010011349case "$withval" in
11350 siphash24)
Pablo Galindoba421752021-05-03 20:33:17 +010011351 printf "%s\n" "#define Py_HASH_ALGORITHM 1" >>confdefs.h
Christian Heimes985ecdc2013-11-20 11:46:18 +010011352
11353 ;;
11354 fnv)
Pablo Galindoba421752021-05-03 20:33:17 +010011355 printf "%s\n" "#define Py_HASH_ALGORITHM 2" >>confdefs.h
Christian Heimes985ecdc2013-11-20 11:46:18 +010011356
11357 ;;
11358 *)
11359 as_fn_error $? "unknown hash algorithm '$withval'" "$LINENO" 5
11360 ;;
11361esac
11362
Pablo Galindoba421752021-05-03 20:33:17 +010011363else $as_nop
11364 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: default" >&5
11365printf "%s\n" "default" >&6; }
Christian Heimes985ecdc2013-11-20 11:46:18 +010011366fi
11367
11368
Paul Ganssle62972d92020-05-16 04:20:06 -040011369validate_tzpath() {
11370 # Checks that each element of hte path is an absolute path
11371 if test -z "$1"; then
11372 # Empty string is allowed: it indicates no system TZPATH
11373 return 0
11374 fi
11375
11376 # Bad paths are those that don't start with /
Paul Ganssle0f664982021-01-12 13:17:52 -050011377 if ( echo $1 | grep '\(^\|:\)\([^/]\|$\)' > /dev/null); then
Paul Ganssle62972d92020-05-16 04:20:06 -040011378 as_fn_error $? "--with-tzpath must contain only absolute paths, not $1" "$LINENO" 5
11379 return 1;
11380 fi
11381}
11382
11383TZPATH="/usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo"
Pablo Galindoba421752021-05-03 20:33:17 +010011384{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-tzpath" >&5
11385printf %s "checking for --with-tzpath... " >&6; }
Paul Ganssle62972d92020-05-16 04:20:06 -040011386
11387# Check whether --with-tzpath was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011388if test ${with_tzpath+y}
11389then :
Paul Ganssle62972d92020-05-16 04:20:06 -040011390 withval=$with_tzpath;
11391case "$withval" in
11392 yes)
11393 as_fn_error $? "--with-tzpath requires a value" "$LINENO" 5
11394 ;;
11395 *)
11396 validate_tzpath "$withval"
11397 TZPATH="$withval"
Pablo Galindoba421752021-05-03 20:33:17 +010011398 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \"$withval\"" >&5
11399printf "%s\n" "\"$withval\"" >&6; }
Paul Ganssle62972d92020-05-16 04:20:06 -040011400 ;;
11401esac
11402
Pablo Galindoba421752021-05-03 20:33:17 +010011403else $as_nop
Paul Ganssle62972d92020-05-16 04:20:06 -040011404 validate_tzpath "$TZPATH"
Pablo Galindoba421752021-05-03 20:33:17 +010011405 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \"$TZPATH\"" >&5
11406printf "%s\n" "\"$TZPATH\"" >&6; }
Paul Ganssle62972d92020-05-16 04:20:06 -040011407fi
11408
11409
11410
Pablo Galindoba421752021-05-03 20:33:17 +010011411{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-address-sanitizer" >&5
11412printf %s "checking for --with-address-sanitizer... " >&6; }
Charles-François Natalid30b0222014-05-08 23:08:51 +010011413
11414# Check whether --with-address_sanitizer was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011415if test ${with_address_sanitizer+y}
11416then :
Charles-François Natalid30b0222014-05-08 23:08:51 +010011417 withval=$with_address_sanitizer;
Pablo Galindoba421752021-05-03 20:33:17 +010011418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
11419printf "%s\n" "$withval" >&6; }
Charles-François Natalid30b0222014-05-08 23:08:51 +010011420BASECFLAGS="-fsanitize=address -fno-omit-frame-pointer $BASECFLAGS"
11421LDFLAGS="-fsanitize=address $LDFLAGS"
Gregory P. Smith1584a002018-11-12 12:07:14 -080011422# ASan works by controlling memory allocation, our own malloc interferes.
11423with_pymalloc="no"
11424
Pablo Galindoba421752021-05-03 20:33:17 +010011425else $as_nop
11426 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11427printf "%s\n" "no" >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011428fi
11429
11430
Pablo Galindoba421752021-05-03 20:33:17 +010011431{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-memory-sanitizer" >&5
11432printf %s "checking for --with-memory-sanitizer... " >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011433
11434# Check whether --with-memory_sanitizer was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011435if test ${with_memory_sanitizer+y}
11436then :
Gregory P. Smith1584a002018-11-12 12:07:14 -080011437 withval=$with_memory_sanitizer;
Pablo Galindoba421752021-05-03 20:33:17 +010011438{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
11439printf "%s\n" "$withval" >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011440BASECFLAGS="-fsanitize=memory -fsanitize-memory-track-origins=2 -fno-omit-frame-pointer $BASECFLAGS"
11441LDFLAGS="-fsanitize=memory -fsanitize-memory-track-origins=2 $LDFLAGS"
11442# MSan works by controlling memory allocation, our own malloc interferes.
11443with_pymalloc="no"
11444
Pablo Galindoba421752021-05-03 20:33:17 +010011445else $as_nop
11446 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11447printf "%s\n" "no" >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011448fi
11449
11450
Pablo Galindoba421752021-05-03 20:33:17 +010011451{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-undefined-behavior-sanitizer" >&5
11452printf %s "checking for --with-undefined-behavior-sanitizer... " >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011453
11454# Check whether --with-undefined_behavior_sanitizer was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011455if test ${with_undefined_behavior_sanitizer+y}
11456then :
Gregory P. Smith1584a002018-11-12 12:07:14 -080011457 withval=$with_undefined_behavior_sanitizer;
Pablo Galindoba421752021-05-03 20:33:17 +010011458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
11459printf "%s\n" "$withval" >&6; }
Gregory P. Smith1584a002018-11-12 12:07:14 -080011460BASECFLAGS="-fsanitize=undefined $BASECFLAGS"
11461LDFLAGS="-fsanitize=undefined $LDFLAGS"
Charles-François Natalid30b0222014-05-08 23:08:51 +010011462
Pablo Galindoba421752021-05-03 20:33:17 +010011463else $as_nop
11464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11465printf "%s\n" "no" >&6; }
Charles-François Natalid30b0222014-05-08 23:08:51 +010011466fi
11467
11468
Guido van Rossum70c7f481998-03-26 18:44:10 +000011469# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
Pablo Galindoba421752021-05-03 20:33:17 +010011470{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5
11471printf %s "checking for t_open in -lnsl... " >&6; }
11472if test ${ac_cv_lib_nsl_t_open+y}
11473then :
11474 printf %s "(cached) " >&6
11475else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000011476 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011477LIBS="-lnsl $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000011478cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011479/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011480
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011481/* Override any GCC internal prototype to avoid an error.
11482 Use char because int might match the return type of a GCC
11483 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011484char t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011485int
Pablo Galindoba421752021-05-03 20:33:17 +010011486main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000011487{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011488return t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011489 ;
11490 return 0;
11491}
11492_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011493if ac_fn_c_try_link "$LINENO"
11494then :
Martin v. Löwis11437992002-04-12 09:54:03 +000011495 ac_cv_lib_nsl_t_open=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011496else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000011497 ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +000011498fi
Pablo Galindoba421752021-05-03 20:33:17 +010011499rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000011500 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011501LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +000011502fi
Pablo Galindoba421752021-05-03 20:33:17 +010011503{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5
11504printf "%s\n" "$ac_cv_lib_nsl_t_open" >&6; }
11505if test "x$ac_cv_lib_nsl_t_open" = xyes
11506then :
Guido van Rossum79dddcb1995-01-12 12:25:42 +000011507 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +000011508fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +000011509 # SVR4
Pablo Galindoba421752021-05-03 20:33:17 +010011510{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
11511printf %s "checking for socket in -lsocket... " >&6; }
11512if test ${ac_cv_lib_socket_socket+y}
11513then :
11514 printf %s "(cached) " >&6
11515else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000011516 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011517LIBS="-lsocket $LIBS $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000011518cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011519/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011520
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011521/* Override any GCC internal prototype to avoid an error.
11522 Use char because int might match the return type of a GCC
11523 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011524char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011525int
Pablo Galindoba421752021-05-03 20:33:17 +010011526main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000011527{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011528return socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011529 ;
11530 return 0;
11531}
11532_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011533if ac_fn_c_try_link "$LINENO"
11534then :
Martin v. Löwis11437992002-04-12 09:54:03 +000011535 ac_cv_lib_socket_socket=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011536else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000011537 ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011538fi
Pablo Galindoba421752021-05-03 20:33:17 +010011539rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000011540 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011541LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011542fi
Pablo Galindoba421752021-05-03 20:33:17 +010011543{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
11544printf "%s\n" "$ac_cv_lib_socket_socket" >&6; }
11545if test "x$ac_cv_lib_socket_socket" = xyes
11546then :
Guido van Rossumad678af1998-10-02 14:42:15 +000011547 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +000011548fi
11549 # SVR4 sockets
Skip Montanarob9949db2004-01-17 04:04:13 +000011550
Pablo Galindoba421752021-05-03 20:33:17 +010011551{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5
11552printf %s "checking for --with-libs... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000011553
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011554# Check whether --with-libs was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011555if test ${with_libs+y}
11556then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011557 withval=$with_libs;
Pablo Galindoba421752021-05-03 20:33:17 +010011558{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
11559printf "%s\n" "$withval" >&6; }
Guido van Rossuma68acba1996-07-31 17:36:39 +000011560LIBS="$withval $LIBS"
11561
Pablo Galindoba421752021-05-03 20:33:17 +010011562else $as_nop
11563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11564printf "%s\n" "no" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000011565fi
11566
Guido van Rossum7f43da71994-08-01 12:15:30 +000011567
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011568
11569
11570
11571
11572
11573
Victor Stinnerb477d192020-01-22 22:48:16 +010011574
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011575if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
11576 if test -n "$ac_tool_prefix"; then
11577 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
11578set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010011579{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11580printf %s "checking for $ac_word... " >&6; }
11581if test ${ac_cv_path_PKG_CONFIG+y}
11582then :
11583 printf %s "(cached) " >&6
11584else $as_nop
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011585 case $PKG_CONFIG in
11586 [\\/]* | ?:[\\/]*)
11587 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11588 ;;
11589 *)
11590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11591for as_dir in $PATH
11592do
11593 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010011594 case $as_dir in #(((
11595 '') as_dir=./ ;;
11596 */) ;;
11597 *) as_dir=$as_dir/ ;;
11598 esac
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011599 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010011600 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11601 ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
11602 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011603 break 2
11604 fi
11605done
11606 done
11607IFS=$as_save_IFS
11608
11609 ;;
11610esac
11611fi
11612PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11613if test -n "$PKG_CONFIG"; then
Pablo Galindoba421752021-05-03 20:33:17 +010011614 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11615printf "%s\n" "$PKG_CONFIG" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011616else
Pablo Galindoba421752021-05-03 20:33:17 +010011617 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11618printf "%s\n" "no" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011619fi
11620
11621
11622fi
11623if test -z "$ac_cv_path_PKG_CONFIG"; then
11624 ac_pt_PKG_CONFIG=$PKG_CONFIG
11625 # Extract the first word of "pkg-config", so it can be a program name with args.
11626set dummy pkg-config; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010011627{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11628printf %s "checking for $ac_word... " >&6; }
11629if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
11630then :
11631 printf %s "(cached) " >&6
11632else $as_nop
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011633 case $ac_pt_PKG_CONFIG in
11634 [\\/]* | ?:[\\/]*)
11635 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
11636 ;;
11637 *)
11638 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11639for as_dir in $PATH
11640do
11641 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010011642 case $as_dir in #(((
11643 '') as_dir=./ ;;
11644 */) ;;
11645 *) as_dir=$as_dir/ ;;
11646 esac
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011647 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010011648 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11649 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
11650 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011651 break 2
11652 fi
11653done
11654 done
11655IFS=$as_save_IFS
11656
11657 ;;
11658esac
11659fi
11660ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
11661if test -n "$ac_pt_PKG_CONFIG"; then
Pablo Galindoba421752021-05-03 20:33:17 +010011662 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
11663printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011664else
Pablo Galindoba421752021-05-03 20:33:17 +010011665 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11666printf "%s\n" "no" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011667fi
11668
11669 if test "x$ac_pt_PKG_CONFIG" = x; then
11670 PKG_CONFIG=""
11671 else
11672 case $cross_compiling:$ac_tool_warned in
11673yes:)
Pablo Galindoba421752021-05-03 20:33:17 +010011674{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11675printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011676ac_tool_warned=yes ;;
11677esac
11678 PKG_CONFIG=$ac_pt_PKG_CONFIG
11679 fi
11680else
11681 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
11682fi
11683
11684fi
11685if test -n "$PKG_CONFIG"; then
11686 _pkg_min_version=0.9.0
Pablo Galindoba421752021-05-03 20:33:17 +010011687 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
11688printf %s "checking pkg-config is at least version $_pkg_min_version... " >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011689 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
Pablo Galindoba421752021-05-03 20:33:17 +010011690 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11691printf "%s\n" "yes" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011692 else
Pablo Galindoba421752021-05-03 20:33:17 +010011693 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11694printf "%s\n" "no" >&6; }
Chih-Hsuan Yen03c0d2e2018-05-24 14:37:08 +080011695 PKG_CONFIG=""
11696 fi
11697fi
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011698
11699# Check for use of the system expat library
Pablo Galindoba421752021-05-03 20:33:17 +010011700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5
11701printf %s "checking for --with-system-expat... " >&6; }
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011702
11703# Check whether --with-system_expat was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011704if test ${with_system_expat+y}
11705then :
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011706 withval=$with_system_expat;
Pablo Galindoba421752021-05-03 20:33:17 +010011707else $as_nop
Benjamin Peterson79263252010-10-31 16:50:44 +000011708 with_system_expat="no"
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011709fi
11710
11711
Pablo Galindoba421752021-05-03 20:33:17 +010011712{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5
11713printf "%s\n" "$with_system_expat" >&6; }
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011714
11715# Check for use of the system libffi library
Pablo Galindoba421752021-05-03 20:33:17 +010011716{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5
11717printf %s "checking for --with-system-ffi... " >&6; }
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011718
11719# Check whether --with-system_ffi was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011720if test ${with_system_ffi+y}
11721then :
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011722 withval=$with_system_ffi;
11723fi
11724
11725
Zachary Waref40d4dd2016-09-17 01:25:24 -050011726if test "$ac_sys_system" = "Darwin"
11727then
11728 case "$with_system_ffi" in
11729 "")
11730 with_system_ffi="no"
11731 ;;
11732 yes|no)
11733 ;;
11734 *)
11735 as_fn_error $? "--with-system-ffi accepts no arguments" "$LINENO" 5
11736 ;;
11737 esac
Pablo Galindoba421752021-05-03 20:33:17 +010011738 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5
11739printf "%s\n" "$with_system_ffi" >&6; }
Zachary Waref40d4dd2016-09-17 01:25:24 -050011740else
Pablo Galindoba421752021-05-03 20:33:17 +010011741 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11742printf "%s\n" "yes" >&6; }
Zachary Waref40d4dd2016-09-17 01:25:24 -050011743 if test "$with_system_ffi" != ""
11744 then
Pablo Galindoba421752021-05-03 20:33:17 +010011745 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: --with(out)-system-ffi is ignored on this platform" >&5
11746printf "%s\n" "$as_me: WARNING: --with(out)-system-ffi is ignored on this platform" >&2;}
Zachary Waref40d4dd2016-09-17 01:25:24 -050011747 fi
11748 with_system_ffi="yes"
11749fi
Zachary Ware935043d2016-09-09 17:01:21 -070011750
Benjamin Peterson0f64b0b2010-03-09 21:49:52 +000011751if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then
Benjamin Petersond78735d2010-01-01 16:04:23 +000011752 LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`"
11753else
11754 LIBFFI_INCLUDEDIR=""
11755fi
11756
11757
Stefan Krah60187b52012-03-23 19:06:27 +010011758# Check for use of the system libmpdec library
Pablo Galindoba421752021-05-03 20:33:17 +010011759{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-system-libmpdec" >&5
11760printf %s "checking for --with-system-libmpdec... " >&6; }
Stefan Krah60187b52012-03-23 19:06:27 +010011761
11762# Check whether --with-system_libmpdec was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011763if test ${with_system_libmpdec+y}
11764then :
Stefan Krah60187b52012-03-23 19:06:27 +010011765 withval=$with_system_libmpdec;
Pablo Galindoba421752021-05-03 20:33:17 +010011766else $as_nop
Stefan Krah60187b52012-03-23 19:06:27 +010011767 with_system_libmpdec="no"
11768fi
11769
11770
Pablo Galindoba421752021-05-03 20:33:17 +010011771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_system_libmpdec" >&5
11772printf "%s\n" "$with_system_libmpdec" >&6; }
Stefan Krah60187b52012-03-23 19:06:27 +010011773
Stefan Krah815280e2020-02-29 19:43:42 +010011774# Check whether _decimal should use a coroutine-local or thread-local context
Pablo Galindoba421752021-05-03 20:33:17 +010011775{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-decimal-contextvar" >&5
11776printf %s "checking for --with-decimal-contextvar... " >&6; }
Stefan Krah815280e2020-02-29 19:43:42 +010011777
11778# Check whether --with-decimal_contextvar was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011779if test ${with_decimal_contextvar+y}
11780then :
Stefan Krah815280e2020-02-29 19:43:42 +010011781 withval=$with_decimal_contextvar;
Pablo Galindoba421752021-05-03 20:33:17 +010011782else $as_nop
Stefan Krah815280e2020-02-29 19:43:42 +010011783 with_decimal_contextvar="yes"
11784fi
11785
11786
11787if test "$with_decimal_contextvar" != "no"
11788then
11789
Pablo Galindoba421752021-05-03 20:33:17 +010011790printf "%s\n" "#define WITH_DECIMAL_CONTEXTVAR 1" >>confdefs.h
Stefan Krah815280e2020-02-29 19:43:42 +010011791
11792fi
11793
Pablo Galindoba421752021-05-03 20:33:17 +010011794{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_decimal_contextvar" >&5
11795printf "%s\n" "$with_decimal_contextvar" >&6; }
Stefan Krah815280e2020-02-29 19:43:42 +010011796
Benjamin Peterson076ed002010-10-31 17:11:02 +000011797# Check for support for loadable sqlite extensions
Pablo Galindoba421752021-05-03 20:33:17 +010011798{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --enable-loadable-sqlite-extensions" >&5
11799printf %s "checking for --enable-loadable-sqlite-extensions... " >&6; }
Benjamin Peterson076ed002010-10-31 17:11:02 +000011800# Check whether --enable-loadable-sqlite-extensions was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011801if test ${enable_loadable_sqlite_extensions+y}
11802then :
Benjamin Peterson076ed002010-10-31 17:11:02 +000011803 enableval=$enable_loadable_sqlite_extensions;
Pablo Galindoba421752021-05-03 20:33:17 +010011804else $as_nop
Benjamin Peterson076ed002010-10-31 17:11:02 +000011805 enable_loadable_sqlite_extensions="no"
11806fi
11807
11808
Pablo Galindoba421752021-05-03 20:33:17 +010011809{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_loadable_sqlite_extensions" >&5
11810printf "%s\n" "$enable_loadable_sqlite_extensions" >&6; }
Benjamin Peterson076ed002010-10-31 17:11:02 +000011811
Ned Deilyd819b932013-09-06 01:07:05 -070011812# Check for --with-tcltk-includes=path and --with-tcltk-libs=path
11813
11814
Pablo Galindoba421752021-05-03 20:33:17 +010011815{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-includes" >&5
11816printf %s "checking for --with-tcltk-includes... " >&6; }
Ned Deilyd819b932013-09-06 01:07:05 -070011817
11818# Check whether --with-tcltk-includes was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011819if test ${with_tcltk_includes+y}
11820then :
Ned Deilyd819b932013-09-06 01:07:05 -070011821 withval=$with_tcltk_includes;
Pablo Galindoba421752021-05-03 20:33:17 +010011822else $as_nop
Ned Deilyd819b932013-09-06 01:07:05 -070011823 with_tcltk_includes="default"
11824fi
11825
Pablo Galindoba421752021-05-03 20:33:17 +010011826{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_includes" >&5
11827printf "%s\n" "$with_tcltk_includes" >&6; }
11828{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-libs" >&5
11829printf %s "checking for --with-tcltk-libs... " >&6; }
Ned Deilyd819b932013-09-06 01:07:05 -070011830
11831# Check whether --with-tcltk-libs was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011832if test ${with_tcltk_libs+y}
11833then :
Ned Deilyd819b932013-09-06 01:07:05 -070011834 withval=$with_tcltk_libs;
Pablo Galindoba421752021-05-03 20:33:17 +010011835else $as_nop
Ned Deilyd819b932013-09-06 01:07:05 -070011836 with_tcltk_libs="default"
11837fi
11838
Pablo Galindoba421752021-05-03 20:33:17 +010011839{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_libs" >&5
11840printf "%s\n" "$with_tcltk_libs" >&6; }
Ned Deilyd819b932013-09-06 01:07:05 -070011841if test "x$with_tcltk_includes" = xdefault || test "x$with_tcltk_libs" = xdefault
11842then
11843 if test "x$with_tcltk_includes" != "x$with_tcltk_libs"
11844 then
11845 as_fn_error $? "use both --with-tcltk-includes='...' and --with-tcltk-libs='...' or neither" "$LINENO" 5
11846 fi
Manolis Stamatogiannakisd2027942021-03-01 04:29:57 +010011847 if test -n "$PKG_CONFIG" && "$PKG_CONFIG" --exists tcl tk; then
11848 TCLTK_INCLUDES="`"$PKG_CONFIG" tcl tk --cflags-only-I 2>/dev/null`"
11849 TCLTK_LIBS="`"$PKG_CONFIG" tcl tk --libs 2>/dev/null`"
11850 else
11851 TCLTK_INCLUDES=""
11852 TCLTK_LIBS=""
11853 fi
Ned Deilyd819b932013-09-06 01:07:05 -070011854else
11855 TCLTK_INCLUDES="$with_tcltk_includes"
11856 TCLTK_LIBS="$with_tcltk_libs"
11857fi
11858
Matthias Klose55708cc2009-04-30 08:06:49 +000011859# Check for --with-dbmliborder
Pablo Galindoba421752021-05-03 20:33:17 +010011860{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5
11861printf %s "checking for --with-dbmliborder... " >&6; }
Matthias Klose55708cc2009-04-30 08:06:49 +000011862
11863# Check whether --with-dbmliborder was given.
Pablo Galindoba421752021-05-03 20:33:17 +010011864if test ${with_dbmliborder+y}
11865then :
Matthias Klose55708cc2009-04-30 08:06:49 +000011866 withval=$with_dbmliborder;
11867if test x$with_dbmliborder = xyes
11868then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020011869as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5
Matthias Klose55708cc2009-04-30 08:06:49 +000011870else
11871 for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do
11872 if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb
11873 then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020011874 as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5
Matthias Klose55708cc2009-04-30 08:06:49 +000011875 fi
11876 done
11877fi
11878fi
11879
Pablo Galindoba421752021-05-03 20:33:17 +010011880{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5
11881printf "%s\n" "$with_dbmliborder" >&6; }
Matthias Klose55708cc2009-04-30 08:06:49 +000011882
Martin v. Löwis11437992002-04-12 09:54:03 +000011883# Templates for things AC_DEFINEd more than once.
11884# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +000011885
11886
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020011887if test "$ac_cv_pthread_is_default" = yes
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000011888then
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011889 # Defining _REENTRANT on system with POSIX threads should not hurt.
Pablo Galindoba421752021-05-03 20:33:17 +010011890 printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011891
11892 posix_threads=yes
Jesús Cea52d1b862019-09-28 03:44:32 +020011893 if test "$ac_sys_system" = "SunOS"; then
11894 CFLAGS="$CFLAGS -D_REENTRANT"
11895 fi
Martin v. Löwis130fb172001-07-19 11:00:41 +000011896elif test "$ac_cv_kpthread" = "yes"
11897then
11898 CC="$CC -Kpthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000011899 if test "$ac_cv_cxx_thread" = "yes"; then
11900 CXX="$CXX -Kpthread"
11901 fi
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011902 posix_threads=yes
Martin v. Löwis5f433f02003-05-05 05:05:30 +000011903elif test "$ac_cv_kthread" = "yes"
11904then
11905 CC="$CC -Kthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000011906 if test "$ac_cv_cxx_thread" = "yes"; then
11907 CXX="$CXX -Kthread"
11908 fi
Martin v. Löwis5f433f02003-05-05 05:05:30 +000011909 posix_threads=yes
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000011910elif test "$ac_cv_pthread" = "yes"
11911then
11912 CC="$CC -pthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000011913 if test "$ac_cv_cxx_thread" = "yes"; then
11914 CXX="$CXX -pthread"
11915 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000011916 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011917else
Martin v. Löwis130fb172001-07-19 11:00:41 +000011918 if test ! -z "$withval" -a -d "$withval"
11919 then LDFLAGS="$LDFLAGS -L$withval"
11920 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011921
11922 # According to the POSIX spec, a pthreads implementation must
Matthias Klosea2542be2004-08-16 11:35:51 +000011923 # define _POSIX_THREADS in unistd.h. Some apparently don't
11924 # (e.g. gnu pth with pthread emulation)
Pablo Galindoba421752021-05-03 20:33:17 +010011925 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5
11926printf %s "checking for _POSIX_THREADS in unistd.h... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000011927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011928/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +000011929
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011930#include <unistd.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000011931#ifdef _POSIX_THREADS
11932yes
11933#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011934
11935_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011936if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010011937 $EGREP "yes" >/dev/null 2>&1
11938then :
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011939 unistd_defines_pthreads=yes
Pablo Galindoba421752021-05-03 20:33:17 +010011940else $as_nop
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011941 unistd_defines_pthreads=no
11942fi
Pablo Galindoba421752021-05-03 20:33:17 +010011943rm -rf conftest*
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011944
Pablo Galindoba421752021-05-03 20:33:17 +010011945 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5
11946printf "%s\n" "$unistd_defines_pthreads" >&6; }
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011947
Pablo Galindoba421752021-05-03 20:33:17 +010011948 printf "%s\n" "#define _REENTRANT 1" >>confdefs.h
Guido van Rossum9caf77a1996-08-01 00:52:26 +000011949
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011950 # Just looking for pthread_create in libpthread is not enough:
11951 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
11952 # So we really have to include pthread.h, and then link.
11953 _libs=$LIBS
11954 LIBS="$LIBS -lpthread"
Pablo Galindoba421752021-05-03 20:33:17 +010011955 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
11956printf %s "checking for pthread_create in -lpthread... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000011957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000011958/* end confdefs.h. */
Stefan Krah7dba5942012-11-22 22:49:11 +010011959
11960#include <stdio.h>
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011961#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000011962
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011963void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000011964int
Pablo Galindoba421752021-05-03 20:33:17 +010011965main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000011966{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011967
11968pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000011969 ;
11970 return 0;
11971}
11972_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010011973if ac_fn_c_try_link "$LINENO"
11974then :
Martin v. Löwis11437992002-04-12 09:54:03 +000011975
Pablo Galindoba421752021-05-03 20:33:17 +010011976 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11977printf "%s\n" "yes" >&6; }
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011978 posix_threads=yes
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020011979
Pablo Galindoba421752021-05-03 20:33:17 +010011980else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000011981
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011982 LIBS=$_libs
Matthias Kloseb9621712010-04-24 17:59:49 +000011983 ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach"
Pablo Galindoba421752021-05-03 20:33:17 +010011984if test "x$ac_cv_func_pthread_detach" = xyes
11985then :
Guido van Rossumad678af1998-10-02 14:42:15 +000011986
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011987 posix_threads=yes
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020011988
Pablo Galindoba421752021-05-03 20:33:17 +010011989else $as_nop
Guido van Rossumad678af1998-10-02 14:42:15 +000011990
Pablo Galindoba421752021-05-03 20:33:17 +010011991 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5
11992printf %s "checking for pthread_create in -lpthreads... " >&6; }
11993if test ${ac_cv_lib_pthreads_pthread_create+y}
11994then :
11995 printf %s "(cached) " >&6
11996else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000011997 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011998LIBS="-lpthreads $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000011999cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012000/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012001
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012002/* Override any GCC internal prototype to avoid an error.
12003 Use char because int might match the return type of a GCC
12004 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012005char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012006int
Pablo Galindoba421752021-05-03 20:33:17 +010012007main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012008{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012009return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012010 ;
12011 return 0;
12012}
12013_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012014if ac_fn_c_try_link "$LINENO"
12015then :
Martin v. Löwis11437992002-04-12 09:54:03 +000012016 ac_cv_lib_pthreads_pthread_create=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012017else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012018 ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000012019fi
Pablo Galindoba421752021-05-03 20:33:17 +010012020rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012021 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012022LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000012023fi
Pablo Galindoba421752021-05-03 20:33:17 +010012024{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5
12025printf "%s\n" "$ac_cv_lib_pthreads_pthread_create" >&6; }
12026if test "x$ac_cv_lib_pthreads_pthread_create" = xyes
12027then :
Greg Steinadf63d62000-07-05 10:38:09 +000012028
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012029 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000012030 LIBS="$LIBS -lpthreads"
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012031
Pablo Galindoba421752021-05-03 20:33:17 +010012032else $as_nop
Greg Steinadf63d62000-07-05 10:38:09 +000012033
Pablo Galindoba421752021-05-03 20:33:17 +010012034 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5
12035printf %s "checking for pthread_create in -lc_r... " >&6; }
12036if test ${ac_cv_lib_c_r_pthread_create+y}
12037then :
12038 printf %s "(cached) " >&6
12039else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000012040 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000012041LIBS="-lc_r $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000012042cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012043/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012044
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012045/* Override any GCC internal prototype to avoid an error.
12046 Use char because int might match the return type of a GCC
12047 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012048char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012049int
Pablo Galindoba421752021-05-03 20:33:17 +010012050main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012051{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012052return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012053 ;
12054 return 0;
12055}
12056_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012057if ac_fn_c_try_link "$LINENO"
12058then :
Martin v. Löwis11437992002-04-12 09:54:03 +000012059 ac_cv_lib_c_r_pthread_create=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012060else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012061 ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000012062fi
Pablo Galindoba421752021-05-03 20:33:17 +010012063rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012064 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012065LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000012066fi
Pablo Galindoba421752021-05-03 20:33:17 +010012067{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5
12068printf "%s\n" "$ac_cv_lib_c_r_pthread_create" >&6; }
12069if test "x$ac_cv_lib_c_r_pthread_create" = xyes
12070then :
Guido van Rossum49545951997-12-02 19:28:29 +000012071
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012072 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000012073 LIBS="$LIBS -lc_r"
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012074
Pablo Galindoba421752021-05-03 20:33:17 +010012075else $as_nop
Guido van Rossum07bd90e2000-05-08 13:41:38 +000012076
Pablo Galindoba421752021-05-03 20:33:17 +010012077 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5
12078printf %s "checking for __pthread_create_system in -lpthread... " >&6; }
12079if test ${ac_cv_lib_pthread___pthread_create_system+y}
12080then :
12081 printf %s "(cached) " >&6
12082else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000012083 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000012084LIBS="-lpthread $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000012085cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012086/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012087
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012088/* Override any GCC internal prototype to avoid an error.
12089 Use char because int might match the return type of a GCC
12090 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012091char __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012092int
Pablo Galindoba421752021-05-03 20:33:17 +010012093main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012094{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012095return __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012096 ;
12097 return 0;
12098}
12099_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012100if ac_fn_c_try_link "$LINENO"
12101then :
Martin v. Löwis11437992002-04-12 09:54:03 +000012102 ac_cv_lib_pthread___pthread_create_system=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012103else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012104 ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000012105fi
Pablo Galindoba421752021-05-03 20:33:17 +010012106rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012107 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012108LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000012109fi
Pablo Galindoba421752021-05-03 20:33:17 +010012110{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5
12111printf "%s\n" "$ac_cv_lib_pthread___pthread_create_system" >&6; }
12112if test "x$ac_cv_lib_pthread___pthread_create_system" = xyes
12113then :
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000012114
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012115 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000012116 LIBS="$LIBS -lpthread"
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012117
Pablo Galindoba421752021-05-03 20:33:17 +010012118else $as_nop
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000012119
Pablo Galindoba421752021-05-03 20:33:17 +010012120 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5
12121printf %s "checking for pthread_create in -lcma... " >&6; }
12122if test ${ac_cv_lib_cma_pthread_create+y}
12123then :
12124 printf %s "(cached) " >&6
12125else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000012126 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000012127LIBS="-lcma $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000012128cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012129/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012130
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012131/* Override any GCC internal prototype to avoid an error.
12132 Use char because int might match the return type of a GCC
12133 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012134char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012135int
Pablo Galindoba421752021-05-03 20:33:17 +010012136main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012137{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012138return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012139 ;
12140 return 0;
12141}
12142_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012143if ac_fn_c_try_link "$LINENO"
12144then :
Martin v. Löwis11437992002-04-12 09:54:03 +000012145 ac_cv_lib_cma_pthread_create=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012146else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012147 ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000012148fi
Pablo Galindoba421752021-05-03 20:33:17 +010012149rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012150 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012151LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000012152fi
Pablo Galindoba421752021-05-03 20:33:17 +010012153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5
12154printf "%s\n" "$ac_cv_lib_cma_pthread_create" >&6; }
12155if test "x$ac_cv_lib_cma_pthread_create" = xyes
12156then :
Guido van Rossumb93a8621998-05-07 13:27:32 +000012157
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012158 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000012159 LIBS="$LIBS -lcma"
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012160
Pablo Galindoba421752021-05-03 20:33:17 +010012161else $as_nop
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000012162
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012163 as_fn_error $? "could not find pthreads on your system" "$LINENO" 5
12164
Guido van Rossum2d38f911996-06-26 19:47:01 +000012165fi
12166
Guido van Rossum627b2d71993-12-24 10:39:16 +000012167
Guido van Rossum7b3853f1996-07-30 18:09:35 +000012168fi
12169
Guido van Rossum0be3e491997-05-22 20:33:33 +000012170fi
12171
Guido van Rossum49545951997-12-02 19:28:29 +000012172fi
12173
Guido van Rossumb93a8621998-05-07 13:27:32 +000012174fi
12175
Martin v. Löwisf90ae202002-06-11 06:22:31 +000012176fi
Pablo Galindoba421752021-05-03 20:33:17 +010012177rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012178 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012179
Pablo Galindoba421752021-05-03 20:33:17 +010012180 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5
12181printf %s "checking for usconfig in -lmpc... " >&6; }
12182if test ${ac_cv_lib_mpc_usconfig+y}
12183then :
12184 printf %s "(cached) " >&6
12185else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000012186 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012187LIBS="-lmpc $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000012188cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012189/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012190
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012191/* Override any GCC internal prototype to avoid an error.
12192 Use char because int might match the return type of a GCC
12193 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012194char usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012195int
Pablo Galindoba421752021-05-03 20:33:17 +010012196main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012197{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012198return usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012199 ;
12200 return 0;
12201}
12202_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012203if ac_fn_c_try_link "$LINENO"
12204then :
Martin v. Löwis11437992002-04-12 09:54:03 +000012205 ac_cv_lib_mpc_usconfig=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012206else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012207 ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000012208fi
Pablo Galindoba421752021-05-03 20:33:17 +010012209rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000012210 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012211LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012212fi
Pablo Galindoba421752021-05-03 20:33:17 +010012213{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5
12214printf "%s\n" "$ac_cv_lib_mpc_usconfig" >&6; }
12215if test "x$ac_cv_lib_mpc_usconfig" = xyes
12216then :
Guido van Rossum627b2d71993-12-24 10:39:16 +000012217
Martin v. Löwis130fb172001-07-19 11:00:41 +000012218 LIBS="$LIBS -lmpc"
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020012219
Guido van Rossum627b2d71993-12-24 10:39:16 +000012220fi
12221
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000012222
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012223fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012224
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012225if test "$posix_threads" = "yes"; then
12226 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012227
Pablo Galindoba421752021-05-03 20:33:17 +010012228printf "%s\n" "#define _POSIX_THREADS 1" >>confdefs.h
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012229
12230 fi
12231
12232 # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8.
12233 case $ac_sys_system/$ac_sys_release in
Charles-François Natali996f6062011-07-21 19:45:31 +020012234 SunOS/5.6)
Pablo Galindoba421752021-05-03 20:33:17 +010012235printf "%s\n" "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012236
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012237 ;;
12238 SunOS/5.8)
Pablo Galindoba421752021-05-03 20:33:17 +010012239printf "%s\n" "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012240
12241 ;;
Charles-François Natali996f6062011-07-21 19:45:31 +020012242 AIX/*)
Pablo Galindoba421752021-05-03 20:33:17 +010012243printf "%s\n" "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h
Christian Heimes7b3ce6a2008-01-31 14:31:45 +000012244
12245 ;;
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012246 esac
12247
Pablo Galindoba421752021-05-03 20:33:17 +010012248 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
12249printf %s "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; }
12250 if test ${ac_cv_pthread_system_supported+y}
12251then :
12252 printf %s "(cached) " >&6
12253else $as_nop
12254 if test "$cross_compiling" = yes
12255then :
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012256 ac_cv_pthread_system_supported=no
Pablo Galindoba421752021-05-03 20:33:17 +010012257else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012259/* end confdefs.h. */
Stefan Krah7dba5942012-11-22 22:49:11 +010012260
12261 #include <stdio.h>
12262 #include <pthread.h>
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012263 void *foo(void *parm) {
12264 return NULL;
12265 }
12266 main() {
12267 pthread_attr_t attr;
12268 pthread_t id;
Joshua Root674fa0a2020-12-14 07:56:34 +110012269 if (pthread_attr_init(&attr)) return (-1);
12270 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) return (-1);
12271 if (pthread_create(&id, &attr, foo, NULL)) return (-1);
12272 return (0);
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012273 }
12274_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012275if ac_fn_c_try_run "$LINENO"
12276then :
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012277 ac_cv_pthread_system_supported=yes
Pablo Galindoba421752021-05-03 20:33:17 +010012278else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000012279 ac_cv_pthread_system_supported=no
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012280fi
Matthias Kloseb9621712010-04-24 17:59:49 +000012281rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12282 conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012283fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012284
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012285
Guido van Rossum627b2d71993-12-24 10:39:16 +000012286fi
12287
Pablo Galindoba421752021-05-03 20:33:17 +010012288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5
12289printf "%s\n" "$ac_cv_pthread_system_supported" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012290 if test "$ac_cv_pthread_system_supported" = "yes"; then
12291
Pablo Galindoba421752021-05-03 20:33:17 +010012292printf "%s\n" "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012293
12294 fi
Pablo Galindoba421752021-05-03 20:33:17 +010012295
12296 for ac_func in pthread_sigmask
Matthias Kloseb9621712010-04-24 17:59:49 +000012297do :
12298 ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask"
Pablo Galindoba421752021-05-03 20:33:17 +010012299if test "x$ac_cv_func_pthread_sigmask" = xyes
12300then :
12301 printf "%s\n" "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
Jason Tishlerfac083d2003-07-22 15:20:49 +000012302 case $ac_sys_system in
12303 CYGWIN*)
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012304
Pablo Galindoba421752021-05-03 20:33:17 +010012305printf "%s\n" "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h
Jason Tishlerfac083d2003-07-22 15:20:49 +000012306
12307 ;;
12308 esac
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012309fi
Christian Heimes39258d32021-04-17 11:36:35 +020012310
Pablo Galindoba421752021-05-03 20:33:17 +010012311done
12312 ac_fn_c_check_func "$LINENO" "pthread_getcpuclockid" "ac_cv_func_pthread_getcpuclockid"
12313if test "x$ac_cv_func_pthread_getcpuclockid" = xyes
12314then :
12315 printf "%s\n" "#define HAVE_PTHREAD_GETCPUCLOCKID 1" >>confdefs.h
pdoxe14679c2017-10-05 00:01:56 -070012316
12317fi
pdoxe14679c2017-10-05 00:01:56 -070012318
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012319fi
12320
12321
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012322# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000012323
Pablo Galindoba421752021-05-03 20:33:17 +010012324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5
12325printf %s "checking if --enable-ipv6 is specified... " >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012326# Check whether --enable-ipv6 was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012327if test ${enable_ipv6+y}
12328then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012329 enableval=$enable_ipv6; case "$enableval" in
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012330 no)
Pablo Galindoba421752021-05-03 20:33:17 +010012331 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12332printf "%s\n" "no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012333 ipv6=no
12334 ;;
Pablo Galindoba421752021-05-03 20:33:17 +010012335 *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12336printf "%s\n" "yes" >&6; }
12337 printf "%s\n" "#define ENABLE_IPV6 1" >>confdefs.h
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012338
12339 ipv6=yes
12340 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000012341 esac
Pablo Galindoba421752021-05-03 20:33:17 +010012342else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000012343
Matthias Kloseb9621712010-04-24 17:59:49 +000012344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012345/* end confdefs.h. */
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012346 /* AF_INET6 available check */
12347#include <sys/types.h>
12348#include <sys/socket.h>
Charles-François Natalif6fd7942013-01-08 19:49:42 +010012349int
Pablo Galindoba421752021-05-03 20:33:17 +010012350main (void)
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012351{
Charles-François Natalif6fd7942013-01-08 19:49:42 +010012352int domain = AF_INET6;
12353 ;
12354 return 0;
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012355}
Martin v. Löwis11437992002-04-12 09:54:03 +000012356_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012357if ac_fn_c_try_compile "$LINENO"
12358then :
Matthias Kloseb159a552010-04-25 21:00:44 +000012359
Pablo Galindoba421752021-05-03 20:33:17 +010012360 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12361printf "%s\n" "yes" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012362 ipv6=yes
Matthias Kloseb159a552010-04-25 21:00:44 +000012363
Pablo Galindoba421752021-05-03 20:33:17 +010012364else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +000012365
Pablo Galindoba421752021-05-03 20:33:17 +010012366 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12367printf "%s\n" "no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012368 ipv6=no
Matthias Kloseb159a552010-04-25 21:00:44 +000012369
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012370fi
Pablo Galindoba421752021-05-03 20:33:17 +010012371rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012372
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012373if test "$ipv6" = "yes"; then
Pablo Galindoba421752021-05-03 20:33:17 +010012374 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5
12375printf %s "checking if RFC2553 API is available... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000012376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012377/* end confdefs.h. */
Matthias Kloseb159a552010-04-25 21:00:44 +000012378
12379 #include <sys/types.h>
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012380#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012381int
Pablo Galindoba421752021-05-03 20:33:17 +010012382main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000012383{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012384struct sockaddr_in6 x;
Matthias Kloseb159a552010-04-25 21:00:44 +000012385 x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000012386 ;
12387 return 0;
12388}
Matthias Kloseb159a552010-04-25 21:00:44 +000012389
Martin v. Löwis11437992002-04-12 09:54:03 +000012390_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012391if ac_fn_c_try_compile "$LINENO"
12392then :
Matthias Kloseb159a552010-04-25 21:00:44 +000012393
Pablo Galindoba421752021-05-03 20:33:17 +010012394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12395printf "%s\n" "yes" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000012396 ipv6=yes
12397
Pablo Galindoba421752021-05-03 20:33:17 +010012398else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +000012399
Pablo Galindoba421752021-05-03 20:33:17 +010012400 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12401printf "%s\n" "no" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000012402 ipv6=no
12403
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012404fi
Pablo Galindoba421752021-05-03 20:33:17 +010012405rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012406fi
12407
12408if test "$ipv6" = "yes"; then
Pablo Galindoba421752021-05-03 20:33:17 +010012409 printf "%s\n" "#define ENABLE_IPV6 1" >>confdefs.h
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012410
12411fi
12412
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012413fi
12414
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012415
12416ipv6type=unknown
12417ipv6lib=none
12418ipv6trylibc=no
12419
12420if test "$ipv6" = "yes"; then
Pablo Galindoba421752021-05-03 20:33:17 +010012421 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5
12422printf %s "checking ipv6 stack type... " >&6; }
Guido van Rossumb8552162001-09-05 14:58:11 +000012423 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
12424 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012425 case $i in
12426 inria)
Matthias Kloseb9621712010-04-24 17:59:49 +000012427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012428/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012429
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012430#include <netinet/in.h>
12431#ifdef IPV6_INRIA_VERSION
12432yes
12433#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012434_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012435if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012436 $EGREP "yes" >/dev/null 2>&1
12437then :
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012438 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012439fi
Pablo Galindoba421752021-05-03 20:33:17 +010012440rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012441
12442 ;;
12443 kame)
Matthias Kloseb9621712010-04-24 17:59:49 +000012444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012445/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012446
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012447#include <netinet/in.h>
12448#ifdef __KAME__
12449yes
12450#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012451_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012452if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012453 $EGREP "yes" >/dev/null 2>&1
12454then :
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012455 ipv6type=$i;
12456 ipv6lib=inet6
12457 ipv6libdir=/usr/local/v6/lib
12458 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012459fi
Pablo Galindoba421752021-05-03 20:33:17 +010012460rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012461
12462 ;;
12463 linux-glibc)
Matthias Kloseb9621712010-04-24 17:59:49 +000012464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012465/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012466
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012467#include <features.h>
12468#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
12469yes
12470#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012471_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012472if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012473 $EGREP "yes" >/dev/null 2>&1
12474then :
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012475 ipv6type=$i;
12476 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012477fi
Pablo Galindoba421752021-05-03 20:33:17 +010012478rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012479
12480 ;;
12481 linux-inet6)
12482 if test -d /usr/inet6; then
12483 ipv6type=$i
12484 ipv6lib=inet6
12485 ipv6libdir=/usr/inet6/lib
Skip Montanarodecc6a42003-01-01 20:07:49 +000012486 BASECFLAGS="-I/usr/inet6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012487 fi
12488 ;;
12489 solaris)
12490 if test -f /etc/netconfig; then
Antoine Pitrouf3fcd9f2011-01-03 18:53:50 +000012491 if $GREP -q tcp6 /etc/netconfig; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012492 ipv6type=$i
12493 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012494 fi
12495 fi
12496 ;;
12497 toshiba)
Matthias Kloseb9621712010-04-24 17:59:49 +000012498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012499/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012500
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012501#include <sys/param.h>
12502#ifdef _TOSHIBA_INET6
12503yes
12504#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012505_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012506if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012507 $EGREP "yes" >/dev/null 2>&1
12508then :
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012509 ipv6type=$i;
12510 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012511 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012512fi
Pablo Galindoba421752021-05-03 20:33:17 +010012513rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012514
12515 ;;
12516 v6d)
Matthias Kloseb9621712010-04-24 17:59:49 +000012517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012518/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012519
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012520#include </usr/local/v6/include/sys/v6config.h>
12521#ifdef __V6D__
12522yes
12523#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012524_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012525if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012526 $EGREP "yes" >/dev/null 2>&1
12527then :
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012528 ipv6type=$i;
12529 ipv6lib=v6;
12530 ipv6libdir=/usr/local/v6/lib;
Skip Montanarodecc6a42003-01-01 20:07:49 +000012531 BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012532fi
Pablo Galindoba421752021-05-03 20:33:17 +010012533rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012534
12535 ;;
12536 zeta)
Matthias Kloseb9621712010-04-24 17:59:49 +000012537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000012538/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012539
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012540#include <sys/param.h>
12541#ifdef _ZETA_MINAMI_INET6
12542yes
12543#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012544_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012545if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Pablo Galindoba421752021-05-03 20:33:17 +010012546 $EGREP "yes" >/dev/null 2>&1
12547then :
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012548 ipv6type=$i;
12549 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012550 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012551fi
Pablo Galindoba421752021-05-03 20:33:17 +010012552rm -rf conftest*
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012553
12554 ;;
12555 esac
12556 if test "$ipv6type" != "unknown"; then
12557 break
12558 fi
12559 done
Pablo Galindoba421752021-05-03 20:33:17 +010012560 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5
12561printf "%s\n" "$ipv6type" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012562fi
12563
12564if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
12565 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
12566 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
12567 echo "using lib$ipv6lib"
12568 else
12569 if test $ipv6trylibc = "yes"; then
12570 echo "using libc"
12571 else
12572 echo 'Fatal: no $ipv6lib library found. cannot continue.'
12573 echo "You need to fetch lib$ipv6lib.a from appropriate"
12574 echo 'ipv6 kit and compile beforehand.'
12575 exit 1
12576 fi
12577 fi
12578fi
12579
Pablo Galindoba421752021-05-03 20:33:17 +010012580{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CAN_RAW_FD_FRAMES" >&5
12581printf %s "checking for CAN_RAW_FD_FRAMES... " >&6; }
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012582cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12583/* end confdefs.h. */
12584 /* CAN_RAW_FD_FRAMES available check */
12585#include <linux/can/raw.h>
12586int
Pablo Galindoba421752021-05-03 20:33:17 +010012587main (void)
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012588{
12589int can_raw_fd_frames = CAN_RAW_FD_FRAMES;
12590 ;
12591 return 0;
12592}
12593_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012594if ac_fn_c_try_compile "$LINENO"
12595then :
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012596
12597
Pablo Galindoba421752021-05-03 20:33:17 +010012598printf "%s\n" "#define HAVE_LINUX_CAN_RAW_FD_FRAMES 1" >>confdefs.h
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012599
Pablo Galindoba421752021-05-03 20:33:17 +010012600 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12601printf "%s\n" "yes" >&6; }
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012602
Pablo Galindoba421752021-05-03 20:33:17 +010012603else $as_nop
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012604
Pablo Galindoba421752021-05-03 20:33:17 +010012605 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12606printf "%s\n" "no" >&6; }
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012607
12608fi
Pablo Galindoba421752021-05-03 20:33:17 +010012609rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Larry Hastingsa6cc5512015-04-13 17:48:40 -040012610
Pablo Galindoba421752021-05-03 20:33:17 +010012611{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CAN_RAW_JOIN_FILTERS" >&5
12612printf %s "checking for CAN_RAW_JOIN_FILTERS... " >&6; }
Zackery Spytz97e0de02020-04-09 06:03:49 -060012613cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12614/* end confdefs.h. */
12615
12616#include <linux/can/raw.h>
12617int
Pablo Galindoba421752021-05-03 20:33:17 +010012618main (void)
Zackery Spytz97e0de02020-04-09 06:03:49 -060012619{
12620int can_raw_join_filters = CAN_RAW_JOIN_FILTERS;
12621 ;
12622 return 0;
12623}
12624_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010012625if ac_fn_c_try_compile "$LINENO"
12626then :
Zackery Spytz97e0de02020-04-09 06:03:49 -060012627
12628
Pablo Galindoba421752021-05-03 20:33:17 +010012629printf "%s\n" "#define HAVE_LINUX_CAN_RAW_JOIN_FILTERS 1" >>confdefs.h
Zackery Spytz97e0de02020-04-09 06:03:49 -060012630
Pablo Galindoba421752021-05-03 20:33:17 +010012631 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12632printf "%s\n" "yes" >&6; }
Zackery Spytz97e0de02020-04-09 06:03:49 -060012633
Pablo Galindoba421752021-05-03 20:33:17 +010012634else $as_nop
Zackery Spytz97e0de02020-04-09 06:03:49 -060012635
Pablo Galindoba421752021-05-03 20:33:17 +010012636 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12637printf "%s\n" "no" >&6; }
Zackery Spytz97e0de02020-04-09 06:03:49 -060012638
12639fi
Pablo Galindoba421752021-05-03 20:33:17 +010012640rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Zackery Spytz97e0de02020-04-09 06:03:49 -060012641
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012642# Check for --with-doc-strings
Pablo Galindoba421752021-05-03 20:33:17 +010012643{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5
12644printf %s "checking for --with-doc-strings... " >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012645
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012646# Check whether --with-doc-strings was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012647if test ${with_doc_strings+y}
12648then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012649 withval=$with_doc_strings;
12650fi
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012651
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012652
12653if test -z "$with_doc_strings"
12654then with_doc_strings="yes"
12655fi
12656if test "$with_doc_strings" != "no"
12657then
12658
Pablo Galindoba421752021-05-03 20:33:17 +010012659printf "%s\n" "#define WITH_DOC_STRINGS 1" >>confdefs.h
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012660
12661fi
Pablo Galindoba421752021-05-03 20:33:17 +010012662{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5
12663printf "%s\n" "$with_doc_strings" >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012664
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000012665# Check for Python-specific malloc support
Pablo Galindoba421752021-05-03 20:33:17 +010012666{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5
12667printf %s "checking for --with-pymalloc... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000012668
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012669# Check whether --with-pymalloc was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012670if test ${with_pymalloc+y}
12671then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000012672 withval=$with_pymalloc;
12673fi
Michael W. Hudson54241132001-12-07 15:38:26 +000012674
Neil Schemenauera35c6882001-02-27 04:45:05 +000012675
Neil Schemenauer16c22972002-03-22 15:34:49 +000012676if test -z "$with_pymalloc"
Barry Warsaw35f3a2c2010-09-03 18:30:30 +000012677then
12678 with_pymalloc="yes"
Neil Schemenauer16c22972002-03-22 15:34:49 +000012679fi
12680if test "$with_pymalloc" != "no"
12681then
Martin v. Löwis11437992002-04-12 09:54:03 +000012682
Pablo Galindoba421752021-05-03 20:33:17 +010012683printf "%s\n" "#define WITH_PYMALLOC 1" >>confdefs.h
Neil Schemenauer16c22972002-03-22 15:34:49 +000012684
12685fi
Pablo Galindoba421752021-05-03 20:33:17 +010012686{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5
12687printf "%s\n" "$with_pymalloc" >&6; }
Neil Schemenauer16c22972002-03-22 15:34:49 +000012688
Nick Coghlan6ea41862017-06-11 13:16:15 +100012689# Check for --with-c-locale-coercion
Pablo Galindoba421752021-05-03 20:33:17 +010012690{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-c-locale-coercion" >&5
12691printf %s "checking for --with-c-locale-coercion... " >&6; }
Nick Coghlan6ea41862017-06-11 13:16:15 +100012692
12693# Check whether --with-c-locale-coercion was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012694if test ${with_c_locale_coercion+y}
12695then :
Nick Coghlan6ea41862017-06-11 13:16:15 +100012696 withval=$with_c_locale_coercion;
12697fi
12698
12699
12700if test -z "$with_c_locale_coercion"
12701then
12702 with_c_locale_coercion="yes"
12703fi
12704if test "$with_c_locale_coercion" != "no"
12705then
12706
Pablo Galindoba421752021-05-03 20:33:17 +010012707printf "%s\n" "#define PY_COERCE_C_LOCALE 1" >>confdefs.h
Nick Coghlan6ea41862017-06-11 13:16:15 +100012708
12709fi
Pablo Galindoba421752021-05-03 20:33:17 +010012710{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_c_locale_coercion" >&5
12711printf "%s\n" "$with_c_locale_coercion" >&6; }
Nick Coghlan6ea41862017-06-11 13:16:15 +100012712
Benjamin Peterson05159c42009-12-03 03:01:27 +000012713# Check for Valgrind support
Pablo Galindoba421752021-05-03 20:33:17 +010012714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5
12715printf %s "checking for --with-valgrind... " >&6; }
Benjamin Peterson05159c42009-12-03 03:01:27 +000012716
12717# Check whether --with-valgrind was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012718if test ${with_valgrind+y}
12719then :
Benjamin Peterson05159c42009-12-03 03:01:27 +000012720 withval=$with_valgrind;
Pablo Galindoba421752021-05-03 20:33:17 +010012721else $as_nop
Benjamin Peterson05159c42009-12-03 03:01:27 +000012722 with_valgrind=no
12723fi
12724
Pablo Galindoba421752021-05-03 20:33:17 +010012725{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5
12726printf "%s\n" "$with_valgrind" >&6; }
Benjamin Peterson05159c42009-12-03 03:01:27 +000012727if test "$with_valgrind" != no; then
Pablo Galindoba421752021-05-03 20:33:17 +010012728 ac_fn_c_check_header_compile "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default"
12729if test "x$ac_cv_header_valgrind_valgrind_h" = xyes
12730then :
Benjamin Peterson05159c42009-12-03 03:01:27 +000012731
Pablo Galindoba421752021-05-03 20:33:17 +010012732printf "%s\n" "#define WITH_VALGRIND 1" >>confdefs.h
Benjamin Peterson05159c42009-12-03 03:01:27 +000012733
Pablo Galindoba421752021-05-03 20:33:17 +010012734else $as_nop
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020012735 as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5
Benjamin Peterson05159c42009-12-03 03:01:27 +000012736
12737fi
12738
Jeffrey Yasskin39370832010-05-03 19:29:34 +000012739 OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT"
Benjamin Peterson05159c42009-12-03 03:01:27 +000012740fi
12741
Łukasz Langaa785c872016-09-09 17:37:37 -070012742# Check for DTrace support
Pablo Galindoba421752021-05-03 20:33:17 +010012743{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-dtrace" >&5
12744printf %s "checking for --with-dtrace... " >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -070012745
12746# Check whether --with-dtrace was given.
Pablo Galindoba421752021-05-03 20:33:17 +010012747if test ${with_dtrace+y}
12748then :
Łukasz Langaa785c872016-09-09 17:37:37 -070012749 withval=$with_dtrace;
Pablo Galindoba421752021-05-03 20:33:17 +010012750else $as_nop
Łukasz Langaa785c872016-09-09 17:37:37 -070012751 with_dtrace=no
12752fi
12753
Pablo Galindoba421752021-05-03 20:33:17 +010012754{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_dtrace" >&5
12755printf "%s\n" "$with_dtrace" >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -070012756
12757
12758
12759
12760
12761DTRACE=
Łukasz Langaa785c872016-09-09 17:37:37 -070012762DTRACE_HEADERS=
12763DTRACE_OBJS=
12764
12765if test "$with_dtrace" = "yes"
12766then
12767 # Extract the first word of "dtrace", so it can be a program name with args.
12768set dummy dtrace; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010012769{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12770printf %s "checking for $ac_word... " >&6; }
12771if test ${ac_cv_path_DTRACE+y}
12772then :
12773 printf %s "(cached) " >&6
12774else $as_nop
Łukasz Langaa785c872016-09-09 17:37:37 -070012775 case $DTRACE in
12776 [\\/]* | ?:[\\/]*)
12777 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
12778 ;;
12779 *)
12780 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12781for as_dir in $PATH
12782do
12783 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010012784 case $as_dir in #(((
12785 '') as_dir=./ ;;
12786 */) ;;
12787 *) as_dir=$as_dir/ ;;
12788 esac
Łukasz Langaa785c872016-09-09 17:37:37 -070012789 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010012790 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
12791 ac_cv_path_DTRACE="$as_dir$ac_word$ac_exec_ext"
12792 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Łukasz Langaa785c872016-09-09 17:37:37 -070012793 break 2
12794 fi
12795done
12796 done
12797IFS=$as_save_IFS
12798
12799 test -z "$ac_cv_path_DTRACE" && ac_cv_path_DTRACE="not found"
12800 ;;
12801esac
12802fi
12803DTRACE=$ac_cv_path_DTRACE
12804if test -n "$DTRACE"; then
Pablo Galindoba421752021-05-03 20:33:17 +010012805 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
12806printf "%s\n" "$DTRACE" >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -070012807else
Pablo Galindoba421752021-05-03 20:33:17 +010012808 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12809printf "%s\n" "no" >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -070012810fi
12811
12812
12813 if test "$DTRACE" = "not found"; then
12814 as_fn_error $? "dtrace command not found on \$PATH" "$LINENO" 5
12815 fi
12816
Pablo Galindoba421752021-05-03 20:33:17 +010012817printf "%s\n" "#define WITH_DTRACE 1" >>confdefs.h
Łukasz Langaa785c872016-09-09 17:37:37 -070012818
12819 DTRACE_HEADERS="Include/pydtrace_probes.h"
12820
12821 # On OS X, DTrace providers do not need to be explicitly compiled and
12822 # linked into the binary. Correspondingly, dtrace(1) is missing the ELF
12823 # generation flag '-G'. We check for presence of this flag, rather than
12824 # hardcoding support by OS, in the interest of robustness.
Pablo Galindoba421752021-05-03 20:33:17 +010012825 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether DTrace probes require linking" >&5
12826printf %s "checking whether DTrace probes require linking... " >&6; }
12827if test ${ac_cv_dtrace_link+y}
12828then :
12829 printf %s "(cached) " >&6
12830else $as_nop
Łukasz Langaa785c872016-09-09 17:37:37 -070012831 ac_cv_dtrace_link=no
Jakub Kulík5c8f5372019-01-24 18:29:48 +010012832 echo 'BEGIN{}' > conftest.d
Petr Viktorin3c97e1e2020-03-11 14:27:42 +010012833 "$DTRACE" $DFLAGS -G -s conftest.d -o conftest.o > /dev/null 2>&1 && \
Łukasz Langaa785c872016-09-09 17:37:37 -070012834 ac_cv_dtrace_link=yes
12835
12836fi
Pablo Galindoba421752021-05-03 20:33:17 +010012837{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_dtrace_link" >&5
12838printf "%s\n" "$ac_cv_dtrace_link" >&6; }
Łukasz Langaa785c872016-09-09 17:37:37 -070012839 if test "$ac_cv_dtrace_link" = "yes"; then
12840 DTRACE_OBJS="Python/pydtrace.o"
12841 fi
12842fi
12843
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012844# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000012845
Guido van Rossum98935bf2001-09-05 19:13:16 +000012846DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000012847
Guido van Rossume97ee181999-12-20 21:27:22 +000012848# the dlopen() function means we might want to use dynload_shlib.o. some
Kevin Adlerc79667f2020-11-16 09:16:10 -060012849# platforms have dlopen(), but don't want to use it.
Pablo Galindoba421752021-05-03 20:33:17 +010012850ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
12851if test "x$ac_cv_func_dlopen" = xyes
12852then :
12853 printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
Guido van Rossume97ee181999-12-20 21:27:22 +000012854
Guido van Rossume97ee181999-12-20 21:27:22 +000012855fi
12856
Michael W. Hudson54241132001-12-07 15:38:26 +000012857
Guido van Rossume97ee181999-12-20 21:27:22 +000012858# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
12859# loading of modules.
12860
Pablo Galindoba421752021-05-03 20:33:17 +010012861{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5
12862printf %s "checking DYNLOADFILE... " >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000012863if test -z "$DYNLOADFILE"
12864then
12865 case $ac_sys_system/$ac_sys_release in
Guido van Rossume97ee181999-12-20 21:27:22 +000012866 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000012867 *)
12868 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
12869 # out any dynamic loading
12870 if test "$ac_cv_func_dlopen" = yes
12871 then DYNLOADFILE="dynload_shlib.o"
12872 else DYNLOADFILE="dynload_stub.o"
12873 fi
12874 ;;
12875 esac
12876fi
Pablo Galindoba421752021-05-03 20:33:17 +010012877{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5
12878printf "%s\n" "$DYNLOADFILE" >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000012879if test "$DYNLOADFILE" != "dynload_stub.o"
12880then
Martin v. Löwis11437992002-04-12 09:54:03 +000012881
Pablo Galindoba421752021-05-03 20:33:17 +010012882printf "%s\n" "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h
Guido van Rossume97ee181999-12-20 21:27:22 +000012883
12884fi
12885
Neil Schemenauer4e425612001-06-19 15:44:15 +000012886# MACHDEP_OBJS can be set to platform-specific object files needed by Python
12887
Michael W. Hudson54241132001-12-07 15:38:26 +000012888
Pablo Galindoba421752021-05-03 20:33:17 +010012889{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5
12890printf %s "checking MACHDEP_OBJS... " >&6; }
Neil Schemenauer4e425612001-06-19 15:44:15 +000012891if test -z "$MACHDEP_OBJS"
12892then
Jack Jansene578a632001-08-15 01:27:14 +000012893 MACHDEP_OBJS=$extra_machdep_objs
12894else
12895 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000012896fi
doko@ubuntu.com9c7817e2012-06-30 17:05:13 +020012897if test -z "$MACHDEP_OBJS"; then
Pablo Galindoba421752021-05-03 20:33:17 +010012898 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
12899printf "%s\n" "none" >&6; }
doko@ubuntu.com9c7817e2012-06-30 17:05:13 +020012900else
Pablo Galindoba421752021-05-03 20:33:17 +010012901 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MACHDEP_OBJS" >&5
12902printf "%s\n" "$MACHDEP_OBJS" >&6; }
doko@ubuntu.com9c7817e2012-06-30 17:05:13 +020012903fi
Neil Schemenauer4e425612001-06-19 15:44:15 +000012904
Guido van Rossum627b2d71993-12-24 10:39:16 +000012905# checks for library functions
Pablo Galindoba421752021-05-03 20:33:17 +010012906ac_fn_c_check_func "$LINENO" "alarm" "ac_cv_func_alarm"
12907if test "x$ac_cv_func_alarm" = xyes
12908then :
12909 printf "%s\n" "#define HAVE_ALARM 1" >>confdefs.h
Fred Drake8cef4cf2000-06-28 16:40:38 +000012910
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012911fi
Pablo Galindoba421752021-05-03 20:33:17 +010012912ac_fn_c_check_func "$LINENO" "accept4" "ac_cv_func_accept4"
12913if test "x$ac_cv_func_accept4" = xyes
12914then :
12915 printf "%s\n" "#define HAVE_ACCEPT4 1" >>confdefs.h
12916
12917fi
12918ac_fn_c_check_func "$LINENO" "setitimer" "ac_cv_func_setitimer"
12919if test "x$ac_cv_func_setitimer" = xyes
12920then :
12921 printf "%s\n" "#define HAVE_SETITIMER 1" >>confdefs.h
12922
12923fi
12924ac_fn_c_check_func "$LINENO" "getitimer" "ac_cv_func_getitimer"
12925if test "x$ac_cv_func_getitimer" = xyes
12926then :
12927 printf "%s\n" "#define HAVE_GETITIMER 1" >>confdefs.h
12928
12929fi
12930ac_fn_c_check_func "$LINENO" "bind_textdomain_codeset" "ac_cv_func_bind_textdomain_codeset"
12931if test "x$ac_cv_func_bind_textdomain_codeset" = xyes
12932then :
12933 printf "%s\n" "#define HAVE_BIND_TEXTDOMAIN_CODESET 1" >>confdefs.h
12934
12935fi
12936ac_fn_c_check_func "$LINENO" "chown" "ac_cv_func_chown"
12937if test "x$ac_cv_func_chown" = xyes
12938then :
12939 printf "%s\n" "#define HAVE_CHOWN 1" >>confdefs.h
12940
12941fi
12942ac_fn_c_check_func "$LINENO" "clock" "ac_cv_func_clock"
12943if test "x$ac_cv_func_clock" = xyes
12944then :
12945 printf "%s\n" "#define HAVE_CLOCK 1" >>confdefs.h
12946
12947fi
12948ac_fn_c_check_func "$LINENO" "confstr" "ac_cv_func_confstr"
12949if test "x$ac_cv_func_confstr" = xyes
12950then :
12951 printf "%s\n" "#define HAVE_CONFSTR 1" >>confdefs.h
12952
12953fi
12954ac_fn_c_check_func "$LINENO" "close_range" "ac_cv_func_close_range"
12955if test "x$ac_cv_func_close_range" = xyes
12956then :
12957 printf "%s\n" "#define HAVE_CLOSE_RANGE 1" >>confdefs.h
12958
12959fi
12960ac_fn_c_check_func "$LINENO" "copy_file_range" "ac_cv_func_copy_file_range"
12961if test "x$ac_cv_func_copy_file_range" = xyes
12962then :
12963 printf "%s\n" "#define HAVE_COPY_FILE_RANGE 1" >>confdefs.h
12964
12965fi
12966ac_fn_c_check_func "$LINENO" "ctermid" "ac_cv_func_ctermid"
12967if test "x$ac_cv_func_ctermid" = xyes
12968then :
12969 printf "%s\n" "#define HAVE_CTERMID 1" >>confdefs.h
12970
12971fi
12972ac_fn_c_check_func "$LINENO" "dup3" "ac_cv_func_dup3"
12973if test "x$ac_cv_func_dup3" = xyes
12974then :
12975 printf "%s\n" "#define HAVE_DUP3 1" >>confdefs.h
12976
12977fi
12978ac_fn_c_check_func "$LINENO" "execv" "ac_cv_func_execv"
12979if test "x$ac_cv_func_execv" = xyes
12980then :
12981 printf "%s\n" "#define HAVE_EXECV 1" >>confdefs.h
12982
12983fi
12984ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero"
12985if test "x$ac_cv_func_explicit_bzero" = xyes
12986then :
12987 printf "%s\n" "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h
12988
12989fi
12990ac_fn_c_check_func "$LINENO" "explicit_memset" "ac_cv_func_explicit_memset"
12991if test "x$ac_cv_func_explicit_memset" = xyes
12992then :
12993 printf "%s\n" "#define HAVE_EXPLICIT_MEMSET 1" >>confdefs.h
12994
12995fi
12996ac_fn_c_check_func "$LINENO" "faccessat" "ac_cv_func_faccessat"
12997if test "x$ac_cv_func_faccessat" = xyes
12998then :
12999 printf "%s\n" "#define HAVE_FACCESSAT 1" >>confdefs.h
13000
13001fi
13002ac_fn_c_check_func "$LINENO" "fchmod" "ac_cv_func_fchmod"
13003if test "x$ac_cv_func_fchmod" = xyes
13004then :
13005 printf "%s\n" "#define HAVE_FCHMOD 1" >>confdefs.h
13006
13007fi
13008ac_fn_c_check_func "$LINENO" "fchmodat" "ac_cv_func_fchmodat"
13009if test "x$ac_cv_func_fchmodat" = xyes
13010then :
13011 printf "%s\n" "#define HAVE_FCHMODAT 1" >>confdefs.h
13012
13013fi
13014ac_fn_c_check_func "$LINENO" "fchown" "ac_cv_func_fchown"
13015if test "x$ac_cv_func_fchown" = xyes
13016then :
13017 printf "%s\n" "#define HAVE_FCHOWN 1" >>confdefs.h
13018
13019fi
13020ac_fn_c_check_func "$LINENO" "fchownat" "ac_cv_func_fchownat"
13021if test "x$ac_cv_func_fchownat" = xyes
13022then :
13023 printf "%s\n" "#define HAVE_FCHOWNAT 1" >>confdefs.h
13024
13025fi
13026ac_fn_c_check_func "$LINENO" "fdwalk" "ac_cv_func_fdwalk"
13027if test "x$ac_cv_func_fdwalk" = xyes
13028then :
13029 printf "%s\n" "#define HAVE_FDWALK 1" >>confdefs.h
13030
13031fi
13032ac_fn_c_check_func "$LINENO" "fexecve" "ac_cv_func_fexecve"
13033if test "x$ac_cv_func_fexecve" = xyes
13034then :
13035 printf "%s\n" "#define HAVE_FEXECVE 1" >>confdefs.h
13036
13037fi
13038ac_fn_c_check_func "$LINENO" "fdopendir" "ac_cv_func_fdopendir"
13039if test "x$ac_cv_func_fdopendir" = xyes
13040then :
13041 printf "%s\n" "#define HAVE_FDOPENDIR 1" >>confdefs.h
13042
13043fi
13044ac_fn_c_check_func "$LINENO" "fork" "ac_cv_func_fork"
13045if test "x$ac_cv_func_fork" = xyes
13046then :
13047 printf "%s\n" "#define HAVE_FORK 1" >>confdefs.h
13048
13049fi
13050ac_fn_c_check_func "$LINENO" "fpathconf" "ac_cv_func_fpathconf"
13051if test "x$ac_cv_func_fpathconf" = xyes
13052then :
13053 printf "%s\n" "#define HAVE_FPATHCONF 1" >>confdefs.h
13054
13055fi
13056ac_fn_c_check_func "$LINENO" "fstatat" "ac_cv_func_fstatat"
13057if test "x$ac_cv_func_fstatat" = xyes
13058then :
13059 printf "%s\n" "#define HAVE_FSTATAT 1" >>confdefs.h
13060
13061fi
13062ac_fn_c_check_func "$LINENO" "ftime" "ac_cv_func_ftime"
13063if test "x$ac_cv_func_ftime" = xyes
13064then :
13065 printf "%s\n" "#define HAVE_FTIME 1" >>confdefs.h
13066
13067fi
13068ac_fn_c_check_func "$LINENO" "ftruncate" "ac_cv_func_ftruncate"
13069if test "x$ac_cv_func_ftruncate" = xyes
13070then :
13071 printf "%s\n" "#define HAVE_FTRUNCATE 1" >>confdefs.h
13072
13073fi
13074ac_fn_c_check_func "$LINENO" "futimesat" "ac_cv_func_futimesat"
13075if test "x$ac_cv_func_futimesat" = xyes
13076then :
13077 printf "%s\n" "#define HAVE_FUTIMESAT 1" >>confdefs.h
13078
13079fi
13080ac_fn_c_check_func "$LINENO" "futimens" "ac_cv_func_futimens"
13081if test "x$ac_cv_func_futimens" = xyes
13082then :
13083 printf "%s\n" "#define HAVE_FUTIMENS 1" >>confdefs.h
13084
13085fi
13086ac_fn_c_check_func "$LINENO" "futimes" "ac_cv_func_futimes"
13087if test "x$ac_cv_func_futimes" = xyes
13088then :
13089 printf "%s\n" "#define HAVE_FUTIMES 1" >>confdefs.h
13090
13091fi
13092ac_fn_c_check_func "$LINENO" "gai_strerror" "ac_cv_func_gai_strerror"
13093if test "x$ac_cv_func_gai_strerror" = xyes
13094then :
13095 printf "%s\n" "#define HAVE_GAI_STRERROR 1" >>confdefs.h
13096
13097fi
13098ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
13099if test "x$ac_cv_func_getentropy" = xyes
13100then :
13101 printf "%s\n" "#define HAVE_GETENTROPY 1" >>confdefs.h
13102
13103fi
13104ac_fn_c_check_func "$LINENO" "getgrgid_r" "ac_cv_func_getgrgid_r"
13105if test "x$ac_cv_func_getgrgid_r" = xyes
13106then :
13107 printf "%s\n" "#define HAVE_GETGRGID_R 1" >>confdefs.h
13108
13109fi
13110ac_fn_c_check_func "$LINENO" "getgrnam_r" "ac_cv_func_getgrnam_r"
13111if test "x$ac_cv_func_getgrnam_r" = xyes
13112then :
13113 printf "%s\n" "#define HAVE_GETGRNAM_R 1" >>confdefs.h
13114
13115fi
13116ac_fn_c_check_func "$LINENO" "getgrouplist" "ac_cv_func_getgrouplist"
13117if test "x$ac_cv_func_getgrouplist" = xyes
13118then :
13119 printf "%s\n" "#define HAVE_GETGROUPLIST 1" >>confdefs.h
13120
13121fi
13122ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
13123if test "x$ac_cv_func_getgroups" = xyes
13124then :
13125 printf "%s\n" "#define HAVE_GETGROUPS 1" >>confdefs.h
13126
13127fi
13128ac_fn_c_check_func "$LINENO" "getlogin" "ac_cv_func_getlogin"
13129if test "x$ac_cv_func_getlogin" = xyes
13130then :
13131 printf "%s\n" "#define HAVE_GETLOGIN 1" >>confdefs.h
13132
13133fi
13134ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
13135if test "x$ac_cv_func_getloadavg" = xyes
13136then :
13137 printf "%s\n" "#define HAVE_GETLOADAVG 1" >>confdefs.h
13138
13139fi
13140ac_fn_c_check_func "$LINENO" "getpeername" "ac_cv_func_getpeername"
13141if test "x$ac_cv_func_getpeername" = xyes
13142then :
13143 printf "%s\n" "#define HAVE_GETPEERNAME 1" >>confdefs.h
13144
13145fi
13146ac_fn_c_check_func "$LINENO" "getpgid" "ac_cv_func_getpgid"
13147if test "x$ac_cv_func_getpgid" = xyes
13148then :
13149 printf "%s\n" "#define HAVE_GETPGID 1" >>confdefs.h
13150
13151fi
13152ac_fn_c_check_func "$LINENO" "getpid" "ac_cv_func_getpid"
13153if test "x$ac_cv_func_getpid" = xyes
13154then :
13155 printf "%s\n" "#define HAVE_GETPID 1" >>confdefs.h
13156
13157fi
13158ac_fn_c_check_func "$LINENO" "getpriority" "ac_cv_func_getpriority"
13159if test "x$ac_cv_func_getpriority" = xyes
13160then :
13161 printf "%s\n" "#define HAVE_GETPRIORITY 1" >>confdefs.h
13162
13163fi
13164ac_fn_c_check_func "$LINENO" "getresuid" "ac_cv_func_getresuid"
13165if test "x$ac_cv_func_getresuid" = xyes
13166then :
13167 printf "%s\n" "#define HAVE_GETRESUID 1" >>confdefs.h
13168
13169fi
13170ac_fn_c_check_func "$LINENO" "getresgid" "ac_cv_func_getresgid"
13171if test "x$ac_cv_func_getresgid" = xyes
13172then :
13173 printf "%s\n" "#define HAVE_GETRESGID 1" >>confdefs.h
13174
13175fi
13176ac_fn_c_check_func "$LINENO" "getpwent" "ac_cv_func_getpwent"
13177if test "x$ac_cv_func_getpwent" = xyes
13178then :
13179 printf "%s\n" "#define HAVE_GETPWENT 1" >>confdefs.h
13180
13181fi
13182ac_fn_c_check_func "$LINENO" "getpwnam_r" "ac_cv_func_getpwnam_r"
13183if test "x$ac_cv_func_getpwnam_r" = xyes
13184then :
13185 printf "%s\n" "#define HAVE_GETPWNAM_R 1" >>confdefs.h
13186
13187fi
13188ac_fn_c_check_func "$LINENO" "getpwuid_r" "ac_cv_func_getpwuid_r"
13189if test "x$ac_cv_func_getpwuid_r" = xyes
13190then :
13191 printf "%s\n" "#define HAVE_GETPWUID_R 1" >>confdefs.h
13192
13193fi
13194ac_fn_c_check_func "$LINENO" "getspnam" "ac_cv_func_getspnam"
13195if test "x$ac_cv_func_getspnam" = xyes
13196then :
13197 printf "%s\n" "#define HAVE_GETSPNAM 1" >>confdefs.h
13198
13199fi
13200ac_fn_c_check_func "$LINENO" "getspent" "ac_cv_func_getspent"
13201if test "x$ac_cv_func_getspent" = xyes
13202then :
13203 printf "%s\n" "#define HAVE_GETSPENT 1" >>confdefs.h
13204
13205fi
13206ac_fn_c_check_func "$LINENO" "getsid" "ac_cv_func_getsid"
13207if test "x$ac_cv_func_getsid" = xyes
13208then :
13209 printf "%s\n" "#define HAVE_GETSID 1" >>confdefs.h
13210
13211fi
13212ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13213if test "x$ac_cv_func_getwd" = xyes
13214then :
13215 printf "%s\n" "#define HAVE_GETWD 1" >>confdefs.h
13216
13217fi
13218ac_fn_c_check_func "$LINENO" "if_nameindex" "ac_cv_func_if_nameindex"
13219if test "x$ac_cv_func_if_nameindex" = xyes
13220then :
13221 printf "%s\n" "#define HAVE_IF_NAMEINDEX 1" >>confdefs.h
13222
13223fi
13224ac_fn_c_check_func "$LINENO" "initgroups" "ac_cv_func_initgroups"
13225if test "x$ac_cv_func_initgroups" = xyes
13226then :
13227 printf "%s\n" "#define HAVE_INITGROUPS 1" >>confdefs.h
13228
13229fi
13230ac_fn_c_check_func "$LINENO" "kill" "ac_cv_func_kill"
13231if test "x$ac_cv_func_kill" = xyes
13232then :
13233 printf "%s\n" "#define HAVE_KILL 1" >>confdefs.h
13234
13235fi
13236ac_fn_c_check_func "$LINENO" "killpg" "ac_cv_func_killpg"
13237if test "x$ac_cv_func_killpg" = xyes
13238then :
13239 printf "%s\n" "#define HAVE_KILLPG 1" >>confdefs.h
13240
13241fi
13242ac_fn_c_check_func "$LINENO" "lchown" "ac_cv_func_lchown"
13243if test "x$ac_cv_func_lchown" = xyes
13244then :
13245 printf "%s\n" "#define HAVE_LCHOWN 1" >>confdefs.h
13246
13247fi
13248ac_fn_c_check_func "$LINENO" "lockf" "ac_cv_func_lockf"
13249if test "x$ac_cv_func_lockf" = xyes
13250then :
13251 printf "%s\n" "#define HAVE_LOCKF 1" >>confdefs.h
13252
13253fi
13254ac_fn_c_check_func "$LINENO" "linkat" "ac_cv_func_linkat"
13255if test "x$ac_cv_func_linkat" = xyes
13256then :
13257 printf "%s\n" "#define HAVE_LINKAT 1" >>confdefs.h
13258
13259fi
13260ac_fn_c_check_func "$LINENO" "lstat" "ac_cv_func_lstat"
13261if test "x$ac_cv_func_lstat" = xyes
13262then :
13263 printf "%s\n" "#define HAVE_LSTAT 1" >>confdefs.h
13264
13265fi
13266ac_fn_c_check_func "$LINENO" "lutimes" "ac_cv_func_lutimes"
13267if test "x$ac_cv_func_lutimes" = xyes
13268then :
13269 printf "%s\n" "#define HAVE_LUTIMES 1" >>confdefs.h
13270
13271fi
13272ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
13273if test "x$ac_cv_func_mmap" = xyes
13274then :
13275 printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h
13276
13277fi
13278ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
13279if test "x$ac_cv_func_memrchr" = xyes
13280then :
13281 printf "%s\n" "#define HAVE_MEMRCHR 1" >>confdefs.h
13282
13283fi
13284ac_fn_c_check_func "$LINENO" "mbrtowc" "ac_cv_func_mbrtowc"
13285if test "x$ac_cv_func_mbrtowc" = xyes
13286then :
13287 printf "%s\n" "#define HAVE_MBRTOWC 1" >>confdefs.h
13288
13289fi
13290ac_fn_c_check_func "$LINENO" "mkdirat" "ac_cv_func_mkdirat"
13291if test "x$ac_cv_func_mkdirat" = xyes
13292then :
13293 printf "%s\n" "#define HAVE_MKDIRAT 1" >>confdefs.h
13294
13295fi
13296ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo"
13297if test "x$ac_cv_func_mkfifo" = xyes
13298then :
13299 printf "%s\n" "#define HAVE_MKFIFO 1" >>confdefs.h
13300
13301fi
13302ac_fn_c_check_func "$LINENO" "madvise" "ac_cv_func_madvise"
13303if test "x$ac_cv_func_madvise" = xyes
13304then :
13305 printf "%s\n" "#define HAVE_MADVISE 1" >>confdefs.h
13306
13307fi
13308ac_fn_c_check_func "$LINENO" "mkfifoat" "ac_cv_func_mkfifoat"
13309if test "x$ac_cv_func_mkfifoat" = xyes
13310then :
13311 printf "%s\n" "#define HAVE_MKFIFOAT 1" >>confdefs.h
13312
13313fi
13314ac_fn_c_check_func "$LINENO" "mknod" "ac_cv_func_mknod"
13315if test "x$ac_cv_func_mknod" = xyes
13316then :
13317 printf "%s\n" "#define HAVE_MKNOD 1" >>confdefs.h
13318
13319fi
13320ac_fn_c_check_func "$LINENO" "mknodat" "ac_cv_func_mknodat"
13321if test "x$ac_cv_func_mknodat" = xyes
13322then :
13323 printf "%s\n" "#define HAVE_MKNODAT 1" >>confdefs.h
13324
13325fi
13326ac_fn_c_check_func "$LINENO" "mktime" "ac_cv_func_mktime"
13327if test "x$ac_cv_func_mktime" = xyes
13328then :
13329 printf "%s\n" "#define HAVE_MKTIME 1" >>confdefs.h
13330
13331fi
13332ac_fn_c_check_func "$LINENO" "mremap" "ac_cv_func_mremap"
13333if test "x$ac_cv_func_mremap" = xyes
13334then :
13335 printf "%s\n" "#define HAVE_MREMAP 1" >>confdefs.h
13336
13337fi
13338ac_fn_c_check_func "$LINENO" "nice" "ac_cv_func_nice"
13339if test "x$ac_cv_func_nice" = xyes
13340then :
13341 printf "%s\n" "#define HAVE_NICE 1" >>confdefs.h
13342
13343fi
13344ac_fn_c_check_func "$LINENO" "openat" "ac_cv_func_openat"
13345if test "x$ac_cv_func_openat" = xyes
13346then :
13347 printf "%s\n" "#define HAVE_OPENAT 1" >>confdefs.h
13348
13349fi
13350ac_fn_c_check_func "$LINENO" "pathconf" "ac_cv_func_pathconf"
13351if test "x$ac_cv_func_pathconf" = xyes
13352then :
13353 printf "%s\n" "#define HAVE_PATHCONF 1" >>confdefs.h
13354
13355fi
13356ac_fn_c_check_func "$LINENO" "pause" "ac_cv_func_pause"
13357if test "x$ac_cv_func_pause" = xyes
13358then :
13359 printf "%s\n" "#define HAVE_PAUSE 1" >>confdefs.h
13360
13361fi
13362ac_fn_c_check_func "$LINENO" "pipe2" "ac_cv_func_pipe2"
13363if test "x$ac_cv_func_pipe2" = xyes
13364then :
13365 printf "%s\n" "#define HAVE_PIPE2 1" >>confdefs.h
13366
13367fi
13368ac_fn_c_check_func "$LINENO" "plock" "ac_cv_func_plock"
13369if test "x$ac_cv_func_plock" = xyes
13370then :
13371 printf "%s\n" "#define HAVE_PLOCK 1" >>confdefs.h
13372
13373fi
13374ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll"
13375if test "x$ac_cv_func_poll" = xyes
13376then :
13377 printf "%s\n" "#define HAVE_POLL 1" >>confdefs.h
13378
13379fi
13380ac_fn_c_check_func "$LINENO" "posix_fallocate" "ac_cv_func_posix_fallocate"
13381if test "x$ac_cv_func_posix_fallocate" = xyes
13382then :
13383 printf "%s\n" "#define HAVE_POSIX_FALLOCATE 1" >>confdefs.h
13384
13385fi
13386ac_fn_c_check_func "$LINENO" "posix_fadvise" "ac_cv_func_posix_fadvise"
13387if test "x$ac_cv_func_posix_fadvise" = xyes
13388then :
13389 printf "%s\n" "#define HAVE_POSIX_FADVISE 1" >>confdefs.h
13390
13391fi
13392ac_fn_c_check_func "$LINENO" "posix_spawn" "ac_cv_func_posix_spawn"
13393if test "x$ac_cv_func_posix_spawn" = xyes
13394then :
13395 printf "%s\n" "#define HAVE_POSIX_SPAWN 1" >>confdefs.h
13396
13397fi
13398ac_fn_c_check_func "$LINENO" "posix_spawnp" "ac_cv_func_posix_spawnp"
13399if test "x$ac_cv_func_posix_spawnp" = xyes
13400then :
13401 printf "%s\n" "#define HAVE_POSIX_SPAWNP 1" >>confdefs.h
13402
13403fi
13404ac_fn_c_check_func "$LINENO" "pread" "ac_cv_func_pread"
13405if test "x$ac_cv_func_pread" = xyes
13406then :
13407 printf "%s\n" "#define HAVE_PREAD 1" >>confdefs.h
13408
13409fi
13410ac_fn_c_check_func "$LINENO" "preadv" "ac_cv_func_preadv"
13411if test "x$ac_cv_func_preadv" = xyes
13412then :
13413 printf "%s\n" "#define HAVE_PREADV 1" >>confdefs.h
13414
13415fi
13416ac_fn_c_check_func "$LINENO" "preadv2" "ac_cv_func_preadv2"
13417if test "x$ac_cv_func_preadv2" = xyes
13418then :
13419 printf "%s\n" "#define HAVE_PREADV2 1" >>confdefs.h
13420
13421fi
13422ac_fn_c_check_func "$LINENO" "pthread_condattr_setclock" "ac_cv_func_pthread_condattr_setclock"
13423if test "x$ac_cv_func_pthread_condattr_setclock" = xyes
13424then :
13425 printf "%s\n" "#define HAVE_PTHREAD_CONDATTR_SETCLOCK 1" >>confdefs.h
13426
13427fi
13428ac_fn_c_check_func "$LINENO" "pthread_init" "ac_cv_func_pthread_init"
13429if test "x$ac_cv_func_pthread_init" = xyes
13430then :
13431 printf "%s\n" "#define HAVE_PTHREAD_INIT 1" >>confdefs.h
13432
13433fi
13434ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill"
13435if test "x$ac_cv_func_pthread_kill" = xyes
13436then :
13437 printf "%s\n" "#define HAVE_PTHREAD_KILL 1" >>confdefs.h
13438
13439fi
13440ac_fn_c_check_func "$LINENO" "pwrite" "ac_cv_func_pwrite"
13441if test "x$ac_cv_func_pwrite" = xyes
13442then :
13443 printf "%s\n" "#define HAVE_PWRITE 1" >>confdefs.h
13444
13445fi
13446ac_fn_c_check_func "$LINENO" "pwritev" "ac_cv_func_pwritev"
13447if test "x$ac_cv_func_pwritev" = xyes
13448then :
13449 printf "%s\n" "#define HAVE_PWRITEV 1" >>confdefs.h
13450
13451fi
13452ac_fn_c_check_func "$LINENO" "pwritev2" "ac_cv_func_pwritev2"
13453if test "x$ac_cv_func_pwritev2" = xyes
13454then :
13455 printf "%s\n" "#define HAVE_PWRITEV2 1" >>confdefs.h
13456
13457fi
13458ac_fn_c_check_func "$LINENO" "readlink" "ac_cv_func_readlink"
13459if test "x$ac_cv_func_readlink" = xyes
13460then :
13461 printf "%s\n" "#define HAVE_READLINK 1" >>confdefs.h
13462
13463fi
13464ac_fn_c_check_func "$LINENO" "readlinkat" "ac_cv_func_readlinkat"
13465if test "x$ac_cv_func_readlinkat" = xyes
13466then :
13467 printf "%s\n" "#define HAVE_READLINKAT 1" >>confdefs.h
13468
13469fi
13470ac_fn_c_check_func "$LINENO" "readv" "ac_cv_func_readv"
13471if test "x$ac_cv_func_readv" = xyes
13472then :
13473 printf "%s\n" "#define HAVE_READV 1" >>confdefs.h
13474
13475fi
13476ac_fn_c_check_func "$LINENO" "realpath" "ac_cv_func_realpath"
13477if test "x$ac_cv_func_realpath" = xyes
13478then :
13479 printf "%s\n" "#define HAVE_REALPATH 1" >>confdefs.h
13480
13481fi
13482ac_fn_c_check_func "$LINENO" "renameat" "ac_cv_func_renameat"
13483if test "x$ac_cv_func_renameat" = xyes
13484then :
13485 printf "%s\n" "#define HAVE_RENAMEAT 1" >>confdefs.h
13486
13487fi
13488ac_fn_c_check_func "$LINENO" "sem_open" "ac_cv_func_sem_open"
13489if test "x$ac_cv_func_sem_open" = xyes
13490then :
13491 printf "%s\n" "#define HAVE_SEM_OPEN 1" >>confdefs.h
13492
13493fi
13494ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait"
13495if test "x$ac_cv_func_sem_timedwait" = xyes
13496then :
13497 printf "%s\n" "#define HAVE_SEM_TIMEDWAIT 1" >>confdefs.h
13498
13499fi
13500ac_fn_c_check_func "$LINENO" "sem_getvalue" "ac_cv_func_sem_getvalue"
13501if test "x$ac_cv_func_sem_getvalue" = xyes
13502then :
13503 printf "%s\n" "#define HAVE_SEM_GETVALUE 1" >>confdefs.h
13504
13505fi
13506ac_fn_c_check_func "$LINENO" "sem_unlink" "ac_cv_func_sem_unlink"
13507if test "x$ac_cv_func_sem_unlink" = xyes
13508then :
13509 printf "%s\n" "#define HAVE_SEM_UNLINK 1" >>confdefs.h
13510
13511fi
13512ac_fn_c_check_func "$LINENO" "sendfile" "ac_cv_func_sendfile"
13513if test "x$ac_cv_func_sendfile" = xyes
13514then :
13515 printf "%s\n" "#define HAVE_SENDFILE 1" >>confdefs.h
13516
13517fi
13518ac_fn_c_check_func "$LINENO" "setegid" "ac_cv_func_setegid"
13519if test "x$ac_cv_func_setegid" = xyes
13520then :
13521 printf "%s\n" "#define HAVE_SETEGID 1" >>confdefs.h
13522
13523fi
13524ac_fn_c_check_func "$LINENO" "seteuid" "ac_cv_func_seteuid"
13525if test "x$ac_cv_func_seteuid" = xyes
13526then :
13527 printf "%s\n" "#define HAVE_SETEUID 1" >>confdefs.h
13528
13529fi
13530ac_fn_c_check_func "$LINENO" "setgid" "ac_cv_func_setgid"
13531if test "x$ac_cv_func_setgid" = xyes
13532then :
13533 printf "%s\n" "#define HAVE_SETGID 1" >>confdefs.h
13534
13535fi
13536ac_fn_c_check_func "$LINENO" "sethostname" "ac_cv_func_sethostname"
13537if test "x$ac_cv_func_sethostname" = xyes
13538then :
13539 printf "%s\n" "#define HAVE_SETHOSTNAME 1" >>confdefs.h
13540
13541fi
13542ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
13543if test "x$ac_cv_func_setlocale" = xyes
13544then :
13545 printf "%s\n" "#define HAVE_SETLOCALE 1" >>confdefs.h
13546
13547fi
13548ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid"
13549if test "x$ac_cv_func_setregid" = xyes
13550then :
13551 printf "%s\n" "#define HAVE_SETREGID 1" >>confdefs.h
13552
13553fi
13554ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid"
13555if test "x$ac_cv_func_setreuid" = xyes
13556then :
13557 printf "%s\n" "#define HAVE_SETREUID 1" >>confdefs.h
13558
13559fi
13560ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
13561if test "x$ac_cv_func_setresuid" = xyes
13562then :
13563 printf "%s\n" "#define HAVE_SETRESUID 1" >>confdefs.h
13564
13565fi
13566ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
13567if test "x$ac_cv_func_setresgid" = xyes
13568then :
13569 printf "%s\n" "#define HAVE_SETRESGID 1" >>confdefs.h
13570
13571fi
13572ac_fn_c_check_func "$LINENO" "setsid" "ac_cv_func_setsid"
13573if test "x$ac_cv_func_setsid" = xyes
13574then :
13575 printf "%s\n" "#define HAVE_SETSID 1" >>confdefs.h
13576
13577fi
13578ac_fn_c_check_func "$LINENO" "setpgid" "ac_cv_func_setpgid"
13579if test "x$ac_cv_func_setpgid" = xyes
13580then :
13581 printf "%s\n" "#define HAVE_SETPGID 1" >>confdefs.h
13582
13583fi
13584ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp"
13585if test "x$ac_cv_func_setpgrp" = xyes
13586then :
13587 printf "%s\n" "#define HAVE_SETPGRP 1" >>confdefs.h
13588
13589fi
13590ac_fn_c_check_func "$LINENO" "setpriority" "ac_cv_func_setpriority"
13591if test "x$ac_cv_func_setpriority" = xyes
13592then :
13593 printf "%s\n" "#define HAVE_SETPRIORITY 1" >>confdefs.h
13594
13595fi
13596ac_fn_c_check_func "$LINENO" "setuid" "ac_cv_func_setuid"
13597if test "x$ac_cv_func_setuid" = xyes
13598then :
13599 printf "%s\n" "#define HAVE_SETUID 1" >>confdefs.h
13600
13601fi
13602ac_fn_c_check_func "$LINENO" "setvbuf" "ac_cv_func_setvbuf"
13603if test "x$ac_cv_func_setvbuf" = xyes
13604then :
13605 printf "%s\n" "#define HAVE_SETVBUF 1" >>confdefs.h
13606
13607fi
13608ac_fn_c_check_func "$LINENO" "sched_get_priority_max" "ac_cv_func_sched_get_priority_max"
13609if test "x$ac_cv_func_sched_get_priority_max" = xyes
13610then :
13611 printf "%s\n" "#define HAVE_SCHED_GET_PRIORITY_MAX 1" >>confdefs.h
13612
13613fi
13614ac_fn_c_check_func "$LINENO" "sched_setaffinity" "ac_cv_func_sched_setaffinity"
13615if test "x$ac_cv_func_sched_setaffinity" = xyes
13616then :
13617 printf "%s\n" "#define HAVE_SCHED_SETAFFINITY 1" >>confdefs.h
13618
13619fi
13620ac_fn_c_check_func "$LINENO" "sched_setscheduler" "ac_cv_func_sched_setscheduler"
13621if test "x$ac_cv_func_sched_setscheduler" = xyes
13622then :
13623 printf "%s\n" "#define HAVE_SCHED_SETSCHEDULER 1" >>confdefs.h
13624
13625fi
13626ac_fn_c_check_func "$LINENO" "sched_setparam" "ac_cv_func_sched_setparam"
13627if test "x$ac_cv_func_sched_setparam" = xyes
13628then :
13629 printf "%s\n" "#define HAVE_SCHED_SETPARAM 1" >>confdefs.h
13630
13631fi
13632ac_fn_c_check_func "$LINENO" "sched_rr_get_interval" "ac_cv_func_sched_rr_get_interval"
13633if test "x$ac_cv_func_sched_rr_get_interval" = xyes
13634then :
13635 printf "%s\n" "#define HAVE_SCHED_RR_GET_INTERVAL 1" >>confdefs.h
13636
13637fi
13638ac_fn_c_check_func "$LINENO" "sigaction" "ac_cv_func_sigaction"
13639if test "x$ac_cv_func_sigaction" = xyes
13640then :
13641 printf "%s\n" "#define HAVE_SIGACTION 1" >>confdefs.h
13642
13643fi
13644ac_fn_c_check_func "$LINENO" "sigaltstack" "ac_cv_func_sigaltstack"
13645if test "x$ac_cv_func_sigaltstack" = xyes
13646then :
13647 printf "%s\n" "#define HAVE_SIGALTSTACK 1" >>confdefs.h
13648
13649fi
13650ac_fn_c_check_func "$LINENO" "sigfillset" "ac_cv_func_sigfillset"
13651if test "x$ac_cv_func_sigfillset" = xyes
13652then :
13653 printf "%s\n" "#define HAVE_SIGFILLSET 1" >>confdefs.h
13654
13655fi
13656ac_fn_c_check_func "$LINENO" "siginterrupt" "ac_cv_func_siginterrupt"
13657if test "x$ac_cv_func_siginterrupt" = xyes
13658then :
13659 printf "%s\n" "#define HAVE_SIGINTERRUPT 1" >>confdefs.h
13660
13661fi
13662ac_fn_c_check_func "$LINENO" "sigpending" "ac_cv_func_sigpending"
13663if test "x$ac_cv_func_sigpending" = xyes
13664then :
13665 printf "%s\n" "#define HAVE_SIGPENDING 1" >>confdefs.h
13666
13667fi
13668ac_fn_c_check_func "$LINENO" "sigrelse" "ac_cv_func_sigrelse"
13669if test "x$ac_cv_func_sigrelse" = xyes
13670then :
13671 printf "%s\n" "#define HAVE_SIGRELSE 1" >>confdefs.h
13672
13673fi
13674ac_fn_c_check_func "$LINENO" "sigtimedwait" "ac_cv_func_sigtimedwait"
13675if test "x$ac_cv_func_sigtimedwait" = xyes
13676then :
13677 printf "%s\n" "#define HAVE_SIGTIMEDWAIT 1" >>confdefs.h
13678
13679fi
13680ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait"
13681if test "x$ac_cv_func_sigwait" = xyes
13682then :
13683 printf "%s\n" "#define HAVE_SIGWAIT 1" >>confdefs.h
13684
13685fi
13686ac_fn_c_check_func "$LINENO" "sigwaitinfo" "ac_cv_func_sigwaitinfo"
13687if test "x$ac_cv_func_sigwaitinfo" = xyes
13688then :
13689 printf "%s\n" "#define HAVE_SIGWAITINFO 1" >>confdefs.h
13690
13691fi
13692ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
13693if test "x$ac_cv_func_snprintf" = xyes
13694then :
13695 printf "%s\n" "#define HAVE_SNPRINTF 1" >>confdefs.h
13696
13697fi
13698ac_fn_c_check_func "$LINENO" "splice" "ac_cv_func_splice"
13699if test "x$ac_cv_func_splice" = xyes
13700then :
13701 printf "%s\n" "#define HAVE_SPLICE 1" >>confdefs.h
13702
13703fi
13704ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
13705if test "x$ac_cv_func_strftime" = xyes
13706then :
13707 printf "%s\n" "#define HAVE_STRFTIME 1" >>confdefs.h
13708
13709fi
13710ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
13711if test "x$ac_cv_func_strlcpy" = xyes
13712then :
13713 printf "%s\n" "#define HAVE_STRLCPY 1" >>confdefs.h
13714
13715fi
13716ac_fn_c_check_func "$LINENO" "strsignal" "ac_cv_func_strsignal"
13717if test "x$ac_cv_func_strsignal" = xyes
13718then :
13719 printf "%s\n" "#define HAVE_STRSIGNAL 1" >>confdefs.h
13720
13721fi
13722ac_fn_c_check_func "$LINENO" "symlinkat" "ac_cv_func_symlinkat"
13723if test "x$ac_cv_func_symlinkat" = xyes
13724then :
13725 printf "%s\n" "#define HAVE_SYMLINKAT 1" >>confdefs.h
13726
13727fi
13728ac_fn_c_check_func "$LINENO" "sync" "ac_cv_func_sync"
13729if test "x$ac_cv_func_sync" = xyes
13730then :
13731 printf "%s\n" "#define HAVE_SYNC 1" >>confdefs.h
13732
13733fi
13734ac_fn_c_check_func "$LINENO" "sysconf" "ac_cv_func_sysconf"
13735if test "x$ac_cv_func_sysconf" = xyes
13736then :
13737 printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h
13738
13739fi
13740ac_fn_c_check_func "$LINENO" "tcgetpgrp" "ac_cv_func_tcgetpgrp"
13741if test "x$ac_cv_func_tcgetpgrp" = xyes
13742then :
13743 printf "%s\n" "#define HAVE_TCGETPGRP 1" >>confdefs.h
13744
13745fi
13746ac_fn_c_check_func "$LINENO" "tcsetpgrp" "ac_cv_func_tcsetpgrp"
13747if test "x$ac_cv_func_tcsetpgrp" = xyes
13748then :
13749 printf "%s\n" "#define HAVE_TCSETPGRP 1" >>confdefs.h
13750
13751fi
13752ac_fn_c_check_func "$LINENO" "tempnam" "ac_cv_func_tempnam"
13753if test "x$ac_cv_func_tempnam" = xyes
13754then :
13755 printf "%s\n" "#define HAVE_TEMPNAM 1" >>confdefs.h
13756
13757fi
13758ac_fn_c_check_func "$LINENO" "timegm" "ac_cv_func_timegm"
13759if test "x$ac_cv_func_timegm" = xyes
13760then :
13761 printf "%s\n" "#define HAVE_TIMEGM 1" >>confdefs.h
13762
13763fi
13764ac_fn_c_check_func "$LINENO" "times" "ac_cv_func_times"
13765if test "x$ac_cv_func_times" = xyes
13766then :
13767 printf "%s\n" "#define HAVE_TIMES 1" >>confdefs.h
13768
13769fi
13770ac_fn_c_check_func "$LINENO" "tmpfile" "ac_cv_func_tmpfile"
13771if test "x$ac_cv_func_tmpfile" = xyes
13772then :
13773 printf "%s\n" "#define HAVE_TMPFILE 1" >>confdefs.h
13774
13775fi
13776ac_fn_c_check_func "$LINENO" "tmpnam" "ac_cv_func_tmpnam"
13777if test "x$ac_cv_func_tmpnam" = xyes
13778then :
13779 printf "%s\n" "#define HAVE_TMPNAM 1" >>confdefs.h
13780
13781fi
13782ac_fn_c_check_func "$LINENO" "tmpnam_r" "ac_cv_func_tmpnam_r"
13783if test "x$ac_cv_func_tmpnam_r" = xyes
13784then :
13785 printf "%s\n" "#define HAVE_TMPNAM_R 1" >>confdefs.h
13786
13787fi
13788ac_fn_c_check_func "$LINENO" "truncate" "ac_cv_func_truncate"
13789if test "x$ac_cv_func_truncate" = xyes
13790then :
13791 printf "%s\n" "#define HAVE_TRUNCATE 1" >>confdefs.h
13792
13793fi
13794ac_fn_c_check_func "$LINENO" "uname" "ac_cv_func_uname"
13795if test "x$ac_cv_func_uname" = xyes
13796then :
13797 printf "%s\n" "#define HAVE_UNAME 1" >>confdefs.h
13798
13799fi
13800ac_fn_c_check_func "$LINENO" "unlinkat" "ac_cv_func_unlinkat"
13801if test "x$ac_cv_func_unlinkat" = xyes
13802then :
13803 printf "%s\n" "#define HAVE_UNLINKAT 1" >>confdefs.h
13804
13805fi
13806ac_fn_c_check_func "$LINENO" "utimensat" "ac_cv_func_utimensat"
13807if test "x$ac_cv_func_utimensat" = xyes
13808then :
13809 printf "%s\n" "#define HAVE_UTIMENSAT 1" >>confdefs.h
13810
13811fi
13812ac_fn_c_check_func "$LINENO" "utimes" "ac_cv_func_utimes"
13813if test "x$ac_cv_func_utimes" = xyes
13814then :
13815 printf "%s\n" "#define HAVE_UTIMES 1" >>confdefs.h
13816
13817fi
13818ac_fn_c_check_func "$LINENO" "vfork" "ac_cv_func_vfork"
13819if test "x$ac_cv_func_vfork" = xyes
13820then :
13821 printf "%s\n" "#define HAVE_VFORK 1" >>confdefs.h
13822
13823fi
13824ac_fn_c_check_func "$LINENO" "waitid" "ac_cv_func_waitid"
13825if test "x$ac_cv_func_waitid" = xyes
13826then :
13827 printf "%s\n" "#define HAVE_WAITID 1" >>confdefs.h
13828
13829fi
13830ac_fn_c_check_func "$LINENO" "waitpid" "ac_cv_func_waitpid"
13831if test "x$ac_cv_func_waitpid" = xyes
13832then :
13833 printf "%s\n" "#define HAVE_WAITPID 1" >>confdefs.h
13834
13835fi
13836ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3"
13837if test "x$ac_cv_func_wait3" = xyes
13838then :
13839 printf "%s\n" "#define HAVE_WAIT3 1" >>confdefs.h
13840
13841fi
13842ac_fn_c_check_func "$LINENO" "wait4" "ac_cv_func_wait4"
13843if test "x$ac_cv_func_wait4" = xyes
13844then :
13845 printf "%s\n" "#define HAVE_WAIT4 1" >>confdefs.h
13846
13847fi
13848ac_fn_c_check_func "$LINENO" "wcscoll" "ac_cv_func_wcscoll"
13849if test "x$ac_cv_func_wcscoll" = xyes
13850then :
13851 printf "%s\n" "#define HAVE_WCSCOLL 1" >>confdefs.h
13852
13853fi
13854ac_fn_c_check_func "$LINENO" "wcsftime" "ac_cv_func_wcsftime"
13855if test "x$ac_cv_func_wcsftime" = xyes
13856then :
13857 printf "%s\n" "#define HAVE_WCSFTIME 1" >>confdefs.h
13858
13859fi
13860ac_fn_c_check_func "$LINENO" "wcsxfrm" "ac_cv_func_wcsxfrm"
13861if test "x$ac_cv_func_wcsxfrm" = xyes
13862then :
13863 printf "%s\n" "#define HAVE_WCSXFRM 1" >>confdefs.h
13864
13865fi
13866ac_fn_c_check_func "$LINENO" "wmemcmp" "ac_cv_func_wmemcmp"
13867if test "x$ac_cv_func_wmemcmp" = xyes
13868then :
13869 printf "%s\n" "#define HAVE_WMEMCMP 1" >>confdefs.h
13870
13871fi
13872ac_fn_c_check_func "$LINENO" "writev" "ac_cv_func_writev"
13873if test "x$ac_cv_func_writev" = xyes
13874then :
13875 printf "%s\n" "#define HAVE_WRITEV 1" >>confdefs.h
13876
13877fi
13878ac_fn_c_check_func "$LINENO" "_getpty" "ac_cv_func__getpty"
13879if test "x$ac_cv_func__getpty" = xyes
13880then :
13881 printf "%s\n" "#define HAVE__GETPTY 1" >>confdefs.h
13882
13883fi
13884ac_fn_c_check_func "$LINENO" "rtpSpawn" "ac_cv_func_rtpSpawn"
13885if test "x$ac_cv_func_rtpSpawn" = xyes
13886then :
13887 printf "%s\n" "#define HAVE_RTPSPAWN 1" >>confdefs.h
13888
13889fi
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013890
Michael W. Hudson54241132001-12-07 15:38:26 +000013891
Benjamin Peterson40caa052018-09-12 15:52:40 -070013892# Force lchmod off for Linux. Linux disallows changing the mode of symbolic
13893# links. Some libc implementations have a stub lchmod implementation that always
13894# returns an error.
13895if test "$MACHDEP" != linux; then
13896 ac_fn_c_check_func "$LINENO" "lchmod" "ac_cv_func_lchmod"
Pablo Galindoba421752021-05-03 20:33:17 +010013897if test "x$ac_cv_func_lchmod" = xyes
13898then :
13899 printf "%s\n" "#define HAVE_LCHMOD 1" >>confdefs.h
13900
13901fi
13902
13903fi
13904
13905{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5
13906printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; }
13907if test ${ac_cv_c_undeclared_builtin_options+y}
13908then :
13909 printf %s "(cached) " >&6
13910else $as_nop
13911 ac_save_CFLAGS=$CFLAGS
13912 ac_cv_c_undeclared_builtin_options='cannot detect'
13913 for ac_arg in '' -fno-builtin; do
13914 CFLAGS="$ac_save_CFLAGS $ac_arg"
13915 # This test program should *not* compile successfully.
13916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13917/* end confdefs.h. */
13918
13919int
13920main (void)
13921{
13922(void) strchr;
13923 ;
13924 return 0;
13925}
Benjamin Petersoned709d52018-09-12 17:22:11 -070013926_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010013927if ac_fn_c_try_compile "$LINENO"
13928then :
13929
13930else $as_nop
13931 # This test program should compile successfully.
13932 # No library function is consistently available on
13933 # freestanding implementations, so test against a dummy
13934 # declaration. Include always-available headers on the
13935 # off chance that they somehow elicit warnings.
13936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13937/* end confdefs.h. */
13938#include <float.h>
13939#include <limits.h>
13940#include <stdarg.h>
13941#include <stddef.h>
13942extern void ac_decl (int, char *);
13943
13944int
13945main (void)
13946{
13947(void) ac_decl (0, (char *) 0);
13948 (void) ac_decl;
13949
13950 ;
13951 return 0;
13952}
13953_ACEOF
13954if ac_fn_c_try_compile "$LINENO"
13955then :
13956 if test x"$ac_arg" = x
13957then :
13958 ac_cv_c_undeclared_builtin_options='none needed'
13959else $as_nop
13960 ac_cv_c_undeclared_builtin_options=$ac_arg
13961fi
13962 break
13963fi
13964rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
13965fi
13966rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
13967 done
13968 CFLAGS=$ac_save_CFLAGS
Benjamin Peterson40caa052018-09-12 15:52:40 -070013969
13970fi
Pablo Galindoba421752021-05-03 20:33:17 +010013971{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5
13972printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; }
13973 case $ac_cv_c_undeclared_builtin_options in #(
13974 'cannot detect') :
13975 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13976printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
13977as_fn_error $? "cannot make $CC report undeclared builtins
13978See \`config.log' for more details" "$LINENO" 5; } ;; #(
13979 'none needed') :
13980 ac_c_undeclared_builtin_options='' ;; #(
13981 *) :
13982 ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;;
13983esac
Benjamin Peterson40caa052018-09-12 15:52:40 -070013984
Pablo Galindoba421752021-05-03 20:33:17 +010013985ac_fn_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h>
Gregory P. Smithdf300d52012-01-21 18:20:15 -080013986 #include <dirent.h>
Pablo Galindoba421752021-05-03 20:33:17 +010013987" "$ac_c_undeclared_builtin_options" "CFLAGS"
13988if test "x$ac_cv_have_decl_dirfd" = xyes
13989then :
Gregory P. Smithdf300d52012-01-21 18:20:15 -080013990
Pablo Galindoba421752021-05-03 20:33:17 +010013991printf "%s\n" "#define HAVE_DIRFD 1" >>confdefs.h
Gregory P. Smithdf300d52012-01-21 18:20:15 -080013992
13993fi
13994
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013995# For some functions, having a definition is not sufficient, since
13996# we want to take their address.
Pablo Galindoba421752021-05-03 20:33:17 +010013997{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5
13998printf %s "checking for chroot... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000013999cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014000/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014001#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014002int
Pablo Galindoba421752021-05-03 20:33:17 +010014003main (void)
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014004{
14005void *x=chroot
14006 ;
14007 return 0;
14008}
14009_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014010if ac_fn_c_try_compile "$LINENO"
14011then :
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014012
Pablo Galindoba421752021-05-03 20:33:17 +010014013printf "%s\n" "#define HAVE_CHROOT 1" >>confdefs.h
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014014
Pablo Galindoba421752021-05-03 20:33:17 +010014015 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14016printf "%s\n" "yes" >&6; }
14017else $as_nop
14018 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14019printf "%s\n" "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014020
14021fi
Pablo Galindoba421752021-05-03 20:33:17 +010014022rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14023{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for link" >&5
14024printf %s "checking for link... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014025cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014026/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014027#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014028int
Pablo Galindoba421752021-05-03 20:33:17 +010014029main (void)
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014030{
14031void *x=link
14032 ;
14033 return 0;
14034}
14035_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014036if ac_fn_c_try_compile "$LINENO"
14037then :
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014038
Pablo Galindoba421752021-05-03 20:33:17 +010014039printf "%s\n" "#define HAVE_LINK 1" >>confdefs.h
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014040
Pablo Galindoba421752021-05-03 20:33:17 +010014041 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14042printf "%s\n" "yes" >&6; }
14043else $as_nop
14044 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14045printf "%s\n" "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014046
14047fi
Pablo Galindoba421752021-05-03 20:33:17 +010014048rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14049{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5
14050printf %s "checking for symlink... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014051cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014052/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014053#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014054int
Pablo Galindoba421752021-05-03 20:33:17 +010014055main (void)
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014056{
14057void *x=symlink
14058 ;
14059 return 0;
14060}
14061_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014062if ac_fn_c_try_compile "$LINENO"
14063then :
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014064
Pablo Galindoba421752021-05-03 20:33:17 +010014065printf "%s\n" "#define HAVE_SYMLINK 1" >>confdefs.h
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014066
Pablo Galindoba421752021-05-03 20:33:17 +010014067 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14068printf "%s\n" "yes" >&6; }
14069else $as_nop
14070 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14071printf "%s\n" "no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014072
14073fi
Pablo Galindoba421752021-05-03 20:33:17 +010014074rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14075{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5
14076printf %s "checking for fchdir... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014077cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014078/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014079#include <unistd.h>
14080int
Pablo Galindoba421752021-05-03 20:33:17 +010014081main (void)
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014082{
14083void *x=fchdir
14084 ;
14085 return 0;
14086}
14087_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014088if ac_fn_c_try_compile "$LINENO"
14089then :
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014090
Pablo Galindoba421752021-05-03 20:33:17 +010014091printf "%s\n" "#define HAVE_FCHDIR 1" >>confdefs.h
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014092
Pablo Galindoba421752021-05-03 20:33:17 +010014093 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14094printf "%s\n" "yes" >&6; }
14095else $as_nop
14096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14097printf "%s\n" "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014098
14099fi
Pablo Galindoba421752021-05-03 20:33:17 +010014100rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14101{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5
14102printf %s "checking for fsync... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014103cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014104/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014105#include <unistd.h>
14106int
Pablo Galindoba421752021-05-03 20:33:17 +010014107main (void)
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014108{
14109void *x=fsync
14110 ;
14111 return 0;
14112}
14113_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014114if ac_fn_c_try_compile "$LINENO"
14115then :
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014116
Pablo Galindoba421752021-05-03 20:33:17 +010014117printf "%s\n" "#define HAVE_FSYNC 1" >>confdefs.h
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014118
Pablo Galindoba421752021-05-03 20:33:17 +010014119 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14120printf "%s\n" "yes" >&6; }
14121else $as_nop
14122 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14123printf "%s\n" "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014124
14125fi
Pablo Galindoba421752021-05-03 20:33:17 +010014126rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14127{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5
14128printf %s "checking for fdatasync... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014129cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014130/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014131#include <unistd.h>
14132int
Pablo Galindoba421752021-05-03 20:33:17 +010014133main (void)
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014134{
14135void *x=fdatasync
14136 ;
14137 return 0;
14138}
14139_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014140if ac_fn_c_try_compile "$LINENO"
14141then :
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014142
Pablo Galindoba421752021-05-03 20:33:17 +010014143printf "%s\n" "#define HAVE_FDATASYNC 1" >>confdefs.h
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014144
Pablo Galindoba421752021-05-03 20:33:17 +010014145 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14146printf "%s\n" "yes" >&6; }
14147else $as_nop
14148 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14149printf "%s\n" "no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000014150
14151fi
Pablo Galindoba421752021-05-03 20:33:17 +010014152rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5
14154printf %s "checking for epoll... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014155cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014156/* end confdefs.h. */
14157#include <sys/epoll.h>
14158int
Pablo Galindoba421752021-05-03 20:33:17 +010014159main (void)
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014160{
14161void *x=epoll_create
14162 ;
14163 return 0;
14164}
14165_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014166if ac_fn_c_try_compile "$LINENO"
14167then :
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000014168
Pablo Galindoba421752021-05-03 20:33:17 +010014169printf "%s\n" "#define HAVE_EPOLL 1" >>confdefs.h
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014170
Pablo Galindoba421752021-05-03 20:33:17 +010014171 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14172printf "%s\n" "yes" >&6; }
14173else $as_nop
14174 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14175printf "%s\n" "no" >&6; }
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014176
14177fi
Pablo Galindoba421752021-05-03 20:33:17 +010014178rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14179{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for epoll_create1" >&5
14180printf %s "checking for epoll_create1... " >&6; }
Benjamin Peterson95c16622011-12-27 15:36:32 -060014181cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14182/* end confdefs.h. */
14183#include <sys/epoll.h>
14184int
Pablo Galindoba421752021-05-03 20:33:17 +010014185main (void)
Benjamin Peterson95c16622011-12-27 15:36:32 -060014186{
14187void *x=epoll_create1
14188 ;
14189 return 0;
14190}
14191_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014192if ac_fn_c_try_compile "$LINENO"
14193then :
Benjamin Peterson95c16622011-12-27 15:36:32 -060014194
Pablo Galindoba421752021-05-03 20:33:17 +010014195printf "%s\n" "#define HAVE_EPOLL_CREATE1 1" >>confdefs.h
Benjamin Peterson95c16622011-12-27 15:36:32 -060014196
Pablo Galindoba421752021-05-03 20:33:17 +010014197 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14198printf "%s\n" "yes" >&6; }
14199else $as_nop
14200 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14201printf "%s\n" "no" >&6; }
Benjamin Peterson95c16622011-12-27 15:36:32 -060014202
14203fi
Pablo Galindoba421752021-05-03 20:33:17 +010014204rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14205{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5
14206printf %s "checking for kqueue... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014207cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014208/* end confdefs.h. */
14209
14210#include <sys/types.h>
14211#include <sys/event.h>
14212
14213int
Pablo Galindoba421752021-05-03 20:33:17 +010014214main (void)
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014215{
14216int x=kqueue()
14217 ;
14218 return 0;
14219}
14220_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014221if ac_fn_c_try_compile "$LINENO"
14222then :
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014223
Pablo Galindoba421752021-05-03 20:33:17 +010014224printf "%s\n" "#define HAVE_KQUEUE 1" >>confdefs.h
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014225
Pablo Galindoba421752021-05-03 20:33:17 +010014226 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14227printf "%s\n" "yes" >&6; }
14228else $as_nop
14229 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14230printf "%s\n" "no" >&6; }
Christian Heimes4fbc72b2008-03-22 00:47:35 +000014231
14232fi
Pablo Galindoba421752021-05-03 20:33:17 +010014233rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14234{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for prlimit" >&5
14235printf %s "checking for prlimit... " >&6; }
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014236cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14237/* end confdefs.h. */
14238
14239#include <sys/time.h>
14240#include <sys/resource.h>
14241
14242int
Pablo Galindoba421752021-05-03 20:33:17 +010014243main (void)
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014244{
14245void *x=prlimit
14246 ;
14247 return 0;
14248}
14249_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014250if ac_fn_c_try_compile "$LINENO"
14251then :
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014252
Pablo Galindoba421752021-05-03 20:33:17 +010014253printf "%s\n" "#define HAVE_PRLIMIT 1" >>confdefs.h
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014254
Pablo Galindoba421752021-05-03 20:33:17 +010014255 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14256printf "%s\n" "yes" >&6; }
14257else $as_nop
14258 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14259printf "%s\n" "no" >&6; }
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014260
14261fi
Pablo Galindoba421752021-05-03 20:33:17 +010014262rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14263{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _dyld_shared_cache_contains_path" >&5
14264printf %s "checking for _dyld_shared_cache_contains_path... " >&6; }
Ronald Oussoren41761932020-11-08 10:05:27 +010014265cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14266/* end confdefs.h. */
14267#include <mach-o/dyld.h>
14268int
Pablo Galindoba421752021-05-03 20:33:17 +010014269main (void)
Ronald Oussoren41761932020-11-08 10:05:27 +010014270{
14271void *x=_dyld_shared_cache_contains_path
14272 ;
14273 return 0;
14274}
14275_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014276if ac_fn_c_try_compile "$LINENO"
14277then :
Ronald Oussoren41761932020-11-08 10:05:27 +010014278
Pablo Galindoba421752021-05-03 20:33:17 +010014279printf "%s\n" "#define HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH 1" >>confdefs.h
Ronald Oussoren41761932020-11-08 10:05:27 +010014280
Pablo Galindoba421752021-05-03 20:33:17 +010014281 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14282printf "%s\n" "yes" >&6; }
14283else $as_nop
14284 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14285printf "%s\n" "no" >&6; }
Ronald Oussoren41761932020-11-08 10:05:27 +010014286
14287fi
Pablo Galindoba421752021-05-03 20:33:17 +010014288rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Christian Heimesb7bd5df2013-10-22 11:21:54 +020014289
Pablo Galindoba421752021-05-03 20:33:17 +010014290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for memfd_create" >&5
14291printf %s "checking for memfd_create... " >&6; }
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014292cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14293/* end confdefs.h. */
14294
14295#ifdef HAVE_SYS_MMAN_H
14296#include <sys/mman.h>
14297#endif
14298#ifdef HAVE_SYS_MEMFD_H
14299#include <sys/memfd.h>
14300#endif
14301
14302int
Pablo Galindoba421752021-05-03 20:33:17 +010014303main (void)
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014304{
14305void *x=memfd_create
14306 ;
14307 return 0;
14308}
14309_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014310if ac_fn_c_try_compile "$LINENO"
14311then :
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014312
Pablo Galindoba421752021-05-03 20:33:17 +010014313printf "%s\n" "#define HAVE_MEMFD_CREATE 1" >>confdefs.h
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014314
Pablo Galindoba421752021-05-03 20:33:17 +010014315 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14316printf "%s\n" "yes" >&6; }
14317else $as_nop
14318 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14319printf "%s\n" "no" >&6; }
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014320
14321fi
Pablo Galindoba421752021-05-03 20:33:17 +010014322rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Zackery Spytz43fdbd22019-05-29 13:57:07 -060014323
Pablo Galindoba421752021-05-03 20:33:17 +010014324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for eventfd" >&5
14325printf %s "checking for eventfd... " >&6; }
Christian Heimescd9fed62020-11-13 19:48:52 +010014326cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14327/* end confdefs.h. */
14328
14329#ifdef HAVE_SYS_EVENTFD_H
14330#include <sys/eventfd.h>
14331#endif
14332
14333int
Pablo Galindoba421752021-05-03 20:33:17 +010014334main (void)
Christian Heimescd9fed62020-11-13 19:48:52 +010014335{
14336int x = eventfd(0, EFD_CLOEXEC)
14337 ;
14338 return 0;
14339}
14340_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014341if ac_fn_c_try_compile "$LINENO"
14342then :
Christian Heimescd9fed62020-11-13 19:48:52 +010014343
Pablo Galindoba421752021-05-03 20:33:17 +010014344printf "%s\n" "#define HAVE_EVENTFD 1" >>confdefs.h
Christian Heimescd9fed62020-11-13 19:48:52 +010014345
Pablo Galindoba421752021-05-03 20:33:17 +010014346 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14347printf "%s\n" "yes" >&6; }
14348else $as_nop
14349 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14350printf "%s\n" "no" >&6; }
Christian Heimescd9fed62020-11-13 19:48:52 +010014351
14352fi
Pablo Galindoba421752021-05-03 20:33:17 +010014353rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Christian Heimescd9fed62020-11-13 19:48:52 +010014354
Martin v. Löwisd5843682002-11-21 20:41:28 +000014355# On some systems (eg. FreeBSD 5), we would find a definition of the
14356# functions ctermid_r, setgroups in the library, but no prototype
14357# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
14358# address to avoid compiler warnings and potential miscompilations
14359# because of the missing prototypes.
14360
Pablo Galindoba421752021-05-03 20:33:17 +010014361{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5
14362printf %s "checking for ctermid_r... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014363cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014364/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000014365
Martin v. Löwisd5843682002-11-21 20:41:28 +000014366#include <stdio.h>
14367
Martin v. Löwisd5843682002-11-21 20:41:28 +000014368int
Pablo Galindoba421752021-05-03 20:33:17 +010014369main (void)
Martin v. Löwisd5843682002-11-21 20:41:28 +000014370{
14371void* p = ctermid_r
14372 ;
14373 return 0;
14374}
14375_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014376if ac_fn_c_try_compile "$LINENO"
14377then :
Martin v. Löwisd5843682002-11-21 20:41:28 +000014378
Pablo Galindoba421752021-05-03 20:33:17 +010014379printf "%s\n" "#define HAVE_CTERMID_R 1" >>confdefs.h
Martin v. Löwisd5843682002-11-21 20:41:28 +000014380
Pablo Galindoba421752021-05-03 20:33:17 +010014381 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14382printf "%s\n" "yes" >&6; }
14383else $as_nop
14384 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14385printf "%s\n" "no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000014386
14387fi
Pablo Galindoba421752021-05-03 20:33:17 +010014388rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014389
Pablo Galindoba421752021-05-03 20:33:17 +010014390{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5
14391printf %s "checking for flock declaration... " >&6; }
14392if test ${ac_cv_flock_decl+y}
14393then :
14394 printf %s "(cached) " >&6
14395else $as_nop
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014397/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014398#include <sys/file.h>
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014399int
Pablo Galindoba421752021-05-03 20:33:17 +010014400main (void)
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014401{
14402void* p = flock
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014403
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014404 ;
14405 return 0;
14406}
14407_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014408if ac_fn_c_try_compile "$LINENO"
14409then :
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014410 ac_cv_flock_decl=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014411else $as_nop
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014412 ac_cv_flock_decl=no
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014413
14414fi
Pablo Galindoba421752021-05-03 20:33:17 +010014415rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Antoine Pitroua3000072010-09-07 14:52:42 +000014416
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014417fi
Pablo Galindoba421752021-05-03 20:33:17 +010014418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5
14419printf "%s\n" "$ac_cv_flock_decl" >&6; }
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014420if test "x${ac_cv_flock_decl}" = xyes; then
Pablo Galindoba421752021-05-03 20:33:17 +010014421
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014422 for ac_func in flock
14423do :
14424 ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock"
Pablo Galindoba421752021-05-03 20:33:17 +010014425if test "x$ac_cv_func_flock" = xyes
14426then :
14427 printf "%s\n" "#define HAVE_FLOCK 1" >>confdefs.h
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014428
Pablo Galindoba421752021-05-03 20:33:17 +010014429else $as_nop
14430 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for flock in -lbsd" >&5
14431printf %s "checking for flock in -lbsd... " >&6; }
14432if test ${ac_cv_lib_bsd_flock+y}
14433then :
14434 printf %s "(cached) " >&6
14435else $as_nop
Antoine Pitroua3000072010-09-07 14:52:42 +000014436 ac_check_lib_save_LIBS=$LIBS
14437LIBS="-lbsd $LIBS"
14438cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14439/* end confdefs.h. */
14440
14441/* Override any GCC internal prototype to avoid an error.
14442 Use char because int might match the return type of a GCC
14443 builtin and then its argument prototype would still apply. */
Antoine Pitroua3000072010-09-07 14:52:42 +000014444char flock ();
14445int
Pablo Galindoba421752021-05-03 20:33:17 +010014446main (void)
Antoine Pitroua3000072010-09-07 14:52:42 +000014447{
14448return flock ();
14449 ;
14450 return 0;
14451}
14452_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014453if ac_fn_c_try_link "$LINENO"
14454then :
Antoine Pitroua3000072010-09-07 14:52:42 +000014455 ac_cv_lib_bsd_flock=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014456else $as_nop
Antoine Pitroua3000072010-09-07 14:52:42 +000014457 ac_cv_lib_bsd_flock=no
14458fi
Pablo Galindoba421752021-05-03 20:33:17 +010014459rm -f core conftest.err conftest.$ac_objext conftest.beam \
Antoine Pitroua3000072010-09-07 14:52:42 +000014460 conftest$ac_exeext conftest.$ac_ext
14461LIBS=$ac_check_lib_save_LIBS
14462fi
Pablo Galindoba421752021-05-03 20:33:17 +010014463{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5
14464printf "%s\n" "$ac_cv_lib_bsd_flock" >&6; }
14465if test "x$ac_cv_lib_bsd_flock" = xyes
14466then :
14467 printf "%s\n" "#define HAVE_FLOCK 1" >>confdefs.h
Antoine Pitroua3000072010-09-07 14:52:42 +000014468
14469
Pablo Galindoba421752021-05-03 20:33:17 +010014470printf "%s\n" "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h
Antoine Pitroua3000072010-09-07 14:52:42 +000014471
14472
14473fi
14474
14475
14476fi
Pablo Galindoba421752021-05-03 20:33:17 +010014477
Antoine Pitroua4e4ae22010-09-10 18:39:00 +000014478done
Antoine Pitroua3000072010-09-07 14:52:42 +000014479fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014480
Pablo Galindoba421752021-05-03 20:33:17 +010014481{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5
14482printf %s "checking for getpagesize... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014483cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014484/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014485
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014486#include <unistd.h>
14487
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014488int
Pablo Galindoba421752021-05-03 20:33:17 +010014489main (void)
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014490{
14491void* p = getpagesize
14492 ;
14493 return 0;
14494}
14495_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014496if ac_fn_c_try_compile "$LINENO"
14497then :
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014498
Pablo Galindoba421752021-05-03 20:33:17 +010014499printf "%s\n" "#define HAVE_GETPAGESIZE 1" >>confdefs.h
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014500
Pablo Galindoba421752021-05-03 20:33:17 +010014501 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14502printf "%s\n" "yes" >&6; }
14503else $as_nop
14504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14505printf "%s\n" "no" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014506
14507fi
Pablo Galindoba421752021-05-03 20:33:17 +010014508rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000014509
Pablo Galindoba421752021-05-03 20:33:17 +010014510{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken unsetenv" >&5
14511printf %s "checking for broken unsetenv... " >&6; }
Victor Stinner984890f2011-11-24 13:53:38 +010014512cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14513/* end confdefs.h. */
14514
14515#include <stdlib.h>
14516
14517int
Pablo Galindoba421752021-05-03 20:33:17 +010014518main (void)
Victor Stinner984890f2011-11-24 13:53:38 +010014519{
14520int res = unsetenv("DUMMY")
14521 ;
14522 return 0;
14523}
14524_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014525if ac_fn_c_try_compile "$LINENO"
14526then :
14527 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14528printf "%s\n" "no" >&6; }
14529else $as_nop
Victor Stinner984890f2011-11-24 13:53:38 +010014530
Pablo Galindoba421752021-05-03 20:33:17 +010014531printf "%s\n" "#define HAVE_BROKEN_UNSETENV 1" >>confdefs.h
Victor Stinner984890f2011-11-24 13:53:38 +010014532
Pablo Galindoba421752021-05-03 20:33:17 +010014533 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14534printf "%s\n" "yes" >&6; }
Victor Stinner984890f2011-11-24 13:53:38 +010014535
14536fi
Pablo Galindoba421752021-05-03 20:33:17 +010014537rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Victor Stinner984890f2011-11-24 13:53:38 +010014538
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014539for ac_prog in true
14540do
14541 # Extract the first word of "$ac_prog", so it can be a program name with args.
14542set dummy $ac_prog; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010014543{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14544printf %s "checking for $ac_word... " >&6; }
14545if test ${ac_cv_prog_TRUE+y}
14546then :
14547 printf %s "(cached) " >&6
14548else $as_nop
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014549 if test -n "$TRUE"; then
14550 ac_cv_prog_TRUE="$TRUE" # Let the user override the test.
14551else
14552as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14553for as_dir in $PATH
14554do
14555 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010014556 case $as_dir in #(((
14557 '') as_dir=./ ;;
14558 */) ;;
14559 *) as_dir=$as_dir/ ;;
14560 esac
Matthias Kloseb9621712010-04-24 17:59:49 +000014561 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010014562 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014563 ac_cv_prog_TRUE="$ac_prog"
Pablo Galindoba421752021-05-03 20:33:17 +010014564 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014565 break 2
14566 fi
14567done
Matthias Kloseb9621712010-04-24 17:59:49 +000014568 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014569IFS=$as_save_IFS
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014570
14571fi
14572fi
14573TRUE=$ac_cv_prog_TRUE
14574if test -n "$TRUE"; then
Pablo Galindoba421752021-05-03 20:33:17 +010014575 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5
14576printf "%s\n" "$TRUE" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014577else
Pablo Galindoba421752021-05-03 20:33:17 +010014578 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14579printf "%s\n" "no" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014580fi
14581
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014582
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014583 test -n "$TRUE" && break
14584done
14585test -n "$TRUE" || TRUE="/bin/true"
14586
14587
Pablo Galindoba421752021-05-03 20:33:17 +010014588{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5
14589printf %s "checking for inet_aton in -lc... " >&6; }
14590if test ${ac_cv_lib_c_inet_aton+y}
14591then :
14592 printf %s "(cached) " >&6
14593else $as_nop
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014594 ac_check_lib_save_LIBS=$LIBS
14595LIBS="-lc $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000014596cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014597/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014598
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014599/* Override any GCC internal prototype to avoid an error.
14600 Use char because int might match the return type of a GCC
14601 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014602char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014603int
Pablo Galindoba421752021-05-03 20:33:17 +010014604main (void)
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014605{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014606return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014607 ;
14608 return 0;
14609}
14610_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014611if ac_fn_c_try_link "$LINENO"
14612then :
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014613 ac_cv_lib_c_inet_aton=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014614else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014615 ac_cv_lib_c_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014616fi
Pablo Galindoba421752021-05-03 20:33:17 +010014617rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000014618 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014619LIBS=$ac_check_lib_save_LIBS
14620fi
Pablo Galindoba421752021-05-03 20:33:17 +010014621{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5
14622printf "%s\n" "$ac_cv_lib_c_inet_aton" >&6; }
14623if test "x$ac_cv_lib_c_inet_aton" = xyes
14624then :
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014625 $ac_cv_prog_TRUE
Pablo Galindoba421752021-05-03 20:33:17 +010014626else $as_nop
14627 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5
14628printf %s "checking for inet_aton in -lresolv... " >&6; }
14629if test ${ac_cv_lib_resolv_inet_aton+y}
14630then :
14631 printf %s "(cached) " >&6
14632else $as_nop
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014633 ac_check_lib_save_LIBS=$LIBS
14634LIBS="-lresolv $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000014635cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014636/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014637
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014638/* Override any GCC internal prototype to avoid an error.
14639 Use char because int might match the return type of a GCC
14640 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014641char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014642int
Pablo Galindoba421752021-05-03 20:33:17 +010014643main (void)
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014644{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014645return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014646 ;
14647 return 0;
14648}
14649_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014650if ac_fn_c_try_link "$LINENO"
14651then :
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014652 ac_cv_lib_resolv_inet_aton=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014653else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014654 ac_cv_lib_resolv_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014655fi
Pablo Galindoba421752021-05-03 20:33:17 +010014656rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000014657 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014658LIBS=$ac_check_lib_save_LIBS
14659fi
Pablo Galindoba421752021-05-03 20:33:17 +010014660{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5
14661printf "%s\n" "$ac_cv_lib_resolv_inet_aton" >&6; }
14662if test "x$ac_cv_lib_resolv_inet_aton" = xyes
14663then :
14664 printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014665
14666 LIBS="-lresolv $LIBS"
14667
14668fi
14669
14670
14671fi
14672
14673
Christian Heimesd0764e22007-12-04 15:00:33 +000014674# On Tru64, chflags seems to be present, but calling it will
14675# exit Python
Pablo Galindoba421752021-05-03 20:33:17 +010014676{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5
14677printf %s "checking for chflags... " >&6; }
14678if test ${ac_cv_have_chflags+y}
14679then :
14680 printf %s "(cached) " >&6
14681else $as_nop
14682 if test "$cross_compiling" = yes
14683then :
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014684 ac_cv_have_chflags=cross
Pablo Galindoba421752021-05-03 20:33:17 +010014685else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Christian Heimesd0764e22007-12-04 15:00:33 +000014687/* end confdefs.h. */
Ned Deily3eb67d52011-06-28 00:00:28 -070014688
Christian Heimesd0764e22007-12-04 15:00:33 +000014689#include <sys/stat.h>
14690#include <unistd.h>
14691int main(int argc, char*argv[])
14692{
14693 if(chflags(argv[0], 0) != 0)
14694 return 1;
14695 return 0;
14696}
Ned Deily3eb67d52011-06-28 00:00:28 -070014697
Christian Heimesd0764e22007-12-04 15:00:33 +000014698_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014699if ac_fn_c_try_run "$LINENO"
14700then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014701 ac_cv_have_chflags=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014702else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014703 ac_cv_have_chflags=no
Alexandre Vassalotti19142282009-07-17 23:11:52 +000014704fi
Matthias Kloseb9621712010-04-24 17:59:49 +000014705rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14706 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +000014707fi
14708
Alexandre Vassalotti19142282009-07-17 23:11:52 +000014709
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014710fi
Pablo Galindoba421752021-05-03 20:33:17 +010014711{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5
14712printf "%s\n" "$ac_cv_have_chflags" >&6; }
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014713if test "$ac_cv_have_chflags" = cross ; then
Matthias Kloseb9621712010-04-24 17:59:49 +000014714 ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags"
Pablo Galindoba421752021-05-03 20:33:17 +010014715if test "x$ac_cv_func_chflags" = xyes
14716then :
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014717 ac_cv_have_chflags="yes"
Pablo Galindoba421752021-05-03 20:33:17 +010014718else $as_nop
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014719 ac_cv_have_chflags="no"
14720fi
14721
14722fi
14723if test "$ac_cv_have_chflags" = yes ; then
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014724
Pablo Galindoba421752021-05-03 20:33:17 +010014725printf "%s\n" "#define HAVE_CHFLAGS 1" >>confdefs.h
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014726
14727fi
14728
Pablo Galindoba421752021-05-03 20:33:17 +010014729{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5
14730printf %s "checking for lchflags... " >&6; }
14731if test ${ac_cv_have_lchflags+y}
14732then :
14733 printf %s "(cached) " >&6
14734else $as_nop
14735 if test "$cross_compiling" = yes
14736then :
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014737 ac_cv_have_lchflags=cross
Pablo Galindoba421752021-05-03 20:33:17 +010014738else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Christian Heimesd0764e22007-12-04 15:00:33 +000014740/* end confdefs.h. */
Ned Deily3eb67d52011-06-28 00:00:28 -070014741
Christian Heimesd0764e22007-12-04 15:00:33 +000014742#include <sys/stat.h>
14743#include <unistd.h>
14744int main(int argc, char*argv[])
14745{
14746 if(lchflags(argv[0], 0) != 0)
14747 return 1;
14748 return 0;
14749}
Ned Deily3eb67d52011-06-28 00:00:28 -070014750
Christian Heimesd0764e22007-12-04 15:00:33 +000014751_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014752if ac_fn_c_try_run "$LINENO"
14753then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014754 ac_cv_have_lchflags=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014755else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014756 ac_cv_have_lchflags=no
Christian Heimesd0764e22007-12-04 15:00:33 +000014757fi
Matthias Kloseb9621712010-04-24 17:59:49 +000014758rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14759 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti19142282009-07-17 23:11:52 +000014760fi
14761
14762
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014763fi
Pablo Galindoba421752021-05-03 20:33:17 +010014764{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5
14765printf "%s\n" "$ac_cv_have_lchflags" >&6; }
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014766if test "$ac_cv_have_lchflags" = cross ; then
Matthias Kloseb9621712010-04-24 17:59:49 +000014767 ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags"
Pablo Galindoba421752021-05-03 20:33:17 +010014768if test "x$ac_cv_func_lchflags" = xyes
14769then :
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014770 ac_cv_have_lchflags="yes"
Pablo Galindoba421752021-05-03 20:33:17 +010014771else $as_nop
Benjamin Petersoned68afa2010-01-30 19:36:43 +000014772 ac_cv_have_lchflags="no"
14773fi
14774
14775fi
14776if test "$ac_cv_have_lchflags" = yes ; then
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014777
Pablo Galindoba421752021-05-03 20:33:17 +010014778printf "%s\n" "#define HAVE_LCHFLAGS 1" >>confdefs.h
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000014779
14780fi
14781
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014782case $ac_sys_system/$ac_sys_release in
14783Darwin/*)
14784 _CUR_CFLAGS="${CFLAGS}"
14785 _CUR_LDFLAGS="${LDFLAGS}"
14786 CFLAGS="${CFLAGS} -Wl,-search_paths_first"
14787 LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib"
14788 ;;
14789esac
14790
Pablo Galindoba421752021-05-03 20:33:17 +010014791{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5
14792printf %s "checking for inflateCopy in -lz... " >&6; }
14793if test ${ac_cv_lib_z_inflateCopy+y}
14794then :
14795 printf %s "(cached) " >&6
14796else $as_nop
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014797 ac_check_lib_save_LIBS=$LIBS
14798LIBS="-lz $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000014799cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014800/* end confdefs.h. */
14801
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014802/* Override any GCC internal prototype to avoid an error.
14803 Use char because int might match the return type of a GCC
14804 builtin and then its argument prototype would still apply. */
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014805char inflateCopy ();
14806int
Pablo Galindoba421752021-05-03 20:33:17 +010014807main (void)
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014808{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014809return inflateCopy ();
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014810 ;
14811 return 0;
14812}
14813_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014814if ac_fn_c_try_link "$LINENO"
14815then :
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014816 ac_cv_lib_z_inflateCopy=yes
Pablo Galindoba421752021-05-03 20:33:17 +010014817else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000014818 ac_cv_lib_z_inflateCopy=no
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014819fi
Pablo Galindoba421752021-05-03 20:33:17 +010014820rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000014821 conftest$ac_exeext conftest.$ac_ext
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014822LIBS=$ac_check_lib_save_LIBS
14823fi
Pablo Galindoba421752021-05-03 20:33:17 +010014824{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5
14825printf "%s\n" "$ac_cv_lib_z_inflateCopy" >&6; }
14826if test "x$ac_cv_lib_z_inflateCopy" = xyes
14827then :
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014828
Pablo Galindoba421752021-05-03 20:33:17 +010014829printf "%s\n" "#define HAVE_ZLIB_COPY 1" >>confdefs.h
Thomas Wouters0e3f5912006-08-11 14:57:12 +000014830
14831fi
14832
14833
14834case $ac_sys_system/$ac_sys_release in
14835Darwin/*)
14836 CFLAGS="${_CUR_CFLAGS}"
14837 LDFLAGS="${_CUR_LDFLAGS}"
14838 ;;
14839esac
14840
Pablo Galindoba421752021-05-03 20:33:17 +010014841{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5
14842printf %s "checking for hstrerror... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014843cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014844/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000014845
Martin v. Löwise9416172003-05-03 10:12:45 +000014846#include <netdb.h>
14847
Martin v. Löwise9416172003-05-03 10:12:45 +000014848int
Pablo Galindoba421752021-05-03 20:33:17 +010014849main (void)
Martin v. Löwise9416172003-05-03 10:12:45 +000014850{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014851void* p = hstrerror; hstrerror(0)
Martin v. Löwise9416172003-05-03 10:12:45 +000014852 ;
14853 return 0;
14854}
14855_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014856if ac_fn_c_try_link "$LINENO"
14857then :
Martin v. Löwise9416172003-05-03 10:12:45 +000014858
Pablo Galindoba421752021-05-03 20:33:17 +010014859printf "%s\n" "#define HAVE_HSTRERROR 1" >>confdefs.h
Martin v. Löwise9416172003-05-03 10:12:45 +000014860
Pablo Galindoba421752021-05-03 20:33:17 +010014861 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14862printf "%s\n" "yes" >&6; }
14863else $as_nop
14864 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14865printf "%s\n" "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000014866
14867fi
Pablo Galindoba421752021-05-03 20:33:17 +010014868rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000014869 conftest$ac_exeext conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014870
Pablo Galindoba421752021-05-03 20:33:17 +010014871{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5
14872printf %s "checking for inet_aton... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014873cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014874/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000014875
Martin v. Löwis86d66262006-02-17 08:40:11 +000014876#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000014877#include <sys/socket.h>
14878#include <netinet/in.h>
14879#include <arpa/inet.h>
14880
Martin v. Löwise9416172003-05-03 10:12:45 +000014881int
Pablo Galindoba421752021-05-03 20:33:17 +010014882main (void)
Martin v. Löwise9416172003-05-03 10:12:45 +000014883{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000014884void* p = inet_aton;inet_aton(0,0)
Martin v. Löwise9416172003-05-03 10:12:45 +000014885 ;
14886 return 0;
14887}
14888_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014889if ac_fn_c_try_link "$LINENO"
14890then :
Martin v. Löwise9416172003-05-03 10:12:45 +000014891
Pablo Galindoba421752021-05-03 20:33:17 +010014892printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
Martin v. Löwise9416172003-05-03 10:12:45 +000014893
Pablo Galindoba421752021-05-03 20:33:17 +010014894 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14895printf "%s\n" "yes" >&6; }
14896else $as_nop
14897 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14898printf "%s\n" "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000014899
14900fi
Pablo Galindoba421752021-05-03 20:33:17 +010014901rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000014902 conftest$ac_exeext conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014903
Pablo Galindoba421752021-05-03 20:33:17 +010014904{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5
14905printf %s "checking for inet_pton... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014906cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014907/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000014908
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000014909#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000014910#include <sys/socket.h>
14911#include <netinet/in.h>
14912#include <arpa/inet.h>
14913
Martin v. Löwise9416172003-05-03 10:12:45 +000014914int
Pablo Galindoba421752021-05-03 20:33:17 +010014915main (void)
Martin v. Löwise9416172003-05-03 10:12:45 +000014916{
14917void* p = inet_pton
14918 ;
14919 return 0;
14920}
14921_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014922if ac_fn_c_try_compile "$LINENO"
14923then :
Martin v. Löwise9416172003-05-03 10:12:45 +000014924
Pablo Galindoba421752021-05-03 20:33:17 +010014925printf "%s\n" "#define HAVE_INET_PTON 1" >>confdefs.h
Martin v. Löwise9416172003-05-03 10:12:45 +000014926
Pablo Galindoba421752021-05-03 20:33:17 +010014927 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14928printf "%s\n" "yes" >&6; }
14929else $as_nop
14930 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14931printf "%s\n" "no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000014932
14933fi
Pablo Galindoba421752021-05-03 20:33:17 +010014934rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000014935
Martin v. Löwisd6640d42003-07-06 09:29:52 +000014936# On some systems, setgroups is in unistd.h, on others, in grp.h
Pablo Galindoba421752021-05-03 20:33:17 +010014937{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5
14938printf %s "checking for setgroups... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000014939cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014940/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000014941
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000014942#include <unistd.h>
Martin v. Löwisd6640d42003-07-06 09:29:52 +000014943#ifdef HAVE_GRP_H
14944#include <grp.h>
14945#endif
Martin v. Löwisd5843682002-11-21 20:41:28 +000014946
Martin v. Löwisd5843682002-11-21 20:41:28 +000014947int
Pablo Galindoba421752021-05-03 20:33:17 +010014948main (void)
Martin v. Löwisd5843682002-11-21 20:41:28 +000014949{
14950void* p = setgroups
14951 ;
14952 return 0;
14953}
14954_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010014955if ac_fn_c_try_compile "$LINENO"
14956then :
Martin v. Löwisd5843682002-11-21 20:41:28 +000014957
Pablo Galindoba421752021-05-03 20:33:17 +010014958printf "%s\n" "#define HAVE_SETGROUPS 1" >>confdefs.h
Martin v. Löwisd5843682002-11-21 20:41:28 +000014959
Pablo Galindoba421752021-05-03 20:33:17 +010014960 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14961printf "%s\n" "yes" >&6; }
14962else $as_nop
14963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14964printf "%s\n" "no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000014965
14966fi
Pablo Galindoba421752021-05-03 20:33:17 +010014967rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwisd5843682002-11-21 20:41:28 +000014968
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000014969# check for openpty and forkpty
14970
Pablo Galindoba421752021-05-03 20:33:17 +010014971
14972 for ac_func in openpty
Matthias Kloseb9621712010-04-24 17:59:49 +000014973do :
14974 ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty"
Pablo Galindoba421752021-05-03 20:33:17 +010014975if test "x$ac_cv_func_openpty" = xyes
14976then :
14977 printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000014978
Pablo Galindoba421752021-05-03 20:33:17 +010014979else $as_nop
14980 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5
14981printf %s "checking for openpty in -lutil... " >&6; }
14982if test ${ac_cv_lib_util_openpty+y}
14983then :
14984 printf %s "(cached) " >&6
14985else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000014986 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000014987LIBS="-lutil $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000014988cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000014989/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014990
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014991/* Override any GCC internal prototype to avoid an error.
14992 Use char because int might match the return type of a GCC
14993 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014994char openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014995int
Pablo Galindoba421752021-05-03 20:33:17 +010014996main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000014997{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000014998return openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014999 ;
15000 return 0;
15001}
15002_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015003if ac_fn_c_try_link "$LINENO"
15004then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015005 ac_cv_lib_util_openpty=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015006else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015007 ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000015008fi
Pablo Galindoba421752021-05-03 20:33:17 +010015009rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015010 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015011LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000015012fi
Pablo Galindoba421752021-05-03 20:33:17 +010015013{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5
15014printf "%s\n" "$ac_cv_lib_util_openpty" >&6; }
15015if test "x$ac_cv_lib_util_openpty" = xyes
15016then :
15017 printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
Fred Drake8cef4cf2000-06-28 16:40:38 +000015018 LIBS="$LIBS -lutil"
Pablo Galindoba421752021-05-03 20:33:17 +010015019else $as_nop
15020 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5
15021printf %s "checking for openpty in -lbsd... " >&6; }
15022if test ${ac_cv_lib_bsd_openpty+y}
15023then :
15024 printf %s "(cached) " >&6
15025else $as_nop
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015026 ac_check_lib_save_LIBS=$LIBS
15027LIBS="-lbsd $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000015028cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015029/* end confdefs.h. */
15030
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015031/* Override any GCC internal prototype to avoid an error.
15032 Use char because int might match the return type of a GCC
15033 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015034char openpty ();
15035int
Pablo Galindoba421752021-05-03 20:33:17 +010015036main (void)
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015037{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015038return openpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015039 ;
15040 return 0;
15041}
15042_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015043if ac_fn_c_try_link "$LINENO"
15044then :
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015045 ac_cv_lib_bsd_openpty=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015046else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015047 ac_cv_lib_bsd_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000015048fi
Pablo Galindoba421752021-05-03 20:33:17 +010015049rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015050 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015051LIBS=$ac_check_lib_save_LIBS
15052fi
Pablo Galindoba421752021-05-03 20:33:17 +010015053{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5
15054printf "%s\n" "$ac_cv_lib_bsd_openpty" >&6; }
15055if test "x$ac_cv_lib_bsd_openpty" = xyes
15056then :
15057 printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015058 LIBS="$LIBS -lbsd"
15059fi
15060
15061
15062fi
15063
Fred Drake8cef4cf2000-06-28 16:40:38 +000015064
15065fi
Pablo Galindoba421752021-05-03 20:33:17 +010015066
Fred Drake8cef4cf2000-06-28 16:40:38 +000015067done
15068
Pablo Galindoba421752021-05-03 20:33:17 +010015069 for ac_func in forkpty
Matthias Kloseb9621712010-04-24 17:59:49 +000015070do :
15071 ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty"
Pablo Galindoba421752021-05-03 20:33:17 +010015072if test "x$ac_cv_func_forkpty" = xyes
15073then :
15074 printf "%s\n" "#define HAVE_FORKPTY 1" >>confdefs.h
Fred Drake8cef4cf2000-06-28 16:40:38 +000015075
Pablo Galindoba421752021-05-03 20:33:17 +010015076else $as_nop
15077 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5
15078printf %s "checking for forkpty in -lutil... " >&6; }
15079if test ${ac_cv_lib_util_forkpty+y}
15080then :
15081 printf %s "(cached) " >&6
15082else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000015083 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000015084LIBS="-lutil $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000015085cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015086/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015087
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015088/* Override any GCC internal prototype to avoid an error.
15089 Use char because int might match the return type of a GCC
15090 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015091char forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015092int
Pablo Galindoba421752021-05-03 20:33:17 +010015093main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000015094{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015095return forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015096 ;
15097 return 0;
15098}
15099_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015100if ac_fn_c_try_link "$LINENO"
15101then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015102 ac_cv_lib_util_forkpty=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015103else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015104 ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000015105fi
Pablo Galindoba421752021-05-03 20:33:17 +010015106rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015107 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015108LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000015109fi
Pablo Galindoba421752021-05-03 20:33:17 +010015110{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5
15111printf "%s\n" "$ac_cv_lib_util_forkpty" >&6; }
15112if test "x$ac_cv_lib_util_forkpty" = xyes
15113then :
15114 printf "%s\n" "#define HAVE_FORKPTY 1" >>confdefs.h
Fred Drake8cef4cf2000-06-28 16:40:38 +000015115 LIBS="$LIBS -lutil"
Pablo Galindoba421752021-05-03 20:33:17 +010015116else $as_nop
15117 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5
15118printf %s "checking for forkpty in -lbsd... " >&6; }
15119if test ${ac_cv_lib_bsd_forkpty+y}
15120then :
15121 printf %s "(cached) " >&6
15122else $as_nop
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015123 ac_check_lib_save_LIBS=$LIBS
15124LIBS="-lbsd $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000015125cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015126/* end confdefs.h. */
15127
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015128/* Override any GCC internal prototype to avoid an error.
15129 Use char because int might match the return type of a GCC
15130 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015131char forkpty ();
15132int
Pablo Galindoba421752021-05-03 20:33:17 +010015133main (void)
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015134{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015135return forkpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015136 ;
15137 return 0;
15138}
15139_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015140if ac_fn_c_try_link "$LINENO"
15141then :
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015142 ac_cv_lib_bsd_forkpty=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015143else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015144 ac_cv_lib_bsd_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000015145fi
Pablo Galindoba421752021-05-03 20:33:17 +010015146rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015147 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015148LIBS=$ac_check_lib_save_LIBS
15149fi
Pablo Galindoba421752021-05-03 20:33:17 +010015150{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5
15151printf "%s\n" "$ac_cv_lib_bsd_forkpty" >&6; }
15152if test "x$ac_cv_lib_bsd_forkpty" = xyes
15153then :
15154 printf "%s\n" "#define HAVE_FORKPTY 1" >>confdefs.h
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000015155 LIBS="$LIBS -lbsd"
15156fi
15157
15158
15159fi
15160
Fred Drake8cef4cf2000-06-28 16:40:38 +000015161
15162fi
Christian Heimes32eba612021-03-19 10:29:25 +010015163
Pablo Galindoba421752021-05-03 20:33:17 +010015164done
Christian Heimes39258d32021-04-17 11:36:35 +020015165
Michael W. Hudson54241132001-12-07 15:38:26 +000015166# check for long file support functions
Pablo Galindoba421752021-05-03 20:33:17 +010015167ac_fn_c_check_func "$LINENO" "fseek64" "ac_cv_func_fseek64"
15168if test "x$ac_cv_func_fseek64" = xyes
15169then :
15170 printf "%s\n" "#define HAVE_FSEEK64 1" >>confdefs.h
Michael W. Hudson54241132001-12-07 15:38:26 +000015171
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015172fi
Pablo Galindoba421752021-05-03 20:33:17 +010015173ac_fn_c_check_func "$LINENO" "fseeko" "ac_cv_func_fseeko"
15174if test "x$ac_cv_func_fseeko" = xyes
15175then :
15176 printf "%s\n" "#define HAVE_FSEEKO 1" >>confdefs.h
15177
15178fi
15179ac_fn_c_check_func "$LINENO" "fstatvfs" "ac_cv_func_fstatvfs"
15180if test "x$ac_cv_func_fstatvfs" = xyes
15181then :
15182 printf "%s\n" "#define HAVE_FSTATVFS 1" >>confdefs.h
15183
15184fi
15185ac_fn_c_check_func "$LINENO" "ftell64" "ac_cv_func_ftell64"
15186if test "x$ac_cv_func_ftell64" = xyes
15187then :
15188 printf "%s\n" "#define HAVE_FTELL64 1" >>confdefs.h
15189
15190fi
15191ac_fn_c_check_func "$LINENO" "ftello" "ac_cv_func_ftello"
15192if test "x$ac_cv_func_ftello" = xyes
15193then :
15194 printf "%s\n" "#define HAVE_FTELLO 1" >>confdefs.h
15195
15196fi
15197ac_fn_c_check_func "$LINENO" "statvfs" "ac_cv_func_statvfs"
15198if test "x$ac_cv_func_statvfs" = xyes
15199then :
15200 printf "%s\n" "#define HAVE_STATVFS 1" >>confdefs.h
15201
15202fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000015203
Michael W. Hudson54241132001-12-07 15:38:26 +000015204
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020015205ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2"
Pablo Galindoba421752021-05-03 20:33:17 +010015206if test "x$ac_cv_func_dup2" = xyes
15207then :
15208 printf "%s\n" "#define HAVE_DUP2 1" >>confdefs.h
Martin v. Löwis1142de32002-03-29 16:28:31 +000015209
Pablo Galindoba421752021-05-03 20:33:17 +010015210else $as_nop
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015211 case " $LIBOBJS " in
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020015212 *" dup2.$ac_objext "* ) ;;
15213 *) LIBOBJS="$LIBOBJS dup2.$ac_objext"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015214 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015215esac
15216
Martin v. Löwis1142de32002-03-29 16:28:31 +000015217fi
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020015218
Martin v. Löwis1142de32002-03-29 16:28:31 +000015219
Pablo Galindoba421752021-05-03 20:33:17 +010015220 for ac_func in getpgrp
Matthias Kloseb9621712010-04-24 17:59:49 +000015221do :
15222 ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp"
Pablo Galindoba421752021-05-03 20:33:17 +010015223if test "x$ac_cv_func_getpgrp" = xyes
15224then :
15225 printf "%s\n" "#define HAVE_GETPGRP 1" >>confdefs.h
Matthias Kloseb9621712010-04-24 17:59:49 +000015226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015227/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015228#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015229int
Pablo Galindoba421752021-05-03 20:33:17 +010015230main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000015231{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015232getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000015233 ;
15234 return 0;
15235}
15236_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015237if ac_fn_c_try_compile "$LINENO"
15238then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015239
Pablo Galindoba421752021-05-03 20:33:17 +010015240printf "%s\n" "#define GETPGRP_HAVE_ARG 1" >>confdefs.h
Skip Montanaro6dead952003-09-25 14:50:04 +000015241
Guido van Rossum627b2d71993-12-24 10:39:16 +000015242fi
Pablo Galindoba421752021-05-03 20:33:17 +010015243rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015244
Guido van Rossum627b2d71993-12-24 10:39:16 +000015245fi
Pablo Galindoba421752021-05-03 20:33:17 +010015246
Thomas Wouters3a584202000-08-05 23:28:51 +000015247done
Guido van Rossum627b2d71993-12-24 10:39:16 +000015248
Pablo Galindoba421752021-05-03 20:33:17 +010015249 for ac_func in setpgrp
Matthias Kloseb9621712010-04-24 17:59:49 +000015250do :
15251 ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp"
Pablo Galindoba421752021-05-03 20:33:17 +010015252if test "x$ac_cv_func_setpgrp" = xyes
15253then :
15254 printf "%s\n" "#define HAVE_SETPGRP 1" >>confdefs.h
Matthias Kloseb9621712010-04-24 17:59:49 +000015255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015256/* end confdefs.h. */
Jack Jansen150753c2003-03-29 22:07:47 +000015257#include <unistd.h>
Jack Jansen150753c2003-03-29 22:07:47 +000015258int
Pablo Galindoba421752021-05-03 20:33:17 +010015259main (void)
Jack Jansen150753c2003-03-29 22:07:47 +000015260{
15261setpgrp(0,0);
15262 ;
15263 return 0;
15264}
15265_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015266if ac_fn_c_try_compile "$LINENO"
15267then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015268
Pablo Galindoba421752021-05-03 20:33:17 +010015269printf "%s\n" "#define SETPGRP_HAVE_ARG 1" >>confdefs.h
Skip Montanaro6dead952003-09-25 14:50:04 +000015270
Guido van Rossum8eee56f1994-10-20 22:18:37 +000015271fi
Pablo Galindoba421752021-05-03 20:33:17 +010015272rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Jack Jansen150753c2003-03-29 22:07:47 +000015273
15274fi
Pablo Galindoba421752021-05-03 20:33:17 +010015275
Jack Jansen150753c2003-03-29 22:07:47 +000015276done
Guido van Rossum8eee56f1994-10-20 22:18:37 +000015277
Gregory P. Smith387512c2018-12-30 15:42:32 -080015278# We search for both crypt and crypt_r as one or the other may be defined
15279# This gets us our -lcrypt in LIBS when required on the target platform.
Pablo Galindoba421752021-05-03 20:33:17 +010015280{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing crypt" >&5
15281printf %s "checking for library containing crypt... " >&6; }
15282if test ${ac_cv_search_crypt+y}
15283then :
15284 printf %s "(cached) " >&6
15285else $as_nop
Gregory P. Smith387512c2018-12-30 15:42:32 -080015286 ac_func_search_save_LIBS=$LIBS
15287cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15288/* end confdefs.h. */
15289
15290/* Override any GCC internal prototype to avoid an error.
15291 Use char because int might match the return type of a GCC
15292 builtin and then its argument prototype would still apply. */
Gregory P. Smith387512c2018-12-30 15:42:32 -080015293char crypt ();
15294int
Pablo Galindoba421752021-05-03 20:33:17 +010015295main (void)
Gregory P. Smith387512c2018-12-30 15:42:32 -080015296{
15297return crypt ();
15298 ;
15299 return 0;
15300}
15301_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015302for ac_lib in '' crypt
15303do
Gregory P. Smith387512c2018-12-30 15:42:32 -080015304 if test -z "$ac_lib"; then
15305 ac_res="none required"
15306 else
15307 ac_res=-l$ac_lib
15308 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15309 fi
Pablo Galindoba421752021-05-03 20:33:17 +010015310 if ac_fn_c_try_link "$LINENO"
15311then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015312 ac_cv_search_crypt=$ac_res
15313fi
Pablo Galindoba421752021-05-03 20:33:17 +010015314rm -f core conftest.err conftest.$ac_objext conftest.beam \
Gregory P. Smith387512c2018-12-30 15:42:32 -080015315 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +010015316 if test ${ac_cv_search_crypt+y}
15317then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015318 break
15319fi
15320done
Pablo Galindoba421752021-05-03 20:33:17 +010015321if test ${ac_cv_search_crypt+y}
15322then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015323
Pablo Galindoba421752021-05-03 20:33:17 +010015324else $as_nop
Gregory P. Smith387512c2018-12-30 15:42:32 -080015325 ac_cv_search_crypt=no
15326fi
15327rm conftest.$ac_ext
15328LIBS=$ac_func_search_save_LIBS
15329fi
Pablo Galindoba421752021-05-03 20:33:17 +010015330{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt" >&5
15331printf "%s\n" "$ac_cv_search_crypt" >&6; }
Gregory P. Smith387512c2018-12-30 15:42:32 -080015332ac_res=$ac_cv_search_crypt
Pablo Galindoba421752021-05-03 20:33:17 +010015333if test "$ac_res" != no
15334then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015335 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15336
15337fi
15338
Pablo Galindoba421752021-05-03 20:33:17 +010015339{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing crypt_r" >&5
15340printf %s "checking for library containing crypt_r... " >&6; }
15341if test ${ac_cv_search_crypt_r+y}
15342then :
15343 printf %s "(cached) " >&6
15344else $as_nop
Gregory P. Smith387512c2018-12-30 15:42:32 -080015345 ac_func_search_save_LIBS=$LIBS
15346cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15347/* end confdefs.h. */
15348
15349/* Override any GCC internal prototype to avoid an error.
15350 Use char because int might match the return type of a GCC
15351 builtin and then its argument prototype would still apply. */
Gregory P. Smith387512c2018-12-30 15:42:32 -080015352char crypt_r ();
15353int
Pablo Galindoba421752021-05-03 20:33:17 +010015354main (void)
Gregory P. Smith387512c2018-12-30 15:42:32 -080015355{
15356return crypt_r ();
15357 ;
15358 return 0;
15359}
15360_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015361for ac_lib in '' crypt
15362do
Gregory P. Smith387512c2018-12-30 15:42:32 -080015363 if test -z "$ac_lib"; then
15364 ac_res="none required"
15365 else
15366 ac_res=-l$ac_lib
15367 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
15368 fi
Pablo Galindoba421752021-05-03 20:33:17 +010015369 if ac_fn_c_try_link "$LINENO"
15370then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015371 ac_cv_search_crypt_r=$ac_res
15372fi
Pablo Galindoba421752021-05-03 20:33:17 +010015373rm -f core conftest.err conftest.$ac_objext conftest.beam \
Gregory P. Smith387512c2018-12-30 15:42:32 -080015374 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +010015375 if test ${ac_cv_search_crypt_r+y}
15376then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015377 break
15378fi
15379done
Pablo Galindoba421752021-05-03 20:33:17 +010015380if test ${ac_cv_search_crypt_r+y}
15381then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015382
Pablo Galindoba421752021-05-03 20:33:17 +010015383else $as_nop
Gregory P. Smith387512c2018-12-30 15:42:32 -080015384 ac_cv_search_crypt_r=no
15385fi
15386rm conftest.$ac_ext
15387LIBS=$ac_func_search_save_LIBS
15388fi
Pablo Galindoba421752021-05-03 20:33:17 +010015389{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt_r" >&5
15390printf "%s\n" "$ac_cv_search_crypt_r" >&6; }
Gregory P. Smith387512c2018-12-30 15:42:32 -080015391ac_res=$ac_cv_search_crypt_r
Pablo Galindoba421752021-05-03 20:33:17 +010015392if test "$ac_res" != no
15393then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015394 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15395
15396fi
15397
15398
15399ac_fn_c_check_func "$LINENO" "crypt_r" "ac_cv_func_crypt_r"
Pablo Galindoba421752021-05-03 20:33:17 +010015400if test "x$ac_cv_func_crypt_r" = xyes
15401then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15403/* end confdefs.h. */
15404
15405#define _GNU_SOURCE /* Required for crypt_r()'s prototype in glibc. */
15406#include <crypt.h>
15407
15408int
Pablo Galindoba421752021-05-03 20:33:17 +010015409main (void)
Gregory P. Smith387512c2018-12-30 15:42:32 -080015410{
15411
15412struct crypt_data d;
15413char *r = crypt_r("", "", &d);
15414
15415 ;
15416 return 0;
15417}
15418_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015419if ac_fn_c_try_compile "$LINENO"
15420then :
Gregory P. Smith387512c2018-12-30 15:42:32 -080015421
Pablo Galindoba421752021-05-03 20:33:17 +010015422printf "%s\n" "#define HAVE_CRYPT_R 1" >>confdefs.h
Gregory P. Smith387512c2018-12-30 15:42:32 -080015423
15424fi
Pablo Galindoba421752021-05-03 20:33:17 +010015425rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Gregory P. Smith387512c2018-12-30 15:42:32 -080015426
15427fi
15428
15429
Pablo Galindoba421752021-05-03 20:33:17 +010015430
15431 for ac_func in clock_gettime
Victor Stinnere0be4232011-10-25 13:06:09 +020015432do :
15433 ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime"
Pablo Galindoba421752021-05-03 20:33:17 +010015434if test "x$ac_cv_func_clock_gettime" = xyes
15435then :
15436 printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
Victor Stinnere0be4232011-10-25 13:06:09 +020015437
Pablo Galindoba421752021-05-03 20:33:17 +010015438else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015439
Pablo Galindoba421752021-05-03 20:33:17 +010015440 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5
15441printf %s "checking for clock_gettime in -lrt... " >&6; }
15442if test ${ac_cv_lib_rt_clock_gettime+y}
15443then :
15444 printf %s "(cached) " >&6
15445else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015446 ac_check_lib_save_LIBS=$LIBS
15447LIBS="-lrt $LIBS"
15448cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15449/* end confdefs.h. */
15450
15451/* Override any GCC internal prototype to avoid an error.
15452 Use char because int might match the return type of a GCC
15453 builtin and then its argument prototype would still apply. */
Victor Stinnere0be4232011-10-25 13:06:09 +020015454char clock_gettime ();
15455int
Pablo Galindoba421752021-05-03 20:33:17 +010015456main (void)
Victor Stinnere0be4232011-10-25 13:06:09 +020015457{
15458return clock_gettime ();
15459 ;
15460 return 0;
15461}
15462_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015463if ac_fn_c_try_link "$LINENO"
15464then :
Victor Stinnere0be4232011-10-25 13:06:09 +020015465 ac_cv_lib_rt_clock_gettime=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015466else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015467 ac_cv_lib_rt_clock_gettime=no
15468fi
Pablo Galindoba421752021-05-03 20:33:17 +010015469rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinnere0be4232011-10-25 13:06:09 +020015470 conftest$ac_exeext conftest.$ac_ext
15471LIBS=$ac_check_lib_save_LIBS
15472fi
Pablo Galindoba421752021-05-03 20:33:17 +010015473{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5
15474printf "%s\n" "$ac_cv_lib_rt_clock_gettime" >&6; }
15475if test "x$ac_cv_lib_rt_clock_gettime" = xyes
15476then :
Victor Stinnere0be4232011-10-25 13:06:09 +020015477
Victor Stinner7efb8332014-08-29 15:41:08 +020015478 LIBS="$LIBS -lrt"
Pablo Galindoba421752021-05-03 20:33:17 +010015479 printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
Victor Stinnere0be4232011-10-25 13:06:09 +020015480
15481
Pablo Galindoba421752021-05-03 20:33:17 +010015482printf "%s\n" "#define TIMEMODULE_LIB rt" >>confdefs.h
Victor Stinnere0be4232011-10-25 13:06:09 +020015483
15484
15485fi
15486
15487
15488fi
Pablo Galindoba421752021-05-03 20:33:17 +010015489
Victor Stinnere0be4232011-10-25 13:06:09 +020015490done
15491
15492
Pablo Galindoba421752021-05-03 20:33:17 +010015493 for ac_func in clock_getres
Victor Stinnere0be4232011-10-25 13:06:09 +020015494do :
15495 ac_fn_c_check_func "$LINENO" "clock_getres" "ac_cv_func_clock_getres"
Pablo Galindoba421752021-05-03 20:33:17 +010015496if test "x$ac_cv_func_clock_getres" = xyes
15497then :
15498 printf "%s\n" "#define HAVE_CLOCK_GETRES 1" >>confdefs.h
Victor Stinnere0be4232011-10-25 13:06:09 +020015499
Pablo Galindoba421752021-05-03 20:33:17 +010015500else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015501
Pablo Galindoba421752021-05-03 20:33:17 +010015502 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_getres in -lrt" >&5
15503printf %s "checking for clock_getres in -lrt... " >&6; }
15504if test ${ac_cv_lib_rt_clock_getres+y}
15505then :
15506 printf %s "(cached) " >&6
15507else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015508 ac_check_lib_save_LIBS=$LIBS
15509LIBS="-lrt $LIBS"
15510cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15511/* end confdefs.h. */
15512
15513/* Override any GCC internal prototype to avoid an error.
15514 Use char because int might match the return type of a GCC
15515 builtin and then its argument prototype would still apply. */
Victor Stinnere0be4232011-10-25 13:06:09 +020015516char clock_getres ();
15517int
Pablo Galindoba421752021-05-03 20:33:17 +010015518main (void)
Victor Stinnere0be4232011-10-25 13:06:09 +020015519{
15520return clock_getres ();
15521 ;
15522 return 0;
15523}
15524_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015525if ac_fn_c_try_link "$LINENO"
15526then :
Victor Stinnere0be4232011-10-25 13:06:09 +020015527 ac_cv_lib_rt_clock_getres=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015528else $as_nop
Victor Stinnere0be4232011-10-25 13:06:09 +020015529 ac_cv_lib_rt_clock_getres=no
15530fi
Pablo Galindoba421752021-05-03 20:33:17 +010015531rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinnere0be4232011-10-25 13:06:09 +020015532 conftest$ac_exeext conftest.$ac_ext
15533LIBS=$ac_check_lib_save_LIBS
15534fi
Pablo Galindoba421752021-05-03 20:33:17 +010015535{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_getres" >&5
15536printf "%s\n" "$ac_cv_lib_rt_clock_getres" >&6; }
15537if test "x$ac_cv_lib_rt_clock_getres" = xyes
15538then :
Victor Stinnere0be4232011-10-25 13:06:09 +020015539
Pablo Galindoba421752021-05-03 20:33:17 +010015540 printf "%s\n" "#define HAVE_CLOCK_GETRES 1" >>confdefs.h
Victor Stinnere0be4232011-10-25 13:06:09 +020015541
15542
15543fi
15544
15545
15546fi
Pablo Galindoba421752021-05-03 20:33:17 +010015547
Victor Stinnere0be4232011-10-25 13:06:09 +020015548done
15549
15550
Pablo Galindoba421752021-05-03 20:33:17 +010015551 for ac_func in clock_settime
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015552do :
15553 ac_fn_c_check_func "$LINENO" "clock_settime" "ac_cv_func_clock_settime"
Pablo Galindoba421752021-05-03 20:33:17 +010015554if test "x$ac_cv_func_clock_settime" = xyes
15555then :
15556 printf "%s\n" "#define HAVE_CLOCK_SETTIME 1" >>confdefs.h
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015557
Pablo Galindoba421752021-05-03 20:33:17 +010015558else $as_nop
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015559
Pablo Galindoba421752021-05-03 20:33:17 +010015560 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_settime in -lrt" >&5
15561printf %s "checking for clock_settime in -lrt... " >&6; }
15562if test ${ac_cv_lib_rt_clock_settime+y}
15563then :
15564 printf %s "(cached) " >&6
15565else $as_nop
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015566 ac_check_lib_save_LIBS=$LIBS
15567LIBS="-lrt $LIBS"
15568cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15569/* end confdefs.h. */
15570
15571/* Override any GCC internal prototype to avoid an error.
15572 Use char because int might match the return type of a GCC
15573 builtin and then its argument prototype would still apply. */
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015574char clock_settime ();
15575int
Pablo Galindoba421752021-05-03 20:33:17 +010015576main (void)
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015577{
15578return clock_settime ();
15579 ;
15580 return 0;
15581}
15582_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015583if ac_fn_c_try_link "$LINENO"
15584then :
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015585 ac_cv_lib_rt_clock_settime=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015586else $as_nop
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015587 ac_cv_lib_rt_clock_settime=no
15588fi
Pablo Galindoba421752021-05-03 20:33:17 +010015589rm -f core conftest.err conftest.$ac_objext conftest.beam \
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015590 conftest$ac_exeext conftest.$ac_ext
15591LIBS=$ac_check_lib_save_LIBS
15592fi
Pablo Galindoba421752021-05-03 20:33:17 +010015593{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_settime" >&5
15594printf "%s\n" "$ac_cv_lib_rt_clock_settime" >&6; }
15595if test "x$ac_cv_lib_rt_clock_settime" = xyes
15596then :
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015597
Pablo Galindoba421752021-05-03 20:33:17 +010015598 printf "%s\n" "#define HAVE_CLOCK_SETTIME 1" >>confdefs.h
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015599
15600
15601fi
15602
15603
15604fi
Pablo Galindoba421752021-05-03 20:33:17 +010015605
Benjamin Peterson37098cd2016-09-13 22:55:09 -070015606done
15607
Pablo Galindoba421752021-05-03 20:33:17 +010015608{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for major" >&5
15609printf %s "checking for major... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000015610cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015611/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015612
Neal Norwitz6eb37f02003-02-23 23:28:15 +000015613#if defined(MAJOR_IN_MKDEV)
15614#include <sys/mkdev.h>
15615#elif defined(MAJOR_IN_SYSMACROS)
15616#include <sys/sysmacros.h>
15617#else
15618#include <sys/types.h>
15619#endif
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015620
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015621int
Pablo Galindoba421752021-05-03 20:33:17 +010015622main (void)
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015623{
15624
15625 makedev(major(0),minor(0));
15626
15627 ;
15628 return 0;
15629}
15630_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015631if ac_fn_c_try_link "$LINENO"
15632then :
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015633
15634
Pablo Galindoba421752021-05-03 20:33:17 +010015635printf "%s\n" "#define HAVE_DEVICE_MACROS 1" >>confdefs.h
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015636
Pablo Galindoba421752021-05-03 20:33:17 +010015637 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15638printf "%s\n" "yes" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015639
Pablo Galindoba421752021-05-03 20:33:17 +010015640else $as_nop
Skip Montanaro6dead952003-09-25 14:50:04 +000015641
Pablo Galindoba421752021-05-03 20:33:17 +010015642 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
15643printf "%s\n" "no" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000015644
15645fi
Pablo Galindoba421752021-05-03 20:33:17 +010015646rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015647 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015648
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015649# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000015650# for [no]getaddrinfo in netdb.h.
Pablo Galindoba421752021-05-03 20:33:17 +010015651{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
15652printf %s "checking for getaddrinfo... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000015653cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015654/* end confdefs.h. */
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015655
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000015656#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015657#include <sys/socket.h>
15658#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000015659#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015660
Martin v. Löwis11437992002-04-12 09:54:03 +000015661int
Pablo Galindoba421752021-05-03 20:33:17 +010015662main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000015663{
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015664getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis11437992002-04-12 09:54:03 +000015665 ;
15666 return 0;
15667}
15668_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015669if ac_fn_c_try_link "$LINENO"
15670then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015671 have_getaddrinfo=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015672else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015673 have_getaddrinfo=no
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015674fi
Pablo Galindoba421752021-05-03 20:33:17 +010015675rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015676 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010015677{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5
15678printf "%s\n" "$have_getaddrinfo" >&6; }
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015679if test $have_getaddrinfo = yes
15680then
Pablo Galindoba421752021-05-03 20:33:17 +010015681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5
15682printf %s "checking getaddrinfo bug... " >&6; }
15683 if test ${ac_cv_buggy_getaddrinfo+y}
15684then :
15685 printf %s "(cached) " >&6
15686else $as_nop
15687 if test "$cross_compiling" = yes
15688then :
Matthias Klose96350132012-03-15 20:42:23 +010015689
15690if test "${enable_ipv6+set}" = set; then
15691 ac_cv_buggy_getaddrinfo="no -- configured with --(en|dis)able-ipv6"
15692else
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015693 ac_cv_buggy_getaddrinfo=yes
Matthias Klose96350132012-03-15 20:42:23 +010015694fi
Pablo Galindoba421752021-05-03 20:33:17 +010015695else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015697/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015698
Stefan Krah19c21392012-11-22 23:47:32 +010015699#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015700#include <sys/types.h>
15701#include <netdb.h>
15702#include <string.h>
15703#include <sys/socket.h>
15704#include <netinet/in.h>
15705
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015706int main()
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015707{
15708 int passive, gaierr, inet4 = 0, inet6 = 0;
15709 struct addrinfo hints, *ai, *aitop;
15710 char straddr[INET6_ADDRSTRLEN], strport[16];
15711
15712 for (passive = 0; passive <= 1; passive++) {
15713 memset(&hints, 0, sizeof(hints));
15714 hints.ai_family = AF_UNSPEC;
15715 hints.ai_flags = passive ? AI_PASSIVE : 0;
15716 hints.ai_socktype = SOCK_STREAM;
Hye-Shik Chang54f94392004-04-14 07:55:31 +000015717 hints.ai_protocol = IPPROTO_TCP;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015718 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
15719 (void)gai_strerror(gaierr);
15720 goto bad;
15721 }
15722 for (ai = aitop; ai; ai = ai->ai_next) {
15723 if (ai->ai_addr == NULL ||
15724 ai->ai_addrlen == 0 ||
15725 getnameinfo(ai->ai_addr, ai->ai_addrlen,
15726 straddr, sizeof(straddr), strport, sizeof(strport),
15727 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
15728 goto bad;
15729 }
15730 switch (ai->ai_family) {
15731 case AF_INET:
15732 if (strcmp(strport, "54321") != 0) {
15733 goto bad;
15734 }
15735 if (passive) {
15736 if (strcmp(straddr, "0.0.0.0") != 0) {
15737 goto bad;
15738 }
15739 } else {
15740 if (strcmp(straddr, "127.0.0.1") != 0) {
15741 goto bad;
15742 }
15743 }
15744 inet4++;
15745 break;
15746 case AF_INET6:
15747 if (strcmp(strport, "54321") != 0) {
15748 goto bad;
15749 }
15750 if (passive) {
15751 if (strcmp(straddr, "::") != 0) {
15752 goto bad;
15753 }
15754 } else {
15755 if (strcmp(straddr, "::1") != 0) {
15756 goto bad;
15757 }
15758 }
15759 inet6++;
15760 break;
15761 case AF_UNSPEC:
15762 goto bad;
15763 break;
15764 default:
15765 /* another family support? */
15766 break;
15767 }
15768 }
Benjamin Peterson01c340d2016-09-06 15:54:24 -070015769 freeaddrinfo(aitop);
15770 aitop = NULL;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015771 }
15772
15773 if (!(inet4 == 0 || inet4 == 2))
15774 goto bad;
15775 if (!(inet6 == 0 || inet6 == 2))
15776 goto bad;
15777
15778 if (aitop)
15779 freeaddrinfo(aitop);
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015780 return 0;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015781
15782 bad:
15783 if (aitop)
15784 freeaddrinfo(aitop);
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015785 return 1;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015786}
15787
Martin v. Löwis11437992002-04-12 09:54:03 +000015788_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015789if ac_fn_c_try_run "$LINENO"
15790then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015791 ac_cv_buggy_getaddrinfo=no
Pablo Galindoba421752021-05-03 20:33:17 +010015792else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015793 ac_cv_buggy_getaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015794fi
Matthias Kloseb9621712010-04-24 17:59:49 +000015795rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15796 conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015797fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015798
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015799fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015800
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015801fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015802
Pablo Galindoba421752021-05-03 20:33:17 +010015803{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5
15804printf "%s\n" "$ac_cv_buggy_getaddrinfo" >&6; }
Benjamin Petersond4694ed2010-11-01 01:44:30 +000015805
doko@ubuntu.com9c7817e2012-06-30 17:05:13 +020015806if test $have_getaddrinfo = no || test "$ac_cv_buggy_getaddrinfo" = yes
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000015807then
15808 if test $ipv6 = yes
15809 then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015810 echo 'Fatal: You must get working getaddrinfo() function.'
15811 echo ' or you can specify "--disable-ipv6"'.
15812 exit 1
15813 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015814else
Martin v. Löwis11437992002-04-12 09:54:03 +000015815
Pablo Galindoba421752021-05-03 20:33:17 +010015816printf "%s\n" "#define HAVE_GETADDRINFO 1" >>confdefs.h
Martin v. Löwis861a65b2001-10-24 14:36:00 +000015817
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015818fi
Benjamin Petersond4694ed2010-11-01 01:44:30 +000015819
Pablo Galindoba421752021-05-03 20:33:17 +010015820ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo"
15821if test "x$ac_cv_func_getnameinfo" = xyes
15822then :
15823 printf "%s\n" "#define HAVE_GETNAMEINFO 1" >>confdefs.h
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015824
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015825fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015826
Michael W. Hudson54241132001-12-07 15:38:26 +000015827
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015828# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000015829
Martin v. Löwis11437992002-04-12 09:54:03 +000015830
Pablo Galindoba421752021-05-03 20:33:17 +010015831# Obsolete code to be removed.
15832if test $ac_cv_header_sys_time_h = yes; then
15833
15834printf "%s\n" "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015835
15836fi
Pablo Galindoba421752021-05-03 20:33:17 +010015837# End of obsolete code.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015838
Pablo Galindoba421752021-05-03 20:33:17 +010015839{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
15840printf %s "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15841if test ${ac_cv_struct_tm+y}
15842then :
15843 printf %s "(cached) " >&6
15844else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015846/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015847#include <sys/types.h>
15848#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015849
Martin v. Löwis11437992002-04-12 09:54:03 +000015850int
Pablo Galindoba421752021-05-03 20:33:17 +010015851main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000015852{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015853struct tm tm;
15854 int *p = &tm.tm_sec;
Matthias Kloseb9621712010-04-24 17:59:49 +000015855 return !p;
Martin v. Löwis11437992002-04-12 09:54:03 +000015856 ;
15857 return 0;
15858}
15859_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015860if ac_fn_c_try_compile "$LINENO"
15861then :
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015862 ac_cv_struct_tm=time.h
Pablo Galindoba421752021-05-03 20:33:17 +010015863else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015864 ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015865fi
Pablo Galindoba421752021-05-03 20:33:17 +010015866rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015867fi
Pablo Galindoba421752021-05-03 20:33:17 +010015868{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
15869printf "%s\n" "$ac_cv_struct_tm" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000015870if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015871
Pablo Galindoba421752021-05-03 20:33:17 +010015872printf "%s\n" "#define TM_IN_SYS_TIME 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015873
15874fi
15875
Matthias Kloseb9621712010-04-24 17:59:49 +000015876ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015877#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000015878
Matthias Kloseb9621712010-04-24 17:59:49 +000015879"
Pablo Galindoba421752021-05-03 20:33:17 +010015880if test "x$ac_cv_member_struct_tm_tm_zone" = xyes
15881then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015882
Pablo Galindoba421752021-05-03 20:33:17 +010015883printf "%s\n" "#define HAVE_STRUCT_TM_TM_ZONE 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015884
15885
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015886fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015887
Martin v. Löwis11437992002-04-12 09:54:03 +000015888if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15889
Pablo Galindoba421752021-05-03 20:33:17 +010015890printf "%s\n" "#define HAVE_TM_ZONE 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015891
15892else
Pablo Galindoba421752021-05-03 20:33:17 +010015893 ac_fn_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
15894" "$ac_c_undeclared_builtin_options" "CFLAGS"
15895if test "x$ac_cv_have_decl_tzname" = xyes
15896then :
Matthias Kloseb9621712010-04-24 17:59:49 +000015897 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010015898else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015899 ac_have_decl=0
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015900fi
Pablo Galindoba421752021-05-03 20:33:17 +010015901printf "%s\n" "#define HAVE_DECL_TZNAME $ac_have_decl" >>confdefs.h
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015902
Pablo Galindoba421752021-05-03 20:33:17 +010015903 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
15904printf %s "checking for tzname... " >&6; }
15905if test ${ac_cv_var_tzname+y}
15906then :
15907 printf %s "(cached) " >&6
15908else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000015910/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000015911#include <time.h>
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015912#if !HAVE_DECL_TZNAME
15913extern char *tzname[];
Guido van Rossum627b2d71993-12-24 10:39:16 +000015914#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015915
Martin v. Löwis11437992002-04-12 09:54:03 +000015916int
Pablo Galindoba421752021-05-03 20:33:17 +010015917main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000015918{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000015919return tzname[0][0];
Martin v. Löwis11437992002-04-12 09:54:03 +000015920 ;
15921 return 0;
15922}
15923_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010015924if ac_fn_c_try_link "$LINENO"
15925then :
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015926 ac_cv_var_tzname=yes
Pablo Galindoba421752021-05-03 20:33:17 +010015927else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000015928 ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015929fi
Pablo Galindoba421752021-05-03 20:33:17 +010015930rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000015931 conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000015932fi
Pablo Galindoba421752021-05-03 20:33:17 +010015933{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
15934printf "%s\n" "$ac_cv_var_tzname" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000015935 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015936
Pablo Galindoba421752021-05-03 20:33:17 +010015937printf "%s\n" "#define HAVE_TZNAME 1" >>confdefs.h
Guido van Rossum627b2d71993-12-24 10:39:16 +000015938
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015939 fi
15940fi
15941
Matthias Kloseb9621712010-04-24 17:59:49 +000015942ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015943if test "x$ac_cv_member_struct_stat_st_rdev" = xyes
15944then :
Martin v. Löwis11437992002-04-12 09:54:03 +000015945
Pablo Galindoba421752021-05-03 20:33:17 +010015946printf "%s\n" "#define HAVE_STRUCT_STAT_ST_RDEV 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015947
15948
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015949fi
15950
Matthias Kloseb9621712010-04-24 17:59:49 +000015951ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015952if test "x$ac_cv_member_struct_stat_st_blksize" = xyes
15953then :
Jack Jansendd19cf82001-12-06 22:36:17 +000015954
Pablo Galindoba421752021-05-03 20:33:17 +010015955printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLKSIZE 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015956
15957
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015958fi
15959
Matthias Kloseb9621712010-04-24 17:59:49 +000015960ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015961if test "x$ac_cv_member_struct_stat_st_flags" = xyes
15962then :
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000015963
Pablo Galindoba421752021-05-03 20:33:17 +010015964printf "%s\n" "#define HAVE_STRUCT_STAT_ST_FLAGS 1" >>confdefs.h
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000015965
15966
15967fi
15968
Matthias Kloseb9621712010-04-24 17:59:49 +000015969ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015970if test "x$ac_cv_member_struct_stat_st_gen" = xyes
15971then :
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000015972
Pablo Galindoba421752021-05-03 20:33:17 +010015973printf "%s\n" "#define HAVE_STRUCT_STAT_ST_GEN 1" >>confdefs.h
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000015974
15975
15976fi
15977
Matthias Kloseb9621712010-04-24 17:59:49 +000015978ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015979if test "x$ac_cv_member_struct_stat_st_birthtime" = xyes
15980then :
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000015981
Pablo Galindoba421752021-05-03 20:33:17 +010015982printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BIRTHTIME 1" >>confdefs.h
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000015983
15984
15985fi
15986
Matthias Kloseb9621712010-04-24 17:59:49 +000015987ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010015988if test "x$ac_cv_member_struct_stat_st_blocks" = xyes
15989then :
Jack Jansendd19cf82001-12-06 22:36:17 +000015990
Pablo Galindoba421752021-05-03 20:33:17 +010015991printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLOCKS 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015992
15993
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015994fi
15995
Stefan Krah267b6392016-04-26 01:09:18 +020015996ac_fn_c_check_member "$LINENO" "struct passwd" "pw_gecos" "ac_cv_member_struct_passwd_pw_gecos" "
15997 #include <sys/types.h>
15998 #include <pwd.h>
15999
16000"
Pablo Galindoba421752021-05-03 20:33:17 +010016001if test "x$ac_cv_member_struct_passwd_pw_gecos" = xyes
16002then :
Stefan Krah267b6392016-04-26 01:09:18 +020016003
Pablo Galindoba421752021-05-03 20:33:17 +010016004printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_GECOS 1" >>confdefs.h
Stefan Krah267b6392016-04-26 01:09:18 +020016005
16006
16007fi
16008ac_fn_c_check_member "$LINENO" "struct passwd" "pw_passwd" "ac_cv_member_struct_passwd_pw_passwd" "
16009 #include <sys/types.h>
16010 #include <pwd.h>
16011
16012"
Pablo Galindoba421752021-05-03 20:33:17 +010016013if test "x$ac_cv_member_struct_passwd_pw_passwd" = xyes
16014then :
Stefan Krah267b6392016-04-26 01:09:18 +020016015
Pablo Galindoba421752021-05-03 20:33:17 +010016016printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_PASSWD 1" >>confdefs.h
Stefan Krah267b6392016-04-26 01:09:18 +020016017
16018
16019fi
16020
Zachary Ware6a6967e2016-10-01 00:47:27 -050016021# Issue #21085: In Cygwin, siginfo_t does not have si_band field.
16022ac_fn_c_check_member "$LINENO" "siginfo_t" "si_band" "ac_cv_member_siginfo_t_si_band" "#include <signal.h>
16023"
Pablo Galindoba421752021-05-03 20:33:17 +010016024if test "x$ac_cv_member_siginfo_t_si_band" = xyes
16025then :
Zachary Ware6a6967e2016-10-01 00:47:27 -050016026
Pablo Galindoba421752021-05-03 20:33:17 +010016027printf "%s\n" "#define HAVE_SIGINFO_T_SI_BAND 1" >>confdefs.h
Zachary Ware6a6967e2016-10-01 00:47:27 -050016028
16029
16030fi
16031
Michael W. Hudson54241132001-12-07 15:38:26 +000016032
Pablo Galindoba421752021-05-03 20:33:17 +010016033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5
16034printf %s "checking for time.h that defines altzone... " >&6; }
16035if test ${ac_cv_header_time_altzone+y}
16036then :
16037 printf %s "(cached) " >&6
16038else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +000016039
Matthias Kloseb9621712010-04-24 17:59:49 +000016040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016041/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016042#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016043int
Pablo Galindoba421752021-05-03 20:33:17 +010016044main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016045{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016046return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000016047 ;
16048 return 0;
16049}
16050_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016051if ac_fn_c_try_compile "$LINENO"
16052then :
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016053 ac_cv_header_time_altzone=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016054else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016055 ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000016056fi
Pablo Galindoba421752021-05-03 20:33:17 +010016057rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb159a552010-04-25 21:00:44 +000016058
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016059fi
16060
Pablo Galindoba421752021-05-03 20:33:17 +010016061{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5
16062printf "%s\n" "$ac_cv_header_time_altzone" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016063if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016064
Pablo Galindoba421752021-05-03 20:33:17 +010016065printf "%s\n" "#define HAVE_ALTZONE 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016066
16067fi
16068
Guido van Rossumda88dad1995-01-26 00:46:29 +000016069was_it_defined=no
Pablo Galindoba421752021-05-03 20:33:17 +010016070{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5
16071printf %s "checking whether sys/select.h and sys/time.h may both be included... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016072cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016073/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016074
16075#include <sys/types.h>
16076#include <sys/select.h>
16077#include <sys/time.h>
16078
Martin v. Löwis11437992002-04-12 09:54:03 +000016079int
Pablo Galindoba421752021-05-03 20:33:17 +010016080main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016081{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016082;
Martin v. Löwis11437992002-04-12 09:54:03 +000016083 ;
16084 return 0;
16085}
16086_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016087if ac_fn_c_try_compile "$LINENO"
16088then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016089
16090
Pablo Galindoba421752021-05-03 20:33:17 +010016091printf "%s\n" "#define SYS_SELECT_WITH_SYS_TIME 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000016092
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016093 was_it_defined=yes
16094
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016095fi
Pablo Galindoba421752021-05-03 20:33:17 +010016096rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16097{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5
16098printf "%s\n" "$was_it_defined" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016099
Pablo Galindoba421752021-05-03 20:33:17 +010016100{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5
16101printf %s "checking for addrinfo... " >&6; }
16102if test ${ac_cv_struct_addrinfo+y}
16103then :
16104 printf %s "(cached) " >&6
16105else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016107/* end confdefs.h. */
Matthias Kloseb159a552010-04-25 21:00:44 +000016108#include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016109int
Pablo Galindoba421752021-05-03 20:33:17 +010016110main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016111{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016112struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000016113 ;
16114 return 0;
16115}
16116_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016117if ac_fn_c_try_compile "$LINENO"
16118then :
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016119 ac_cv_struct_addrinfo=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016120else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016121 ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016122fi
Pablo Galindoba421752021-05-03 20:33:17 +010016123rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016124fi
16125
Pablo Galindoba421752021-05-03 20:33:17 +010016126{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5
16127printf "%s\n" "$ac_cv_struct_addrinfo" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016128if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016129
Pablo Galindoba421752021-05-03 20:33:17 +010016130printf "%s\n" "#define HAVE_ADDRINFO 1" >>confdefs.h
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016131
16132fi
16133
Pablo Galindoba421752021-05-03 20:33:17 +010016134{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5
16135printf %s "checking for sockaddr_storage... " >&6; }
16136if test ${ac_cv_struct_sockaddr_storage+y}
16137then :
16138 printf %s "(cached) " >&6
16139else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016141/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016142
16143# include <sys/types.h>
16144# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016145int
Pablo Galindoba421752021-05-03 20:33:17 +010016146main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016147{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016148struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000016149 ;
16150 return 0;
16151}
16152_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016153if ac_fn_c_try_compile "$LINENO"
16154then :
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016155 ac_cv_struct_sockaddr_storage=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016156else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016157 ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016158fi
Pablo Galindoba421752021-05-03 20:33:17 +010016159rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016160fi
16161
Pablo Galindoba421752021-05-03 20:33:17 +010016162{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5
16163printf "%s\n" "$ac_cv_struct_sockaddr_storage" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016164if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016165
Pablo Galindoba421752021-05-03 20:33:17 +010016166printf "%s\n" "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016167
16168fi
16169
Pablo Galindoba421752021-05-03 20:33:17 +010016170{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sockaddr_alg" >&5
16171printf %s "checking for sockaddr_alg... " >&6; }
16172if test ${ac_cv_struct_sockaddr_alg+y}
16173then :
16174 printf %s "(cached) " >&6
16175else $as_nop
Christian Heimesdffa3942016-09-05 23:54:41 +020016176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16177/* end confdefs.h. */
16178
16179# include <sys/types.h>
16180# include <sys/socket.h>
16181# include <linux/if_alg.h>
16182int
Pablo Galindoba421752021-05-03 20:33:17 +010016183main (void)
Christian Heimesdffa3942016-09-05 23:54:41 +020016184{
16185struct sockaddr_alg s
16186 ;
16187 return 0;
16188}
16189_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016190if ac_fn_c_try_compile "$LINENO"
16191then :
Christian Heimesdffa3942016-09-05 23:54:41 +020016192 ac_cv_struct_sockaddr_alg=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016193else $as_nop
Christian Heimesdffa3942016-09-05 23:54:41 +020016194 ac_cv_struct_sockaddr_alg=no
16195fi
Pablo Galindoba421752021-05-03 20:33:17 +010016196rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Christian Heimesdffa3942016-09-05 23:54:41 +020016197fi
16198
Pablo Galindoba421752021-05-03 20:33:17 +010016199{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_alg" >&5
16200printf "%s\n" "$ac_cv_struct_sockaddr_alg" >&6; }
Christian Heimesdffa3942016-09-05 23:54:41 +020016201if test $ac_cv_struct_sockaddr_alg = yes; then
16202
Pablo Galindoba421752021-05-03 20:33:17 +010016203printf "%s\n" "#define HAVE_SOCKADDR_ALG 1" >>confdefs.h
Christian Heimesdffa3942016-09-05 23:54:41 +020016204
16205fi
16206
Guido van Rossum627b2d71993-12-24 10:39:16 +000016207# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000016208
Pablo Galindoba421752021-05-03 20:33:17 +010016209{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
16210printf %s "checking whether char is unsigned... " >&6; }
16211if test ${ac_cv_c_char_unsigned+y}
16212then :
16213 printf %s "(cached) " >&6
16214else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016216/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016217$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000016218int
Pablo Galindoba421752021-05-03 20:33:17 +010016219main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016220{
16221static int test_array [1 - 2 * !(((char) -1) < 0)];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016222test_array [0] = 0;
16223return test_array [0];
Martin v. Löwis11437992002-04-12 09:54:03 +000016224
16225 ;
16226 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000016227}
Martin v. Löwis11437992002-04-12 09:54:03 +000016228_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016229if ac_fn_c_try_compile "$LINENO"
16230then :
Michael W. Hudson54241132001-12-07 15:38:26 +000016231 ac_cv_c_char_unsigned=no
Pablo Galindoba421752021-05-03 20:33:17 +010016232else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016233 ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016234fi
Pablo Galindoba421752021-05-03 20:33:17 +010016235rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016236fi
Pablo Galindoba421752021-05-03 20:33:17 +010016237{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
16238printf "%s\n" "$ac_cv_c_char_unsigned" >&6; }
16239if test $ac_cv_c_char_unsigned = yes; then
16240 printf "%s\n" "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016241
16242fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000016243
Pablo Galindoba421752021-05-03 20:33:17 +010016244{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
16245printf %s "checking for an ANSI C-conforming const... " >&6; }
16246if test ${ac_cv_c_const+y}
16247then :
16248 printf %s "(cached) " >&6
16249else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016251/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016252
Martin v. Löwis11437992002-04-12 09:54:03 +000016253int
Pablo Galindoba421752021-05-03 20:33:17 +010016254main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016255{
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016256
Martin v. Löwis11437992002-04-12 09:54:03 +000016257#ifndef __cplusplus
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016258 /* Ultrix mips cc rejects this sort of thing. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016259 typedef int charset[2];
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016260 const charset cs = { 0, 0 };
Martin v. Löwis11437992002-04-12 09:54:03 +000016261 /* SunOS 4.1.1 cc rejects this. */
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016262 char const *const *pcpcc;
16263 char **ppc;
Martin v. Löwis11437992002-04-12 09:54:03 +000016264 /* NEC SVR4.0.2 mips cc rejects this. */
16265 struct point {int x, y;};
16266 static struct point const zero = {0,0};
Pablo Galindoba421752021-05-03 20:33:17 +010016267 /* IBM XL C 1.02.0.0 rejects this.
Martin v. Löwis11437992002-04-12 09:54:03 +000016268 It does not let you subtract one const X* pointer from another in
16269 an arm of an if-expression whose if-part is not a constant
16270 expression */
16271 const char *g = "string";
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016272 pcpcc = &g + (g ? g-g : 0);
Martin v. Löwis11437992002-04-12 09:54:03 +000016273 /* HPUX 7.0 cc rejects these. */
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016274 ++pcpcc;
16275 ppc = (char**) pcpcc;
16276 pcpcc = (char const *const *) ppc;
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016277 { /* SCO 3.2v4 cc rejects this sort of thing. */
16278 char tx;
16279 char *t = &tx;
Martin v. Löwis11437992002-04-12 09:54:03 +000016280 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016281
Martin v. Löwis11437992002-04-12 09:54:03 +000016282 *t++ = 0;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016283 if (s) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000016284 }
16285 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
16286 int x[] = {25, 17};
16287 const int *foo = &x[0];
16288 ++foo;
16289 }
16290 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
16291 typedef const int *iptr;
16292 iptr p = 0;
16293 ++p;
16294 }
Pablo Galindoba421752021-05-03 20:33:17 +010016295 { /* IBM XL C 1.02.0.0 rejects this sort of thing, saying
Martin v. Löwis11437992002-04-12 09:54:03 +000016296 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000016297 struct s { int j; const int *ap[3]; } bx;
16298 struct s *b = &bx; b->j = 5;
Martin v. Löwis11437992002-04-12 09:54:03 +000016299 }
16300 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
16301 const int foo = 10;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016302 if (!foo) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000016303 }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016304 return !cs[0] && !zero.x;
Martin v. Löwis11437992002-04-12 09:54:03 +000016305#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000016306
Martin v. Löwis11437992002-04-12 09:54:03 +000016307 ;
16308 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000016309}
Martin v. Löwis11437992002-04-12 09:54:03 +000016310_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016311if ac_fn_c_try_compile "$LINENO"
16312then :
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016313 ac_cv_c_const=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016314else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016315 ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016316fi
Pablo Galindoba421752021-05-03 20:33:17 +010016317rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016318fi
Pablo Galindoba421752021-05-03 20:33:17 +010016319{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
16320printf "%s\n" "$ac_cv_c_const" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016321if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016322
Pablo Galindoba421752021-05-03 20:33:17 +010016323printf "%s\n" "#define const /**/" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016324
16325fi
16326
Michael W. Hudson54241132001-12-07 15:38:26 +000016327
Guido van Rossumda88dad1995-01-26 00:46:29 +000016328works=no
Pablo Galindoba421752021-05-03 20:33:17 +010016329{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5
16330printf %s "checking for working signed char... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016331cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016332/* end confdefs.h. */
Guido van Rossumdabb11b1994-10-11 15:04:27 +000016333
Martin v. Löwis11437992002-04-12 09:54:03 +000016334int
Pablo Galindoba421752021-05-03 20:33:17 +010016335main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016336{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016337signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000016338 ;
16339 return 0;
16340}
16341_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016342if ac_fn_c_try_compile "$LINENO"
16343then :
Guido van Rossumda88dad1995-01-26 00:46:29 +000016344 works=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016345else $as_nop
Skip Montanaro6dead952003-09-25 14:50:04 +000016346
Pablo Galindoba421752021-05-03 20:33:17 +010016347printf "%s\n" "#define signed /**/" >>confdefs.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000016348
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016349
Guido van Rossum7f43da71994-08-01 12:15:30 +000016350fi
Pablo Galindoba421752021-05-03 20:33:17 +010016351rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16352{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $works" >&5
16353printf "%s\n" "$works" >&6; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000016354
Guido van Rossumda88dad1995-01-26 00:46:29 +000016355have_prototypes=no
Pablo Galindoba421752021-05-03 20:33:17 +010016356{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5
16357printf %s "checking for prototypes... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016358cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016359/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016360int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016361int
Pablo Galindoba421752021-05-03 20:33:17 +010016362main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016363{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016364return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000016365 ;
16366 return 0;
16367}
16368_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016369if ac_fn_c_try_compile "$LINENO"
16370then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016371
Pablo Galindoba421752021-05-03 20:33:17 +010016372printf "%s\n" "#define HAVE_PROTOTYPES 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000016373
Matthias Kloseb159a552010-04-25 21:00:44 +000016374 have_prototypes=yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000016375fi
Pablo Galindoba421752021-05-03 20:33:17 +010016376rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16377{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5
16378printf "%s\n" "$have_prototypes" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016379
Guido van Rossumda88dad1995-01-26 00:46:29 +000016380works=no
Pablo Galindoba421752021-05-03 20:33:17 +010016381{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5
16382printf %s "checking for variable length prototypes and stdarg.h... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016383cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016384/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016385
16386#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000016387int foo(int x, ...) {
16388 va_list va;
16389 va_start(va, x);
16390 va_arg(va, int);
16391 va_arg(va, char *);
16392 va_arg(va, double);
16393 return 0;
16394}
Guido van Rossum7f43da71994-08-01 12:15:30 +000016395
Martin v. Löwis11437992002-04-12 09:54:03 +000016396int
Pablo Galindoba421752021-05-03 20:33:17 +010016397main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016398{
Guido van Rossum90eea071996-08-30 20:58:57 +000016399return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000016400 ;
16401 return 0;
16402}
16403_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016404if ac_fn_c_try_compile "$LINENO"
16405then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016406
16407
Pablo Galindoba421752021-05-03 20:33:17 +010016408printf "%s\n" "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000016409
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016410 works=yes
16411
Guido van Rossum627b2d71993-12-24 10:39:16 +000016412fi
Pablo Galindoba421752021-05-03 20:33:17 +010016413rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16414{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $works" >&5
16415printf "%s\n" "$works" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016416
Martin v. Löwisd6320502004-08-12 13:45:08 +000016417# check for socketpair
Pablo Galindoba421752021-05-03 20:33:17 +010016418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5
16419printf %s "checking for socketpair... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016420cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Martin v. Löwisd6320502004-08-12 13:45:08 +000016421/* end confdefs.h. */
16422
16423#include <sys/types.h>
16424#include <sys/socket.h>
16425
16426int
Pablo Galindoba421752021-05-03 20:33:17 +010016427main (void)
Martin v. Löwisd6320502004-08-12 13:45:08 +000016428{
16429void *x=socketpair
16430 ;
16431 return 0;
16432}
16433_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016434if ac_fn_c_try_compile "$LINENO"
16435then :
Martin v. Löwisd6320502004-08-12 13:45:08 +000016436
Pablo Galindoba421752021-05-03 20:33:17 +010016437printf "%s\n" "#define HAVE_SOCKETPAIR 1" >>confdefs.h
Martin v. Löwisd6320502004-08-12 13:45:08 +000016438
Pablo Galindoba421752021-05-03 20:33:17 +010016439 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16440printf "%s\n" "yes" >&6; }
16441else $as_nop
16442 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16443printf "%s\n" "no" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000016444
16445fi
Pablo Galindoba421752021-05-03 20:33:17 +010016446rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwisd6320502004-08-12 13:45:08 +000016447
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016448# check if sockaddr has sa_len member
Pablo Galindoba421752021-05-03 20:33:17 +010016449{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5
16450printf %s "checking if sockaddr has sa_len member... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016451cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016452/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016453#include <sys/types.h>
16454#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016455int
Pablo Galindoba421752021-05-03 20:33:17 +010016456main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016457{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016458struct sockaddr x;
16459x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000016460 ;
16461 return 0;
16462}
16463_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016464if ac_fn_c_try_compile "$LINENO"
16465then :
16466 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16467printf "%s\n" "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016468
Pablo Galindoba421752021-05-03 20:33:17 +010016469printf "%s\n" "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016470
Pablo Galindoba421752021-05-03 20:33:17 +010016471else $as_nop
16472 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16473printf "%s\n" "no" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000016474
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016475fi
Pablo Galindoba421752021-05-03 20:33:17 +010016476rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016477
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016478# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000016479
16480
Matthias Kloseb9621712010-04-24 17:59:49 +000016481ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r"
Pablo Galindoba421752021-05-03 20:33:17 +010016482if test "x$ac_cv_func_gethostbyname_r" = xyes
16483then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016484
Pablo Galindoba421752021-05-03 20:33:17 +010016485 printf "%s\n" "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016486
Pablo Galindoba421752021-05-03 20:33:17 +010016487 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5
16488printf %s "checking gethostbyname_r with 6 args... " >&6; }
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016489 OLD_CFLAGS=$CFLAGS
16490 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Matthias Kloseb9621712010-04-24 17:59:49 +000016491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016492/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016493
16494# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016495
Martin v. Löwis11437992002-04-12 09:54:03 +000016496int
Pablo Galindoba421752021-05-03 20:33:17 +010016497main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016498{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016499
16500 char *name;
16501 struct hostent *he, *res;
16502 char buffer[2048];
16503 int buflen = 2048;
16504 int h_errnop;
16505
16506 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000016507
16508 ;
16509 return 0;
16510}
16511_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016512if ac_fn_c_try_compile "$LINENO"
16513then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016514
Pablo Galindoba421752021-05-03 20:33:17 +010016515 printf "%s\n" "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016516
Martin v. Löwis11437992002-04-12 09:54:03 +000016517
Pablo Galindoba421752021-05-03 20:33:17 +010016518printf "%s\n" "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016519
Pablo Galindoba421752021-05-03 20:33:17 +010016520 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16521printf "%s\n" "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016522
Pablo Galindoba421752021-05-03 20:33:17 +010016523else $as_nop
Skip Montanaro6dead952003-09-25 14:50:04 +000016524
Pablo Galindoba421752021-05-03 20:33:17 +010016525 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16526printf "%s\n" "no" >&6; }
16527 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5
16528printf %s "checking gethostbyname_r with 5 args... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016530/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016531
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016532# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016533
Martin v. Löwis11437992002-04-12 09:54:03 +000016534int
Pablo Galindoba421752021-05-03 20:33:17 +010016535main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016536{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016537
16538 char *name;
16539 struct hostent *he;
Matthias Kloseb159a552010-04-25 21:00:44 +000016540 char buffer[2048];
16541 int buflen = 2048;
16542 int h_errnop;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016543
Matthias Kloseb159a552010-04-25 21:00:44 +000016544 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000016545
16546 ;
16547 return 0;
16548}
16549_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016550if ac_fn_c_try_compile "$LINENO"
16551then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016552
Pablo Galindoba421752021-05-03 20:33:17 +010016553 printf "%s\n" "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016554
Martin v. Löwis11437992002-04-12 09:54:03 +000016555
Pablo Galindoba421752021-05-03 20:33:17 +010016556printf "%s\n" "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016557
Pablo Galindoba421752021-05-03 20:33:17 +010016558 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16559printf "%s\n" "yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016560
Pablo Galindoba421752021-05-03 20:33:17 +010016561else $as_nop
Skip Montanaro6dead952003-09-25 14:50:04 +000016562
Pablo Galindoba421752021-05-03 20:33:17 +010016563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16564printf "%s\n" "no" >&6; }
16565 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5
16566printf %s "checking gethostbyname_r with 3 args... " >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000016567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16568/* end confdefs.h. */
16569
16570# include <netdb.h>
16571
16572int
Pablo Galindoba421752021-05-03 20:33:17 +010016573main (void)
Matthias Kloseb159a552010-04-25 21:00:44 +000016574{
16575
16576 char *name;
16577 struct hostent *he;
16578 struct hostent_data data;
16579
16580 (void) gethostbyname_r(name, he, &data);
16581
16582 ;
16583 return 0;
16584}
16585_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016586if ac_fn_c_try_compile "$LINENO"
16587then :
Matthias Kloseb159a552010-04-25 21:00:44 +000016588
Pablo Galindoba421752021-05-03 20:33:17 +010016589 printf "%s\n" "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
Matthias Kloseb159a552010-04-25 21:00:44 +000016590
16591
Pablo Galindoba421752021-05-03 20:33:17 +010016592printf "%s\n" "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h
Matthias Kloseb159a552010-04-25 21:00:44 +000016593
Pablo Galindoba421752021-05-03 20:33:17 +010016594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16595printf "%s\n" "yes" >&6; }
Matthias Kloseb159a552010-04-25 21:00:44 +000016596
Pablo Galindoba421752021-05-03 20:33:17 +010016597else $as_nop
Matthias Kloseb159a552010-04-25 21:00:44 +000016598
Pablo Galindoba421752021-05-03 20:33:17 +010016599 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16600printf "%s\n" "no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016601
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016602fi
Pablo Galindoba421752021-05-03 20:33:17 +010016603rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000016604
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016605fi
Pablo Galindoba421752021-05-03 20:33:17 +010016606rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000016607
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016608fi
Pablo Galindoba421752021-05-03 20:33:17 +010016609rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016610 CFLAGS=$OLD_CFLAGS
16611
Pablo Galindoba421752021-05-03 20:33:17 +010016612else $as_nop
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016613
Matthias Kloseb9621712010-04-24 17:59:49 +000016614 ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
Pablo Galindoba421752021-05-03 20:33:17 +010016615if test "x$ac_cv_func_gethostbyname" = xyes
16616then :
16617 printf "%s\n" "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016618
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016619fi
16620
Michael W. Hudson54241132001-12-07 15:38:26 +000016621
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016622fi
16623
Michael W. Hudson54241132001-12-07 15:38:26 +000016624
16625
16626
16627
16628
16629
Guido van Rossum627b2d71993-12-24 10:39:16 +000016630# checks for system services
16631# (none yet)
16632
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016633# Linux requires this for correct f.p. operations
Matthias Kloseb9621712010-04-24 17:59:49 +000016634ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control"
Pablo Galindoba421752021-05-03 20:33:17 +010016635if test "x$ac_cv_func___fpu_control" = xyes
16636then :
Matthias Kloseb9621712010-04-24 17:59:49 +000016637
Pablo Galindoba421752021-05-03 20:33:17 +010016638else $as_nop
16639 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5
16640printf %s "checking for __fpu_control in -lieee... " >&6; }
16641if test ${ac_cv_lib_ieee___fpu_control+y}
16642then :
16643 printf %s "(cached) " >&6
16644else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000016645 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016646LIBS="-lieee $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000016647cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000016648/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016649
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016650/* Override any GCC internal prototype to avoid an error.
16651 Use char because int might match the return type of a GCC
16652 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016653char __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016654int
Pablo Galindoba421752021-05-03 20:33:17 +010016655main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000016656{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016657return __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016658 ;
16659 return 0;
16660}
16661_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016662if ac_fn_c_try_link "$LINENO"
16663then :
Martin v. Löwis11437992002-04-12 09:54:03 +000016664 ac_cv_lib_ieee___fpu_control=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016665else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016666 ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000016667fi
Pablo Galindoba421752021-05-03 20:33:17 +010016668rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000016669 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000016670LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016671fi
Pablo Galindoba421752021-05-03 20:33:17 +010016672{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5
16673printf "%s\n" "$ac_cv_lib_ieee___fpu_control" >&6; }
16674if test "x$ac_cv_lib_ieee___fpu_control" = xyes
16675then :
16676 printf "%s\n" "#define HAVE_LIBIEEE 1" >>confdefs.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016677
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016678 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016679
Guido van Rossum627b2d71993-12-24 10:39:16 +000016680fi
16681
Michael W. Hudson54241132001-12-07 15:38:26 +000016682
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016683fi
16684
Michael W. Hudson54241132001-12-07 15:38:26 +000016685
Guido van Rossum7f43da71994-08-01 12:15:30 +000016686# check for --with-libm=...
16687
Guido van Rossum563e7081996-09-10 18:20:48 +000016688case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000016689Darwin) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000016690*) LIBM=-lm
16691esac
Pablo Galindoba421752021-05-03 20:33:17 +010016692{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5
16693printf %s "checking for --with-libm=STRING... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016694
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016695# Check whether --with-libm was given.
Pablo Galindoba421752021-05-03 20:33:17 +010016696if test ${with_libm+y}
16697then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016698 withval=$with_libm;
Guido van Rossum7f253911997-05-09 02:42:48 +000016699if test "$withval" = no
16700then LIBM=
Pablo Galindoba421752021-05-03 20:33:17 +010016701 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5
16702printf "%s\n" "force LIBM empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000016703elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000016704then LIBM=$withval
Pablo Galindoba421752021-05-03 20:33:17 +010016705 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5
16706printf "%s\n" "set LIBM=\"$withval\"" >&6; }
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020016707else as_fn_error $? "proper usage is --with-libm=STRING" "$LINENO" 5
Guido van Rossum7f43da71994-08-01 12:15:30 +000016708fi
Pablo Galindoba421752021-05-03 20:33:17 +010016709else $as_nop
16710 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5
16711printf "%s\n" "default LIBM=\"$LIBM\"" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016712fi
16713
Guido van Rossum7f43da71994-08-01 12:15:30 +000016714
16715# check for --with-libc=...
16716
Pablo Galindoba421752021-05-03 20:33:17 +010016717{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5
16718printf %s "checking for --with-libc=STRING... " >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016719
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016720# Check whether --with-libc was given.
Pablo Galindoba421752021-05-03 20:33:17 +010016721if test ${with_libc+y}
16722then :
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016723 withval=$with_libc;
Guido van Rossum7f253911997-05-09 02:42:48 +000016724if test "$withval" = no
16725then LIBC=
Pablo Galindoba421752021-05-03 20:33:17 +010016726 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5
16727printf "%s\n" "force LIBC empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000016728elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000016729then LIBC=$withval
Pablo Galindoba421752021-05-03 20:33:17 +010016730 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5
16731printf "%s\n" "set LIBC=\"$withval\"" >&6; }
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020016732else as_fn_error $? "proper usage is --with-libc=STRING" "$LINENO" 5
Guido van Rossum7f43da71994-08-01 12:15:30 +000016733fi
Pablo Galindoba421752021-05-03 20:33:17 +010016734else $as_nop
16735 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5
16736printf "%s\n" "default LIBC=\"$LIBC\"" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000016737fi
16738
Guido van Rossum7f43da71994-08-01 12:15:30 +000016739
Stefan Krah1919b7e2012-03-21 18:25:23 +010016740# **************************************
16741# * Check for gcc x64 inline assembler *
16742# **************************************
16743
Pablo Galindoba421752021-05-03 20:33:17 +010016744{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for x64 gcc inline assembler" >&5
16745printf %s "checking for x64 gcc inline assembler... " >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010016746cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16747/* end confdefs.h. */
16748
16749int
Pablo Galindoba421752021-05-03 20:33:17 +010016750main (void)
Stefan Krah1919b7e2012-03-21 18:25:23 +010016751{
16752
16753 __asm__ __volatile__ ("movq %rcx, %rax");
16754
16755 ;
16756 return 0;
16757}
16758_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016759if ac_fn_c_try_link "$LINENO"
16760then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010016761 have_gcc_asm_for_x64=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016762else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010016763 have_gcc_asm_for_x64=no
16764fi
Pablo Galindoba421752021-05-03 20:33:17 +010016765rm -f core conftest.err conftest.$ac_objext conftest.beam \
Stefan Krahe31db2a2015-07-02 20:27:56 +020016766 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010016767{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x64" >&5
16768printf "%s\n" "$have_gcc_asm_for_x64" >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010016769if test "$have_gcc_asm_for_x64" = yes
16770then
16771
Pablo Galindoba421752021-05-03 20:33:17 +010016772printf "%s\n" "#define HAVE_GCC_ASM_FOR_X64 1" >>confdefs.h
Stefan Krah1919b7e2012-03-21 18:25:23 +010016773
16774fi
16775
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016776# **************************************************
16777# * Check for various properties of floating point *
16778# **************************************************
Christian Heimes81ee3ef2008-05-04 22:42:01 +000016779
Pablo Galindoba421752021-05-03 20:33:17 +010016780{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether float word ordering is bigendian" >&5
16781printf %s "checking whether float word ordering is bigendian... " >&6; }
16782if test ${ax_cv_c_float_words_bigendian+y}
16783then :
16784 printf %s "(cached) " >&6
16785else $as_nop
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016786
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016787
16788ax_cv_c_float_words_bigendian=unknown
16789cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016790/* end confdefs.h. */
16791
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016792
16793double d = 90904234967036810337470478905505011476211692735615632014797120844053488865816695273723469097858056257517020191247487429516932130503560650002327564517570778480236724525140520121371739201496540132640109977779420565776568942592.0;
16794
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016795
16796_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016797if ac_fn_c_try_compile "$LINENO"
16798then :
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016799
16800
Christian Heimes5d6e8c12021-03-27 14:44:04 +010016801if grep noonsees conftest.$ac_objext >/dev/null ; then
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016802 ax_cv_c_float_words_bigendian=yes
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016803fi
Christian Heimes5d6e8c12021-03-27 14:44:04 +010016804if grep seesnoon conftest.$ac_objext >/dev/null ; then
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016805 if test "$ax_cv_c_float_words_bigendian" = unknown; then
16806 ax_cv_c_float_words_bigendian=no
16807 else
16808 ax_cv_c_float_words_bigendian=unknown
16809 fi
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016810fi
16811
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016812
16813fi
Pablo Galindoba421752021-05-03 20:33:17 +010016814rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016815fi
Pablo Galindoba421752021-05-03 20:33:17 +010016816{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_c_float_words_bigendian" >&5
16817printf "%s\n" "$ax_cv_c_float_words_bigendian" >&6; }
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016818
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016819case $ax_cv_c_float_words_bigendian in
16820 yes)
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016821
Pablo Galindoba421752021-05-03 20:33:17 +010016822printf "%s\n" "#define FLOAT_WORDS_BIGENDIAN 1" >>confdefs.h
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016823 ;;
16824 no)
16825 ;;
16826 *)
16827 as_fn_error $? "
16828
16829Unknown float word ordering. You need to manually preset
16830ax_cv_c_float_words_bigendian=no (or yes) according to your system.
16831
16832 " "$LINENO" 5 ;;
16833esac
16834
16835
16836if test "$ax_cv_c_float_words_bigendian" = "yes"
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016837then
16838
Pablo Galindoba421752021-05-03 20:33:17 +010016839printf "%s\n" "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016840
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016841elif test "$ax_cv_c_float_words_bigendian" = "no"
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016842then
16843
Pablo Galindoba421752021-05-03 20:33:17 +010016844printf "%s\n" "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h
Benjamin Petersonb3b8cb42018-09-18 23:49:05 -070016845
16846else
16847 # Some ARM platforms use a mixed-endian representation for doubles.
16848 # While Python doesn't currently have full support for these platforms
16849 # (see e.g., issue 1762561), we can at least make sure that float <-> string
16850 # conversions work.
16851 # FLOAT_WORDS_BIGENDIAN doesnt actually detect this case, but if it's not big
16852 # or little, then it must be this?
16853
Pablo Galindoba421752021-05-03 20:33:17 +010016854printf "%s\n" "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016855
16856fi
16857
Mark Dickinson7abf8d42009-04-18 20:17:52 +000016858# The short float repr introduced in Python 3.1 requires the
Mark Dickinson10683072009-04-18 21:18:19 +000016859# correctly-rounded string <-> double conversion functions from
Mark Dickinson7abf8d42009-04-18 20:17:52 +000016860# Python/dtoa.c, which in turn require that the FPU uses 53-bit
Mark Dickinson10683072009-04-18 21:18:19 +000016861# rounding; this is a problem on x86, where the x87 FPU has a default
Mark Dickinsonf4243f62009-11-15 13:47:27 +000016862# rounding precision of 64 bits. For gcc/x86, we can fix this by
Mark Dickinson10683072009-04-18 21:18:19 +000016863# using inline assembler to get and set the x87 FPU control word.
Mark Dickinsonf4243f62009-11-15 13:47:27 +000016864
16865# This inline assembler syntax may also work for suncc and icc,
16866# so we try it on all platforms.
16867
Pablo Galindoba421752021-05-03 20:33:17 +010016868{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5
16869printf %s "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000016870cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016871/* end confdefs.h. */
16872
16873int
Pablo Galindoba421752021-05-03 20:33:17 +010016874main (void)
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016875{
16876
Mark Dickinsonf4243f62009-11-15 13:47:27 +000016877 unsigned short cw;
16878 __asm__ __volatile__ ("fnstcw %0" : "=m" (cw));
16879 __asm__ __volatile__ ("fldcw %0" : : "m" (cw));
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016880
16881 ;
16882 return 0;
16883}
16884_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016885if ac_fn_c_try_link "$LINENO"
16886then :
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016887 have_gcc_asm_for_x87=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016888else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016889 have_gcc_asm_for_x87=no
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016890fi
Pablo Galindoba421752021-05-03 20:33:17 +010016891rm -f core conftest.err conftest.$ac_objext conftest.beam \
Stefan Krahe31db2a2015-07-02 20:27:56 +020016892 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010016893{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5
16894printf "%s\n" "$have_gcc_asm_for_x87" >&6; }
Mark Dickinsonf4243f62009-11-15 13:47:27 +000016895if test "$have_gcc_asm_for_x87" = yes
16896then
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016897
Pablo Galindoba421752021-05-03 20:33:17 +010016898printf "%s\n" "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016899
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016900fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016901
Pablo Galindoba421752021-05-03 20:33:17 +010016902{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set mc68881 fpcr" >&5
16903printf %s "checking whether we can use gcc inline assembler to get and set mc68881 fpcr... " >&6; }
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016904cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16905/* end confdefs.h. */
16906
16907int
Pablo Galindoba421752021-05-03 20:33:17 +010016908main (void)
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016909{
16910
16911 unsigned int fpcr;
16912 __asm__ __volatile__ ("fmove.l %%fpcr,%0" : "=g" (fpcr));
16913 __asm__ __volatile__ ("fmove.l %0,%%fpcr" : : "g" (fpcr));
16914
16915 ;
16916 return 0;
16917}
16918_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016919if ac_fn_c_try_link "$LINENO"
16920then :
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016921 have_gcc_asm_for_mc68881=yes
Pablo Galindoba421752021-05-03 20:33:17 +010016922else $as_nop
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016923 have_gcc_asm_for_mc68881=no
16924fi
Pablo Galindoba421752021-05-03 20:33:17 +010016925rm -f core conftest.err conftest.$ac_objext conftest.beam \
Stefan Krahe31db2a2015-07-02 20:27:56 +020016926 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010016927{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_mc68881" >&5
16928printf "%s\n" "$have_gcc_asm_for_mc68881" >&6; }
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016929if test "$have_gcc_asm_for_mc68881" = yes
16930then
16931
Pablo Galindoba421752021-05-03 20:33:17 +010016932printf "%s\n" "#define HAVE_GCC_ASM_FOR_MC68881 1" >>confdefs.h
Benjamin Peterson8bdeb162014-04-17 00:00:31 -040016933
16934fi
16935
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016936# Detect whether system arithmetic is subject to x87-style double
16937# rounding issues. The result of this test has little meaning on non
16938# IEEE 754 platforms. On IEEE 754, test should return 1 if rounding
16939# mode is round-to-nearest and double rounding issues are present, and
16940# 0 otherwise. See http://bugs.python.org/issue2937 for more info.
Pablo Galindoba421752021-05-03 20:33:17 +010016941{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5
16942printf %s "checking for x87-style double rounding... " >&6; }
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016943# $BASECFLAGS may affect the result
16944ac_save_cc="$CC"
16945CC="$CC $BASECFLAGS"
Pablo Galindoba421752021-05-03 20:33:17 +010016946if test "$cross_compiling" = yes
16947then :
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016948 ac_cv_x87_double_rounding=no
Pablo Galindoba421752021-05-03 20:33:17 +010016949else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016951/* end confdefs.h. */
16952
16953#include <stdlib.h>
16954#include <math.h>
16955int main() {
16956 volatile double x, y, z;
16957 /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */
16958 x = 0.99999999999999989; /* 1-2**-53 */
16959 y = 1./x;
16960 if (y != 1.)
16961 exit(0);
16962 /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */
16963 x = 1e16;
16964 y = 2.99999;
16965 z = x + y;
16966 if (z != 1e16+4.)
16967 exit(0);
16968 /* both tests show evidence of double rounding */
16969 exit(1);
16970}
16971
16972_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010016973if ac_fn_c_try_run "$LINENO"
16974then :
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016975 ac_cv_x87_double_rounding=no
Pablo Galindoba421752021-05-03 20:33:17 +010016976else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000016977 ac_cv_x87_double_rounding=yes
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016978fi
Matthias Kloseb9621712010-04-24 17:59:49 +000016979rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16980 conftest.$ac_objext conftest.beam conftest.$ac_ext
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016981fi
16982
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016983CC="$ac_save_cc"
Pablo Galindoba421752021-05-03 20:33:17 +010016984{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5
16985printf "%s\n" "$ac_cv_x87_double_rounding" >&6; }
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016986if test "$ac_cv_x87_double_rounding" = yes
16987then
16988
Pablo Galindoba421752021-05-03 20:33:17 +010016989printf "%s\n" "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h
Mark Dickinson3dc7c6a2009-01-04 15:09:02 +000016990
16991fi
16992
Mark Dickinsonb08a53a2009-04-16 19:52:09 +000016993# ************************************
16994# * Check for mathematical functions *
16995# ************************************
16996
16997LIBS_SAVE=$LIBS
16998LIBS="$LIBS $LIBM"
16999
Pablo Galindoba421752021-05-03 20:33:17 +010017000ac_fn_c_check_func "$LINENO" "acosh" "ac_cv_func_acosh"
17001if test "x$ac_cv_func_acosh" = xyes
17002then :
17003 printf "%s\n" "#define HAVE_ACOSH 1" >>confdefs.h
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017004
17005fi
Pablo Galindoba421752021-05-03 20:33:17 +010017006ac_fn_c_check_func "$LINENO" "asinh" "ac_cv_func_asinh"
17007if test "x$ac_cv_func_asinh" = xyes
17008then :
17009 printf "%s\n" "#define HAVE_ASINH 1" >>confdefs.h
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017010
17011fi
Pablo Galindoba421752021-05-03 20:33:17 +010017012ac_fn_c_check_func "$LINENO" "atanh" "ac_cv_func_atanh"
17013if test "x$ac_cv_func_atanh" = xyes
17014then :
17015 printf "%s\n" "#define HAVE_ATANH 1" >>confdefs.h
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017016
Pablo Galindoba421752021-05-03 20:33:17 +010017017fi
17018ac_fn_c_check_func "$LINENO" "copysign" "ac_cv_func_copysign"
17019if test "x$ac_cv_func_copysign" = xyes
17020then :
17021 printf "%s\n" "#define HAVE_COPYSIGN 1" >>confdefs.h
17022
17023fi
17024ac_fn_c_check_func "$LINENO" "erf" "ac_cv_func_erf"
17025if test "x$ac_cv_func_erf" = xyes
17026then :
17027 printf "%s\n" "#define HAVE_ERF 1" >>confdefs.h
17028
17029fi
17030ac_fn_c_check_func "$LINENO" "erfc" "ac_cv_func_erfc"
17031if test "x$ac_cv_func_erfc" = xyes
17032then :
17033 printf "%s\n" "#define HAVE_ERFC 1" >>confdefs.h
17034
17035fi
17036ac_fn_c_check_func "$LINENO" "expm1" "ac_cv_func_expm1"
17037if test "x$ac_cv_func_expm1" = xyes
17038then :
17039 printf "%s\n" "#define HAVE_EXPM1 1" >>confdefs.h
17040
17041fi
17042ac_fn_c_check_func "$LINENO" "finite" "ac_cv_func_finite"
17043if test "x$ac_cv_func_finite" = xyes
17044then :
17045 printf "%s\n" "#define HAVE_FINITE 1" >>confdefs.h
17046
17047fi
17048ac_fn_c_check_func "$LINENO" "gamma" "ac_cv_func_gamma"
17049if test "x$ac_cv_func_gamma" = xyes
17050then :
17051 printf "%s\n" "#define HAVE_GAMMA 1" >>confdefs.h
17052
17053fi
17054
17055ac_fn_c_check_func "$LINENO" "hypot" "ac_cv_func_hypot"
17056if test "x$ac_cv_func_hypot" = xyes
17057then :
17058 printf "%s\n" "#define HAVE_HYPOT 1" >>confdefs.h
17059
17060fi
17061ac_fn_c_check_func "$LINENO" "lgamma" "ac_cv_func_lgamma"
17062if test "x$ac_cv_func_lgamma" = xyes
17063then :
17064 printf "%s\n" "#define HAVE_LGAMMA 1" >>confdefs.h
17065
17066fi
17067ac_fn_c_check_func "$LINENO" "log1p" "ac_cv_func_log1p"
17068if test "x$ac_cv_func_log1p" = xyes
17069then :
17070 printf "%s\n" "#define HAVE_LOG1P 1" >>confdefs.h
17071
17072fi
17073ac_fn_c_check_func "$LINENO" "log2" "ac_cv_func_log2"
17074if test "x$ac_cv_func_log2" = xyes
17075then :
17076 printf "%s\n" "#define HAVE_LOG2 1" >>confdefs.h
17077
17078fi
17079ac_fn_c_check_func "$LINENO" "round" "ac_cv_func_round"
17080if test "x$ac_cv_func_round" = xyes
17081then :
17082 printf "%s\n" "#define HAVE_ROUND 1" >>confdefs.h
17083
17084fi
17085ac_fn_c_check_func "$LINENO" "tgamma" "ac_cv_func_tgamma"
17086if test "x$ac_cv_func_tgamma" = xyes
17087then :
17088 printf "%s\n" "#define HAVE_TGAMMA 1" >>confdefs.h
17089
17090fi
17091
17092ac_fn_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h>
17093" "$ac_c_undeclared_builtin_options" "CFLAGS"
17094if test "x$ac_cv_have_decl_isinf" = xyes
17095then :
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017096 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017097else $as_nop
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017098 ac_have_decl=0
17099fi
Pablo Galindoba421752021-05-03 20:33:17 +010017100printf "%s\n" "#define HAVE_DECL_ISINF $ac_have_decl" >>confdefs.h
17101ac_fn_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h>
17102" "$ac_c_undeclared_builtin_options" "CFLAGS"
17103if test "x$ac_cv_have_decl_isnan" = xyes
17104then :
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017105 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017106else $as_nop
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017107 ac_have_decl=0
17108fi
Pablo Galindoba421752021-05-03 20:33:17 +010017109printf "%s\n" "#define HAVE_DECL_ISNAN $ac_have_decl" >>confdefs.h
17110ac_fn_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h>
17111" "$ac_c_undeclared_builtin_options" "CFLAGS"
17112if test "x$ac_cv_have_decl_isfinite" = xyes
17113then :
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017114 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017115else $as_nop
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017116 ac_have_decl=0
17117fi
Pablo Galindoba421752021-05-03 20:33:17 +010017118printf "%s\n" "#define HAVE_DECL_ISFINITE $ac_have_decl" >>confdefs.h
Mark Dickinsonec0d3552010-11-20 10:29:12 +000017119
17120
Mark Dickinsona614f042009-11-28 12:48:43 +000017121# For multiprocessing module, check that sem_open
17122# actually works. For FreeBSD versions <= 7.2,
17123# the kernel module that provides POSIX semaphores
17124# isn't loaded by default, so an attempt to call
17125# sem_open results in a 'Signal 12' error.
Pablo Galindoba421752021-05-03 20:33:17 +010017126{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5
17127printf %s "checking whether POSIX semaphores are enabled... " >&6; }
17128if test ${ac_cv_posix_semaphores_enabled+y}
17129then :
17130 printf %s "(cached) " >&6
17131else $as_nop
17132 if test "$cross_compiling" = yes
17133then :
Mark Dickinsona614f042009-11-28 12:48:43 +000017134 ac_cv_posix_semaphores_enabled=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017135else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Mark Dickinsona614f042009-11-28 12:48:43 +000017137/* end confdefs.h. */
17138
17139#include <unistd.h>
17140#include <fcntl.h>
17141#include <stdio.h>
17142#include <semaphore.h>
17143#include <sys/stat.h>
17144
17145int main(void) {
17146 sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0);
17147 if (a == SEM_FAILED) {
17148 perror("sem_open");
17149 return 1;
17150 }
17151 sem_close(a);
Mark Dickinsonba79b352009-12-13 21:10:57 +000017152 sem_unlink("/autoconf");
Mark Dickinsona614f042009-11-28 12:48:43 +000017153 return 0;
17154}
17155
17156_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017157if ac_fn_c_try_run "$LINENO"
17158then :
Mark Dickinsona614f042009-11-28 12:48:43 +000017159 ac_cv_posix_semaphores_enabled=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017160else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017161 ac_cv_posix_semaphores_enabled=no
Mark Dickinsona614f042009-11-28 12:48:43 +000017162fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017163rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17164 conftest.$ac_objext conftest.beam conftest.$ac_ext
Mark Dickinsona614f042009-11-28 12:48:43 +000017165fi
17166
17167
Mark Dickinsona614f042009-11-28 12:48:43 +000017168fi
17169
Pablo Galindoba421752021-05-03 20:33:17 +010017170{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5
17171printf "%s\n" "$ac_cv_posix_semaphores_enabled" >&6; }
Mark Dickinsona614f042009-11-28 12:48:43 +000017172if test $ac_cv_posix_semaphores_enabled = no
17173then
17174
Pablo Galindoba421752021-05-03 20:33:17 +010017175printf "%s\n" "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h
Mark Dickinsona614f042009-11-28 12:48:43 +000017176
17177fi
17178
Mark Dickinson10683072009-04-18 21:18:19 +000017179# Multiprocessing check for broken sem_getvalue
Pablo Galindoba421752021-05-03 20:33:17 +010017180{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5
17181printf %s "checking for broken sem_getvalue... " >&6; }
17182if test ${ac_cv_broken_sem_getvalue+y}
17183then :
17184 printf %s "(cached) " >&6
17185else $as_nop
17186 if test "$cross_compiling" = yes
17187then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000017188 ac_cv_broken_sem_getvalue=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017189else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Mark Dickinson10683072009-04-18 21:18:19 +000017191/* end confdefs.h. */
17192
17193#include <unistd.h>
17194#include <fcntl.h>
17195#include <stdio.h>
17196#include <semaphore.h>
17197#include <sys/stat.h>
17198
17199int main(void){
Mark Dickinsonba79b352009-12-13 21:10:57 +000017200 sem_t *a = sem_open("/autocftw", O_CREAT, S_IRUSR|S_IWUSR, 0);
Mark Dickinson10683072009-04-18 21:18:19 +000017201 int count;
17202 int res;
17203 if(a==SEM_FAILED){
17204 perror("sem_open");
17205 return 1;
17206
17207 }
17208 res = sem_getvalue(a, &count);
17209 sem_close(a);
Mark Dickinsonba79b352009-12-13 21:10:57 +000017210 sem_unlink("/autocftw");
Mark Dickinson10683072009-04-18 21:18:19 +000017211 return res==-1 ? 1 : 0;
17212}
17213
Mark Dickinson10683072009-04-18 21:18:19 +000017214_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017215if ac_fn_c_try_run "$LINENO"
17216then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000017217 ac_cv_broken_sem_getvalue=no
Pablo Galindoba421752021-05-03 20:33:17 +010017218else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017219 ac_cv_broken_sem_getvalue=yes
Alexandre Vassalotti19142282009-07-17 23:11:52 +000017220fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017221rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17222 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +000017223fi
17224
Alexandre Vassalotti19142282009-07-17 23:11:52 +000017225
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000017226fi
17227
Pablo Galindoba421752021-05-03 20:33:17 +010017228{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5
17229printf "%s\n" "$ac_cv_broken_sem_getvalue" >&6; }
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000017230if test $ac_cv_broken_sem_getvalue = yes
17231then
17232
Pablo Galindoba421752021-05-03 20:33:17 +010017233printf "%s\n" "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000017234
17235fi
17236
Pablo Galindoba421752021-05-03 20:33:17 +010017237ac_fn_check_decl "$LINENO" "RTLD_LAZY" "ac_cv_have_decl_RTLD_LAZY" "#include <dlfcn.h>
17238" "$ac_c_undeclared_builtin_options" "CFLAGS"
17239if test "x$ac_cv_have_decl_RTLD_LAZY" = xyes
17240then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017241 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017242else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017243 ac_have_decl=0
17244fi
Pablo Galindoba421752021-05-03 20:33:17 +010017245printf "%s\n" "#define HAVE_DECL_RTLD_LAZY $ac_have_decl" >>confdefs.h
17246ac_fn_check_decl "$LINENO" "RTLD_NOW" "ac_cv_have_decl_RTLD_NOW" "#include <dlfcn.h>
17247" "$ac_c_undeclared_builtin_options" "CFLAGS"
17248if test "x$ac_cv_have_decl_RTLD_NOW" = xyes
17249then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017250 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017251else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017252 ac_have_decl=0
17253fi
Pablo Galindoba421752021-05-03 20:33:17 +010017254printf "%s\n" "#define HAVE_DECL_RTLD_NOW $ac_have_decl" >>confdefs.h
17255ac_fn_check_decl "$LINENO" "RTLD_GLOBAL" "ac_cv_have_decl_RTLD_GLOBAL" "#include <dlfcn.h>
17256" "$ac_c_undeclared_builtin_options" "CFLAGS"
17257if test "x$ac_cv_have_decl_RTLD_GLOBAL" = xyes
17258then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017259 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017260else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017261 ac_have_decl=0
17262fi
Pablo Galindoba421752021-05-03 20:33:17 +010017263printf "%s\n" "#define HAVE_DECL_RTLD_GLOBAL $ac_have_decl" >>confdefs.h
17264ac_fn_check_decl "$LINENO" "RTLD_LOCAL" "ac_cv_have_decl_RTLD_LOCAL" "#include <dlfcn.h>
17265" "$ac_c_undeclared_builtin_options" "CFLAGS"
17266if test "x$ac_cv_have_decl_RTLD_LOCAL" = xyes
17267then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017268 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017269else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017270 ac_have_decl=0
17271fi
Pablo Galindoba421752021-05-03 20:33:17 +010017272printf "%s\n" "#define HAVE_DECL_RTLD_LOCAL $ac_have_decl" >>confdefs.h
17273ac_fn_check_decl "$LINENO" "RTLD_NODELETE" "ac_cv_have_decl_RTLD_NODELETE" "#include <dlfcn.h>
17274" "$ac_c_undeclared_builtin_options" "CFLAGS"
17275if test "x$ac_cv_have_decl_RTLD_NODELETE" = xyes
17276then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017277 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017278else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017279 ac_have_decl=0
17280fi
Pablo Galindoba421752021-05-03 20:33:17 +010017281printf "%s\n" "#define HAVE_DECL_RTLD_NODELETE $ac_have_decl" >>confdefs.h
17282ac_fn_check_decl "$LINENO" "RTLD_NOLOAD" "ac_cv_have_decl_RTLD_NOLOAD" "#include <dlfcn.h>
17283" "$ac_c_undeclared_builtin_options" "CFLAGS"
17284if test "x$ac_cv_have_decl_RTLD_NOLOAD" = xyes
17285then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017286 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017287else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017288 ac_have_decl=0
17289fi
Pablo Galindoba421752021-05-03 20:33:17 +010017290printf "%s\n" "#define HAVE_DECL_RTLD_NOLOAD $ac_have_decl" >>confdefs.h
17291ac_fn_check_decl "$LINENO" "RTLD_DEEPBIND" "ac_cv_have_decl_RTLD_DEEPBIND" "#include <dlfcn.h>
17292" "$ac_c_undeclared_builtin_options" "CFLAGS"
17293if test "x$ac_cv_have_decl_RTLD_DEEPBIND" = xyes
17294then :
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017295 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017296else $as_nop
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017297 ac_have_decl=0
17298fi
Pablo Galindoba421752021-05-03 20:33:17 +010017299printf "%s\n" "#define HAVE_DECL_RTLD_DEEPBIND $ac_have_decl" >>confdefs.h
17300ac_fn_check_decl "$LINENO" "RTLD_MEMBER" "ac_cv_have_decl_RTLD_MEMBER" "#include <dlfcn.h>
17301" "$ac_c_undeclared_builtin_options" "CFLAGS"
17302if test "x$ac_cv_have_decl_RTLD_MEMBER" = xyes
17303then :
Michael Feltc5ae1692017-12-19 13:58:49 +010017304 ac_have_decl=1
Pablo Galindoba421752021-05-03 20:33:17 +010017305else $as_nop
Michael Feltc5ae1692017-12-19 13:58:49 +010017306 ac_have_decl=0
17307fi
Pablo Galindoba421752021-05-03 20:33:17 +010017308printf "%s\n" "#define HAVE_DECL_RTLD_MEMBER $ac_have_decl" >>confdefs.h
Serhiy Storchakac2f7d872016-05-04 09:44:44 +030017309
17310
Mark Dickinsonbd792642009-03-18 20:06:12 +000017311# determine what size digit to use for Python's longs
Pablo Galindoba421752021-05-03 20:33:17 +010017312{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5
17313printf %s "checking digit size for Python's longs... " >&6; }
Mark Dickinsonbd792642009-03-18 20:06:12 +000017314# Check whether --enable-big-digits was given.
Pablo Galindoba421752021-05-03 20:33:17 +010017315if test ${enable_big_digits+y}
17316then :
Mark Dickinsonbd792642009-03-18 20:06:12 +000017317 enableval=$enable_big_digits; case $enable_big_digits in
17318yes)
17319 enable_big_digits=30 ;;
17320no)
17321 enable_big_digits=15 ;;
1732215|30)
17323 ;;
17324*)
Victor Stinnere0be4232011-10-25 13:06:09 +020017325 as_fn_error $? "bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" "$LINENO" 5 ;;
Mark Dickinsonbd792642009-03-18 20:06:12 +000017326esac
Pablo Galindoba421752021-05-03 20:33:17 +010017327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5
17328printf "%s\n" "$enable_big_digits" >&6; }
Mark Dickinsonbd792642009-03-18 20:06:12 +000017329
Pablo Galindoba421752021-05-03 20:33:17 +010017330printf "%s\n" "#define PYLONG_BITS_IN_DIGIT $enable_big_digits" >>confdefs.h
Mark Dickinsonbd792642009-03-18 20:06:12 +000017331
17332
Pablo Galindoba421752021-05-03 20:33:17 +010017333else $as_nop
17334 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5
17335printf "%s\n" "no value specified" >&6; }
Mark Dickinsonbd792642009-03-18 20:06:12 +000017336fi
17337
17338
Guido van Rossumef2255b2000-03-10 22:30:29 +000017339# check for wchar.h
Pablo Galindoba421752021-05-03 20:33:17 +010017340ac_fn_c_check_header_compile "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default"
17341if test "x$ac_cv_header_wchar_h" = xyes
17342then :
Martin v. Löwis11437992002-04-12 09:54:03 +000017343
17344
Pablo Galindoba421752021-05-03 20:33:17 +010017345printf "%s\n" "#define HAVE_WCHAR_H 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000017346
Martin v. Löwisc45929e2002-04-06 10:10:49 +000017347 wchar_h="yes"
17348
Pablo Galindoba421752021-05-03 20:33:17 +010017349else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000017350 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000017351
17352fi
17353
Michael W. Hudson54241132001-12-07 15:38:26 +000017354
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017355# determine wchar_t size
17356if test "$wchar_h" = yes
17357then
Matthias Kloseb9621712010-04-24 17:59:49 +000017358 # The cast to long int works around a bug in the HP C Compiler
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017359# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17360# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17361# This bug is HP SR number 8606223364.
Pablo Galindoba421752021-05-03 20:33:17 +010017362{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5
17363printf %s "checking size of wchar_t... " >&6; }
17364if test ${ac_cv_sizeof_wchar_t+y}
17365then :
17366 printf %s "(cached) " >&6
17367else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017368 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h>
Pablo Galindoba421752021-05-03 20:33:17 +010017369"
17370then :
Martin v. Löwis11437992002-04-12 09:54:03 +000017371
Pablo Galindoba421752021-05-03 20:33:17 +010017372else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017373 if test "$ac_cv_type_wchar_t" = yes; then
Pablo Galindoba421752021-05-03 20:33:17 +010017374 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17375printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020017376as_fn_error 77 "cannot compute sizeof (wchar_t)
Victor Stinnere0be4232011-10-25 13:06:09 +020017377See \`config.log' for more details" "$LINENO" 5; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017378 else
17379 ac_cv_sizeof_wchar_t=0
17380 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017381fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017382
Martin v. Löwis11437992002-04-12 09:54:03 +000017383fi
Pablo Galindoba421752021-05-03 20:33:17 +010017384{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5
17385printf "%s\n" "$ac_cv_sizeof_wchar_t" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017386
17387
17388
Pablo Galindoba421752021-05-03 20:33:17 +010017389printf "%s\n" "#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t" >>confdefs.h
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017390
Michael W. Hudson54241132001-12-07 15:38:26 +000017391
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017392fi
17393
Pablo Galindoba421752021-05-03 20:33:17 +010017394{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5
17395printf %s "checking for UCS-4 tcl... " >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017396have_ucs4_tcl=no
Matthias Kloseb9621712010-04-24 17:59:49 +000017397cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017398/* end confdefs.h. */
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017399
17400#include <tcl.h>
17401#if TCL_UTF_MAX != 6
17402# error "NOT UCS4_TCL"
17403#endif
17404int
Pablo Galindoba421752021-05-03 20:33:17 +010017405main (void)
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017406{
17407
17408 ;
17409 return 0;
17410}
17411_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017412if ac_fn_c_try_compile "$LINENO"
17413then :
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017414
17415
Pablo Galindoba421752021-05-03 20:33:17 +010017416printf "%s\n" "#define HAVE_UCS4_TCL 1" >>confdefs.h
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017417
17418 have_ucs4_tcl=yes
17419
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017420fi
Pablo Galindoba421752021-05-03 20:33:17 +010017421rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17422{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5
17423printf "%s\n" "$have_ucs4_tcl" >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000017424
Skip Montanaro6dead952003-09-25 14:50:04 +000017425# check whether wchar_t is signed or not
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017426if test "$wchar_h" = yes
17427then
17428 # check whether wchar_t is signed or not
Pablo Galindoba421752021-05-03 20:33:17 +010017429 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5
17430printf %s "checking whether wchar_t is signed... " >&6; }
17431 if test ${ac_cv_wchar_t_signed+y}
17432then :
17433 printf %s "(cached) " >&6
17434else $as_nop
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017435
Pablo Galindoba421752021-05-03 20:33:17 +010017436 if test "$cross_compiling" = yes
17437then :
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017438 ac_cv_wchar_t_signed=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017439else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017440 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017441/* end confdefs.h. */
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017442
17443 #include <wchar.h>
17444 int main()
17445 {
Thomas Wouters49fd7fa2006-04-21 10:40:58 +000017446 /* Success: exit code 0 */
Joshua Root674fa0a2020-12-14 07:56:34 +110017447 return ((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1);
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017448 }
17449
17450_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017451if ac_fn_c_try_run "$LINENO"
17452then :
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017453 ac_cv_wchar_t_signed=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017454else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017455 ac_cv_wchar_t_signed=no
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017456fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017457rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17458 conftest.$ac_objext conftest.beam conftest.$ac_ext
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017459fi
17460
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000017461fi
17462
Pablo Galindoba421752021-05-03 20:33:17 +010017463 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5
17464printf "%s\n" "$ac_cv_wchar_t_signed" >&6; }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017465fi
17466
Pablo Galindoba421752021-05-03 20:33:17 +010017467{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is usable" >&5
17468printf %s "checking whether wchar_t is usable... " >&6; }
Georg Brandl52d168a2008-01-07 18:10:24 +000017469# wchar_t is only usable if it maps to an unsigned type
Martin v. Löwisd63a3b82011-09-28 07:41:54 +020017470if test "$ac_cv_sizeof_wchar_t" -ge 2 \
Matthias Klose7dbeed72004-12-24 08:22:17 +000017471 -a "$ac_cv_wchar_t_signed" = "no"
Georg Brandl52d168a2008-01-07 18:10:24 +000017472then
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017473
Pablo Galindoba421752021-05-03 20:33:17 +010017474printf "%s\n" "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +000017475
Pablo Galindoba421752021-05-03 20:33:17 +010017476 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17477printf "%s\n" "yes" >&6; }
Georg Brandl52d168a2008-01-07 18:10:24 +000017478else
Pablo Galindoba421752021-05-03 20:33:17 +010017479 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17480printf "%s\n" "no" >&6; }
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017481fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000017482
Jakub Kulík9032cf52021-04-30 15:21:42 +020017483case $ac_sys_system/$ac_sys_release in
17484SunOS/*)
17485 if test -f /etc/os-release; then
17486 OS_NAME=$(awk -F= '/^NAME=/ {print substr($2,2,length($2)-2)}' /etc/os-release)
17487 if test "x$OS_NAME" = "xOracle Solaris"; then
17488 # bpo-43667: In Oracle Solaris, the internal form of wchar_t in
17489 # non-Unicode locales is not Unicode and hence cannot be used directly.
17490 # https://docs.oracle.com/cd/E37838_01/html/E61053/gmwke.html
17491
Pablo Galindoba421752021-05-03 20:33:17 +010017492printf "%s\n" "#define HAVE_NON_UNICODE_WCHAR_T_REPRESENTATION 1" >>confdefs.h
Jakub Kulík9032cf52021-04-30 15:21:42 +020017493
17494 fi
17495 fi
17496 ;;
17497esac
17498
Guido van Rossumef2255b2000-03-10 22:30:29 +000017499# check for endianness
Pablo Galindoba421752021-05-03 20:33:17 +010017500 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17501printf %s "checking whether byte ordering is bigendian... " >&6; }
17502if test ${ac_cv_c_bigendian+y}
17503then :
17504 printf %s "(cached) " >&6
17505else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017506 ac_cv_c_bigendian=unknown
17507 # See if we're dealing with a universal compiler.
17508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17509/* end confdefs.h. */
17510#ifndef __APPLE_CC__
17511 not a universal capable compiler
17512 #endif
17513 typedef int dummy;
17514
Skip Montanaro6dead952003-09-25 14:50:04 +000017515_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017516if ac_fn_c_try_compile "$LINENO"
17517then :
Matthias Kloseb9621712010-04-24 17:59:49 +000017518
17519 # Check for potential -arch flags. It is not universal unless
17520 # there are at least two -arch flags with different values.
17521 ac_arch=
17522 ac_prev=
17523 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
17524 if test -n "$ac_prev"; then
17525 case $ac_word in
17526 i?86 | x86_64 | ppc | ppc64)
17527 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
17528 ac_arch=$ac_word
17529 else
17530 ac_cv_c_bigendian=universal
17531 break
17532 fi
17533 ;;
17534 esac
17535 ac_prev=
17536 elif test "x$ac_word" = "x-arch"; then
17537 ac_prev=arch
17538 fi
17539 done
17540fi
Pablo Galindoba421752021-05-03 20:33:17 +010017541rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +000017542 if test $ac_cv_c_bigendian = unknown; then
17543 # See if sys/param.h defines the BYTE_ORDER macro.
17544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017545/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000017546#include <sys/types.h>
Matthias Kloseb9621712010-04-24 17:59:49 +000017547 #include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000017548
Martin v. Löwis11437992002-04-12 09:54:03 +000017549int
Pablo Galindoba421752021-05-03 20:33:17 +010017550main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000017551{
Matthias Kloseb9621712010-04-24 17:59:49 +000017552#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
17553 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
17554 && LITTLE_ENDIAN)
17555 bogus endian macros
17556 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000017557
17558 ;
17559 return 0;
17560}
17561_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017562if ac_fn_c_try_compile "$LINENO"
17563then :
Guido van Rossumef2255b2000-03-10 22:30:29 +000017564 # It does; now see whether it defined to BIG_ENDIAN or not.
Matthias Kloseb9621712010-04-24 17:59:49 +000017565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017566/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000017567#include <sys/types.h>
Matthias Kloseb9621712010-04-24 17:59:49 +000017568 #include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000017569
Martin v. Löwis11437992002-04-12 09:54:03 +000017570int
Pablo Galindoba421752021-05-03 20:33:17 +010017571main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000017572{
Guido van Rossumef2255b2000-03-10 22:30:29 +000017573#if BYTE_ORDER != BIG_ENDIAN
Matthias Kloseb9621712010-04-24 17:59:49 +000017574 not big endian
17575 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000017576
17577 ;
17578 return 0;
17579}
17580_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017581if ac_fn_c_try_compile "$LINENO"
17582then :
Guido van Rossumef2255b2000-03-10 22:30:29 +000017583 ac_cv_c_bigendian=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017584else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017585 ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000017586fi
Pablo Galindoba421752021-05-03 20:33:17 +010017587rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +000017588fi
Pablo Galindoba421752021-05-03 20:33:17 +010017589rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +000017590 fi
17591 if test $ac_cv_c_bigendian = unknown; then
17592 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
17593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017594/* end confdefs.h. */
Matthias Kloseb9621712010-04-24 17:59:49 +000017595#include <limits.h>
17596
Martin v. Löwis11437992002-04-12 09:54:03 +000017597int
Pablo Galindoba421752021-05-03 20:33:17 +010017598main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000017599{
Matthias Kloseb9621712010-04-24 17:59:49 +000017600#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
17601 bogus endian macros
17602 #endif
17603
Martin v. Löwis11437992002-04-12 09:54:03 +000017604 ;
17605 return 0;
17606}
17607_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017608if ac_fn_c_try_compile "$LINENO"
17609then :
Matthias Kloseb9621712010-04-24 17:59:49 +000017610 # It does; now see whether it defined to _BIG_ENDIAN or not.
17611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17612/* end confdefs.h. */
17613#include <limits.h>
17614
17615int
Pablo Galindoba421752021-05-03 20:33:17 +010017616main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +000017617{
17618#ifndef _BIG_ENDIAN
17619 not big endian
17620 #endif
17621
17622 ;
17623 return 0;
17624}
17625_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017626if ac_fn_c_try_compile "$LINENO"
17627then :
Martin v. Löwis11437992002-04-12 09:54:03 +000017628 ac_cv_c_bigendian=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017629else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017630 ac_cv_c_bigendian=no
Martin v. Löwis11437992002-04-12 09:54:03 +000017631fi
Pablo Galindoba421752021-05-03 20:33:17 +010017632rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +000017633fi
Pablo Galindoba421752021-05-03 20:33:17 +010017634rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Matthias Kloseb9621712010-04-24 17:59:49 +000017635 fi
17636 if test $ac_cv_c_bigendian = unknown; then
17637 # Compile a test program.
Pablo Galindoba421752021-05-03 20:33:17 +010017638 if test "$cross_compiling" = yes
17639then :
Matthias Kloseb9621712010-04-24 17:59:49 +000017640 # Try to guess by grepping values from an object file.
17641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17642/* end confdefs.h. */
Pablo Galindoba421752021-05-03 20:33:17 +010017643unsigned short int ascii_mm[] =
Matthias Kloseb9621712010-04-24 17:59:49 +000017644 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
Pablo Galindoba421752021-05-03 20:33:17 +010017645 unsigned short int ascii_ii[] =
Matthias Kloseb9621712010-04-24 17:59:49 +000017646 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17647 int use_ascii (int i) {
17648 return ascii_mm[i] + ascii_ii[i];
17649 }
Pablo Galindoba421752021-05-03 20:33:17 +010017650 unsigned short int ebcdic_ii[] =
Matthias Kloseb9621712010-04-24 17:59:49 +000017651 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
Pablo Galindoba421752021-05-03 20:33:17 +010017652 unsigned short int ebcdic_mm[] =
Matthias Kloseb9621712010-04-24 17:59:49 +000017653 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17654 int use_ebcdic (int i) {
17655 return ebcdic_mm[i] + ebcdic_ii[i];
17656 }
17657 extern int foo;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017658
Matthias Kloseb9621712010-04-24 17:59:49 +000017659int
Pablo Galindoba421752021-05-03 20:33:17 +010017660main (void)
Matthias Kloseb9621712010-04-24 17:59:49 +000017661{
17662return use_ascii (foo) == use_ebcdic (foo);
17663 ;
17664 return 0;
17665}
17666_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017667if ac_fn_c_try_compile "$LINENO"
17668then :
Matthias Kloseb9621712010-04-24 17:59:49 +000017669 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
17670 ac_cv_c_bigendian=yes
17671 fi
17672 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
17673 if test "$ac_cv_c_bigendian" = unknown; then
17674 ac_cv_c_bigendian=no
17675 else
17676 # finding both strings is unlikely to happen, but who knows?
17677 ac_cv_c_bigendian=unknown
17678 fi
17679 fi
17680fi
Pablo Galindoba421752021-05-03 20:33:17 +010017681rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17682else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017684/* end confdefs.h. */
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017685$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000017686int
Pablo Galindoba421752021-05-03 20:33:17 +010017687main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000017688{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017689
Matthias Kloseb9621712010-04-24 17:59:49 +000017690 /* Are we little or big endian? From Harbison&Steele. */
17691 union
17692 {
17693 long int l;
17694 char c[sizeof (long int)];
17695 } u;
17696 u.l = 1;
17697 return u.c[sizeof (long int) - 1] == 1;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017698
17699 ;
17700 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000017701}
Martin v. Löwis11437992002-04-12 09:54:03 +000017702_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017703if ac_fn_c_try_run "$LINENO"
17704then :
Guido van Rossumef2255b2000-03-10 22:30:29 +000017705 ac_cv_c_bigendian=no
Pablo Galindoba421752021-05-03 20:33:17 +010017706else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017707 ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000017708fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017709rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17710 conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000017711fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017712
Matthias Kloseb9621712010-04-24 17:59:49 +000017713 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017714fi
Pablo Galindoba421752021-05-03 20:33:17 +010017715{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
17716printf "%s\n" "$ac_cv_c_bigendian" >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000017717 case $ac_cv_c_bigendian in #(
17718 yes)
Pablo Galindoba421752021-05-03 20:33:17 +010017719 printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h
Matthias Kloseb9621712010-04-24 17:59:49 +000017720;; #(
17721 no)
17722 ;; #(
17723 universal)
Ronald Oussoren74f29b42009-09-20 20:09:26 +000017724
Pablo Galindoba421752021-05-03 20:33:17 +010017725printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
Benjamin Peterson8719ad52009-09-11 22:24:02 +000017726
Matthias Kloseb9621712010-04-24 17:59:49 +000017727 ;; #(
17728 *)
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020017729 as_fn_error $? "unknown endianness
Victor Stinnere0be4232011-10-25 13:06:09 +020017730 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
Matthias Kloseb9621712010-04-24 17:59:49 +000017731 esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000017732
Michael W. Hudson54241132001-12-07 15:38:26 +000017733
Barry Warsaw35f3a2c2010-09-03 18:30:30 +000017734# ABI version string for Python extension modules. This appears between the
17735# periods in shared library file names, e.g. foo.<SOABI>.so. It is calculated
17736# from the following attributes which affect the ABI of this Python build (in
17737# this order):
17738#
17739# * The Python implementation (always 'cpython-' for us)
17740# * The major and minor version numbers
17741# * --with-pydebug (adds a 'd')
Barry Warsaw35f3a2c2010-09-03 18:30:30 +000017742#
17743# Thus for example, Python 3.2 built with wide unicode, pydebug, and pymalloc,
Benjamin Petersond7f73e92010-09-05 00:09:07 +000017744# would get a shared library ABI version tag of 'cpython-32dmu' and shared
17745# libraries would be named 'foo.cpython-32dmu.so'.
Victor Stinner6c44fde2019-04-24 16:10:09 +020017746#
17747# In Python 3.2 and older, --with-wide-unicode added a 'u' flag.
17748# In Python 3.7 and older, --with-pymalloc added a 'm' flag.
Barry Warsaw35f3a2c2010-09-03 18:30:30 +000017749
Pablo Galindoba421752021-05-03 20:33:17 +010017750{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking ABIFLAGS" >&5
17751printf %s "checking ABIFLAGS... " >&6; }
17752{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ABIFLAGS" >&5
17753printf "%s\n" "$ABIFLAGS" >&6; }
17754{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5
17755printf %s "checking SOABI... " >&6; }
doko@ubuntu.comd3899c12015-04-15 20:23:14 +020017756SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS}${PLATFORM_TRIPLET:+-$PLATFORM_TRIPLET}
Pablo Galindoba421752021-05-03 20:33:17 +010017757{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5
17758printf "%s\n" "$SOABI" >&6; }
Barry Warsaw35f3a2c2010-09-03 18:30:30 +000017759
Victor Stinner6d13e5b2019-04-26 18:56:19 +020017760# Release and debug (Py_DEBUG) ABI are compatible, but not Py_TRACE_REFS ABI
17761if test "$Py_DEBUG" = 'true' -a "$with_trace_refs" != "yes"; then
Victor Stinner5422e3c2019-04-26 01:40:00 +020017762 # Similar to SOABI but remove "d" flag from ABIFLAGS
17763
17764 ALT_SOABI='cpython-'`echo $VERSION | tr -d .``echo $ABIFLAGS | tr -d d`${PLATFORM_TRIPLET:+-$PLATFORM_TRIPLET}
17765
Pablo Galindoba421752021-05-03 20:33:17 +010017766printf "%s\n" "#define ALT_SOABI \"${ALT_SOABI}\"" >>confdefs.h
Victor Stinner5422e3c2019-04-26 01:40:00 +020017767
17768fi
17769
Victor Stinner52a327c2020-12-23 03:41:08 +010017770
Matti Picusa44ce6c2020-12-20 04:56:57 +020017771EXT_SUFFIX=.${SOABI}${SHLIB_SUFFIX}
doko@ubuntu.comd5537d02013-03-21 13:21:49 -070017772
Pablo Galindoba421752021-05-03 20:33:17 +010017773{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5
17774printf %s "checking LDVERSION... " >&6; }
Barry Warsaw8cf4eae2010-10-16 01:04:07 +000017775LDVERSION='$(VERSION)$(ABIFLAGS)'
Pablo Galindoba421752021-05-03 20:33:17 +010017776{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5
17777printf "%s\n" "$LDVERSION" >&6; }
Barry Warsaw8cf4eae2010-10-16 01:04:07 +000017778
E. M. Brayc994c8f2019-05-24 17:33:47 +020017779# On Android and Cygwin the shared libraries must be linked with libpython.
xdegaye254b3092019-04-29 09:27:40 +020017780
E. M. Brayb1fc4172019-05-24 18:39:39 +020017781if test -n "$ANDROID_API_LEVEL" -o "$MACHDEP" = "cygwin"; then
xdegaye254b3092019-04-29 09:27:40 +020017782 LIBPYTHON="-lpython${VERSION}${ABIFLAGS}"
E. M. Brayb1fc4172019-05-24 18:39:39 +020017783else
17784 LIBPYTHON=''
xdegaye254b3092019-04-29 09:27:40 +020017785fi
17786
doko@python.org87421192013-01-26 11:39:31 +010017787
Victor Stinner51ae31e2020-06-09 15:32:43 +020017788
17789BINLIBDEST='$(LIBDIR)/python$(VERSION)'
17790
17791
17792# Check for --with-platlibdir
Victor Stinner8510f432020-03-10 09:53:09 +010017793# /usr/$LIDIRNAME/python$VERSION
17794
17795PLATLIBDIR="lib"
Pablo Galindoba421752021-05-03 20:33:17 +010017796{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-platlibdir" >&5
17797printf %s "checking for --with-platlibdir... " >&6; }
Victor Stinner8510f432020-03-10 09:53:09 +010017798
17799# Check whether --with-platlibdir was given.
Pablo Galindoba421752021-05-03 20:33:17 +010017800if test ${with_platlibdir+y}
17801then :
Victor Stinner8510f432020-03-10 09:53:09 +010017802 withval=$with_platlibdir;
17803# ignore 3 options:
17804# --with-platlibdir
17805# --with-platlibdir=
17806# --without-platlibdir
17807if test -n "$withval" -a "$withval" != yes -a "$withval" != no
17808then
Pablo Galindoba421752021-05-03 20:33:17 +010017809 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17810printf "%s\n" "yes" >&6; }
Victor Stinner8510f432020-03-10 09:53:09 +010017811 PLATLIBDIR="$withval"
Victor Stinner51ae31e2020-06-09 15:32:43 +020017812 BINLIBDEST='${exec_prefix}/${PLATLIBDIR}/python$(VERSION)'
doko@ubuntu.com55532312016-06-14 08:55:19 +020017813else
Pablo Galindoba421752021-05-03 20:33:17 +010017814 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17815printf "%s\n" "no" >&6; }
Victor Stinner8510f432020-03-10 09:53:09 +010017816fi
Pablo Galindoba421752021-05-03 20:33:17 +010017817else $as_nop
17818 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17819printf "%s\n" "no" >&6; }
Victor Stinner8510f432020-03-10 09:53:09 +010017820fi
17821
17822
17823
17824
17825if test x$PLATFORM_TRIPLET = x; then
17826 LIBPL='$(prefix)'"/${PLATLIBDIR}/python${VERSION}/config-${LDVERSION}"
17827else
17828 LIBPL='$(prefix)'"/${PLATLIBDIR}/python${VERSION}/config-${LDVERSION}-${PLATFORM_TRIPLET}"
doko@ubuntu.com55532312016-06-14 08:55:19 +020017829fi
doko@python.org87421192013-01-26 11:39:31 +010017830
17831
Victor Stinner75e59a92021-01-20 17:07:21 +010017832# Check for --with-wheel-pkg-dir=PATH
17833
17834WHEEL_PKG_DIR=""
Pablo Galindoba421752021-05-03 20:33:17 +010017835{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-wheel-pkg-dir" >&5
17836printf %s "checking for --with-wheel-pkg-dir... " >&6; }
Victor Stinner75e59a92021-01-20 17:07:21 +010017837
17838# Check whether --with-wheel-pkg-dir was given.
Pablo Galindoba421752021-05-03 20:33:17 +010017839if test ${with_wheel_pkg_dir+y}
17840then :
Victor Stinner75e59a92021-01-20 17:07:21 +010017841 withval=$with_wheel_pkg_dir;
17842if test -n "$withval"; then
Pablo Galindoba421752021-05-03 20:33:17 +010017843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17844printf "%s\n" "yes" >&6; }
Victor Stinner75e59a92021-01-20 17:07:21 +010017845 WHEEL_PKG_DIR="$withval"
17846else
Pablo Galindoba421752021-05-03 20:33:17 +010017847 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17848printf "%s\n" "no" >&6; }
Victor Stinner75e59a92021-01-20 17:07:21 +010017849fi
Pablo Galindoba421752021-05-03 20:33:17 +010017850else $as_nop
17851 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17852printf "%s\n" "no" >&6; }
Victor Stinner75e59a92021-01-20 17:07:21 +010017853fi
17854
17855
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017856# Check whether right shifting a negative integer extends the sign bit
17857# or fills with zeros (like the Cray J90, according to Tim Peters).
Pablo Galindoba421752021-05-03 20:33:17 +010017858{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5
17859printf %s "checking whether right shift extends the sign bit... " >&6; }
17860if test ${ac_cv_rshift_extends_sign+y}
17861then :
17862 printf %s "(cached) " >&6
17863else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000017864
Pablo Galindoba421752021-05-03 20:33:17 +010017865if test "$cross_compiling" = yes
17866then :
Guido van Rossum3065c942001-09-17 04:03:14 +000017867 ac_cv_rshift_extends_sign=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017868else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017870/* end confdefs.h. */
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017871
17872int main()
17873{
Joshua Root674fa0a2020-12-14 07:56:34 +110017874 return (((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017875}
17876
Martin v. Löwis11437992002-04-12 09:54:03 +000017877_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017878if ac_fn_c_try_run "$LINENO"
17879then :
Vladimir Marangozova6180282000-07-12 05:05:06 +000017880 ac_cv_rshift_extends_sign=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017881else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017882 ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000017883fi
Matthias Kloseb9621712010-04-24 17:59:49 +000017884rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17885 conftest.$ac_objext conftest.beam conftest.$ac_ext
Vladimir Marangozova6180282000-07-12 05:05:06 +000017886fi
17887
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017888fi
17889
Pablo Galindoba421752021-05-03 20:33:17 +010017890{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5
17891printf "%s\n" "$ac_cv_rshift_extends_sign" >&6; }
Vladimir Marangozova6180282000-07-12 05:05:06 +000017892if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017893then
Martin v. Löwis11437992002-04-12 09:54:03 +000017894
Pablo Galindoba421752021-05-03 20:33:17 +010017895printf "%s\n" "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017896
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017897fi
17898
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017899# check for getc_unlocked and related locking functions
Pablo Galindoba421752021-05-03 20:33:17 +010017900{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5
17901printf %s "checking for getc_unlocked() and friends... " >&6; }
17902if test ${ac_cv_have_getc_unlocked+y}
17903then :
17904 printf %s "(cached) " >&6
17905else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000017906
Matthias Kloseb9621712010-04-24 17:59:49 +000017907cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000017908/* end confdefs.h. */
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017909#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000017910int
Pablo Galindoba421752021-05-03 20:33:17 +010017911main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000017912{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017913
17914 FILE *f = fopen("/dev/null", "r");
17915 flockfile(f);
17916 getc_unlocked(f);
17917 funlockfile(f);
17918
Martin v. Löwis11437992002-04-12 09:54:03 +000017919 ;
17920 return 0;
17921}
17922_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010017923if ac_fn_c_try_link "$LINENO"
17924then :
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017925 ac_cv_have_getc_unlocked=yes
Pablo Galindoba421752021-05-03 20:33:17 +010017926else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000017927 ac_cv_have_getc_unlocked=no
17928fi
Pablo Galindoba421752021-05-03 20:33:17 +010017929rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000017930 conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017931fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017932
Pablo Galindoba421752021-05-03 20:33:17 +010017933{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5
17934printf "%s\n" "$ac_cv_have_getc_unlocked" >&6; }
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017935if test "$ac_cv_have_getc_unlocked" = yes
17936then
Martin v. Löwis11437992002-04-12 09:54:03 +000017937
Pablo Galindoba421752021-05-03 20:33:17 +010017938printf "%s\n" "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017939
17940fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017941
Roland Hiebere1f77692021-02-09 02:05:25 +010017942
17943# Check whether --with-readline was given.
Pablo Galindoba421752021-05-03 20:33:17 +010017944if test ${with_readline+y}
17945then :
Roland Hiebere1f77692021-02-09 02:05:25 +010017946 withval=$with_readline;
Pablo Galindoba421752021-05-03 20:33:17 +010017947else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010017948 with_readline=yes
17949fi
17950
17951
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017952# check where readline lives
Roland Hiebere1f77692021-02-09 02:05:25 +010017953py_cv_lib_readline=no
Martin v. Löwis82bca632006-02-10 20:49:30 +000017954# save the value of LIBS so we don't actually link Python with readline
17955LIBS_no_readline=$LIBS
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017956
Roland Hiebere1f77692021-02-09 02:05:25 +010017957if test "$with_readline" != no; then
17958 case "$with_readline" in
17959 editline|edit)
17960 LIBREADLINE=edit
17961
Pablo Galindoba421752021-05-03 20:33:17 +010017962printf "%s\n" "#define WITH_EDITLINE 1" >>confdefs.h
Roland Hiebere1f77692021-02-09 02:05:25 +010017963
17964 ;;
17965 yes|readline)
17966 LIBREADLINE=readline
17967 ;;
17968 *)
17969 as_fn_error $? "proper usage is --with(out)-readline[=editline]" "$LINENO" 5
17970 ;;
17971 esac
17972
17973 # On some systems we need to link readline to a termcap compatible
17974 # library. NOTE: Keep the precedence of listed libraries synchronised
17975 # with setup.py.
Pablo Galindoba421752021-05-03 20:33:17 +010017976 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5
17977printf %s "checking how to link readline libs... " >&6; }
Roland Hiebere1f77692021-02-09 02:05:25 +010017978 for py_libtermcap in "" tinfo ncursesw ncurses curses termcap; do
17979 if test -z "$py_libtermcap"; then
17980 READLINE_LIBS="-l$LIBREADLINE"
17981 else
17982 READLINE_LIBS="-l$LIBREADLINE -l$py_libtermcap"
17983 fi
17984 LIBS="$READLINE_LIBS $LIBS_no_readline"
17985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017986/* end confdefs.h. */
17987
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017988/* Override any GCC internal prototype to avoid an error.
17989 Use char because int might match the return type of a GCC
17990 builtin and then its argument prototype would still apply. */
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017991char readline ();
17992int
Pablo Galindoba421752021-05-03 20:33:17 +010017993main (void)
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017994{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000017995return readline ();
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000017996 ;
17997 return 0;
17998}
17999_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018000if ac_fn_c_try_link "$LINENO"
18001then :
Gregory P. Smith18820942008-09-07 06:24:49 +000018002 py_cv_lib_readline=yes
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000018003fi
Pablo Galindoba421752021-05-03 20:33:17 +010018004rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000018005 conftest$ac_exeext conftest.$ac_ext
Roland Hiebere1f77692021-02-09 02:05:25 +010018006 if test $py_cv_lib_readline = yes; then
18007 break
18008 fi
18009 done
18010
18011 # Uncomment this line if you want to use READLINE_LIBS in Makefile or scripts
18012 #AC_SUBST([READLINE_LIBS])
18013 if test $py_cv_lib_readline = no; then
Pablo Galindoba421752021-05-03 20:33:17 +010018014 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
18015printf "%s\n" "none" >&6; }
Roland Hiebere1f77692021-02-09 02:05:25 +010018016 else
Pablo Galindoba421752021-05-03 20:33:17 +010018017 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5
18018printf "%s\n" "$READLINE_LIBS" >&6; }
Gregory P. Smith18820942008-09-07 06:24:49 +000018019
Pablo Galindoba421752021-05-03 20:33:17 +010018020printf "%s\n" "#define HAVE_LIBREADLINE 1" >>confdefs.h
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000018021
Roland Hiebere1f77692021-02-09 02:05:25 +010018022 fi
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000018023fi
18024
Roland Hiebere1f77692021-02-09 02:05:25 +010018025if test "$py_cv_lib_readline" = yes; then
18026 # check for readline 2.2
Pablo Galindoba421752021-05-03 20:33:17 +010018027 ac_fn_check_decl "$LINENO" "rl_completion_append_character" "ac_cv_have_decl_rl_completion_append_character" "
Roland Hiebere1f77692021-02-09 02:05:25 +010018028#include <stdio.h> /* Must be first for Gnu Readline */
18029#ifdef WITH_EDITLINE
18030# include <editline/readline.h>
18031#else
18032# include <readline/readline.h>
18033#endif
Matthias Kloseb159a552010-04-25 21:00:44 +000018034
Pablo Galindoba421752021-05-03 20:33:17 +010018035" "$ac_c_undeclared_builtin_options" "CFLAGS"
18036if test "x$ac_cv_have_decl_rl_completion_append_character" = xyes
18037then :
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000018038
Pablo Galindoba421752021-05-03 20:33:17 +010018039printf "%s\n" "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000018040
18041fi
Pablo Galindoba421752021-05-03 20:33:17 +010018042 ac_fn_check_decl "$LINENO" "rl_completion_suppress_append" "ac_cv_have_decl_rl_completion_suppress_append" "
Roland Hiebere1f77692021-02-09 02:05:25 +010018043#include <stdio.h> /* Must be first for Gnu Readline */
18044#ifdef WITH_EDITLINE
18045# include <editline/readline.h>
18046#else
18047# include <readline/readline.h>
18048#endif
Antoine Pitroud5131772009-10-26 19:22:14 +000018049
Pablo Galindoba421752021-05-03 20:33:17 +010018050" "$ac_c_undeclared_builtin_options" "CFLAGS"
18051if test "x$ac_cv_have_decl_rl_completion_suppress_append" = xyes
18052then :
Antoine Pitroud5131772009-10-26 19:22:14 +000018053
Pablo Galindoba421752021-05-03 20:33:17 +010018054printf "%s\n" "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h
Antoine Pitroud5131772009-10-26 19:22:14 +000018055
18056fi
Antoine Pitroud5131772009-10-26 19:22:14 +000018057
Roland Hiebere1f77692021-02-09 02:05:25 +010018058 # check for readline 4.0
Pablo Galindoba421752021-05-03 20:33:17 +010018059 as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIBREADLINE""_rl_pre_input_hook" | $as_tr_sh`
18060{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -l$LIBREADLINE" >&5
18061printf %s "checking for rl_pre_input_hook in -l$LIBREADLINE... " >&6; }
18062if eval test \${$as_ac_Lib+y}
18063then :
18064 printf %s "(cached) " >&6
18065else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000018066 ac_check_lib_save_LIBS=$LIBS
Roland Hiebere1f77692021-02-09 02:05:25 +010018067LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000018068cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018069/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018070
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018071/* Override any GCC internal prototype to avoid an error.
18072 Use char because int might match the return type of a GCC
18073 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018074char rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018075int
Pablo Galindoba421752021-05-03 20:33:17 +010018076main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000018077{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018078return rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018079 ;
18080 return 0;
18081}
18082_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018083if ac_fn_c_try_link "$LINENO"
18084then :
Roland Hiebere1f77692021-02-09 02:05:25 +010018085 eval "$as_ac_Lib=yes"
Pablo Galindoba421752021-05-03 20:33:17 +010018086else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010018087 eval "$as_ac_Lib=no"
Martin v. Löwis0daad592001-09-30 21:09:59 +000018088fi
Pablo Galindoba421752021-05-03 20:33:17 +010018089rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000018090 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018091LIBS=$ac_check_lib_save_LIBS
18092fi
Roland Hiebere1f77692021-02-09 02:05:25 +010018093eval ac_res=\$$as_ac_Lib
Pablo Galindoba421752021-05-03 20:33:17 +010018094 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18095printf "%s\n" "$ac_res" >&6; }
18096if eval test \"x\$"$as_ac_Lib"\" = x"yes"
18097then :
Michael W. Hudson54241132001-12-07 15:38:26 +000018098
Pablo Galindoba421752021-05-03 20:33:17 +010018099printf "%s\n" "#define HAVE_RL_PRE_INPUT_HOOK 1" >>confdefs.h
Martin v. Löwis0daad592001-09-30 21:09:59 +000018100
Martin v. Löwis0daad592001-09-30 21:09:59 +000018101fi
18102
Michael W. Hudson54241132001-12-07 15:38:26 +000018103
Roland Hiebere1f77692021-02-09 02:05:25 +010018104 # also in 4.0
Pablo Galindoba421752021-05-03 20:33:17 +010018105 as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIBREADLINE""_rl_completion_display_matches_hook" | $as_tr_sh`
18106{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -l$LIBREADLINE" >&5
18107printf %s "checking for rl_completion_display_matches_hook in -l$LIBREADLINE... " >&6; }
18108if eval test \${$as_ac_Lib+y}
18109then :
18110 printf %s "(cached) " >&6
18111else $as_nop
Thomas Wouters89d996e2007-09-08 17:39:28 +000018112 ac_check_lib_save_LIBS=$LIBS
Roland Hiebere1f77692021-02-09 02:05:25 +010018113LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000018114cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters89d996e2007-09-08 17:39:28 +000018115/* end confdefs.h. */
18116
18117/* Override any GCC internal prototype to avoid an error.
18118 Use char because int might match the return type of a GCC
18119 builtin and then its argument prototype would still apply. */
Thomas Wouters89d996e2007-09-08 17:39:28 +000018120char rl_completion_display_matches_hook ();
18121int
Pablo Galindoba421752021-05-03 20:33:17 +010018122main (void)
Thomas Wouters89d996e2007-09-08 17:39:28 +000018123{
18124return rl_completion_display_matches_hook ();
18125 ;
18126 return 0;
18127}
18128_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018129if ac_fn_c_try_link "$LINENO"
18130then :
Roland Hiebere1f77692021-02-09 02:05:25 +010018131 eval "$as_ac_Lib=yes"
Pablo Galindoba421752021-05-03 20:33:17 +010018132else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010018133 eval "$as_ac_Lib=no"
Thomas Wouters89d996e2007-09-08 17:39:28 +000018134fi
Pablo Galindoba421752021-05-03 20:33:17 +010018135rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000018136 conftest$ac_exeext conftest.$ac_ext
Thomas Wouters89d996e2007-09-08 17:39:28 +000018137LIBS=$ac_check_lib_save_LIBS
18138fi
Roland Hiebere1f77692021-02-09 02:05:25 +010018139eval ac_res=\$$as_ac_Lib
Pablo Galindoba421752021-05-03 20:33:17 +010018140 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18141printf "%s\n" "$ac_res" >&6; }
18142if eval test \"x\$"$as_ac_Lib"\" = x"yes"
18143then :
Thomas Wouters89d996e2007-09-08 17:39:28 +000018144
Pablo Galindoba421752021-05-03 20:33:17 +010018145printf "%s\n" "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h
Thomas Wouters89d996e2007-09-08 17:39:28 +000018146
18147fi
18148
18149
Roland Hiebere1f77692021-02-09 02:05:25 +010018150 # also in 4.0, but not in editline
Pablo Galindoba421752021-05-03 20:33:17 +010018151 as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIBREADLINE""_rl_resize_terminal" | $as_tr_sh`
18152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_resize_terminal in -l$LIBREADLINE" >&5
18153printf %s "checking for rl_resize_terminal in -l$LIBREADLINE... " >&6; }
18154if eval test \${$as_ac_Lib+y}
18155then :
18156 printf %s "(cached) " >&6
18157else $as_nop
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018158 ac_check_lib_save_LIBS=$LIBS
Roland Hiebere1f77692021-02-09 02:05:25 +010018159LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018160cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18161/* end confdefs.h. */
18162
18163/* Override any GCC internal prototype to avoid an error.
18164 Use char because int might match the return type of a GCC
18165 builtin and then its argument prototype would still apply. */
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018166char rl_resize_terminal ();
18167int
Pablo Galindoba421752021-05-03 20:33:17 +010018168main (void)
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018169{
18170return rl_resize_terminal ();
18171 ;
18172 return 0;
18173}
18174_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018175if ac_fn_c_try_link "$LINENO"
18176then :
Roland Hiebere1f77692021-02-09 02:05:25 +010018177 eval "$as_ac_Lib=yes"
Pablo Galindoba421752021-05-03 20:33:17 +010018178else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010018179 eval "$as_ac_Lib=no"
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018180fi
Pablo Galindoba421752021-05-03 20:33:17 +010018181rm -f core conftest.err conftest.$ac_objext conftest.beam \
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018182 conftest$ac_exeext conftest.$ac_ext
18183LIBS=$ac_check_lib_save_LIBS
18184fi
Roland Hiebere1f77692021-02-09 02:05:25 +010018185eval ac_res=\$$as_ac_Lib
Pablo Galindoba421752021-05-03 20:33:17 +010018186 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18187printf "%s\n" "$ac_res" >&6; }
18188if eval test \"x\$"$as_ac_Lib"\" = x"yes"
18189then :
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018190
Pablo Galindoba421752021-05-03 20:33:17 +010018191printf "%s\n" "#define HAVE_RL_RESIZE_TERMINAL 1" >>confdefs.h
Martin Panter5dbbf1a2016-04-03 02:54:58 +000018192
18193fi
18194
18195
Roland Hiebere1f77692021-02-09 02:05:25 +010018196 # check for readline 4.2
Pablo Galindoba421752021-05-03 20:33:17 +010018197 as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIBREADLINE""_rl_completion_matches" | $as_tr_sh`
18198{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -l$LIBREADLINE" >&5
18199printf %s "checking for rl_completion_matches in -l$LIBREADLINE... " >&6; }
18200if eval test \${$as_ac_Lib+y}
18201then :
18202 printf %s "(cached) " >&6
18203else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000018204 ac_check_lib_save_LIBS=$LIBS
Roland Hiebere1f77692021-02-09 02:05:25 +010018205LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
Matthias Kloseb9621712010-04-24 17:59:49 +000018206cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018207/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018208
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018209/* Override any GCC internal prototype to avoid an error.
18210 Use char because int might match the return type of a GCC
18211 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018212char rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018213int
Pablo Galindoba421752021-05-03 20:33:17 +010018214main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000018215{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018216return rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018217 ;
18218 return 0;
18219}
18220_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018221if ac_fn_c_try_link "$LINENO"
18222then :
Roland Hiebere1f77692021-02-09 02:05:25 +010018223 eval "$as_ac_Lib=yes"
Pablo Galindoba421752021-05-03 20:33:17 +010018224else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010018225 eval "$as_ac_Lib=no"
Guido van Rossum353ae582001-07-10 16:45:32 +000018226fi
Pablo Galindoba421752021-05-03 20:33:17 +010018227rm -f core conftest.err conftest.$ac_objext conftest.beam \
Matthias Kloseb9621712010-04-24 17:59:49 +000018228 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018229LIBS=$ac_check_lib_save_LIBS
18230fi
Roland Hiebere1f77692021-02-09 02:05:25 +010018231eval ac_res=\$$as_ac_Lib
Pablo Galindoba421752021-05-03 20:33:17 +010018232 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18233printf "%s\n" "$ac_res" >&6; }
18234if eval test \"x\$"$as_ac_Lib"\" = x"yes"
18235then :
Michael W. Hudson54241132001-12-07 15:38:26 +000018236
Pablo Galindoba421752021-05-03 20:33:17 +010018237printf "%s\n" "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h
Guido van Rossum353ae582001-07-10 16:45:32 +000018238
Guido van Rossum353ae582001-07-10 16:45:32 +000018239fi
18240
Jack Jansendd19cf82001-12-06 22:36:17 +000018241
Roland Hiebere1f77692021-02-09 02:05:25 +010018242 # also in readline 4.2
Pablo Galindoba421752021-05-03 20:33:17 +010018243 ac_fn_check_decl "$LINENO" "rl_catch_signals" "ac_cv_have_decl_rl_catch_signals" "
Roland Hiebere1f77692021-02-09 02:05:25 +010018244#include <stdio.h> /* Must be first for Gnu Readline */
18245#ifdef WITH_EDITLINE
18246# include <editline/readline.h>
18247#else
18248# include <readline/readline.h>
18249#endif
Matthias Kloseb159a552010-04-25 21:00:44 +000018250
Pablo Galindoba421752021-05-03 20:33:17 +010018251" "$ac_c_undeclared_builtin_options" "CFLAGS"
18252if test "x$ac_cv_have_decl_rl_catch_signals" = xyes
18253then :
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000018254
Pablo Galindoba421752021-05-03 20:33:17 +010018255printf "%s\n" "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000018256
18257fi
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000018258
Pablo Galindoba421752021-05-03 20:33:17 +010018259 as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIBREADLINE""_append_history" | $as_tr_sh`
18260{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for append_history in -l$LIBREADLINE" >&5
18261printf %s "checking for append_history in -l$LIBREADLINE... " >&6; }
18262if eval test \${$as_ac_Lib+y}
18263then :
18264 printf %s "(cached) " >&6
18265else $as_nop
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018266 ac_check_lib_save_LIBS=$LIBS
Roland Hiebere1f77692021-02-09 02:05:25 +010018267LIBS="-l$LIBREADLINE $READLINE_LIBS $LIBS"
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018268cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18269/* end confdefs.h. */
18270
18271/* Override any GCC internal prototype to avoid an error.
18272 Use char because int might match the return type of a GCC
18273 builtin and then its argument prototype would still apply. */
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018274char append_history ();
18275int
Pablo Galindoba421752021-05-03 20:33:17 +010018276main (void)
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018277{
18278return append_history ();
18279 ;
18280 return 0;
18281}
18282_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018283if ac_fn_c_try_link "$LINENO"
18284then :
Roland Hiebere1f77692021-02-09 02:05:25 +010018285 eval "$as_ac_Lib=yes"
Pablo Galindoba421752021-05-03 20:33:17 +010018286else $as_nop
Roland Hiebere1f77692021-02-09 02:05:25 +010018287 eval "$as_ac_Lib=no"
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018288fi
Pablo Galindoba421752021-05-03 20:33:17 +010018289rm -f core conftest.err conftest.$ac_objext conftest.beam \
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018290 conftest$ac_exeext conftest.$ac_ext
18291LIBS=$ac_check_lib_save_LIBS
18292fi
Roland Hiebere1f77692021-02-09 02:05:25 +010018293eval ac_res=\$$as_ac_Lib
Pablo Galindoba421752021-05-03 20:33:17 +010018294 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18295printf "%s\n" "$ac_res" >&6; }
18296if eval test \"x\$"$as_ac_Lib"\" = x"yes"
18297then :
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018298
Pablo Galindoba421752021-05-03 20:33:17 +010018299printf "%s\n" "#define HAVE_RL_APPEND_HISTORY 1" >>confdefs.h
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018300
18301fi
18302
Roland Hiebere1f77692021-02-09 02:05:25 +010018303fi
Benjamin Petersond1e22ba2014-11-26 14:35:12 -060018304
Martin v. Löwis82bca632006-02-10 20:49:30 +000018305# End of readline checks: restore LIBS
18306LIBS=$LIBS_no_readline
18307
Pablo Galindoba421752021-05-03 20:33:17 +010018308{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5
18309printf %s "checking for broken nice()... " >&6; }
18310if test ${ac_cv_broken_nice+y}
18311then :
18312 printf %s "(cached) " >&6
18313else $as_nop
Martin v. Löwis11437992002-04-12 09:54:03 +000018314
Pablo Galindoba421752021-05-03 20:33:17 +010018315if test "$cross_compiling" = yes
18316then :
Guido van Rossum3065c942001-09-17 04:03:14 +000018317 ac_cv_broken_nice=no
Pablo Galindoba421752021-05-03 20:33:17 +010018318else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018320/* end confdefs.h. */
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018321
Benjamin Petersonb84df2d2019-02-25 21:37:59 -080018322#include <stdlib.h>
18323#include <unistd.h>
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018324int main()
18325{
18326 int val1 = nice(1);
18327 if (val1 != -1 && val1 == nice(2))
18328 exit(0);
18329 exit(1);
18330}
18331
Martin v. Löwis11437992002-04-12 09:54:03 +000018332_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018333if ac_fn_c_try_run "$LINENO"
18334then :
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018335 ac_cv_broken_nice=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018336else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018337 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018338fi
Matthias Kloseb9621712010-04-24 17:59:49 +000018339rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18340 conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018341fi
18342
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018343fi
18344
Pablo Galindoba421752021-05-03 20:33:17 +010018345{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5
18346printf "%s\n" "$ac_cv_broken_nice" >&6; }
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018347if test "$ac_cv_broken_nice" = yes
18348then
Martin v. Löwis11437992002-04-12 09:54:03 +000018349
Pablo Galindoba421752021-05-03 20:33:17 +010018350printf "%s\n" "#define HAVE_BROKEN_NICE 1" >>confdefs.h
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018351
18352fi
18353
Pablo Galindoba421752021-05-03 20:33:17 +010018354{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5
18355printf %s "checking for broken poll()... " >&6; }
18356if test ${ac_cv_broken_poll+y}
18357then :
18358 printf %s "(cached) " >&6
18359else $as_nop
18360 if test "$cross_compiling" = yes
18361then :
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018362 ac_cv_broken_poll=no
Pablo Galindoba421752021-05-03 20:33:17 +010018363else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018365/* end confdefs.h. */
18366
18367#include <poll.h>
Joshua Root674fa0a2020-12-14 07:56:34 +110018368#include <unistd.h>
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018369
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018370int main()
18371{
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018372 struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 };
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018373 int poll_test;
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018374
18375 close (42);
18376
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018377 poll_test = poll(&poll_struct, 1, 0);
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018378 if (poll_test < 0)
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018379 return 0;
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018380 else if (poll_test == 0 && poll_struct.revents != POLLNVAL)
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018381 return 0;
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018382 else
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018383 return 1;
18384}
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018385
18386_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018387if ac_fn_c_try_run "$LINENO"
18388then :
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018389 ac_cv_broken_poll=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018390else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018391 ac_cv_broken_poll=no
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018392fi
Matthias Kloseb9621712010-04-24 17:59:49 +000018393rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18394 conftest.$ac_objext conftest.beam conftest.$ac_ext
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018395fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018396
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000018397fi
18398
Pablo Galindoba421752021-05-03 20:33:17 +010018399{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5
18400printf "%s\n" "$ac_cv_broken_poll" >&6; }
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018401if test "$ac_cv_broken_poll" = yes
18402then
18403
Pablo Galindoba421752021-05-03 20:33:17 +010018404printf "%s\n" "#define HAVE_BROKEN_POLL 1" >>confdefs.h
Nicholas Bastine62c5c82004-03-21 23:45:42 +000018405
18406fi
18407
Martin v. Löwis1d459062005-03-14 21:23:33 +000018408# check tzset(3) exists and works like we expect it to
Pablo Galindoba421752021-05-03 20:33:17 +010018409{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5
18410printf %s "checking for working tzset()... " >&6; }
18411if test ${ac_cv_working_tzset+y}
18412then :
18413 printf %s "(cached) " >&6
18414else $as_nop
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018415
Pablo Galindoba421752021-05-03 20:33:17 +010018416if test "$cross_compiling" = yes
18417then :
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018418 ac_cv_working_tzset=no
Pablo Galindoba421752021-05-03 20:33:17 +010018419else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018421/* end confdefs.h. */
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018422
18423#include <stdlib.h>
18424#include <time.h>
Brett Cannon18367812003-09-19 00:59:16 +000018425#include <string.h>
Brett Cannon43802422005-02-10 20:48:03 +000018426
18427#if HAVE_TZNAME
18428extern char *tzname[];
18429#endif
18430
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018431int main()
18432{
Brett Cannon18367812003-09-19 00:59:16 +000018433 /* Note that we need to ensure that not only does tzset(3)
18434 do 'something' with localtime, but it works as documented
18435 in the library reference and as expected by the test suite.
Martin v. Löwis1d459062005-03-14 21:23:33 +000018436 This includes making sure that tzname is set properly if
18437 tm->tm_zone does not exist since it is the alternative way
18438 of getting timezone info.
Brett Cannon18367812003-09-19 00:59:16 +000018439
18440 Red Hat 6.2 doesn't understand the southern hemisphere
Martin v. Löwis1d459062005-03-14 21:23:33 +000018441 after New Year's Day.
Brett Cannon18367812003-09-19 00:59:16 +000018442 */
18443
Martin v. Löwis1d459062005-03-14 21:23:33 +000018444 time_t groundhogday = 1044144000; /* GMT-based */
Brett Cannon18367812003-09-19 00:59:16 +000018445 time_t midyear = groundhogday + (365 * 24 * 3600 / 2);
18446
Neal Norwitz7f2588c2003-04-11 15:35:53 +000018447 putenv("TZ=UTC+0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018448 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000018449 if (localtime(&groundhogday)->tm_hour != 0)
18450 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000018451#if HAVE_TZNAME
18452 /* For UTC, tzname[1] is sometimes "", sometimes " " */
18453 if (strcmp(tzname[0], "UTC") ||
18454 (tzname[1][0] != 0 && tzname[1][0] != ' '))
18455 exit(1);
18456#endif
Brett Cannon18367812003-09-19 00:59:16 +000018457
Neal Norwitz7f2588c2003-04-11 15:35:53 +000018458 putenv("TZ=EST+5EDT,M4.1.0,M10.5.0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018459 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000018460 if (localtime(&groundhogday)->tm_hour != 19)
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018461 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000018462#if HAVE_TZNAME
18463 if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT"))
18464 exit(1);
18465#endif
Brett Cannon18367812003-09-19 00:59:16 +000018466
18467 putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0");
18468 tzset();
18469 if (localtime(&groundhogday)->tm_hour != 11)
18470 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000018471#if HAVE_TZNAME
18472 if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT"))
18473 exit(1);
18474#endif
18475
18476#if HAVE_STRUCT_TM_TM_ZONE
Brett Cannon18367812003-09-19 00:59:16 +000018477 if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT"))
18478 exit(1);
18479 if (strcmp(localtime(&midyear)->tm_zone, "AEST"))
18480 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000018481#endif
Brett Cannon18367812003-09-19 00:59:16 +000018482
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018483 exit(0);
18484}
18485
18486_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018487if ac_fn_c_try_run "$LINENO"
18488then :
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018489 ac_cv_working_tzset=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018490else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018491 ac_cv_working_tzset=no
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018492fi
Matthias Kloseb9621712010-04-24 17:59:49 +000018493rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18494 conftest.$ac_objext conftest.beam conftest.$ac_ext
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018495fi
18496
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018497fi
18498
Pablo Galindoba421752021-05-03 20:33:17 +010018499{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5
18500printf "%s\n" "$ac_cv_working_tzset" >&6; }
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018501if test "$ac_cv_working_tzset" = yes
18502then
18503
Pablo Galindoba421752021-05-03 20:33:17 +010018504printf "%s\n" "#define HAVE_WORKING_TZSET 1" >>confdefs.h
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018505
18506fi
18507
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018508# Look for subsecond timestamps in struct stat
Pablo Galindoba421752021-05-03 20:33:17 +010018509{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5
18510printf %s "checking for tv_nsec in struct stat... " >&6; }
18511if test ${ac_cv_stat_tv_nsec+y}
18512then :
18513 printf %s "(cached) " >&6
18514else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018516/* end confdefs.h. */
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018517#include <sys/stat.h>
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018518int
Pablo Galindoba421752021-05-03 20:33:17 +010018519main (void)
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018520{
18521
18522struct stat st;
18523st.st_mtim.tv_nsec = 1;
18524
18525 ;
18526 return 0;
18527}
18528_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018529if ac_fn_c_try_compile "$LINENO"
18530then :
Martin v. Löwisa32c9942002-09-09 16:17:47 +000018531 ac_cv_stat_tv_nsec=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018532else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018533 ac_cv_stat_tv_nsec=no
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018534fi
Pablo Galindoba421752021-05-03 20:33:17 +010018535rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018536fi
18537
Pablo Galindoba421752021-05-03 20:33:17 +010018538{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5
18539printf "%s\n" "$ac_cv_stat_tv_nsec" >&6; }
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018540if test "$ac_cv_stat_tv_nsec" = yes
18541then
18542
Pablo Galindoba421752021-05-03 20:33:17 +010018543printf "%s\n" "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018544
18545fi
18546
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018547# Look for BSD style subsecond timestamps in struct stat
Pablo Galindoba421752021-05-03 20:33:17 +010018548{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5
18549printf %s "checking for tv_nsec2 in struct stat... " >&6; }
18550if test ${ac_cv_stat_tv_nsec2+y}
18551then :
18552 printf %s "(cached) " >&6
18553else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018555/* end confdefs.h. */
18556#include <sys/stat.h>
18557int
Pablo Galindoba421752021-05-03 20:33:17 +010018558main (void)
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018559{
18560
18561struct stat st;
18562st.st_mtimespec.tv_nsec = 1;
18563
18564 ;
18565 return 0;
18566}
18567_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018568if ac_fn_c_try_compile "$LINENO"
18569then :
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018570 ac_cv_stat_tv_nsec2=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018571else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018572 ac_cv_stat_tv_nsec2=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018573fi
Pablo Galindoba421752021-05-03 20:33:17 +010018574rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018575fi
18576
Pablo Galindoba421752021-05-03 20:33:17 +010018577{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5
18578printf "%s\n" "$ac_cv_stat_tv_nsec2" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018579if test "$ac_cv_stat_tv_nsec2" = yes
18580then
18581
Pablo Galindoba421752021-05-03 20:33:17 +010018582printf "%s\n" "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000018583
18584fi
18585
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018586# first curses header check
doko@ubuntu.com9dc823d2012-07-07 03:06:42 +020018587ac_save_cppflags="$CPPFLAGS"
Xavier de Gayee13c3202016-12-13 16:04:14 +010018588if test "$cross_compiling" = no; then
18589 CPPFLAGS="$CPPFLAGS -I/usr/include/ncursesw"
18590fi
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018591
Pablo Galindoba421752021-05-03 20:33:17 +010018592ac_fn_c_check_header_compile "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
18593if test "x$ac_cv_header_curses_h" = xyes
18594then :
18595 printf "%s\n" "#define HAVE_CURSES_H 1" >>confdefs.h
18596
18597fi
18598ac_fn_c_check_header_compile "$LINENO" "ncurses.h" "ac_cv_header_ncurses_h" "$ac_includes_default"
18599if test "x$ac_cv_header_ncurses_h" = xyes
18600then :
18601 printf "%s\n" "#define HAVE_NCURSES_H 1" >>confdefs.h
Pablo Galindo53e55292021-04-05 17:38:40 +010018602
18603fi
Pablo Galindocc128882021-03-01 16:47:53 +000018604
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018605
18606# On Solaris, term.h requires curses.h
Pablo Galindoba421752021-05-03 20:33:17 +010018607ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" "
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018608#ifdef HAVE_CURSES_H
18609#include <curses.h>
18610#endif
18611
18612"
Pablo Galindoba421752021-05-03 20:33:17 +010018613if test "x$ac_cv_header_term_h" = xyes
18614then :
18615 printf "%s\n" "#define HAVE_TERM_H 1" >>confdefs.h
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018616
18617fi
18618
doko@ubuntu.com1a4f5612014-04-17 20:13:44 +020018619
Jack Jansen666b1e72001-10-31 12:11:48 +000018620# On HP/UX 11.0, mvwdelch is a block with a return statement
Pablo Galindoba421752021-05-03 20:33:17 +010018621{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5
18622printf %s "checking whether mvwdelch is an expression... " >&6; }
18623if test ${ac_cv_mvwdelch_is_expression+y}
18624then :
18625 printf %s "(cached) " >&6
18626else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018628/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000018629#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000018630int
Pablo Galindoba421752021-05-03 20:33:17 +010018631main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000018632{
Jack Jansen666b1e72001-10-31 12:11:48 +000018633
18634 int rtn;
18635 rtn = mvwdelch(0,0,0);
18636
Martin v. Löwis11437992002-04-12 09:54:03 +000018637 ;
18638 return 0;
18639}
18640_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018641if ac_fn_c_try_compile "$LINENO"
18642then :
Jack Jansen666b1e72001-10-31 12:11:48 +000018643 ac_cv_mvwdelch_is_expression=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018644else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018645 ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000018646fi
Pablo Galindoba421752021-05-03 20:33:17 +010018647rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018648fi
18649
Pablo Galindoba421752021-05-03 20:33:17 +010018650{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5
18651printf "%s\n" "$ac_cv_mvwdelch_is_expression" >&6; }
Jack Jansen666b1e72001-10-31 12:11:48 +000018652
18653if test "$ac_cv_mvwdelch_is_expression" = yes
18654then
Martin v. Löwis11437992002-04-12 09:54:03 +000018655
Pablo Galindoba421752021-05-03 20:33:17 +010018656printf "%s\n" "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h
Jack Jansen666b1e72001-10-31 12:11:48 +000018657
18658fi
18659
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018660# Issue #25720: ncurses has introduced the NCURSES_OPAQUE symbol making opaque
18661# structs since version 5.7. If the macro is defined as zero before including
18662# [n]curses.h, ncurses will expose fields of the structs regardless of the
18663# configuration.
Pablo Galindoba421752021-05-03 20:33:17 +010018664{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5
18665printf %s "checking whether WINDOW has _flags... " >&6; }
18666if test ${ac_cv_window_has_flags+y}
18667then :
18668 printf %s "(cached) " >&6
18669else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000018671/* end confdefs.h. */
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018672
18673 #define NCURSES_OPAQUE 0
18674 #include <curses.h>
18675
Martin v. Löwis11437992002-04-12 09:54:03 +000018676int
Pablo Galindoba421752021-05-03 20:33:17 +010018677main (void)
Martin v. Löwis11437992002-04-12 09:54:03 +000018678{
Jack Jansen666b1e72001-10-31 12:11:48 +000018679
18680 WINDOW *w;
18681 w->_flags = 0;
18682
Martin v. Löwis11437992002-04-12 09:54:03 +000018683 ;
18684 return 0;
18685}
18686_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018687if ac_fn_c_try_compile "$LINENO"
18688then :
Jack Jansen666b1e72001-10-31 12:11:48 +000018689 ac_cv_window_has_flags=yes
Pablo Galindoba421752021-05-03 20:33:17 +010018690else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000018691 ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000018692fi
Pablo Galindoba421752021-05-03 20:33:17 +010018693rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018694fi
18695
Pablo Galindoba421752021-05-03 20:33:17 +010018696{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5
18697printf "%s\n" "$ac_cv_window_has_flags" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000018698
Jack Jansen666b1e72001-10-31 12:11:48 +000018699
18700if test "$ac_cv_window_has_flags" = yes
18701then
Martin v. Löwis11437992002-04-12 09:54:03 +000018702
Pablo Galindoba421752021-05-03 20:33:17 +010018703printf "%s\n" "#define WINDOW_HAS_FLAGS 1" >>confdefs.h
Jack Jansen666b1e72001-10-31 12:11:48 +000018704
18705fi
18706
Pablo Galindoba421752021-05-03 20:33:17 +010018707{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for is_pad" >&5
18708printf %s "checking for is_pad... " >&6; }
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018709cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18710/* end confdefs.h. */
18711#include <curses.h>
18712int
Pablo Galindoba421752021-05-03 20:33:17 +010018713main (void)
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018714{
18715
18716#ifndef is_pad
18717void *x=is_pad
18718#endif
18719
18720 ;
18721 return 0;
18722}
18723_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018724if ac_fn_c_try_compile "$LINENO"
18725then :
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018726
Pablo Galindoba421752021-05-03 20:33:17 +010018727printf "%s\n" "#define HAVE_CURSES_IS_PAD 1" >>confdefs.h
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018728
Pablo Galindoba421752021-05-03 20:33:17 +010018729 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18730printf "%s\n" "yes" >&6; }
18731else $as_nop
18732 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18733printf "%s\n" "no" >&6; }
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018734
18735fi
Pablo Galindoba421752021-05-03 20:33:17 +010018736rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Masayuki Yamamoto8bc7d632017-11-01 21:05:26 +090018737
Pablo Galindoba421752021-05-03 20:33:17 +010018738{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5
18739printf %s "checking for is_term_resized... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000018740cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018741/* end confdefs.h. */
18742#include <curses.h>
18743int
Pablo Galindoba421752021-05-03 20:33:17 +010018744main (void)
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018745{
18746void *x=is_term_resized
18747 ;
18748 return 0;
18749}
18750_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018751if ac_fn_c_try_compile "$LINENO"
18752then :
Martin v. Löwis24a880b2002-12-31 12:55:15 +000018753
Pablo Galindoba421752021-05-03 20:33:17 +010018754printf "%s\n" "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018755
Pablo Galindoba421752021-05-03 20:33:17 +010018756 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18757printf "%s\n" "yes" >&6; }
18758else $as_nop
18759 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18760printf "%s\n" "no" >&6; }
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018761
18762fi
Pablo Galindoba421752021-05-03 20:33:17 +010018763rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018764
Pablo Galindoba421752021-05-03 20:33:17 +010018765{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5
18766printf %s "checking for resize_term... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000018767cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018768/* end confdefs.h. */
18769#include <curses.h>
18770int
Pablo Galindoba421752021-05-03 20:33:17 +010018771main (void)
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018772{
18773void *x=resize_term
18774 ;
18775 return 0;
18776}
18777_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018778if ac_fn_c_try_compile "$LINENO"
18779then :
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018780
Pablo Galindoba421752021-05-03 20:33:17 +010018781printf "%s\n" "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018782
Pablo Galindoba421752021-05-03 20:33:17 +010018783 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18784printf "%s\n" "yes" >&6; }
18785else $as_nop
18786 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18787printf "%s\n" "no" >&6; }
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018788
18789fi
Pablo Galindoba421752021-05-03 20:33:17 +010018790rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Thomas Wouters47b49bf2007-08-30 22:15:33 +000018791
Pablo Galindoba421752021-05-03 20:33:17 +010018792{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5
18793printf %s "checking for resizeterm... " >&6; }
Matthias Kloseb9621712010-04-24 17:59:49 +000018794cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018795/* end confdefs.h. */
18796#include <curses.h>
18797int
Pablo Galindoba421752021-05-03 20:33:17 +010018798main (void)
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018799{
18800void *x=resizeterm
18801 ;
18802 return 0;
18803}
18804_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018805if ac_fn_c_try_compile "$LINENO"
18806then :
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018807
Pablo Galindoba421752021-05-03 20:33:17 +010018808printf "%s\n" "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018809
Pablo Galindoba421752021-05-03 20:33:17 +010018810 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18811printf "%s\n" "yes" >&6; }
18812else $as_nop
18813 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18814printf "%s\n" "no" >&6; }
Thomas Wouters0e3f5912006-08-11 14:57:12 +000018815
18816fi
Pablo Galindoba421752021-05-03 20:33:17 +010018817rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018818
Pablo Galindoba421752021-05-03 20:33:17 +010018819{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for immedok" >&5
18820printf %s "checking for immedok... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018821cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18822/* end confdefs.h. */
18823#include <curses.h>
18824int
Pablo Galindoba421752021-05-03 20:33:17 +010018825main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018826{
18827
18828#ifndef immedok
18829void *x=immedok
18830#endif
18831
18832 ;
18833 return 0;
18834}
18835_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018836if ac_fn_c_try_compile "$LINENO"
18837then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018838
Pablo Galindoba421752021-05-03 20:33:17 +010018839printf "%s\n" "#define HAVE_CURSES_IMMEDOK 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018840
Pablo Galindoba421752021-05-03 20:33:17 +010018841 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18842printf "%s\n" "yes" >&6; }
18843else $as_nop
18844 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18845printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018846
18847fi
Pablo Galindoba421752021-05-03 20:33:17 +010018848rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018849
Pablo Galindoba421752021-05-03 20:33:17 +010018850{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for syncok" >&5
18851printf %s "checking for syncok... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018852cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18853/* end confdefs.h. */
18854#include <curses.h>
18855int
Pablo Galindoba421752021-05-03 20:33:17 +010018856main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018857{
18858
18859#ifndef syncok
18860void *x=syncok
18861#endif
18862
18863 ;
18864 return 0;
18865}
18866_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018867if ac_fn_c_try_compile "$LINENO"
18868then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018869
Pablo Galindoba421752021-05-03 20:33:17 +010018870printf "%s\n" "#define HAVE_CURSES_SYNCOK 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018871
Pablo Galindoba421752021-05-03 20:33:17 +010018872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18873printf "%s\n" "yes" >&6; }
18874else $as_nop
18875 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18876printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018877
18878fi
Pablo Galindoba421752021-05-03 20:33:17 +010018879rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018880
Pablo Galindoba421752021-05-03 20:33:17 +010018881{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wchgat" >&5
18882printf %s "checking for wchgat... " >&6; }
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018883cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18884/* end confdefs.h. */
18885#include <curses.h>
18886int
Pablo Galindoba421752021-05-03 20:33:17 +010018887main (void)
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018888{
18889
18890#ifndef wchgat
18891void *x=wchgat
18892#endif
18893
18894 ;
18895 return 0;
18896}
18897_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018898if ac_fn_c_try_compile "$LINENO"
18899then :
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018900
Pablo Galindoba421752021-05-03 20:33:17 +010018901printf "%s\n" "#define HAVE_CURSES_WCHGAT 1" >>confdefs.h
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018902
Pablo Galindoba421752021-05-03 20:33:17 +010018903 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18904printf "%s\n" "yes" >&6; }
18905else $as_nop
18906 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18907printf "%s\n" "no" >&6; }
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018908
18909fi
Pablo Galindoba421752021-05-03 20:33:17 +010018910rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchaka894ebd02017-11-01 14:34:20 +020018911
Pablo Galindoba421752021-05-03 20:33:17 +010018912{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for filter" >&5
18913printf %s "checking for filter... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018914cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18915/* end confdefs.h. */
18916#include <curses.h>
18917int
Pablo Galindoba421752021-05-03 20:33:17 +010018918main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018919{
18920
18921#ifndef filter
18922void *x=filter
18923#endif
18924
18925 ;
18926 return 0;
18927}
18928_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018929if ac_fn_c_try_compile "$LINENO"
18930then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018931
Pablo Galindoba421752021-05-03 20:33:17 +010018932printf "%s\n" "#define HAVE_CURSES_FILTER 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018933
Pablo Galindoba421752021-05-03 20:33:17 +010018934 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18935printf "%s\n" "yes" >&6; }
18936else $as_nop
18937 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18938printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018939
18940fi
Pablo Galindoba421752021-05-03 20:33:17 +010018941rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018942
Pablo Galindoba421752021-05-03 20:33:17 +010018943{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for has_key" >&5
18944printf %s "checking for has_key... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018945cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18946/* end confdefs.h. */
18947#include <curses.h>
18948int
Pablo Galindoba421752021-05-03 20:33:17 +010018949main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018950{
18951
18952#ifndef has_key
18953void *x=has_key
18954#endif
18955
18956 ;
18957 return 0;
18958}
18959_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018960if ac_fn_c_try_compile "$LINENO"
18961then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018962
Pablo Galindoba421752021-05-03 20:33:17 +010018963printf "%s\n" "#define HAVE_CURSES_HAS_KEY 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018964
Pablo Galindoba421752021-05-03 20:33:17 +010018965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18966printf "%s\n" "yes" >&6; }
18967else $as_nop
18968 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
18969printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018970
18971fi
Pablo Galindoba421752021-05-03 20:33:17 +010018972rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018973
Pablo Galindoba421752021-05-03 20:33:17 +010018974{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for typeahead" >&5
18975printf %s "checking for typeahead... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018976cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18977/* end confdefs.h. */
18978#include <curses.h>
18979int
Pablo Galindoba421752021-05-03 20:33:17 +010018980main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018981{
18982
18983#ifndef typeahead
18984void *x=typeahead
18985#endif
18986
18987 ;
18988 return 0;
18989}
18990_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010018991if ac_fn_c_try_compile "$LINENO"
18992then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018993
Pablo Galindoba421752021-05-03 20:33:17 +010018994printf "%s\n" "#define HAVE_CURSES_TYPEAHEAD 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020018995
Pablo Galindoba421752021-05-03 20:33:17 +010018996 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18997printf "%s\n" "yes" >&6; }
18998else $as_nop
18999 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19000printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019001
19002fi
Pablo Galindoba421752021-05-03 20:33:17 +010019003rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019004
Pablo Galindoba421752021-05-03 20:33:17 +010019005{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for use_env" >&5
19006printf %s "checking for use_env... " >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019007cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19008/* end confdefs.h. */
19009#include <curses.h>
19010int
Pablo Galindoba421752021-05-03 20:33:17 +010019011main (void)
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019012{
19013
19014#ifndef use_env
19015void *x=use_env
19016#endif
19017
19018 ;
19019 return 0;
19020}
19021_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019022if ac_fn_c_try_compile "$LINENO"
19023then :
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019024
Pablo Galindoba421752021-05-03 20:33:17 +010019025printf "%s\n" "#define HAVE_CURSES_USE_ENV 1" >>confdefs.h
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019026
Pablo Galindoba421752021-05-03 20:33:17 +010019027 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19028printf "%s\n" "yes" >&6; }
19029else $as_nop
19030 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19031printf "%s\n" "no" >&6; }
Serhiy Storchakabaac01e2017-10-31 13:56:44 +020019032
19033fi
Pablo Galindoba421752021-05-03 20:33:17 +010019034rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
doko@ubuntu.com9dc823d2012-07-07 03:06:42 +020019035# last curses configure check
19036CPPFLAGS=$ac_save_cppflags
Thomas Wouters47b49bf2007-08-30 22:15:33 +000019037
Pablo Galindoba421752021-05-03 20:33:17 +010019038{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for device files" >&5
19039printf "%s\n" "$as_me: checking for device files" >&6;}
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019040
19041if test "x$cross_compiling" = xyes; then
19042 if test "${ac_cv_file__dev_ptmx+set}" != set; then
Pablo Galindoba421752021-05-03 20:33:17 +010019043 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5
19044printf %s "checking for /dev/ptmx... " >&6; }
19045 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not set" >&5
19046printf "%s\n" "not set" >&6; }
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019047 as_fn_error $? "set ac_cv_file__dev_ptmx to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5
19048 fi
19049 if test "${ac_cv_file__dev_ptc+set}" != set; then
Pablo Galindoba421752021-05-03 20:33:17 +010019050 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5
19051printf %s "checking for /dev/ptc... " >&6; }
19052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not set" >&5
19053printf "%s\n" "not set" >&6; }
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019054 as_fn_error $? "set ac_cv_file__dev_ptc to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5
19055 fi
19056fi
19057
Pablo Galindoba421752021-05-03 20:33:17 +010019058{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5
19059printf %s "checking for /dev/ptmx... " >&6; }
19060if test ${ac_cv_file__dev_ptmx+y}
19061then :
19062 printf %s "(cached) " >&6
19063else $as_nop
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019064 test "$cross_compiling" = yes &&
19065 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
19066if test -r "/dev/ptmx"; then
19067 ac_cv_file__dev_ptmx=yes
19068else
19069 ac_cv_file__dev_ptmx=no
19070fi
19071fi
Pablo Galindoba421752021-05-03 20:33:17 +010019072{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptmx" >&5
19073printf "%s\n" "$ac_cv_file__dev_ptmx" >&6; }
19074if test "x$ac_cv_file__dev_ptmx" = xyes
19075then :
Thomas Wouters89f507f2006-12-13 04:49:30 +000019076
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019077fi
19078
19079if test "x$ac_cv_file__dev_ptmx" = xyes; then
Martin v. Löwis24a880b2002-12-31 12:55:15 +000019080
Pablo Galindoba421752021-05-03 20:33:17 +010019081printf "%s\n" "#define HAVE_DEV_PTMX 1" >>confdefs.h
Martin v. Löwis24a880b2002-12-31 12:55:15 +000019082
Martin v. Löwis24a880b2002-12-31 12:55:15 +000019083fi
Pablo Galindoba421752021-05-03 20:33:17 +010019084{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5
19085printf %s "checking for /dev/ptc... " >&6; }
19086if test ${ac_cv_file__dev_ptc+y}
19087then :
19088 printf %s "(cached) " >&6
19089else $as_nop
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019090 test "$cross_compiling" = yes &&
19091 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
19092if test -r "/dev/ptc"; then
19093 ac_cv_file__dev_ptc=yes
19094else
19095 ac_cv_file__dev_ptc=no
19096fi
19097fi
Pablo Galindoba421752021-05-03 20:33:17 +010019098{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptc" >&5
19099printf "%s\n" "$ac_cv_file__dev_ptc" >&6; }
19100if test "x$ac_cv_file__dev_ptc" = xyes
19101then :
Thomas Wouters89f507f2006-12-13 04:49:30 +000019102
doko@ubuntu.comb457b9b2012-06-30 19:28:16 +020019103fi
19104
19105if test "x$ac_cv_file__dev_ptc" = xyes; then
Neal Norwitz865400f2003-03-21 01:42:58 +000019106
Pablo Galindoba421752021-05-03 20:33:17 +010019107printf "%s\n" "#define HAVE_DEV_PTC 1" >>confdefs.h
Neal Norwitz865400f2003-03-21 01:42:58 +000019108
Neal Norwitz865400f2003-03-21 01:42:58 +000019109fi
19110
Ronald Oussoren3c1928a2009-11-19 17:15:31 +000019111if test $ac_sys_system = Darwin
19112then
19113 LIBS="$LIBS -framework CoreFoundation"
19114fi
Mark Dickinson6ce4a9a2009-11-16 17:00:11 +000019115
Pablo Galindoba421752021-05-03 20:33:17 +010019116{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5
19117printf %s "checking for %zd printf() format support... " >&6; }
19118if test ${ac_cv_have_size_t_format+y}
19119then :
19120 printf %s "(cached) " >&6
19121else $as_nop
19122 if test "$cross_compiling" = yes
19123then :
Benjamin Peterson8f326b22009-12-13 02:10:36 +000019124 ac_cv_have_size_t_format="cross -- assuming yes"
19125
Pablo Galindoba421752021-05-03 20:33:17 +010019126else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000019127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Thomas Wouters477c8d52006-05-27 19:21:47 +000019128/* end confdefs.h. */
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019129
Thomas Wouters477c8d52006-05-27 19:21:47 +000019130#include <stdio.h>
19131#include <stddef.h>
19132#include <string.h>
19133
Christian Heimes2c181612007-12-17 20:04:13 +000019134#ifdef HAVE_SYS_TYPES_H
19135#include <sys/types.h>
19136#endif
Thomas Wouters89f507f2006-12-13 04:49:30 +000019137
19138#ifdef HAVE_SSIZE_T
19139typedef ssize_t Py_ssize_t;
19140#elif SIZEOF_VOID_P == SIZEOF_LONG
19141typedef long Py_ssize_t;
19142#else
19143typedef int Py_ssize_t;
19144#endif
Thomas Wouters477c8d52006-05-27 19:21:47 +000019145
Christian Heimes2c181612007-12-17 20:04:13 +000019146int main()
19147{
19148 char buffer[256];
19149
Thomas Wouters477c8d52006-05-27 19:21:47 +000019150 if(sprintf(buffer, "%zd", (size_t)123) < 0)
19151 return 1;
19152
Thomas Wouters89f507f2006-12-13 04:49:30 +000019153 if (strcmp(buffer, "123"))
19154 return 1;
19155
19156 if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
19157 return 1;
19158
19159 if (strcmp(buffer, "-123"))
Thomas Wouters477c8d52006-05-27 19:21:47 +000019160 return 1;
19161
19162 return 0;
19163}
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019164
Thomas Wouters477c8d52006-05-27 19:21:47 +000019165_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019166if ac_fn_c_try_run "$LINENO"
19167then :
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019168 ac_cv_have_size_t_format=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019169else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000019170 ac_cv_have_size_t_format=no
Alexandre Vassalotti19142282009-07-17 23:11:52 +000019171fi
Matthias Kloseb9621712010-04-24 17:59:49 +000019172rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19173 conftest.$ac_objext conftest.beam conftest.$ac_ext
Alexandre Vassalotti302825b2009-07-17 07:49:53 +000019174fi
19175
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019176fi
Pablo Galindoba421752021-05-03 20:33:17 +010019177{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5
19178printf "%s\n" "$ac_cv_have_size_t_format" >&6; }
Benjamin Peterson8f326b22009-12-13 02:10:36 +000019179if test "$ac_cv_have_size_t_format" != no ; then
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019180
Pablo Galindoba421752021-05-03 20:33:17 +010019181printf "%s\n" "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019182
19183fi
19184
Matthias Kloseb9621712010-04-24 17:59:49 +000019185ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
Martin v. Löwis01c04012002-11-11 14:58:44 +000019186#ifdef HAVE_SYS_TYPES_H
19187#include <sys/types.h>
19188#endif
19189#ifdef HAVE_SYS_SOCKET_H
19190#include <sys/socket.h>
19191#endif
19192
Matthias Kloseb9621712010-04-24 17:59:49 +000019193"
Pablo Galindoba421752021-05-03 20:33:17 +010019194if test "x$ac_cv_type_socklen_t" = xyes
19195then :
Martin v. Löwis01c04012002-11-11 14:58:44 +000019196
Pablo Galindoba421752021-05-03 20:33:17 +010019197else $as_nop
Guido van Rossum95713eb2000-05-18 20:53:31 +000019198
Pablo Galindoba421752021-05-03 20:33:17 +010019199printf "%s\n" "#define socklen_t int" >>confdefs.h
Guido van Rossum95713eb2000-05-18 20:53:31 +000019200
19201fi
19202
Michael W. Hudson54241132001-12-07 15:38:26 +000019203
Pablo Galindoba421752021-05-03 20:33:17 +010019204{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5
19205printf %s "checking for broken mbstowcs... " >&6; }
19206if test ${ac_cv_broken_mbstowcs+y}
19207then :
19208 printf %s "(cached) " >&6
19209else $as_nop
19210 if test "$cross_compiling" = yes
19211then :
Antoine Pitroufff95302008-09-03 18:58:51 +000019212 ac_cv_broken_mbstowcs=no
Pablo Galindoba421752021-05-03 20:33:17 +010019213else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000019214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
Antoine Pitroufff95302008-09-03 18:58:51 +000019215/* end confdefs.h. */
19216
Stefan Krah19c21392012-11-22 23:47:32 +010019217#include <stdio.h>
Antoine Pitroufff95302008-09-03 18:58:51 +000019218#include<stdlib.h>
19219int main() {
19220 size_t len = -1;
19221 const char *str = "text";
19222 len = mbstowcs(NULL, str, 0);
19223 return (len != 4);
19224}
19225
19226_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019227if ac_fn_c_try_run "$LINENO"
19228then :
Antoine Pitroufff95302008-09-03 18:58:51 +000019229 ac_cv_broken_mbstowcs=no
Pablo Galindoba421752021-05-03 20:33:17 +010019230else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000019231 ac_cv_broken_mbstowcs=yes
Antoine Pitroufff95302008-09-03 18:58:51 +000019232fi
Matthias Kloseb9621712010-04-24 17:59:49 +000019233rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19234 conftest.$ac_objext conftest.beam conftest.$ac_ext
Antoine Pitroufff95302008-09-03 18:58:51 +000019235fi
19236
Alexandre Vassalottib0a61d72009-07-17 23:19:37 +000019237fi
19238
Pablo Galindoba421752021-05-03 20:33:17 +010019239{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5
19240printf "%s\n" "$ac_cv_broken_mbstowcs" >&6; }
Antoine Pitroufff95302008-09-03 18:58:51 +000019241if test "$ac_cv_broken_mbstowcs" = yes
19242then
19243
Pablo Galindoba421752021-05-03 20:33:17 +010019244printf "%s\n" "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h
Antoine Pitroufff95302008-09-03 18:58:51 +000019245
19246fi
19247
Antoine Pitroub52ec782009-01-25 16:34:23 +000019248# Check for --with-computed-gotos
Pablo Galindoba421752021-05-03 20:33:17 +010019249{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5
19250printf %s "checking for --with-computed-gotos... " >&6; }
Antoine Pitroub52ec782009-01-25 16:34:23 +000019251
19252# Check whether --with-computed-gotos was given.
Pablo Galindoba421752021-05-03 20:33:17 +010019253if test ${with_computed_gotos+y}
19254then :
Antoine Pitroub52ec782009-01-25 16:34:23 +000019255 withval=$with_computed_gotos;
Antoine Pitrou042b1282010-08-13 21:15:58 +000019256if test "$withval" = yes
Antoine Pitroub52ec782009-01-25 16:34:23 +000019257then
19258
Pablo Galindoba421752021-05-03 20:33:17 +010019259printf "%s\n" "#define USE_COMPUTED_GOTOS 1" >>confdefs.h
Antoine Pitroub52ec782009-01-25 16:34:23 +000019260
Pablo Galindoba421752021-05-03 20:33:17 +010019261 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19262printf "%s\n" "yes" >&6; }
Antoine Pitroub52ec782009-01-25 16:34:23 +000019263fi
Antoine Pitrou042b1282010-08-13 21:15:58 +000019264if test "$withval" = no
19265then
19266
Pablo Galindoba421752021-05-03 20:33:17 +010019267printf "%s\n" "#define USE_COMPUTED_GOTOS 0" >>confdefs.h
Antoine Pitrou042b1282010-08-13 21:15:58 +000019268
Pablo Galindoba421752021-05-03 20:33:17 +010019269 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19270printf "%s\n" "no" >&6; }
Antoine Pitroub52ec782009-01-25 16:34:23 +000019271fi
19272
Pablo Galindoba421752021-05-03 20:33:17 +010019273else $as_nop
19274 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5
19275printf "%s\n" "no value specified" >&6; }
Antoine Pitrou042b1282010-08-13 21:15:58 +000019276fi
19277
Antoine Pitroub52ec782009-01-25 16:34:23 +000019278
Pablo Galindoba421752021-05-03 20:33:17 +010019279{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5
19280printf %s "checking whether $CC supports computed gotos... " >&6; }
19281if test ${ac_cv_computed_gotos+y}
19282then :
19283 printf %s "(cached) " >&6
19284else $as_nop
19285 if test "$cross_compiling" = yes
19286then :
Matthias Kloseb17289e2012-03-15 19:51:34 +010019287 if test "${with_computed_gotos+set}" = set; then
19288 ac_cv_computed_gotos="$with_computed_gotos -- configured --with(out)-computed-gotos"
19289 else
19290 ac_cv_computed_gotos=no
19291 fi
Pablo Galindoba421752021-05-03 20:33:17 +010019292else $as_nop
Matthias Kloseb17289e2012-03-15 19:51:34 +010019293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19294/* end confdefs.h. */
19295
19296int main(int argc, char **argv)
19297{
19298 static void *targets[1] = { &&LABEL1 };
19299 goto LABEL2;
19300LABEL1:
19301 return 0;
19302LABEL2:
19303 goto *targets[0];
19304 return 1;
19305}
19306
19307_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019308if ac_fn_c_try_run "$LINENO"
19309then :
Matthias Kloseb17289e2012-03-15 19:51:34 +010019310 ac_cv_computed_gotos=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019311else $as_nop
Matthias Kloseb17289e2012-03-15 19:51:34 +010019312 ac_cv_computed_gotos=no
19313fi
19314rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19315 conftest.$ac_objext conftest.beam conftest.$ac_ext
19316fi
19317
19318fi
19319
Pablo Galindoba421752021-05-03 20:33:17 +010019320{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5
19321printf "%s\n" "$ac_cv_computed_gotos" >&6; }
Matthias Kloseb17289e2012-03-15 19:51:34 +010019322case "$ac_cv_computed_gotos" in yes*)
19323
Pablo Galindoba421752021-05-03 20:33:17 +010019324printf "%s\n" "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h
Matthias Kloseb17289e2012-03-15 19:51:34 +010019325
19326esac
19327
Benjamin Petersond8d835b2010-10-15 23:14:46 +000019328case $ac_sys_system in
19329AIX*)
19330
Pablo Galindoba421752021-05-03 20:33:17 +010019331printf "%s\n" "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h
Benjamin Petersond8d835b2010-10-15 23:14:46 +000019332 ;;
19333esac
Antoine Pitroub52ec782009-01-25 16:34:23 +000019334
Michael W. Hudson54241132001-12-07 15:38:26 +000019335
Mark Dickinsonb2153e92010-05-05 22:31:36 +000019336
19337
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000019338for h in `(cd $srcdir;echo Python/thread_*.h)`
19339do
19340 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
19341done
19342
Michael W. Hudson54241132001-12-07 15:38:26 +000019343
Ned Deily8d02f912020-06-25 10:46:44 -040019344SRCDIRS="Parser Objects Python Modules Modules/_io Programs"
Pablo Galindoba421752021-05-03 20:33:17 +010019345{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5
19346printf %s "checking for build directories... " >&6; }
Neil Schemenauerd32c2492001-01-24 17:25:28 +000019347for dir in $SRCDIRS; do
19348 if test ! -d $dir; then
19349 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000019350 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000019351done
Pablo Galindoba421752021-05-03 20:33:17 +010019352{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5
19353printf "%s\n" "done" >&6; }
Fred Drake036144d2000-10-26 17:09:35 +000019354
Stefan Krah1919b7e2012-03-21 18:25:23 +010019355# Availability of -O2:
Pablo Galindoba421752021-05-03 20:33:17 +010019356{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -O2" >&5
19357printf %s "checking for -O2... " >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019358saved_cflags="$CFLAGS"
19359CFLAGS="-O2"
19360cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19361/* end confdefs.h. */
19362
19363int
Pablo Galindoba421752021-05-03 20:33:17 +010019364main (void)
Stefan Krah1919b7e2012-03-21 18:25:23 +010019365{
19366
19367
19368 ;
19369 return 0;
19370}
19371_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019372if ac_fn_c_try_compile "$LINENO"
19373then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010019374 have_O2=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019375else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010019376 have_O2=no
19377fi
Pablo Galindoba421752021-05-03 20:33:17 +010019378rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
19379{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_O2" >&5
19380printf "%s\n" "$have_O2" >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019381CFLAGS="$saved_cflags"
19382
19383# _FORTIFY_SOURCE wrappers for memmove and bcopy are incorrect:
19384# http://sourceware.org/ml/libc-alpha/2010-12/msg00009.html
Pablo Galindoba421752021-05-03 20:33:17 +010019385{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for glibc _FORTIFY_SOURCE/memmove bug" >&5
19386printf %s "checking for glibc _FORTIFY_SOURCE/memmove bug... " >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019387saved_cflags="$CFLAGS"
19388CFLAGS="-O2 -D_FORTIFY_SOURCE=2"
19389if test "$have_O2" = no; then
19390 CFLAGS=""
19391fi
Pablo Galindoba421752021-05-03 20:33:17 +010019392if test "$cross_compiling" = yes
19393then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010019394 have_glibc_memmove_bug=undefined
Pablo Galindoba421752021-05-03 20:33:17 +010019395else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010019396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19397/* end confdefs.h. */
19398
19399#include <stdio.h>
19400#include <stdlib.h>
19401#include <string.h>
19402void foo(void *p, void *q) { memmove(p, q, 19); }
19403int main() {
19404 char a[32] = "123456789000000000";
19405 foo(&a[9], a);
19406 if (strcmp(a, "123456789123456789000000000") != 0)
19407 return 1;
19408 foo(a, &a[9]);
19409 if (strcmp(a, "123456789000000000") != 0)
19410 return 1;
19411 return 0;
19412}
19413
19414_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019415if ac_fn_c_try_run "$LINENO"
19416then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010019417 have_glibc_memmove_bug=no
Pablo Galindoba421752021-05-03 20:33:17 +010019418else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010019419 have_glibc_memmove_bug=yes
19420fi
19421rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19422 conftest.$ac_objext conftest.beam conftest.$ac_ext
19423fi
19424
19425CFLAGS="$saved_cflags"
Pablo Galindoba421752021-05-03 20:33:17 +010019426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_glibc_memmove_bug" >&5
19427printf "%s\n" "$have_glibc_memmove_bug" >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019428if test "$have_glibc_memmove_bug" = yes; then
19429
Pablo Galindoba421752021-05-03 20:33:17 +010019430printf "%s\n" "#define HAVE_GLIBC_MEMMOVE_BUG 1" >>confdefs.h
Stefan Krah1919b7e2012-03-21 18:25:23 +010019431
19432fi
19433
19434if test "$have_gcc_asm_for_x87" = yes; then
19435 # Some versions of gcc miscompile inline asm:
19436 # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46491
19437 # http://gcc.gnu.org/ml/gcc/2010-11/msg00366.html
19438 case $CC in
19439 *gcc*)
Pablo Galindoba421752021-05-03 20:33:17 +010019440 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gcc ipa-pure-const bug" >&5
19441printf %s "checking for gcc ipa-pure-const bug... " >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019442 saved_cflags="$CFLAGS"
19443 CFLAGS="-O2"
Pablo Galindoba421752021-05-03 20:33:17 +010019444 if test "$cross_compiling" = yes
19445then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010019446 have_ipa_pure_const_bug=undefined
Pablo Galindoba421752021-05-03 20:33:17 +010019447else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010019448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19449/* end confdefs.h. */
19450
19451 __attribute__((noinline)) int
19452 foo(int *p) {
19453 int r;
19454 asm ( "movl \$6, (%1)\n\t"
19455 "xorl %0, %0\n\t"
19456 : "=r" (r) : "r" (p) : "memory"
19457 );
19458 return r;
19459 }
19460 int main() {
19461 int p = 8;
19462 if ((foo(&p) ? : p) != 6)
19463 return 1;
19464 return 0;
19465 }
19466
19467_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019468if ac_fn_c_try_run "$LINENO"
19469then :
Stefan Krah1919b7e2012-03-21 18:25:23 +010019470 have_ipa_pure_const_bug=no
Pablo Galindoba421752021-05-03 20:33:17 +010019471else $as_nop
Stefan Krah1919b7e2012-03-21 18:25:23 +010019472 have_ipa_pure_const_bug=yes
19473fi
19474rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19475 conftest.$ac_objext conftest.beam conftest.$ac_ext
19476fi
19477
19478 CFLAGS="$saved_cflags"
Pablo Galindoba421752021-05-03 20:33:17 +010019479 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_ipa_pure_const_bug" >&5
19480printf "%s\n" "$have_ipa_pure_const_bug" >&6; }
Stefan Krah1919b7e2012-03-21 18:25:23 +010019481 if test "$have_ipa_pure_const_bug" = yes; then
19482
Pablo Galindoba421752021-05-03 20:33:17 +010019483printf "%s\n" "#define HAVE_IPA_PURE_CONST_BUG 1" >>confdefs.h
Stefan Krah1919b7e2012-03-21 18:25:23 +010019484
19485 fi
19486 ;;
19487 esac
19488fi
19489
Victor Stinner4f5366e2015-01-09 02:13:19 +010019490# Check for stdatomic.h
Pablo Galindoba421752021-05-03 20:33:17 +010019491{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdatomic.h" >&5
19492printf %s "checking for stdatomic.h... " >&6; }
Victor Stinner4f5366e2015-01-09 02:13:19 +010019493cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19494/* end confdefs.h. */
19495
19496
19497 #include <stdatomic.h>
Victor Stinner028f7342019-10-22 21:53:50 +020019498 atomic_int int_var;
19499 atomic_uintptr_t uintptr_var;
Victor Stinner4f5366e2015-01-09 02:13:19 +010019500 int main() {
Victor Stinner028f7342019-10-22 21:53:50 +020019501 atomic_store_explicit(&int_var, 5, memory_order_relaxed);
19502 atomic_store_explicit(&uintptr_var, 0, memory_order_relaxed);
19503 int loaded_value = atomic_load_explicit(&int_var, memory_order_seq_cst);
Victor Stinner4f5366e2015-01-09 02:13:19 +010019504 return 0;
19505 }
19506
19507
19508_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019509if ac_fn_c_try_link "$LINENO"
19510then :
Victor Stinner4f5366e2015-01-09 02:13:19 +010019511 have_stdatomic_h=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019512else $as_nop
Victor Stinner4f5366e2015-01-09 02:13:19 +010019513 have_stdatomic_h=no
19514fi
Pablo Galindoba421752021-05-03 20:33:17 +010019515rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinner4f5366e2015-01-09 02:13:19 +010019516 conftest$ac_exeext conftest.$ac_ext
19517
Pablo Galindoba421752021-05-03 20:33:17 +010019518{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_stdatomic_h" >&5
19519printf "%s\n" "$have_stdatomic_h" >&6; }
Victor Stinner4f5366e2015-01-09 02:13:19 +010019520
19521if test "$have_stdatomic_h" = yes; then
19522
Pablo Galindoba421752021-05-03 20:33:17 +010019523printf "%s\n" "#define HAVE_STD_ATOMIC 1" >>confdefs.h
Victor Stinner4f5366e2015-01-09 02:13:19 +010019524
19525fi
19526
Victor Stinner52a327c2020-12-23 03:41:08 +010019527# Check for GCC >= 4.7 and clang __atomic builtin functions
Pablo Galindoba421752021-05-03 20:33:17 +010019528{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic_load_n and __atomic_store_n functions" >&5
19529printf %s "checking for builtin __atomic_load_n and __atomic_store_n functions... " >&6; }
Victor Stinner4f5366e2015-01-09 02:13:19 +010019530cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19531/* end confdefs.h. */
19532
19533
Victor Stinner52a327c2020-12-23 03:41:08 +010019534 int val;
Victor Stinner4f5366e2015-01-09 02:13:19 +010019535 int main() {
Victor Stinner52a327c2020-12-23 03:41:08 +010019536 __atomic_store_n(&val, 1, __ATOMIC_SEQ_CST);
19537 (void)__atomic_load_n(&val, __ATOMIC_SEQ_CST);
Victor Stinner4f5366e2015-01-09 02:13:19 +010019538 return 0;
19539 }
19540
19541
19542_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019543if ac_fn_c_try_link "$LINENO"
19544then :
Victor Stinner4f5366e2015-01-09 02:13:19 +010019545 have_builtin_atomic=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019546else $as_nop
Victor Stinner4f5366e2015-01-09 02:13:19 +010019547 have_builtin_atomic=no
19548fi
Pablo Galindoba421752021-05-03 20:33:17 +010019549rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinner4f5366e2015-01-09 02:13:19 +010019550 conftest$ac_exeext conftest.$ac_ext
19551
Pablo Galindoba421752021-05-03 20:33:17 +010019552{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_builtin_atomic" >&5
19553printf "%s\n" "$have_builtin_atomic" >&6; }
Victor Stinner4f5366e2015-01-09 02:13:19 +010019554
19555if test "$have_builtin_atomic" = yes; then
19556
Pablo Galindoba421752021-05-03 20:33:17 +010019557printf "%s\n" "#define HAVE_BUILTIN_ATOMIC 1" >>confdefs.h
Victor Stinner4f5366e2015-01-09 02:13:19 +010019558
19559fi
19560
Ned Deily322f5ba2013-11-21 23:01:59 -080019561# ensurepip option
Pablo Galindoba421752021-05-03 20:33:17 +010019562{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ensurepip" >&5
19563printf %s "checking for ensurepip... " >&6; }
Ned Deily322f5ba2013-11-21 23:01:59 -080019564
19565# Check whether --with-ensurepip was given.
Pablo Galindoba421752021-05-03 20:33:17 +010019566if test ${with_ensurepip+y}
19567then :
Ned Deily322f5ba2013-11-21 23:01:59 -080019568 withval=$with_ensurepip;
Pablo Galindoba421752021-05-03 20:33:17 +010019569else $as_nop
Ned Deily322f5ba2013-11-21 23:01:59 -080019570 with_ensurepip=upgrade
19571fi
19572
19573case $with_ensurepip in #(
19574 yes|upgrade) :
19575 ENSUREPIP=upgrade ;; #(
19576 install) :
19577 ENSUREPIP=install ;; #(
19578 no) :
19579 ENSUREPIP=no ;; #(
19580 *) :
19581 as_fn_error $? "--with-ensurepip=upgrade|install|no" "$LINENO" 5 ;;
19582esac
Pablo Galindoba421752021-05-03 20:33:17 +010019583{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ENSUREPIP" >&5
19584printf "%s\n" "$ENSUREPIP" >&6; }
Ned Deily322f5ba2013-11-21 23:01:59 -080019585
19586
Victor Stinner35a97c02015-03-08 02:59:09 +010019587# check if the dirent structure of a d_type field and DT_UNKNOWN is defined
Pablo Galindoba421752021-05-03 20:33:17 +010019588{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the dirent structure of a d_type field" >&5
19589printf %s "checking if the dirent structure of a d_type field... " >&6; }
Victor Stinner35a97c02015-03-08 02:59:09 +010019590cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19591/* end confdefs.h. */
19592
19593
19594 #include <dirent.h>
19595
19596 int main() {
19597 struct dirent entry;
19598 return entry.d_type == DT_UNKNOWN;
19599 }
19600
19601
19602_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019603if ac_fn_c_try_link "$LINENO"
19604then :
Victor Stinner35a97c02015-03-08 02:59:09 +010019605 have_dirent_d_type=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019606else $as_nop
Victor Stinner35a97c02015-03-08 02:59:09 +010019607 have_dirent_d_type=no
19608fi
Pablo Galindoba421752021-05-03 20:33:17 +010019609rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinner35a97c02015-03-08 02:59:09 +010019610 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010019611{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_dirent_d_type" >&5
19612printf "%s\n" "$have_dirent_d_type" >&6; }
Victor Stinner35a97c02015-03-08 02:59:09 +010019613
19614if test "$have_dirent_d_type" = yes; then
19615
Pablo Galindoba421752021-05-03 20:33:17 +010019616printf "%s\n" "#define HAVE_DIRENT_D_TYPE 1" >>confdefs.h
Victor Stinner35a97c02015-03-08 02:59:09 +010019617
19618fi
19619
Victor Stinner9eb57c52015-03-19 22:21:49 +010019620# check if the Linux getrandom() syscall is available
Pablo Galindoba421752021-05-03 20:33:17 +010019621{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the Linux getrandom() syscall" >&5
19622printf %s "checking for the Linux getrandom() syscall... " >&6; }
Victor Stinner9eb57c52015-03-19 22:21:49 +010019623cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19624/* end confdefs.h. */
19625
19626
Victor Stinner1b80b242016-04-12 22:34:58 +020019627 #include <unistd.h>
Victor Stinner9eb57c52015-03-19 22:21:49 +010019628 #include <sys/syscall.h>
Victor Stinnerdddf4842016-06-07 11:21:42 +020019629 #include <linux/random.h>
Victor Stinner9eb57c52015-03-19 22:21:49 +010019630
19631 int main() {
Victor Stinner9eb57c52015-03-19 22:21:49 +010019632 char buffer[1];
Victor Stinner3abf44e2015-09-18 15:38:37 +020019633 const size_t buflen = sizeof(buffer);
Victor Stinnerdddf4842016-06-07 11:21:42 +020019634 const int flags = GRND_NONBLOCK;
19635 /* ignore the result, Python checks for ENOSYS and EAGAIN at runtime */
Victor Stinner3abf44e2015-09-18 15:38:37 +020019636 (void)syscall(SYS_getrandom, buffer, buflen, flags);
Victor Stinner9eb57c52015-03-19 22:21:49 +010019637 return 0;
19638 }
19639
19640
19641_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019642if ac_fn_c_try_link "$LINENO"
19643then :
Victor Stinner9eb57c52015-03-19 22:21:49 +010019644 have_getrandom_syscall=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019645else $as_nop
Victor Stinner9eb57c52015-03-19 22:21:49 +010019646 have_getrandom_syscall=no
19647fi
Pablo Galindoba421752021-05-03 20:33:17 +010019648rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinner9eb57c52015-03-19 22:21:49 +010019649 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010019650{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_getrandom_syscall" >&5
19651printf "%s\n" "$have_getrandom_syscall" >&6; }
Victor Stinner9eb57c52015-03-19 22:21:49 +010019652
19653if test "$have_getrandom_syscall" = yes; then
19654
Pablo Galindoba421752021-05-03 20:33:17 +010019655printf "%s\n" "#define HAVE_GETRANDOM_SYSCALL 1" >>confdefs.h
Victor Stinner9eb57c52015-03-19 22:21:49 +010019656
19657fi
19658
Victor Stinner3abf44e2015-09-18 15:38:37 +020019659# check if the getrandom() function is available
19660# the test was written for the Solaris function of <sys/random.h>
Pablo Galindoba421752021-05-03 20:33:17 +010019661{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the getrandom() function" >&5
19662printf %s "checking for the getrandom() function... " >&6; }
Victor Stinner3abf44e2015-09-18 15:38:37 +020019663cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19664/* end confdefs.h. */
19665
19666
19667 #include <sys/random.h>
19668
19669 int main() {
19670 char buffer[1];
19671 const size_t buflen = sizeof(buffer);
19672 const int flags = 0;
19673 /* ignore the result, Python checks for ENOSYS at runtime */
19674 (void)getrandom(buffer, buflen, flags);
19675 return 0;
19676 }
19677
19678
19679_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019680if ac_fn_c_try_link "$LINENO"
19681then :
Victor Stinner3abf44e2015-09-18 15:38:37 +020019682 have_getrandom=yes
Pablo Galindoba421752021-05-03 20:33:17 +010019683else $as_nop
Victor Stinner3abf44e2015-09-18 15:38:37 +020019684 have_getrandom=no
19685fi
Pablo Galindoba421752021-05-03 20:33:17 +010019686rm -f core conftest.err conftest.$ac_objext conftest.beam \
Victor Stinner3abf44e2015-09-18 15:38:37 +020019687 conftest$ac_exeext conftest.$ac_ext
Pablo Galindoba421752021-05-03 20:33:17 +010019688{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_getrandom" >&5
19689printf "%s\n" "$have_getrandom" >&6; }
Victor Stinner3abf44e2015-09-18 15:38:37 +020019690
19691if test "$have_getrandom" = yes; then
19692
Pablo Galindoba421752021-05-03 20:33:17 +010019693printf "%s\n" "#define HAVE_GETRANDOM 1" >>confdefs.h
Victor Stinner3abf44e2015-09-18 15:38:37 +020019694
19695fi
19696
Neil Schemenauer5741c452019-02-08 10:48:46 -080019697# checks for POSIX shared memory, used by Modules/_multiprocessing/posixshmem.c
19698# shm_* may only be available if linking against librt
19699save_LIBS="$LIBS"
19700save_includes_default="$ac_includes_default"
Pablo Galindoba421752021-05-03 20:33:17 +010019701{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing shm_open" >&5
19702printf %s "checking for library containing shm_open... " >&6; }
19703if test ${ac_cv_search_shm_open+y}
19704then :
19705 printf %s "(cached) " >&6
19706else $as_nop
Neil Schemenauer5741c452019-02-08 10:48:46 -080019707 ac_func_search_save_LIBS=$LIBS
19708cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19709/* end confdefs.h. */
19710
19711/* Override any GCC internal prototype to avoid an error.
19712 Use char because int might match the return type of a GCC
19713 builtin and then its argument prototype would still apply. */
Neil Schemenauer5741c452019-02-08 10:48:46 -080019714char shm_open ();
19715int
Pablo Galindoba421752021-05-03 20:33:17 +010019716main (void)
Neil Schemenauer5741c452019-02-08 10:48:46 -080019717{
19718return shm_open ();
19719 ;
19720 return 0;
19721}
19722_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019723for ac_lib in '' rt
19724do
Neil Schemenauer5741c452019-02-08 10:48:46 -080019725 if test -z "$ac_lib"; then
19726 ac_res="none required"
19727 else
19728 ac_res=-l$ac_lib
19729 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19730 fi
Pablo Galindoba421752021-05-03 20:33:17 +010019731 if ac_fn_c_try_link "$LINENO"
19732then :
Neil Schemenauer5741c452019-02-08 10:48:46 -080019733 ac_cv_search_shm_open=$ac_res
19734fi
Pablo Galindoba421752021-05-03 20:33:17 +010019735rm -f core conftest.err conftest.$ac_objext conftest.beam \
Neil Schemenauer5741c452019-02-08 10:48:46 -080019736 conftest$ac_exeext
Pablo Galindoba421752021-05-03 20:33:17 +010019737 if test ${ac_cv_search_shm_open+y}
19738then :
Neil Schemenauer5741c452019-02-08 10:48:46 -080019739 break
19740fi
19741done
Pablo Galindoba421752021-05-03 20:33:17 +010019742if test ${ac_cv_search_shm_open+y}
19743then :
Neil Schemenauer5741c452019-02-08 10:48:46 -080019744
Pablo Galindoba421752021-05-03 20:33:17 +010019745else $as_nop
Neil Schemenauer5741c452019-02-08 10:48:46 -080019746 ac_cv_search_shm_open=no
19747fi
19748rm conftest.$ac_ext
19749LIBS=$ac_func_search_save_LIBS
19750fi
Pablo Galindoba421752021-05-03 20:33:17 +010019751{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_open" >&5
19752printf "%s\n" "$ac_cv_search_shm_open" >&6; }
Neil Schemenauer5741c452019-02-08 10:48:46 -080019753ac_res=$ac_cv_search_shm_open
Pablo Galindoba421752021-05-03 20:33:17 +010019754if test "$ac_res" != no
19755then :
Neil Schemenauer5741c452019-02-08 10:48:46 -080019756 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19757
19758fi
19759
19760if test "$ac_cv_search_shm_open" = "-lrt"; then
19761
Pablo Galindoba421752021-05-03 20:33:17 +010019762printf "%s\n" "#define SHM_NEEDS_LIBRT 1" >>confdefs.h
Neil Schemenauer5741c452019-02-08 10:48:46 -080019763
19764fi
Pablo Galindoba421752021-05-03 20:33:17 +010019765ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
19766if test "x$ac_cv_header_sys_mman_h" = xyes
19767then :
19768 printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h
Neil Schemenauer5741c452019-02-08 10:48:46 -080019769
19770fi
19771
Neil Schemenauer5741c452019-02-08 10:48:46 -080019772# temporarily override ac_includes_default for AC_CHECK_FUNCS below
19773ac_includes_default="\
19774${ac_includes_default}
19775#ifndef __cplusplus
19776# ifdef HAVE_SYS_MMAN_H
19777# include <sys/mman.h>
19778# endif
19779#endif
19780"
Pablo Galindoba421752021-05-03 20:33:17 +010019781ac_fn_c_check_func "$LINENO" "shm_open" "ac_cv_func_shm_open"
19782if test "x$ac_cv_func_shm_open" = xyes
19783then :
19784 printf "%s\n" "#define HAVE_SHM_OPEN 1" >>confdefs.h
Neil Schemenauer5741c452019-02-08 10:48:46 -080019785
19786fi
Pablo Galindoba421752021-05-03 20:33:17 +010019787ac_fn_c_check_func "$LINENO" "shm_unlink" "ac_cv_func_shm_unlink"
19788if test "x$ac_cv_func_shm_unlink" = xyes
19789then :
19790 printf "%s\n" "#define HAVE_SHM_UNLINK 1" >>confdefs.h
19791
19792fi
Neil Schemenauer5741c452019-02-08 10:48:46 -080019793
19794# we don't want to link with librt always, restore LIBS
19795LIBS="$save_LIBS"
19796ac_includes_default="$save_includes_default"
19797
Christian Heimesff5be6e2018-01-20 13:19:21 +010019798# Check for usable OpenSSL
19799
19800 found=false
19801
19802# Check whether --with-openssl was given.
Pablo Galindoba421752021-05-03 20:33:17 +010019803if test ${with_openssl+y}
19804then :
Christian Heimesff5be6e2018-01-20 13:19:21 +010019805 withval=$with_openssl;
19806 case "$withval" in
19807 "" | y | ye | yes | n | no)
19808 as_fn_error $? "Invalid --with-openssl value" "$LINENO" 5
19809 ;;
19810 *) ssldirs="$withval"
19811 ;;
19812 esac
19813
Pablo Galindoba421752021-05-03 20:33:17 +010019814else $as_nop
Christian Heimesff5be6e2018-01-20 13:19:21 +010019815
19816 # if pkg-config is installed and openssl has installed a .pc file,
19817 # then use that information and don't search ssldirs
19818 if test -n "$ac_tool_prefix"; then
19819 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
19820set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010019821{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19822printf %s "checking for $ac_word... " >&6; }
19823if test ${ac_cv_prog_PKG_CONFIG+y}
19824then :
19825 printf %s "(cached) " >&6
19826else $as_nop
Christian Heimesff5be6e2018-01-20 13:19:21 +010019827 if test -n "$PKG_CONFIG"; then
19828 ac_cv_prog_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test.
19829else
19830as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19831for as_dir in $PATH
19832do
19833 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010019834 case $as_dir in #(((
19835 '') as_dir=./ ;;
19836 */) ;;
19837 *) as_dir=$as_dir/ ;;
19838 esac
Christian Heimesff5be6e2018-01-20 13:19:21 +010019839 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010019840 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Christian Heimesff5be6e2018-01-20 13:19:21 +010019841 ac_cv_prog_PKG_CONFIG="${ac_tool_prefix}pkg-config"
Pablo Galindoba421752021-05-03 20:33:17 +010019842 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Christian Heimesff5be6e2018-01-20 13:19:21 +010019843 break 2
19844 fi
19845done
19846 done
19847IFS=$as_save_IFS
19848
19849fi
19850fi
19851PKG_CONFIG=$ac_cv_prog_PKG_CONFIG
19852if test -n "$PKG_CONFIG"; then
Pablo Galindoba421752021-05-03 20:33:17 +010019853 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19854printf "%s\n" "$PKG_CONFIG" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019855else
Pablo Galindoba421752021-05-03 20:33:17 +010019856 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19857printf "%s\n" "no" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019858fi
19859
19860
19861fi
19862if test -z "$ac_cv_prog_PKG_CONFIG"; then
19863 ac_ct_PKG_CONFIG=$PKG_CONFIG
19864 # Extract the first word of "pkg-config", so it can be a program name with args.
19865set dummy pkg-config; ac_word=$2
Pablo Galindoba421752021-05-03 20:33:17 +010019866{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19867printf %s "checking for $ac_word... " >&6; }
19868if test ${ac_cv_prog_ac_ct_PKG_CONFIG+y}
19869then :
19870 printf %s "(cached) " >&6
19871else $as_nop
Christian Heimesff5be6e2018-01-20 13:19:21 +010019872 if test -n "$ac_ct_PKG_CONFIG"; then
19873 ac_cv_prog_ac_ct_PKG_CONFIG="$ac_ct_PKG_CONFIG" # Let the user override the test.
19874else
19875as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19876for as_dir in $PATH
19877do
19878 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010019879 case $as_dir in #(((
19880 '') as_dir=./ ;;
19881 */) ;;
19882 *) as_dir=$as_dir/ ;;
19883 esac
Christian Heimesff5be6e2018-01-20 13:19:21 +010019884 for ac_exec_ext in '' $ac_executable_extensions; do
Pablo Galindoba421752021-05-03 20:33:17 +010019885 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
Christian Heimesff5be6e2018-01-20 13:19:21 +010019886 ac_cv_prog_ac_ct_PKG_CONFIG="pkg-config"
Pablo Galindoba421752021-05-03 20:33:17 +010019887 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
Christian Heimesff5be6e2018-01-20 13:19:21 +010019888 break 2
19889 fi
19890done
19891 done
19892IFS=$as_save_IFS
19893
19894fi
19895fi
19896ac_ct_PKG_CONFIG=$ac_cv_prog_ac_ct_PKG_CONFIG
19897if test -n "$ac_ct_PKG_CONFIG"; then
Pablo Galindoba421752021-05-03 20:33:17 +010019898 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PKG_CONFIG" >&5
19899printf "%s\n" "$ac_ct_PKG_CONFIG" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019900else
Pablo Galindoba421752021-05-03 20:33:17 +010019901 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19902printf "%s\n" "no" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019903fi
19904
19905 if test "x$ac_ct_PKG_CONFIG" = x; then
19906 PKG_CONFIG=""
19907 else
19908 case $cross_compiling:$ac_tool_warned in
19909yes:)
Pablo Galindoba421752021-05-03 20:33:17 +010019910{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19911printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
Christian Heimesff5be6e2018-01-20 13:19:21 +010019912ac_tool_warned=yes ;;
19913esac
19914 PKG_CONFIG=$ac_ct_PKG_CONFIG
19915 fi
19916else
19917 PKG_CONFIG="$ac_cv_prog_PKG_CONFIG"
19918fi
19919
19920 if test x"$PKG_CONFIG" != x""; then
19921 OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
19922 if test $? = 0; then
19923 OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
19924 OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
19925 found=true
19926 fi
19927 fi
19928
19929 # no such luck; use some default ssldirs
19930 if ! $found; then
19931 ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
19932 fi
19933
19934
19935fi
19936
19937
19938
19939 # note that we #include <openssl/foo.h>, so the OpenSSL headers have to be in
19940 # an 'openssl' subdirectory
19941
19942 if ! $found; then
19943 OPENSSL_INCLUDES=
19944 for ssldir in $ssldirs; do
Pablo Galindoba421752021-05-03 20:33:17 +010019945 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl/ssl.h in $ssldir" >&5
19946printf %s "checking for openssl/ssl.h in $ssldir... " >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019947 if test -f "$ssldir/include/openssl/ssl.h"; then
19948 OPENSSL_INCLUDES="-I$ssldir/include"
19949 OPENSSL_LDFLAGS="-L$ssldir/lib"
19950 OPENSSL_LIBS="-lssl -lcrypto"
19951 found=true
Pablo Galindoba421752021-05-03 20:33:17 +010019952 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19953printf "%s\n" "yes" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019954 break
19955 else
Pablo Galindoba421752021-05-03 20:33:17 +010019956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19957printf "%s\n" "no" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019958 fi
19959 done
19960
19961 # if the file wasn't found, well, go ahead and try the link anyway -- maybe
19962 # it will just work!
19963 fi
19964
19965 # try the preprocessor and linker with our new flags,
19966 # being careful not to pollute the global LIBS, LDFLAGS, and CPPFLAGS
19967
Pablo Galindoba421752021-05-03 20:33:17 +010019968 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether compiling and linking against OpenSSL works" >&5
19969printf %s "checking whether compiling and linking against OpenSSL works... " >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019970 echo "Trying link with OPENSSL_LDFLAGS=$OPENSSL_LDFLAGS;" \
19971 "OPENSSL_LIBS=$OPENSSL_LIBS; OPENSSL_INCLUDES=$OPENSSL_INCLUDES" >&5
19972
19973 save_LIBS="$LIBS"
19974 save_LDFLAGS="$LDFLAGS"
19975 save_CPPFLAGS="$CPPFLAGS"
19976 LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS"
19977 LIBS="$OPENSSL_LIBS $LIBS"
19978 CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS"
19979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19980/* end confdefs.h. */
19981#include <openssl/ssl.h>
19982int
Pablo Galindoba421752021-05-03 20:33:17 +010019983main (void)
Christian Heimesff5be6e2018-01-20 13:19:21 +010019984{
19985SSL_new(NULL)
19986 ;
19987 return 0;
19988}
19989_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010019990if ac_fn_c_try_link "$LINENO"
19991then :
Christian Heimesff5be6e2018-01-20 13:19:21 +010019992
Pablo Galindoba421752021-05-03 20:33:17 +010019993 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19994printf "%s\n" "yes" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010019995 have_openssl=yes
19996
Pablo Galindoba421752021-05-03 20:33:17 +010019997else $as_nop
Christian Heimesff5be6e2018-01-20 13:19:21 +010019998
Pablo Galindoba421752021-05-03 20:33:17 +010019999 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20000printf "%s\n" "no" >&6; }
Christian Heimesff5be6e2018-01-20 13:19:21 +010020001 have_openssl=no
20002
20003fi
Pablo Galindoba421752021-05-03 20:33:17 +010020004rm -f core conftest.err conftest.$ac_objext conftest.beam \
Christian Heimesff5be6e2018-01-20 13:19:21 +010020005 conftest$ac_exeext conftest.$ac_ext
20006 CPPFLAGS="$save_CPPFLAGS"
20007 LDFLAGS="$save_LDFLAGS"
20008 LIBS="$save_LIBS"
20009
20010
20011
20012
20013
20014
Christian Heimes32eba612021-03-19 10:29:25 +010020015# rpath to libssl and libcrypto
Pablo Galindoba421752021-05-03 20:33:17 +010020016{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-openssl-rpath" >&5
20017printf %s "checking for --with-openssl-rpath... " >&6; }
Christian Heimes32eba612021-03-19 10:29:25 +010020018
20019# Check whether --with-openssl-rpath was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020020if test ${with_openssl_rpath+y}
20021then :
Christian Heimes32eba612021-03-19 10:29:25 +010020022 withval=$with_openssl_rpath;
Pablo Galindoba421752021-05-03 20:33:17 +010020023else $as_nop
Christian Heimes32eba612021-03-19 10:29:25 +010020024 with_openssl_rpath=no
20025
20026fi
20027
20028case $with_openssl_rpath in #(
20029 auto|yes) :
20030 OPENSSL_RPATH=auto ;; #(
20031 no) :
20032 OPENSSL_RPATH= ;; #(
20033 *) :
Pablo Galindoba421752021-05-03 20:33:17 +010020034 if test -d "$with_openssl_rpath"
20035then :
Christian Heimes32eba612021-03-19 10:29:25 +010020036 OPENSSL_RPATH="$with_openssl_rpath"
Pablo Galindoba421752021-05-03 20:33:17 +010020037else $as_nop
Christian Heimes32eba612021-03-19 10:29:25 +010020038 as_fn_error $? "--with-openssl-rpath \"$with_openssl_rpath\" is not a directory" "$LINENO" 5
20039fi
20040
20041 ;;
20042esac
Pablo Galindoba421752021-05-03 20:33:17 +010020043{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OPENSSL_RPATH" >&5
20044printf "%s\n" "$OPENSSL_RPATH" >&6; }
Christian Heimes32eba612021-03-19 10:29:25 +010020045
20046
Christian Heimes892d66e2018-01-29 14:10:18 +010020047# ssl module default cipher suite string
20048
20049
20050
Pablo Galindoba421752021-05-03 20:33:17 +010020051{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-ssl-default-suites" >&5
20052printf %s "checking for --with-ssl-default-suites... " >&6; }
Christian Heimes892d66e2018-01-29 14:10:18 +010020053
20054# Check whether --with-ssl-default-suites was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020055if test ${with_ssl_default_suites+y}
20056then :
Christian Heimes892d66e2018-01-29 14:10:18 +010020057 withval=$with_ssl_default_suites;
Pablo Galindoba421752021-05-03 20:33:17 +010020058{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
20059printf "%s\n" "$withval" >&6; }
Christian Heimes892d66e2018-01-29 14:10:18 +010020060case "$withval" in
20061 python)
Pablo Galindoba421752021-05-03 20:33:17 +010020062 printf "%s\n" "#define PY_SSL_DEFAULT_CIPHERS 1" >>confdefs.h
Christian Heimes892d66e2018-01-29 14:10:18 +010020063
20064 ;;
20065 openssl)
Pablo Galindoba421752021-05-03 20:33:17 +010020066 printf "%s\n" "#define PY_SSL_DEFAULT_CIPHERS 2" >>confdefs.h
Christian Heimes892d66e2018-01-29 14:10:18 +010020067
20068 ;;
20069 *)
Pablo Galindoba421752021-05-03 20:33:17 +010020070 printf "%s\n" "#define PY_SSL_DEFAULT_CIPHERS 0" >>confdefs.h
Christian Heimes892d66e2018-01-29 14:10:18 +010020071
Pablo Galindoba421752021-05-03 20:33:17 +010020072 printf "%s\n" "#define PY_SSL_DEFAULT_CIPHER_STRING \"$withval\"" >>confdefs.h
Christian Heimes892d66e2018-01-29 14:10:18 +010020073
20074 ;;
20075esac
20076
Pablo Galindoba421752021-05-03 20:33:17 +010020077else $as_nop
Christian Heimes892d66e2018-01-29 14:10:18 +010020078
Pablo Galindoba421752021-05-03 20:33:17 +010020079{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: python" >&5
20080printf "%s\n" "python" >&6; }
20081printf "%s\n" "#define PY_SSL_DEFAULT_CIPHERS 1" >>confdefs.h
Christian Heimes892d66e2018-01-29 14:10:18 +010020082
20083
20084fi
20085
20086
Christian Heimes9b60e552020-05-15 23:54:53 +020020087# builtin hash modules
20088default_hashlib_hashes="md5,sha1,sha256,sha512,sha3,blake2"
20089
Pablo Galindoba421752021-05-03 20:33:17 +010020090printf "%s\n" "#define PY_BUILTIN_HASHLIB_HASHES /**/" >>confdefs.h
Christian Heimes9b60e552020-05-15 23:54:53 +020020091
Pablo Galindoba421752021-05-03 20:33:17 +010020092{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-builtin-hashlib-hashes" >&5
20093printf %s "checking for --with-builtin-hashlib-hashes... " >&6; }
Christian Heimes9b60e552020-05-15 23:54:53 +020020094
20095# Check whether --with-builtin-hashlib-hashes was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020096if test ${with_builtin_hashlib_hashes+y}
20097then :
Christian Heimes9b60e552020-05-15 23:54:53 +020020098 withval=$with_builtin_hashlib_hashes;
20099case "$withval" in
20100 yes)
20101 withval=$default_hashlib_hashes
20102 ;;
20103 no)
20104 withval=""
20105 ;;
20106esac
Pablo Galindoba421752021-05-03 20:33:17 +010020107{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
20108printf "%s\n" "$withval" >&6; }
20109printf "%s\n" "#define PY_BUILTIN_HASHLIB_HASHES \"$withval\"" >>confdefs.h
Christian Heimes9b60e552020-05-15 23:54:53 +020020110
20111
Pablo Galindoba421752021-05-03 20:33:17 +010020112else $as_nop
Christian Heimes9b60e552020-05-15 23:54:53 +020020113
Pablo Galindoba421752021-05-03 20:33:17 +010020114{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $default_hashlib_hashes" >&5
20115printf "%s\n" "$default_hashlib_hashes" >&6; };
20116printf "%s\n" "#define PY_BUILTIN_HASHLIB_HASHES \"$default_hashlib_hashes\"" >>confdefs.h
Christian Heimes9b60e552020-05-15 23:54:53 +020020117
20118
20119fi
20120
20121
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020122# --with-experimental-isolated-subinterpreters
20123
Pablo Galindoba421752021-05-03 20:33:17 +010020124{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-experimental-isolated-subinterpreters" >&5
20125printf %s "checking for --with-experimental-isolated-subinterpreters... " >&6; }
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020126
20127# Check whether --with-experimental-isolated-subinterpreters was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020128if test ${with_experimental_isolated_subinterpreters+y}
20129then :
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020130 withval=$with_experimental_isolated_subinterpreters;
20131if test "$withval" != no
20132then
Pablo Galindoba421752021-05-03 20:33:17 +010020133 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20134printf "%s\n" "yes" >&6; };
20135 printf "%s\n" "#define EXPERIMENTAL_ISOLATED_SUBINTERPRETERS 1" >>confdefs.h
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020136
20137else
Pablo Galindoba421752021-05-03 20:33:17 +010020138 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20139printf "%s\n" "no" >&6; };
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020140fi
Pablo Galindoba421752021-05-03 20:33:17 +010020141else $as_nop
20142 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20143printf "%s\n" "no" >&6; }
Victor Stinnerc5fa3642020-05-05 16:41:11 +020020144fi
20145
20146
Victor Stinner801bb0b2021-02-17 11:14:42 +010020147# --with-static-libpython
20148STATIC_LIBPYTHON=1
Pablo Galindoba421752021-05-03 20:33:17 +010020149{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --with-static-libpython" >&5
20150printf %s "checking for --with-static-libpython... " >&6; }
Victor Stinner801bb0b2021-02-17 11:14:42 +010020151
20152# Check whether --with-static-libpython was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020153if test ${with_static_libpython+y}
20154then :
Victor Stinner801bb0b2021-02-17 11:14:42 +010020155 withval=$with_static_libpython;
20156if test "$withval" = no
20157then
Pablo Galindoba421752021-05-03 20:33:17 +010020158 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20159printf "%s\n" "no" >&6; };
Victor Stinner801bb0b2021-02-17 11:14:42 +010020160 STATIC_LIBPYTHON=0
20161else
Pablo Galindoba421752021-05-03 20:33:17 +010020162 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20163printf "%s\n" "yes" >&6; };
Victor Stinner801bb0b2021-02-17 11:14:42 +010020164fi
Pablo Galindoba421752021-05-03 20:33:17 +010020165else $as_nop
20166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20167printf "%s\n" "yes" >&6; }
Victor Stinner801bb0b2021-02-17 11:14:42 +010020168fi
20169
20170LIBRARY_DEPS='$(PY3LIBRARY) $(EXPORTSYMS)'
Ned Deily06084252021-03-01 02:04:02 -050020171if test "$PY_ENABLE_SHARED" = 1 || test "$enable_framework" ; then
Victor Stinner801bb0b2021-02-17 11:14:42 +010020172 LIBRARY_DEPS="\$(LDLIBRARY) $LIBRARY_DEPS"
20173 if test "$STATIC_LIBPYTHON" = 1; then
20174 LIBRARY_DEPS="\$(LIBRARY) $LIBRARY_DEPS"
20175 fi
20176else
20177 LIBRARY_DEPS="\$(LIBRARY) $LIBRARY_DEPS"
20178fi
20179
20180
20181
pxinwr277ce302020-12-30 20:50:39 +080020182# Check whether to disable test modules. Once set, setup.py will not build
20183# test extension modules and "make install" will not install test suites.
Pablo Galindoba421752021-05-03 20:33:17 +010020184{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for --disable-test-modules" >&5
20185printf %s "checking for --disable-test-modules... " >&6; }
pxinwr277ce302020-12-30 20:50:39 +080020186# Check whether --enable-test-modules was given.
Pablo Galindoba421752021-05-03 20:33:17 +010020187if test ${enable_test_modules+y}
20188then :
pxinwr277ce302020-12-30 20:50:39 +080020189 enableval=$enable_test_modules;
20190fi
20191
20192if test "$enable_test_modules" = no; then
20193 TEST_MODULES=no
Pablo Galindoba421752021-05-03 20:33:17 +010020194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20195printf "%s\n" "yes" >&6; }
pxinwr277ce302020-12-30 20:50:39 +080020196else
20197 TEST_MODULES=yes
Pablo Galindoba421752021-05-03 20:33:17 +010020198 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20199printf "%s\n" "no" >&6; }
pxinwr277ce302020-12-30 20:50:39 +080020200fi
20201
20202
Christian Heimes892d66e2018-01-29 14:10:18 +010020203
Guido van Rossum627b2d71993-12-24 10:39:16 +000020204# generate output files
Victor Stinner0a8e5722019-05-23 03:30:23 +020020205ac_config_files="$ac_config_files Makefile.pre Misc/python.pc Misc/python-embed.pc Misc/python-config.sh"
Martin v. Löwis88afe662002-10-26 13:47:44 +000020206
Antoine Pitrou8e6b4072010-09-10 19:44:44 +000020207ac_config_files="$ac_config_files Modules/ld_so_aix"
20208
Martin v. Löwis11437992002-04-12 09:54:03 +000020209cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020210# This file is a shell script that caches the results of configure
20211# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000020212# scripts and configure runs, see configure's option --config-cache.
20213# It is not useful on other systems. If it contains results you don't
20214# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020215#
Martin v. Löwis11437992002-04-12 09:54:03 +000020216# config.status only pays attention to the cache file if you give it
20217# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020218#
Skip Montanaro6dead952003-09-25 14:50:04 +000020219# `ac_cv_env_foo' variables (set or unset) will be overridden when
Martin v. Löwis11437992002-04-12 09:54:03 +000020220# loading this file, other *unset* `ac_cv_foo' will be assigned the
20221# following values.
20222
20223_ACEOF
20224
Guido van Rossumf78abae1997-01-21 22:02:36 +000020225# The following way of writing the cache mishandles newlines in values,
20226# but we know of no workaround that is simple, portable, and efficient.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020227# So, we kill variables containing newlines.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000020228# Ultrix sh set writes to stderr and can't be redirected directly,
20229# and sets the high bit in the cache file unless we assign to the vars.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020230(
20231 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
20232 eval ac_val=\$$ac_var
20233 case $ac_val in #(
20234 *${as_nl}*)
20235 case $ac_var in #(
Pablo Galindoba421752021-05-03 20:33:17 +010020236 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
20237printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020238 esac
20239 case $ac_var in #(
20240 _ | IFS | as_nl) ;; #(
Matthias Kloseb9621712010-04-24 17:59:49 +000020241 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
20242 *) { eval $ac_var=; unset $ac_var;} ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020243 esac ;;
20244 esac
20245 done
20246
Martin v. Löwis11437992002-04-12 09:54:03 +000020247 (set) 2>&1 |
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020248 case $as_nl`(ac_space=' '; set) 2>&1` in #(
20249 *${as_nl}ac_space=\ *)
Matthias Kloseb9621712010-04-24 17:59:49 +000020250 # `set' does not quote correctly, so add quotes: double-quote
20251 # substitution turns \\\\ into \\, and sed turns \\ into \.
Martin v. Löwis11437992002-04-12 09:54:03 +000020252 sed -n \
Skip Montanarof0d5f792004-08-15 14:08:23 +000020253 "s/'/'\\\\''/g;
20254 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020255 ;; #(
Martin v. Löwis11437992002-04-12 09:54:03 +000020256 *)
20257 # `set' quotes correctly as required by POSIX, so do not add quotes.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020258 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Martin v. Löwis11437992002-04-12 09:54:03 +000020259 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020260 esac |
20261 sort
20262) |
Martin v. Löwis11437992002-04-12 09:54:03 +000020263 sed '
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020264 /^ac_cv_env_/b end
Martin v. Löwis11437992002-04-12 09:54:03 +000020265 t clear
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020266 :clear
Pablo Galindoba421752021-05-03 20:33:17 +010020267 s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
Martin v. Löwis11437992002-04-12 09:54:03 +000020268 t end
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020269 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
20270 :end' >>confcache
20271if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
20272 if test -w "$cache_file"; then
Victor Stinnere0be4232011-10-25 13:06:09 +020020273 if test "x$cache_file" != "x/dev/null"; then
Pablo Galindoba421752021-05-03 20:33:17 +010020274 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
20275printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
Victor Stinnere0be4232011-10-25 13:06:09 +020020276 if test ! -f "$cache_file" || test -h "$cache_file"; then
20277 cat confcache >"$cache_file"
20278 else
20279 case $cache_file in #(
20280 */* | ?:*)
20281 mv -f confcache "$cache_file"$$ &&
20282 mv -f "$cache_file"$$ "$cache_file" ;; #(
20283 *)
20284 mv -f confcache "$cache_file" ;;
20285 esac
20286 fi
20287 fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000020288 else
Pablo Galindoba421752021-05-03 20:33:17 +010020289 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
20290printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000020291 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020292fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000020293rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000020294
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020295test "x$prefix" = xNONE && prefix=$ac_default_prefix
20296# Let make expand exec_prefix.
20297test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000020298
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020299DEFS=-DHAVE_CONFIG_H
20300
Skip Montanaro6dead952003-09-25 14:50:04 +000020301ac_libobjs=
20302ac_ltlibobjs=
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020303U=
Skip Montanaro6dead952003-09-25 14:50:04 +000020304for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
20305 # 1. Remove the extension, and $U if already installed.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020306 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
Pablo Galindoba421752021-05-03 20:33:17 +010020307 ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020308 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
20309 # will be set to the directory where LIBOBJS objects are built.
Matthias Kloseb9621712010-04-24 17:59:49 +000020310 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
20311 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
Skip Montanaro6dead952003-09-25 14:50:04 +000020312done
20313LIBOBJS=$ac_libobjs
20314
20315LTLIBOBJS=$ac_ltlibobjs
20316
20317
Martin v. Löwis11437992002-04-12 09:54:03 +000020318
Matthias Kloseb9621712010-04-24 17:59:49 +000020319
Victor Stinnere0be4232011-10-25 13:06:09 +020020320: "${CONFIG_STATUS=./config.status}"
Matthias Kloseb9621712010-04-24 17:59:49 +000020321ac_write_fail=0
Martin v. Löwis11437992002-04-12 09:54:03 +000020322ac_clean_files_save=$ac_clean_files
20323ac_clean_files="$ac_clean_files $CONFIG_STATUS"
Pablo Galindoba421752021-05-03 20:33:17 +010020324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
20325printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
Matthias Kloseb9621712010-04-24 17:59:49 +000020326as_write_fail=0
20327cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000020328#! $SHELL
20329# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000020330# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020331# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000020332# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000020333
Martin v. Löwis11437992002-04-12 09:54:03 +000020334debug=false
Skip Montanaro6dead952003-09-25 14:50:04 +000020335ac_cs_recheck=false
20336ac_cs_silent=false
Jack Jansendd19cf82001-12-06 22:36:17 +000020337
Matthias Kloseb9621712010-04-24 17:59:49 +000020338SHELL=\${CONFIG_SHELL-$SHELL}
20339export SHELL
20340_ASEOF
20341cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
20342## -------------------- ##
20343## M4sh Initialization. ##
20344## -------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000020345
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020346# Be more Bourne compatible
20347DUALCASE=1; export DUALCASE # for MKS sh
Pablo Galindoba421752021-05-03 20:33:17 +010020348as_nop=:
20349if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
20350then :
Martin v. Löwis11437992002-04-12 09:54:03 +000020351 emulate sh
20352 NULLCMD=:
Matthias Kloseb9621712010-04-24 17:59:49 +000020353 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
Skip Montanaro6dead952003-09-25 14:50:04 +000020354 # is contrary to our usage. Disable this feature.
20355 alias -g '${1+"$@"}'='"$@"'
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020356 setopt NO_GLOB_SUBST
Pablo Galindoba421752021-05-03 20:33:17 +010020357else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000020358 case `(set -o) 2>/dev/null` in #(
20359 *posix*) :
20360 set -o posix ;; #(
20361 *) :
20362 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020363esac
Michael W. Hudson54241132001-12-07 15:38:26 +000020364fi
Thomas Wouters89f507f2006-12-13 04:49:30 +000020365
20366
Pablo Galindoba421752021-05-03 20:33:17 +010020367
20368# Reset variables that may have inherited troublesome values from
20369# the environment.
20370
20371# IFS needs to be set, to space, tab, and newline, in precisely that order.
20372# (If _AS_PATH_WALK were called with IFS unset, it would have the
20373# side effect of setting IFS to empty, thus disabling word splitting.)
20374# Quoting is to prevent editors from complaining about space-tab.
Matthias Kloseb9621712010-04-24 17:59:49 +000020375as_nl='
20376'
20377export as_nl
Pablo Galindoba421752021-05-03 20:33:17 +010020378IFS=" "" $as_nl"
20379
20380PS1='$ '
20381PS2='> '
20382PS4='+ '
20383
20384# Ensure predictable behavior from utilities with locale-dependent output.
20385LC_ALL=C
20386export LC_ALL
20387LANGUAGE=C
20388export LANGUAGE
20389
20390# We cannot yet rely on "unset" to work, but we need these variables
20391# to be unset--not just set to an empty or harmless value--now, to
20392# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
20393# also avoids known problems related to "unset" and subshell syntax
20394# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
20395for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
20396do eval test \${$as_var+y} \
20397 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
20398done
20399
20400# Ensure that fds 0, 1, and 2 are open.
20401if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
20402if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
20403if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
Martin v. Löwis11437992002-04-12 09:54:03 +000020404
20405# The user is always right.
Pablo Galindoba421752021-05-03 20:33:17 +010020406if ${PATH_SEPARATOR+false} :; then
Matthias Kloseb9621712010-04-24 17:59:49 +000020407 PATH_SEPARATOR=:
20408 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
20409 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
20410 PATH_SEPARATOR=';'
20411 }
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020412fi
Martin v. Löwis11437992002-04-12 09:54:03 +000020413
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020414
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020415# Find who we are. Look in the path if we contain no directory separator.
Victor Stinnere0be4232011-10-25 13:06:09 +020020416as_myself=
Matthias Kloseb9621712010-04-24 17:59:49 +000020417case $0 in #((
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020418 *[\\/]* ) as_myself=$0 ;;
20419 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +000020420for as_dir in $PATH
20421do
20422 IFS=$as_save_IFS
Pablo Galindoba421752021-05-03 20:33:17 +010020423 case $as_dir in #(((
20424 '') as_dir=./ ;;
20425 */) ;;
20426 *) as_dir=$as_dir/ ;;
20427 esac
20428 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
Matthias Kloseb9621712010-04-24 17:59:49 +000020429 done
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020430IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +000020431
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020432 ;;
20433esac
20434# We did not find ourselves, most probably we were run as `sh COMMAND'
20435# in which case we are not to be found in the path.
20436if test "x$as_myself" = x; then
20437 as_myself=$0
20438fi
20439if test ! -f "$as_myself"; then
Pablo Galindoba421752021-05-03 20:33:17 +010020440 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Matthias Kloseb9621712010-04-24 17:59:49 +000020441 exit 1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020442fi
20443
Matthias Kloseb9621712010-04-24 17:59:49 +000020444
20445
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020446# as_fn_error STATUS ERROR [LINENO LOG_FD]
20447# ----------------------------------------
Matthias Kloseb9621712010-04-24 17:59:49 +000020448# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
20449# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020450# script with STATUS, using 1 if that was 0.
Matthias Kloseb9621712010-04-24 17:59:49 +000020451as_fn_error ()
20452{
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020453 as_status=$1; test $as_status -eq 0 && as_status=1
20454 if test "$4"; then
20455 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
Pablo Galindoba421752021-05-03 20:33:17 +010020456 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
Matthias Kloseb9621712010-04-24 17:59:49 +000020457 fi
Pablo Galindoba421752021-05-03 20:33:17 +010020458 printf "%s\n" "$as_me: error: $2" >&2
Matthias Kloseb9621712010-04-24 17:59:49 +000020459 as_fn_exit $as_status
20460} # as_fn_error
20461
20462
Pablo Galindoba421752021-05-03 20:33:17 +010020463
Matthias Kloseb9621712010-04-24 17:59:49 +000020464# as_fn_set_status STATUS
20465# -----------------------
20466# Set $? to STATUS, without forking.
20467as_fn_set_status ()
20468{
20469 return $1
20470} # as_fn_set_status
20471
20472# as_fn_exit STATUS
20473# -----------------
20474# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
20475as_fn_exit ()
20476{
20477 set +e
20478 as_fn_set_status $1
20479 exit $1
20480} # as_fn_exit
20481
20482# as_fn_unset VAR
20483# ---------------
20484# Portably unset VAR.
20485as_fn_unset ()
20486{
20487 { eval $1=; unset $1;}
20488}
20489as_unset=as_fn_unset
Pablo Galindoba421752021-05-03 20:33:17 +010020490
Matthias Kloseb9621712010-04-24 17:59:49 +000020491# as_fn_append VAR VALUE
20492# ----------------------
20493# Append the text in VALUE to the end of the definition contained in VAR. Take
20494# advantage of any shell optimizations that allow amortized linear growth over
20495# repeated appends, instead of the typical quadratic growth present in naive
20496# implementations.
Pablo Galindoba421752021-05-03 20:33:17 +010020497if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
20498then :
Matthias Kloseb9621712010-04-24 17:59:49 +000020499 eval 'as_fn_append ()
20500 {
20501 eval $1+=\$2
20502 }'
Pablo Galindoba421752021-05-03 20:33:17 +010020503else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000020504 as_fn_append ()
20505 {
20506 eval $1=\$$1\$2
20507 }
20508fi # as_fn_append
20509
20510# as_fn_arith ARG...
20511# ------------------
20512# Perform arithmetic evaluation on the ARGs, and store the result in the
20513# global $as_val. Take advantage of shells that can avoid forks. The arguments
20514# must be portable across $(()) and expr.
Pablo Galindoba421752021-05-03 20:33:17 +010020515if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
20516then :
Matthias Kloseb9621712010-04-24 17:59:49 +000020517 eval 'as_fn_arith ()
20518 {
20519 as_val=$(( $* ))
20520 }'
Pablo Galindoba421752021-05-03 20:33:17 +010020521else $as_nop
Matthias Kloseb9621712010-04-24 17:59:49 +000020522 as_fn_arith ()
20523 {
20524 as_val=`expr "$@" || test $? -eq 1`
20525 }
20526fi # as_fn_arith
20527
20528
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020529if expr a : '\(a\)' >/dev/null 2>&1 &&
20530 test "X`expr 00001 : '.*\(...\)'`" = X001; then
20531 as_expr=expr
20532else
20533 as_expr=false
20534fi
20535
20536if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
20537 as_basename=basename
20538else
20539 as_basename=false
20540fi
20541
Matthias Kloseb9621712010-04-24 17:59:49 +000020542if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
20543 as_dirname=dirname
20544else
20545 as_dirname=false
20546fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020547
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020548as_me=`$as_basename -- "$0" ||
20549$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
20550 X"$0" : 'X\(//\)$' \| \
20551 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +010020552printf "%s\n" X/"$0" |
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020553 sed '/^.*\/\([^/][^/]*\)\/*$/{
20554 s//\1/
20555 q
20556 }
20557 /^X\/\(\/\/\)$/{
20558 s//\1/
20559 q
20560 }
20561 /^X\/\(\/\).*/{
20562 s//\1/
20563 q
20564 }
20565 s/.*/./; q'`
20566
Matthias Kloseb9621712010-04-24 17:59:49 +000020567# Avoid depending upon Character Ranges.
20568as_cr_letters='abcdefghijklmnopqrstuvwxyz'
20569as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
20570as_cr_Letters=$as_cr_letters$as_cr_LETTERS
20571as_cr_digits='0123456789'
20572as_cr_alnum=$as_cr_Letters$as_cr_digits
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020573
Pablo Galindoba421752021-05-03 20:33:17 +010020574
20575# Determine whether it's possible to make 'echo' print without a newline.
20576# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
20577# for compatibility with existing Makefiles.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020578ECHO_C= ECHO_N= ECHO_T=
Matthias Kloseb9621712010-04-24 17:59:49 +000020579case `echo -n x` in #(((((
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020580-n*)
Matthias Kloseb9621712010-04-24 17:59:49 +000020581 case `echo 'xy\c'` in
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020582 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
Matthias Kloseb9621712010-04-24 17:59:49 +000020583 xy) ECHO_C='\c';;
20584 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
20585 ECHO_T=' ';;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020586 esac;;
20587*)
20588 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +000020589esac
Ronald Oussoren74f29b42009-09-20 20:09:26 +000020590
Pablo Galindoba421752021-05-03 20:33:17 +010020591# For backward compatibility with old third-party macros, we provide
20592# the shell variables $as_echo and $as_echo_n. New code should use
20593# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
20594as_echo='printf %s\n'
20595as_echo_n='printf %s'
20596
Martin v. Löwis11437992002-04-12 09:54:03 +000020597rm -f conf$$ conf$$.exe conf$$.file
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020598if test -d conf$$.dir; then
20599 rm -f conf$$.dir/conf$$.file
20600else
20601 rm -f conf$$.dir
Matthias Kloseb9621712010-04-24 17:59:49 +000020602 mkdir conf$$.dir 2>/dev/null
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020603fi
Matthias Kloseb9621712010-04-24 17:59:49 +000020604if (echo >conf$$.file) 2>/dev/null; then
20605 if ln -s conf$$.file conf$$ 2>/dev/null; then
20606 as_ln_s='ln -s'
20607 # ... but there are two gotchas:
20608 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
20609 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020610 # In both cases, we have to default to `cp -pR'.
Matthias Kloseb9621712010-04-24 17:59:49 +000020611 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020612 as_ln_s='cp -pR'
Matthias Kloseb9621712010-04-24 17:59:49 +000020613 elif ln conf$$.file conf$$ 2>/dev/null; then
20614 as_ln_s=ln
20615 else
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020616 as_ln_s='cp -pR'
Matthias Kloseb9621712010-04-24 17:59:49 +000020617 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000020618else
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020619 as_ln_s='cp -pR'
Martin v. Löwis11437992002-04-12 09:54:03 +000020620fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020621rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
20622rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +000020623
Matthias Kloseb9621712010-04-24 17:59:49 +000020624
20625# as_fn_mkdir_p
20626# -------------
20627# Create "$as_dir" as a directory, including parents if necessary.
20628as_fn_mkdir_p ()
20629{
20630
20631 case $as_dir in #(
20632 -*) as_dir=./$as_dir;;
20633 esac
20634 test -d "$as_dir" || eval $as_mkdir_p || {
20635 as_dirs=
20636 while :; do
20637 case $as_dir in #(
Pablo Galindoba421752021-05-03 20:33:17 +010020638 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
Matthias Kloseb9621712010-04-24 17:59:49 +000020639 *) as_qdir=$as_dir;;
20640 esac
20641 as_dirs="'$as_qdir' $as_dirs"
20642 as_dir=`$as_dirname -- "$as_dir" ||
20643$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20644 X"$as_dir" : 'X\(//\)[^/]' \| \
20645 X"$as_dir" : 'X\(//\)$' \| \
20646 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +010020647printf "%s\n" X"$as_dir" |
Matthias Kloseb9621712010-04-24 17:59:49 +000020648 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20649 s//\1/
20650 q
20651 }
20652 /^X\(\/\/\)[^/].*/{
20653 s//\1/
20654 q
20655 }
20656 /^X\(\/\/\)$/{
20657 s//\1/
20658 q
20659 }
20660 /^X\(\/\).*/{
20661 s//\1/
20662 q
20663 }
20664 s/.*/./; q'`
20665 test -d "$as_dir" && break
20666 done
20667 test -z "$as_dirs" || eval "mkdir $as_dirs"
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020668 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
Matthias Kloseb9621712010-04-24 17:59:49 +000020669
20670
20671} # as_fn_mkdir_p
Skip Montanaro6dead952003-09-25 14:50:04 +000020672if mkdir -p . 2>/dev/null; then
Matthias Kloseb9621712010-04-24 17:59:49 +000020673 as_mkdir_p='mkdir -p "$as_dir"'
Skip Montanaro6dead952003-09-25 14:50:04 +000020674else
Skip Montanarof0d5f792004-08-15 14:08:23 +000020675 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +000020676 as_mkdir_p=false
20677fi
20678
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020679
20680# as_fn_executable_p FILE
20681# -----------------------
20682# Test if FILE is an executable regular file.
20683as_fn_executable_p ()
20684{
20685 test -f "$1" && test -x "$1"
20686} # as_fn_executable_p
20687as_test_x='test -x'
20688as_executable_p=as_fn_executable_p
Martin v. Löwis11437992002-04-12 09:54:03 +000020689
20690# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000020691as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +000020692
20693# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000020694as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +000020695
20696
Martin v. Löwis11437992002-04-12 09:54:03 +000020697exec 6>&1
Matthias Kloseb9621712010-04-24 17:59:49 +000020698## ----------------------------------- ##
20699## Main body of $CONFIG_STATUS script. ##
20700## ----------------------------------- ##
20701_ASEOF
20702test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000020703
Matthias Kloseb9621712010-04-24 17:59:49 +000020704cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20705# Save the log message, to keep $0 and so on meaningful, and to
Martin v. Löwis11437992002-04-12 09:54:03 +000020706# report actual input values of CONFIG_FILES etc. instead of their
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020707# values after options handling.
20708ac_log="
Pablo Galindod4fe0982020-05-19 03:33:01 +010020709This file was extended by python $as_me 3.10, which was
Pablo Galindoba421752021-05-03 20:33:17 +010020710generated by GNU Autoconf 2.71. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +000020711
20712 CONFIG_FILES = $CONFIG_FILES
20713 CONFIG_HEADERS = $CONFIG_HEADERS
20714 CONFIG_LINKS = $CONFIG_LINKS
20715 CONFIG_COMMANDS = $CONFIG_COMMANDS
20716 $ $0 $@
20717
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020718on `(hostname || uname -n) 2>/dev/null | sed 1q`
20719"
20720
Martin v. Löwis11437992002-04-12 09:54:03 +000020721_ACEOF
20722
Matthias Kloseb9621712010-04-24 17:59:49 +000020723case $ac_config_files in *"
20724"*) set x $ac_config_files; shift; ac_config_files=$*;;
20725esac
20726
20727case $ac_config_headers in *"
20728"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
20729esac
20730
20731
20732cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000020733# Files that config.status was made for.
Charles-François Natali6613c182011-11-27 12:41:06 +010020734config_files="$ac_config_files"
20735config_headers="$ac_config_headers"
Martin v. Löwis11437992002-04-12 09:54:03 +000020736
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020737_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000020738
Matthias Kloseb9621712010-04-24 17:59:49 +000020739cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000020740ac_cs_usage="\
Matthias Kloseb9621712010-04-24 17:59:49 +000020741\`$as_me' instantiates files and other configuration actions
20742from templates according to the current configuration. Unless the files
20743and actions are specified as TAGs, all are instantiated by default.
Martin v. Löwis11437992002-04-12 09:54:03 +000020744
Matthias Kloseb9621712010-04-24 17:59:49 +000020745Usage: $0 [OPTION]... [TAG]...
Martin v. Löwis11437992002-04-12 09:54:03 +000020746
20747 -h, --help print this help, then exit
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020748 -V, --version print version number and configuration settings, then exit
Matthias Kloseb9621712010-04-24 17:59:49 +000020749 --config print configuration, then exit
20750 -q, --quiet, --silent
20751 do not print progress messages
Martin v. Löwis11437992002-04-12 09:54:03 +000020752 -d, --debug don't remove temporary files
20753 --recheck update $as_me by reconfiguring in the same conditions
Matthias Kloseb9621712010-04-24 17:59:49 +000020754 --file=FILE[:TEMPLATE]
20755 instantiate the configuration file FILE
20756 --header=FILE[:TEMPLATE]
20757 instantiate the configuration header FILE
Martin v. Löwis11437992002-04-12 09:54:03 +000020758
20759Configuration files:
20760$config_files
20761
20762Configuration headers:
20763$config_headers
20764
Benjamin Petersonc2fcbf42016-08-03 22:01:32 -070020765Report bugs to <https://bugs.python.org/>."
Skip Montanaroeb33e5a2007-08-17 12:57:41 +000020766
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020767_ACEOF
Pablo Galindoba421752021-05-03 20:33:17 +010020768ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
20769ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
Matthias Kloseb9621712010-04-24 17:59:49 +000020770cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Pablo Galindoba421752021-05-03 20:33:17 +010020771ac_cs_config='$ac_cs_config_escaped'
Martin v. Löwis11437992002-04-12 09:54:03 +000020772ac_cs_version="\\
Pablo Galindod4fe0982020-05-19 03:33:01 +010020773python config.status 3.10
Pablo Galindoba421752021-05-03 20:33:17 +010020774configured by $0, generated by GNU Autoconf 2.71,
Matthias Kloseb9621712010-04-24 17:59:49 +000020775 with options \\"\$ac_cs_config\\"
Martin v. Löwis11437992002-04-12 09:54:03 +000020776
Pablo Galindoba421752021-05-03 20:33:17 +010020777Copyright (C) 2021 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +000020778This config.status script is free software; the Free Software Foundation
20779gives unlimited permission to copy, distribute and modify it."
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020780
20781ac_pwd='$ac_pwd'
20782srcdir='$srcdir'
20783INSTALL='$INSTALL'
Matthias Klose93a0ef12012-03-15 18:08:34 +010020784MKDIR_P='$MKDIR_P'
Matthias Kloseb9621712010-04-24 17:59:49 +000020785test -n "\$AWK" || AWK=awk
Martin v. Löwis11437992002-04-12 09:54:03 +000020786_ACEOF
20787
Matthias Kloseb9621712010-04-24 17:59:49 +000020788cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20789# The default lists apply if the user does not specify any file.
Martin v. Löwis11437992002-04-12 09:54:03 +000020790ac_need_defaults=:
20791while test $# != 0
20792do
20793 case $1 in
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020794 --*=?*)
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020795 ac_option=`expr "X$1" : 'X\([^=]*\)='`
20796 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
Skip Montanaro6dead952003-09-25 14:50:04 +000020797 ac_shift=:
Martin v. Löwis11437992002-04-12 09:54:03 +000020798 ;;
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020799 --*=)
20800 ac_option=`expr "X$1" : 'X\([^=]*\)='`
20801 ac_optarg=
20802 ac_shift=:
20803 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020804 *)
Skip Montanaro6dead952003-09-25 14:50:04 +000020805 ac_option=$1
20806 ac_optarg=$2
20807 ac_shift=shift
20808 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000020809 esac
20810
Skip Montanaro6dead952003-09-25 14:50:04 +000020811 case $ac_option in
Martin v. Löwis11437992002-04-12 09:54:03 +000020812 # Handling of the options.
Skip Montanaro6dead952003-09-25 14:50:04 +000020813 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
20814 ac_cs_recheck=: ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020815 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
Pablo Galindoba421752021-05-03 20:33:17 +010020816 printf "%s\n" "$ac_cs_version"; exit ;;
Matthias Kloseb9621712010-04-24 17:59:49 +000020817 --config | --confi | --conf | --con | --co | --c )
Pablo Galindoba421752021-05-03 20:33:17 +010020818 printf "%s\n" "$ac_cs_config"; exit ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020819 --debug | --debu | --deb | --de | --d | -d )
Martin v. Löwis11437992002-04-12 09:54:03 +000020820 debug=: ;;
20821 --file | --fil | --fi | --f )
Skip Montanaro6dead952003-09-25 14:50:04 +000020822 $ac_shift
Matthias Kloseb9621712010-04-24 17:59:49 +000020823 case $ac_optarg in
Pablo Galindoba421752021-05-03 20:33:17 +010020824 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020825 '') as_fn_error $? "missing file argument" ;;
Matthias Kloseb9621712010-04-24 17:59:49 +000020826 esac
20827 as_fn_append CONFIG_FILES " '$ac_optarg'"
Martin v. Löwis11437992002-04-12 09:54:03 +000020828 ac_need_defaults=false;;
20829 --header | --heade | --head | --hea )
Skip Montanaro6dead952003-09-25 14:50:04 +000020830 $ac_shift
Matthias Kloseb9621712010-04-24 17:59:49 +000020831 case $ac_optarg in
Pablo Galindoba421752021-05-03 20:33:17 +010020832 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
Matthias Kloseb9621712010-04-24 17:59:49 +000020833 esac
20834 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
Martin v. Löwis11437992002-04-12 09:54:03 +000020835 ac_need_defaults=false;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020836 --he | --h)
20837 # Conflict between --help and --header
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020838 as_fn_error $? "ambiguous option: \`$1'
Matthias Kloseb9621712010-04-24 17:59:49 +000020839Try \`$0 --help' for more information.";;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020840 --help | --hel | -h )
Pablo Galindoba421752021-05-03 20:33:17 +010020841 printf "%s\n" "$ac_cs_usage"; exit ;;
Skip Montanaro6dead952003-09-25 14:50:04 +000020842 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
20843 | -silent | --silent | --silen | --sile | --sil | --si | --s)
20844 ac_cs_silent=: ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000020845
20846 # This is an error.
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020847 -*) as_fn_error $? "unrecognized option: \`$1'
Matthias Kloseb9621712010-04-24 17:59:49 +000020848Try \`$0 --help' for more information." ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000020849
Matthias Kloseb9621712010-04-24 17:59:49 +000020850 *) as_fn_append ac_config_targets " $1"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020851 ac_need_defaults=false ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000020852
20853 esac
20854 shift
20855done
20856
Skip Montanaro6dead952003-09-25 14:50:04 +000020857ac_configure_extra_args=
20858
20859if $ac_cs_silent; then
20860 exec 6>/dev/null
20861 ac_configure_extra_args="$ac_configure_extra_args --silent"
20862fi
20863
20864_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000020865cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Skip Montanaro6dead952003-09-25 14:50:04 +000020866if \$ac_cs_recheck; then
Ross Lagerwall1b863eb2012-10-29 17:31:54 +000020867 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
Matthias Kloseb9621712010-04-24 17:59:49 +000020868 shift
Pablo Galindoba421752021-05-03 20:33:17 +010020869 \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
Matthias Kloseb9621712010-04-24 17:59:49 +000020870 CONFIG_SHELL='$SHELL'
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020871 export CONFIG_SHELL
Matthias Kloseb9621712010-04-24 17:59:49 +000020872 exec "\$@"
Skip Montanaro6dead952003-09-25 14:50:04 +000020873fi
20874
Martin v. Löwis11437992002-04-12 09:54:03 +000020875_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000020876cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020877exec 5>>config.log
20878{
20879 echo
20880 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
20881## Running $as_me. ##
20882_ASBOX
Pablo Galindoba421752021-05-03 20:33:17 +010020883 printf "%s\n" "$ac_log"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020884} >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000020885
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020886_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000020887cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020888_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000020889
Matthias Kloseb9621712010-04-24 17:59:49 +000020890cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020891
20892# Handling of arguments.
Martin v. Löwis11437992002-04-12 09:54:03 +000020893for ac_config_target in $ac_config_targets
20894do
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020895 case $ac_config_target in
20896 "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
20897 "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;;
20898 "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;;
Christian Heimes81ee3ef2008-05-04 22:42:01 +000020899 "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;;
20900 "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020901 "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
Antoine Pitrou20327222009-05-24 20:39:11 +000020902 "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;;
Victor Stinner0a8e5722019-05-23 03:30:23 +020020903 "Misc/python-embed.pc") CONFIG_FILES="$CONFIG_FILES Misc/python-embed.pc" ;;
doko@python.org87421192013-01-26 11:39:31 +010020904 "Misc/python-config.sh") CONFIG_FILES="$CONFIG_FILES Misc/python-config.sh" ;;
Antoine Pitrou8e6b4072010-09-10 19:44:44 +000020905 "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020906
Victor Stinnere0be4232011-10-25 13:06:09 +020020907 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
Martin v. Löwis11437992002-04-12 09:54:03 +000020908 esac
20909done
20910
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020911
Martin v. Löwis11437992002-04-12 09:54:03 +000020912# If the user did not use the arguments to specify the items to instantiate,
20913# then the envvar interface is used. Set only those that are not.
20914# We use the long form for the default assignment because of an extremely
20915# bizarre bug on SunOS 4.1.3.
20916if $ac_need_defaults; then
Pablo Galindoba421752021-05-03 20:33:17 +010020917 test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
20918 test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers
Martin v. Löwis11437992002-04-12 09:54:03 +000020919fi
20920
Skip Montanaro6dead952003-09-25 14:50:04 +000020921# Have a temporary directory for convenience. Make it in the build tree
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020922# simply because there is no reason against having it here, and in addition,
Skip Montanaro6dead952003-09-25 14:50:04 +000020923# creating and moving files from /tmp can sometimes cause problems.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020924# Hook for its removal unless debugging.
20925# Note that there is a small window in which the directory will not be cleaned:
20926# after its creation but before its name has been assigned to `$tmp'.
Martin v. Löwis11437992002-04-12 09:54:03 +000020927$debug ||
20928{
Victor Stinnere0be4232011-10-25 13:06:09 +020020929 tmp= ac_tmp=
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020930 trap 'exit_status=$?
Victor Stinnere0be4232011-10-25 13:06:09 +020020931 : "${ac_tmp:=$tmp}"
20932 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020933' 0
Matthias Kloseb9621712010-04-24 17:59:49 +000020934 trap 'as_fn_exit 1' 1 2 13 15
Martin v. Löwis11437992002-04-12 09:54:03 +000020935}
Martin v. Löwis11437992002-04-12 09:54:03 +000020936# Create a (secure) tmp directory for tmp files.
Skip Montanaro6dead952003-09-25 14:50:04 +000020937
Martin v. Löwis11437992002-04-12 09:54:03 +000020938{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020939 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
Victor Stinnere0be4232011-10-25 13:06:09 +020020940 test -d "$tmp"
Martin v. Löwis11437992002-04-12 09:54:03 +000020941} ||
20942{
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020943 tmp=./conf$$-$RANDOM
20944 (umask 077 && mkdir "$tmp")
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020945} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
Victor Stinnere0be4232011-10-25 13:06:09 +020020946ac_tmp=$tmp
Martin v. Löwis11437992002-04-12 09:54:03 +000020947
Matthias Kloseb9621712010-04-24 17:59:49 +000020948# Set up the scripts for CONFIG_FILES section.
20949# No need to generate them if there are no CONFIG_FILES.
20950# This happens for instance with `./config.status config.h'.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020951if test -n "$CONFIG_FILES"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020952
Matthias Kloseb9621712010-04-24 17:59:49 +000020953
20954ac_cr=`echo X | tr X '\015'`
20955# On cygwin, bash can eat \r inside `` if the user requested igncr.
20956# But we know of no other shell where ac_cr would be empty at this
20957# point, so we can use a bashism as a fallback.
20958if test "x$ac_cr" = x; then
20959 eval ac_cr=\$\'\\r\'
20960fi
20961ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
20962if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020963 ac_cs_awk_cr='\\r'
Matthias Kloseb9621712010-04-24 17:59:49 +000020964else
20965 ac_cs_awk_cr=$ac_cr
20966fi
20967
Victor Stinnere0be4232011-10-25 13:06:09 +020020968echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
Martin v. Löwis11437992002-04-12 09:54:03 +000020969_ACEOF
20970
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020971
Matthias Kloseb9621712010-04-24 17:59:49 +000020972{
20973 echo "cat >conf$$subs.awk <<_ACEOF" &&
20974 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
20975 echo "_ACEOF"
20976} >conf$$subs.sh ||
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020977 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20978ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020979ac_delim='%!_!# '
20980for ac_last_try in false false false false false :; do
Matthias Kloseb9621712010-04-24 17:59:49 +000020981 . ./conf$$subs.sh ||
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020982 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020983
Matthias Kloseb9621712010-04-24 17:59:49 +000020984 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
20985 if test $ac_delim_n = $ac_delim_num; then
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020986 break
20987 elif $ac_last_try; then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020020988 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020989 else
20990 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
Martin v. Löwis11437992002-04-12 09:54:03 +000020991 fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020992done
Matthias Kloseb9621712010-04-24 17:59:49 +000020993rm -f conf$$subs.sh
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020994
Matthias Kloseb9621712010-04-24 17:59:49 +000020995cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Victor Stinnere0be4232011-10-25 13:06:09 +020020996cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
Thomas Wouters47b49bf2007-08-30 22:15:33 +000020997_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000020998sed -n '
20999h
21000s/^/S["/; s/!.*/"]=/
21001p
21002g
21003s/^[^!]*!//
21004:repl
21005t repl
21006s/'"$ac_delim"'$//
21007t delim
21008:nl
21009h
21010s/\(.\{148\}\)..*/\1/
21011t more1
21012s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
21013p
21014n
21015b repl
21016:more1
21017s/["\\]/\\&/g; s/^/"/; s/$/"\\/
21018p
21019g
21020s/.\{148\}//
21021t nl
21022:delim
21023h
21024s/\(.\{148\}\)..*/\1/
21025t more2
21026s/["\\]/\\&/g; s/^/"/; s/$/"/
21027p
21028b
21029:more2
21030s/["\\]/\\&/g; s/^/"/; s/$/"\\/
21031p
21032g
21033s/.\{148\}//
21034t delim
21035' <conf$$subs.awk | sed '
21036/^[^""]/{
21037 N
21038 s/\n//
21039}
21040' >>$CONFIG_STATUS || ac_write_fail=1
21041rm -f conf$$subs.awk
21042cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21043_ACAWK
Victor Stinnere0be4232011-10-25 13:06:09 +020021044cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
Matthias Kloseb9621712010-04-24 17:59:49 +000021045 for (key in S) S_is_set[key] = 1
21046 FS = ""
21047
21048}
21049{
21050 line = $ 0
21051 nfields = split(line, field, "@")
21052 substed = 0
21053 len = length(field[1])
21054 for (i = 2; i < nfields; i++) {
21055 key = field[i]
21056 keylen = length(key)
21057 if (S_is_set[key]) {
21058 value = S[key]
21059 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
21060 len += length(value) + length(field[++i])
21061 substed = 1
21062 } else
21063 len += 1 + keylen
21064 }
21065
21066 print line
21067}
21068
21069_ACAWK
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021070_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000021071cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21072if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
21073 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
21074else
21075 cat
Victor Stinnere0be4232011-10-25 13:06:09 +020021076fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021077 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
Ronald Oussoren74f29b42009-09-20 20:09:26 +000021078_ACEOF
21079
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021080# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
21081# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021082# trailing colons and then remove the whole line if VPATH becomes empty
21083# (actually we leave an empty line to preserve line numbers).
21084if test "x$srcdir" = x.; then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021085 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
21086h
21087s///
21088s/^/:/
21089s/[ ]*$/:/
21090s/:\$(srcdir):/:/g
21091s/:\${srcdir}:/:/g
21092s/:@srcdir@:/:/g
21093s/^:*//
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021094s/:*$//
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021095x
21096s/\(=[ ]*\).*/\1/
21097G
21098s/\n//
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021099s/^[^=]*=[ ]*$//
21100}'
21101fi
21102
Matthias Kloseb9621712010-04-24 17:59:49 +000021103cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000021104fi # test -n "$CONFIG_FILES"
21105
Matthias Kloseb9621712010-04-24 17:59:49 +000021106# Set up the scripts for CONFIG_HEADERS section.
21107# No need to generate them if there are no CONFIG_HEADERS.
21108# This happens for instance with `./config.status Makefile'.
21109if test -n "$CONFIG_HEADERS"; then
Victor Stinnere0be4232011-10-25 13:06:09 +020021110cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
Matthias Kloseb9621712010-04-24 17:59:49 +000021111BEGIN {
21112_ACEOF
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021113
Matthias Kloseb9621712010-04-24 17:59:49 +000021114# Transform confdefs.h into an awk script `defines.awk', embedded as
21115# here-document in config.status, that substitutes the proper values into
21116# config.h.in to produce config.h.
21117
21118# Create a delimiter string that does not exist in confdefs.h, to ease
21119# handling of long lines.
21120ac_delim='%!_!# '
21121for ac_last_try in false false :; do
Victor Stinnere0be4232011-10-25 13:06:09 +020021122 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
21123 if test -z "$ac_tt"; then
Matthias Kloseb9621712010-04-24 17:59:49 +000021124 break
21125 elif $ac_last_try; then
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021126 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
Matthias Kloseb9621712010-04-24 17:59:49 +000021127 else
21128 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
21129 fi
21130done
21131
21132# For the awk script, D is an array of macro values keyed by name,
21133# likewise P contains macro parameters if any. Preserve backslash
21134# newline sequences.
21135
21136ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
21137sed -n '
21138s/.\{148\}/&'"$ac_delim"'/g
21139t rset
21140:rset
21141s/^[ ]*#[ ]*define[ ][ ]*/ /
21142t def
21143d
21144:def
21145s/\\$//
21146t bsnl
21147s/["\\]/\\&/g
21148s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
21149D["\1"]=" \3"/p
21150s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
21151d
21152:bsnl
21153s/["\\]/\\&/g
21154s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
21155D["\1"]=" \3\\\\\\n"\\/p
21156t cont
21157s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
21158t cont
21159d
21160:cont
21161n
21162s/.\{148\}/&'"$ac_delim"'/g
21163t clear
21164:clear
21165s/\\$//
21166t bsnlc
21167s/["\\]/\\&/g; s/^/"/; s/$/"/p
21168d
21169:bsnlc
21170s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
21171b cont
21172' <confdefs.h | sed '
21173s/'"$ac_delim"'/"\\\
21174"/g' >>$CONFIG_STATUS || ac_write_fail=1
21175
21176cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21177 for (key in D) D_is_set[key] = 1
21178 FS = ""
21179}
21180/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
21181 line = \$ 0
21182 split(line, arg, " ")
21183 if (arg[1] == "#") {
21184 defundef = arg[2]
21185 mac1 = arg[3]
21186 } else {
21187 defundef = substr(arg[1], 2)
21188 mac1 = arg[2]
21189 }
21190 split(mac1, mac2, "(") #)
21191 macro = mac2[1]
21192 prefix = substr(line, 1, index(line, defundef) - 1)
21193 if (D_is_set[macro]) {
21194 # Preserve the white space surrounding the "#".
21195 print prefix "define", macro P[macro] D[macro]
21196 next
21197 } else {
21198 # Replace #undef with comments. This is necessary, for example,
21199 # in the case of _POSIX_SOURCE, which is predefined and required
21200 # on some systems where configure will not decide to define it.
21201 if (defundef == "undef") {
21202 print "/*", prefix defundef, macro, "*/"
21203 next
21204 }
21205 }
21206}
21207{ print }
21208_ACAWK
21209_ACEOF
21210cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021211 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
Matthias Kloseb9621712010-04-24 17:59:49 +000021212fi # test -n "$CONFIG_HEADERS"
21213
21214
21215eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS "
21216shift
21217for ac_tag
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021218do
21219 case $ac_tag in
21220 :[FHLC]) ac_mode=$ac_tag; continue;;
21221 esac
21222 case $ac_mode$ac_tag in
21223 :[FHL]*:*);;
Victor Stinnere0be4232011-10-25 13:06:09 +020021224 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021225 :[FH]-) ac_tag=-:-;;
21226 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
21227 esac
21228 ac_save_IFS=$IFS
21229 IFS=:
21230 set x $ac_tag
21231 IFS=$ac_save_IFS
21232 shift
21233 ac_file=$1
21234 shift
21235
21236 case $ac_mode in
21237 :L) ac_source=$1;;
21238 :[FH])
21239 ac_file_inputs=
21240 for ac_f
21241 do
21242 case $ac_f in
Victor Stinnere0be4232011-10-25 13:06:09 +020021243 -) ac_f="$ac_tmp/stdin";;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021244 *) # Look for the file first in the build tree, then in the source tree
21245 # (if the path is not absolute). The absolute path cannot be DOS-style,
21246 # because $ac_f cannot contain `:'.
21247 test -f "$ac_f" ||
21248 case $ac_f in
21249 [\\/$]*) false;;
21250 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
21251 esac ||
Victor Stinnere0be4232011-10-25 13:06:09 +020021252 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021253 esac
Pablo Galindoba421752021-05-03 20:33:17 +010021254 case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
Matthias Kloseb9621712010-04-24 17:59:49 +000021255 as_fn_append ac_file_inputs " '$ac_f'"
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021256 done
21257
21258 # Let's still pretend it is `configure' which instantiates (i.e., don't
21259 # use $as_me), people would be surprised to read:
21260 # /* config.h. Generated by config.status. */
Matthias Kloseb9621712010-04-24 17:59:49 +000021261 configure_input='Generated from '`
Pablo Galindoba421752021-05-03 20:33:17 +010021262 printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
Matthias Kloseb9621712010-04-24 17:59:49 +000021263 `' by configure.'
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021264 if test x"$ac_file" != x-; then
21265 configure_input="$ac_file. $configure_input"
Pablo Galindoba421752021-05-03 20:33:17 +010021266 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
21267printf "%s\n" "$as_me: creating $ac_file" >&6;}
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021268 fi
Matthias Kloseb9621712010-04-24 17:59:49 +000021269 # Neutralize special characters interpreted by sed in replacement strings.
21270 case $configure_input in #(
21271 *\&* | *\|* | *\\* )
Pablo Galindoba421752021-05-03 20:33:17 +010021272 ac_sed_conf_input=`printf "%s\n" "$configure_input" |
Matthias Kloseb9621712010-04-24 17:59:49 +000021273 sed 's/[\\\\&|]/\\\\&/g'`;; #(
21274 *) ac_sed_conf_input=$configure_input;;
21275 esac
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021276
21277 case $ac_tag in
Victor Stinnere0be4232011-10-25 13:06:09 +020021278 *:-:* | *:-) cat >"$ac_tmp/stdin" \
21279 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021280 esac
21281 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000021282 esac
21283
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021284 ac_dir=`$as_dirname -- "$ac_file" ||
Martin v. Löwis11437992002-04-12 09:54:03 +000021285$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021286 X"$ac_file" : 'X\(//\)[^/]' \| \
21287 X"$ac_file" : 'X\(//\)$' \| \
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021288 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
Pablo Galindoba421752021-05-03 20:33:17 +010021289printf "%s\n" X"$ac_file" |
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021290 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21291 s//\1/
21292 q
21293 }
21294 /^X\(\/\/\)[^/].*/{
21295 s//\1/
21296 q
21297 }
21298 /^X\(\/\/\)$/{
21299 s//\1/
21300 q
21301 }
21302 /^X\(\/\).*/{
21303 s//\1/
21304 q
21305 }
21306 s/.*/./; q'`
Matthias Kloseb9621712010-04-24 17:59:49 +000021307 as_dir="$ac_dir"; as_fn_mkdir_p
Martin v. Löwis11437992002-04-12 09:54:03 +000021308 ac_builddir=.
21309
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021310case "$ac_dir" in
21311.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
21312*)
Pablo Galindoba421752021-05-03 20:33:17 +010021313 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021314 # A ".." for each directory in $ac_dir_suffix.
Pablo Galindoba421752021-05-03 20:33:17 +010021315 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021316 case $ac_top_builddir_sub in
21317 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
21318 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
21319 esac ;;
21320esac
21321ac_abs_top_builddir=$ac_pwd
21322ac_abs_builddir=$ac_pwd$ac_dir_suffix
21323# for backward compatibility:
21324ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +000021325
21326case $srcdir in
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021327 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +000021328 ac_srcdir=.
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021329 ac_top_srcdir=$ac_top_builddir_sub
21330 ac_abs_top_srcdir=$ac_pwd ;;
21331 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +000021332 ac_srcdir=$srcdir$ac_dir_suffix;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021333 ac_top_srcdir=$srcdir
21334 ac_abs_top_srcdir=$srcdir ;;
21335 *) # Relative name.
21336 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
21337 ac_top_srcdir=$ac_top_build_prefix$srcdir
21338 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000021339esac
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021340ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +000021341
Martin v. Löwis11437992002-04-12 09:54:03 +000021342
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021343 case $ac_mode in
21344 :F)
21345 #
21346 # CONFIG_FILE
21347 #
Martin v. Löwis11437992002-04-12 09:54:03 +000021348
21349 case $INSTALL in
21350 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021351 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000021352 esac
Matthias Klose93a0ef12012-03-15 18:08:34 +010021353 ac_MKDIR_P=$MKDIR_P
21354 case $MKDIR_P in
21355 [\\/$]* | ?:[\\/]* ) ;;
21356 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
21357 esac
Thomas Wouters477c8d52006-05-27 19:21:47 +000021358_ACEOF
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021359
Matthias Kloseb9621712010-04-24 17:59:49 +000021360cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021361# If the template does not know about datarootdir, expand it.
21362# FIXME: This hack should be removed a few years after 2.60.
21363ac_datarootdir_hack=; ac_datarootdir_seen=
Matthias Kloseb9621712010-04-24 17:59:49 +000021364ac_sed_dataroot='
21365/datarootdir/ {
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021366 p
21367 q
21368}
21369/@datadir@/p
21370/@docdir@/p
21371/@infodir@/p
21372/@localedir@/p
Matthias Kloseb9621712010-04-24 17:59:49 +000021373/@mandir@/p'
21374case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021375*datarootdir*) ac_datarootdir_seen=yes;;
21376*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
Pablo Galindoba421752021-05-03 20:33:17 +010021377 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
21378printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021379_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000021380cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021381 ac_datarootdir_hack='
21382 s&@datadir@&$datadir&g
21383 s&@docdir@&$docdir&g
21384 s&@infodir@&$infodir&g
21385 s&@localedir@&$localedir&g
21386 s&@mandir@&$mandir&g
Matthias Kloseb9621712010-04-24 17:59:49 +000021387 s&\\\${datarootdir}&$datarootdir&g' ;;
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021388esac
21389_ACEOF
21390
21391# Neutralize VPATH when `$srcdir' = `.'.
21392# Shell code in configure.ac might set extrasub.
21393# FIXME: do we really want to maintain this feature?
Matthias Kloseb9621712010-04-24 17:59:49 +000021394cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21395ac_sed_extra="$ac_vpsub
Martin v. Löwis11437992002-04-12 09:54:03 +000021396$extrasub
21397_ACEOF
Matthias Kloseb9621712010-04-24 17:59:49 +000021398cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
Martin v. Löwis11437992002-04-12 09:54:03 +000021399:t
21400/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
Matthias Kloseb9621712010-04-24 17:59:49 +000021401s|@configure_input@|$ac_sed_conf_input|;t t
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021402s&@top_builddir@&$ac_top_builddir_sub&;t t
Matthias Kloseb9621712010-04-24 17:59:49 +000021403s&@top_build_prefix@&$ac_top_build_prefix&;t t
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021404s&@srcdir@&$ac_srcdir&;t t
21405s&@abs_srcdir@&$ac_abs_srcdir&;t t
21406s&@top_srcdir@&$ac_top_srcdir&;t t
21407s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
21408s&@builddir@&$ac_builddir&;t t
21409s&@abs_builddir@&$ac_abs_builddir&;t t
21410s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
21411s&@INSTALL@&$ac_INSTALL&;t t
Matthias Klose93a0ef12012-03-15 18:08:34 +010021412s&@MKDIR_P@&$ac_MKDIR_P&;t t
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021413$ac_datarootdir_hack
Matthias Kloseb9621712010-04-24 17:59:49 +000021414"
Victor Stinnere0be4232011-10-25 13:06:09 +020021415eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
21416 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021417
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021418test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
Victor Stinnere0be4232011-10-25 13:06:09 +020021419 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
21420 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
21421 "$ac_tmp/out"`; test -z "$ac_out"; } &&
Pablo Galindoba421752021-05-03 20:33:17 +010021422 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021423which seems to be undefined. Please make sure it is defined" >&5
Pablo Galindoba421752021-05-03 20:33:17 +010021424printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021425which seems to be undefined. Please make sure it is defined" >&2;}
Thomas Wouters1ba5b3b2006-06-08 14:52:47 +000021426
Victor Stinnere0be4232011-10-25 13:06:09 +020021427 rm -f "$ac_tmp/stdin"
Martin v. Löwis11437992002-04-12 09:54:03 +000021428 case $ac_file in
Victor Stinnere0be4232011-10-25 13:06:09 +020021429 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
21430 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
Matthias Kloseb9621712010-04-24 17:59:49 +000021431 esac \
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021432 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021433 ;;
21434 :H)
21435 #
21436 # CONFIG_HEADER
21437 #
Martin v. Löwis11437992002-04-12 09:54:03 +000021438 if test x"$ac_file" != x-; then
Matthias Kloseb9621712010-04-24 17:59:49 +000021439 {
Pablo Galindoba421752021-05-03 20:33:17 +010021440 printf "%s\n" "/* $configure_input */" >&1 \
Victor Stinnere0be4232011-10-25 13:06:09 +020021441 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
21442 } >"$ac_tmp/config.h" \
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021443 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
Victor Stinnere0be4232011-10-25 13:06:09 +020021444 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
Pablo Galindoba421752021-05-03 20:33:17 +010021445 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
21446printf "%s\n" "$as_me: $ac_file is unchanged" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +000021447 else
Matthias Kloseb9621712010-04-24 17:59:49 +000021448 rm -f "$ac_file"
Victor Stinnere0be4232011-10-25 13:06:09 +020021449 mv "$ac_tmp/config.h" "$ac_file" \
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021450 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
Martin v. Löwis11437992002-04-12 09:54:03 +000021451 fi
21452 else
Pablo Galindoba421752021-05-03 20:33:17 +010021453 printf "%s\n" "/* $configure_input */" >&1 \
Victor Stinnere0be4232011-10-25 13:06:09 +020021454 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021455 || as_fn_error $? "could not create -" "$LINENO" 5
Martin v. Löwis11437992002-04-12 09:54:03 +000021456 fi
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021457 ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +000021458
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021459
21460 esac
21461
Antoine Pitrou8e6b4072010-09-10 19:44:44 +000021462
21463 case $ac_file$ac_mode in
21464 "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;;
21465
21466 esac
Thomas Wouters47b49bf2007-08-30 22:15:33 +000021467done # for ac_tag
21468
Guido van Rossum627b2d71993-12-24 10:39:16 +000021469
Matthias Kloseb9621712010-04-24 17:59:49 +000021470as_fn_exit 0
Martin v. Löwis11437992002-04-12 09:54:03 +000021471_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000021472ac_clean_files=$ac_clean_files_save
21473
Matthias Kloseb9621712010-04-24 17:59:49 +000021474test $ac_write_fail = 0 ||
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021475 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
Matthias Kloseb9621712010-04-24 17:59:49 +000021476
Martin v. Löwis11437992002-04-12 09:54:03 +000021477
21478# configure is writing to config.log, and then calls config.status.
21479# config.status does its own redirection, appending to config.log.
21480# Unfortunately, on DOS this fails, as config.log is still kept open
21481# by configure, so config.status won't be able to write to it; its
21482# output is simply discarded. So we exec the FD to /dev/null,
21483# effectively closing config.log, so it can be properly (re)opened and
21484# appended to by config.status. When coming back to configure, we
21485# need to make the FD available again.
21486if test "$no_create" != yes; then
21487 ac_cs_success=:
Skip Montanaro6dead952003-09-25 14:50:04 +000021488 ac_config_status_args=
21489 test "$silent" = yes &&
21490 ac_config_status_args="$ac_config_status_args --quiet"
Martin v. Löwis11437992002-04-12 09:54:03 +000021491 exec 5>/dev/null
Skip Montanaro6dead952003-09-25 14:50:04 +000021492 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
Martin v. Löwis11437992002-04-12 09:54:03 +000021493 exec 5>>config.log
21494 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
21495 # would make configure fail if this is the last instruction.
Ross Lagerwallb0ae53d2011-06-10 07:30:30 +020021496 $ac_cs_success || as_fn_exit 1
Matthias Kloseb9621712010-04-24 17:59:49 +000021497fi
21498if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
Pablo Galindoba421752021-05-03 20:33:17 +010021499 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
21500printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000021501fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000021502
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000021503
Christian Heimes75ed8902013-11-20 01:11:18 +010021504echo "creating Modules/Setup.local" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000021505if test ! -f Modules/Setup.local
21506then
21507 echo "# Edit this file for local setup changes" >Modules/Setup.local
21508fi
21509
Christian Heimes75ed8902013-11-20 01:11:18 +010021510echo "creating Makefile" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000021511$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
Antoine Pitroua6a4dc82017-09-07 18:56:24 +020021512 -s Modules \
Antoine Pitrou961d54c2018-07-16 19:03:03 +020021513 Modules/Setup.local $srcdir/Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000021514mv config.c Modules
Brett Cannon63d98bc2016-09-06 17:12:40 -070021515
21516if test "$Py_OPT" = 'false' -a "$Py_DEBUG" != 'true'; then
21517 echo "" >&6
21518 echo "" >&6
Brett Cannonb4e5fee2017-06-09 13:56:57 -070021519 echo "If you want a release build with all stable optimizations active (PGO, etc)," >&6
Gregory P. Smith ext:(%20%5BGoogle%20Inc.%5D)1016b2f2016-11-20 21:07:42 +000021520 echo "please run ./configure --enable-optimizations" >&6
Brett Cannon63d98bc2016-09-06 17:12:40 -070021521 echo "" >&6
21522 echo "" >&6
21523fi
Pablo Galindoba421752021-05-03 20:33:17 +010021524