Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2 | # Guess values for system-dependent variables and create Makefiles. |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 3 | # Generated by GNU Autoconf 2.69 for python 3.5. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4 | # |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 5 | # Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 6 | # |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7 | # |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 8 | # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9 | # |
| 10 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11 | # This configure script is free software; the Free Software Foundation |
| 12 | # gives unlimited permission to copy, distribute and modify it. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13 | ## -------------------- ## |
| 14 | ## M4sh Initialization. ## |
| 15 | ## -------------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17 | # Be more Bourne compatible |
| 18 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 19 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 20 | emulate sh |
| 21 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 22 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 23 | # is contrary to our usage. Disable this feature. |
| 24 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 25 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 26 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 27 | case `(set -o) 2>/dev/null` in #( |
| 28 | *posix*) : |
| 29 | set -o posix ;; #( |
| 30 | *) : |
| 31 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 32 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 33 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 34 | |
| 35 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 36 | as_nl=' |
| 37 | ' |
| 38 | export as_nl |
| 39 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 40 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 41 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 42 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 43 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 44 | # but without wasting forks for bash or zsh. |
| 45 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 46 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 47 | as_echo='print -r --' |
| 48 | as_echo_n='print -rn --' |
| 49 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 50 | as_echo='printf %s\n' |
| 51 | as_echo_n='printf %s' |
| 52 | else |
| 53 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 54 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 55 | as_echo_n='/usr/ucb/echo -n' |
| 56 | else |
| 57 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 58 | as_echo_n_body='eval |
| 59 | arg=$1; |
| 60 | case $arg in #( |
| 61 | *"$as_nl"*) |
| 62 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 63 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 64 | esac; |
| 65 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 66 | ' |
| 67 | export as_echo_n_body |
| 68 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 69 | fi |
| 70 | export as_echo_body |
| 71 | as_echo='sh -c $as_echo_body as_echo' |
| 72 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 73 | |
| 74 | # The user is always right. |
| 75 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 76 | PATH_SEPARATOR=: |
| 77 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 78 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 79 | PATH_SEPARATOR=';' |
| 80 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 81 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 82 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 83 | |
| 84 | # IFS |
| 85 | # We need space, tab and new line, in precisely that order. Quoting is |
| 86 | # there to prevent editors from complaining about space-tab. |
| 87 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 88 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 89 | IFS=" "" $as_nl" |
| 90 | |
| 91 | # Find who we are. Look in the path if we contain no directory separator. |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 92 | as_myself= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 93 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 94 | *[\\/]* ) as_myself=$0 ;; |
| 95 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 96 | for as_dir in $PATH |
| 97 | do |
| 98 | IFS=$as_save_IFS |
| 99 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 100 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 101 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 102 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 103 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 104 | ;; |
| 105 | esac |
| 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. |
| 108 | if test "x$as_myself" = x; then |
| 109 | as_myself=$0 |
| 110 | fi |
| 111 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 112 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 113 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 114 | fi |
| 115 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 116 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 117 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 118 | # suppresses any "Segmentation fault" message there. '((' could |
| 119 | # trigger a bug in pdksh 5.2.14. |
| 120 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 121 | do eval test x\${$as_var+set} = xset \ |
| 122 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 123 | done |
| 124 | PS1='$ ' |
| 125 | PS2='> ' |
| 126 | PS4='+ ' |
| 127 | |
| 128 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 129 | LC_ALL=C |
| 130 | export LC_ALL |
| 131 | LANGUAGE=C |
| 132 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 133 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 134 | # CDPATH. |
| 135 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 136 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 137 | # Use a proper internal environment variable to ensure we don't fall |
| 138 | # into an infinite loop, continuously re-executing ourselves. |
| 139 | if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then |
| 140 | _as_can_reexec=no; export _as_can_reexec; |
| 141 | # We cannot yet assume a decent shell, so we have to provide a |
| 142 | # neutralization value for shells without unset; and this also |
| 143 | # works around shells that cannot unset nonexistent variables. |
| 144 | # Preserve -v and -x to the replacement shell. |
| 145 | BASH_ENV=/dev/null |
| 146 | ENV=/dev/null |
| 147 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 148 | case $- in # (((( |
| 149 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 150 | *v* ) as_opts=-v ;; |
| 151 | *x* ) as_opts=-x ;; |
| 152 | * ) as_opts= ;; |
| 153 | esac |
| 154 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} |
| 155 | # Admittedly, this is quite paranoid, since all the known shells bail |
| 156 | # out after a failed `exec'. |
| 157 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 |
| 158 | as_fn_exit 255 |
| 159 | fi |
| 160 | # We don't want this to propagate to other subprocesses. |
| 161 | { _as_can_reexec=; unset _as_can_reexec;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 162 | if test "x$CONFIG_SHELL" = x; then |
| 163 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 164 | emulate sh |
| 165 | NULLCMD=: |
| 166 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 167 | # is contrary to our usage. Disable this feature. |
| 168 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 169 | setopt NO_GLOB_SUBST |
| 170 | else |
| 171 | case \`(set -o) 2>/dev/null\` in #( |
| 172 | *posix*) : |
| 173 | set -o posix ;; #( |
| 174 | *) : |
| 175 | ;; |
| 176 | esac |
| 177 | fi |
| 178 | " |
| 179 | as_required="as_fn_return () { (exit \$1); } |
| 180 | as_fn_success () { as_fn_return 0; } |
| 181 | as_fn_failure () { as_fn_return 1; } |
| 182 | as_fn_ret_success () { return 0; } |
| 183 | as_fn_ret_failure () { return 1; } |
| 184 | |
| 185 | exitcode=0 |
| 186 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 187 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 188 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 189 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 190 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 191 | |
| 192 | else |
| 193 | exitcode=1; echo positional parameters were not saved. |
| 194 | fi |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 195 | test x\$exitcode = x0 || exit 1 |
| 196 | test -x / || exit 1" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 197 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 198 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 199 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 200 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 201 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 202 | if (eval "$as_required") 2>/dev/null; then : |
| 203 | as_have_required=yes |
| 204 | else |
| 205 | as_have_required=no |
| 206 | fi |
| 207 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 208 | |
| 209 | else |
| 210 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 211 | as_found=false |
| 212 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 213 | do |
| 214 | IFS=$as_save_IFS |
| 215 | test -z "$as_dir" && as_dir=. |
| 216 | as_found=: |
| 217 | case $as_dir in #( |
| 218 | /*) |
| 219 | for as_base in sh bash ksh sh5; do |
| 220 | # Try only shells that exist, to save several forks. |
| 221 | as_shell=$as_dir/$as_base |
| 222 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 223 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 224 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 225 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 226 | break 2 |
| 227 | fi |
| 228 | fi |
| 229 | done;; |
| 230 | esac |
| 231 | as_found=false |
| 232 | done |
| 233 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 234 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 235 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 236 | fi; } |
| 237 | IFS=$as_save_IFS |
| 238 | |
| 239 | |
| 240 | if test "x$CONFIG_SHELL" != x; then : |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 241 | export CONFIG_SHELL |
| 242 | # We cannot yet assume a decent shell, so we have to provide a |
| 243 | # neutralization value for shells without unset; and this also |
| 244 | # works around shells that cannot unset nonexistent variables. |
| 245 | # Preserve -v and -x to the replacement shell. |
| 246 | BASH_ENV=/dev/null |
| 247 | ENV=/dev/null |
| 248 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 249 | case $- in # (((( |
| 250 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 251 | *v* ) as_opts=-v ;; |
| 252 | *x* ) as_opts=-x ;; |
| 253 | * ) as_opts= ;; |
| 254 | esac |
| 255 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} |
| 256 | # Admittedly, this is quite paranoid, since all the known shells bail |
| 257 | # out after a failed `exec'. |
| 258 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 |
| 259 | exit 255 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 260 | fi |
| 261 | |
| 262 | if test x$as_have_required = xno; then : |
| 263 | $as_echo "$0: This script requires a shell more modern than all" |
| 264 | $as_echo "$0: the shells that I found on your system." |
| 265 | if test x${ZSH_VERSION+set} = xset ; then |
| 266 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 267 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 268 | else |
| 269 | $as_echo "$0: Please tell bug-autoconf@gnu.org and |
| 270 | $0: http://bugs.python.org/ about your system, including |
| 271 | $0: any error possibly output before this message. Then |
| 272 | $0: install a modern shell, or manually run the script |
| 273 | $0: under such a shell if you do have one." |
| 274 | fi |
| 275 | exit 1 |
| 276 | fi |
| 277 | fi |
| 278 | fi |
| 279 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 280 | export SHELL |
| 281 | # Unset more variables known to interfere with behavior of common tools. |
| 282 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 283 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 284 | |
| 285 | ## --------------------- ## |
| 286 | ## M4sh Shell Functions. ## |
| 287 | ## --------------------- ## |
| 288 | # as_fn_unset VAR |
| 289 | # --------------- |
| 290 | # Portably unset VAR. |
| 291 | as_fn_unset () |
| 292 | { |
| 293 | { eval $1=; unset $1;} |
| 294 | } |
| 295 | as_unset=as_fn_unset |
| 296 | |
| 297 | # as_fn_set_status STATUS |
| 298 | # ----------------------- |
| 299 | # Set $? to STATUS, without forking. |
| 300 | as_fn_set_status () |
| 301 | { |
| 302 | return $1 |
| 303 | } # as_fn_set_status |
| 304 | |
| 305 | # as_fn_exit STATUS |
| 306 | # ----------------- |
| 307 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 308 | as_fn_exit () |
| 309 | { |
| 310 | set +e |
| 311 | as_fn_set_status $1 |
| 312 | exit $1 |
| 313 | } # as_fn_exit |
| 314 | |
| 315 | # as_fn_mkdir_p |
| 316 | # ------------- |
| 317 | # Create "$as_dir" as a directory, including parents if necessary. |
| 318 | as_fn_mkdir_p () |
| 319 | { |
| 320 | |
| 321 | case $as_dir in #( |
| 322 | -*) as_dir=./$as_dir;; |
| 323 | esac |
| 324 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 325 | as_dirs= |
| 326 | while :; do |
| 327 | case $as_dir in #( |
| 328 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 329 | *) as_qdir=$as_dir;; |
| 330 | esac |
| 331 | as_dirs="'$as_qdir' $as_dirs" |
| 332 | as_dir=`$as_dirname -- "$as_dir" || |
| 333 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 334 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 335 | X"$as_dir" : 'X\(//\)$' \| \ |
| 336 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 337 | $as_echo X"$as_dir" | |
| 338 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 339 | s//\1/ |
| 340 | q |
| 341 | } |
| 342 | /^X\(\/\/\)[^/].*/{ |
| 343 | s//\1/ |
| 344 | q |
| 345 | } |
| 346 | /^X\(\/\/\)$/{ |
| 347 | s//\1/ |
| 348 | q |
| 349 | } |
| 350 | /^X\(\/\).*/{ |
| 351 | s//\1/ |
| 352 | q |
| 353 | } |
| 354 | s/.*/./; q'` |
| 355 | test -d "$as_dir" && break |
| 356 | done |
| 357 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 358 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 359 | |
| 360 | |
| 361 | } # as_fn_mkdir_p |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 362 | |
| 363 | # as_fn_executable_p FILE |
| 364 | # ----------------------- |
| 365 | # Test if FILE is an executable regular file. |
| 366 | as_fn_executable_p () |
| 367 | { |
| 368 | test -f "$1" && test -x "$1" |
| 369 | } # as_fn_executable_p |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 370 | # as_fn_append VAR VALUE |
| 371 | # ---------------------- |
| 372 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 373 | # advantage of any shell optimizations that allow amortized linear growth over |
| 374 | # repeated appends, instead of the typical quadratic growth present in naive |
| 375 | # implementations. |
| 376 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 377 | eval 'as_fn_append () |
| 378 | { |
| 379 | eval $1+=\$2 |
| 380 | }' |
| 381 | else |
| 382 | as_fn_append () |
| 383 | { |
| 384 | eval $1=\$$1\$2 |
| 385 | } |
| 386 | fi # as_fn_append |
| 387 | |
| 388 | # as_fn_arith ARG... |
| 389 | # ------------------ |
| 390 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 391 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 392 | # must be portable across $(()) and expr. |
| 393 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 394 | eval 'as_fn_arith () |
| 395 | { |
| 396 | as_val=$(( $* )) |
| 397 | }' |
| 398 | else |
| 399 | as_fn_arith () |
| 400 | { |
| 401 | as_val=`expr "$@" || test $? -eq 1` |
| 402 | } |
| 403 | fi # as_fn_arith |
| 404 | |
| 405 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 406 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 407 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 408 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 409 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 410 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 411 | as_fn_error () |
| 412 | { |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 413 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 414 | if test "$4"; then |
| 415 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 416 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 417 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 418 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 419 | as_fn_exit $as_status |
| 420 | } # as_fn_error |
| 421 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 422 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 423 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 424 | as_expr=expr |
| 425 | else |
| 426 | as_expr=false |
| 427 | fi |
| 428 | |
| 429 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 430 | as_basename=basename |
| 431 | else |
| 432 | as_basename=false |
| 433 | fi |
| 434 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 435 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 436 | as_dirname=dirname |
| 437 | else |
| 438 | as_dirname=false |
| 439 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 440 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 441 | as_me=`$as_basename -- "$0" || |
| 442 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 443 | X"$0" : 'X\(//\)$' \| \ |
| 444 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 445 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 446 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 447 | s//\1/ |
| 448 | q |
| 449 | } |
| 450 | /^X\/\(\/\/\)$/{ |
| 451 | s//\1/ |
| 452 | q |
| 453 | } |
| 454 | /^X\/\(\/\).*/{ |
| 455 | s//\1/ |
| 456 | q |
| 457 | } |
| 458 | s/.*/./; q'` |
| 459 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 460 | # Avoid depending upon Character Ranges. |
| 461 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 462 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 463 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 464 | as_cr_digits='0123456789' |
| 465 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 466 | |
| 467 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 468 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 469 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 470 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 471 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 472 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 473 | sed -n ' |
| 474 | p |
| 475 | /[$]LINENO/= |
| 476 | ' <$as_myself | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 477 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 478 | s/[$]LINENO.*/&-/ |
| 479 | t lineno |
| 480 | b |
| 481 | :lineno |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 482 | N |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 483 | :loop |
| 484 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 485 | t loop |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 486 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 487 | ' >$as_me.lineno && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 488 | chmod +x "$as_me.lineno" || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 489 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 490 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 491 | # If we had to re-execute with $CONFIG_SHELL, we're ensured to have |
| 492 | # already done that, so ensure we don't try to do so again and fall |
| 493 | # in an infinite loop. This has already happened in practice. |
| 494 | _as_can_reexec=no; export _as_can_reexec |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 495 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 496 | # (the dirname of $[0] is not the place where we might find the |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 497 | # original and so on. Autoconf is especially sensitive to this). |
| 498 | . "./$as_me.lineno" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 499 | # Exit status is that of the last command. |
| 500 | exit |
| 501 | } |
| 502 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 503 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 504 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 505 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 506 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 507 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 508 | xy) ECHO_C='\c';; |
| 509 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 510 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 511 | esac;; |
| 512 | *) |
| 513 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 514 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 515 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 516 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 517 | if test -d conf$$.dir; then |
| 518 | rm -f conf$$.dir/conf$$.file |
| 519 | else |
| 520 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 521 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 522 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 523 | if (echo >conf$$.file) 2>/dev/null; then |
| 524 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 525 | as_ln_s='ln -s' |
| 526 | # ... but there are two gotchas: |
| 527 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 528 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 529 | # In both cases, we have to default to `cp -pR'. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 530 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 531 | as_ln_s='cp -pR' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 532 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 533 | as_ln_s=ln |
| 534 | else |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 535 | as_ln_s='cp -pR' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 536 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 537 | else |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 538 | as_ln_s='cp -pR' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 539 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 540 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 541 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 542 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 543 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 544 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 545 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 546 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 547 | as_mkdir_p=false |
| 548 | fi |
| 549 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 550 | as_test_x='test -x' |
| 551 | as_executable_p=as_fn_executable_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 552 | |
| 553 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 554 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 555 | |
| 556 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 557 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 558 | |
| 559 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 560 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 561 | exec 6>&1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 562 | |
| 563 | # Name of the host. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 564 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 565 | # so uname gets run too. |
| 566 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 567 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 568 | # |
| 569 | # Initializations. |
| 570 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 571 | ac_default_prefix=/usr/local |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 572 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 573 | ac_config_libobj_dir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 574 | LIBOBJS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 575 | cross_compiling=no |
| 576 | subdirs= |
| 577 | MFLAGS= |
| 578 | MAKEFLAGS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 579 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 580 | # Identity of this package. |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 581 | PACKAGE_NAME='python' |
| 582 | PACKAGE_TARNAME='python' |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 583 | PACKAGE_VERSION='3.5' |
| 584 | PACKAGE_STRING='python 3.5' |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 585 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 586 | PACKAGE_URL='' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 587 | |
| 588 | ac_unique_file="Include/object.h" |
| 589 | # Factoring default headers for most tests. |
| 590 | ac_includes_default="\ |
| 591 | #include <stdio.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 592 | #ifdef HAVE_SYS_TYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 593 | # include <sys/types.h> |
| 594 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 595 | #ifdef HAVE_SYS_STAT_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 596 | # include <sys/stat.h> |
| 597 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 598 | #ifdef STDC_HEADERS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 599 | # include <stdlib.h> |
| 600 | # include <stddef.h> |
| 601 | #else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 602 | # ifdef HAVE_STDLIB_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 603 | # include <stdlib.h> |
| 604 | # endif |
| 605 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 606 | #ifdef HAVE_STRING_H |
| 607 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 608 | # include <memory.h> |
| 609 | # endif |
| 610 | # include <string.h> |
| 611 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 612 | #ifdef HAVE_STRINGS_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 613 | # include <strings.h> |
| 614 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 615 | #ifdef HAVE_INTTYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 616 | # include <inttypes.h> |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 617 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 618 | #ifdef HAVE_STDINT_H |
| 619 | # include <stdint.h> |
| 620 | #endif |
| 621 | #ifdef HAVE_UNISTD_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 622 | # include <unistd.h> |
| 623 | #endif" |
| 624 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 625 | ac_subst_vars='LTLIBOBJS |
Ned Deily | 322f5ba | 2013-11-21 23:01:59 -0800 | [diff] [blame] | 626 | ENSUREPIP |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 627 | SRCDIRS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 628 | THREADHEADERS |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 629 | LIBPL |
| 630 | PY_ENABLE_SHARED |
doko@ubuntu.com | d5537d0 | 2013-03-21 13:21:49 -0700 | [diff] [blame] | 631 | EXT_SUFFIX |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 632 | SOABI |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 633 | LIBC |
| 634 | LIBM |
| 635 | HAVE_GETHOSTBYNAME |
| 636 | HAVE_GETHOSTBYNAME_R |
| 637 | HAVE_GETHOSTBYNAME_R_3_ARG |
| 638 | HAVE_GETHOSTBYNAME_R_5_ARG |
| 639 | HAVE_GETHOSTBYNAME_R_6_ARG |
| 640 | LIBOBJS |
| 641 | TRUE |
| 642 | MACHDEP_OBJS |
| 643 | DYNLOADFILE |
| 644 | DLINCLDIR |
| 645 | THREADOBJ |
| 646 | LDLAST |
| 647 | USE_THREAD_MODULE |
| 648 | SIGNAL_OBJS |
| 649 | USE_SIGNAL_MODULE |
Ned Deily | d819b93 | 2013-09-06 01:07:05 -0700 | [diff] [blame] | 650 | TCLTK_LIBS |
| 651 | TCLTK_INCLUDES |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 652 | LIBFFI_INCLUDEDIR |
Benjamin Peterson | 0f3cde1 | 2014-12-15 00:00:23 -0500 | [diff] [blame] | 653 | PKG_CONFIG_LIBDIR |
| 654 | PKG_CONFIG_PATH |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 655 | PKG_CONFIG |
| 656 | SHLIBS |
| 657 | CFLAGSFORSHARED |
| 658 | LINKFORSHARED |
| 659 | CCSHARED |
| 660 | BLDSHARED |
| 661 | LDCXXSHARED |
| 662 | LDSHARED |
doko@ubuntu.com | d5537d0 | 2013-03-21 13:21:49 -0700 | [diff] [blame] | 663 | SHLIB_SUFFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 664 | LIBTOOL_CRUFT |
| 665 | OTHER_LIBTOOL_OPT |
| 666 | UNIVERSAL_ARCH_FLAGS |
Benjamin Peterson | acb8c52 | 2014-08-09 20:01:49 -0700 | [diff] [blame] | 667 | CFLAGS_NODIST |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 668 | BASECFLAGS |
| 669 | OPT |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 670 | ABIFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 671 | LN |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 672 | MKDIR_P |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 673 | INSTALL_DATA |
| 674 | INSTALL_SCRIPT |
| 675 | INSTALL_PROGRAM |
Kushal Das | 02d23a2 | 2014-04-15 23:50:06 +0530 | [diff] [blame] | 676 | OPCODEHGEN |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 677 | PYTHON |
| 678 | ASDLGEN |
doko@ubuntu.com | 5884449 | 2012-06-30 18:25:32 +0200 | [diff] [blame] | 679 | ac_ct_READELF |
| 680 | READELF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 681 | ARFLAGS |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 682 | ac_ct_AR |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 683 | AR |
| 684 | RANLIB |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 685 | USE_INLINE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 686 | GNULD |
| 687 | LINKCC |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 688 | LDVERSION |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 689 | RUNSHARED |
| 690 | INSTSONAME |
| 691 | LDLIBRARYDIR |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 692 | PY3LIBRARY |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 693 | BLDLIBRARY |
| 694 | DLLLIBRARY |
| 695 | LDLIBRARY |
| 696 | LIBRARY |
doko@python.org | 3e6e2ac | 2013-01-25 13:12:29 +0100 | [diff] [blame] | 697 | MULTIARCH |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 698 | BUILDEXEEXT |
| 699 | EGREP |
| 700 | GREP |
| 701 | CPP |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 702 | NO_AS_NEEDED |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 703 | ac_ct_CXX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 704 | MAINCC |
| 705 | CXX |
| 706 | OBJEXT |
| 707 | EXEEXT |
| 708 | ac_ct_CC |
| 709 | CPPFLAGS |
| 710 | LDFLAGS |
| 711 | CFLAGS |
| 712 | CC |
| 713 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 714 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 715 | SGI_ABI |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 716 | _PYTHON_HOST_PLATFORM |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 717 | MACHDEP |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 718 | FRAMEWORKINSTALLAPPSPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 719 | FRAMEWORKUNIXTOOLSPREFIX |
Ned Deily | b8f944f | 2013-11-21 22:42:25 -0800 | [diff] [blame] | 720 | FRAMEWORKPYTHONW |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 721 | FRAMEWORKALTINSTALLLAST |
| 722 | FRAMEWORKALTINSTALLFIRST |
| 723 | FRAMEWORKINSTALLLAST |
| 724 | FRAMEWORKINSTALLFIRST |
| 725 | PYTHONFRAMEWORKINSTALLDIR |
| 726 | PYTHONFRAMEWORKPREFIX |
| 727 | PYTHONFRAMEWORKDIR |
| 728 | PYTHONFRAMEWORKIDENTIFIER |
| 729 | PYTHONFRAMEWORK |
| 730 | LIPO_32BIT_FLAGS |
| 731 | ARCH_RUN_32BIT |
| 732 | UNIVERSALSDK |
| 733 | CONFIG_ARGS |
| 734 | SOVERSION |
| 735 | VERSION |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 736 | PYTHON_FOR_BUILD |
Matthias Klose | ca2f6ec | 2012-03-15 21:30:11 +0100 | [diff] [blame] | 737 | host_os |
| 738 | host_vendor |
| 739 | host_cpu |
| 740 | host |
| 741 | build_os |
| 742 | build_vendor |
| 743 | build_cpu |
| 744 | build |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 745 | HAS_HG |
| 746 | HGBRANCH |
| 747 | HGTAG |
| 748 | HGVERSION |
Trent Nelson | 4d4ec65 | 2012-10-16 08:51:24 -0400 | [diff] [blame] | 749 | BASECPPFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 750 | target_alias |
| 751 | host_alias |
| 752 | build_alias |
| 753 | LIBS |
| 754 | ECHO_T |
| 755 | ECHO_N |
| 756 | ECHO_C |
| 757 | DEFS |
| 758 | mandir |
| 759 | localedir |
| 760 | libdir |
| 761 | psdir |
| 762 | pdfdir |
| 763 | dvidir |
| 764 | htmldir |
| 765 | infodir |
| 766 | docdir |
| 767 | oldincludedir |
| 768 | includedir |
| 769 | localstatedir |
| 770 | sharedstatedir |
| 771 | sysconfdir |
| 772 | datadir |
| 773 | datarootdir |
| 774 | libexecdir |
| 775 | sbindir |
| 776 | bindir |
| 777 | program_transform_name |
| 778 | prefix |
| 779 | exec_prefix |
| 780 | PACKAGE_URL |
| 781 | PACKAGE_BUGREPORT |
| 782 | PACKAGE_STRING |
| 783 | PACKAGE_VERSION |
| 784 | PACKAGE_TARNAME |
| 785 | PACKAGE_NAME |
| 786 | PATH_SEPARATOR |
| 787 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 788 | ac_subst_files='' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 789 | ac_user_opts=' |
| 790 | enable_option_checking |
| 791 | enable_universalsdk |
| 792 | with_universal_archs |
| 793 | with_framework_name |
| 794 | enable_framework |
| 795 | with_gcc |
| 796 | with_cxx_main |
| 797 | with_suffix |
| 798 | enable_shared |
| 799 | enable_profiling |
| 800 | with_pydebug |
Christian Heimes | 985ecdc | 2013-11-20 11:46:18 +0100 | [diff] [blame] | 801 | with_hash_algorithm |
Charles-François Natali | d30b022 | 2014-05-08 23:08:51 +0100 | [diff] [blame] | 802 | with_address_sanitizer |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 803 | with_libs |
| 804 | with_system_expat |
| 805 | with_system_ffi |
Stefan Krah | 60187b5 | 2012-03-23 19:06:27 +0100 | [diff] [blame] | 806 | with_system_libmpdec |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 807 | enable_loadable_sqlite_extensions |
Ned Deily | d819b93 | 2013-09-06 01:07:05 -0700 | [diff] [blame] | 808 | with_tcltk_includes |
| 809 | with_tcltk_libs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 810 | with_dbmliborder |
| 811 | with_signal_module |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 812 | with_threads |
| 813 | with_thread |
| 814 | enable_ipv6 |
| 815 | with_doc_strings |
| 816 | with_tsc |
| 817 | with_pymalloc |
| 818 | with_valgrind |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 819 | with_fpectl |
| 820 | with_libm |
| 821 | with_libc |
| 822 | enable_big_digits |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 823 | with_computed_gotos |
Ned Deily | 322f5ba | 2013-11-21 23:01:59 -0800 | [diff] [blame] | 824 | with_ensurepip |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 825 | ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 826 | ac_precious_vars='build_alias |
| 827 | host_alias |
| 828 | target_alias |
doko@python.org | eab42bf | 2013-01-26 18:57:19 +0100 | [diff] [blame] | 829 | MACHDEP |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 830 | CC |
| 831 | CFLAGS |
| 832 | LDFLAGS |
| 833 | LIBS |
| 834 | CPPFLAGS |
Benjamin Peterson | 0f3cde1 | 2014-12-15 00:00:23 -0500 | [diff] [blame] | 835 | CPP |
| 836 | PKG_CONFIG |
| 837 | PKG_CONFIG_PATH |
| 838 | PKG_CONFIG_LIBDIR' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 839 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 840 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 841 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 842 | ac_init_help= |
| 843 | ac_init_version=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 844 | ac_unrecognized_opts= |
| 845 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 846 | # The variables have the same names as the options, with |
| 847 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 848 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 849 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 850 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 851 | no_recursion= |
| 852 | prefix=NONE |
| 853 | program_prefix=NONE |
| 854 | program_suffix=NONE |
| 855 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 856 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 857 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 858 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 859 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 860 | x_includes=NONE |
| 861 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 862 | |
| 863 | # Installation directory options. |
| 864 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 865 | # and all the variables that are supposed to be based on exec_prefix |
| 866 | # by default will actually change. |
| 867 | # Use braces instead of parens because sh, perl, etc. also accept them. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 868 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 869 | bindir='${exec_prefix}/bin' |
| 870 | sbindir='${exec_prefix}/sbin' |
| 871 | libexecdir='${exec_prefix}/libexec' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 872 | datarootdir='${prefix}/share' |
| 873 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 874 | sysconfdir='${prefix}/etc' |
| 875 | sharedstatedir='${prefix}/com' |
| 876 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 877 | includedir='${prefix}/include' |
| 878 | oldincludedir='/usr/include' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 879 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 880 | infodir='${datarootdir}/info' |
| 881 | htmldir='${docdir}' |
| 882 | dvidir='${docdir}' |
| 883 | pdfdir='${docdir}' |
| 884 | psdir='${docdir}' |
| 885 | libdir='${exec_prefix}/lib' |
| 886 | localedir='${datarootdir}/locale' |
| 887 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 888 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 889 | ac_prev= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 890 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 891 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 892 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 893 | # If the previous option needs an argument, assign it. |
| 894 | if test -n "$ac_prev"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 895 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 896 | ac_prev= |
| 897 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 898 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 899 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 900 | case $ac_option in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 901 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 902 | *=) ac_optarg= ;; |
| 903 | *) ac_optarg=yes ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 904 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 905 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 906 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 907 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 908 | case $ac_dashdash$ac_option in |
| 909 | --) |
| 910 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 911 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 912 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 913 | ac_prev=bindir ;; |
| 914 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 915 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 916 | |
| 917 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 918 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 919 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 920 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 921 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 922 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 923 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 924 | ac_prev=cache_file ;; |
| 925 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 926 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 927 | cache_file=$ac_optarg ;; |
| 928 | |
| 929 | --config-cache | -C) |
| 930 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 931 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 932 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 933 | ac_prev=datadir ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 934 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 935 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 936 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 937 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 938 | | --dataroo | --dataro | --datar) |
| 939 | ac_prev=datarootdir ;; |
| 940 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 941 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 942 | datarootdir=$ac_optarg ;; |
| 943 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 944 | -disable-* | --disable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 945 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 946 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 947 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 948 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 949 | ac_useropt_orig=$ac_useropt |
| 950 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 951 | case $ac_user_opts in |
| 952 | *" |
| 953 | "enable_$ac_useropt" |
| 954 | "*) ;; |
| 955 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 956 | ac_unrecognized_sep=', ';; |
| 957 | esac |
| 958 | eval enable_$ac_useropt=no ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 959 | |
| 960 | -docdir | --docdir | --docdi | --doc | --do) |
| 961 | ac_prev=docdir ;; |
| 962 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 963 | docdir=$ac_optarg ;; |
| 964 | |
| 965 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 966 | ac_prev=dvidir ;; |
| 967 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 968 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 969 | |
| 970 | -enable-* | --enable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 971 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 972 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 973 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 974 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 975 | ac_useropt_orig=$ac_useropt |
| 976 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 977 | case $ac_user_opts in |
| 978 | *" |
| 979 | "enable_$ac_useropt" |
| 980 | "*) ;; |
| 981 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 982 | ac_unrecognized_sep=', ';; |
| 983 | esac |
| 984 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 985 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 986 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 987 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 988 | | --exec | --exe | --ex) |
| 989 | ac_prev=exec_prefix ;; |
| 990 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 991 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 992 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 993 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 994 | |
| 995 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 996 | # Obsolete; use --with-gas. |
| 997 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 998 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 999 | -help | --help | --hel | --he | -h) |
| 1000 | ac_init_help=long ;; |
| 1001 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 1002 | ac_init_help=recursive ;; |
| 1003 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 1004 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1005 | |
| 1006 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1007 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1008 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1009 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1010 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1011 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 1012 | ac_prev=htmldir ;; |
| 1013 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 1014 | | --ht=*) |
| 1015 | htmldir=$ac_optarg ;; |
| 1016 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1017 | -includedir | --includedir | --includedi | --included | --include \ |
| 1018 | | --includ | --inclu | --incl | --inc) |
| 1019 | ac_prev=includedir ;; |
| 1020 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 1021 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1022 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1023 | |
| 1024 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 1025 | ac_prev=infodir ;; |
| 1026 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1027 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1028 | |
| 1029 | -libdir | --libdir | --libdi | --libd) |
| 1030 | ac_prev=libdir ;; |
| 1031 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1032 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1033 | |
| 1034 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 1035 | | --libexe | --libex | --libe) |
| 1036 | ac_prev=libexecdir ;; |
| 1037 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 1038 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1039 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1040 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1041 | -localedir | --localedir | --localedi | --localed | --locale) |
| 1042 | ac_prev=localedir ;; |
| 1043 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 1044 | localedir=$ac_optarg ;; |
| 1045 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1046 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1047 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1048 | ac_prev=localstatedir ;; |
| 1049 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1050 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1051 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1052 | |
| 1053 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 1054 | ac_prev=mandir ;; |
| 1055 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1056 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1057 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1058 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1059 | # Obsolete; use --without-fp. |
| 1060 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1061 | |
| 1062 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1063 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1064 | no_create=yes ;; |
| 1065 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1066 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 1067 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 1068 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1069 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1070 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 1071 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 1072 | | --oldin | --oldi | --old | --ol | --o) |
| 1073 | ac_prev=oldincludedir ;; |
| 1074 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1075 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1076 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1077 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1078 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1079 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1080 | ac_prev=prefix ;; |
| 1081 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1082 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1083 | |
| 1084 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1085 | | --program-pre | --program-pr | --program-p) |
| 1086 | ac_prev=program_prefix ;; |
| 1087 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1088 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1089 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1090 | |
| 1091 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1092 | | --program-suf | --program-su | --program-s) |
| 1093 | ac_prev=program_suffix ;; |
| 1094 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1095 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1096 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1097 | |
| 1098 | -program-transform-name | --program-transform-name \ |
| 1099 | | --program-transform-nam | --program-transform-na \ |
| 1100 | | --program-transform-n | --program-transform- \ |
| 1101 | | --program-transform | --program-transfor \ |
| 1102 | | --program-transfo | --program-transf \ |
| 1103 | | --program-trans | --program-tran \ |
| 1104 | | --progr-tra | --program-tr | --program-t) |
| 1105 | ac_prev=program_transform_name ;; |
| 1106 | -program-transform-name=* | --program-transform-name=* \ |
| 1107 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1108 | | --program-transform-n=* | --program-transform-=* \ |
| 1109 | | --program-transform=* | --program-transfor=* \ |
| 1110 | | --program-transfo=* | --program-transf=* \ |
| 1111 | | --program-trans=* | --program-tran=* \ |
| 1112 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1113 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1114 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1115 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1116 | ac_prev=pdfdir ;; |
| 1117 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1118 | pdfdir=$ac_optarg ;; |
| 1119 | |
| 1120 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1121 | ac_prev=psdir ;; |
| 1122 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1123 | psdir=$ac_optarg ;; |
| 1124 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1125 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1126 | | -silent | --silent | --silen | --sile | --sil) |
| 1127 | silent=yes ;; |
| 1128 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1129 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1130 | ac_prev=sbindir ;; |
| 1131 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1132 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1133 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1134 | |
| 1135 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1136 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1137 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1138 | | --sha | --sh) |
| 1139 | ac_prev=sharedstatedir ;; |
| 1140 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1141 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1142 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1143 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1144 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1145 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1146 | -site | --site | --sit) |
| 1147 | ac_prev=site ;; |
| 1148 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1149 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1150 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1151 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1152 | ac_prev=srcdir ;; |
| 1153 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1154 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1155 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1156 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1157 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1158 | ac_prev=sysconfdir ;; |
| 1159 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1160 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1161 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1162 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1163 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1164 | ac_prev=target_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1165 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1166 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1167 | |
| 1168 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1169 | verbose=yes ;; |
| 1170 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1171 | -version | --version | --versio | --versi | --vers | -V) |
| 1172 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1173 | |
| 1174 | -with-* | --with-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1175 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1176 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1177 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1178 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1179 | ac_useropt_orig=$ac_useropt |
| 1180 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1181 | case $ac_user_opts in |
| 1182 | *" |
| 1183 | "with_$ac_useropt" |
| 1184 | "*) ;; |
| 1185 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1186 | ac_unrecognized_sep=', ';; |
| 1187 | esac |
| 1188 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1189 | |
| 1190 | -without-* | --without-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1191 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1192 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1193 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1194 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1195 | ac_useropt_orig=$ac_useropt |
| 1196 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1197 | case $ac_user_opts in |
| 1198 | *" |
| 1199 | "with_$ac_useropt" |
| 1200 | "*) ;; |
| 1201 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1202 | ac_unrecognized_sep=', ';; |
| 1203 | esac |
| 1204 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1205 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1206 | --x) |
| 1207 | # Obsolete; use --with-x. |
| 1208 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1209 | |
| 1210 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1211 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1212 | ac_prev=x_includes ;; |
| 1213 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1214 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1215 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1216 | |
| 1217 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1218 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1219 | ac_prev=x_libraries ;; |
| 1220 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1221 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1222 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1223 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1224 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
| 1225 | Try \`$0 --help' for more information" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1226 | ;; |
| 1227 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1228 | *=*) |
| 1229 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1230 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1231 | case $ac_envvar in #( |
| 1232 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1233 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1234 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1235 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1236 | export $ac_envvar ;; |
| 1237 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1238 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1239 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1240 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1241 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1242 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1243 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1244 | ;; |
| 1245 | |
| 1246 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1247 | done |
| 1248 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1249 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1250 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1251 | as_fn_error $? "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1252 | fi |
| 1253 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1254 | if test -n "$ac_unrecognized_opts"; then |
| 1255 | case $enable_option_checking in |
| 1256 | no) ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1257 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1258 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1259 | esac |
| 1260 | fi |
| 1261 | |
| 1262 | # Check all directory arguments for consistency. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1263 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1264 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1265 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1266 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1267 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1268 | eval ac_val=\$$ac_var |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1269 | # Remove trailing slashes. |
| 1270 | case $ac_val in |
| 1271 | */ ) |
| 1272 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1273 | eval $ac_var=\$ac_val;; |
| 1274 | esac |
| 1275 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1276 | case $ac_val in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1277 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1278 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1279 | esac |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1280 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1281 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1282 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1283 | # There might be people who depend on the old broken behavior: `$host' |
| 1284 | # used to hold the argument of --host etc. |
| 1285 | # FIXME: To remove some day. |
| 1286 | build=$build_alias |
| 1287 | host=$host_alias |
| 1288 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1289 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1290 | # FIXME: To remove some day. |
| 1291 | if test "x$host_alias" != x; then |
| 1292 | if test "x$build_alias" = x; then |
| 1293 | cross_compiling=maybe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1294 | elif test "x$build_alias" != "x$host_alias"; then |
| 1295 | cross_compiling=yes |
| 1296 | fi |
| 1297 | fi |
| 1298 | |
| 1299 | ac_tool_prefix= |
| 1300 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1301 | |
| 1302 | test "$silent" = yes && exec 6>/dev/null |
| 1303 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1304 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1305 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1306 | ac_ls_di=`ls -di .` && |
| 1307 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1308 | as_fn_error $? "working directory cannot be determined" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1309 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1310 | as_fn_error $? "pwd does not report name of working directory" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1311 | |
| 1312 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1313 | # Find the source files, if location was not specified. |
| 1314 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1315 | ac_srcdir_defaulted=yes |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1316 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1317 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1318 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1319 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1320 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1321 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1322 | $as_echo X"$as_myself" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1323 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1324 | s//\1/ |
| 1325 | q |
| 1326 | } |
| 1327 | /^X\(\/\/\)[^/].*/{ |
| 1328 | s//\1/ |
| 1329 | q |
| 1330 | } |
| 1331 | /^X\(\/\/\)$/{ |
| 1332 | s//\1/ |
| 1333 | q |
| 1334 | } |
| 1335 | /^X\(\/\).*/{ |
| 1336 | s//\1/ |
| 1337 | q |
| 1338 | } |
| 1339 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1340 | srcdir=$ac_confdir |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1341 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1342 | srcdir=.. |
| 1343 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1344 | else |
| 1345 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1346 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1347 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1348 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1349 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 1350 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1351 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1352 | ac_abs_confdir=`( |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1353 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1354 | pwd)` |
| 1355 | # When building in place, set srcdir=. |
| 1356 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1357 | srcdir=. |
| 1358 | fi |
| 1359 | # Remove unnecessary trailing slashes from srcdir. |
| 1360 | # Double slashes in file names in object file debugging info |
| 1361 | # mess up M-x gdb in Emacs. |
| 1362 | case $srcdir in |
| 1363 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1364 | esac |
| 1365 | for ac_var in $ac_precious_vars; do |
| 1366 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1367 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1368 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1369 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1370 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1371 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1372 | # |
| 1373 | # Report the --help message. |
| 1374 | # |
| 1375 | if test "$ac_init_help" = "long"; then |
| 1376 | # Omit some internal or obsolete options to make the list less imposing. |
| 1377 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1378 | cat <<_ACEOF |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 1379 | \`configure' configures python 3.5 to adapt to many kinds of systems. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1380 | |
| 1381 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1382 | |
| 1383 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1384 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1385 | |
| 1386 | Defaults for the options are specified in brackets. |
| 1387 | |
| 1388 | Configuration: |
| 1389 | -h, --help display this help and exit |
| 1390 | --help=short display options specific to this package |
| 1391 | --help=recursive display the short help of all the included packages |
| 1392 | -V, --version display version information and exit |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1393 | -q, --quiet, --silent do not print \`checking ...' messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1394 | --cache-file=FILE cache test results in FILE [disabled] |
| 1395 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1396 | -n, --no-create do not create output files |
| 1397 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1398 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1399 | Installation directories: |
| 1400 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1401 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1402 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1403 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1404 | |
| 1405 | By default, \`make install' will install all the files in |
| 1406 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1407 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1408 | for instance \`--prefix=\$HOME'. |
| 1409 | |
| 1410 | For better control, use the options below. |
| 1411 | |
| 1412 | Fine tuning of the installation directories: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1413 | --bindir=DIR user executables [EPREFIX/bin] |
| 1414 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1415 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1416 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1417 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1418 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1419 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1420 | --includedir=DIR C header files [PREFIX/include] |
| 1421 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1422 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1423 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1424 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1425 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1426 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1427 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1428 | --htmldir=DIR html documentation [DOCDIR] |
| 1429 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1430 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1431 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1432 | _ACEOF |
| 1433 | |
| 1434 | cat <<\_ACEOF |
Matthias Klose | ca2f6ec | 2012-03-15 21:30:11 +0100 | [diff] [blame] | 1435 | |
| 1436 | System types: |
| 1437 | --build=BUILD configure for building on BUILD [guessed] |
| 1438 | --host=HOST cross-compile to build programs to run on HOST [BUILD] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1439 | _ACEOF |
| 1440 | fi |
| 1441 | |
| 1442 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1443 | case $ac_init_help in |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 1444 | short | recursive ) echo "Configuration of python 3.5:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1445 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1446 | cat <<\_ACEOF |
| 1447 | |
| 1448 | Optional Features: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1449 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1450 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1451 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Christian Heimes | 68f5fbe | 2008-02-14 08:27:37 +0000 | [diff] [blame] | 1452 | --enable-universalsdk[=SDKDIR] |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 1453 | Build fat binary against Mac OS X SDK |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1454 | --enable-framework[=INSTALLDIR] |
| 1455 | Build (MacOSX|Darwin) framework |
| 1456 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1457 | --enable-profiling enable C-level code profiling |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 1458 | --enable-loadable-sqlite-extensions |
| 1459 | support loadable extensions in _sqlite module |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1460 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1461 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 1462 | --enable-big-digits[=BITS] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1463 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1464 | |
| 1465 | Optional Packages: |
| 1466 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1467 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 1468 | --with-universal-archs=ARCH |
| 1469 | select architectures for universal build ("32-bit", |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 1470 | "64-bit", "3-way", "intel", "intel-32", or "all") |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 1471 | --with-framework-name=FRAMEWORK |
| 1472 | specify an alternate name of the framework built |
| 1473 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1474 | --without-gcc never use gcc |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1475 | --with-cxx-main=<compiler> |
| 1476 | compile main() and link python executable with C++ |
| 1477 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1478 | --with-suffix=.exe set executable suffix |
| 1479 | --with-pydebug build with Py_DEBUG defined |
Christian Heimes | 985ecdc | 2013-11-20 11:46:18 +0100 | [diff] [blame] | 1480 | --with-hash-algorithm=[fnv|siphash24] |
| 1481 | select hash algorithm |
Charles-François Natali | d30b022 | 2014-05-08 23:08:51 +0100 | [diff] [blame] | 1482 | --with-address-sanitizer |
| 1483 | enable AddressSanitizer |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1484 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | b2d9046 | 2009-12-31 03:23:10 +0000 | [diff] [blame] | 1485 | --with-system-expat build pyexpat module using an installed expat |
| 1486 | library |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1487 | --with-system-ffi build _ctypes module using an installed ffi library |
Stefan Krah | 60187b5 | 2012-03-23 19:06:27 +0100 | [diff] [blame] | 1488 | --with-system-libmpdec build _decimal module using an installed libmpdec |
| 1489 | library |
Ned Deily | d819b93 | 2013-09-06 01:07:05 -0700 | [diff] [blame] | 1490 | --with-tcltk-includes='-I...' |
| 1491 | override search for Tcl and Tk include files |
| 1492 | --with-tcltk-libs='-L...' |
| 1493 | override search for Tcl and Tk libs |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 1494 | --with-dbmliborder=db1:db2:... |
| 1495 | order to check db backends for dbm. Valid value is a |
| 1496 | colon separated string with the backend names |
| 1497 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1498 | --with-signal-module disable/enable signal module |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1499 | --with(out)-threads[=DIRECTORY] |
| 1500 | disable/enable thread support |
| 1501 | --with(out)-thread[=DIRECTORY] |
| 1502 | deprecated; use --with(out)-threads |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1503 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1504 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1505 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 1506 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1507 | --with-fpectl enable SIGFPE catching |
| 1508 | --with-libm=STRING math library |
| 1509 | --with-libc=STRING C library |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 1510 | --with(out)-computed-gotos |
| 1511 | Use computed gotos in evaluation loop (enabled by |
| 1512 | default on supported compilers) |
Ned Deily | 322f5ba | 2013-11-21 23:01:59 -0800 | [diff] [blame] | 1513 | --with(out)-ensurepip=[=upgrade] |
| 1514 | "install" or "upgrade" using bundled pip |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1515 | |
| 1516 | Some influential environment variables: |
doko@python.org | eab42bf | 2013-01-26 18:57:19 +0100 | [diff] [blame] | 1517 | MACHDEP name for machine-dependent library files |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1518 | CC C compiler command |
| 1519 | CFLAGS C compiler flags |
| 1520 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1521 | nonstandard directory <lib dir> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1522 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1523 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1524 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1525 | CPP C preprocessor |
Benjamin Peterson | 0f3cde1 | 2014-12-15 00:00:23 -0500 | [diff] [blame] | 1526 | PKG_CONFIG path to pkg-config utility |
| 1527 | PKG_CONFIG_PATH |
| 1528 | directories to add to pkg-config's search path |
| 1529 | PKG_CONFIG_LIBDIR |
| 1530 | path overriding pkg-config's built-in search path |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1531 | |
| 1532 | Use these variables to override the choices made by `configure' or to help |
| 1533 | it to find libraries and programs with nonstandard names/locations. |
| 1534 | |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 1535 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1536 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1537 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1538 | fi |
| 1539 | |
| 1540 | if test "$ac_init_help" = "recursive"; then |
| 1541 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1542 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1543 | test -d "$ac_dir" || |
| 1544 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1545 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1546 | ac_builddir=. |
| 1547 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1548 | case "$ac_dir" in |
| 1549 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1550 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1551 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1552 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1553 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1554 | case $ac_top_builddir_sub in |
| 1555 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1556 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1557 | esac ;; |
| 1558 | esac |
| 1559 | ac_abs_top_builddir=$ac_pwd |
| 1560 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1561 | # for backward compatibility: |
| 1562 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1563 | |
| 1564 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1565 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1566 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1567 | ac_top_srcdir=$ac_top_builddir_sub |
| 1568 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1569 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1570 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1571 | ac_top_srcdir=$srcdir |
| 1572 | ac_abs_top_srcdir=$srcdir ;; |
| 1573 | *) # Relative name. |
| 1574 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1575 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1576 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1577 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1578 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1579 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1580 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1581 | # Check for guested configure. |
| 1582 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1583 | echo && |
| 1584 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1585 | elif test -f "$ac_srcdir/configure"; then |
| 1586 | echo && |
| 1587 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1588 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1589 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1590 | fi || ac_status=$? |
| 1591 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1592 | done |
| 1593 | fi |
| 1594 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1595 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1596 | if $ac_init_version; then |
| 1597 | cat <<\_ACEOF |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 1598 | python configure 3.5 |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 1599 | generated by GNU Autoconf 2.69 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1600 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 1601 | Copyright (C) 2012 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1602 | This configure script is free software; the Free Software Foundation |
| 1603 | gives unlimited permission to copy, distribute and modify it. |
| 1604 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1605 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1606 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1607 | |
| 1608 | ## ------------------------ ## |
| 1609 | ## Autoconf initialization. ## |
| 1610 | ## ------------------------ ## |
| 1611 | |
| 1612 | # ac_fn_c_try_compile LINENO |
| 1613 | # -------------------------- |
| 1614 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1615 | ac_fn_c_try_compile () |
| 1616 | { |
| 1617 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1618 | rm -f conftest.$ac_objext |
| 1619 | if { { ac_try="$ac_compile" |
| 1620 | case "(($ac_try" in |
| 1621 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1622 | *) ac_try_echo=$ac_try;; |
| 1623 | esac |
| 1624 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1625 | $as_echo "$ac_try_echo"; } >&5 |
| 1626 | (eval "$ac_compile") 2>conftest.err |
| 1627 | ac_status=$? |
| 1628 | if test -s conftest.err; then |
| 1629 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1630 | cat conftest.er1 >&5 |
| 1631 | mv -f conftest.er1 conftest.err |
| 1632 | fi |
| 1633 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1634 | test $ac_status = 0; } && { |
| 1635 | test -z "$ac_c_werror_flag" || |
| 1636 | test ! -s conftest.err |
| 1637 | } && test -s conftest.$ac_objext; then : |
| 1638 | ac_retval=0 |
| 1639 | else |
| 1640 | $as_echo "$as_me: failed program was:" >&5 |
| 1641 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1642 | |
| 1643 | ac_retval=1 |
| 1644 | fi |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1645 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1646 | as_fn_set_status $ac_retval |
| 1647 | |
| 1648 | } # ac_fn_c_try_compile |
| 1649 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1650 | # ac_fn_c_try_link LINENO |
| 1651 | # ----------------------- |
| 1652 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1653 | ac_fn_c_try_link () |
| 1654 | { |
| 1655 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1656 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1657 | if { { ac_try="$ac_link" |
| 1658 | case "(($ac_try" in |
| 1659 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1660 | *) ac_try_echo=$ac_try;; |
| 1661 | esac |
| 1662 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1663 | $as_echo "$ac_try_echo"; } >&5 |
| 1664 | (eval "$ac_link") 2>conftest.err |
| 1665 | ac_status=$? |
| 1666 | if test -s conftest.err; then |
| 1667 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1668 | cat conftest.er1 >&5 |
| 1669 | mv -f conftest.er1 conftest.err |
| 1670 | fi |
| 1671 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1672 | test $ac_status = 0; } && { |
| 1673 | test -z "$ac_c_werror_flag" || |
| 1674 | test ! -s conftest.err |
| 1675 | } && test -s conftest$ac_exeext && { |
| 1676 | test "$cross_compiling" = yes || |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 1677 | test -x conftest$ac_exeext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1678 | }; then : |
| 1679 | ac_retval=0 |
| 1680 | else |
| 1681 | $as_echo "$as_me: failed program was:" >&5 |
| 1682 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1683 | |
| 1684 | ac_retval=1 |
| 1685 | fi |
| 1686 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1687 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1688 | # interfere with the next link command; also delete a directory that is |
| 1689 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1690 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1691 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1692 | as_fn_set_status $ac_retval |
| 1693 | |
| 1694 | } # ac_fn_c_try_link |
| 1695 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1696 | # ac_fn_c_try_cpp LINENO |
| 1697 | # ---------------------- |
| 1698 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1699 | ac_fn_c_try_cpp () |
| 1700 | { |
| 1701 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1702 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1703 | case "(($ac_try" in |
| 1704 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1705 | *) ac_try_echo=$ac_try;; |
| 1706 | esac |
| 1707 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1708 | $as_echo "$ac_try_echo"; } >&5 |
| 1709 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1710 | ac_status=$? |
| 1711 | if test -s conftest.err; then |
| 1712 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1713 | cat conftest.er1 >&5 |
| 1714 | mv -f conftest.er1 conftest.err |
| 1715 | fi |
| 1716 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1717 | test $ac_status = 0; } > conftest.i && { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1718 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1719 | test ! -s conftest.err |
| 1720 | }; then : |
| 1721 | ac_retval=0 |
| 1722 | else |
| 1723 | $as_echo "$as_me: failed program was:" >&5 |
| 1724 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1725 | |
| 1726 | ac_retval=1 |
| 1727 | fi |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1728 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1729 | as_fn_set_status $ac_retval |
| 1730 | |
| 1731 | } # ac_fn_c_try_cpp |
| 1732 | |
| 1733 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1734 | # ------------------------------------------------------- |
| 1735 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1736 | # the include files in INCLUDES and setting the cache variable VAR |
| 1737 | # accordingly. |
| 1738 | ac_fn_c_check_header_mongrel () |
| 1739 | { |
| 1740 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1741 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1742 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1743 | $as_echo_n "checking for $2... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1744 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1745 | $as_echo_n "(cached) " >&6 |
| 1746 | fi |
| 1747 | eval ac_res=\$$3 |
| 1748 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1749 | $as_echo "$ac_res" >&6; } |
| 1750 | else |
| 1751 | # Is the header compilable? |
| 1752 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1753 | $as_echo_n "checking $2 usability... " >&6; } |
| 1754 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1755 | /* end confdefs.h. */ |
| 1756 | $4 |
| 1757 | #include <$2> |
| 1758 | _ACEOF |
| 1759 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1760 | ac_header_compiler=yes |
| 1761 | else |
| 1762 | ac_header_compiler=no |
| 1763 | fi |
| 1764 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1766 | $as_echo "$ac_header_compiler" >&6; } |
| 1767 | |
| 1768 | # Is the header present? |
| 1769 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1770 | $as_echo_n "checking $2 presence... " >&6; } |
| 1771 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1772 | /* end confdefs.h. */ |
| 1773 | #include <$2> |
| 1774 | _ACEOF |
| 1775 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1776 | ac_header_preproc=yes |
| 1777 | else |
| 1778 | ac_header_preproc=no |
| 1779 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1780 | rm -f conftest.err conftest.i conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1782 | $as_echo "$ac_header_preproc" >&6; } |
| 1783 | |
| 1784 | # So? What about this header? |
| 1785 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1786 | yes:no: ) |
| 1787 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1788 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1789 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1790 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1791 | ;; |
| 1792 | no:yes:* ) |
| 1793 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1794 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1795 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1796 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1797 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1798 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1799 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1800 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1801 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1802 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1803 | ( $as_echo "## -------------------------------------- ## |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1804 | ## Report this to http://bugs.python.org/ ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1805 | ## -------------------------------------- ##" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1806 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1807 | ;; |
| 1808 | esac |
| 1809 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1810 | $as_echo_n "checking for $2... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1811 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1812 | $as_echo_n "(cached) " >&6 |
| 1813 | else |
| 1814 | eval "$3=\$ac_header_compiler" |
| 1815 | fi |
| 1816 | eval ac_res=\$$3 |
| 1817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1818 | $as_echo "$ac_res" >&6; } |
| 1819 | fi |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1820 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1821 | |
| 1822 | } # ac_fn_c_check_header_mongrel |
| 1823 | |
| 1824 | # ac_fn_c_try_run LINENO |
| 1825 | # ---------------------- |
| 1826 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1827 | # that executables *can* be run. |
| 1828 | ac_fn_c_try_run () |
| 1829 | { |
| 1830 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1831 | if { { ac_try="$ac_link" |
| 1832 | case "(($ac_try" in |
| 1833 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1834 | *) ac_try_echo=$ac_try;; |
| 1835 | esac |
| 1836 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1837 | $as_echo "$ac_try_echo"; } >&5 |
| 1838 | (eval "$ac_link") 2>&5 |
| 1839 | ac_status=$? |
| 1840 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1841 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1842 | { { case "(($ac_try" in |
| 1843 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1844 | *) ac_try_echo=$ac_try;; |
| 1845 | esac |
| 1846 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1847 | $as_echo "$ac_try_echo"; } >&5 |
| 1848 | (eval "$ac_try") 2>&5 |
| 1849 | ac_status=$? |
| 1850 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1851 | test $ac_status = 0; }; }; then : |
| 1852 | ac_retval=0 |
| 1853 | else |
| 1854 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1855 | $as_echo "$as_me: failed program was:" >&5 |
| 1856 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1857 | |
| 1858 | ac_retval=$ac_status |
| 1859 | fi |
| 1860 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1861 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1862 | as_fn_set_status $ac_retval |
| 1863 | |
| 1864 | } # ac_fn_c_try_run |
| 1865 | |
| 1866 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1867 | # ------------------------------------------------------- |
| 1868 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1869 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1870 | ac_fn_c_check_header_compile () |
| 1871 | { |
| 1872 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1873 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1874 | $as_echo_n "checking for $2... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1875 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1876 | $as_echo_n "(cached) " >&6 |
| 1877 | else |
| 1878 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1879 | /* end confdefs.h. */ |
| 1880 | $4 |
| 1881 | #include <$2> |
| 1882 | _ACEOF |
| 1883 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1884 | eval "$3=yes" |
| 1885 | else |
| 1886 | eval "$3=no" |
| 1887 | fi |
| 1888 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1889 | fi |
| 1890 | eval ac_res=\$$3 |
| 1891 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1892 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1893 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1894 | |
| 1895 | } # ac_fn_c_check_header_compile |
| 1896 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1897 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1898 | # ------------------------------------------- |
| 1899 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1900 | # variable VAR accordingly. |
| 1901 | ac_fn_c_check_type () |
| 1902 | { |
| 1903 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1904 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1905 | $as_echo_n "checking for $2... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1906 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1907 | $as_echo_n "(cached) " >&6 |
| 1908 | else |
| 1909 | eval "$3=no" |
| 1910 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1911 | /* end confdefs.h. */ |
| 1912 | $4 |
| 1913 | int |
| 1914 | main () |
| 1915 | { |
| 1916 | if (sizeof ($2)) |
| 1917 | return 0; |
| 1918 | ; |
| 1919 | return 0; |
| 1920 | } |
| 1921 | _ACEOF |
| 1922 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1923 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1924 | /* end confdefs.h. */ |
| 1925 | $4 |
| 1926 | int |
| 1927 | main () |
| 1928 | { |
| 1929 | if (sizeof (($2))) |
| 1930 | return 0; |
| 1931 | ; |
| 1932 | return 0; |
| 1933 | } |
| 1934 | _ACEOF |
| 1935 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1936 | |
| 1937 | else |
| 1938 | eval "$3=yes" |
| 1939 | fi |
| 1940 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1941 | fi |
| 1942 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1943 | fi |
| 1944 | eval ac_res=\$$3 |
| 1945 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1946 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1947 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1948 | |
| 1949 | } # ac_fn_c_check_type |
| 1950 | |
| 1951 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1952 | # ------------------------------------ |
| 1953 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1954 | # accordingly. |
| 1955 | ac_fn_c_find_uintX_t () |
| 1956 | { |
| 1957 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1959 | $as_echo_n "checking for uint$2_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 1960 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1961 | $as_echo_n "(cached) " >&6 |
| 1962 | else |
| 1963 | eval "$3=no" |
| 1964 | # Order is important - never check a type that is potentially smaller |
| 1965 | # than half of the expected target width. |
| 1966 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1967 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1968 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1969 | /* end confdefs.h. */ |
| 1970 | $ac_includes_default |
| 1971 | int |
| 1972 | main () |
| 1973 | { |
| 1974 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 1975 | test_array [0] = 0; |
| 1976 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1977 | |
| 1978 | ; |
| 1979 | return 0; |
| 1980 | } |
| 1981 | _ACEOF |
| 1982 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1983 | case $ac_type in #( |
| 1984 | uint$2_t) : |
| 1985 | eval "$3=yes" ;; #( |
| 1986 | *) : |
| 1987 | eval "$3=\$ac_type" ;; |
| 1988 | esac |
| 1989 | fi |
| 1990 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 1991 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1992 | |
| 1993 | else |
| 1994 | break |
| 1995 | fi |
| 1996 | done |
| 1997 | fi |
| 1998 | eval ac_res=\$$3 |
| 1999 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2000 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2001 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2002 | |
| 2003 | } # ac_fn_c_find_uintX_t |
| 2004 | |
| 2005 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 2006 | # ----------------------------------- |
| 2007 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 2008 | # accordingly. |
| 2009 | ac_fn_c_find_intX_t () |
| 2010 | { |
| 2011 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2012 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 2013 | $as_echo_n "checking for int$2_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2014 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2015 | $as_echo_n "(cached) " >&6 |
| 2016 | else |
| 2017 | eval "$3=no" |
| 2018 | # Order is important - never check a type that is potentially smaller |
| 2019 | # than half of the expected target width. |
| 2020 | for ac_type in int$2_t 'int' 'long int' \ |
| 2021 | 'long long int' 'short int' 'signed char'; do |
| 2022 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2023 | /* end confdefs.h. */ |
| 2024 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2025 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2026 | int |
| 2027 | main () |
| 2028 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2029 | static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2030 | test_array [0] = 0; |
| 2031 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2032 | |
| 2033 | ; |
| 2034 | return 0; |
| 2035 | } |
| 2036 | _ACEOF |
| 2037 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2038 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2039 | /* end confdefs.h. */ |
| 2040 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2041 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2042 | int |
| 2043 | main () |
| 2044 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2045 | static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2046 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2047 | test_array [0] = 0; |
| 2048 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2049 | |
| 2050 | ; |
| 2051 | return 0; |
| 2052 | } |
| 2053 | _ACEOF |
| 2054 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2055 | |
| 2056 | else |
| 2057 | case $ac_type in #( |
| 2058 | int$2_t) : |
| 2059 | eval "$3=yes" ;; #( |
| 2060 | *) : |
| 2061 | eval "$3=\$ac_type" ;; |
| 2062 | esac |
| 2063 | fi |
| 2064 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2065 | fi |
| 2066 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2067 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2068 | |
| 2069 | else |
| 2070 | break |
| 2071 | fi |
| 2072 | done |
| 2073 | fi |
| 2074 | eval ac_res=\$$3 |
| 2075 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2076 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2077 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2078 | |
| 2079 | } # ac_fn_c_find_intX_t |
| 2080 | |
| 2081 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 2082 | # -------------------------------------------- |
| 2083 | # Tries to find the compile-time value of EXPR in a program that includes |
| 2084 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 2085 | # computed |
| 2086 | ac_fn_c_compute_int () |
| 2087 | { |
| 2088 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2089 | if test "$cross_compiling" = yes; then |
| 2090 | # Depending upon the size, compute the lo and hi bounds. |
| 2091 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2092 | /* end confdefs.h. */ |
| 2093 | $4 |
| 2094 | int |
| 2095 | main () |
| 2096 | { |
| 2097 | static int test_array [1 - 2 * !(($2) >= 0)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2098 | test_array [0] = 0; |
| 2099 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2100 | |
| 2101 | ; |
| 2102 | return 0; |
| 2103 | } |
| 2104 | _ACEOF |
| 2105 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2106 | ac_lo=0 ac_mid=0 |
| 2107 | while :; do |
| 2108 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2109 | /* end confdefs.h. */ |
| 2110 | $4 |
| 2111 | int |
| 2112 | main () |
| 2113 | { |
| 2114 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2115 | test_array [0] = 0; |
| 2116 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2117 | |
| 2118 | ; |
| 2119 | return 0; |
| 2120 | } |
| 2121 | _ACEOF |
| 2122 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2123 | ac_hi=$ac_mid; break |
| 2124 | else |
| 2125 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2126 | if test $ac_lo -le $ac_mid; then |
| 2127 | ac_lo= ac_hi= |
| 2128 | break |
| 2129 | fi |
| 2130 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2131 | fi |
| 2132 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2133 | done |
| 2134 | else |
| 2135 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2136 | /* end confdefs.h. */ |
| 2137 | $4 |
| 2138 | int |
| 2139 | main () |
| 2140 | { |
| 2141 | static int test_array [1 - 2 * !(($2) < 0)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2142 | test_array [0] = 0; |
| 2143 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2144 | |
| 2145 | ; |
| 2146 | return 0; |
| 2147 | } |
| 2148 | _ACEOF |
| 2149 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2150 | ac_hi=-1 ac_mid=-1 |
| 2151 | while :; do |
| 2152 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2153 | /* end confdefs.h. */ |
| 2154 | $4 |
| 2155 | int |
| 2156 | main () |
| 2157 | { |
| 2158 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2159 | test_array [0] = 0; |
| 2160 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2161 | |
| 2162 | ; |
| 2163 | return 0; |
| 2164 | } |
| 2165 | _ACEOF |
| 2166 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2167 | ac_lo=$ac_mid; break |
| 2168 | else |
| 2169 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2170 | if test $ac_mid -le $ac_hi; then |
| 2171 | ac_lo= ac_hi= |
| 2172 | break |
| 2173 | fi |
| 2174 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2175 | fi |
| 2176 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2177 | done |
| 2178 | else |
| 2179 | ac_lo= ac_hi= |
| 2180 | fi |
| 2181 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2182 | fi |
| 2183 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2184 | # Binary search between lo and hi bounds. |
| 2185 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2186 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2187 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2188 | /* end confdefs.h. */ |
| 2189 | $4 |
| 2190 | int |
| 2191 | main () |
| 2192 | { |
| 2193 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2194 | test_array [0] = 0; |
| 2195 | return test_array [0]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2196 | |
| 2197 | ; |
| 2198 | return 0; |
| 2199 | } |
| 2200 | _ACEOF |
| 2201 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2202 | ac_hi=$ac_mid |
| 2203 | else |
| 2204 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2205 | fi |
| 2206 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2207 | done |
| 2208 | case $ac_lo in #(( |
| 2209 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2210 | '') ac_retval=1 ;; |
| 2211 | esac |
| 2212 | else |
| 2213 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2214 | /* end confdefs.h. */ |
| 2215 | $4 |
| 2216 | static long int longval () { return $2; } |
| 2217 | static unsigned long int ulongval () { return $2; } |
| 2218 | #include <stdio.h> |
| 2219 | #include <stdlib.h> |
| 2220 | int |
| 2221 | main () |
| 2222 | { |
| 2223 | |
| 2224 | FILE *f = fopen ("conftest.val", "w"); |
| 2225 | if (! f) |
| 2226 | return 1; |
| 2227 | if (($2) < 0) |
| 2228 | { |
| 2229 | long int i = longval (); |
| 2230 | if (i != ($2)) |
| 2231 | return 1; |
| 2232 | fprintf (f, "%ld", i); |
| 2233 | } |
| 2234 | else |
| 2235 | { |
| 2236 | unsigned long int i = ulongval (); |
| 2237 | if (i != ($2)) |
| 2238 | return 1; |
| 2239 | fprintf (f, "%lu", i); |
| 2240 | } |
| 2241 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2242 | on some platforms. */ |
| 2243 | return ferror (f) || fclose (f) != 0; |
| 2244 | |
| 2245 | ; |
| 2246 | return 0; |
| 2247 | } |
| 2248 | _ACEOF |
| 2249 | if ac_fn_c_try_run "$LINENO"; then : |
| 2250 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2251 | else |
| 2252 | ac_retval=1 |
| 2253 | fi |
| 2254 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2255 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2256 | rm -f conftest.val |
| 2257 | |
| 2258 | fi |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2259 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2260 | as_fn_set_status $ac_retval |
| 2261 | |
| 2262 | } # ac_fn_c_compute_int |
| 2263 | |
| 2264 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2265 | # ---------------------------------- |
| 2266 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2267 | ac_fn_c_check_func () |
| 2268 | { |
| 2269 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2270 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2271 | $as_echo_n "checking for $2... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2272 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2273 | $as_echo_n "(cached) " >&6 |
| 2274 | else |
| 2275 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2276 | /* end confdefs.h. */ |
| 2277 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2278 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2279 | #define $2 innocuous_$2 |
| 2280 | |
| 2281 | /* System header to define __stub macros and hopefully few prototypes, |
| 2282 | which can conflict with char $2 (); below. |
| 2283 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2284 | <limits.h> exists even on freestanding compilers. */ |
| 2285 | |
| 2286 | #ifdef __STDC__ |
| 2287 | # include <limits.h> |
| 2288 | #else |
| 2289 | # include <assert.h> |
| 2290 | #endif |
| 2291 | |
| 2292 | #undef $2 |
| 2293 | |
| 2294 | /* Override any GCC internal prototype to avoid an error. |
| 2295 | Use char because int might match the return type of a GCC |
| 2296 | builtin and then its argument prototype would still apply. */ |
| 2297 | #ifdef __cplusplus |
| 2298 | extern "C" |
| 2299 | #endif |
| 2300 | char $2 (); |
| 2301 | /* The GNU C library defines this for functions which it implements |
| 2302 | to always fail with ENOSYS. Some functions are actually named |
| 2303 | something starting with __ and the normal name is an alias. */ |
| 2304 | #if defined __stub_$2 || defined __stub___$2 |
| 2305 | choke me |
| 2306 | #endif |
| 2307 | |
| 2308 | int |
| 2309 | main () |
| 2310 | { |
| 2311 | return $2 (); |
| 2312 | ; |
| 2313 | return 0; |
| 2314 | } |
| 2315 | _ACEOF |
| 2316 | if ac_fn_c_try_link "$LINENO"; then : |
| 2317 | eval "$3=yes" |
| 2318 | else |
| 2319 | eval "$3=no" |
| 2320 | fi |
| 2321 | rm -f core conftest.err conftest.$ac_objext \ |
| 2322 | conftest$ac_exeext conftest.$ac_ext |
| 2323 | fi |
| 2324 | eval ac_res=\$$3 |
| 2325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2326 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2327 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2328 | |
| 2329 | } # ac_fn_c_check_func |
| 2330 | |
Gregory P. Smith | df300d5 | 2012-01-21 18:20:15 -0800 | [diff] [blame] | 2331 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
| 2332 | # --------------------------------------------- |
| 2333 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR |
| 2334 | # accordingly. |
| 2335 | ac_fn_c_check_decl () |
| 2336 | { |
| 2337 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2338 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
| 2339 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` |
| 2340 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 |
| 2341 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } |
| 2342 | if eval \${$3+:} false; then : |
| 2343 | $as_echo_n "(cached) " >&6 |
| 2344 | else |
| 2345 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2346 | /* end confdefs.h. */ |
| 2347 | $4 |
| 2348 | int |
| 2349 | main () |
| 2350 | { |
| 2351 | #ifndef $as_decl_name |
| 2352 | #ifdef __cplusplus |
| 2353 | (void) $as_decl_use; |
| 2354 | #else |
| 2355 | (void) $as_decl_name; |
| 2356 | #endif |
| 2357 | #endif |
| 2358 | |
| 2359 | ; |
| 2360 | return 0; |
| 2361 | } |
| 2362 | _ACEOF |
| 2363 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2364 | eval "$3=yes" |
| 2365 | else |
| 2366 | eval "$3=no" |
| 2367 | fi |
| 2368 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2369 | fi |
| 2370 | eval ac_res=\$$3 |
| 2371 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2372 | $as_echo "$ac_res" >&6; } |
| 2373 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 2374 | |
| 2375 | } # ac_fn_c_check_decl |
| 2376 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2377 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2378 | # ---------------------------------------------------- |
| 2379 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2380 | # INCLUDES, setting cache variable VAR accordingly. |
| 2381 | ac_fn_c_check_member () |
| 2382 | { |
| 2383 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2384 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2385 | $as_echo_n "checking for $2.$3... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2386 | if eval \${$4+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2387 | $as_echo_n "(cached) " >&6 |
| 2388 | else |
| 2389 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2390 | /* end confdefs.h. */ |
| 2391 | $5 |
| 2392 | int |
| 2393 | main () |
| 2394 | { |
| 2395 | static $2 ac_aggr; |
| 2396 | if (ac_aggr.$3) |
| 2397 | return 0; |
| 2398 | ; |
| 2399 | return 0; |
| 2400 | } |
| 2401 | _ACEOF |
| 2402 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2403 | eval "$4=yes" |
| 2404 | else |
| 2405 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2406 | /* end confdefs.h. */ |
| 2407 | $5 |
| 2408 | int |
| 2409 | main () |
| 2410 | { |
| 2411 | static $2 ac_aggr; |
| 2412 | if (sizeof ac_aggr.$3) |
| 2413 | return 0; |
| 2414 | ; |
| 2415 | return 0; |
| 2416 | } |
| 2417 | _ACEOF |
| 2418 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2419 | eval "$4=yes" |
| 2420 | else |
| 2421 | eval "$4=no" |
| 2422 | fi |
| 2423 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2424 | fi |
| 2425 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2426 | fi |
| 2427 | eval ac_res=\$$4 |
| 2428 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2429 | $as_echo "$ac_res" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2430 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2431 | |
| 2432 | } # ac_fn_c_check_member |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2433 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2434 | This file contains any messages produced by compilers while |
| 2435 | running configure, to aid debugging if configure makes a mistake. |
| 2436 | |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 2437 | It was created by python $as_me 3.5, which was |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 2438 | generated by GNU Autoconf 2.69. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2439 | |
| 2440 | $ $0 $@ |
| 2441 | |
| 2442 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2443 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2444 | { |
| 2445 | cat <<_ASUNAME |
| 2446 | ## --------- ## |
| 2447 | ## Platform. ## |
| 2448 | ## --------- ## |
| 2449 | |
| 2450 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2451 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2452 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2453 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2454 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2455 | |
| 2456 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2457 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2458 | |
| 2459 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2460 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2461 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2462 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2463 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2464 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2465 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2466 | |
| 2467 | _ASUNAME |
| 2468 | |
| 2469 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2470 | for as_dir in $PATH |
| 2471 | do |
| 2472 | IFS=$as_save_IFS |
| 2473 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2474 | $as_echo "PATH: $as_dir" |
| 2475 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2476 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2477 | |
| 2478 | } >&5 |
| 2479 | |
| 2480 | cat >&5 <<_ACEOF |
| 2481 | |
| 2482 | |
| 2483 | ## ----------- ## |
| 2484 | ## Core tests. ## |
| 2485 | ## ----------- ## |
| 2486 | |
| 2487 | _ACEOF |
| 2488 | |
| 2489 | |
| 2490 | # Keep a trace of the command line. |
| 2491 | # Strip out --no-create and --no-recursion so they do not pile up. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2492 | # Strip out --silent because we don't want to record it for future runs. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2493 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2494 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2495 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2496 | ac_configure_args0= |
| 2497 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2498 | ac_must_keep_next=false |
| 2499 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2500 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2501 | for ac_arg |
| 2502 | do |
| 2503 | case $ac_arg in |
| 2504 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2505 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2506 | | -silent | --silent | --silen | --sile | --sil) |
| 2507 | continue ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2508 | *\'*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2509 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2510 | esac |
| 2511 | case $ac_pass in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2512 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2513 | 2) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2514 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2515 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2516 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2517 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2518 | case $ac_arg in |
| 2519 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2520 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2521 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2522 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2523 | case "$ac_configure_args0 " in |
| 2524 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2525 | esac |
| 2526 | ;; |
| 2527 | -* ) ac_must_keep_next=true ;; |
| 2528 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2529 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2530 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2531 | ;; |
| 2532 | esac |
| 2533 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2534 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2535 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2536 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2537 | |
| 2538 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2539 | # config.log. We remove comments because anyway the quotes in there |
| 2540 | # would cause problems or look ugly. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2541 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2542 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2543 | trap 'exit_status=$? |
| 2544 | # Save into config.log some information that might help in debugging. |
| 2545 | { |
| 2546 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2547 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2548 | $as_echo "## ---------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2549 | ## Cache variables. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2550 | ## ---------------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2551 | echo |
| 2552 | # The following way of writing the cache mishandles newlines in values, |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2553 | ( |
| 2554 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2555 | eval ac_val=\$$ac_var |
| 2556 | case $ac_val in #( |
| 2557 | *${as_nl}*) |
| 2558 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2559 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2560 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2561 | esac |
| 2562 | case $ac_var in #( |
| 2563 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2564 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2565 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2566 | esac ;; |
| 2567 | esac |
| 2568 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2569 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2570 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2571 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2572 | sed -n \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2573 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2574 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2575 | ;; #( |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2576 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2577 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2578 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2579 | esac | |
| 2580 | sort |
| 2581 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2582 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2583 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2584 | $as_echo "## ----------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2585 | ## Output variables. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2586 | ## ----------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2587 | echo |
| 2588 | for ac_var in $ac_subst_vars |
| 2589 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2590 | eval ac_val=\$$ac_var |
| 2591 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2592 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2593 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2594 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2595 | done | sort |
| 2596 | echo |
| 2597 | |
| 2598 | if test -n "$ac_subst_files"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2599 | $as_echo "## ------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2600 | ## File substitutions. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2601 | ## ------------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2602 | echo |
| 2603 | for ac_var in $ac_subst_files |
| 2604 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2605 | eval ac_val=\$$ac_var |
| 2606 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2607 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2608 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2609 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2610 | done | sort |
| 2611 | echo |
| 2612 | fi |
| 2613 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2614 | if test -s confdefs.h; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2615 | $as_echo "## ----------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2616 | ## confdefs.h. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2617 | ## ----------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2618 | echo |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2619 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2620 | echo |
| 2621 | fi |
| 2622 | test "$ac_signal" != 0 && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2623 | $as_echo "$as_me: caught signal $ac_signal" |
| 2624 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2625 | } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2626 | rm -f core *.core core.conftest.* && |
| 2627 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2628 | exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2629 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2630 | for ac_signal in 1 2 13 15; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2631 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2632 | done |
| 2633 | ac_signal=0 |
| 2634 | |
| 2635 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2636 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2637 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2638 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2639 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2640 | # Predefined preprocessor variables. |
| 2641 | |
| 2642 | cat >>confdefs.h <<_ACEOF |
| 2643 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2644 | _ACEOF |
| 2645 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2646 | cat >>confdefs.h <<_ACEOF |
| 2647 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2648 | _ACEOF |
| 2649 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2650 | cat >>confdefs.h <<_ACEOF |
| 2651 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2652 | _ACEOF |
| 2653 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2654 | cat >>confdefs.h <<_ACEOF |
| 2655 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2656 | _ACEOF |
| 2657 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2658 | cat >>confdefs.h <<_ACEOF |
| 2659 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2660 | _ACEOF |
| 2661 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2662 | cat >>confdefs.h <<_ACEOF |
| 2663 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2664 | _ACEOF |
| 2665 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2666 | |
| 2667 | # Let the site file select an alternate cache file if it wants to. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2668 | # Prefer an explicitly selected file to automatically selected ones. |
| 2669 | ac_site_file1=NONE |
| 2670 | ac_site_file2=NONE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2671 | if test -n "$CONFIG_SITE"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2672 | # We do not want a PATH search for config.site. |
| 2673 | case $CONFIG_SITE in #(( |
| 2674 | -*) ac_site_file1=./$CONFIG_SITE;; |
| 2675 | */*) ac_site_file1=$CONFIG_SITE;; |
| 2676 | *) ac_site_file1=./$CONFIG_SITE;; |
| 2677 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2678 | elif test "x$prefix" != xNONE; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2679 | ac_site_file1=$prefix/share/config.site |
| 2680 | ac_site_file2=$prefix/etc/config.site |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2681 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2682 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2683 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2684 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2685 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2686 | do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2687 | test "x$ac_site_file" = xNONE && continue |
| 2688 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2689 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2690 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2691 | sed 's/^/| /' "$ac_site_file" >&5 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2692 | . "$ac_site_file" \ |
| 2693 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2694 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2695 | as_fn_error $? "failed to load site script $ac_site_file |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2696 | See \`config.log' for more details" "$LINENO" 5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2697 | fi |
| 2698 | done |
| 2699 | |
| 2700 | if test -r "$cache_file"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2701 | # Some versions of bash will fail to source /dev/null (special files |
| 2702 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2703 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2704 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2705 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2706 | case $cache_file in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2707 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2708 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2709 | esac |
| 2710 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2711 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2712 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2713 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2714 | >$cache_file |
| 2715 | fi |
| 2716 | |
| 2717 | # Check that the precious variables saved in the cache have kept the same |
| 2718 | # value. |
| 2719 | ac_cache_corrupted=false |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2720 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2721 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2722 | eval ac_new_set=\$ac_env_${ac_var}_set |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2723 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2724 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2725 | case $ac_old_set,$ac_new_set in |
| 2726 | set,) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2727 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2728 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2729 | ac_cache_corrupted=: ;; |
| 2730 | ,set) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2731 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2732 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2733 | ac_cache_corrupted=: ;; |
| 2734 | ,);; |
| 2735 | *) |
| 2736 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2737 | # differences in whitespace do not lead to failure. |
| 2738 | ac_old_val_w=`echo x $ac_old_val` |
| 2739 | ac_new_val_w=`echo x $ac_new_val` |
| 2740 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2741 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2742 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2743 | ac_cache_corrupted=: |
| 2744 | else |
| 2745 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2746 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2747 | eval $ac_var=\$ac_old_val |
| 2748 | fi |
| 2749 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2750 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2751 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2752 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2753 | fi;; |
| 2754 | esac |
| 2755 | # Pass precious variables to config.status. |
| 2756 | if test "$ac_new_set" = set; then |
| 2757 | case $ac_new_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2758 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2759 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2760 | esac |
| 2761 | case " $ac_configure_args " in |
| 2762 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2763 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2764 | esac |
| 2765 | fi |
| 2766 | done |
| 2767 | if $ac_cache_corrupted; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2768 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2769 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2770 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2771 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 2772 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2773 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2774 | ## -------------------- ## |
| 2775 | ## Main body of script. ## |
| 2776 | ## -------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2777 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2778 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2779 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2780 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2781 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2782 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2783 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2784 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2785 | |
Trent Nelson | 4d4ec65 | 2012-10-16 08:51:24 -0400 | [diff] [blame] | 2786 | |
Trent Nelson | 5595ab5 | 2012-10-17 04:47:31 -0400 | [diff] [blame] | 2787 | if test "$abs_srcdir" != "$abs_builddir"; then |
Trent Nelson | 4d4ec65 | 2012-10-16 08:51:24 -0400 | [diff] [blame] | 2788 | # If we're building out-of-tree, we need to make sure the following |
| 2789 | # resources get picked up before their $srcdir counterparts. |
| 2790 | # Objects/ -> typeslots.inc |
| 2791 | # Include/ -> Python-ast.h, graminit.h |
| 2792 | # Python/ -> importlib.h |
| 2793 | # (A side effect of this is that these resources will automatically be |
| 2794 | # regenerated when building out-of-tree, regardless of whether or not |
| 2795 | # the $srcdir counterpart is up-to-date. This is an acceptable trade |
| 2796 | # off.) |
| 2797 | BASECPPFLAGS="-IObjects -IInclude -IPython" |
| 2798 | else |
| 2799 | BASECPPFLAGS="" |
| 2800 | fi |
| 2801 | |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 2802 | |
| 2803 | |
| 2804 | |
| 2805 | |
Antoine Pitrou | d3b2aef | 2011-07-27 01:22:41 +0200 | [diff] [blame] | 2806 | if test -e $srcdir/.hg/dirstate |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 2807 | then |
| 2808 | # Extract the first word of "hg", so it can be a program name with args. |
| 2809 | set dummy hg; ac_word=$2 |
| 2810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2811 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 2812 | if ${ac_cv_prog_HAS_HG+:} false; then : |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 2813 | $as_echo_n "(cached) " >&6 |
| 2814 | else |
| 2815 | if test -n "$HAS_HG"; then |
| 2816 | ac_cv_prog_HAS_HG="$HAS_HG" # Let the user override the test. |
| 2817 | else |
| 2818 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2819 | for as_dir in $PATH |
| 2820 | do |
| 2821 | IFS=$as_save_IFS |
| 2822 | test -z "$as_dir" && as_dir=. |
| 2823 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 2824 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 2825 | ac_cv_prog_HAS_HG="found" |
| 2826 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 2827 | break 2 |
| 2828 | fi |
| 2829 | done |
| 2830 | done |
| 2831 | IFS=$as_save_IFS |
| 2832 | |
| 2833 | test -z "$ac_cv_prog_HAS_HG" && ac_cv_prog_HAS_HG="not-found" |
| 2834 | fi |
| 2835 | fi |
| 2836 | HAS_HG=$ac_cv_prog_HAS_HG |
| 2837 | if test -n "$HAS_HG"; then |
| 2838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAS_HG" >&5 |
| 2839 | $as_echo "$HAS_HG" >&6; } |
| 2840 | else |
| 2841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2842 | $as_echo "no" >&6; } |
| 2843 | fi |
| 2844 | |
| 2845 | |
| 2846 | else |
| 2847 | HAS_HG=no-repository |
| 2848 | fi |
| 2849 | if test $HAS_HG = found |
| 2850 | then |
| 2851 | HGVERSION="hg id -i \$(srcdir)" |
| 2852 | HGTAG="hg id -t \$(srcdir)" |
| 2853 | HGBRANCH="hg id -b \$(srcdir)" |
| 2854 | else |
| 2855 | HGVERSION="" |
| 2856 | HGTAG="" |
| 2857 | HGBRANCH="" |
| 2858 | fi |
| 2859 | |
| 2860 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2861 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2862 | |
| 2863 | |
Matthias Klose | ca2f6ec | 2012-03-15 21:30:11 +0100 | [diff] [blame] | 2864 | ac_aux_dir= |
| 2865 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
| 2866 | if test -f "$ac_dir/install-sh"; then |
| 2867 | ac_aux_dir=$ac_dir |
| 2868 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 2869 | break |
| 2870 | elif test -f "$ac_dir/install.sh"; then |
| 2871 | ac_aux_dir=$ac_dir |
| 2872 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 2873 | break |
| 2874 | elif test -f "$ac_dir/shtool"; then |
| 2875 | ac_aux_dir=$ac_dir |
| 2876 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 2877 | break |
| 2878 | fi |
| 2879 | done |
| 2880 | if test -z "$ac_aux_dir"; then |
| 2881 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 |
| 2882 | fi |
| 2883 | |
| 2884 | # These three variables are undocumented and unsupported, |
| 2885 | # and are intended to be withdrawn in a future Autoconf release. |
| 2886 | # They can cause serious problems if a builder's source tree is in a directory |
| 2887 | # whose full name contains unusual characters. |
| 2888 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 2889 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 2890 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 2891 | |
| 2892 | |
| 2893 | # Make sure we can run config.sub. |
| 2894 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || |
| 2895 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 |
| 2896 | |
| 2897 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 |
| 2898 | $as_echo_n "checking build system type... " >&6; } |
| 2899 | if ${ac_cv_build+:} false; then : |
| 2900 | $as_echo_n "(cached) " >&6 |
| 2901 | else |
| 2902 | ac_build_alias=$build_alias |
| 2903 | test "x$ac_build_alias" = x && |
| 2904 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` |
| 2905 | test "x$ac_build_alias" = x && |
| 2906 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 |
| 2907 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || |
| 2908 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 |
| 2909 | |
| 2910 | fi |
| 2911 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 |
| 2912 | $as_echo "$ac_cv_build" >&6; } |
| 2913 | case $ac_cv_build in |
| 2914 | *-*-*) ;; |
| 2915 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; |
| 2916 | esac |
| 2917 | build=$ac_cv_build |
| 2918 | ac_save_IFS=$IFS; IFS='-' |
| 2919 | set x $ac_cv_build |
| 2920 | shift |
| 2921 | build_cpu=$1 |
| 2922 | build_vendor=$2 |
| 2923 | shift; shift |
| 2924 | # Remember, the first character of IFS is used to create $*, |
| 2925 | # except with old shells: |
| 2926 | build_os=$* |
| 2927 | IFS=$ac_save_IFS |
| 2928 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac |
| 2929 | |
| 2930 | |
| 2931 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 |
| 2932 | $as_echo_n "checking host system type... " >&6; } |
| 2933 | if ${ac_cv_host+:} false; then : |
| 2934 | $as_echo_n "(cached) " >&6 |
| 2935 | else |
| 2936 | if test "x$host_alias" = x; then |
| 2937 | ac_cv_host=$ac_cv_build |
| 2938 | else |
| 2939 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || |
| 2940 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 |
| 2941 | fi |
| 2942 | |
| 2943 | fi |
| 2944 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
| 2945 | $as_echo "$ac_cv_host" >&6; } |
| 2946 | case $ac_cv_host in |
| 2947 | *-*-*) ;; |
| 2948 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; |
| 2949 | esac |
| 2950 | host=$ac_cv_host |
| 2951 | ac_save_IFS=$IFS; IFS='-' |
| 2952 | set x $ac_cv_host |
| 2953 | shift |
| 2954 | host_cpu=$1 |
| 2955 | host_vendor=$2 |
| 2956 | shift; shift |
| 2957 | # Remember, the first character of IFS is used to create $*, |
| 2958 | # except with old shells: |
| 2959 | host_os=$* |
| 2960 | IFS=$ac_save_IFS |
| 2961 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac |
| 2962 | |
| 2963 | |
| 2964 | |
doko@python.org | a10e4a9 | 2013-01-25 18:45:12 +0100 | [diff] [blame] | 2965 | |
| 2966 | |
Ned Deily | fcbc246 | 2014-08-22 13:32:49 -0700 | [diff] [blame] | 2967 | # pybuilddir.txt will be created by --generate-posix-vars in the Makefile |
| 2968 | rm -f pybuilddir.txt |
| 2969 | |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 2970 | if test "$cross_compiling" = yes; then |
| 2971 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for python interpreter for cross build" >&5 |
| 2972 | $as_echo_n "checking for python interpreter for cross build... " >&6; } |
| 2973 | if test -z "$PYTHON_FOR_BUILD"; then |
| 2974 | for interp in python$PACKAGE_VERSION python3 python; do |
| 2975 | which $interp >/dev/null 2>&1 || continue |
| 2976 | if $interp -c 'import sys;sys.exit(not sys.version_info[:2] >= (3,3))'; then |
| 2977 | break |
| 2978 | fi |
| 2979 | interp= |
| 2980 | done |
| 2981 | if test x$interp = x; then |
| 2982 | as_fn_error $? "python$PACKAGE_VERSION interpreter not found" "$LINENO" 5 |
| 2983 | fi |
| 2984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $interp" >&5 |
| 2985 | $as_echo "$interp" >&6; } |
doko@python.org | 244b687 | 2013-01-26 12:08:25 +0100 | [diff] [blame] | 2986 | 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:$(srcdir)/Lib/$(PLATDIR) '$interp |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 2987 | fi |
Christian Heimes | 954ac03 | 2012-12-12 13:10:21 +0100 | [diff] [blame] | 2988 | elif test "$cross_compiling" = maybe; then |
| 2989 | as_fn_error $? "Cross compiling required --host=HOST-TUPLE and --build=ARCH" "$LINENO" 5 |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 2990 | else |
| 2991 | PYTHON_FOR_BUILD='./$(BUILDPYTHON) -E' |
| 2992 | fi |
| 2993 | |
| 2994 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2995 | |
Benjamin Peterson | d23f822 | 2009-04-05 19:13:16 +0000 | [diff] [blame] | 2996 | if test "$prefix" != "/"; then |
| 2997 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2998 | fi |
| 2999 | |
| 3000 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3001 | |
| 3002 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 3003 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 3004 | # with other autoconf-based packages that include Python.h |
| 3005 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 3006 | rm confdefs.h |
| 3007 | mv confdefs.h.new confdefs.h |
| 3008 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 3009 | |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 3010 | VERSION=3.5 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 3011 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3012 | # Version number of Python's own shared library file. |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 3013 | |
| 3014 | SOVERSION=1.0 |
| 3015 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 3016 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 3017 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 3018 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3019 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 3020 | |
| 3021 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 3022 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 3023 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 3024 | # them. |
| 3025 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3026 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 3027 | |
| 3028 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 3029 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 3030 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 3031 | # them. |
| 3032 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3033 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 3034 | |
| 3035 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 3036 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 3037 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 3038 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3039 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 3040 | |
| 3041 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3042 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 3043 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 3044 | # them. |
| 3045 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3046 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3047 | |
| 3048 | |
| 3049 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3050 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 3051 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 3052 | # Arguments passed to configure. |
| 3053 | |
| 3054 | CONFIG_ARGS="$ac_configure_args" |
| 3055 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3056 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 3057 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3058 | # Check whether --enable-universalsdk was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3059 | if test "${enable_universalsdk+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3060 | enableval=$enable_universalsdk; |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3061 | case $enableval in |
| 3062 | yes) |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3063 | # Locate the best usable SDK, see Mac/README.txt for more |
| 3064 | # information |
| 3065 | enableval="`/usr/bin/xcodebuild -version -sdk macosx Path 2>/dev/null`" |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 3066 | if ! ( echo $enableval | grep -E '\.sdk' 1>/dev/null ) |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3067 | then |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3068 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
| 3069 | if test ! -d "${enableval}" |
| 3070 | then |
| 3071 | enableval=/ |
| 3072 | fi |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3073 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3074 | ;; |
| 3075 | esac |
| 3076 | case $enableval in |
| 3077 | no) |
| 3078 | UNIVERSALSDK= |
| 3079 | enable_universalsdk= |
| 3080 | ;; |
| 3081 | *) |
| 3082 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3083 | if test ! -d "${UNIVERSALSDK}" |
| 3084 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 3085 | as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3086 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3087 | ;; |
| 3088 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3089 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3090 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3091 | else |
| 3092 | |
| 3093 | UNIVERSALSDK= |
| 3094 | enable_universalsdk= |
| 3095 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3096 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3097 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3098 | if test -n "${UNIVERSALSDK}" |
| 3099 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 3101 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3102 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3103 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3104 | $as_echo "no" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 3105 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3106 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3107 | |
Benjamin Peterson | 6794aa3 | 2008-07-16 20:33:37 +0000 | [diff] [blame] | 3108 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 3109 | ARCH_RUN_32BIT="" |
Benjamin Peterson | 6794aa3 | 2008-07-16 20:33:37 +0000 | [diff] [blame] | 3110 | |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3111 | # For backward compatibility reasons we prefer to select '32-bit' if available, |
| 3112 | # otherwise use 'intel' |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3113 | UNIVERSAL_ARCHS="32-bit" |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3114 | if test "`uname -s`" = "Darwin" |
| 3115 | then |
| 3116 | if test -n "${UNIVERSALSDK}" |
| 3117 | then |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 3118 | if test -z "`/usr/bin/file -L "${UNIVERSALSDK}/usr/lib/libSystem.dylib" | grep ppc`" |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3119 | then |
| 3120 | UNIVERSAL_ARCHS="intel" |
| 3121 | fi |
| 3122 | fi |
| 3123 | fi |
| 3124 | |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 3125 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3126 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 3127 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3128 | |
| 3129 | # Check whether --with-universal-archs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3130 | if test "${with_universal_archs+set}" = set; then : |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3131 | withval=$with_universal_archs; |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3132 | UNIVERSAL_ARCHS="$withval" |
| 3133 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3134 | fi |
| 3135 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 3136 | if test -n "${UNIVERSALSDK}" |
| 3137 | then |
| 3138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSAL_ARCHS}" >&5 |
| 3139 | $as_echo "${UNIVERSAL_ARCHS}" >&6; } |
| 3140 | else |
| 3141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3142 | $as_echo "no" >&6; } |
| 3143 | fi |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3144 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3145 | |
| 3146 | # Check whether --with-framework-name was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3147 | if test "${with_framework_name+set}" = set; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3148 | withval=$with_framework_name; |
| 3149 | PYTHONFRAMEWORK=${withval} |
| 3150 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 3151 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 3152 | |
| 3153 | else |
| 3154 | |
| 3155 | PYTHONFRAMEWORK=Python |
| 3156 | PYTHONFRAMEWORKDIR=Python.framework |
| 3157 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 3158 | |
| 3159 | fi |
| 3160 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3161 | # Check whether --enable-framework was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3162 | if test "${enable_framework+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3163 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3164 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3165 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3166 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 3167 | esac |
| 3168 | case $enableval in |
| 3169 | no) |
| 3170 | PYTHONFRAMEWORK= |
| 3171 | PYTHONFRAMEWORKDIR=no-framework |
| 3172 | PYTHONFRAMEWORKPREFIX= |
| 3173 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3174 | FRAMEWORKINSTALLFIRST= |
| 3175 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3176 | FRAMEWORKALTINSTALLFIRST= |
| 3177 | FRAMEWORKALTINSTALLLAST= |
Ned Deily | b8f944f | 2013-11-21 22:42:25 -0800 | [diff] [blame] | 3178 | FRAMEWORKPYTHONW= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3179 | if test "x${prefix}" = "xNONE"; then |
| 3180 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 3181 | else |
| 3182 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 3183 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 3184 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3185 | ;; |
| 3186 | *) |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3187 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 3188 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3189 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | f6ccbf6 | 2009-06-02 10:55:56 +0000 | [diff] [blame] | 3190 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure " |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 3191 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 3192 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ned Deily | b8f944f | 2013-11-21 22:42:25 -0800 | [diff] [blame] | 3193 | FRAMEWORKPYTHONW="frameworkpythonw" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3194 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3195 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3196 | if test "x${prefix}" = "xNONE" ; then |
| 3197 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3198 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3199 | else |
| 3200 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 3201 | fi |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3202 | |
| 3203 | case "${enableval}" in |
| 3204 | /System*) |
| 3205 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 3206 | if test "${prefix}" = "NONE" ; then |
| 3207 | # See below |
| 3208 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 3209 | fi |
| 3210 | ;; |
| 3211 | |
| 3212 | /Library*) |
| 3213 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 3214 | ;; |
| 3215 | |
| 3216 | */Library/Frameworks) |
| 3217 | MDIR="`dirname "${enableval}"`" |
| 3218 | MDIR="`dirname "${MDIR}"`" |
| 3219 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 3220 | |
| 3221 | if test "${prefix}" = "NONE"; then |
| 3222 | # User hasn't specified the |
| 3223 | # --prefix option, but wants to install |
| 3224 | # the framework in a non-default location, |
| 3225 | # ensure that the compatibility links get |
| 3226 | # installed relative to that prefix as well |
| 3227 | # instead of in /usr/local. |
| 3228 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 3229 | fi |
| 3230 | ;; |
| 3231 | |
| 3232 | *) |
| 3233 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 3234 | ;; |
| 3235 | esac |
| 3236 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 3237 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3238 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3239 | # Add files for Mac specific code to the list of output |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3240 | # files: |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3241 | ac_config_files="$ac_config_files Mac/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3242 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3243 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3244 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3245 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 3246 | |
| 3247 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 3248 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3249 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3250 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3251 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3252 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3253 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 3254 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3255 | PYTHONFRAMEWORKPREFIX= |
| 3256 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3257 | FRAMEWORKINSTALLFIRST= |
| 3258 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3259 | FRAMEWORKALTINSTALLFIRST= |
| 3260 | FRAMEWORKALTINSTALLLAST= |
Ned Deily | b8f944f | 2013-11-21 22:42:25 -0800 | [diff] [blame] | 3261 | FRAMEWORKPYTHONW= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3262 | if test "x${prefix}" = "xNONE" ; then |
| 3263 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 3264 | else |
| 3265 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 3266 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3267 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3268 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3269 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3270 | fi |
| 3271 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3272 | |
| 3273 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3274 | |
| 3275 | |
| 3276 | |
| 3277 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3278 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3279 | |
| 3280 | |
| 3281 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3282 | |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3283 | |
Ned Deily | b8f944f | 2013-11-21 22:42:25 -0800 | [diff] [blame] | 3284 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3285 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 2b8733f | 2010-04-25 18:34:36 +0000 | [diff] [blame] | 3286 | ## AS_HELP_STRING([--with-dyld], |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 3287 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3288 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3289 | # Set name for machine-dependent library files |
| 3290 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3291 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 3292 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3293 | if test -z "$MACHDEP" |
| 3294 | then |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 3295 | # avoid using uname for cross builds |
| 3296 | if test "$cross_compiling" = yes; then |
doko@python.org | 44bbbda | 2013-01-25 14:44:00 +0100 | [diff] [blame] | 3297 | # ac_sys_system and ac_sys_release are used for setting |
| 3298 | # a lot of different things including 'define_xopen_source' |
| 3299 | # in the case statement below. |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 3300 | case "$host" in |
| 3301 | *-*-linux*) |
| 3302 | ac_sys_system=Linux |
| 3303 | ;; |
| 3304 | *-*-cygwin*) |
| 3305 | ac_sys_system=Cygwin |
| 3306 | ;; |
| 3307 | *) |
| 3308 | # for now, limit cross builds to known configurations |
| 3309 | MACHDEP="unknown" |
| 3310 | as_fn_error $? "cross build not supported for $host" "$LINENO" 5 |
| 3311 | esac |
| 3312 | ac_sys_release= |
| 3313 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3314 | ac_sys_system=`uname -s` |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 3315 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 3316 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3317 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3318 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3319 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3320 | fi |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 3321 | fi |
| 3322 | ac_md_system=`echo $ac_sys_system | |
| 3323 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 3324 | ac_md_release=`echo $ac_sys_release | |
| 3325 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
| 3326 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3327 | |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 3328 | case $MACHDEP in |
Victor Stinner | 7209ff2 | 2011-08-21 00:00:16 +0200 | [diff] [blame] | 3329 | linux*) MACHDEP="linux";; |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 3330 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 3331 | darwin*) MACHDEP="darwin";; |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 3332 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 3333 | '') MACHDEP="unknown";; |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 3334 | esac |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3335 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3336 | |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 3337 | |
| 3338 | if test "$cross_compiling" = yes; then |
| 3339 | case "$host" in |
| 3340 | *-*-linux*) |
| 3341 | case "$host_cpu" in |
| 3342 | arm*) |
| 3343 | _host_cpu=arm |
| 3344 | ;; |
| 3345 | *) |
| 3346 | _host_cpu=$host_cpu |
| 3347 | esac |
| 3348 | ;; |
| 3349 | *-*-cygwin*) |
| 3350 | _host_cpu= |
| 3351 | ;; |
| 3352 | *) |
| 3353 | # for now, limit cross builds to known configurations |
| 3354 | MACHDEP="unknown" |
| 3355 | as_fn_error $? "cross build not supported for $host" "$LINENO" 5 |
| 3356 | esac |
| 3357 | _PYTHON_HOST_PLATFORM="$MACHDEP${_host_cpu:+-$_host_cpu}" |
| 3358 | fi |
| 3359 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3360 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 3361 | # disable features if it is defined, without any means to access these |
| 3362 | # features as extensions. For these systems, we skip the definition of |
| 3363 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 3364 | # some feature, make sure there is no alternative way to access this |
| 3365 | # feature. Also, when using wildcards, make sure you have verified the |
| 3366 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 3367 | # wildcard, and that the wildcard does not include future systems |
| 3368 | # (which may remove their limitations). |
| 3369 | case $ac_sys_system/$ac_sys_release in |
| 3370 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 3371 | # even though select is a POSIX function. Reported by J. Ribbens. |
Martin v. Löwis | 76bafc6 | 2003-10-03 13:47:44 +0000 | [diff] [blame] | 3372 | # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish. |
Martin v. Löwis | 19ed3c8 | 2010-02-15 21:45:06 +0000 | [diff] [blame] | 3373 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 3374 | # OpenBSD 4.6, but is fixed in 4.7. |
Charles-François Natali | 54ef40b | 2011-07-22 23:52:02 +0200 | [diff] [blame] | 3375 | OpenBSD/2.* | OpenBSD/3.* | OpenBSD/4.[0123456]) |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3376 | define_xopen_source=no |
| 3377 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3378 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3379 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3380 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3381 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3382 | |
| 3383 | ;; |
Charles-François Natali | 54ef40b | 2011-07-22 23:52:02 +0200 | [diff] [blame] | 3384 | OpenBSD/*) |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3385 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3386 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3387 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3388 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3389 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3390 | |
| 3391 | ;; |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 3392 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3393 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3394 | # Marc Recht |
Benjamin Peterson | f608c61 | 2008-11-16 18:33:53 +0000 | [diff] [blame] | 3395 | NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S]) |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3396 | define_xopen_source=no;; |
Martin v. Löwis | 1a41576 | 2010-05-28 15:44:20 +0000 | [diff] [blame] | 3397 | # From the perspective of Solaris, _XOPEN_SOURCE is not so much a |
| 3398 | # request to enable features supported by the standard as a request |
| 3399 | # to disable features not supported by the standard. The best way |
| 3400 | # for Python to use Solaris is simply to leave _XOPEN_SOURCE out |
| 3401 | # entirely and define __EXTENSIONS__ instead. |
| 3402 | SunOS/*) |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3403 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3404 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3405 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3406 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3407 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3408 | define_xopen_source=no;; |
| 3409 | # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE, |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3410 | # but used in struct sockaddr.sa_family. Reported by Tim Rice. |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3411 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3412 | define_xopen_source=no;; |
Martin v. Löwis | b37509b | 2008-11-04 20:45:29 +0000 | [diff] [blame] | 3413 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3414 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3415 | FreeBSD/4.*) |
| 3416 | define_xopen_source=no;; |
| 3417 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3418 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3419 | # identifies itself as Darwin/7.* |
| 3420 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3421 | # disables platform specific features beyond repair. |
| 3422 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3423 | # has no effect, don't bother defining them |
| 3424 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3425 | define_xopen_source=no;; |
Ronald Oussoren | 92fb941 | 2010-03-09 06:40:19 +0000 | [diff] [blame] | 3426 | Darwin/1[0-9].*) |
Ronald Oussoren | b8f11a6 | 2010-03-08 07:02:03 +0000 | [diff] [blame] | 3427 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3428 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3429 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3430 | # or has another value. By not (re)defining it, the defaults come in place. |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 3431 | AIX/4) |
| 3432 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3433 | AIX/5) |
| 3434 | if test `uname -r` -eq 1; then |
| 3435 | define_xopen_source=no |
| 3436 | fi |
| 3437 | ;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 3438 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3439 | # defining NI_NUMERICHOST. |
| 3440 | QNX/6.3.2) |
| 3441 | define_xopen_source=no |
| 3442 | ;; |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3443 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3444 | esac |
| 3445 | |
| 3446 | if test $define_xopen_source = yes |
| 3447 | then |
Victor Stinner | 14d098d | 2011-09-07 22:29:43 +0200 | [diff] [blame] | 3448 | # X/Open 7, incorporating POSIX.1-2008 |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3449 | |
Victor Stinner | 14d098d | 2011-09-07 22:29:43 +0200 | [diff] [blame] | 3450 | $as_echo "#define _XOPEN_SOURCE 700" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3451 | |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3452 | |
| 3453 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3454 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3455 | # several APIs are not declared. Since this is also needed in some |
| 3456 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3457 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3458 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3459 | |
| 3460 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3461 | |
Victor Stinner | d169fdc | 2011-09-08 00:56:17 +0200 | [diff] [blame] | 3462 | $as_echo "#define _POSIX_C_SOURCE 200809L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3463 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3464 | fi |
| 3465 | |
Christian Heimes | 647cd87 | 2013-12-07 23:39:33 +0100 | [diff] [blame] | 3466 | # On HP-UX mbstate_t requires _INCLUDE__STDC_A1_SOURCE |
| 3467 | case $ac_sys_system in |
Christian Heimes | b02bcae | 2013-12-08 15:21:08 +0100 | [diff] [blame] | 3468 | hp*|HP*) |
| 3469 | define_stdc_a1=yes;; |
| 3470 | *) |
| 3471 | define_stdc_a1=no;; |
| 3472 | esac |
| 3473 | |
| 3474 | if test $define_stdc_a1 = yes |
| 3475 | then |
Christian Heimes | 647cd87 | 2013-12-07 23:39:33 +0100 | [diff] [blame] | 3476 | |
| 3477 | $as_echo "#define _INCLUDE__STDC_A1_SOURCE 1" >>confdefs.h |
| 3478 | |
Christian Heimes | b02bcae | 2013-12-08 15:21:08 +0100 | [diff] [blame] | 3479 | fi |
Christian Heimes | 647cd87 | 2013-12-07 23:39:33 +0100 | [diff] [blame] | 3480 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3481 | # |
| 3482 | # SGI compilers allow the specification of the both the ABI and the |
| 3483 | # ISA on the command line. Depending on the values of these switches, |
| 3484 | # different and often incompatable code will be generated. |
| 3485 | # |
| 3486 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3487 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3488 | # variable is also adjusted. |
| 3489 | # |
| 3490 | |
| 3491 | if test ! -z "$SGI_ABI" |
| 3492 | then |
| 3493 | CC="cc $SGI_ABI" |
| 3494 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3495 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3496 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3497 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3498 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3499 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3500 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3501 | # it may influence the way we can build extensions, so distutils |
| 3502 | # needs to check it |
| 3503 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3504 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3505 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3506 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3507 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3508 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3509 | |
| 3510 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3511 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3512 | # just to get things to compile and link. Users are free to override OPT |
| 3513 | # when running configure or make. The build should not break if they do. |
| 3514 | # BASECFLAGS should generally not be messed with, however. |
| 3515 | |
| 3516 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3517 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3518 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3519 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3520 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3521 | # Check whether --with-gcc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3522 | if test "${with_gcc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3523 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3524 | case $withval in |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 3525 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3526 | without_gcc=yes;; |
| 3527 | yes) CC=gcc |
| 3528 | without_gcc=no;; |
| 3529 | *) CC=$withval |
| 3530 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3531 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3532 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3533 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3534 | case $ac_sys_system in |
Antoine Pitrou | f6350d2 | 2010-09-21 15:19:14 +0000 | [diff] [blame] | 3535 | AIX*) CC=${CC:-xlc_r} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3536 | without_gcc=;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3537 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3538 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3539 | fi |
| 3540 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3541 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3542 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3543 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3544 | # If the user switches compilers, we can't believe the cache |
| 3545 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3546 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 3547 | as_fn_error $? "cached CC is different -- throw away $cache_file |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3548 | (it is also a good idea to do 'make clean' before compiling)" "$LINENO" 5 |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3549 | fi |
| 3550 | |
Jeffrey Yasskin | d4fcdb1 | 2010-07-09 16:30:58 +0000 | [diff] [blame] | 3551 | # Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2 |
| 3552 | # when the compiler supports them, but we don't always want -O2, and |
| 3553 | # we set -g later. |
| 3554 | if test -z "$CFLAGS"; then |
| 3555 | CFLAGS= |
| 3556 | fi |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 3557 | |
| 3558 | if test "$ac_sys_system" = "Darwin" |
| 3559 | then |
| 3560 | # Compiler selection on MacOSX is more complicated than |
| 3561 | # AC_PROG_CC can handle, see Mac/README.txt for more |
| 3562 | # information |
| 3563 | if test -z "${CC}" |
| 3564 | then |
| 3565 | found_gcc= |
| 3566 | found_clang= |
| 3567 | as_save_IFS=$IFS; IFS=: |
| 3568 | for as_dir in $PATH |
| 3569 | do |
| 3570 | IFS=$as_save_IFS |
| 3571 | if test -x $as_dir/gcc; then |
| 3572 | if test -z "${found_gcc}"; then |
| 3573 | found_gcc=$as_dir/gcc |
| 3574 | fi |
| 3575 | fi |
| 3576 | if test -x $as_dir/clang; then |
| 3577 | if test -z "${found_clang}"; then |
| 3578 | found_clang=$as_dir/clang |
| 3579 | fi |
| 3580 | fi |
| 3581 | done |
| 3582 | IFS=$as_save_IFS |
| 3583 | |
| 3584 | if test -n "$found_gcc" -a -n "$found_clang" |
| 3585 | then |
| 3586 | if test -n "`"$found_gcc" --version | grep llvm-gcc`" |
| 3587 | then |
| 3588 | { $as_echo "$as_me:${as_lineno-$LINENO}: Detected llvm-gcc, falling back to clang" >&5 |
| 3589 | $as_echo "$as_me: Detected llvm-gcc, falling back to clang" >&6;} |
| 3590 | CC="$found_clang" |
| 3591 | CXX="$found_clang++" |
| 3592 | fi |
| 3593 | |
| 3594 | |
| 3595 | elif test -z "$found_gcc" -a -n "$found_clang" |
| 3596 | then |
| 3597 | { $as_echo "$as_me:${as_lineno-$LINENO}: No GCC found, use CLANG" >&5 |
| 3598 | $as_echo "$as_me: No GCC found, use CLANG" >&6;} |
| 3599 | CC="$found_clang" |
| 3600 | CXX="$found_clang++" |
| 3601 | |
| 3602 | elif test -z "$found_gcc" -a -z "$found_clang" |
| 3603 | then |
| 3604 | found_clang=`/usr/bin/xcrun -find clang 2>/dev/null` |
| 3605 | if test -n "${found_clang}" |
| 3606 | then |
| 3607 | { $as_echo "$as_me:${as_lineno-$LINENO}: Using clang from Xcode.app" >&5 |
| 3608 | $as_echo "$as_me: Using clang from Xcode.app" >&6;} |
| 3609 | CC="${found_clang}" |
| 3610 | CXX="`/usr/bin/xcrun -find clang++`" |
| 3611 | |
| 3612 | # else: use default behaviour |
| 3613 | fi |
| 3614 | fi |
| 3615 | fi |
| 3616 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3617 | ac_ext=c |
| 3618 | ac_cpp='$CPP $CPPFLAGS' |
| 3619 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3620 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3621 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3622 | if test -n "$ac_tool_prefix"; then |
| 3623 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3624 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3625 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3626 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3627 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3628 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3629 | else |
| 3630 | if test -n "$CC"; then |
| 3631 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3632 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3633 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3634 | for as_dir in $PATH |
| 3635 | do |
| 3636 | IFS=$as_save_IFS |
| 3637 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3638 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3639 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3640 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3641 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3642 | break 2 |
| 3643 | fi |
| 3644 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3645 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3646 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3647 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3648 | fi |
| 3649 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3650 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3651 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3653 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3654 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3655 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3656 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3657 | fi |
| 3658 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3659 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3660 | fi |
| 3661 | if test -z "$ac_cv_prog_CC"; then |
| 3662 | ac_ct_CC=$CC |
| 3663 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3664 | set dummy gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3665 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3666 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3667 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3668 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3669 | else |
| 3670 | if test -n "$ac_ct_CC"; then |
| 3671 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3672 | else |
| 3673 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3674 | for as_dir in $PATH |
| 3675 | do |
| 3676 | IFS=$as_save_IFS |
| 3677 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3678 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3679 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3680 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3681 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3682 | break 2 |
| 3683 | fi |
| 3684 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3685 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3686 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3687 | |
| 3688 | fi |
| 3689 | fi |
| 3690 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3691 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3692 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3693 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3694 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3695 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3696 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3697 | fi |
| 3698 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3699 | if test "x$ac_ct_CC" = x; then |
| 3700 | CC="" |
| 3701 | else |
| 3702 | case $cross_compiling:$ac_tool_warned in |
| 3703 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3704 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3705 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3706 | ac_tool_warned=yes ;; |
| 3707 | esac |
| 3708 | CC=$ac_ct_CC |
| 3709 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3710 | else |
| 3711 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3712 | fi |
| 3713 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3714 | if test -z "$CC"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3715 | if test -n "$ac_tool_prefix"; then |
| 3716 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3717 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3718 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3719 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3720 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3721 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3722 | else |
| 3723 | if test -n "$CC"; then |
| 3724 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3725 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3726 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3727 | for as_dir in $PATH |
| 3728 | do |
| 3729 | IFS=$as_save_IFS |
| 3730 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3731 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3732 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3733 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3734 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3735 | break 2 |
| 3736 | fi |
| 3737 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3738 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3739 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3740 | |
| 3741 | fi |
| 3742 | fi |
| 3743 | CC=$ac_cv_prog_CC |
| 3744 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3745 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3746 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3747 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3748 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3749 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3750 | fi |
| 3751 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3752 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3753 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3754 | fi |
| 3755 | if test -z "$CC"; then |
| 3756 | # Extract the first word of "cc", so it can be a program name with args. |
| 3757 | set dummy cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3758 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3759 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3760 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3761 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3762 | else |
| 3763 | if test -n "$CC"; then |
| 3764 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3765 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3766 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3767 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3768 | for as_dir in $PATH |
| 3769 | do |
| 3770 | IFS=$as_save_IFS |
| 3771 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3772 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3773 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3774 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3775 | ac_prog_rejected=yes |
| 3776 | continue |
| 3777 | fi |
| 3778 | ac_cv_prog_CC="cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3779 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3780 | break 2 |
| 3781 | fi |
| 3782 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3783 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3784 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3785 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3786 | if test $ac_prog_rejected = yes; then |
| 3787 | # We found a bogon in the path, so make sure we never use it. |
| 3788 | set dummy $ac_cv_prog_CC |
| 3789 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3790 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3791 | # We chose a different compiler from the bogus one. |
| 3792 | # However, it has the same basename, so the bogon will be chosen |
| 3793 | # first if we set CC to just the basename; use the full file name. |
| 3794 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3795 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3796 | fi |
| 3797 | fi |
| 3798 | fi |
| 3799 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3800 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3801 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3802 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3803 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3804 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3805 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3806 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3807 | fi |
| 3808 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3809 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3810 | fi |
| 3811 | if test -z "$CC"; then |
| 3812 | if test -n "$ac_tool_prefix"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3813 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3814 | do |
| 3815 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3816 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3817 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3818 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3819 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3820 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3821 | else |
| 3822 | if test -n "$CC"; then |
| 3823 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3824 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3825 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3826 | for as_dir in $PATH |
| 3827 | do |
| 3828 | IFS=$as_save_IFS |
| 3829 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3830 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3831 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3832 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3833 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3834 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3835 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3836 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3837 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3838 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3839 | |
| 3840 | fi |
| 3841 | fi |
| 3842 | CC=$ac_cv_prog_CC |
| 3843 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3844 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3845 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3846 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3847 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3848 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3849 | fi |
| 3850 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3851 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3852 | test -n "$CC" && break |
| 3853 | done |
| 3854 | fi |
| 3855 | if test -z "$CC"; then |
| 3856 | ac_ct_CC=$CC |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3857 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3858 | do |
| 3859 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3860 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3861 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3862 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3863 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3864 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3865 | else |
| 3866 | if test -n "$ac_ct_CC"; then |
| 3867 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3868 | else |
| 3869 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3870 | for as_dir in $PATH |
| 3871 | do |
| 3872 | IFS=$as_save_IFS |
| 3873 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3874 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 3875 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3876 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3877 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3878 | break 2 |
| 3879 | fi |
| 3880 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3881 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3882 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3883 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3884 | fi |
| 3885 | fi |
| 3886 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3887 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3888 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3889 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3890 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3891 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3892 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3893 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3894 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3895 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3896 | test -n "$ac_ct_CC" && break |
| 3897 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3898 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3899 | if test "x$ac_ct_CC" = x; then |
| 3900 | CC="" |
| 3901 | else |
| 3902 | case $cross_compiling:$ac_tool_warned in |
| 3903 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3904 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3905 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3906 | ac_tool_warned=yes ;; |
| 3907 | esac |
| 3908 | CC=$ac_ct_CC |
| 3909 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3910 | fi |
| 3911 | |
| 3912 | fi |
| 3913 | |
| 3914 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3915 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3916 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 3917 | as_fn_error $? "no acceptable C compiler found in \$PATH |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 3918 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3919 | |
| 3920 | # Provide some information about the compiler. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3921 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3922 | set X $ac_compile |
| 3923 | ac_compiler=$2 |
| 3924 | for ac_option in --version -v -V -qversion; do |
| 3925 | { { ac_try="$ac_compiler $ac_option >&5" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3926 | case "(($ac_try" in |
| 3927 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3928 | *) ac_try_echo=$ac_try;; |
| 3929 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3930 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3931 | $as_echo "$ac_try_echo"; } >&5 |
| 3932 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3933 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3934 | if test -s conftest.err; then |
| 3935 | sed '10a\ |
| 3936 | ... rest of stderr output deleted ... |
| 3937 | 10q' conftest.err >conftest.er1 |
| 3938 | cat conftest.er1 >&5 |
| 3939 | fi |
| 3940 | rm -f conftest.er1 conftest.err |
| 3941 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3942 | test $ac_status = 0; } |
| 3943 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3944 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3945 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3946 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3947 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3948 | int |
| 3949 | main () |
| 3950 | { |
| 3951 | |
| 3952 | ; |
| 3953 | return 0; |
| 3954 | } |
| 3955 | _ACEOF |
| 3956 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3957 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3958 | # Try to create an executable without -o first, disregard a.out. |
| 3959 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3960 | # of exeext. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3961 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3962 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3963 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3964 | |
| 3965 | # The possible output files: |
| 3966 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3967 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3968 | ac_rmfiles= |
| 3969 | for ac_file in $ac_files |
| 3970 | do |
| 3971 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3972 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3973 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3974 | esac |
| 3975 | done |
| 3976 | rm -f $ac_rmfiles |
| 3977 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3978 | if { { ac_try="$ac_link_default" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3979 | case "(($ac_try" in |
| 3980 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3981 | *) ac_try_echo=$ac_try;; |
| 3982 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3983 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3984 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3985 | (eval "$ac_link_default") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3986 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3987 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3988 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3989 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3990 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3991 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3992 | # so that the user can short-circuit this test for compilers unknown to |
| 3993 | # Autoconf. |
| 3994 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3995 | do |
| 3996 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3997 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3998 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3999 | ;; |
| 4000 | [ab].out ) |
| 4001 | # We found the default executable, but exeext='' is most |
| 4002 | # certainly right. |
| 4003 | break;; |
| 4004 | *.* ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4005 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4006 | then :; else |
| 4007 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 4008 | fi |
| 4009 | # We set ac_cv_exeext here because the later test for it is not |
| 4010 | # safe: cross compilers may not add the suffix if given an `-o' |
| 4011 | # argument, so we may need to know it at that point already. |
| 4012 | # Even if this section looks crufty: it has the advantage of |
| 4013 | # actually working. |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4014 | break;; |
| 4015 | * ) |
| 4016 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4017 | esac |
| 4018 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4019 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 4020 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4021 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4022 | ac_file='' |
| 4023 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4024 | if test -z "$ac_file"; then : |
| 4025 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4026 | $as_echo "no" >&6; } |
| 4027 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4028 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 4029 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4030 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4031 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4032 | as_fn_error 77 "C compiler cannot create executables |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4033 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4034 | else |
| 4035 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4036 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 4037 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4038 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 4039 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 4040 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 4041 | $as_echo "$ac_file" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4042 | ac_exeext=$ac_cv_exeext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4043 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4044 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4045 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4046 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 4047 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 4048 | if { { ac_try="$ac_link" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4049 | case "(($ac_try" in |
| 4050 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 4051 | *) ac_try_echo=$ac_try;; |
| 4052 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4053 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 4054 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4055 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4056 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4057 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 4058 | test $ac_status = 0; }; then : |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4059 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 4060 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 4061 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 4062 | # `rm'. |
| 4063 | for ac_file in conftest.exe conftest conftest.*; do |
| 4064 | test -f "$ac_file" || continue |
| 4065 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4066 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4067 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 4068 | break;; |
| 4069 | * ) break;; |
| 4070 | esac |
| 4071 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4072 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4073 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4074 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4075 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4076 | See \`config.log' for more details" "$LINENO" 5; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 4077 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4078 | rm -f conftest conftest$ac_cv_exeext |
| 4079 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 4080 | $as_echo "$ac_cv_exeext" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4081 | |
| 4082 | rm -f conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4083 | EXEEXT=$ac_cv_exeext |
| 4084 | ac_exeext=$EXEEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4085 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4086 | /* end confdefs.h. */ |
| 4087 | #include <stdio.h> |
| 4088 | int |
| 4089 | main () |
| 4090 | { |
| 4091 | FILE *f = fopen ("conftest.out", "w"); |
| 4092 | return ferror (f) || fclose (f) != 0; |
| 4093 | |
| 4094 | ; |
| 4095 | return 0; |
| 4096 | } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4097 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4098 | ac_clean_files="$ac_clean_files conftest.out" |
| 4099 | # Check that the compiler produces executables we can run. If not, either |
| 4100 | # the compiler is broken, or we cross compile. |
| 4101 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 4102 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 4103 | if test "$cross_compiling" != yes; then |
| 4104 | { { ac_try="$ac_link" |
| 4105 | case "(($ac_try" in |
| 4106 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 4107 | *) ac_try_echo=$ac_try;; |
| 4108 | esac |
| 4109 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 4110 | $as_echo "$ac_try_echo"; } >&5 |
| 4111 | (eval "$ac_link") 2>&5 |
| 4112 | ac_status=$? |
| 4113 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 4114 | test $ac_status = 0; } |
| 4115 | if { ac_try='./conftest$ac_cv_exeext' |
| 4116 | { { case "(($ac_try" in |
| 4117 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 4118 | *) ac_try_echo=$ac_try;; |
| 4119 | esac |
| 4120 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 4121 | $as_echo "$ac_try_echo"; } >&5 |
| 4122 | (eval "$ac_try") 2>&5 |
| 4123 | ac_status=$? |
| 4124 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 4125 | test $ac_status = 0; }; }; then |
| 4126 | cross_compiling=no |
| 4127 | else |
| 4128 | if test "$cross_compiling" = maybe; then |
| 4129 | cross_compiling=yes |
| 4130 | else |
| 4131 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4132 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4133 | as_fn_error $? "cannot run C compiled programs. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4134 | If you meant to cross compile, use \`--host'. |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4135 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4136 | fi |
| 4137 | fi |
| 4138 | fi |
| 4139 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 4140 | $as_echo "$cross_compiling" >&6; } |
| 4141 | |
| 4142 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 4143 | ac_clean_files=$ac_clean_files_save |
| 4144 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 4145 | $as_echo_n "checking for suffix of object files... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4146 | if ${ac_cv_objext+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4147 | $as_echo_n "(cached) " >&6 |
| 4148 | else |
| 4149 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4150 | /* end confdefs.h. */ |
| 4151 | |
| 4152 | int |
| 4153 | main () |
| 4154 | { |
| 4155 | |
| 4156 | ; |
| 4157 | return 0; |
| 4158 | } |
| 4159 | _ACEOF |
| 4160 | rm -f conftest.o conftest.obj |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4161 | if { { ac_try="$ac_compile" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4162 | case "(($ac_try" in |
| 4163 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 4164 | *) ac_try_echo=$ac_try;; |
| 4165 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4166 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 4167 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4168 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4169 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4170 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 4171 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4172 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 4173 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4174 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4175 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4176 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 4177 | break;; |
| 4178 | esac |
| 4179 | done |
| 4180 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4181 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4182 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 4183 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4184 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4185 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4186 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4187 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4188 | fi |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 4189 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4190 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4191 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 4192 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4193 | OBJEXT=$ac_cv_objext |
| 4194 | ac_objext=$OBJEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 4196 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4197 | if ${ac_cv_c_compiler_gnu+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4198 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4199 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4200 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4201 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4202 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4203 | int |
| 4204 | main () |
| 4205 | { |
| 4206 | #ifndef __GNUC__ |
| 4207 | choke me |
| 4208 | #endif |
| 4209 | |
| 4210 | ; |
| 4211 | return 0; |
| 4212 | } |
| 4213 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4214 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4215 | ac_compiler_gnu=yes |
| 4216 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4217 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4218 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4219 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4220 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 4221 | |
| 4222 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4223 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 4224 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 4225 | if test $ac_compiler_gnu = yes; then |
| 4226 | GCC=yes |
| 4227 | else |
| 4228 | GCC= |
| 4229 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4230 | ac_test_CFLAGS=${CFLAGS+set} |
| 4231 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4232 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 4233 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4234 | if ${ac_cv_prog_cc_g+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4235 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4236 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4237 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 4238 | ac_c_werror_flag=yes |
| 4239 | ac_cv_prog_cc_g=no |
| 4240 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4241 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4242 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4243 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4244 | int |
| 4245 | main () |
| 4246 | { |
| 4247 | |
| 4248 | ; |
| 4249 | return 0; |
| 4250 | } |
| 4251 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4252 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4253 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4254 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4255 | CFLAGS="" |
| 4256 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4257 | /* end confdefs.h. */ |
| 4258 | |
| 4259 | int |
| 4260 | main () |
| 4261 | { |
| 4262 | |
| 4263 | ; |
| 4264 | return 0; |
| 4265 | } |
| 4266 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4267 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4268 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4269 | else |
| 4270 | ac_c_werror_flag=$ac_save_c_werror_flag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4271 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4272 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4273 | /* end confdefs.h. */ |
| 4274 | |
| 4275 | int |
| 4276 | main () |
| 4277 | { |
| 4278 | |
| 4279 | ; |
| 4280 | return 0; |
| 4281 | } |
| 4282 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4283 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4284 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4285 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4286 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4287 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4288 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4289 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4290 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4291 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 4292 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4293 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 4294 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4295 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4296 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4297 | elif test $ac_cv_prog_cc_g = yes; then |
| 4298 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4299 | CFLAGS="-g -O2" |
| 4300 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4301 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4302 | fi |
| 4303 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4304 | if test "$GCC" = yes; then |
| 4305 | CFLAGS="-O2" |
| 4306 | else |
| 4307 | CFLAGS= |
| 4308 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4309 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4310 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 4311 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4312 | if ${ac_cv_prog_cc_c89+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4313 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4314 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4315 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4316 | ac_save_CC=$CC |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4317 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4318 | /* end confdefs.h. */ |
| 4319 | #include <stdarg.h> |
| 4320 | #include <stdio.h> |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 4321 | struct stat; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4322 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 4323 | struct buf { int x; }; |
| 4324 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 4325 | static char *e (p, i) |
| 4326 | char **p; |
| 4327 | int i; |
| 4328 | { |
| 4329 | return p[i]; |
| 4330 | } |
| 4331 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 4332 | { |
| 4333 | char *s; |
| 4334 | va_list v; |
| 4335 | va_start (v,p); |
| 4336 | s = g (p, va_arg (v,int)); |
| 4337 | va_end (v); |
| 4338 | return s; |
| 4339 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4340 | |
| 4341 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 4342 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 4343 | These don't provoke an error unfortunately, instead are silently treated |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4344 | as 'x'. The following induces an error, until -std is added to get |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4345 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 4346 | array size at least. It's necessary to write '\x00'==0 to get something |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4347 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4348 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 4349 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4350 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 4351 | inside strings and character constants. */ |
| 4352 | #define FOO(x) 'x' |
| 4353 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 4354 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4355 | int test (int i, double x); |
| 4356 | struct s1 {int (*f) (int a);}; |
| 4357 | struct s2 {int (*f) (double a);}; |
| 4358 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 4359 | int argc; |
| 4360 | char **argv; |
| 4361 | int |
| 4362 | main () |
| 4363 | { |
| 4364 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 4365 | ; |
| 4366 | return 0; |
| 4367 | } |
| 4368 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4369 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 4370 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4371 | do |
| 4372 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4373 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4374 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4375 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4376 | rm -f core conftest.err conftest.$ac_objext |
| 4377 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4378 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4379 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4380 | CC=$ac_save_CC |
| 4381 | |
| 4382 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4383 | # AC_CACHE_VAL |
| 4384 | case "x$ac_cv_prog_cc_c89" in |
| 4385 | x) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4386 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 4387 | $as_echo "none needed" >&6; } ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4388 | xno) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4389 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 4390 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4391 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4392 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4393 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 4394 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4395 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4396 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4397 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4398 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4399 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4400 | ac_ext=c |
| 4401 | ac_cpp='$CPP $CPPFLAGS' |
| 4402 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4403 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4404 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4405 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4406 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4407 | |
| 4408 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4409 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 4410 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4411 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4412 | # Check whether --with-cxx_main was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4413 | if test "${with_cxx_main+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4414 | withval=$with_cxx_main; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4415 | |
| 4416 | case $withval in |
| 4417 | no) with_cxx_main=no |
| 4418 | MAINCC='$(CC)';; |
| 4419 | yes) with_cxx_main=yes |
| 4420 | MAINCC='$(CXX)';; |
| 4421 | *) with_cxx_main=yes |
| 4422 | MAINCC=$withval |
| 4423 | if test -z "$CXX" |
| 4424 | then |
| 4425 | CXX=$withval |
| 4426 | fi;; |
| 4427 | esac |
| 4428 | else |
| 4429 | |
| 4430 | with_cxx_main=no |
| 4431 | MAINCC='$(CC)' |
| 4432 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4433 | fi |
| 4434 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4435 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 4436 | $as_echo "$with_cxx_main" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4437 | |
| 4438 | preset_cxx="$CXX" |
| 4439 | if test -z "$CXX" |
| 4440 | then |
| 4441 | case "$CC" in |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4442 | gcc) if test -n "$ac_tool_prefix"; then |
| 4443 | # Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args. |
| 4444 | set dummy ${ac_tool_prefix}g++; ac_word=$2 |
| 4445 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4446 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4447 | if ${ac_cv_path_CXX+:} false; then : |
| 4448 | $as_echo_n "(cached) " >&6 |
| 4449 | else |
| 4450 | case $CXX in |
| 4451 | [\\/]* | ?:[\\/]*) |
| 4452 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4453 | ;; |
| 4454 | *) |
| 4455 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4456 | for as_dir in notfound |
| 4457 | do |
| 4458 | IFS=$as_save_IFS |
| 4459 | test -z "$as_dir" && as_dir=. |
| 4460 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 4461 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4462 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
| 4463 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 4464 | break 2 |
| 4465 | fi |
| 4466 | done |
| 4467 | done |
| 4468 | IFS=$as_save_IFS |
| 4469 | |
| 4470 | ;; |
| 4471 | esac |
| 4472 | fi |
| 4473 | CXX=$ac_cv_path_CXX |
| 4474 | if test -n "$CXX"; then |
| 4475 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4476 | $as_echo "$CXX" >&6; } |
| 4477 | else |
| 4478 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4479 | $as_echo "no" >&6; } |
| 4480 | fi |
| 4481 | |
| 4482 | |
| 4483 | fi |
| 4484 | if test -z "$ac_cv_path_CXX"; then |
| 4485 | ac_pt_CXX=$CXX |
| 4486 | # Extract the first word of "g++", so it can be a program name with args. |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4487 | set dummy g++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4488 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4489 | $as_echo_n "checking for $ac_word... " >&6; } |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4490 | if ${ac_cv_path_ac_pt_CXX+:} false; then : |
| 4491 | $as_echo_n "(cached) " >&6 |
| 4492 | else |
| 4493 | case $ac_pt_CXX in |
| 4494 | [\\/]* | ?:[\\/]*) |
| 4495 | ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path. |
| 4496 | ;; |
| 4497 | *) |
| 4498 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4499 | for as_dir in notfound |
| 4500 | do |
| 4501 | IFS=$as_save_IFS |
| 4502 | test -z "$as_dir" && as_dir=. |
| 4503 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 4504 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4505 | ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext" |
| 4506 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 4507 | break 2 |
| 4508 | fi |
| 4509 | done |
| 4510 | done |
| 4511 | IFS=$as_save_IFS |
| 4512 | |
| 4513 | ;; |
| 4514 | esac |
| 4515 | fi |
| 4516 | ac_pt_CXX=$ac_cv_path_ac_pt_CXX |
| 4517 | if test -n "$ac_pt_CXX"; then |
| 4518 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5 |
| 4519 | $as_echo "$ac_pt_CXX" >&6; } |
| 4520 | else |
| 4521 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4522 | $as_echo "no" >&6; } |
| 4523 | fi |
| 4524 | |
| 4525 | if test "x$ac_pt_CXX" = x; then |
| 4526 | CXX="g++" |
| 4527 | else |
| 4528 | case $cross_compiling:$ac_tool_warned in |
| 4529 | yes:) |
| 4530 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 4531 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 4532 | ac_tool_warned=yes ;; |
| 4533 | esac |
| 4534 | CXX=$ac_pt_CXX |
| 4535 | fi |
| 4536 | else |
| 4537 | CXX="$ac_cv_path_CXX" |
| 4538 | fi |
| 4539 | ;; |
| 4540 | cc) if test -n "$ac_tool_prefix"; then |
| 4541 | # Extract the first word of "${ac_tool_prefix}c++", so it can be a program name with args. |
| 4542 | set dummy ${ac_tool_prefix}c++; ac_word=$2 |
| 4543 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4544 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4545 | if ${ac_cv_path_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4546 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4547 | else |
| 4548 | case $CXX in |
| 4549 | [\\/]* | ?:[\\/]*) |
| 4550 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4551 | ;; |
| 4552 | *) |
| 4553 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4554 | for as_dir in notfound |
| 4555 | do |
| 4556 | IFS=$as_save_IFS |
| 4557 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4558 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 4559 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4560 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4561 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4562 | break 2 |
| 4563 | fi |
| 4564 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4565 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4566 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4567 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4568 | ;; |
| 4569 | esac |
| 4570 | fi |
| 4571 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4572 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4574 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4575 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4576 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4577 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4578 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4579 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4580 | |
| 4581 | fi |
| 4582 | if test -z "$ac_cv_path_CXX"; then |
| 4583 | ac_pt_CXX=$CXX |
| 4584 | # Extract the first word of "c++", so it can be a program name with args. |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4585 | set dummy c++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4587 | $as_echo_n "checking for $ac_word... " >&6; } |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4588 | if ${ac_cv_path_ac_pt_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4589 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4590 | else |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4591 | case $ac_pt_CXX in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4592 | [\\/]* | ?:[\\/]*) |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4593 | ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path. |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4594 | ;; |
| 4595 | *) |
| 4596 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4597 | for as_dir in notfound |
| 4598 | do |
| 4599 | IFS=$as_save_IFS |
| 4600 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4601 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 4602 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4603 | ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4604 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4605 | break 2 |
| 4606 | fi |
| 4607 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4608 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4609 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4610 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4611 | ;; |
| 4612 | esac |
| 4613 | fi |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4614 | ac_pt_CXX=$ac_cv_path_ac_pt_CXX |
| 4615 | if test -n "$ac_pt_CXX"; then |
| 4616 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5 |
| 4617 | $as_echo "$ac_pt_CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4618 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4619 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4620 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4621 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4622 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4623 | if test "x$ac_pt_CXX" = x; then |
| 4624 | CXX="c++" |
| 4625 | else |
| 4626 | case $cross_compiling:$ac_tool_warned in |
| 4627 | yes:) |
| 4628 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 4629 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 4630 | ac_tool_warned=yes ;; |
| 4631 | esac |
| 4632 | CXX=$ac_pt_CXX |
| 4633 | fi |
| 4634 | else |
| 4635 | CXX="$ac_cv_path_CXX" |
| 4636 | fi |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4637 | ;; |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4638 | clang|*/clang) if test -n "$ac_tool_prefix"; then |
| 4639 | # Extract the first word of "${ac_tool_prefix}clang++", so it can be a program name with args. |
| 4640 | set dummy ${ac_tool_prefix}clang++; ac_word=$2 |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 4641 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4642 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4643 | if ${ac_cv_path_CXX+:} false; then : |
| 4644 | $as_echo_n "(cached) " >&6 |
| 4645 | else |
| 4646 | case $CXX in |
| 4647 | [\\/]* | ?:[\\/]*) |
| 4648 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4649 | ;; |
| 4650 | *) |
| 4651 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4652 | for as_dir in notfound |
| 4653 | do |
| 4654 | IFS=$as_save_IFS |
| 4655 | test -z "$as_dir" && as_dir=. |
| 4656 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 4657 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 4658 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
| 4659 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 4660 | break 2 |
| 4661 | fi |
| 4662 | done |
| 4663 | done |
| 4664 | IFS=$as_save_IFS |
| 4665 | |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 4666 | ;; |
| 4667 | esac |
| 4668 | fi |
| 4669 | CXX=$ac_cv_path_CXX |
| 4670 | if test -n "$CXX"; then |
| 4671 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4672 | $as_echo "$CXX" >&6; } |
| 4673 | else |
| 4674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4675 | $as_echo "no" >&6; } |
| 4676 | fi |
| 4677 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4678 | |
| 4679 | fi |
| 4680 | if test -z "$ac_cv_path_CXX"; then |
| 4681 | ac_pt_CXX=$CXX |
| 4682 | # Extract the first word of "clang++", so it can be a program name with args. |
| 4683 | set dummy clang++; ac_word=$2 |
| 4684 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4685 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4686 | if ${ac_cv_path_ac_pt_CXX+:} false; then : |
| 4687 | $as_echo_n "(cached) " >&6 |
| 4688 | else |
| 4689 | case $ac_pt_CXX in |
| 4690 | [\\/]* | ?:[\\/]*) |
| 4691 | ac_cv_path_ac_pt_CXX="$ac_pt_CXX" # Let the user override the test with a path. |
| 4692 | ;; |
| 4693 | *) |
| 4694 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4695 | for as_dir in notfound |
| 4696 | do |
| 4697 | IFS=$as_save_IFS |
| 4698 | test -z "$as_dir" && as_dir=. |
| 4699 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 4700 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4701 | ac_cv_path_ac_pt_CXX="$as_dir/$ac_word$ac_exec_ext" |
| 4702 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 4703 | break 2 |
| 4704 | fi |
| 4705 | done |
| 4706 | done |
| 4707 | IFS=$as_save_IFS |
| 4708 | |
| 4709 | ;; |
| 4710 | esac |
| 4711 | fi |
| 4712 | ac_pt_CXX=$ac_cv_path_ac_pt_CXX |
| 4713 | if test -n "$ac_pt_CXX"; then |
| 4714 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CXX" >&5 |
| 4715 | $as_echo "$ac_pt_CXX" >&6; } |
| 4716 | else |
| 4717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4718 | $as_echo "no" >&6; } |
| 4719 | fi |
| 4720 | |
| 4721 | if test "x$ac_pt_CXX" = x; then |
| 4722 | CXX="clang++" |
| 4723 | else |
| 4724 | case $cross_compiling:$ac_tool_warned in |
| 4725 | yes:) |
| 4726 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 4727 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 4728 | ac_tool_warned=yes ;; |
| 4729 | esac |
| 4730 | CXX=$ac_pt_CXX |
| 4731 | fi |
| 4732 | else |
| 4733 | CXX="$ac_cv_path_CXX" |
| 4734 | fi |
Ned Deily | cbfb9a5 | 2012-06-23 16:02:19 -0700 | [diff] [blame] | 4735 | ;; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4736 | esac |
| 4737 | if test "$CXX" = "notfound" |
| 4738 | then |
| 4739 | CXX="" |
| 4740 | fi |
| 4741 | fi |
| 4742 | if test -z "$CXX" |
| 4743 | then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4744 | if test -n "$ac_tool_prefix"; then |
| 4745 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4746 | do |
| 4747 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 4748 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4749 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4750 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4751 | if ${ac_cv_prog_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4752 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4753 | else |
| 4754 | if test -n "$CXX"; then |
| 4755 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4756 | else |
| 4757 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4758 | for as_dir in $PATH |
| 4759 | do |
| 4760 | IFS=$as_save_IFS |
| 4761 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4762 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 4763 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4764 | ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4765 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4766 | break 2 |
| 4767 | fi |
| 4768 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4769 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4770 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4771 | |
| 4772 | fi |
| 4773 | fi |
| 4774 | CXX=$ac_cv_prog_CXX |
| 4775 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4776 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4777 | $as_echo "$CXX" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4778 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4779 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4780 | $as_echo "no" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4781 | fi |
| 4782 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4783 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4784 | test -n "$CXX" && break |
| 4785 | done |
| 4786 | fi |
| 4787 | if test -z "$CXX"; then |
| 4788 | ac_ct_CXX=$CXX |
| 4789 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4790 | do |
| 4791 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4792 | set dummy $ac_prog; ac_word=$2 |
| 4793 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4794 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4795 | if ${ac_cv_prog_ac_ct_CXX+:} false; then : |
| 4796 | $as_echo_n "(cached) " >&6 |
| 4797 | else |
| 4798 | if test -n "$ac_ct_CXX"; then |
| 4799 | ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. |
| 4800 | else |
| 4801 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4802 | for as_dir in $PATH |
| 4803 | do |
| 4804 | IFS=$as_save_IFS |
| 4805 | test -z "$as_dir" && as_dir=. |
| 4806 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 4807 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4808 | ac_cv_prog_ac_ct_CXX="$ac_prog" |
| 4809 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 4810 | break 2 |
| 4811 | fi |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4812 | done |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 4813 | done |
| 4814 | IFS=$as_save_IFS |
| 4815 | |
| 4816 | fi |
| 4817 | fi |
| 4818 | ac_ct_CXX=$ac_cv_prog_ac_ct_CXX |
| 4819 | if test -n "$ac_ct_CXX"; then |
| 4820 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 |
| 4821 | $as_echo "$ac_ct_CXX" >&6; } |
| 4822 | else |
| 4823 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4824 | $as_echo "no" >&6; } |
| 4825 | fi |
| 4826 | |
| 4827 | |
| 4828 | test -n "$ac_ct_CXX" && break |
| 4829 | done |
| 4830 | |
| 4831 | if test "x$ac_ct_CXX" = x; then |
| 4832 | CXX="notfound" |
| 4833 | else |
| 4834 | case $cross_compiling:$ac_tool_warned in |
| 4835 | yes:) |
| 4836 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 4837 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 4838 | ac_tool_warned=yes ;; |
| 4839 | esac |
| 4840 | CXX=$ac_ct_CXX |
| 4841 | fi |
| 4842 | fi |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4843 | |
| 4844 | if test "$CXX" = "notfound" |
| 4845 | then |
| 4846 | CXX="" |
| 4847 | fi |
| 4848 | fi |
| 4849 | if test "$preset_cxx" != "$CXX" |
| 4850 | then |
Christian Heimes | fe32aec | 2013-11-20 01:18:26 +0100 | [diff] [blame] | 4851 | { $as_echo "$as_me:${as_lineno-$LINENO}: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4852 | |
| 4853 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4854 | If this is not intended, then set CXX on the configure command line. |
| 4855 | " >&5 |
Christian Heimes | fe32aec | 2013-11-20 01:18:26 +0100 | [diff] [blame] | 4856 | $as_echo "$as_me: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4857 | |
| 4858 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4859 | If this is not intended, then set CXX on the configure command line. |
Christian Heimes | fe32aec | 2013-11-20 01:18:26 +0100 | [diff] [blame] | 4860 | " >&6;} |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4861 | fi |
| 4862 | |
| 4863 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4864 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wl,--no-as-needed" >&5 |
| 4865 | $as_echo_n "checking for -Wl,--no-as-needed... " >&6; } |
| 4866 | save_LDFLAGS="$LDFLAGS" |
| 4867 | LDFLAGS="$LDFLAGS -Wl,--no-as-needed" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4868 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4869 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4870 | /* end confdefs.h. */ |
| 4871 | |
| 4872 | int |
| 4873 | main () |
| 4874 | { |
| 4875 | |
| 4876 | ; |
| 4877 | return 0; |
| 4878 | } |
| 4879 | _ACEOF |
| 4880 | if ac_fn_c_try_link "$LINENO"; then : |
| 4881 | NO_AS_NEEDED="-Wl,--no-as-needed" |
| 4882 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4883 | $as_echo "yes" >&6; } |
| 4884 | else |
| 4885 | NO_AS_NEEDED="" |
| 4886 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4887 | $as_echo "no" >&6; } |
| 4888 | fi |
| 4889 | rm -f core conftest.err conftest.$ac_objext \ |
| 4890 | conftest$ac_exeext conftest.$ac_ext |
| 4891 | LDFLAGS="$save_LDFLAGS" |
| 4892 | |
| 4893 | |
| 4894 | |
| 4895 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4896 | ac_ext=c |
| 4897 | ac_cpp='$CPP $CPPFLAGS' |
| 4898 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4899 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4900 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4901 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4902 | $as_echo_n "checking how to run the C preprocessor... " >&6; } |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4903 | # On Suns, sometimes $CPP names a directory. |
| 4904 | if test -n "$CPP" && test -d "$CPP"; then |
| 4905 | CPP= |
| 4906 | fi |
| 4907 | if test -z "$CPP"; then |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 4908 | if ${ac_cv_prog_CPP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4909 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4910 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4911 | # Double quotes because CPP needs to be expanded |
| 4912 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4913 | do |
| 4914 | ac_preproc_ok=false |
| 4915 | for ac_c_preproc_warn_flag in '' yes |
| 4916 | do |
| 4917 | # Use a header file that comes with gcc, so configuring glibc |
| 4918 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4919 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4920 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4921 | # On the NeXT, cc -E runs the code through the compiler's parser, |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4922 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4923 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4924 | /* end confdefs.h. */ |
| 4925 | #ifdef __STDC__ |
| 4926 | # include <limits.h> |
| 4927 | #else |
| 4928 | # include <assert.h> |
| 4929 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4930 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4931 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4932 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4933 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4934 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4935 | # Broken: fails on valid input. |
| 4936 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4937 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4938 | rm -f conftest.err conftest.i conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4939 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4940 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4941 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4942 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4943 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4944 | #include <ac_nonexistent.h> |
| 4945 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4946 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4947 | # Broken: success on invalid input. |
| 4948 | continue |
| 4949 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4950 | # Passes both tests. |
| 4951 | ac_preproc_ok=: |
| 4952 | break |
| 4953 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4954 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4955 | |
| 4956 | done |
| 4957 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4958 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4959 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4960 | break |
| 4961 | fi |
| 4962 | |
| 4963 | done |
| 4964 | ac_cv_prog_CPP=$CPP |
| 4965 | |
| 4966 | fi |
| 4967 | CPP=$ac_cv_prog_CPP |
| 4968 | else |
| 4969 | ac_cv_prog_CPP=$CPP |
| 4970 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4971 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4972 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4973 | ac_preproc_ok=false |
| 4974 | for ac_c_preproc_warn_flag in '' yes |
| 4975 | do |
| 4976 | # Use a header file that comes with gcc, so configuring glibc |
| 4977 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4978 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4979 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4980 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4981 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4982 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4983 | /* end confdefs.h. */ |
| 4984 | #ifdef __STDC__ |
| 4985 | # include <limits.h> |
| 4986 | #else |
| 4987 | # include <assert.h> |
| 4988 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4989 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4990 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4991 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4992 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4993 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4994 | # Broken: fails on valid input. |
| 4995 | continue |
| 4996 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 4997 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4998 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4999 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5000 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5001 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 5002 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5003 | #include <ac_nonexistent.h> |
| 5004 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5005 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5006 | # Broken: success on invalid input. |
| 5007 | continue |
| 5008 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5009 | # Passes both tests. |
| 5010 | ac_preproc_ok=: |
| 5011 | break |
| 5012 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5013 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5014 | |
| 5015 | done |
| 5016 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5017 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5018 | if $ac_preproc_ok; then : |
| 5019 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5020 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5021 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 5022 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5023 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5024 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 5025 | fi |
| 5026 | |
| 5027 | ac_ext=c |
| 5028 | ac_cpp='$CPP $CPPFLAGS' |
| 5029 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 5030 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 5031 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 5032 | |
| 5033 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5034 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 5035 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5036 | if ${ac_cv_path_GREP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5037 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 5038 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5039 | if test -z "$GREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5040 | ac_path_GREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5041 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 5042 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5043 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 5044 | do |
| 5045 | IFS=$as_save_IFS |
| 5046 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5047 | for ac_prog in grep ggrep; do |
| 5048 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5049 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5050 | as_fn_executable_p "$ac_path_GREP" || continue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5051 | # Check for GNU ac_path_GREP and select it if it is found. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5052 | # Check for GNU $ac_path_GREP |
| 5053 | case `"$ac_path_GREP" --version 2>&1` in |
| 5054 | *GNU*) |
| 5055 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 5056 | *) |
| 5057 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5058 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5059 | while : |
| 5060 | do |
| 5061 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 5062 | mv "conftest.tmp" "conftest.in" |
| 5063 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5064 | $as_echo 'GREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5065 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 5066 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5067 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5068 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 5069 | # Best one so far, save it but keep looking for a better one |
| 5070 | ac_cv_path_GREP="$ac_path_GREP" |
| 5071 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 5072 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5073 | # 10*(2^10) chars as input seems more than enough |
| 5074 | test $ac_count -gt 10 && break |
| 5075 | done |
| 5076 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 5077 | esac |
| 5078 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5079 | $ac_path_GREP_found && break 3 |
| 5080 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5081 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5082 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5083 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5084 | if test -z "$ac_cv_path_GREP"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5085 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5086 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5087 | else |
| 5088 | ac_cv_path_GREP=$GREP |
| 5089 | fi |
| 5090 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5091 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5092 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 5093 | $as_echo "$ac_cv_path_GREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5094 | GREP="$ac_cv_path_GREP" |
| 5095 | |
| 5096 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5097 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 5098 | $as_echo_n "checking for egrep... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5099 | if ${ac_cv_path_EGREP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5100 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5101 | else |
| 5102 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 5103 | then ac_cv_path_EGREP="$GREP -E" |
| 5104 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5105 | if test -z "$EGREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5106 | ac_path_EGREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5107 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 5108 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5109 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 5110 | do |
| 5111 | IFS=$as_save_IFS |
| 5112 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5113 | for ac_prog in egrep; do |
| 5114 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5115 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5116 | as_fn_executable_p "$ac_path_EGREP" || continue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5117 | # Check for GNU ac_path_EGREP and select it if it is found. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5118 | # Check for GNU $ac_path_EGREP |
| 5119 | case `"$ac_path_EGREP" --version 2>&1` in |
| 5120 | *GNU*) |
| 5121 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 5122 | *) |
| 5123 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5124 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5125 | while : |
| 5126 | do |
| 5127 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 5128 | mv "conftest.tmp" "conftest.in" |
| 5129 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5130 | $as_echo 'EGREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5131 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 5132 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5133 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5134 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 5135 | # Best one so far, save it but keep looking for a better one |
| 5136 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 5137 | ac_path_EGREP_max=$ac_count |
| 5138 | fi |
| 5139 | # 10*(2^10) chars as input seems more than enough |
| 5140 | test $ac_count -gt 10 && break |
| 5141 | done |
| 5142 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 5143 | esac |
| 5144 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5145 | $ac_path_EGREP_found && break 3 |
| 5146 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5147 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5148 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5149 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5150 | if test -z "$ac_cv_path_EGREP"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5151 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5152 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5153 | else |
| 5154 | ac_cv_path_EGREP=$EGREP |
| 5155 | fi |
| 5156 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5157 | fi |
| 5158 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5159 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 5160 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 5161 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 5162 | |
| 5163 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5164 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5165 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5166 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5167 | $as_echo_n "(cached) " >&6 |
| 5168 | else |
| 5169 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 5170 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5171 | #include <stdlib.h> |
| 5172 | #include <stdarg.h> |
| 5173 | #include <string.h> |
| 5174 | #include <float.h> |
| 5175 | |
| 5176 | int |
| 5177 | main () |
| 5178 | { |
| 5179 | |
| 5180 | ; |
| 5181 | return 0; |
| 5182 | } |
| 5183 | _ACEOF |
| 5184 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5185 | ac_cv_header_stdc=yes |
| 5186 | else |
| 5187 | ac_cv_header_stdc=no |
| 5188 | fi |
| 5189 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5190 | |
| 5191 | if test $ac_cv_header_stdc = yes; then |
| 5192 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 5193 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5194 | /* end confdefs.h. */ |
| 5195 | #include <string.h> |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 5196 | |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 5197 | _ACEOF |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 5198 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5199 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5200 | |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 5201 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5202 | ac_cv_header_stdc=no |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 5203 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 5204 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5205 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5206 | fi |
| 5207 | |
| 5208 | if test $ac_cv_header_stdc = yes; then |
| 5209 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 5210 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5211 | /* end confdefs.h. */ |
| 5212 | #include <stdlib.h> |
| 5213 | |
| 5214 | _ACEOF |
| 5215 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 5216 | $EGREP "free" >/dev/null 2>&1; then : |
| 5217 | |
| 5218 | else |
| 5219 | ac_cv_header_stdc=no |
| 5220 | fi |
| 5221 | rm -f conftest* |
| 5222 | |
| 5223 | fi |
| 5224 | |
| 5225 | if test $ac_cv_header_stdc = yes; then |
| 5226 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 5227 | if test "$cross_compiling" = yes; then : |
| 5228 | : |
| 5229 | else |
| 5230 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5231 | /* end confdefs.h. */ |
| 5232 | #include <ctype.h> |
| 5233 | #include <stdlib.h> |
| 5234 | #if ((' ' & 0x0FF) == 0x020) |
| 5235 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 5236 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 5237 | #else |
| 5238 | # define ISLOWER(c) \ |
| 5239 | (('a' <= (c) && (c) <= 'i') \ |
| 5240 | || ('j' <= (c) && (c) <= 'r') \ |
| 5241 | || ('s' <= (c) && (c) <= 'z')) |
| 5242 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 5243 | #endif |
| 5244 | |
| 5245 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 5246 | int |
| 5247 | main () |
| 5248 | { |
| 5249 | int i; |
| 5250 | for (i = 0; i < 256; i++) |
| 5251 | if (XOR (islower (i), ISLOWER (i)) |
| 5252 | || toupper (i) != TOUPPER (i)) |
| 5253 | return 2; |
| 5254 | return 0; |
| 5255 | } |
| 5256 | _ACEOF |
| 5257 | if ac_fn_c_try_run "$LINENO"; then : |
| 5258 | |
| 5259 | else |
| 5260 | ac_cv_header_stdc=no |
| 5261 | fi |
| 5262 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5263 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 5264 | fi |
| 5265 | |
| 5266 | fi |
| 5267 | fi |
| 5268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 5269 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 5270 | if test $ac_cv_header_stdc = yes; then |
| 5271 | |
| 5272 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 5273 | |
| 5274 | fi |
| 5275 | |
| 5276 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 5277 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 5278 | inttypes.h stdint.h unistd.h |
| 5279 | do : |
| 5280 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 5281 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 5282 | " |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 5283 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5284 | cat >>confdefs.h <<_ACEOF |
| 5285 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 5286 | _ACEOF |
| 5287 | |
| 5288 | fi |
| 5289 | |
| 5290 | done |
| 5291 | |
| 5292 | |
| 5293 | |
| 5294 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5295 | if test "x$ac_cv_header_minix_config_h" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5296 | MINIX=yes |
| 5297 | else |
| 5298 | MINIX= |
| 5299 | fi |
| 5300 | |
| 5301 | |
| 5302 | if test "$MINIX" = yes; then |
| 5303 | |
| 5304 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 5305 | |
| 5306 | |
| 5307 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 5308 | |
| 5309 | |
| 5310 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 5311 | |
| 5312 | fi |
| 5313 | |
| 5314 | |
| 5315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 5316 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5317 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5318 | $as_echo_n "(cached) " >&6 |
| 5319 | else |
| 5320 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5321 | /* end confdefs.h. */ |
| 5322 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5323 | # define __EXTENSIONS__ 1 |
| 5324 | $ac_includes_default |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5325 | int |
| 5326 | main () |
| 5327 | { |
| 5328 | |
| 5329 | ; |
| 5330 | return 0; |
| 5331 | } |
| 5332 | _ACEOF |
| 5333 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5334 | ac_cv_safe_to_define___extensions__=yes |
| 5335 | else |
| 5336 | ac_cv_safe_to_define___extensions__=no |
| 5337 | fi |
| 5338 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5339 | fi |
| 5340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 5341 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 5342 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 5343 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 5344 | |
| 5345 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 5346 | |
| 5347 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 5348 | |
| 5349 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 5350 | |
| 5351 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 5352 | |
| 5353 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5354 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5355 | # Check for unsupported systems |
| 5356 | case $ac_sys_system/$ac_sys_release in |
| 5357 | atheos*|Linux*/1*) |
| 5358 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 5359 | echo See README for details. |
| 5360 | exit 1;; |
| 5361 | esac |
| 5362 | |
| 5363 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5364 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 5365 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5366 | |
| 5367 | # Check whether --with-suffix was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5368 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5369 | withval=$with_suffix; |
| 5370 | case $withval in |
| 5371 | no) EXEEXT=;; |
| 5372 | yes) EXEEXT=.exe;; |
| 5373 | *) EXEEXT=$withval;; |
| 5374 | esac |
| 5375 | fi |
| 5376 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5377 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 5378 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5379 | |
| 5380 | # Test whether we're running on a non-case-sensitive system, in which |
| 5381 | # case we give a warning if no ext is given |
| 5382 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5383 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 5384 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5385 | if test ! -d CaseSensitiveTestDir; then |
| 5386 | mkdir CaseSensitiveTestDir |
| 5387 | fi |
| 5388 | |
| 5389 | if test -d casesensitivetestdir |
| 5390 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5391 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5392 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5393 | BUILDEXEEXT=.exe |
| 5394 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5395 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5396 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5397 | BUILDEXEEXT=$EXEEXT |
| 5398 | fi |
| 5399 | rmdir CaseSensitiveTestDir |
| 5400 | |
| 5401 | case $MACHDEP in |
| 5402 | bsdos*) |
| 5403 | case $CC in |
| 5404 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 5405 | esac;; |
| 5406 | esac |
| 5407 | |
| 5408 | case $ac_sys_system in |
| 5409 | hp*|HP*) |
| 5410 | case $CC in |
| 5411 | cc|*/cc) CC="$CC -Ae";; |
| 5412 | esac;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5413 | esac |
| 5414 | |
doko@python.org | 3e6e2ac | 2013-01-25 13:12:29 +0100 | [diff] [blame] | 5415 | MULTIARCH=$($CC --print-multiarch 2>/dev/null) |
| 5416 | |
| 5417 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5418 | |
| 5419 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5420 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 5421 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5422 | if test -z "$LIBRARY" |
| 5423 | then |
Barry Warsaw | f040d7d | 2010-10-18 17:09:07 +0000 | [diff] [blame] | 5424 | LIBRARY='libpython$(VERSION)$(ABIFLAGS).a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5425 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5426 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 5427 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5428 | |
| 5429 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 5430 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 5431 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 5432 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 5433 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 5434 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 5435 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 5436 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 5437 | # |
| 5438 | # RUNSHARED is used to run shared python without installed libraries |
| 5439 | # |
| 5440 | # INSTSONAME is the name of the shared library that will be use to install |
| 5441 | # on the system - some systems like version suffix, others don't |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5442 | # |
| 5443 | # LDVERSION is the shared library version number, normally the Python version |
| 5444 | # with the ABI build flags appended. |
| 5445 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5446 | |
| 5447 | |
| 5448 | |
| 5449 | |
| 5450 | |
| 5451 | |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 5452 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5453 | LDLIBRARY="$LIBRARY" |
| 5454 | BLDLIBRARY='$(LDLIBRARY)' |
| 5455 | INSTSONAME='$(LDLIBRARY)' |
| 5456 | DLLLIBRARY='' |
| 5457 | LDLIBRARYDIR='' |
| 5458 | RUNSHARED='' |
Barry Warsaw | 14d98ac | 2010-11-24 19:43:47 +0000 | [diff] [blame] | 5459 | LDVERSION="$VERSION" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5460 | |
| 5461 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 5462 | # If CXX is set, and if it is needed to link a main function that was |
| 5463 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 5464 | # python might then depend on the C++ runtime |
| 5465 | # This is altered for AIX in order to build the export list before |
| 5466 | # linking. |
| 5467 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5468 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 5469 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5470 | if test -z "$LINKCC" |
| 5471 | then |
| 5472 | LINKCC='$(PURIFY) $(MAINCC)' |
| 5473 | case $ac_sys_system in |
| 5474 | AIX*) |
| 5475 | exp_extra="\"\"" |
| 5476 | if test $ac_sys_release -ge 5 -o \ |
| 5477 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 5478 | exp_extra="." |
| 5479 | fi |
| 5480 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5481 | QNX*) |
| 5482 | # qcc must be used because the other compilers do not |
| 5483 | # support -N. |
| 5484 | LINKCC=qcc;; |
| 5485 | esac |
| 5486 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 5488 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5489 | |
| 5490 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 5491 | # make sure we default having it set to "no": this is used by |
| 5492 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 5493 | # to linker command lines, and failing to detect GNU ld simply results |
| 5494 | # in the same bahaviour as before. |
| 5495 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5496 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 5497 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5498 | ac_prog=ld |
| 5499 | if test "$GCC" = yes; then |
| 5500 | ac_prog=`$CC -print-prog-name=ld` |
| 5501 | fi |
| 5502 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 5503 | *GNU*) |
| 5504 | GNULD=yes;; |
| 5505 | *) |
| 5506 | GNULD=no;; |
| 5507 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5508 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 5509 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5510 | |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 5511 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
| 5512 | $as_echo_n "checking for inline... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5513 | if ${ac_cv_c_inline+:} false; then : |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 5514 | $as_echo_n "(cached) " >&6 |
| 5515 | else |
| 5516 | ac_cv_c_inline=no |
| 5517 | for ac_kw in inline __inline__ __inline; do |
| 5518 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 5519 | /* end confdefs.h. */ |
| 5520 | #ifndef __cplusplus |
| 5521 | typedef int foo_t; |
| 5522 | static $ac_kw foo_t static_foo () {return 0; } |
| 5523 | $ac_kw foo_t foo () {return 0; } |
| 5524 | #endif |
| 5525 | |
| 5526 | _ACEOF |
| 5527 | if ac_fn_c_try_compile "$LINENO"; then : |
| 5528 | ac_cv_c_inline=$ac_kw |
| 5529 | fi |
| 5530 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5531 | test "$ac_cv_c_inline" != no && break |
| 5532 | done |
| 5533 | |
| 5534 | fi |
| 5535 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
| 5536 | $as_echo "$ac_cv_c_inline" >&6; } |
| 5537 | |
| 5538 | case $ac_cv_c_inline in |
| 5539 | inline | yes) ;; |
| 5540 | *) |
| 5541 | case $ac_cv_c_inline in |
| 5542 | no) ac_val=;; |
| 5543 | *) ac_val=$ac_cv_c_inline;; |
| 5544 | esac |
| 5545 | cat >>confdefs.h <<_ACEOF |
| 5546 | #ifndef __cplusplus |
| 5547 | #define inline $ac_val |
| 5548 | #endif |
| 5549 | _ACEOF |
| 5550 | ;; |
| 5551 | esac |
| 5552 | |
| 5553 | if test "$ac_cv_c_inline" != no ; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 5554 | |
| 5555 | $as_echo "#define USE_INLINE 1" >>confdefs.h |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 5556 | |
| 5557 | |
| 5558 | fi |
| 5559 | |
| 5560 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5561 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 5562 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5563 | # Check whether --enable-shared was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5564 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5565 | enableval=$enable_shared; |
| 5566 | fi |
| 5567 | |
| 5568 | |
| 5569 | if test -z "$enable_shared" |
| 5570 | then |
| 5571 | case $ac_sys_system in |
Antoine Pitrou | 6103ab1 | 2009-10-24 20:11:21 +0000 | [diff] [blame] | 5572 | CYGWIN*) |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5573 | enable_shared="yes";; |
| 5574 | *) |
| 5575 | enable_shared="no";; |
| 5576 | esac |
| 5577 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5578 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 5579 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5580 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5581 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 5582 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5583 | # Check whether --enable-profiling was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5584 | if test "${enable_profiling+set}" = set; then : |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5585 | enableval=$enable_profiling; |
| 5586 | fi |
| 5587 | |
| 5588 | if test "x$enable_profiling" = xyes; then |
| 5589 | ac_save_cc="$CC" |
Benjamin Peterson | 615ea1a | 2013-03-26 08:55:37 -0400 | [diff] [blame] | 5590 | CC="$CC -pg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5591 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5592 | /* end confdefs.h. */ |
| 5593 | int main() { return 0; } |
| 5594 | _ACEOF |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5595 | if ac_fn_c_try_link "$LINENO"; then : |
| 5596 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5597 | else |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5598 | enable_profiling=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5599 | fi |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5600 | rm -f core conftest.err conftest.$ac_objext \ |
| 5601 | conftest$ac_exeext conftest.$ac_ext |
| 5602 | CC="$ac_save_cc" |
| 5603 | else |
| 5604 | enable_profiling=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5605 | fi |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5606 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_profiling" >&5 |
| 5607 | $as_echo "$enable_profiling" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5608 | |
doko@ubuntu.com | ba01583 | 2012-06-30 16:52:05 +0200 | [diff] [blame] | 5609 | if test "x$enable_profiling" = xyes; then |
| 5610 | BASECFLAGS="-pg $BASECFLAGS" |
| 5611 | LDFLAGS="-pg $LDFLAGS" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5612 | fi |
| 5613 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 5615 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5616 | |
| 5617 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 5618 | # library that we build, but we do not want to link against it (we |
| 5619 | # will find it with a -framework option). For this reason there is an |
| 5620 | # extra variable BLDLIBRARY against which Python and the extension |
| 5621 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 5622 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 5623 | if test "$enable_framework" |
| 5624 | then |
| 5625 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5626 | RUNSHARED=DYLD_FRAMEWORK_PATH=`pwd`${DYLD_FRAMEWORK_PATH:+:${DYLD_FRAMEWORK_PATH}} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5627 | BLDLIBRARY='' |
| 5628 | else |
| 5629 | BLDLIBRARY='$(LDLIBRARY)' |
| 5630 | fi |
| 5631 | |
| 5632 | # Other platforms follow |
| 5633 | if test $enable_shared = "yes"; then |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 5634 | PY_ENABLE_SHARED=1 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5635 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5636 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5637 | |
| 5638 | case $ac_sys_system in |
| 5639 | CYGWIN*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5640 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
| 5641 | DLLLIBRARY='libpython$(LDVERSION).dll' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5642 | ;; |
| 5643 | SunOS*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5644 | LDLIBRARY='libpython$(LDVERSION).so' |
| 5645 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5646 | RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5647 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5648 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 5649 | then |
| 5650 | PY3LIBRARY=libpython3.so |
| 5651 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5652 | ;; |
Charles-François Natali | 749400a | 2011-07-24 22:41:18 +0200 | [diff] [blame] | 5653 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5654 | LDLIBRARY='libpython$(LDVERSION).so' |
| 5655 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5656 | RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5657 | case $ac_sys_system in |
| 5658 | FreeBSD*) |
| 5659 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 5660 | ;; |
| 5661 | esac |
| 5662 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5663 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 5664 | then |
| 5665 | PY3LIBRARY=libpython3.so |
| 5666 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5667 | ;; |
| 5668 | hp*|HP*) |
| 5669 | case `uname -m` in |
| 5670 | ia64) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5671 | LDLIBRARY='libpython$(LDVERSION).so' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5672 | ;; |
| 5673 | *) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5674 | LDLIBRARY='libpython$(LDVERSION).sl' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5675 | ;; |
| 5676 | esac |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5677 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(LDVERSION)' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5678 | RUNSHARED=SHLIB_PATH=`pwd`${SHLIB_PATH:+:${SHLIB_PATH}} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5679 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5680 | Darwin*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5681 | LDLIBRARY='libpython$(LDVERSION).dylib' |
| 5682 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5683 | RUNSHARED=DYLD_LIBRARY_PATH=`pwd`${DYLD_LIBRARY_PATH:+:${DYLD_LIBRARY_PATH}} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5684 | ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 5685 | AIX*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5686 | LDLIBRARY='libpython$(LDVERSION).so' |
doko@ubuntu.com | e5de66e | 2014-05-07 12:57:44 +0200 | [diff] [blame] | 5687 | RUNSHARED=LIBPATH=`pwd`${LIBPATH:+:${LIBPATH}} |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 5688 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5689 | |
| 5690 | esac |
| 5691 | else # shared is disabled |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 5692 | PY_ENABLE_SHARED=0 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5693 | case $ac_sys_system in |
| 5694 | CYGWIN*) |
| 5695 | BLDLIBRARY='$(LIBRARY)' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5696 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5697 | ;; |
| 5698 | esac |
| 5699 | fi |
| 5700 | |
doko@ubuntu.com | 1abe1c5 | 2012-06-30 20:42:45 +0200 | [diff] [blame] | 5701 | if test "$cross_compiling" = yes; then |
| 5702 | RUNSHARED= |
| 5703 | fi |
| 5704 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5705 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 5706 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5707 | |
| 5708 | if test -n "$ac_tool_prefix"; then |
| 5709 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 5710 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5711 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5712 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5713 | if ${ac_cv_prog_RANLIB+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5714 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5715 | else |
| 5716 | if test -n "$RANLIB"; then |
| 5717 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 5718 | else |
| 5719 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5720 | for as_dir in $PATH |
| 5721 | do |
| 5722 | IFS=$as_save_IFS |
| 5723 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5724 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5725 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5726 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5727 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5728 | break 2 |
| 5729 | fi |
| 5730 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5731 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5732 | IFS=$as_save_IFS |
| 5733 | |
| 5734 | fi |
| 5735 | fi |
| 5736 | RANLIB=$ac_cv_prog_RANLIB |
| 5737 | if test -n "$RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5738 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 5739 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5740 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5741 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5742 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5743 | fi |
| 5744 | |
| 5745 | |
| 5746 | fi |
| 5747 | if test -z "$ac_cv_prog_RANLIB"; then |
| 5748 | ac_ct_RANLIB=$RANLIB |
| 5749 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 5750 | set dummy ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5751 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5752 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5753 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5754 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5755 | else |
| 5756 | if test -n "$ac_ct_RANLIB"; then |
| 5757 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5758 | else |
| 5759 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5760 | for as_dir in $PATH |
| 5761 | do |
| 5762 | IFS=$as_save_IFS |
| 5763 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5764 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5765 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5766 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5767 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5768 | break 2 |
| 5769 | fi |
| 5770 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5771 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5772 | IFS=$as_save_IFS |
| 5773 | |
| 5774 | fi |
| 5775 | fi |
| 5776 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5777 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5778 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5779 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5780 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5782 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5783 | fi |
| 5784 | |
| 5785 | if test "x$ac_ct_RANLIB" = x; then |
| 5786 | RANLIB=":" |
| 5787 | else |
| 5788 | case $cross_compiling:$ac_tool_warned in |
| 5789 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5790 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5791 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5792 | ac_tool_warned=yes ;; |
| 5793 | esac |
| 5794 | RANLIB=$ac_ct_RANLIB |
| 5795 | fi |
| 5796 | else |
| 5797 | RANLIB="$ac_cv_prog_RANLIB" |
| 5798 | fi |
| 5799 | |
| 5800 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 5801 | if test -n "$ac_tool_prefix"; then |
| 5802 | for ac_prog in ar aal |
| 5803 | do |
| 5804 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 5805 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5806 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5807 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 5808 | if ${ac_cv_prog_AR+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5809 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5810 | else |
| 5811 | if test -n "$AR"; then |
| 5812 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5813 | else |
| 5814 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5815 | for as_dir in $PATH |
| 5816 | do |
| 5817 | IFS=$as_save_IFS |
| 5818 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5819 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5820 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 5821 | ac_cv_prog_AR="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5822 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5823 | break 2 |
| 5824 | fi |
| 5825 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5826 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5827 | IFS=$as_save_IFS |
| 5828 | |
| 5829 | fi |
| 5830 | fi |
| 5831 | AR=$ac_cv_prog_AR |
| 5832 | if test -n "$AR"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5833 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5834 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5835 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5836 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5837 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5838 | fi |
| 5839 | |
| 5840 | |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 5841 | test -n "$AR" && break |
| 5842 | done |
| 5843 | fi |
| 5844 | if test -z "$AR"; then |
| 5845 | ac_ct_AR=$AR |
| 5846 | for ac_prog in ar aal |
| 5847 | do |
| 5848 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5849 | set dummy $ac_prog; ac_word=$2 |
| 5850 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5851 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5852 | if ${ac_cv_prog_ac_ct_AR+:} false; then : |
| 5853 | $as_echo_n "(cached) " >&6 |
| 5854 | else |
| 5855 | if test -n "$ac_ct_AR"; then |
| 5856 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. |
| 5857 | else |
| 5858 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5859 | for as_dir in $PATH |
| 5860 | do |
| 5861 | IFS=$as_save_IFS |
| 5862 | test -z "$as_dir" && as_dir=. |
| 5863 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 646eb1e | 2012-10-29 17:35:57 +0000 | [diff] [blame] | 5864 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 5865 | ac_cv_prog_ac_ct_AR="$ac_prog" |
| 5866 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 5867 | break 2 |
| 5868 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5869 | done |
doko@ubuntu.com | 51f6594 | 2012-06-30 14:42:46 +0200 | [diff] [blame] | 5870 | done |
| 5871 | IFS=$as_save_IFS |
| 5872 | |
| 5873 | fi |
| 5874 | fi |
| 5875 | ac_ct_AR=$ac_cv_prog_ac_ct_AR |
| 5876 | if test -n "$ac_ct_AR"; then |
| 5877 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 |
| 5878 | $as_echo "$ac_ct_AR" >&6; } |
| 5879 | else |
| 5880 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5881 | $as_echo "no" >&6; } |
| 5882 | fi |
| 5883 | |
| 5884 | |
| 5885 | test -n "$ac_ct_AR" && break |
| 5886 | done |
| 5887 | |
| 5888 | if test "x$ac_ct_AR" = x; then |
| 5889 | AR="ar" |
| 5890 | else |
| 5891 | case $cross_compiling:$ac_tool_warned in |
| 5892 | yes:) |
| 5893 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5894 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 5895 | ac_tool_warned=yes ;; |
| 5896 | esac |
| 5897 | AR=$ac_ct_AR |
| 5898 | fi |
| 5899 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5900 | |
| 5901 | |
| 5902 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5903 | |
| 5904 | if test -z "$ARFLAGS" |
| 5905 | then |
| 5906 | ARFLAGS="rc" |
| 5907 | fi |
| 5908 | |
doko@ubuntu.com | 5884449 | 2012-06-30 18:25:32 +0200 | [diff] [blame] | 5909 | if test -n "$ac_tool_prefix"; then |
| 5910 | for ac_prog in readelf |
| 5911 | do |
| 5912 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 5913 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
| 5914 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5915 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5916 | if ${ac_cv_prog_READELF+:} false; then : |
| 5917 | $as_echo_n "(cached) " >&6 |
| 5918 | else |
| 5919 | if test -n "$READELF"; then |
| 5920 | ac_cv_prog_READELF="$READELF" # Let the user override the test. |
| 5921 | else |
| 5922 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5923 | for as_dir in $PATH |
| 5924 | do |
| 5925 | IFS=$as_save_IFS |
| 5926 | test -z "$as_dir" && as_dir=. |
| 5927 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5928 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 5884449 | 2012-06-30 18:25:32 +0200 | [diff] [blame] | 5929 | ac_cv_prog_READELF="$ac_tool_prefix$ac_prog" |
| 5930 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 5931 | break 2 |
| 5932 | fi |
| 5933 | done |
| 5934 | done |
| 5935 | IFS=$as_save_IFS |
| 5936 | |
| 5937 | fi |
| 5938 | fi |
| 5939 | READELF=$ac_cv_prog_READELF |
| 5940 | if test -n "$READELF"; then |
| 5941 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 |
| 5942 | $as_echo "$READELF" >&6; } |
| 5943 | else |
| 5944 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5945 | $as_echo "no" >&6; } |
| 5946 | fi |
| 5947 | |
| 5948 | |
| 5949 | test -n "$READELF" && break |
| 5950 | done |
| 5951 | fi |
| 5952 | if test -z "$READELF"; then |
| 5953 | ac_ct_READELF=$READELF |
| 5954 | for ac_prog in readelf |
| 5955 | do |
| 5956 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5957 | set dummy $ac_prog; ac_word=$2 |
| 5958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5959 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5960 | if ${ac_cv_prog_ac_ct_READELF+:} false; then : |
| 5961 | $as_echo_n "(cached) " >&6 |
| 5962 | else |
| 5963 | if test -n "$ac_ct_READELF"; then |
| 5964 | ac_cv_prog_ac_ct_READELF="$ac_ct_READELF" # Let the user override the test. |
| 5965 | else |
| 5966 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5967 | for as_dir in $PATH |
| 5968 | do |
| 5969 | IFS=$as_save_IFS |
| 5970 | test -z "$as_dir" && as_dir=. |
| 5971 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 5972 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
doko@ubuntu.com | 5884449 | 2012-06-30 18:25:32 +0200 | [diff] [blame] | 5973 | ac_cv_prog_ac_ct_READELF="$ac_prog" |
| 5974 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 5975 | break 2 |
| 5976 | fi |
| 5977 | done |
| 5978 | done |
| 5979 | IFS=$as_save_IFS |
| 5980 | |
| 5981 | fi |
| 5982 | fi |
| 5983 | ac_ct_READELF=$ac_cv_prog_ac_ct_READELF |
| 5984 | if test -n "$ac_ct_READELF"; then |
| 5985 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_READELF" >&5 |
| 5986 | $as_echo "$ac_ct_READELF" >&6; } |
| 5987 | else |
| 5988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5989 | $as_echo "no" >&6; } |
| 5990 | fi |
| 5991 | |
| 5992 | |
| 5993 | test -n "$ac_ct_READELF" && break |
| 5994 | done |
| 5995 | |
| 5996 | if test "x$ac_ct_READELF" = x; then |
| 5997 | READELF=":" |
| 5998 | else |
| 5999 | case $cross_compiling:$ac_tool_warned in |
| 6000 | yes:) |
| 6001 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 6002 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
| 6003 | ac_tool_warned=yes ;; |
| 6004 | esac |
| 6005 | READELF=$ac_ct_READELF |
| 6006 | fi |
| 6007 | fi |
| 6008 | |
| 6009 | if test "$cross_compiling" = yes; then |
| 6010 | case "$READELF" in |
| 6011 | readelf|:) |
| 6012 | as_fn_error $? "readelf for the host is required for cross builds" "$LINENO" 5 |
| 6013 | ;; |
| 6014 | esac |
| 6015 | fi |
| 6016 | |
| 6017 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6018 | |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6019 | for ac_prog in python$PACKAGE_VERSION python3 python |
| 6020 | do |
| 6021 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6022 | set dummy $ac_prog; ac_word=$2 |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6023 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 6024 | $as_echo_n "checking for $ac_word... " >&6; } |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6025 | if ${ac_cv_prog_PYTHON+:} false; then : |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6026 | $as_echo_n "(cached) " >&6 |
| 6027 | else |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6028 | if test -n "$PYTHON"; then |
| 6029 | ac_cv_prog_PYTHON="$PYTHON" # Let the user override the test. |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6030 | else |
| 6031 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6032 | for as_dir in $PATH |
| 6033 | do |
| 6034 | IFS=$as_save_IFS |
| 6035 | test -z "$as_dir" && as_dir=. |
| 6036 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 6037 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6038 | ac_cv_prog_PYTHON="$ac_prog" |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6039 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 6040 | break 2 |
| 6041 | fi |
| 6042 | done |
| 6043 | done |
| 6044 | IFS=$as_save_IFS |
| 6045 | |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6046 | fi |
| 6047 | fi |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6048 | PYTHON=$ac_cv_prog_PYTHON |
| 6049 | if test -n "$PYTHON"; then |
| 6050 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 |
| 6051 | $as_echo "$PYTHON" >&6; } |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6052 | else |
| 6053 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6054 | $as_echo "no" >&6; } |
| 6055 | fi |
| 6056 | |
| 6057 | |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6058 | test -n "$PYTHON" && break |
| 6059 | done |
| 6060 | test -n "$PYTHON" || PYTHON="not-found" |
| 6061 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 6062 | if test "$PYTHON" = not-found; then |
Matthias Klose | c4c4842 | 2012-10-21 23:05:35 +0200 | [diff] [blame] | 6063 | ASDLGEN="@echo python: $PYTHON! cannot run \$(srcdir)/Parser/asdl_c.py #" |
| 6064 | else |
| 6065 | ASDLGEN="$PYTHON" |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 6066 | fi |
| 6067 | |
| 6068 | |
Kushal Das | 02d23a2 | 2014-04-15 23:50:06 +0530 | [diff] [blame] | 6069 | for ac_prog in python$PACKAGE_VERSION python3 python |
| 6070 | do |
| 6071 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 6072 | set dummy $ac_prog; ac_word=$2 |
| 6073 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 6074 | $as_echo_n "checking for $ac_word... " >&6; } |
| 6075 | if ${ac_cv_prog_PYTHON+:} false; then : |
| 6076 | $as_echo_n "(cached) " >&6 |
| 6077 | else |
| 6078 | if test -n "$PYTHON"; then |
| 6079 | ac_cv_prog_PYTHON="$PYTHON" # Let the user override the test. |
| 6080 | else |
| 6081 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6082 | for as_dir in $PATH |
| 6083 | do |
| 6084 | IFS=$as_save_IFS |
| 6085 | test -z "$as_dir" && as_dir=. |
| 6086 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 6087 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
| 6088 | ac_cv_prog_PYTHON="$ac_prog" |
| 6089 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 6090 | break 2 |
| 6091 | fi |
| 6092 | done |
| 6093 | done |
| 6094 | IFS=$as_save_IFS |
| 6095 | |
| 6096 | fi |
| 6097 | fi |
| 6098 | PYTHON=$ac_cv_prog_PYTHON |
| 6099 | if test -n "$PYTHON"; then |
| 6100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 |
| 6101 | $as_echo "$PYTHON" >&6; } |
| 6102 | else |
| 6103 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6104 | $as_echo "no" >&6; } |
| 6105 | fi |
| 6106 | |
| 6107 | |
| 6108 | test -n "$PYTHON" && break |
| 6109 | done |
| 6110 | test -n "$PYTHON" || PYTHON="not-found" |
| 6111 | |
| 6112 | if test "$PYTHON" = not-found; then |
| 6113 | OPCODEHGEN="@echo python: $PYTHON! cannot run Tools/scripts/generate_opcode_h.py" |
| 6114 | else |
| 6115 | OPCODEHGEN="$PYTHON" |
| 6116 | fi |
| 6117 | |
| 6118 | |
| 6119 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6120 | case $MACHDEP in |
| 6121 | bsdos*|hp*|HP*) |
| 6122 | # install -d does not work on BSDI or HP-UX |
| 6123 | if test -z "$INSTALL" |
| 6124 | then |
| 6125 | INSTALL="${srcdir}/install-sh -c" |
| 6126 | fi |
| 6127 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6128 | # Find a good install program. We prefer a C program (faster), |
| 6129 | # so one script is as good as another. But avoid the broken or |
| 6130 | # incompatible versions: |
| 6131 | # SysV /etc/install, /usr/sbin/install |
| 6132 | # SunOS /usr/etc/install |
| 6133 | # IRIX /sbin/install |
| 6134 | # AIX /bin/install |
| 6135 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 6136 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 6137 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 6138 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 6139 | # OS/2's system install, which has a completely different semantic |
| 6140 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6141 | # Reject install programs that cannot install multiple files. |
| 6142 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 6143 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6144 | if test -z "$INSTALL"; then |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6145 | if ${ac_cv_path_install+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6146 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6147 | else |
| 6148 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6149 | for as_dir in $PATH |
| 6150 | do |
| 6151 | IFS=$as_save_IFS |
| 6152 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6153 | # Account for people who put trailing slashes in PATH elements. |
| 6154 | case $as_dir/ in #(( |
| 6155 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6156 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6157 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6158 | /usr/ucb/* ) ;; |
| 6159 | *) |
| 6160 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 6161 | # Don't use installbsd from OSF since it installs stuff as root |
| 6162 | # by default. |
| 6163 | for ac_prog in ginstall scoinst install; do |
| 6164 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 6165 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6166 | if test $ac_prog = install && |
| 6167 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 6168 | # AIX install. It has an incompatible calling convention. |
| 6169 | : |
| 6170 | elif test $ac_prog = install && |
| 6171 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 6172 | # program-specific install script used by HP pwplus--don't use. |
| 6173 | : |
| 6174 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6175 | rm -rf conftest.one conftest.two conftest.dir |
| 6176 | echo one > conftest.one |
| 6177 | echo two > conftest.two |
| 6178 | mkdir conftest.dir |
| 6179 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 6180 | test -s conftest.one && test -s conftest.two && |
| 6181 | test -s conftest.dir/conftest.one && |
| 6182 | test -s conftest.dir/conftest.two |
| 6183 | then |
| 6184 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 6185 | break 3 |
| 6186 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6187 | fi |
| 6188 | fi |
| 6189 | done |
| 6190 | done |
| 6191 | ;; |
| 6192 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6193 | |
| 6194 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6195 | IFS=$as_save_IFS |
| 6196 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6197 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6198 | |
| 6199 | fi |
| 6200 | if test "${ac_cv_path_install+set}" = set; then |
| 6201 | INSTALL=$ac_cv_path_install |
| 6202 | else |
| 6203 | # As a last resort, use the slow shell script. Don't cache a |
| 6204 | # value for INSTALL within a source directory, because that will |
| 6205 | # break other packages using the cache if that directory is |
| 6206 | # removed, or if the value is a relative name. |
| 6207 | INSTALL=$ac_install_sh |
| 6208 | fi |
| 6209 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6210 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 6211 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6212 | |
| 6213 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 6214 | # It thinks the first close brace ends the variable substitution. |
| 6215 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 6216 | |
| 6217 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 6218 | |
| 6219 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 6220 | |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 6221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 |
| 6222 | $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } |
| 6223 | if test -z "$MKDIR_P"; then |
| 6224 | if ${ac_cv_path_mkdir+:} false; then : |
| 6225 | $as_echo_n "(cached) " >&6 |
| 6226 | else |
| 6227 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 6228 | for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin |
| 6229 | do |
| 6230 | IFS=$as_save_IFS |
| 6231 | test -z "$as_dir" && as_dir=. |
| 6232 | for ac_prog in mkdir gmkdir; do |
| 6233 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 6234 | as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 6235 | case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( |
| 6236 | 'mkdir (GNU coreutils) '* | \ |
| 6237 | 'mkdir (coreutils) '* | \ |
| 6238 | 'mkdir (fileutils) '4.1*) |
| 6239 | ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext |
| 6240 | break 3;; |
| 6241 | esac |
| 6242 | done |
| 6243 | done |
| 6244 | done |
| 6245 | IFS=$as_save_IFS |
| 6246 | |
| 6247 | fi |
| 6248 | |
| 6249 | test -d ./--version && rmdir ./--version |
| 6250 | if test "${ac_cv_path_mkdir+set}" = set; then |
| 6251 | MKDIR_P="$ac_cv_path_mkdir -p" |
| 6252 | else |
| 6253 | # As a last resort, use the slow shell script. Don't cache a |
| 6254 | # value for MKDIR_P within a source directory, because that will |
| 6255 | # break other packages using the cache if that directory is |
| 6256 | # removed, or if the value is a relative name. |
| 6257 | MKDIR_P="$ac_install_sh -d" |
| 6258 | fi |
| 6259 | fi |
| 6260 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 |
| 6261 | $as_echo "$MKDIR_P" >&6; } |
| 6262 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6263 | |
| 6264 | # Not every filesystem supports hard links |
| 6265 | |
| 6266 | if test -z "$LN" ; then |
| 6267 | case $ac_sys_system in |
| 6268 | CYGWIN*) LN="ln -s";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6269 | *) LN=ln;; |
| 6270 | esac |
| 6271 | fi |
| 6272 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 6273 | # For calculating the .so ABI tag. |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 6274 | |
| 6275 | ABIFLAGS="" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 6276 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6277 | # Check for --with-pydebug |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6278 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 6279 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6280 | |
| 6281 | # Check whether --with-pydebug was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6282 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6283 | withval=$with_pydebug; |
| 6284 | if test "$withval" != no |
| 6285 | then |
| 6286 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6287 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6288 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 6290 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6291 | Py_DEBUG='true' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 6292 | ABIFLAGS="${ABIFLAGS}d" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6293 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6294 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6295 | fi |
| 6296 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 6298 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6299 | fi |
| 6300 | |
| 6301 | |
| 6302 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 6303 | # merged with this chunk of code? |
| 6304 | |
| 6305 | # Optimizer/debugger flags |
| 6306 | # ------------------------ |
| 6307 | # (The following bit of code is complicated enough - please keep things |
| 6308 | # indented properly. Just pretend you're editing Python code. ;-) |
| 6309 | |
| 6310 | # There are two parallel sets of case statements below, one that checks to |
| 6311 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 6312 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 6313 | # user set OPT. |
| 6314 | |
| 6315 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 6316 | # it on the command line |
| 6317 | |
Benjamin Peterson | 65b4ec5 | 2010-03-23 21:02:34 +0000 | [diff] [blame] | 6318 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6319 | then |
| 6320 | case $GCC in |
| 6321 | yes) |
| 6322 | if test "$CC" != 'g++' ; then |
| 6323 | STRICT_PROTO="-Wstrict-prototypes" |
| 6324 | fi |
| 6325 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 6326 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 6327 | WRAP="-fwrapv" |
| 6328 | fi |
Stefan Krah | 962055d | 2011-09-14 15:14:08 +0200 | [diff] [blame] | 6329 | |
| 6330 | # Clang also needs -fwrapv |
Stefan Krah | af04ff2 | 2011-12-08 22:20:31 +0100 | [diff] [blame] | 6331 | case $CC in |
| 6332 | *clang*) WRAP="-fwrapv" |
| 6333 | ;; |
| 6334 | esac |
Stefan Krah | 962055d | 2011-09-14 15:14:08 +0200 | [diff] [blame] | 6335 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6336 | case $ac_cv_prog_cc_g in |
| 6337 | yes) |
| 6338 | if test "$Py_DEBUG" = 'true' ; then |
| 6339 | # Optimization messes up debuggers, so turn it off for |
| 6340 | # debug builds. |
Antoine Pitrou | 3d6c784 | 2015-02-11 19:39:16 +0100 | [diff] [blame] | 6341 | if "$CC" -v --help 2>/dev/null |grep -- -Og > /dev/null; then |
| 6342 | OPT="-g -Og -Wall $STRICT_PROTO" |
| 6343 | else |
| 6344 | OPT="-g -O0 -Wall $STRICT_PROTO" |
| 6345 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6346 | else |
| 6347 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 6348 | fi |
| 6349 | ;; |
| 6350 | *) |
| 6351 | OPT="-O3 -Wall $STRICT_PROTO" |
| 6352 | ;; |
| 6353 | esac |
| 6354 | case $ac_sys_system in |
| 6355 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 6356 | ;; |
| 6357 | esac |
| 6358 | ;; |
| 6359 | |
| 6360 | *) |
| 6361 | OPT="-O" |
| 6362 | ;; |
| 6363 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6364 | fi |
| 6365 | |
| 6366 | |
| 6367 | |
Benjamin Peterson | acb8c52 | 2014-08-09 20:01:49 -0700 | [diff] [blame] | 6368 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6369 | # The -arch flags for universal builds on OSX |
| 6370 | UNIVERSAL_ARCH_FLAGS= |
| 6371 | |
| 6372 | |
| 6373 | # tweak BASECFLAGS based on compiler and platform |
| 6374 | case $GCC in |
| 6375 | yes) |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6376 | # Python doesn't violate C99 aliasing rules, but older versions of |
| 6377 | # GCC produce warnings for legal Python code. Enable |
| 6378 | # -fno-strict-aliasing on versions of GCC that support but produce |
| 6379 | # warnings. See Issue3326 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6380 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5 |
| 6381 | $as_echo_n "checking whether $CC accepts and needs -fno-strict-aliasing... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6382 | ac_save_cc="$CC" |
| 6383 | CC="$CC -fno-strict-aliasing" |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6384 | save_CFLAGS="$CFLAGS" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6385 | if ${ac_cv_no_strict_aliasing+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6386 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 6387 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6388 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6389 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 6390 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6391 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 6392 | int |
| 6393 | main () |
| 6394 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 6395 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 6396 | ; |
| 6397 | return 0; |
| 6398 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6399 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6400 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6401 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6402 | |
| 6403 | CC="$ac_save_cc -fstrict-aliasing" |
| 6404 | CFLAGS="$CFLAGS -Werror -Wstrict-aliasing" |
| 6405 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6406 | /* end confdefs.h. */ |
| 6407 | |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 6408 | void f(int **x) {} |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6409 | int |
| 6410 | main () |
| 6411 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 6412 | double *x; f((int **) &x); |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6413 | ; |
| 6414 | return 0; |
| 6415 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6416 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6417 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6418 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6419 | |
| 6420 | ac_cv_no_strict_aliasing=no |
| 6421 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6422 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6423 | |
| 6424 | ac_cv_no_strict_aliasing=yes |
| 6425 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6426 | fi |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6427 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6428 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6429 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6430 | |
| 6431 | ac_cv_no_strict_aliasing=no |
| 6432 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6433 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 6434 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 6435 | fi |
| 6436 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6437 | CFLAGS="$save_CFLAGS" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6438 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6439 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5 |
| 6440 | $as_echo "$ac_cv_no_strict_aliasing" >&6; } |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 6441 | if test $ac_cv_no_strict_aliasing = yes |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6442 | then |
| 6443 | BASECFLAGS="$BASECFLAGS -fno-strict-aliasing" |
| 6444 | fi |
| 6445 | |
Benjamin Peterson | 7ddbf10 | 2011-09-23 13:23:22 -0400 | [diff] [blame] | 6446 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn off $CC unused result warning" >&5 |
| 6447 | $as_echo_n "checking if we can turn off $CC unused result warning... " >&6; } |
| 6448 | ac_save_cc="$CC" |
| 6449 | CC="$CC -Wunused-result -Werror" |
| 6450 | save_CFLAGS="$CFLAGS" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6451 | if ${ac_cv_disable_unused_result_warning+:} false; then : |
Benjamin Peterson | 7ddbf10 | 2011-09-23 13:23:22 -0400 | [diff] [blame] | 6452 | $as_echo_n "(cached) " >&6 |
| 6453 | else |
| 6454 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6455 | /* end confdefs.h. */ |
| 6456 | |
| 6457 | |
| 6458 | int |
| 6459 | main () |
| 6460 | { |
| 6461 | |
| 6462 | ; |
| 6463 | return 0; |
| 6464 | } |
| 6465 | |
| 6466 | _ACEOF |
| 6467 | if ac_fn_c_try_compile "$LINENO"; then : |
| 6468 | |
| 6469 | ac_cv_disable_unused_result_warning=yes |
| 6470 | |
| 6471 | else |
| 6472 | |
| 6473 | ac_cv_disable_unused_result_warning=no |
| 6474 | |
| 6475 | fi |
| 6476 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6477 | fi |
| 6478 | |
| 6479 | CFLAGS="$save_CFLAGS" |
| 6480 | CC="$ac_save_cc" |
| 6481 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_disable_unused_result_warning" >&5 |
| 6482 | $as_echo "$ac_cv_disable_unused_result_warning" >&6; } |
| 6483 | |
| 6484 | if test $ac_cv_disable_unused_result_warning = yes |
| 6485 | then |
| 6486 | BASECFLAGS="$BASECFLAGS -Wno-unused-result" |
| 6487 | fi |
| 6488 | |
Benjamin Peterson | cc00e01 | 2013-05-20 08:22:04 -0700 | [diff] [blame] | 6489 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Werror=declaration-after-statement" >&5 |
| 6490 | $as_echo_n "checking for -Werror=declaration-after-statement... " >&6; } |
| 6491 | ac_save_cc="$CC" |
| 6492 | CC="$CC -Werror=declaration-after-statement" |
| 6493 | save_CFLAGS="$CFLAGS" |
| 6494 | if ${ac_cv_declaration_after_statement_warning+:} false; then : |
| 6495 | $as_echo_n "(cached) " >&6 |
| 6496 | else |
| 6497 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6498 | /* end confdefs.h. */ |
| 6499 | |
| 6500 | |
| 6501 | int |
| 6502 | main () |
| 6503 | { |
| 6504 | |
| 6505 | ; |
| 6506 | return 0; |
| 6507 | } |
| 6508 | |
| 6509 | _ACEOF |
| 6510 | if ac_fn_c_try_compile "$LINENO"; then : |
| 6511 | |
| 6512 | ac_cv_declaration_after_statement_warning=yes |
| 6513 | |
| 6514 | else |
| 6515 | |
| 6516 | ac_cv_declaration_after_statement_warning=no |
| 6517 | |
| 6518 | fi |
| 6519 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6520 | fi |
| 6521 | |
| 6522 | CFLAGS="$save_CFLAGS" |
| 6523 | CC="$ac_save_cc" |
| 6524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_declaration_after_statement_warning" >&5 |
| 6525 | $as_echo "$ac_cv_declaration_after_statement_warning" >&6; } |
| 6526 | |
| 6527 | if test $ac_cv_declaration_after_statement_warning = yes |
| 6528 | then |
Benjamin Peterson | acb8c52 | 2014-08-09 20:01:49 -0700 | [diff] [blame] | 6529 | CFLAGS_NODIST="$CFLAGS_NODIST -Werror=declaration-after-statement" |
Benjamin Peterson | cc00e01 | 2013-05-20 08:22:04 -0700 | [diff] [blame] | 6530 | fi |
| 6531 | |
Charles-François Natali | 7f9cc93 | 2014-08-01 21:57:49 +0100 | [diff] [blame] | 6532 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC mixed sign comparison warning" >&5 |
| 6533 | $as_echo_n "checking if we can turn on $CC mixed sign comparison warning... " >&6; } |
| 6534 | ac_save_cc="$CC" |
| 6535 | CC="$CC -Wsign-compare" |
| 6536 | save_CFLAGS="$CFLAGS" |
| 6537 | if ${ac_cv_enable_sign_compare_warning+:} false; then : |
| 6538 | $as_echo_n "(cached) " >&6 |
| 6539 | else |
| 6540 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6541 | /* end confdefs.h. */ |
| 6542 | |
| 6543 | |
| 6544 | int |
| 6545 | main () |
| 6546 | { |
| 6547 | |
| 6548 | ; |
| 6549 | return 0; |
| 6550 | } |
| 6551 | |
| 6552 | _ACEOF |
| 6553 | if ac_fn_c_try_compile "$LINENO"; then : |
| 6554 | |
| 6555 | ac_cv_enable_sign_compare_warning=yes |
| 6556 | |
| 6557 | else |
| 6558 | |
| 6559 | ac_cv_enable_sign_compare_warning=no |
| 6560 | |
| 6561 | fi |
| 6562 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6563 | fi |
| 6564 | |
| 6565 | CFLAGS="$save_CFLAGS" |
| 6566 | CC="$ac_save_cc" |
| 6567 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_sign_compare_warning" >&5 |
| 6568 | $as_echo "$ac_cv_enable_sign_compare_warning" >&6; } |
| 6569 | |
| 6570 | if test $ac_cv_enable_sign_compare_warning = yes |
| 6571 | then |
| 6572 | BASECFLAGS="$BASECFLAGS -Wsign-compare" |
| 6573 | fi |
| 6574 | |
| 6575 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can turn on $CC unreachable code warning" >&5 |
| 6576 | $as_echo_n "checking if we can turn on $CC unreachable code warning... " >&6; } |
| 6577 | ac_save_cc="$CC" |
| 6578 | CC="$CC -Wunreachable-code" |
| 6579 | save_CFLAGS="$CFLAGS" |
| 6580 | if ${ac_cv_enable_unreachable_code_warning+:} false; then : |
| 6581 | $as_echo_n "(cached) " >&6 |
| 6582 | else |
| 6583 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 6584 | /* end confdefs.h. */ |
| 6585 | |
| 6586 | |
| 6587 | int |
| 6588 | main () |
| 6589 | { |
| 6590 | |
| 6591 | ; |
| 6592 | return 0; |
| 6593 | } |
| 6594 | |
| 6595 | _ACEOF |
| 6596 | if ac_fn_c_try_compile "$LINENO"; then : |
| 6597 | |
| 6598 | ac_cv_enable_unreachable_code_warning=yes |
| 6599 | |
| 6600 | else |
| 6601 | |
| 6602 | ac_cv_enable_unreachable_code_warning=no |
| 6603 | |
| 6604 | fi |
| 6605 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6606 | fi |
| 6607 | |
| 6608 | CFLAGS="$save_CFLAGS" |
| 6609 | CC="$ac_save_cc" |
| 6610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_enable_unreachable_code_warning" >&5 |
| 6611 | $as_echo "$ac_cv_enable_unreachable_code_warning" >&6; } |
| 6612 | |
| 6613 | # Don't enable unreachable code warning in debug mode, since it usually |
| 6614 | # results in non-standard code paths. |
| 6615 | if test $ac_cv_enable_unreachable_code_warning = yes && test "$Py_DEBUG" != "true" |
| 6616 | then |
| 6617 | BASECFLAGS="$BASECFLAGS -Wunreachable-code" |
| 6618 | fi |
| 6619 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6620 | # if using gcc on alpha, use -mieee to get (near) full IEEE 754 |
| 6621 | # support. Without this, treatment of subnormals doesn't follow |
| 6622 | # the standard. |
Matthias Klose | df2aecb | 2012-03-15 22:19:28 +0100 | [diff] [blame] | 6623 | case $host in |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6624 | alpha*) |
| 6625 | BASECFLAGS="$BASECFLAGS -mieee" |
| 6626 | ;; |
| 6627 | esac |
| 6628 | |
| 6629 | case $ac_sys_system in |
| 6630 | SCO_SV*) |
| 6631 | BASECFLAGS="$BASECFLAGS -m486 -DSCO5" |
| 6632 | ;; |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6633 | |
| 6634 | # is there any other compiler on Darwin besides gcc? |
| 6635 | Darwin*) |
| 6636 | # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd |
| 6637 | # used to be here, but non-Apple gcc doesn't accept them. |
| 6638 | if test "${CC}" = gcc |
| 6639 | then |
| 6640 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6641 | $as_echo_n "checking which compiler should be used... " >&6; } |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6642 | case "${UNIVERSALSDK}" in |
| 6643 | */MacOSX10.4u.sdk) |
| 6644 | # Build using 10.4 SDK, force usage of gcc when the |
| 6645 | # compiler is gcc, otherwise the user will get very |
| 6646 | # confusing error messages when building on OSX 10.6 |
| 6647 | CC=gcc-4.0 |
| 6648 | CPP=cpp-4.0 |
| 6649 | ;; |
| 6650 | esac |
| 6651 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6652 | $as_echo "$CC" >&6; } |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6653 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6654 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6655 | if test "${enable_universalsdk}" |
| 6656 | then |
| 6657 | case "$UNIVERSAL_ARCHS" in |
| 6658 | 32-bit) |
| 6659 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 6660 | LIPO_32BIT_FLAGS="" |
| 6661 | ARCH_RUN_32BIT="" |
| 6662 | ;; |
| 6663 | 64-bit) |
| 6664 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
| 6665 | LIPO_32BIT_FLAGS="" |
| 6666 | ARCH_RUN_32BIT="true" |
| 6667 | ;; |
| 6668 | all) |
| 6669 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
| 6670 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
| 6671 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
| 6672 | ;; |
| 6673 | intel) |
| 6674 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
| 6675 | LIPO_32BIT_FLAGS="-extract i386" |
| 6676 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
| 6677 | ;; |
| 6678 | intel-32) |
| 6679 | UNIVERSAL_ARCH_FLAGS="-arch i386" |
| 6680 | LIPO_32BIT_FLAGS="" |
| 6681 | ARCH_RUN_32BIT="" |
| 6682 | ;; |
| 6683 | 3-way) |
| 6684 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
| 6685 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
| 6686 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
| 6687 | ;; |
| 6688 | *) |
| 6689 | as_fn_error $? "proper usage is --with-universal-arch=32-bit|64-bit|all|intel|3-way" "$LINENO" 5 |
| 6690 | ;; |
| 6691 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6692 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6693 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 6694 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
| 6695 | if test "${UNIVERSALSDK}" != "/" |
| 6696 | then |
| 6697 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
| 6698 | fi |
| 6699 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6700 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6701 | # Calculate an appropriate deployment target for this build: |
| 6702 | # The deployment target value is used explicitly to enable certain |
| 6703 | # features are enabled (such as builtin libedit support for readline) |
| 6704 | # through the use of Apple's Availabiliy Macros and is used as a |
| 6705 | # component of the string returned by distutils.get_platform(). |
| 6706 | # |
| 6707 | # Use the value from: |
| 6708 | # 1. the MACOSX_DEPLOYMENT_TARGET environment variable if specified |
| 6709 | # 2. the operating system version of the build machine if >= 10.6 |
| 6710 | # 3. If running on OS X 10.3 through 10.5, use the legacy tests |
| 6711 | # below to pick either 10.3, 10.4, or 10.5 as the target. |
| 6712 | # 4. If we are running on OS X 10.2 or earlier, good luck! |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6713 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which MACOSX_DEPLOYMENT_TARGET to use" >&5 |
| 6715 | $as_echo_n "checking which MACOSX_DEPLOYMENT_TARGET to use... " >&6; } |
Ned Deily | 36820b6 | 2014-06-25 13:44:22 -0700 | [diff] [blame] | 6716 | cur_target_major=`sw_vers -productVersion | \ |
| 6717 | sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'` |
| 6718 | cur_target_minor=`sw_vers -productVersion | \ |
| 6719 | sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'` |
| 6720 | cur_target="${cur_target_major}.${cur_target_minor}" |
| 6721 | if test ${cur_target_major} -eq 10 && \ |
| 6722 | test ${cur_target_minor} -ge 3 && \ |
| 6723 | test ${cur_target_minor} -le 5 |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6724 | then |
Ned Deily | 36820b6 | 2014-06-25 13:44:22 -0700 | [diff] [blame] | 6725 | # OS X 10.3 through 10.5 |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6726 | cur_target=10.3 |
| 6727 | if test ${enable_universalsdk} |
| 6728 | then |
| 6729 | case "$UNIVERSAL_ARCHS" in |
| 6730 | all|3-way|intel|64-bit) |
| 6731 | # These configurations were first supported in 10.5 |
| 6732 | cur_target='10.5' |
| 6733 | ;; |
| 6734 | esac |
| 6735 | else |
| 6736 | if test `/usr/bin/arch` = "i386" |
| 6737 | then |
| 6738 | # 10.4 was the first release to support Intel archs |
| 6739 | cur_target="10.4" |
| 6740 | fi |
| 6741 | fi |
| 6742 | fi |
| 6743 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 6744 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6745 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 6746 | # environment with a value that is the same as what we'll use |
| 6747 | # in the Makefile to ensure that we'll get the same compiler |
| 6748 | # environment during configure and build time. |
| 6749 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 6750 | export MACOSX_DEPLOYMENT_TARGET |
| 6751 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 6752 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACOSX_DEPLOYMENT_TARGET" >&5 |
| 6753 | $as_echo "$MACOSX_DEPLOYMENT_TARGET" >&6; } |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 6754 | |
Ned Deily | 87adb6e | 2013-10-18 21:09:56 -0700 | [diff] [blame] | 6755 | # end of Darwin* tests |
| 6756 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6757 | esac |
| 6758 | ;; |
| 6759 | |
| 6760 | *) |
| 6761 | case $ac_sys_system in |
| 6762 | OpenUNIX*|UnixWare*) |
| 6763 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 6764 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6765 | SCO_SV*) |
| 6766 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 6767 | ;; |
| 6768 | esac |
| 6769 | ;; |
| 6770 | esac |
| 6771 | |
| 6772 | if test "$Py_DEBUG" = 'true'; then |
| 6773 | : |
| 6774 | else |
| 6775 | OPT="-DNDEBUG $OPT" |
| 6776 | fi |
| 6777 | |
| 6778 | if test "$ac_arch_flags" |
| 6779 | then |
| 6780 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 6781 | fi |
| 6782 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6783 | # On some compilers, pthreads are available without further options |
| 6784 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 6785 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 6786 | # So we have to see first whether pthreads are available without |
| 6787 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6788 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 6789 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6790 | if ${ac_cv_pthread_is_default+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6791 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6793 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6794 | ac_cv_pthread_is_default=no |
| 6795 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6796 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6797 | /* end confdefs.h. */ |
| 6798 | |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 6799 | #include <stdio.h> |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6800 | #include <pthread.h> |
| 6801 | |
| 6802 | void* routine(void* p){return NULL;} |
| 6803 | |
| 6804 | int main(){ |
| 6805 | pthread_t p; |
| 6806 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 6807 | return 1; |
| 6808 | (void)pthread_detach(p); |
| 6809 | return 0; |
| 6810 | } |
| 6811 | |
| 6812 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6813 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6814 | |
| 6815 | ac_cv_pthread_is_default=yes |
| 6816 | ac_cv_kthread=no |
| 6817 | ac_cv_pthread=no |
| 6818 | |
| 6819 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6820 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6821 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6822 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6823 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6824 | fi |
| 6825 | |
| 6826 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6827 | fi |
| 6828 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6829 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 6830 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6831 | |
| 6832 | |
| 6833 | if test $ac_cv_pthread_is_default = yes |
| 6834 | then |
| 6835 | ac_cv_kpthread=no |
| 6836 | else |
| 6837 | # -Kpthread, if available, provides the right #defines |
| 6838 | # and linker options to make pthread_create available |
| 6839 | # Some compilers won't report that they do not support -Kpthread, |
| 6840 | # so we need to run a program to see whether it really made the |
| 6841 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6842 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 6843 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6844 | if ${ac_cv_kpthread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6845 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6846 | else |
| 6847 | ac_save_cc="$CC" |
| 6848 | CC="$CC -Kpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6849 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6850 | ac_cv_kpthread=no |
| 6851 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6852 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6853 | /* end confdefs.h. */ |
| 6854 | |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 6855 | #include <stdio.h> |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6856 | #include <pthread.h> |
| 6857 | |
| 6858 | void* routine(void* p){return NULL;} |
| 6859 | |
| 6860 | int main(){ |
| 6861 | pthread_t p; |
| 6862 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 6863 | return 1; |
| 6864 | (void)pthread_detach(p); |
| 6865 | return 0; |
| 6866 | } |
| 6867 | |
| 6868 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6869 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6870 | ac_cv_kpthread=yes |
| 6871 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6872 | ac_cv_kpthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6873 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6874 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6875 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6876 | fi |
| 6877 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6878 | CC="$ac_save_cc" |
| 6879 | fi |
| 6880 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6881 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 6882 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6883 | fi |
| 6884 | |
| 6885 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 6886 | then |
| 6887 | # -Kthread, if available, provides the right #defines |
| 6888 | # and linker options to make pthread_create available |
| 6889 | # Some compilers won't report that they do not support -Kthread, |
| 6890 | # so we need to run a program to see whether it really made the |
| 6891 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6892 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 6893 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 6894 | if ${ac_cv_kthread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6895 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6896 | else |
| 6897 | ac_save_cc="$CC" |
| 6898 | CC="$CC -Kthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6899 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6900 | ac_cv_kthread=no |
| 6901 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6902 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6903 | /* end confdefs.h. */ |
| 6904 | |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 6905 | #include <stdio.h> |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6906 | #include <pthread.h> |
| 6907 | |
| 6908 | void* routine(void* p){return NULL;} |
| 6909 | |
| 6910 | int main(){ |
| 6911 | pthread_t p; |
| 6912 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 6913 | return 1; |
| 6914 | (void)pthread_detach(p); |
| 6915 | return 0; |
| 6916 | } |
| 6917 | |
| 6918 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6919 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6920 | ac_cv_kthread=yes |
| 6921 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6922 | ac_cv_kthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6923 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6924 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6925 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6926 | fi |
| 6927 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6928 | CC="$ac_save_cc" |
| 6929 | fi |
| 6930 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6931 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 6932 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6933 | fi |
| 6934 | |
| 6935 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 6936 | then |
| 6937 | # -pthread, if available, provides the right #defines |
| 6938 | # and linker options to make pthread_create available |
| 6939 | # Some compilers won't report that they do not support -pthread, |
| 6940 | # so we need to run a program to see whether it really made the |
| 6941 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6942 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 6943 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
doko@python.org | 7981f20 | 2013-01-25 15:33:25 +0100 | [diff] [blame] | 6944 | if ${ac_cv_pthread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6945 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6946 | else |
| 6947 | ac_save_cc="$CC" |
| 6948 | CC="$CC -pthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6949 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6950 | ac_cv_pthread=no |
| 6951 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6952 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6953 | /* end confdefs.h. */ |
| 6954 | |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 6955 | #include <stdio.h> |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6956 | #include <pthread.h> |
| 6957 | |
| 6958 | void* routine(void* p){return NULL;} |
| 6959 | |
| 6960 | int main(){ |
| 6961 | pthread_t p; |
| 6962 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 6963 | return 1; |
| 6964 | (void)pthread_detach(p); |
| 6965 | return 0; |
| 6966 | } |
| 6967 | |
| 6968 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6969 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6970 | ac_cv_pthread=yes |
| 6971 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6972 | ac_cv_pthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6973 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6974 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6975 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6976 | fi |
| 6977 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6978 | CC="$ac_save_cc" |
| 6979 | fi |
| 6980 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6981 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 6982 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6983 | fi |
| 6984 | |
| 6985 | # If we have set a CC compiler flag for thread support then |
| 6986 | # check if it works for CXX, too. |
| 6987 | ac_cv_cxx_thread=no |
| 6988 | if test ! -z "$CXX" |
| 6989 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6990 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 6991 | $as_echo_n "checking whether $CXX also accepts flags for thread support... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6992 | ac_save_cxx="$CXX" |
| 6993 | |
| 6994 | if test "$ac_cv_kpthread" = "yes" |
| 6995 | then |
| 6996 | CXX="$CXX -Kpthread" |
| 6997 | ac_cv_cxx_thread=yes |
| 6998 | elif test "$ac_cv_kthread" = "yes" |
| 6999 | then |
| 7000 | CXX="$CXX -Kthread" |
| 7001 | ac_cv_cxx_thread=yes |
| 7002 | elif test "$ac_cv_pthread" = "yes" |
| 7003 | then |
| 7004 | CXX="$CXX -pthread" |
| 7005 | ac_cv_cxx_thread=yes |
| 7006 | fi |
| 7007 | |
| 7008 | if test $ac_cv_cxx_thread = yes |
| 7009 | then |
| 7010 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 7011 | $CXX -c conftest.$ac_ext 2>&5 |
| 7012 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 7013 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 7014 | then |
| 7015 | ac_cv_cxx_thread=yes |
| 7016 | else |
| 7017 | ac_cv_cxx_thread=no |
| 7018 | fi |
| 7019 | rm -fr conftest* |
| 7020 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7021 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 7022 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7023 | fi |
| 7024 | CXX="$ac_save_cxx" |
| 7025 | |
| 7026 | |
| 7027 | # checks for header files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7028 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 7029 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7030 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7031 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7032 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7033 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7034 | /* end confdefs.h. */ |
| 7035 | #include <stdlib.h> |
| 7036 | #include <stdarg.h> |
| 7037 | #include <string.h> |
| 7038 | #include <float.h> |
| 7039 | |
| 7040 | int |
| 7041 | main () |
| 7042 | { |
| 7043 | |
| 7044 | ; |
| 7045 | return 0; |
| 7046 | } |
| 7047 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7048 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7049 | ac_cv_header_stdc=yes |
| 7050 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7051 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7052 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7053 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 7054 | |
| 7055 | if test $ac_cv_header_stdc = yes; then |
| 7056 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7057 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7058 | /* end confdefs.h. */ |
| 7059 | #include <string.h> |
| 7060 | |
| 7061 | _ACEOF |
| 7062 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7063 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 7064 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7065 | else |
| 7066 | ac_cv_header_stdc=no |
| 7067 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 7068 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7069 | |
| 7070 | fi |
| 7071 | |
| 7072 | if test $ac_cv_header_stdc = yes; then |
| 7073 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7074 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7075 | /* end confdefs.h. */ |
| 7076 | #include <stdlib.h> |
| 7077 | |
| 7078 | _ACEOF |
| 7079 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7080 | $EGREP "free" >/dev/null 2>&1; then : |
| 7081 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7082 | else |
| 7083 | ac_cv_header_stdc=no |
| 7084 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 7085 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7086 | |
| 7087 | fi |
| 7088 | |
| 7089 | if test $ac_cv_header_stdc = yes; then |
| 7090 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7091 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7092 | : |
| 7093 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7094 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7095 | /* end confdefs.h. */ |
| 7096 | #include <ctype.h> |
| 7097 | #include <stdlib.h> |
| 7098 | #if ((' ' & 0x0FF) == 0x020) |
| 7099 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 7100 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 7101 | #else |
| 7102 | # define ISLOWER(c) \ |
| 7103 | (('a' <= (c) && (c) <= 'i') \ |
| 7104 | || ('j' <= (c) && (c) <= 'r') \ |
| 7105 | || ('s' <= (c) && (c) <= 'z')) |
| 7106 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 7107 | #endif |
| 7108 | |
| 7109 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 7110 | int |
| 7111 | main () |
| 7112 | { |
| 7113 | int i; |
| 7114 | for (i = 0; i < 256; i++) |
| 7115 | if (XOR (islower (i), ISLOWER (i)) |
| 7116 | || toupper (i) != TOUPPER (i)) |
| 7117 | return 2; |
| 7118 | return 0; |
| 7119 | } |
| 7120 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7121 | if ac_fn_c_try_run "$LINENO"; then : |
| 7122 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7123 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7124 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7125 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7126 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7127 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7128 | fi |
| 7129 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7130 | fi |
| 7131 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7132 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 7133 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7134 | if test $ac_cv_header_stdc = yes; then |
| 7135 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7136 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 7137 | |
| 7138 | fi |
| 7139 | |
doko@ubuntu.com | 1a4f561 | 2014-04-17 20:13:44 +0200 | [diff] [blame] | 7140 | for ac_header in asm/types.h conio.h direct.h dlfcn.h errno.h \ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 7141 | fcntl.h grp.h \ |
doko@ubuntu.com | 1a4f561 | 2014-04-17 20:13:44 +0200 | [diff] [blame] | 7142 | ieeefp.h io.h langinfo.h libintl.h process.h pthread.h \ |
Benjamin Peterson | 94b580d | 2011-08-02 17:30:04 -0500 | [diff] [blame] | 7143 | sched.h shadow.h signal.h stdint.h stropts.h termios.h \ |
Martin v. Löwis | 14e73b1 | 2003-01-01 09:51:12 +0000 | [diff] [blame] | 7144 | unistd.h utime.h \ |
Jesus Cea | d8b9ae6 | 2011-11-14 19:07:41 +0100 | [diff] [blame] | 7145 | poll.h sys/devpoll.h sys/epoll.h sys/poll.h \ |
Antoine Pitrou | bcf2b59 | 2012-02-08 23:28:36 +0100 | [diff] [blame] | 7146 | sys/audioio.h sys/xattr.h sys/bsdtty.h sys/event.h sys/file.h sys/ioctl.h \ |
Martin v. Löwis | 9d6c669 | 2012-02-03 17:44:58 +0100 | [diff] [blame] | 7147 | sys/kern_control.h sys/loadavg.h sys/lock.h sys/mkdev.h sys/modem.h \ |
Jesus Cea | d8b9ae6 | 2011-11-14 19:07:41 +0100 | [diff] [blame] | 7148 | sys/param.h sys/select.h sys/sendfile.h sys/socket.h sys/statvfs.h \ |
Martin v. Löwis | 9d6c669 | 2012-02-03 17:44:58 +0100 | [diff] [blame] | 7149 | sys/stat.h sys/syscall.h sys/sys_domain.h sys/termio.h sys/time.h \ |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 7150 | sys/times.h sys/types.h sys/uio.h sys/un.h sys/utsname.h sys/wait.h pty.h \ |
Gregory P. Smith | 3b1f2c3 | 2011-05-15 12:18:23 -0700 | [diff] [blame] | 7151 | libutil.h sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Christian Heimes | 985ecdc | 2013-11-20 11:46:18 +0100 | [diff] [blame] | 7152 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h alloca.h endian.h \ |
| 7153 | sys/endian.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7154 | do : |
| 7155 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 7156 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7157 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7158 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7159 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7160 | _ACEOF |
| 7161 | |
| 7162 | fi |
| 7163 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7164 | done |
| 7165 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7166 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7167 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7168 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 7169 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 7170 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7171 | if eval \${$as_ac_Header+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7172 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7173 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7174 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7175 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7176 | #include <sys/types.h> |
| 7177 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7178 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7179 | int |
| 7180 | main () |
| 7181 | { |
| 7182 | if ((DIR *) 0) |
| 7183 | return 0; |
| 7184 | ; |
| 7185 | return 0; |
| 7186 | } |
| 7187 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7188 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7189 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7190 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7191 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7192 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7193 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7194 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7195 | eval ac_res=\$$as_ac_Header |
| 7196 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 7197 | $as_echo "$ac_res" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7198 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7199 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7200 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7201 | _ACEOF |
| 7202 | |
| 7203 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7204 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7205 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7206 | done |
| 7207 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 7208 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7209 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 7210 | $as_echo_n "checking for library containing opendir... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7211 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7212 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7213 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7214 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7215 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7216 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7217 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7218 | /* Override any GCC internal prototype to avoid an error. |
| 7219 | Use char because int might match the return type of a GCC |
| 7220 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7221 | #ifdef __cplusplus |
| 7222 | extern "C" |
| 7223 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7224 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7225 | int |
| 7226 | main () |
| 7227 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7228 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7229 | ; |
| 7230 | return 0; |
| 7231 | } |
| 7232 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7233 | for ac_lib in '' dir; do |
| 7234 | if test -z "$ac_lib"; then |
| 7235 | ac_res="none required" |
| 7236 | else |
| 7237 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7238 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7239 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7240 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7241 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7242 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7243 | rm -f core conftest.err conftest.$ac_objext \ |
| 7244 | conftest$ac_exeext |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7245 | if ${ac_cv_search_opendir+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7246 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7247 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7248 | done |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7249 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7250 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7251 | else |
| 7252 | ac_cv_search_opendir=no |
| 7253 | fi |
| 7254 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7255 | LIBS=$ac_func_search_save_LIBS |
| 7256 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7257 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 7258 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7259 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7260 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7261 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7262 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7263 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7264 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7265 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7266 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 7267 | $as_echo_n "checking for library containing opendir... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7268 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7269 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7270 | else |
| 7271 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7272 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7273 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7274 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7275 | /* Override any GCC internal prototype to avoid an error. |
| 7276 | Use char because int might match the return type of a GCC |
| 7277 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7278 | #ifdef __cplusplus |
| 7279 | extern "C" |
| 7280 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7281 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7282 | int |
| 7283 | main () |
| 7284 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7285 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7286 | ; |
| 7287 | return 0; |
| 7288 | } |
| 7289 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7290 | for ac_lib in '' x; do |
| 7291 | if test -z "$ac_lib"; then |
| 7292 | ac_res="none required" |
| 7293 | else |
| 7294 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7295 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7296 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7297 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7298 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7299 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7300 | rm -f core conftest.err conftest.$ac_objext \ |
| 7301 | conftest$ac_exeext |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7302 | if ${ac_cv_search_opendir+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7303 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7304 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7305 | done |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7306 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7307 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7308 | else |
| 7309 | ac_cv_search_opendir=no |
| 7310 | fi |
| 7311 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7312 | LIBS=$ac_func_search_save_LIBS |
| 7313 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7314 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 7315 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7316 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7317 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7318 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7319 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7320 | fi |
| 7321 | |
| 7322 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7323 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7324 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 7325 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7326 | if ${ac_cv_header_sys_types_h_makedev+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7327 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7328 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7329 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7330 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7331 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7332 | int |
| 7333 | main () |
| 7334 | { |
| 7335 | return makedev(0, 0); |
| 7336 | ; |
| 7337 | return 0; |
| 7338 | } |
| 7339 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7340 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7341 | ac_cv_header_sys_types_h_makedev=yes |
| 7342 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7343 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7344 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7345 | rm -f core conftest.err conftest.$ac_objext \ |
| 7346 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7347 | |
| 7348 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 7350 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7351 | |
| 7352 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7353 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7354 | if test "x$ac_cv_header_sys_mkdev_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7355 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7356 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7357 | |
| 7358 | fi |
| 7359 | |
| 7360 | |
| 7361 | |
| 7362 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7363 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7364 | if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7365 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7366 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 7367 | |
| 7368 | fi |
| 7369 | |
| 7370 | |
| 7371 | fi |
| 7372 | fi |
| 7373 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7374 | |
Gregory P. Smith | 3b1f2c3 | 2011-05-15 12:18:23 -0700 | [diff] [blame] | 7375 | # On Darwin (OS X) net/if.h requires sys/socket.h to be imported first. |
| 7376 | for ac_header in net/if.h |
| 7377 | do : |
| 7378 | ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#include <stdio.h> |
| 7379 | #ifdef STDC_HEADERS |
| 7380 | # include <stdlib.h> |
| 7381 | # include <stddef.h> |
| 7382 | #else |
| 7383 | # ifdef HAVE_STDLIB_H |
| 7384 | # include <stdlib.h> |
| 7385 | # endif |
| 7386 | #endif |
| 7387 | #ifdef HAVE_SYS_SOCKET_H |
| 7388 | # include <sys/socket.h> |
| 7389 | #endif |
| 7390 | |
| 7391 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7392 | if test "x$ac_cv_header_net_if_h" = xyes; then : |
Gregory P. Smith | 3b1f2c3 | 2011-05-15 12:18:23 -0700 | [diff] [blame] | 7393 | cat >>confdefs.h <<_ACEOF |
| 7394 | #define HAVE_NET_IF_H 1 |
| 7395 | _ACEOF |
| 7396 | |
| 7397 | fi |
| 7398 | |
| 7399 | done |
| 7400 | |
| 7401 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 7402 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 7403 | for ac_header in linux/netlink.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7404 | do : |
| 7405 | ac_fn_c_check_header_compile "$LINENO" "linux/netlink.h" "ac_cv_header_linux_netlink_h" " |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 7406 | #ifdef HAVE_ASM_TYPES_H |
| 7407 | #include <asm/types.h> |
| 7408 | #endif |
| 7409 | #ifdef HAVE_SYS_SOCKET_H |
| 7410 | #include <sys/socket.h> |
| 7411 | #endif |
| 7412 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7413 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7414 | if test "x$ac_cv_header_linux_netlink_h" = xyes; then : |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 7415 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7416 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 7417 | _ACEOF |
| 7418 | |
| 7419 | fi |
| 7420 | |
| 7421 | done |
| 7422 | |
| 7423 | |
Charles-François Natali | 47413c1 | 2011-10-06 19:47:44 +0200 | [diff] [blame] | 7424 | # On Linux, can.h and can/raw.h require sys/socket.h |
Charles-François Natali | 773e42d | 2013-02-05 19:42:01 +0100 | [diff] [blame] | 7425 | for ac_header in linux/can.h linux/can/raw.h linux/can/bcm.h |
Charles-François Natali | 47413c1 | 2011-10-06 19:47:44 +0200 | [diff] [blame] | 7426 | do : |
| 7427 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 7428 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " |
| 7429 | #ifdef HAVE_SYS_SOCKET_H |
| 7430 | #include <sys/socket.h> |
| 7431 | #endif |
| 7432 | |
| 7433 | " |
| 7434 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
| 7435 | cat >>confdefs.h <<_ACEOF |
| 7436 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 7437 | _ACEOF |
| 7438 | |
| 7439 | fi |
| 7440 | |
| 7441 | done |
| 7442 | |
| 7443 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7444 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7445 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7446 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 7447 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 7448 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7449 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7450 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7451 | |
| 7452 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7453 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7454 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7455 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7456 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7457 | |
| 7458 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7459 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7460 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 7461 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7462 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 7463 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7464 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7465 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 7466 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7467 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7468 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 7469 | $as_echo_n "checking for makedev... " >&6; } |
| 7470 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7471 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7472 | |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 7473 | #if defined(MAJOR_IN_MKDEV) |
| 7474 | #include <sys/mkdev.h> |
| 7475 | #elif defined(MAJOR_IN_SYSMACROS) |
| 7476 | #include <sys/sysmacros.h> |
| 7477 | #else |
| 7478 | #include <sys/types.h> |
| 7479 | #endif |
| 7480 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7481 | int |
| 7482 | main () |
| 7483 | { |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 7484 | |
| 7485 | makedev(0, 0) |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7486 | ; |
| 7487 | return 0; |
| 7488 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7489 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7490 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7491 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7492 | ac_cv_has_makedev=yes |
| 7493 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7494 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7495 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7496 | rm -f core conftest.err conftest.$ac_objext \ |
| 7497 | conftest$ac_exeext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7498 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 7499 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7500 | if test "$ac_cv_has_makedev" = "yes"; then |
| 7501 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7502 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 7503 | |
| 7504 | fi |
| 7505 | |
Christian Heimes | 985ecdc | 2013-11-20 11:46:18 +0100 | [diff] [blame] | 7506 | # byte swapping |
| 7507 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for le64toh" >&5 |
| 7508 | $as_echo_n "checking for le64toh... " >&6; } |
| 7509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7510 | /* end confdefs.h. */ |
| 7511 | |
| 7512 | #ifdef HAVE_ENDIAN_H |
| 7513 | #include <endian.h> |
| 7514 | #elif defined(HAVE_SYS_ENDIAN_H) |
| 7515 | #include <sys/endian.h> |
| 7516 | #endif |
| 7517 | |
| 7518 | int |
| 7519 | main () |
| 7520 | { |
| 7521 | |
| 7522 | le64toh(1) |
| 7523 | ; |
| 7524 | return 0; |
| 7525 | } |
| 7526 | |
| 7527 | _ACEOF |
| 7528 | if ac_fn_c_try_link "$LINENO"; then : |
| 7529 | ac_cv_has_le64toh=yes |
| 7530 | else |
| 7531 | ac_cv_has_le64toh=no |
| 7532 | fi |
| 7533 | rm -f core conftest.err conftest.$ac_objext \ |
| 7534 | conftest$ac_exeext conftest.$ac_ext |
| 7535 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_le64toh" >&5 |
| 7536 | $as_echo "$ac_cv_has_le64toh" >&6; } |
| 7537 | if test "$ac_cv_has_le64toh" = "yes"; then |
| 7538 | |
| 7539 | $as_echo "#define HAVE_HTOLE64 1" >>confdefs.h |
| 7540 | |
| 7541 | fi |
| 7542 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7543 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 7544 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 7545 | # defined, but the compiler does not support pragma redefine_extname, |
| 7546 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 7547 | # structures (such as rlimit64) without declaring them. As a |
| 7548 | # work-around, disable LFS on such configurations |
| 7549 | |
| 7550 | use_lfs=yes |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7551 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 7552 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 7553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7554 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7555 | |
| 7556 | #define _LARGEFILE_SOURCE 1 |
| 7557 | #define _FILE_OFFSET_BITS 64 |
| 7558 | #include <sys/resource.h> |
| 7559 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7560 | int |
| 7561 | main () |
| 7562 | { |
| 7563 | struct rlimit foo; |
| 7564 | ; |
| 7565 | return 0; |
| 7566 | } |
| 7567 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7568 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7569 | sol_lfs_bug=no |
| 7570 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7571 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7572 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7573 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 7575 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7576 | if test "$sol_lfs_bug" = "yes"; then |
| 7577 | use_lfs=no |
| 7578 | fi |
| 7579 | |
| 7580 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 7581 | # Two defines needed to enable largefile support on various platforms |
| 7582 | # These may affect some typedefs |
Georg Brandl | 216e404 | 2011-02-19 08:58:23 +0000 | [diff] [blame] | 7583 | case $ac_sys_system/$ac_sys_release in |
| 7584 | AIX*) |
| 7585 | |
| 7586 | $as_echo "#define _LARGE_FILES 1" >>confdefs.h |
| 7587 | |
| 7588 | ;; |
| 7589 | esac |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 7590 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7591 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7592 | |
| 7593 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7594 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 7595 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 7596 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7597 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 7598 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 7599 | cat >> confdefs.h <<\EOF |
| 7600 | #if defined(SCO_DS) |
| 7601 | #undef _OFF_T |
| 7602 | #endif |
| 7603 | EOF |
| 7604 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7605 | # Type availability checks |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7606 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7607 | if test "x$ac_cv_type_mode_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7608 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7609 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7610 | |
| 7611 | cat >>confdefs.h <<_ACEOF |
| 7612 | #define mode_t int |
| 7613 | _ACEOF |
| 7614 | |
| 7615 | fi |
| 7616 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7617 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7618 | if test "x$ac_cv_type_off_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7619 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7620 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7621 | |
| 7622 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7623 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7624 | _ACEOF |
| 7625 | |
| 7626 | fi |
| 7627 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7628 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7629 | if test "x$ac_cv_type_pid_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7630 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7631 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7632 | |
| 7633 | cat >>confdefs.h <<_ACEOF |
| 7634 | #define pid_t int |
| 7635 | _ACEOF |
| 7636 | |
| 7637 | fi |
| 7638 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7639 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7640 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | bada4c3 | 2010-04-25 21:18:48 +0000 | [diff] [blame] | 7641 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7642 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7643 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7644 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7645 | if test "x$ac_cv_type_size_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7646 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7647 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7648 | |
| 7649 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7650 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7651 | _ACEOF |
| 7652 | |
| 7653 | fi |
| 7654 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7655 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 7656 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7657 | if ${ac_cv_type_uid_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7658 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7659 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7660 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7661 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7662 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7663 | |
| 7664 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7665 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7666 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7667 | ac_cv_type_uid_t=yes |
| 7668 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7669 | ac_cv_type_uid_t=no |
| 7670 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 7671 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7672 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7673 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 7675 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7676 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7677 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7678 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7679 | |
| 7680 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7681 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7682 | |
| 7683 | fi |
| 7684 | |
Mark Dickinson | 983bc16 | 2012-12-02 12:11:38 +0000 | [diff] [blame] | 7685 | |
| 7686 | # There are two separate checks for each of the exact-width integer types we |
| 7687 | # need. First we check whether the type is available using the usual |
| 7688 | # AC_CHECK_TYPE macro with the default includes (which includes <inttypes.h> |
| 7689 | # and <stdint.h> where available). We then also use the special type checks of |
| 7690 | # the form AC_TYPE_UINT32_T, which in the case that uint32_t is not available |
| 7691 | # directly, #define's uint32_t to be a suitable type. |
| 7692 | |
| 7693 | ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default" |
| 7694 | if test "x$ac_cv_type_uint32_t" = xyes; then : |
| 7695 | |
| 7696 | $as_echo "#define HAVE_UINT32_T 1" >>confdefs.h |
| 7697 | |
| 7698 | fi |
| 7699 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7700 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 7701 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7702 | no|yes) ;; #( |
| 7703 | *) |
| 7704 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7705 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7706 | |
| 7707 | |
| 7708 | cat >>confdefs.h <<_ACEOF |
| 7709 | #define uint32_t $ac_cv_c_uint32_t |
| 7710 | _ACEOF |
| 7711 | ;; |
| 7712 | esac |
| 7713 | |
Mark Dickinson | 983bc16 | 2012-12-02 12:11:38 +0000 | [diff] [blame] | 7714 | |
| 7715 | ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default" |
| 7716 | if test "x$ac_cv_type_uint64_t" = xyes; then : |
| 7717 | |
| 7718 | $as_echo "#define HAVE_UINT64_T 1" >>confdefs.h |
| 7719 | |
| 7720 | fi |
| 7721 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7722 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 7723 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7724 | no|yes) ;; #( |
| 7725 | *) |
| 7726 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7727 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7728 | |
| 7729 | |
| 7730 | cat >>confdefs.h <<_ACEOF |
| 7731 | #define uint64_t $ac_cv_c_uint64_t |
| 7732 | _ACEOF |
| 7733 | ;; |
| 7734 | esac |
| 7735 | |
Mark Dickinson | 983bc16 | 2012-12-02 12:11:38 +0000 | [diff] [blame] | 7736 | |
| 7737 | ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default" |
| 7738 | if test "x$ac_cv_type_int32_t" = xyes; then : |
| 7739 | |
| 7740 | $as_echo "#define HAVE_INT32_T 1" >>confdefs.h |
| 7741 | |
| 7742 | fi |
| 7743 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7744 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 7745 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7746 | no|yes) ;; #( |
| 7747 | *) |
| 7748 | |
| 7749 | cat >>confdefs.h <<_ACEOF |
| 7750 | #define int32_t $ac_cv_c_int32_t |
| 7751 | _ACEOF |
| 7752 | ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7753 | esac |
| 7754 | |
Mark Dickinson | 983bc16 | 2012-12-02 12:11:38 +0000 | [diff] [blame] | 7755 | |
| 7756 | ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default" |
| 7757 | if test "x$ac_cv_type_int64_t" = xyes; then : |
| 7758 | |
| 7759 | $as_echo "#define HAVE_INT64_T 1" >>confdefs.h |
| 7760 | |
| 7761 | fi |
| 7762 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7763 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 7764 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 7765 | no|yes) ;; #( |
| 7766 | *) |
| 7767 | |
| 7768 | cat >>confdefs.h <<_ACEOF |
| 7769 | #define int64_t $ac_cv_c_int64_t |
| 7770 | _ACEOF |
| 7771 | ;; |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 7772 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 7773 | |
Mark Dickinson | 983bc16 | 2012-12-02 12:11:38 +0000 | [diff] [blame] | 7774 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7775 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7776 | if test "x$ac_cv_type_ssize_t" = xyes; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7777 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7778 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 7779 | |
| 7780 | fi |
| 7781 | |
Stefan Krah | 1919b7e | 2012-03-21 18:25:23 +0100 | [diff] [blame] | 7782 | ac_fn_c_check_type "$LINENO" "__uint128_t" "ac_cv_type___uint128_t" "$ac_includes_default" |
| 7783 | if test "x$ac_cv_type___uint128_t" = xyes; then : |
| 7784 | |
| 7785 | $as_echo "#define HAVE_GCC_UINT128_T 1" >>confdefs.h |
| 7786 | |
| 7787 | fi |
| 7788 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 7789 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7790 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 7791 | # ANSI C requires sizeof(char) == 1, so no need to check it |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7792 | # The cast to long int works around a bug in the HP C Compiler |
| 7793 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7794 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7795 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7796 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 7797 | $as_echo_n "checking size of int... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7798 | if ${ac_cv_sizeof_int+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7799 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7800 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7801 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7802 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7803 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7804 | if test "$ac_cv_type_int" = yes; then |
| 7805 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7806 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7807 | as_fn_error 77 "cannot compute sizeof (int) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7808 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7809 | else |
| 7810 | ac_cv_sizeof_int=0 |
| 7811 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7812 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7813 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7814 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7815 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 7816 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7817 | |
| 7818 | |
| 7819 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7820 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7821 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7822 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7823 | |
| 7824 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7825 | # The cast to long int works around a bug in the HP C Compiler |
| 7826 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7827 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7828 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7829 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 7830 | $as_echo_n "checking size of long... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7831 | if ${ac_cv_sizeof_long+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7832 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7833 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7834 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7835 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7836 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7837 | if test "$ac_cv_type_long" = yes; then |
| 7838 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7839 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7840 | as_fn_error 77 "cannot compute sizeof (long) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7841 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7842 | else |
| 7843 | ac_cv_sizeof_long=0 |
| 7844 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7845 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7846 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7847 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 7849 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7850 | |
| 7851 | |
| 7852 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7853 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7854 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7855 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7856 | |
| 7857 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7858 | # The cast to long int works around a bug in the HP C Compiler |
| 7859 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7860 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7861 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7862 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 7863 | $as_echo_n "checking size of void *... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7864 | if ${ac_cv_sizeof_void_p+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7865 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7866 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7867 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7868 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7869 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7870 | if test "$ac_cv_type_void_p" = yes; then |
| 7871 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7872 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7873 | as_fn_error 77 "cannot compute sizeof (void *) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7874 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7875 | else |
| 7876 | ac_cv_sizeof_void_p=0 |
| 7877 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7878 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7879 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7880 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7881 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 7882 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7883 | |
| 7884 | |
| 7885 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7886 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 7887 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7888 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 7889 | |
| 7890 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7891 | # The cast to long int works around a bug in the HP C Compiler |
| 7892 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7893 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7894 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7895 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 7896 | $as_echo_n "checking size of short... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7897 | if ${ac_cv_sizeof_short+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7898 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7899 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7900 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7901 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7902 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7903 | if test "$ac_cv_type_short" = yes; then |
| 7904 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7905 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7906 | as_fn_error 77 "cannot compute sizeof (short) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7907 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7908 | else |
| 7909 | ac_cv_sizeof_short=0 |
| 7910 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7911 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7912 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7913 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7914 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 7915 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7916 | |
| 7917 | |
| 7918 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7919 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7920 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7921 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7922 | |
| 7923 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7924 | # The cast to long int works around a bug in the HP C Compiler |
| 7925 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7926 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7927 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7928 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 7929 | $as_echo_n "checking size of float... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7930 | if ${ac_cv_sizeof_float+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7931 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7932 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7933 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (float))" "ac_cv_sizeof_float" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7934 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7935 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7936 | if test "$ac_cv_type_float" = yes; then |
| 7937 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7938 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7939 | as_fn_error 77 "cannot compute sizeof (float) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7940 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7941 | else |
| 7942 | ac_cv_sizeof_float=0 |
| 7943 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7944 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7945 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7946 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 7948 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7949 | |
| 7950 | |
| 7951 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7952 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7953 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7954 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7955 | |
| 7956 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7957 | # The cast to long int works around a bug in the HP C Compiler |
| 7958 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7959 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7960 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7961 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 7962 | $as_echo_n "checking size of double... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7963 | if ${ac_cv_sizeof_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7964 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7965 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7966 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7967 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7968 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7969 | if test "$ac_cv_type_double" = yes; then |
| 7970 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7971 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 7972 | as_fn_error 77 "cannot compute sizeof (double) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7973 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7974 | else |
| 7975 | ac_cv_sizeof_double=0 |
| 7976 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7977 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7978 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7979 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7980 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 7981 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7982 | |
| 7983 | |
| 7984 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7985 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7986 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7987 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 7988 | |
| 7989 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7990 | # The cast to long int works around a bug in the HP C Compiler |
| 7991 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7992 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7993 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7994 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 7995 | $as_echo_n "checking size of fpos_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 7996 | if ${ac_cv_sizeof_fpos_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7997 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7998 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7999 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (fpos_t))" "ac_cv_sizeof_fpos_t" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8000 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8001 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8002 | if test "$ac_cv_type_fpos_t" = yes; then |
| 8003 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8004 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8005 | as_fn_error 77 "cannot compute sizeof (fpos_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8006 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8007 | else |
| 8008 | ac_cv_sizeof_fpos_t=0 |
| 8009 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8010 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8011 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8012 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 8014 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8015 | |
| 8016 | |
| 8017 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8018 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8019 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8020 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8021 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8022 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8023 | # The cast to long int works around a bug in the HP C Compiler |
| 8024 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8025 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8026 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8027 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 8028 | $as_echo_n "checking size of size_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8029 | if ${ac_cv_sizeof_size_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8030 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8031 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8032 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8033 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8034 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8035 | if test "$ac_cv_type_size_t" = yes; then |
| 8036 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8037 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8038 | as_fn_error 77 "cannot compute sizeof (size_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8039 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8040 | else |
| 8041 | ac_cv_sizeof_size_t=0 |
| 8042 | fi |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8043 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8044 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8045 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 |
| 8047 | $as_echo "$ac_cv_sizeof_size_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8048 | |
| 8049 | |
| 8050 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 8051 | cat >>confdefs.h <<_ACEOF |
| 8052 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t |
| 8053 | _ACEOF |
| 8054 | |
| 8055 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8056 | # The cast to long int works around a bug in the HP C Compiler |
| 8057 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8058 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8059 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8060 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5 |
| 8061 | $as_echo_n "checking size of pid_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8062 | if ${ac_cv_sizeof_pid_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8063 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8064 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8065 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pid_t))" "ac_cv_sizeof_pid_t" "$ac_includes_default"; then : |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8066 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8067 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8068 | if test "$ac_cv_type_pid_t" = yes; then |
| 8069 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8070 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8071 | as_fn_error 77 "cannot compute sizeof (pid_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8072 | See \`config.log' for more details" "$LINENO" 5; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8073 | else |
| 8074 | ac_cv_sizeof_pid_t=0 |
| 8075 | fi |
| 8076 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8077 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8078 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8079 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 8080 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 8081 | |
| 8082 | |
| 8083 | |
| 8084 | cat >>confdefs.h <<_ACEOF |
| 8085 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 8086 | _ACEOF |
| 8087 | |
| 8088 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8089 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8090 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 8091 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8092 | have_long_long=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8093 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8094 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8095 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8096 | int |
| 8097 | main () |
| 8098 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8099 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8100 | ; |
| 8101 | return 0; |
| 8102 | } |
| 8103 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8104 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8105 | |
| 8106 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8107 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8108 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 8109 | have_long_long=yes |
| 8110 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8111 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8112 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 8114 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 8115 | if test "$have_long_long" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8116 | # The cast to long int works around a bug in the HP C Compiler |
| 8117 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8118 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8119 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8120 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 8121 | $as_echo_n "checking size of long long... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8122 | if ${ac_cv_sizeof_long_long+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8123 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8124 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8125 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8126 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8127 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8128 | if test "$ac_cv_type_long_long" = yes; then |
| 8129 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8130 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8131 | as_fn_error 77 "cannot compute sizeof (long long) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8132 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8133 | else |
| 8134 | ac_cv_sizeof_long_long=0 |
| 8135 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8136 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8137 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8138 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8139 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 8140 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8141 | |
| 8142 | |
| 8143 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8144 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8145 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8146 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8147 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8148 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8149 | fi |
| 8150 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8151 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 8152 | $as_echo_n "checking for long double support... " >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8153 | have_long_double=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8154 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8155 | /* end confdefs.h. */ |
| 8156 | |
| 8157 | int |
| 8158 | main () |
| 8159 | { |
| 8160 | long double x; x = (long double)0; |
| 8161 | ; |
| 8162 | return 0; |
| 8163 | } |
| 8164 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8165 | if ac_fn_c_try_compile "$LINENO"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8166 | |
| 8167 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8168 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8169 | |
| 8170 | have_long_double=yes |
| 8171 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8172 | fi |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8173 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8174 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 8175 | $as_echo "$have_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8176 | if test "$have_long_double" = yes ; then |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8177 | # The cast to long int works around a bug in the HP C Compiler |
| 8178 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8179 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8180 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8181 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 8182 | $as_echo_n "checking size of long double... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8183 | if ${ac_cv_sizeof_long_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8184 | $as_echo_n "(cached) " >&6 |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8185 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8186 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double" "$ac_includes_default"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8187 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8188 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8189 | if test "$ac_cv_type_long_double" = yes; then |
| 8190 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8191 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8192 | as_fn_error 77 "cannot compute sizeof (long double) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8193 | See \`config.log' for more details" "$LINENO" 5; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8194 | else |
| 8195 | ac_cv_sizeof_long_double=0 |
| 8196 | fi |
| 8197 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8198 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8199 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8200 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 8201 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 8202 | |
| 8203 | |
| 8204 | |
| 8205 | cat >>confdefs.h <<_ACEOF |
| 8206 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 8207 | _ACEOF |
| 8208 | |
| 8209 | |
| 8210 | fi |
| 8211 | |
| 8212 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8213 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 8214 | $as_echo_n "checking for _Bool support... " >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8215 | have_c99_bool=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8216 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8217 | /* end confdefs.h. */ |
| 8218 | |
| 8219 | int |
| 8220 | main () |
| 8221 | { |
| 8222 | _Bool x; x = (_Bool)0; |
| 8223 | ; |
| 8224 | return 0; |
| 8225 | } |
| 8226 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8227 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8228 | |
| 8229 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8230 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8231 | |
| 8232 | have_c99_bool=yes |
| 8233 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8234 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8235 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8236 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 8237 | $as_echo "$have_c99_bool" >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8238 | if test "$have_c99_bool" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8239 | # The cast to long int works around a bug in the HP C Compiler |
| 8240 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8241 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8242 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8243 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 8244 | $as_echo_n "checking size of _Bool... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8245 | if ${ac_cv_sizeof__Bool+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8246 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8247 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8248 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (_Bool))" "ac_cv_sizeof__Bool" "$ac_includes_default"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8249 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8250 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8251 | if test "$ac_cv_type__Bool" = yes; then |
| 8252 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8253 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8254 | as_fn_error 77 "cannot compute sizeof (_Bool) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8255 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8256 | else |
| 8257 | ac_cv_sizeof__Bool=0 |
| 8258 | fi |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8259 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8260 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8261 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8262 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 8263 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8264 | |
| 8265 | |
| 8266 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 8267 | cat >>confdefs.h <<_ACEOF |
| 8268 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 8269 | _ACEOF |
| 8270 | |
| 8271 | |
| 8272 | fi |
| 8273 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8274 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "#ifdef HAVE_STDINT_H |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 8275 | #include <stdint.h> |
| 8276 | #endif |
Antoine Pitrou | 1bf29b7 | 2010-10-10 08:10:16 +0000 | [diff] [blame] | 8277 | #ifdef HAVE_INTTYPES_H |
| 8278 | #include <inttypes.h> |
| 8279 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8280 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8281 | if test "x$ac_cv_type_uintptr_t" = xyes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 8282 | |
| 8283 | cat >>confdefs.h <<_ACEOF |
| 8284 | #define HAVE_UINTPTR_T 1 |
| 8285 | _ACEOF |
| 8286 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8287 | # The cast to long int works around a bug in the HP C Compiler |
| 8288 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8289 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8290 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8291 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 8292 | $as_echo_n "checking size of uintptr_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8293 | if ${ac_cv_sizeof_uintptr_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8294 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8295 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8296 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (uintptr_t))" "ac_cv_sizeof_uintptr_t" "$ac_includes_default"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8297 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8298 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8299 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 8300 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8301 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8302 | as_fn_error 77 "cannot compute sizeof (uintptr_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8303 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8304 | else |
| 8305 | ac_cv_sizeof_uintptr_t=0 |
| 8306 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8307 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8308 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8309 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8310 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 8311 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8312 | |
| 8313 | |
| 8314 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8315 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 8316 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8317 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 8318 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8319 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 8320 | fi |
| 8321 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 8322 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8323 | # The cast to long int works around a bug in the HP C Compiler |
| 8324 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8325 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8326 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8327 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 8328 | $as_echo_n "checking size of off_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8329 | if ${ac_cv_sizeof_off_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8330 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8331 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8332 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8333 | #ifdef HAVE_SYS_TYPES_H |
| 8334 | #include <sys/types.h> |
| 8335 | #endif |
| 8336 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8337 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8338 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8339 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8340 | if test "$ac_cv_type_off_t" = yes; then |
| 8341 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8342 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8343 | as_fn_error 77 "cannot compute sizeof (off_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8344 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8345 | else |
| 8346 | ac_cv_sizeof_off_t=0 |
| 8347 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8348 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8349 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8350 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8351 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 8352 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8353 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8354 | |
| 8355 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8356 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8357 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8358 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8359 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8360 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8361 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8362 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 8363 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 8364 | if test "$have_long_long" = yes |
| 8365 | then |
| 8366 | if test "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 8367 | "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8368 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8369 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8370 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8371 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8372 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8373 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8375 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8376 | fi |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 8377 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8378 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8379 | $as_echo "no" >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 8380 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 8381 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8382 | # The cast to long int works around a bug in the HP C Compiler |
| 8383 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8384 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8385 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8386 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 8387 | $as_echo_n "checking size of time_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8388 | if ${ac_cv_sizeof_time_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8389 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8390 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8391 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8392 | #ifdef HAVE_SYS_TYPES_H |
| 8393 | #include <sys/types.h> |
| 8394 | #endif |
| 8395 | #ifdef HAVE_TIME_H |
| 8396 | #include <time.h> |
| 8397 | #endif |
| 8398 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8399 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8400 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8401 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8402 | if test "$ac_cv_type_time_t" = yes; then |
| 8403 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8404 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8405 | as_fn_error 77 "cannot compute sizeof (time_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8406 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8407 | else |
| 8408 | ac_cv_sizeof_time_t=0 |
| 8409 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8410 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8411 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8412 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 8414 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8415 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8416 | |
| 8417 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8418 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8419 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8420 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 8421 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8422 | |
| 8423 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8424 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 8425 | ac_save_cc="$CC" |
| 8426 | if test "$ac_cv_kpthread" = "yes" |
| 8427 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8428 | elif test "$ac_cv_kthread" = "yes" |
| 8429 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8430 | elif test "$ac_cv_pthread" = "yes" |
| 8431 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 8432 | fi |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8433 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 8435 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8436 | have_pthread_t=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8437 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8438 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8439 | |
| 8440 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8441 | int |
| 8442 | main () |
| 8443 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 8444 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8445 | ; |
| 8446 | return 0; |
| 8447 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8448 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8449 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8450 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8451 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8452 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8453 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 8455 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8456 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8457 | # The cast to long int works around a bug in the HP C Compiler |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8458 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 8459 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 8460 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8461 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 8462 | $as_echo_n "checking size of pthread_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8463 | if ${ac_cv_sizeof_pthread_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8464 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8465 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8466 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8467 | #ifdef HAVE_PTHREAD_H |
| 8468 | #include <pthread.h> |
| 8469 | #endif |
| 8470 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8471 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8472 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8473 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8474 | if test "$ac_cv_type_pthread_t" = yes; then |
| 8475 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 8476 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8477 | as_fn_error 77 "cannot compute sizeof (pthread_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8478 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8479 | else |
| 8480 | ac_cv_sizeof_pthread_t=0 |
| 8481 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8482 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8483 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8484 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 8486 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8487 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8488 | |
| 8489 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8490 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8491 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8492 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8493 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 8494 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8495 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 8496 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 8497 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8498 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8499 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 8500 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 8501 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 8502 | ;; |
| 8503 | Darwin/*) |
| 8504 | OTHER_LIBTOOL_OPT="" |
| 8505 | ;; |
| 8506 | esac |
| 8507 | |
| 8508 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8509 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 8510 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 8511 | Darwin/[01567]\..*) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 8512 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 8513 | if test "${enable_universalsdk}"; then |
| 8514 | : |
| 8515 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 8516 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 8517 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 8518 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 8519 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 8520 | Darwin/*) |
Ronald Oussoren | 9812a6c | 2010-02-07 11:53:18 +0000 | [diff] [blame] | 8521 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 8522 | if test ${gcc_version} '<' 4.0 |
| 8523 | then |
| 8524 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 8525 | else |
| 8526 | LIBTOOL_CRUFT="" |
| 8527 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8528 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 8529 | ac_osx_32bit=yes |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8530 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8531 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8532 | /* end confdefs.h. */ |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 8533 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8534 | #include <unistd.h> |
| 8535 | int main(int argc, char*argv[]) |
| 8536 | { |
| 8537 | if (sizeof(long) == 4) { |
| 8538 | return 0; |
| 8539 | } else { |
| 8540 | return 1; |
| 8541 | } |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 8542 | } |
| 8543 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8544 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8545 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8546 | ac_osx_32bit=yes |
| 8547 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8548 | ac_osx_32bit=no |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8549 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8550 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8551 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8552 | fi |
| 8553 | |
| 8554 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8555 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 8556 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8557 | i386) |
| 8558 | MACOSX_DEFAULT_ARCH="i386" |
| 8559 | ;; |
| 8560 | ppc) |
| 8561 | MACOSX_DEFAULT_ARCH="ppc" |
| 8562 | ;; |
| 8563 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8564 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8565 | ;; |
| 8566 | esac |
| 8567 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 8568 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8569 | i386) |
| 8570 | MACOSX_DEFAULT_ARCH="x86_64" |
| 8571 | ;; |
| 8572 | ppc) |
| 8573 | MACOSX_DEFAULT_ARCH="ppc64" |
| 8574 | ;; |
| 8575 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8576 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8577 | ;; |
| 8578 | esac |
| 8579 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 8580 | fi |
| 8581 | |
| 8582 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 8583 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8584 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8585 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 8587 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8588 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8589 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 8590 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8591 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8592 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8593 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8594 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8595 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8596 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8597 | $as_echo "yes" >&6; } |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 8598 | if test $enable_shared = "yes" |
| 8599 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 8600 | as_fn_error $? "Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" "$LINENO" 5 |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 8601 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8602 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8603 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8604 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8605 | fi |
| 8606 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8607 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 8608 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 8609 | case $ac_sys_system/$ac_sys_release in |
| 8610 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8611 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8612 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8613 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8614 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 8615 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 8616 | ;; |
| 8617 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8618 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8619 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8620 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 8621 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8622 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8623 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8624 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8625 | |
| 8626 | |
| 8627 | |
| 8628 | |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8629 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 8630 | |
doko@ubuntu.com | d5537d0 | 2013-03-21 13:21:49 -0700 | [diff] [blame] | 8631 | # SHLIB_SUFFIX is the extension of shared libraries `(including the dot!) |
| 8632 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
| 8633 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking the extension of shared libraries" >&5 |
| 8634 | $as_echo_n "checking the extension of shared libraries... " >&6; } |
| 8635 | if test -z "$SHLIB_SUFFIX"; then |
| 8636 | case $ac_sys_system in |
| 8637 | hp*|HP*) |
| 8638 | case `uname -m` in |
| 8639 | ia64) SHLIB_SUFFIX=.so;; |
| 8640 | *) SHLIB_SUFFIX=.sl;; |
| 8641 | esac |
| 8642 | ;; |
| 8643 | CYGWIN*) SHLIB_SUFFIX=.dll;; |
| 8644 | *) SHLIB_SUFFIX=.so;; |
| 8645 | esac |
| 8646 | fi |
| 8647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIB_SUFFIX" >&5 |
| 8648 | $as_echo "$SHLIB_SUFFIX" >&6; } |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 8649 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8650 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 8651 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8652 | # (Shared libraries in this instance are shared modules to be loaded into |
| 8653 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 8655 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8656 | if test -z "$LDSHARED" |
| 8657 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8658 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 8659 | AIX*) |
Georg Brandl | 9a829be | 2011-02-15 15:44:51 +0000 | [diff] [blame] | 8660 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:\$(srcdir)/Modules/python.exp" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 8661 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 8662 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 8663 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 8664 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8665 | SunOS/5*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8666 | if test "$GCC" = "yes" ; then |
| 8667 | LDSHARED='$(CC) -shared' |
| 8668 | LDCXXSHARED='$(CXX) -shared' |
| 8669 | else |
| 8670 | LDSHARED='$(CC) -G' |
| 8671 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 8672 | fi ;; |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 8673 | hp*|HP*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8674 | if test "$GCC" = "yes" ; then |
| 8675 | LDSHARED='$(CC) -shared' |
| 8676 | LDCXXSHARED='$(CXX) -shared' |
| 8677 | else |
| 8678 | LDSHARED='ld -b' |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 8679 | fi ;; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 8680 | Darwin/1.3*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8681 | LDSHARED='$(CC) -bundle' |
| 8682 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 8683 | if test "$enable_framework" ; then |
| 8684 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 8685 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 8686 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8687 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 8688 | else |
| 8689 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 8690 | LDSHARED="$LDSHARED -undefined suppress" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8691 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 8692 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8693 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8694 | LDSHARED='$(CC) -bundle' |
| 8695 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8696 | if test "$enable_framework" ; then |
| 8697 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 8698 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 8699 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8700 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8701 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 8702 | # No framework, use the Python app as bundle-loader |
| 8703 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 8704 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8705 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8706 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8707 | Darwin/*) |
| 8708 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 8709 | # This allows an extension to be used in any Python |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 8710 | |
Ned Deily | 36820b6 | 2014-06-25 13:44:22 -0700 | [diff] [blame] | 8711 | dep_target_major=`echo ${MACOSX_DEPLOYMENT_TARGET} | \ |
| 8712 | sed 's/\([0-9]*\)\.\([0-9]*\).*/\1/'` |
| 8713 | dep_target_minor=`echo ${MACOSX_DEPLOYMENT_TARGET} | \ |
| 8714 | sed 's/\([0-9]*\)\.\([0-9]*\).*/\2/'` |
| 8715 | if test ${dep_target_major} -eq 10 && \ |
| 8716 | test ${dep_target_minor} -le 2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8717 | then |
Ned Deily | 36820b6 | 2014-06-25 13:44:22 -0700 | [diff] [blame] | 8718 | # building for OS X 10.0 through 10.2 |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8719 | LDSHARED='$(CC) -bundle' |
| 8720 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8721 | if test "$enable_framework" ; then |
| 8722 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 8723 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 8724 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8725 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8726 | else |
| 8727 | # No framework, use the Python app as bundle-loader |
| 8728 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 8729 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8730 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8731 | fi |
Ned Deily | 36820b6 | 2014-06-25 13:44:22 -0700 | [diff] [blame] | 8732 | else |
| 8733 | # building for OS X 10.3 and later |
| 8734 | LDSHARED='$(CC) -bundle -undefined dynamic_lookup' |
| 8735 | LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup' |
| 8736 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 8737 | fi |
| 8738 | ;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8739 | Linux*|GNU*|QNX*) |
| 8740 | LDSHARED='$(CC) -shared' |
| 8741 | LDCXXSHARED='$(CXX) -shared';; |
| 8742 | BSD/OS*/4*) |
| 8743 | LDSHARED="gcc -shared" |
| 8744 | LDCXXSHARED="g++ -shared";; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 8745 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 8746 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 8747 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8748 | LDSHARED='$(CC) -shared' |
| 8749 | LDCXXSHARED='$(CXX) -shared' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 8750 | else |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8751 | LDSHARED="ld -Bshareable" |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 8752 | fi;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 8753 | OpenBSD*) |
| 8754 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 8755 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8756 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 8757 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 8758 | else |
| 8759 | case `uname -r` in |
| 8760 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 8761 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 8762 | ;; |
| 8763 | *) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 8764 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 8765 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 8766 | ;; |
| 8767 | esac |
| 8768 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8769 | NetBSD*|DragonFly*) |
Antoine Pitrou | ece919e | 2011-01-02 20:45:21 +0000 | [diff] [blame] | 8770 | LDSHARED='$(CC) -shared' |
| 8771 | LDCXXSHARED='$(CXX) -shared';; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 8772 | OpenUNIX*|UnixWare*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8773 | if test "$GCC" = "yes" ; then |
| 8774 | LDSHARED='$(CC) -shared' |
| 8775 | LDCXXSHARED='$(CXX) -shared' |
| 8776 | else |
| 8777 | LDSHARED='$(CC) -G' |
| 8778 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 8779 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8780 | SCO_SV*) |
| 8781 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 8782 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 8783 | CYGWIN*) |
| 8784 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 8785 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8786 | *) LDSHARED="ld";; |
| 8787 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8788 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8789 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 8790 | $as_echo "$LDSHARED" >&6; } |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 8791 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 8792 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8793 | # CCSHARED are the C *flags* used to create objects to go into a shared |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8794 | # library (module) -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8795 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 8796 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8797 | if test -z "$CCSHARED" |
| 8798 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 8799 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 8800 | SunOS*) if test "$GCC" = yes; |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 8801 | then CCSHARED="-fPIC"; |
| 8802 | elif test `uname -p` = sparc; |
| 8803 | then CCSHARED="-xcode=pic32"; |
| 8804 | else CCSHARED="-Kpic"; |
| 8805 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 8806 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 8807 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 8808 | else CCSHARED="+z"; |
| 8809 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8810 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 8811 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 8812 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 8813 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 8814 | if test "$GCC" = "yes" |
| 8815 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8816 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 8817 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 8818 | SCO_SV*) |
| 8819 | if test "$GCC" = "yes" |
| 8820 | then CCSHARED="-fPIC" |
| 8821 | else CCSHARED="-Kpic -belf" |
| 8822 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 8823 | IRIX*/6*) case $CC in |
| 8824 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 8825 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 8826 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8827 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8828 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8829 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 8830 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8831 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8832 | # the python executable -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8833 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 8834 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8835 | if test -z "$LINKFORSHARED" |
| 8836 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 8837 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 8838 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 8839 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 8840 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 8841 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 8842 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8843 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 8844 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8845 | Darwin/*) |
Benjamin Peterson | 9c80cac | 2009-05-23 16:34:23 +0000 | [diff] [blame] | 8846 | LINKFORSHARED="$extra_undefs -framework CoreFoundation" |
Łukasz Langa | 335ab5b | 2013-05-30 20:58:53 +0200 | [diff] [blame] | 8847 | |
| 8848 | # Issue #18075: the default maximum stack size (8MBytes) is too |
| 8849 | # small for the default recursion limit. Increase the stack size |
| 8850 | # to ensure that tests don't crash |
| 8851 | LINKFORSHARED="-Wl,-stack_size,1000000 $LINKFORSHARED" |
| 8852 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8853 | if test "$enable_framework" |
| 8854 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 8855 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 8856 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 8857 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 8858 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 8859 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 8860 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 8861 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 8862 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 8863 | then |
| 8864 | LINKFORSHARED="-Wl,--export-dynamic" |
| 8865 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 8866 | SunOS/5*) case $CC in |
| 8867 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 8868 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 8869 | then |
| 8870 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 8871 | fi;; |
| 8872 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 8873 | CYGWIN*) |
| 8874 | if test $enable_shared = "no" |
| 8875 | then |
| 8876 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 8877 | fi;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 8878 | QNX*) |
| 8879 | # -Wl,-E causes the symbols to be added to the dynamic |
| 8880 | # symbol table so that they can be found when a module |
| 8881 | # is loaded. -N 2048K causes the stack size to be set |
| 8882 | # to 2048 kilobytes so that the stack doesn't overflow |
| 8883 | # when running test_compile.py. |
| 8884 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8885 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8886 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8887 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 8888 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 8889 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8890 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 8891 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8892 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 8893 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 8894 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 8895 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 8896 | case $ac_sys_system in |
| 8897 | CYGWIN*) |
| 8898 | # Cygwin needs CCSHARED when building extension DLLs |
| 8899 | # but not when building the interpreter DLL. |
| 8900 | CFLAGSFORSHARED='';; |
| 8901 | *) |
| 8902 | CFLAGSFORSHARED='$(CCSHARED)' |
| 8903 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 8904 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8905 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 8906 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 8907 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8908 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 8909 | # library (with --enable-shared). |
| 8910 | # For platforms on which shared libraries are not allowed to have unresolved |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 8911 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 8912 | # if it is not required, since it creates a dependency of the shared library |
| 8913 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 8914 | # don't need to link LIBS explicitly. The default should be only changed |
| 8915 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8916 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8917 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 8918 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8919 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8920 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 8921 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8922 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 8924 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8925 | |
| 8926 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8927 | # checks for libraries |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 8928 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sendfile in -lsendfile" >&5 |
| 8929 | $as_echo_n "checking for sendfile in -lsendfile... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8930 | if ${ac_cv_lib_sendfile_sendfile+:} false; then : |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 8931 | $as_echo_n "(cached) " >&6 |
| 8932 | else |
| 8933 | ac_check_lib_save_LIBS=$LIBS |
| 8934 | LIBS="-lsendfile $LIBS" |
| 8935 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 8936 | /* end confdefs.h. */ |
| 8937 | |
| 8938 | /* Override any GCC internal prototype to avoid an error. |
| 8939 | Use char because int might match the return type of a GCC |
| 8940 | builtin and then its argument prototype would still apply. */ |
| 8941 | #ifdef __cplusplus |
| 8942 | extern "C" |
| 8943 | #endif |
| 8944 | char sendfile (); |
| 8945 | int |
| 8946 | main () |
| 8947 | { |
| 8948 | return sendfile (); |
| 8949 | ; |
| 8950 | return 0; |
| 8951 | } |
| 8952 | _ACEOF |
| 8953 | if ac_fn_c_try_link "$LINENO"; then : |
| 8954 | ac_cv_lib_sendfile_sendfile=yes |
| 8955 | else |
| 8956 | ac_cv_lib_sendfile_sendfile=no |
| 8957 | fi |
| 8958 | rm -f core conftest.err conftest.$ac_objext \ |
| 8959 | conftest$ac_exeext conftest.$ac_ext |
| 8960 | LIBS=$ac_check_lib_save_LIBS |
| 8961 | fi |
| 8962 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sendfile_sendfile" >&5 |
| 8963 | $as_echo "$ac_cv_lib_sendfile_sendfile" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8964 | if test "x$ac_cv_lib_sendfile_sendfile" = xyes; then : |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 8965 | cat >>confdefs.h <<_ACEOF |
| 8966 | #define HAVE_LIBSENDFILE 1 |
| 8967 | _ACEOF |
| 8968 | |
| 8969 | LIBS="-lsendfile $LIBS" |
| 8970 | |
| 8971 | fi |
| 8972 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8973 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 8974 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 8975 | if ${ac_cv_lib_dl_dlopen+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8976 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8977 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8978 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8979 | LIBS="-ldl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8980 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8981 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8982 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8983 | /* Override any GCC internal prototype to avoid an error. |
| 8984 | Use char because int might match the return type of a GCC |
| 8985 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8986 | #ifdef __cplusplus |
| 8987 | extern "C" |
| 8988 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8989 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8990 | int |
| 8991 | main () |
| 8992 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8993 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8994 | ; |
| 8995 | return 0; |
| 8996 | } |
| 8997 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8998 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8999 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9000 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9001 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9002 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9003 | rm -f core conftest.err conftest.$ac_objext \ |
| 9004 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9005 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9006 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9007 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 9008 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9009 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9010 | cat >>confdefs.h <<_ACEOF |
| 9011 | #define HAVE_LIBDL 1 |
| 9012 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9013 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9014 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9015 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9016 | fi |
| 9017 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9018 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 9019 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9020 | if ${ac_cv_lib_dld_shl_load+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9021 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9022 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9023 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9024 | LIBS="-ldld $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9025 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9026 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9027 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9028 | /* Override any GCC internal prototype to avoid an error. |
| 9029 | Use char because int might match the return type of a GCC |
| 9030 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9031 | #ifdef __cplusplus |
| 9032 | extern "C" |
| 9033 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9034 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9035 | int |
| 9036 | main () |
| 9037 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9038 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9039 | ; |
| 9040 | return 0; |
| 9041 | } |
| 9042 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9043 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9044 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9045 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9046 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9047 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9048 | rm -f core conftest.err conftest.$ac_objext \ |
| 9049 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9050 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9051 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 9053 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9054 | if test "x$ac_cv_lib_dld_shl_load" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9055 | cat >>confdefs.h <<_ACEOF |
| 9056 | #define HAVE_LIBDLD 1 |
| 9057 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9058 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9059 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9060 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9061 | fi |
| 9062 | # Dynamic linking for HP-UX |
Victor Stinner | beeb512 | 2014-11-28 13:28:25 +0100 | [diff] [blame] | 9063 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RAND_egd in -lcrypto" >&5 |
| 9064 | $as_echo_n "checking for RAND_egd in -lcrypto... " >&6; } |
| 9065 | if ${ac_cv_lib_crypto_RAND_egd+:} false; then : |
| 9066 | $as_echo_n "(cached) " >&6 |
| 9067 | else |
| 9068 | ac_check_lib_save_LIBS=$LIBS |
| 9069 | LIBS="-lcrypto $LIBS" |
| 9070 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9071 | /* end confdefs.h. */ |
| 9072 | |
| 9073 | /* Override any GCC internal prototype to avoid an error. |
| 9074 | Use char because int might match the return type of a GCC |
| 9075 | builtin and then its argument prototype would still apply. */ |
| 9076 | #ifdef __cplusplus |
| 9077 | extern "C" |
| 9078 | #endif |
| 9079 | char RAND_egd (); |
| 9080 | int |
| 9081 | main () |
| 9082 | { |
| 9083 | return RAND_egd (); |
| 9084 | ; |
| 9085 | return 0; |
| 9086 | } |
| 9087 | _ACEOF |
| 9088 | if ac_fn_c_try_link "$LINENO"; then : |
| 9089 | ac_cv_lib_crypto_RAND_egd=yes |
| 9090 | else |
| 9091 | ac_cv_lib_crypto_RAND_egd=no |
| 9092 | fi |
| 9093 | rm -f core conftest.err conftest.$ac_objext \ |
| 9094 | conftest$ac_exeext conftest.$ac_ext |
| 9095 | LIBS=$ac_check_lib_save_LIBS |
| 9096 | fi |
| 9097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_RAND_egd" >&5 |
| 9098 | $as_echo "$ac_cv_lib_crypto_RAND_egd" >&6; } |
| 9099 | if test "x$ac_cv_lib_crypto_RAND_egd" = xyes; then : |
| 9100 | |
| 9101 | $as_echo "#define HAVE_RAND_EGD 1" >>confdefs.h |
| 9102 | |
| 9103 | fi |
| 9104 | |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9105 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 9106 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9107 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9108 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 9109 | $as_echo_n "checking for library containing sem_init... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9110 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9111 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 9112 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 9113 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9114 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9115 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9116 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9117 | /* Override any GCC internal prototype to avoid an error. |
| 9118 | Use char because int might match the return type of a GCC |
| 9119 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9120 | #ifdef __cplusplus |
| 9121 | extern "C" |
| 9122 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9123 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9124 | int |
| 9125 | main () |
| 9126 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9127 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9128 | ; |
| 9129 | return 0; |
| 9130 | } |
| 9131 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9132 | for ac_lib in '' pthread rt posix4; do |
| 9133 | if test -z "$ac_lib"; then |
| 9134 | ac_res="none required" |
| 9135 | else |
| 9136 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 9137 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9138 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9139 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9140 | ac_cv_search_sem_init=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 9141 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9142 | rm -f core conftest.err conftest.$ac_objext \ |
| 9143 | conftest$ac_exeext |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9144 | if ${ac_cv_search_sem_init+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9145 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 9146 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9147 | done |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9148 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9149 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9150 | else |
| 9151 | ac_cv_search_sem_init=no |
| 9152 | fi |
| 9153 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 9154 | LIBS=$ac_func_search_save_LIBS |
| 9155 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9156 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 9157 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9158 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9159 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9160 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 9161 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 9162 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 9163 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9164 | # posix4 on Solaris 2.6 |
| 9165 | # pthread (first!) on Linux |
| 9166 | fi |
| 9167 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9168 | # check if we need libintl for locale functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9169 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 9170 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9171 | if ${ac_cv_lib_intl_textdomain+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9172 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9173 | else |
| 9174 | ac_check_lib_save_LIBS=$LIBS |
| 9175 | LIBS="-lintl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9176 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9177 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9178 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9179 | /* Override any GCC internal prototype to avoid an error. |
| 9180 | Use char because int might match the return type of a GCC |
| 9181 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9182 | #ifdef __cplusplus |
| 9183 | extern "C" |
| 9184 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9185 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9186 | int |
| 9187 | main () |
| 9188 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9189 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9190 | ; |
| 9191 | return 0; |
| 9192 | } |
| 9193 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9194 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9195 | ac_cv_lib_intl_textdomain=yes |
| 9196 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9197 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9198 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9199 | rm -f core conftest.err conftest.$ac_objext \ |
| 9200 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9201 | LIBS=$ac_check_lib_save_LIBS |
| 9202 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9203 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 9204 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9205 | if test "x$ac_cv_lib_intl_textdomain" = xyes; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9206 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9207 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9208 | |
Brett Cannon | c6d936e | 2009-06-07 20:09:53 +0000 | [diff] [blame] | 9209 | LIBS="-lintl $LIBS" |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 9210 | fi |
| 9211 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9212 | |
| 9213 | # checks for system dependent C++ extensions support |
| 9214 | case "$ac_sys_system" in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9215 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 9216 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 9217 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9218 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9219 | |
Georg Brandl | 59e87bd | 2011-02-15 19:48:59 +0000 | [diff] [blame] | 9220 | #include <load.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9221 | int |
| 9222 | main () |
| 9223 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9224 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9225 | ; |
| 9226 | return 0; |
| 9227 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9228 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9229 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9230 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9231 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9232 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9233 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9234 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9235 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9236 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9237 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9238 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9239 | |
| 9240 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9241 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9242 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9243 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9244 | rm -f core conftest.err conftest.$ac_objext \ |
| 9245 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 9246 | *) ;; |
| 9247 | esac |
| 9248 | |
Christian Heimes | 985ecdc | 2013-11-20 11:46:18 +0100 | [diff] [blame] | 9249 | # check for systems that require aligned memory access |
| 9250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking aligned memory access is required" >&5 |
| 9251 | $as_echo_n "checking aligned memory access is required... " >&6; } |
| 9252 | if test "$cross_compiling" = yes; then : |
| 9253 | aligned_required=yes |
| 9254 | else |
| 9255 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9256 | /* end confdefs.h. */ |
| 9257 | |
| 9258 | int main() |
| 9259 | { |
| 9260 | char s[16]; |
| 9261 | int i, *p1, *p2; |
| 9262 | for (i=0; i < 16; i++) |
| 9263 | s[i] = i; |
| 9264 | p1 = (int*)(s+1); |
| 9265 | p2 = (int*)(s+2); |
| 9266 | if (*p1 == *p2) |
| 9267 | return 1; |
| 9268 | return 0; |
| 9269 | } |
| 9270 | |
| 9271 | _ACEOF |
| 9272 | if ac_fn_c_try_run "$LINENO"; then : |
| 9273 | aligned_required=no |
| 9274 | else |
| 9275 | aligned_required=yes |
| 9276 | fi |
| 9277 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9278 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 9279 | fi |
| 9280 | |
| 9281 | |
| 9282 | if test "$aligned_required" = yes ; then |
| 9283 | |
| 9284 | $as_echo "#define HAVE_ALIGNED_REQUIRED 1" >>confdefs.h |
| 9285 | |
| 9286 | fi |
| 9287 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $aligned_required" >&5 |
| 9288 | $as_echo "$aligned_required" >&6; } |
| 9289 | |
| 9290 | |
| 9291 | # str, bytes and memoryview hash algorithm |
| 9292 | |
| 9293 | |
| 9294 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-hash-algorithm" >&5 |
| 9295 | $as_echo_n "checking for --with-hash-algorithm... " >&6; } |
| 9296 | |
| 9297 | # Check whether --with-hash_algorithm was given. |
| 9298 | if test "${with_hash_algorithm+set}" = set; then : |
| 9299 | withval=$with_hash_algorithm; |
| 9300 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 9301 | $as_echo "$withval" >&6; } |
| 9302 | case "$withval" in |
| 9303 | siphash24) |
| 9304 | $as_echo "#define Py_HASH_ALGORITHM 1" >>confdefs.h |
| 9305 | |
| 9306 | ;; |
| 9307 | fnv) |
| 9308 | $as_echo "#define Py_HASH_ALGORITHM 2" >>confdefs.h |
| 9309 | |
| 9310 | ;; |
| 9311 | *) |
| 9312 | as_fn_error $? "unknown hash algorithm '$withval'" "$LINENO" 5 |
| 9313 | ;; |
| 9314 | esac |
| 9315 | |
| 9316 | else |
| 9317 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default" >&5 |
| 9318 | $as_echo "default" >&6; } |
| 9319 | fi |
| 9320 | |
| 9321 | |
Charles-François Natali | d30b022 | 2014-05-08 23:08:51 +0100 | [diff] [blame] | 9322 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-address-sanitizer" >&5 |
| 9323 | $as_echo_n "checking for --with-address-sanitizer... " >&6; } |
| 9324 | |
| 9325 | # Check whether --with-address_sanitizer was given. |
| 9326 | if test "${with_address_sanitizer+set}" = set; then : |
| 9327 | withval=$with_address_sanitizer; |
| 9328 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 9329 | $as_echo "$withval" >&6; } |
| 9330 | BASECFLAGS="-fsanitize=address -fno-omit-frame-pointer $BASECFLAGS" |
| 9331 | LDFLAGS="-fsanitize=address $LDFLAGS" |
| 9332 | |
| 9333 | else |
| 9334 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9335 | $as_echo "no" >&6; } |
| 9336 | fi |
| 9337 | |
| 9338 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 9339 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9340 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 9341 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9342 | if ${ac_cv_lib_nsl_t_open+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9343 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9344 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9345 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9346 | LIBS="-lnsl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9347 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9348 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9349 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9350 | /* Override any GCC internal prototype to avoid an error. |
| 9351 | Use char because int might match the return type of a GCC |
| 9352 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9353 | #ifdef __cplusplus |
| 9354 | extern "C" |
| 9355 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9356 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9357 | int |
| 9358 | main () |
| 9359 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9360 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9361 | ; |
| 9362 | return 0; |
| 9363 | } |
| 9364 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9365 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9366 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9367 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9368 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9369 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9370 | rm -f core conftest.err conftest.$ac_objext \ |
| 9371 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9372 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9373 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 9375 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9376 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9377 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 9378 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 9379 | # SVR4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9380 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 9381 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9382 | if ${ac_cv_lib_socket_socket+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9383 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9384 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9385 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9386 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9387 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9388 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9389 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9390 | /* Override any GCC internal prototype to avoid an error. |
| 9391 | Use char because int might match the return type of a GCC |
| 9392 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9393 | #ifdef __cplusplus |
| 9394 | extern "C" |
| 9395 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9396 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9397 | int |
| 9398 | main () |
| 9399 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9400 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9401 | ; |
| 9402 | return 0; |
| 9403 | } |
| 9404 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9405 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9406 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 9407 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9408 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 9409 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9410 | rm -f core conftest.err conftest.$ac_objext \ |
| 9411 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9412 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 9413 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9414 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 9415 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9416 | if test "x$ac_cv_lib_socket_socket" = xyes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 9417 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 9418 | fi |
| 9419 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 9420 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 9422 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9423 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9424 | # Check whether --with-libs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9425 | if test "${with_libs+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9426 | withval=$with_libs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 9428 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 9429 | LIBS="$withval $LIBS" |
| 9430 | |
| 9431 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9432 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9433 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9434 | fi |
| 9435 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9436 | |
Benjamin Peterson | 0f3cde1 | 2014-12-15 00:00:23 -0500 | [diff] [blame] | 9437 | |
| 9438 | |
| 9439 | |
| 9440 | |
| 9441 | |
| 9442 | |
| 9443 | |
| 9444 | if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then |
| 9445 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9446 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 9447 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9448 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9449 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9450 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9451 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9452 | else |
| 9453 | case $PKG_CONFIG in |
| 9454 | [\\/]* | ?:[\\/]*) |
| 9455 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 9456 | ;; |
| 9457 | *) |
| 9458 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9459 | for as_dir in $PATH |
| 9460 | do |
| 9461 | IFS=$as_save_IFS |
| 9462 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9463 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 9464 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9465 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9466 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9467 | break 2 |
| 9468 | fi |
| 9469 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9470 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9471 | IFS=$as_save_IFS |
| 9472 | |
| 9473 | ;; |
| 9474 | esac |
| 9475 | fi |
| 9476 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 9477 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9478 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 9479 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9480 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9481 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9482 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9483 | fi |
| 9484 | |
| 9485 | |
| 9486 | fi |
| 9487 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 9488 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 9489 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 9490 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9491 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9492 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9493 | if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9494 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9495 | else |
| 9496 | case $ac_pt_PKG_CONFIG in |
| 9497 | [\\/]* | ?:[\\/]*) |
| 9498 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 9499 | ;; |
| 9500 | *) |
| 9501 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9502 | for as_dir in $PATH |
| 9503 | do |
| 9504 | IFS=$as_save_IFS |
| 9505 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9506 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 9507 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9508 | ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9509 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9510 | break 2 |
| 9511 | fi |
| 9512 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9513 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9514 | IFS=$as_save_IFS |
| 9515 | |
| 9516 | ;; |
| 9517 | esac |
| 9518 | fi |
| 9519 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 9520 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9521 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 9522 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9523 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9525 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9526 | fi |
| 9527 | |
| 9528 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 9529 | PKG_CONFIG="" |
| 9530 | else |
| 9531 | case $cross_compiling:$ac_tool_warned in |
| 9532 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9533 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 9534 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9535 | ac_tool_warned=yes ;; |
| 9536 | esac |
| 9537 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 9538 | fi |
| 9539 | else |
| 9540 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 9541 | fi |
| 9542 | |
Benjamin Peterson | 0f3cde1 | 2014-12-15 00:00:23 -0500 | [diff] [blame] | 9543 | fi |
| 9544 | if test -n "$PKG_CONFIG"; then |
| 9545 | _pkg_min_version=0.9.0 |
| 9546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 |
| 9547 | $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } |
| 9548 | if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then |
| 9549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9550 | $as_echo "yes" >&6; } |
| 9551 | else |
| 9552 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9553 | $as_echo "no" >&6; } |
| 9554 | PKG_CONFIG="" |
| 9555 | fi |
| 9556 | fi |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9557 | |
| 9558 | # Check for use of the system expat library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9559 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 9560 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9561 | |
| 9562 | # Check whether --with-system_expat was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9563 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9564 | withval=$with_system_expat; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 9565 | else |
| 9566 | with_system_expat="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9567 | fi |
| 9568 | |
| 9569 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 9571 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9572 | |
| 9573 | # Check for use of the system libffi library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 9575 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9576 | |
| 9577 | # Check whether --with-system_ffi was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9578 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9579 | withval=$with_system_ffi; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 9580 | else |
| 9581 | with_system_ffi="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 9582 | fi |
| 9583 | |
| 9584 | |
| 9585 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 9586 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 9587 | else |
| 9588 | LIBFFI_INCLUDEDIR="" |
| 9589 | fi |
| 9590 | |
| 9591 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 9593 | $as_echo "$with_system_ffi" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 9594 | |
Stefan Krah | 60187b5 | 2012-03-23 19:06:27 +0100 | [diff] [blame] | 9595 | # Check for use of the system libmpdec library |
| 9596 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-libmpdec" >&5 |
| 9597 | $as_echo_n "checking for --with-system-libmpdec... " >&6; } |
| 9598 | |
| 9599 | # Check whether --with-system_libmpdec was given. |
| 9600 | if test "${with_system_libmpdec+set}" = set; then : |
| 9601 | withval=$with_system_libmpdec; |
| 9602 | else |
| 9603 | with_system_libmpdec="no" |
| 9604 | fi |
| 9605 | |
| 9606 | |
| 9607 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_libmpdec" >&5 |
| 9608 | $as_echo "$with_system_libmpdec" >&6; } |
| 9609 | |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 9610 | # Check for support for loadable sqlite extensions |
| 9611 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-loadable-sqlite-extensions" >&5 |
| 9612 | $as_echo_n "checking for --enable-loadable-sqlite-extensions... " >&6; } |
| 9613 | # Check whether --enable-loadable-sqlite-extensions was given. |
| 9614 | if test "${enable_loadable_sqlite_extensions+set}" = set; then : |
| 9615 | enableval=$enable_loadable_sqlite_extensions; |
| 9616 | else |
| 9617 | enable_loadable_sqlite_extensions="no" |
| 9618 | fi |
| 9619 | |
| 9620 | |
| 9621 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_loadable_sqlite_extensions" >&5 |
| 9622 | $as_echo "$enable_loadable_sqlite_extensions" >&6; } |
| 9623 | |
Ned Deily | d819b93 | 2013-09-06 01:07:05 -0700 | [diff] [blame] | 9624 | # Check for --with-tcltk-includes=path and --with-tcltk-libs=path |
| 9625 | |
| 9626 | |
| 9627 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-includes" >&5 |
| 9628 | $as_echo_n "checking for --with-tcltk-includes... " >&6; } |
| 9629 | |
| 9630 | # Check whether --with-tcltk-includes was given. |
| 9631 | if test "${with_tcltk_includes+set}" = set; then : |
| 9632 | withval=$with_tcltk_includes; |
| 9633 | else |
| 9634 | with_tcltk_includes="default" |
| 9635 | fi |
| 9636 | |
| 9637 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_includes" >&5 |
| 9638 | $as_echo "$with_tcltk_includes" >&6; } |
| 9639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tcltk-libs" >&5 |
| 9640 | $as_echo_n "checking for --with-tcltk-libs... " >&6; } |
| 9641 | |
| 9642 | # Check whether --with-tcltk-libs was given. |
| 9643 | if test "${with_tcltk_libs+set}" = set; then : |
| 9644 | withval=$with_tcltk_libs; |
| 9645 | else |
| 9646 | with_tcltk_libs="default" |
| 9647 | fi |
| 9648 | |
| 9649 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcltk_libs" >&5 |
| 9650 | $as_echo "$with_tcltk_libs" >&6; } |
| 9651 | if test "x$with_tcltk_includes" = xdefault || test "x$with_tcltk_libs" = xdefault |
| 9652 | then |
| 9653 | if test "x$with_tcltk_includes" != "x$with_tcltk_libs" |
| 9654 | then |
| 9655 | as_fn_error $? "use both --with-tcltk-includes='...' and --with-tcltk-libs='...' or neither" "$LINENO" 5 |
| 9656 | fi |
| 9657 | TCLTK_INCLUDES="" |
| 9658 | TCLTK_LIBS="" |
| 9659 | else |
| 9660 | TCLTK_INCLUDES="$with_tcltk_includes" |
| 9661 | TCLTK_LIBS="$with_tcltk_libs" |
| 9662 | fi |
| 9663 | |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9664 | # Check for --with-dbmliborder |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9665 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 9666 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9667 | |
| 9668 | # Check whether --with-dbmliborder was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9669 | if test "${with_dbmliborder+set}" = set; then : |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9670 | withval=$with_dbmliborder; |
| 9671 | if test x$with_dbmliborder = xyes |
| 9672 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 9673 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9674 | else |
| 9675 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 9676 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 9677 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 9678 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9679 | fi |
| 9680 | done |
| 9681 | fi |
| 9682 | fi |
| 9683 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9684 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 9685 | $as_echo "$with_dbmliborder" >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 9686 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 9687 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 9688 | |
| 9689 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9690 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 9691 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9692 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9693 | # Check whether --with-signal-module was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9694 | if test "${with_signal_module+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9695 | withval=$with_signal_module; |
| 9696 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 9697 | |
| 9698 | |
| 9699 | if test -z "$with_signal_module" |
| 9700 | then with_signal_module="yes" |
| 9701 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9702 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 9703 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 9704 | |
| 9705 | if test "${with_signal_module}" = "yes"; then |
| 9706 | USE_SIGNAL_MODULE="" |
| 9707 | SIGNAL_OBJS="" |
| 9708 | else |
| 9709 | USE_SIGNAL_MODULE="#" |
| 9710 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 9711 | fi |
| 9712 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 9713 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 9714 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 9715 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 9716 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9717 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9718 | |
| 9719 | # Templates for things AC_DEFINEd more than once. |
| 9720 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 9721 | |
| 9722 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9723 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9724 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 9725 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9726 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9727 | # Check whether --with-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9728 | if test "${with_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9729 | withval=$with_threads; |
| 9730 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 9731 | |
| 9732 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 9733 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9734 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9735 | # Check whether --with-thread was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9736 | if test "${with_thread+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9737 | withval=$with_thread; with_threads=$with_thread |
| 9738 | fi |
| 9739 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 9740 | |
| 9741 | if test -z "$with_threads" |
| 9742 | then with_threads="yes" |
| 9743 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9744 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 9745 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 9746 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9747 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 9748 | if test "$with_threads" = "no" |
| 9749 | then |
| 9750 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9751 | elif test "$ac_cv_pthread_is_default" = yes |
| 9752 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9753 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9754 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9755 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9756 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9757 | |
| 9758 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9759 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 9760 | elif test "$ac_cv_kpthread" = "yes" |
| 9761 | then |
| 9762 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9763 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 9764 | CXX="$CXX -Kpthread" |
| 9765 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9766 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 9767 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9768 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9769 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 9770 | elif test "$ac_cv_kthread" = "yes" |
| 9771 | then |
| 9772 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9773 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 9774 | CXX="$CXX -Kthread" |
| 9775 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9776 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 9777 | |
| 9778 | posix_threads=yes |
| 9779 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9780 | elif test "$ac_cv_pthread" = "yes" |
| 9781 | then |
| 9782 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 9783 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 9784 | CXX="$CXX -pthread" |
| 9785 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9786 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9787 | |
| 9788 | posix_threads=yes |
| 9789 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 9790 | else |
| 9791 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 9792 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 9793 | fi |
| 9794 | if test ! -z "$withval" -a -d "$withval" |
| 9795 | then LDFLAGS="$LDFLAGS -L$withval" |
| 9796 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9797 | |
| 9798 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 9799 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 9800 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9801 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 9802 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 9803 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9804 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 9805 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9806 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 9807 | #ifdef _POSIX_THREADS |
| 9808 | yes |
| 9809 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9810 | |
| 9811 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9812 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9813 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9814 | unistd_defines_pthreads=yes |
| 9815 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9816 | unistd_defines_pthreads=no |
| 9817 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9818 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9819 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9820 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 9821 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9822 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9823 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 9824 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 9825 | # Just looking for pthread_create in libpthread is not enough: |
| 9826 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 9827 | # So we really have to include pthread.h, and then link. |
| 9828 | _libs=$LIBS |
| 9829 | LIBS="$LIBS -lpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9830 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 9831 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 9832 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9833 | /* end confdefs.h. */ |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 9834 | |
| 9835 | #include <stdio.h> |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 9836 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 9837 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 9838 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9839 | int |
| 9840 | main () |
| 9841 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 9842 | |
| 9843 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9844 | ; |
| 9845 | return 0; |
| 9846 | } |
| 9847 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9848 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9849 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9851 | $as_echo "yes" >&6; } |
| 9852 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 9853 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9854 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9855 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 9856 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9857 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 9858 | LIBS=$_libs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9859 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9860 | if test "x$ac_cv_func_pthread_detach" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9861 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 9862 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 9863 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9864 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 9865 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 9866 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9867 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 9868 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9869 | if ${ac_cv_lib_pthreads_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9870 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 9871 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9872 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 9873 | LIBS="-lpthreads $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9874 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9875 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9876 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9877 | /* Override any GCC internal prototype to avoid an error. |
| 9878 | Use char because int might match the return type of a GCC |
| 9879 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9880 | #ifdef __cplusplus |
| 9881 | extern "C" |
| 9882 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9883 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9884 | int |
| 9885 | main () |
| 9886 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9887 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9888 | ; |
| 9889 | return 0; |
| 9890 | } |
| 9891 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9892 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9893 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9894 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9895 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9896 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9897 | rm -f core conftest.err conftest.$ac_objext \ |
| 9898 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9899 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9900 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 9902 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9903 | if test "x$ac_cv_lib_pthreads_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9904 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9905 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9906 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 9907 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9908 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9909 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9910 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9911 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 9912 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9913 | if ${ac_cv_lib_c_r_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9914 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9915 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9916 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 9917 | LIBS="-lc_r $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9918 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9919 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9920 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9921 | /* Override any GCC internal prototype to avoid an error. |
| 9922 | Use char because int might match the return type of a GCC |
| 9923 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9924 | #ifdef __cplusplus |
| 9925 | extern "C" |
| 9926 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9927 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9928 | int |
| 9929 | main () |
| 9930 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9931 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9932 | ; |
| 9933 | return 0; |
| 9934 | } |
| 9935 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9936 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9937 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 9938 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9939 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 9940 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9941 | rm -f core conftest.err conftest.$ac_objext \ |
| 9942 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9943 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 9944 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9945 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 9946 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9947 | if test "x$ac_cv_lib_c_r_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9948 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 9949 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9950 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 9951 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9952 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 9953 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 9954 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9955 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 9956 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9957 | if ${ac_cv_lib_pthread___pthread_create_system+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9958 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9959 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9960 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9961 | LIBS="-lpthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9963 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9964 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9965 | /* Override any GCC internal prototype to avoid an error. |
| 9966 | Use char because int might match the return type of a GCC |
| 9967 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9968 | #ifdef __cplusplus |
| 9969 | extern "C" |
| 9970 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9971 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9972 | int |
| 9973 | main () |
| 9974 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9975 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9976 | ; |
| 9977 | return 0; |
| 9978 | } |
| 9979 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9980 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9981 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9983 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9984 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9985 | rm -f core conftest.err conftest.$ac_objext \ |
| 9986 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9987 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9988 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9989 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 9990 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 9991 | if test "x$ac_cv_lib_pthread___pthread_create_system" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9992 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9993 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9994 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 9995 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 9996 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9997 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 9998 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9999 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 10000 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10001 | if ${ac_cv_lib_cma_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10002 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10003 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10004 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10005 | LIBS="-lcma $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10006 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10007 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10008 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10009 | /* Override any GCC internal prototype to avoid an error. |
| 10010 | Use char because int might match the return type of a GCC |
| 10011 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10012 | #ifdef __cplusplus |
| 10013 | extern "C" |
| 10014 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10015 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10016 | int |
| 10017 | main () |
| 10018 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10019 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10020 | ; |
| 10021 | return 0; |
| 10022 | } |
| 10023 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10024 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10025 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10026 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10027 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10028 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10029 | rm -f core conftest.err conftest.$ac_objext \ |
| 10030 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10031 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10032 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10033 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 10034 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10035 | if test "x$ac_cv_lib_cma_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10036 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10037 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10038 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 10039 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 10040 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10041 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 10042 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 10043 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 10044 | fi |
| 10045 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10046 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 10047 | fi |
| 10048 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 10049 | fi |
| 10050 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 10051 | fi |
| 10052 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 10053 | fi |
| 10054 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 10055 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10056 | rm -f core conftest.err conftest.$ac_objext \ |
| 10057 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10058 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10059 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 10060 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10061 | if ${ac_cv_lib_mpc_usconfig+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10062 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10063 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10064 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 10065 | LIBS="-lmpc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10066 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10067 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10068 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10069 | /* Override any GCC internal prototype to avoid an error. |
| 10070 | Use char because int might match the return type of a GCC |
| 10071 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10072 | #ifdef __cplusplus |
| 10073 | extern "C" |
| 10074 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10075 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10076 | int |
| 10077 | main () |
| 10078 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10079 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10080 | ; |
| 10081 | return 0; |
| 10082 | } |
| 10083 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10084 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10085 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10086 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10087 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10088 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10089 | rm -f core conftest.err conftest.$ac_objext \ |
| 10090 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10091 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10092 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10093 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 10094 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10095 | if test "x$ac_cv_lib_mpc_usconfig" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10096 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10097 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 10098 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 10099 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 10100 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10101 | fi |
| 10102 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 10103 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 10104 | if test "$posix_threads" != "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10105 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 10106 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10107 | if ${ac_cv_lib_thread_thr_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10108 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10109 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10110 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 10111 | LIBS="-lthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10112 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10113 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10114 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10115 | /* Override any GCC internal prototype to avoid an error. |
| 10116 | Use char because int might match the return type of a GCC |
| 10117 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10118 | #ifdef __cplusplus |
| 10119 | extern "C" |
| 10120 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10121 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10122 | int |
| 10123 | main () |
| 10124 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10125 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10126 | ; |
| 10127 | return 0; |
| 10128 | } |
| 10129 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10130 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10131 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10132 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10133 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10134 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10135 | rm -f core conftest.err conftest.$ac_objext \ |
| 10136 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10137 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10138 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10139 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 10140 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10141 | if test "x$ac_cv_lib_thread_thr_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10142 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10143 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 10144 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 10145 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 10146 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10147 | fi |
| 10148 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 10149 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10150 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 10151 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10152 | if test "$posix_threads" = "yes"; then |
| 10153 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 10154 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10155 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10156 | |
| 10157 | fi |
| 10158 | |
| 10159 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 10160 | case $ac_sys_system/$ac_sys_release in |
Charles-François Natali | 996f606 | 2011-07-21 19:45:31 +0200 | [diff] [blame] | 10161 | SunOS/5.6) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10162 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 10163 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10164 | ;; |
| 10165 | SunOS/5.8) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10166 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10167 | |
| 10168 | ;; |
Charles-François Natali | 996f606 | 2011-07-21 19:45:31 +0200 | [diff] [blame] | 10169 | AIX/*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10170 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 10171 | |
| 10172 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10173 | esac |
| 10174 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10175 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 10176 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10177 | if ${ac_cv_pthread_system_supported+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10178 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10179 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10180 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10181 | ac_cv_pthread_system_supported=no |
| 10182 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10183 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10184 | /* end confdefs.h. */ |
Stefan Krah | 7dba594 | 2012-11-22 22:49:11 +0100 | [diff] [blame] | 10185 | |
| 10186 | #include <stdio.h> |
| 10187 | #include <pthread.h> |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10188 | void *foo(void *parm) { |
| 10189 | return NULL; |
| 10190 | } |
| 10191 | main() { |
| 10192 | pthread_attr_t attr; |
| 10193 | pthread_t id; |
| 10194 | if (pthread_attr_init(&attr)) exit(-1); |
| 10195 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 10196 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 10197 | exit(0); |
| 10198 | } |
| 10199 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10200 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10201 | ac_cv_pthread_system_supported=yes |
| 10202 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10203 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10204 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10205 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10206 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10207 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 10208 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10209 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10210 | fi |
| 10211 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 10213 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10214 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 10215 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10216 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10217 | |
| 10218 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10219 | for ac_func in pthread_sigmask |
| 10220 | do : |
| 10221 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10222 | if test "x$ac_cv_func_pthread_sigmask" = xyes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10223 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10224 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10225 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 10226 | case $ac_sys_system in |
| 10227 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10228 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10229 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 10230 | |
| 10231 | ;; |
| 10232 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10233 | fi |
| 10234 | done |
| 10235 | |
Christian Heimes | f77b4b2 | 2013-08-21 13:26:05 +0200 | [diff] [blame] | 10236 | for ac_func in pthread_atfork |
| 10237 | do : |
| 10238 | ac_fn_c_check_func "$LINENO" "pthread_atfork" "ac_cv_func_pthread_atfork" |
| 10239 | if test "x$ac_cv_func_pthread_atfork" = xyes; then : |
| 10240 | cat >>confdefs.h <<_ACEOF |
| 10241 | #define HAVE_PTHREAD_ATFORK 1 |
| 10242 | _ACEOF |
| 10243 | |
| 10244 | fi |
| 10245 | done |
| 10246 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 10247 | fi |
| 10248 | |
| 10249 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10250 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10251 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10252 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 10253 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10254 | # Check whether --enable-ipv6 was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10255 | if test "${enable_ipv6+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10256 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10257 | no) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10258 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10259 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10260 | ipv6=no |
| 10261 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10262 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10263 | $as_echo "yes" >&6; } |
| 10264 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10265 | |
| 10266 | ipv6=yes |
| 10267 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10268 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10269 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10270 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10271 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10272 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10273 | /* AF_INET6 available check */ |
| 10274 | #include <sys/types.h> |
| 10275 | #include <sys/socket.h> |
Charles-François Natali | f6fd794 | 2013-01-08 19:49:42 +0100 | [diff] [blame] | 10276 | int |
| 10277 | main () |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10278 | { |
Charles-François Natali | f6fd794 | 2013-01-08 19:49:42 +0100 | [diff] [blame] | 10279 | int domain = AF_INET6; |
| 10280 | ; |
| 10281 | return 0; |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10282 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10283 | _ACEOF |
Charles-François Natali | f6fd794 | 2013-01-08 19:49:42 +0100 | [diff] [blame] | 10284 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10285 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10286 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10287 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10288 | ipv6=yes |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10289 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10290 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10291 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10292 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10293 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10294 | ipv6=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10295 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10296 | fi |
Charles-François Natali | f6fd794 | 2013-01-08 19:49:42 +0100 | [diff] [blame] | 10297 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10298 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10299 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10300 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 10301 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 10302 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10303 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10304 | |
| 10305 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10306 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10307 | int |
| 10308 | main () |
| 10309 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10310 | struct sockaddr_in6 x; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10311 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10312 | ; |
| 10313 | return 0; |
| 10314 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10315 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10316 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10317 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10318 | |
| 10319 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10320 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10321 | ipv6=yes |
| 10322 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10323 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10324 | |
| 10325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10326 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10327 | ipv6=no |
| 10328 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10329 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10330 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10331 | fi |
| 10332 | |
| 10333 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10334 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 10335 | |
| 10336 | fi |
| 10337 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10338 | fi |
| 10339 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10340 | |
| 10341 | ipv6type=unknown |
| 10342 | ipv6lib=none |
| 10343 | ipv6trylibc=no |
| 10344 | |
| 10345 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10346 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 10347 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 10348 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 10349 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10350 | case $i in |
| 10351 | inria) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10352 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10353 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10354 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10355 | #include <netinet/in.h> |
| 10356 | #ifdef IPV6_INRIA_VERSION |
| 10357 | yes |
| 10358 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10359 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10360 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10361 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 10362 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10363 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10364 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10365 | |
| 10366 | ;; |
| 10367 | kame) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10368 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10369 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10370 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10371 | #include <netinet/in.h> |
| 10372 | #ifdef __KAME__ |
| 10373 | yes |
| 10374 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10375 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10376 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10377 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10378 | ipv6type=$i; |
| 10379 | ipv6lib=inet6 |
| 10380 | ipv6libdir=/usr/local/v6/lib |
| 10381 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10382 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10383 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10384 | |
| 10385 | ;; |
| 10386 | linux-glibc) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10387 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10388 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10389 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10390 | #include <features.h> |
| 10391 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 10392 | yes |
| 10393 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10394 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10395 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10396 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10397 | ipv6type=$i; |
| 10398 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10399 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10400 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10401 | |
| 10402 | ;; |
| 10403 | linux-inet6) |
| 10404 | if test -d /usr/inet6; then |
| 10405 | ipv6type=$i |
| 10406 | ipv6lib=inet6 |
| 10407 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 10408 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10409 | fi |
| 10410 | ;; |
| 10411 | solaris) |
| 10412 | if test -f /etc/netconfig; then |
Antoine Pitrou | f3fcd9f | 2011-01-03 18:53:50 +0000 | [diff] [blame] | 10413 | if $GREP -q tcp6 /etc/netconfig; then |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10414 | ipv6type=$i |
| 10415 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10416 | fi |
| 10417 | fi |
| 10418 | ;; |
| 10419 | toshiba) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10420 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10421 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10422 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10423 | #include <sys/param.h> |
| 10424 | #ifdef _TOSHIBA_INET6 |
| 10425 | yes |
| 10426 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10427 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10428 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10429 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10430 | ipv6type=$i; |
| 10431 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 10432 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10433 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10434 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10435 | |
| 10436 | ;; |
| 10437 | v6d) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10438 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10439 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10440 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10441 | #include </usr/local/v6/include/sys/v6config.h> |
| 10442 | #ifdef __V6D__ |
| 10443 | yes |
| 10444 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10445 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10446 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10447 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10448 | ipv6type=$i; |
| 10449 | ipv6lib=v6; |
| 10450 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 10451 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10452 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10453 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10454 | |
| 10455 | ;; |
| 10456 | zeta) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10457 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10458 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 10459 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10460 | #include <sys/param.h> |
| 10461 | #ifdef _ZETA_MINAMI_INET6 |
| 10462 | yes |
| 10463 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10464 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10465 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10466 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10467 | ipv6type=$i; |
| 10468 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 10469 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10470 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 10471 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10472 | |
| 10473 | ;; |
| 10474 | esac |
| 10475 | if test "$ipv6type" != "unknown"; then |
| 10476 | break |
| 10477 | fi |
| 10478 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10479 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 10480 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 10481 | fi |
| 10482 | |
| 10483 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 10484 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 10485 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 10486 | echo "using lib$ipv6lib" |
| 10487 | else |
| 10488 | if test $ipv6trylibc = "yes"; then |
| 10489 | echo "using libc" |
| 10490 | else |
| 10491 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 10492 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 10493 | echo 'ipv6 kit and compile beforehand.' |
| 10494 | exit 1 |
| 10495 | fi |
| 10496 | fi |
| 10497 | fi |
| 10498 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10499 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 10500 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 10501 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10502 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10503 | |
| 10504 | #include <Carbon/Carbon.h> |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10505 | int |
| 10506 | main () |
| 10507 | { |
| 10508 | FSIORefNum fRef = 0 |
| 10509 | ; |
| 10510 | return 0; |
| 10511 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10512 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10513 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10514 | if ac_fn_c_try_compile "$LINENO"; then : |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10515 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10516 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10517 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10518 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10519 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10520 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10521 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10522 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10523 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10525 | $as_echo "no" >&6; } |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10526 | |
| 10527 | fi |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 10528 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 10529 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10530 | # Check for --with-doc-strings |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10531 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 10532 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10533 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10534 | # Check whether --with-doc-strings was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10535 | if test "${with_doc_strings+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10536 | withval=$with_doc_strings; |
| 10537 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10538 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10539 | |
| 10540 | if test -z "$with_doc_strings" |
| 10541 | then with_doc_strings="yes" |
| 10542 | fi |
| 10543 | if test "$with_doc_strings" != "no" |
| 10544 | then |
| 10545 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10546 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10547 | |
| 10548 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 10550 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 10551 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 10552 | # Check if eval loop should use timestamp counter profiling |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 10554 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 10555 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10556 | # Check whether --with-tsc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10557 | if test "${with_tsc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10558 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 10559 | if test "$withval" != no |
| 10560 | then |
| 10561 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10562 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 10563 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10564 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10565 | $as_echo "yes" >&6; } |
| 10566 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10567 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 10568 | fi |
| 10569 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10571 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10572 | fi |
| 10573 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 10574 | |
| 10575 | # Check for Python-specific malloc support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10576 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 10577 | $as_echo_n "checking for --with-pymalloc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10578 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10579 | # Check whether --with-pymalloc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10580 | if test "${with_pymalloc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10581 | withval=$with_pymalloc; |
| 10582 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10583 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 10584 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 10585 | if test -z "$with_pymalloc" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 10586 | then |
| 10587 | with_pymalloc="yes" |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 10588 | fi |
| 10589 | if test "$with_pymalloc" != "no" |
| 10590 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10591 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10592 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 10593 | |
doko@ubuntu.com | 9c7817e | 2012-06-30 17:05:13 +0200 | [diff] [blame] | 10594 | ABIFLAGS="${ABIFLAGS}m" |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 10595 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10596 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 10597 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 10598 | |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10599 | # Check for Valgrind support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10600 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 10601 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10602 | |
| 10603 | # Check whether --with-valgrind was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10604 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10605 | withval=$with_valgrind; |
| 10606 | else |
| 10607 | with_valgrind=no |
| 10608 | fi |
| 10609 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 10611 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10612 | if test "$with_valgrind" != no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10613 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10614 | if test "x$ac_cv_header_valgrind_valgrind_h" = xyes; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10615 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10616 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10617 | |
| 10618 | else |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 10619 | as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10620 | |
| 10621 | fi |
| 10622 | |
| 10623 | |
Jeffrey Yasskin | 3937083 | 2010-05-03 19:29:34 +0000 | [diff] [blame] | 10624 | OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT" |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 10625 | fi |
| 10626 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10627 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10628 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 10629 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10630 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10631 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 10632 | # platforms, such as AIX, have dlopen(), but don't want to use it. |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10633 | for ac_func in dlopen |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10634 | do : |
| 10635 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 10636 | if test "x$ac_cv_func_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10637 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10638 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10639 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10640 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10641 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10642 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10643 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10644 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10645 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 10646 | # loading of modules. |
| 10647 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10648 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 10649 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10650 | if test -z "$DYNLOADFILE" |
| 10651 | then |
| 10652 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 10653 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 10654 | if test "$ac_cv_func_dlopen" = yes |
| 10655 | then DYNLOADFILE="dynload_shlib.o" |
| 10656 | else DYNLOADFILE="dynload_aix.o" |
| 10657 | fi |
| 10658 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10659 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 10660 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 10661 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10662 | *) |
| 10663 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 10664 | # out any dynamic loading |
| 10665 | if test "$ac_cv_func_dlopen" = yes |
| 10666 | then DYNLOADFILE="dynload_shlib.o" |
| 10667 | else DYNLOADFILE="dynload_stub.o" |
| 10668 | fi |
| 10669 | ;; |
| 10670 | esac |
| 10671 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 10673 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10674 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 10675 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10676 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10677 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 10678 | |
| 10679 | fi |
| 10680 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 10681 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 10682 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10683 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10684 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 10685 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 10686 | if test -z "$MACHDEP_OBJS" |
| 10687 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 10688 | MACHDEP_OBJS=$extra_machdep_objs |
| 10689 | else |
| 10690 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 10691 | fi |
doko@ubuntu.com | 9c7817e | 2012-06-30 17:05:13 +0200 | [diff] [blame] | 10692 | if test -z "$MACHDEP_OBJS"; then |
| 10693 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 10694 | $as_echo "none" >&6; } |
| 10695 | else |
| 10696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP_OBJS" >&5 |
| 10697 | $as_echo "$MACHDEP_OBJS" >&6; } |
| 10698 | fi |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 10699 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10700 | # checks for library functions |
Antoine Pitrou | b1c5496 | 2010-10-14 15:05:38 +0000 | [diff] [blame] | 10701 | for ac_func in alarm accept4 setitimer getitimer bind_textdomain_codeset chown \ |
Victor Stinner | daf4555 | 2013-08-28 00:53:59 +0200 | [diff] [blame] | 10702 | clock confstr ctermid dup3 execv faccessat fchmod fchmodat fchown fchownat \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 10703 | fexecve fdopendir fork fpathconf fstatat ftime ftruncate futimesat \ |
Victor Stinner | 4d6a3d6 | 2014-12-21 01:16:38 +0100 | [diff] [blame] | 10704 | futimens futimes gai_strerror getentropy \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 10705 | getgrouplist getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 10706 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Gregory P. Smith | 5ed2e77 | 2011-05-15 00:26:45 -0700 | [diff] [blame] | 10707 | if_nameindex \ |
Antoine Pitrou | f0effe6 | 2011-11-26 01:11:02 +0100 | [diff] [blame] | 10708 | initgroups kill killpg lchmod lchown lockf linkat lstat lutimes mmap \ |
| 10709 | memrchr mbrtowc mkdirat mkfifo \ |
Charles-François Natali | daafdd5 | 2011-05-29 20:07:40 +0200 | [diff] [blame] | 10710 | mkfifoat mknod mknodat mktime mremap nice openat pathconf pause pipe2 plock poll \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 10711 | posix_fallocate posix_fadvise pread \ |
Victor Stinner | b3e7219 | 2011-05-08 01:46:11 +0200 | [diff] [blame] | 10712 | pthread_init pthread_kill putenv pwrite readlink readlinkat readv realpath renameat \ |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 10713 | select sem_open sem_timedwait sem_getvalue sem_unlink sendfile setegid seteuid \ |
Antoine Pitrou | 061cfb5 | 2011-02-28 22:25:22 +0000 | [diff] [blame] | 10714 | setgid sethostname \ |
Giampaolo Rodolà | 18e8bcb | 2011-02-25 20:57:54 +0000 | [diff] [blame] | 10715 | setlocale setregid setreuid setresuid setresgid setsid setpgid setpgrp setpriority setuid setvbuf \ |
Charles-François Natali | ea0d5fc | 2011-09-06 19:03:35 +0200 | [diff] [blame] | 10716 | sched_get_priority_max sched_setaffinity sched_setscheduler sched_setparam \ |
| 10717 | sched_rr_get_interval \ |
Ross Lagerwall | bc80822 | 2011-06-25 12:13:40 +0200 | [diff] [blame] | 10718 | sigaction sigaltstack siginterrupt sigpending sigrelse \ |
| 10719 | sigtimedwait sigwait sigwaitinfo snprintf strftime strlcpy symlinkat sync \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 10720 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 10721 | truncate uname unlinkat unsetenv utimensat utimes waitid waitpid wait3 wait4 \ |
Victor Stinner | cd777ea | 2013-04-08 22:43:44 +0200 | [diff] [blame] | 10722 | wcscoll wcsftime wcsxfrm wmemcmp writev _getpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10723 | do : |
| 10724 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10725 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 10726 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10727 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10728 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10729 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10730 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10731 | fi |
| 10732 | done |
| 10733 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10734 | |
Gregory P. Smith | df300d5 | 2012-01-21 18:20:15 -0800 | [diff] [blame] | 10735 | ac_fn_c_check_decl "$LINENO" "dirfd" "ac_cv_have_decl_dirfd" "#include <sys/types.h> |
| 10736 | #include <dirent.h> |
| 10737 | " |
| 10738 | if test "x$ac_cv_have_decl_dirfd" = xyes; then : |
| 10739 | |
| 10740 | $as_echo "#define HAVE_DIRFD 1" >>confdefs.h |
| 10741 | |
| 10742 | fi |
| 10743 | |
| 10744 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10745 | # For some functions, having a definition is not sufficient, since |
| 10746 | # we want to take their address. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10747 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 10748 | $as_echo_n "checking for chroot... " >&6; } |
| 10749 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10750 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10751 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10752 | int |
| 10753 | main () |
| 10754 | { |
| 10755 | void *x=chroot |
| 10756 | ; |
| 10757 | return 0; |
| 10758 | } |
| 10759 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10760 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10761 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10762 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10763 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10764 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10765 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10766 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10767 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10768 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10769 | |
| 10770 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10771 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10772 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 10773 | $as_echo_n "checking for link... " >&6; } |
| 10774 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10775 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10776 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10777 | int |
| 10778 | main () |
| 10779 | { |
| 10780 | void *x=link |
| 10781 | ; |
| 10782 | return 0; |
| 10783 | } |
| 10784 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10785 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10786 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10787 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10788 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10789 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10790 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10791 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10793 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10794 | |
| 10795 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10796 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10797 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 10798 | $as_echo_n "checking for symlink... " >&6; } |
| 10799 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10800 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10801 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10802 | int |
| 10803 | main () |
| 10804 | { |
| 10805 | void *x=symlink |
| 10806 | ; |
| 10807 | return 0; |
| 10808 | } |
| 10809 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10810 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10811 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10812 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10813 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10815 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10816 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10818 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10819 | |
| 10820 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10821 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 10823 | $as_echo_n "checking for fchdir... " >&6; } |
| 10824 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10825 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10826 | #include <unistd.h> |
| 10827 | int |
| 10828 | main () |
| 10829 | { |
| 10830 | void *x=fchdir |
| 10831 | ; |
| 10832 | return 0; |
| 10833 | } |
| 10834 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10835 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10836 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10837 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10838 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10839 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10840 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10841 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10842 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10843 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10844 | |
| 10845 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10846 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10847 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 10848 | $as_echo_n "checking for fsync... " >&6; } |
| 10849 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10850 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10851 | #include <unistd.h> |
| 10852 | int |
| 10853 | main () |
| 10854 | { |
| 10855 | void *x=fsync |
| 10856 | ; |
| 10857 | return 0; |
| 10858 | } |
| 10859 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10860 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10861 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10862 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10863 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10864 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10865 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10866 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10868 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10869 | |
| 10870 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10871 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10872 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 10873 | $as_echo_n "checking for fdatasync... " >&6; } |
| 10874 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10875 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10876 | #include <unistd.h> |
| 10877 | int |
| 10878 | main () |
| 10879 | { |
| 10880 | void *x=fdatasync |
| 10881 | ; |
| 10882 | return 0; |
| 10883 | } |
| 10884 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10885 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10886 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10887 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10888 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10889 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10890 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10891 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10892 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10893 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 10894 | |
| 10895 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10896 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10897 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 10898 | $as_echo_n "checking for epoll... " >&6; } |
| 10899 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10900 | /* end confdefs.h. */ |
| 10901 | #include <sys/epoll.h> |
| 10902 | int |
| 10903 | main () |
| 10904 | { |
| 10905 | void *x=epoll_create |
| 10906 | ; |
| 10907 | return 0; |
| 10908 | } |
| 10909 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10910 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 10911 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10912 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10913 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10914 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10915 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10916 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10918 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10919 | |
| 10920 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10921 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Benjamin Peterson | 95c1662 | 2011-12-27 15:36:32 -0600 | [diff] [blame] | 10922 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll_create1" >&5 |
| 10923 | $as_echo_n "checking for epoll_create1... " >&6; } |
| 10924 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 10925 | /* end confdefs.h. */ |
| 10926 | #include <sys/epoll.h> |
| 10927 | int |
| 10928 | main () |
| 10929 | { |
| 10930 | void *x=epoll_create1 |
| 10931 | ; |
| 10932 | return 0; |
| 10933 | } |
| 10934 | _ACEOF |
| 10935 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10936 | |
| 10937 | $as_echo "#define HAVE_EPOLL_CREATE1 1" >>confdefs.h |
| 10938 | |
| 10939 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10940 | $as_echo "yes" >&6; } |
| 10941 | else |
| 10942 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10943 | $as_echo "no" >&6; } |
| 10944 | |
| 10945 | fi |
| 10946 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10947 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 10948 | $as_echo_n "checking for kqueue... " >&6; } |
| 10949 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10950 | /* end confdefs.h. */ |
| 10951 | |
| 10952 | #include <sys/types.h> |
| 10953 | #include <sys/event.h> |
| 10954 | |
| 10955 | int |
| 10956 | main () |
| 10957 | { |
| 10958 | int x=kqueue() |
| 10959 | ; |
| 10960 | return 0; |
| 10961 | } |
| 10962 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10963 | if ac_fn_c_try_compile "$LINENO"; then : |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10964 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10965 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10966 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10968 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10969 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10970 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10971 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10972 | |
| 10973 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 10974 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Christian Heimes | b7bd5df | 2013-10-22 11:21:54 +0200 | [diff] [blame] | 10975 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prlimit" >&5 |
| 10976 | $as_echo_n "checking for prlimit... " >&6; } |
| 10977 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 10978 | /* end confdefs.h. */ |
| 10979 | |
| 10980 | #include <sys/time.h> |
| 10981 | #include <sys/resource.h> |
| 10982 | |
| 10983 | int |
| 10984 | main () |
| 10985 | { |
| 10986 | void *x=prlimit |
| 10987 | ; |
| 10988 | return 0; |
| 10989 | } |
| 10990 | _ACEOF |
| 10991 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10992 | |
| 10993 | $as_echo "#define HAVE_PRLIMIT 1" >>confdefs.h |
| 10994 | |
| 10995 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10996 | $as_echo "yes" >&6; } |
| 10997 | else |
| 10998 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10999 | $as_echo "no" >&6; } |
| 11000 | |
| 11001 | fi |
| 11002 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11003 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11004 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 11005 | # functions ctermid_r, setgroups in the library, but no prototype |
| 11006 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 11007 | # address to avoid compiler warnings and potential miscompilations |
| 11008 | # because of the missing prototypes. |
| 11009 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11010 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 11011 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 11012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11013 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11014 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11015 | #include <stdio.h> |
| 11016 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11017 | int |
| 11018 | main () |
| 11019 | { |
| 11020 | void* p = ctermid_r |
| 11021 | ; |
| 11022 | return 0; |
| 11023 | } |
| 11024 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11025 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11026 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11027 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11028 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11029 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11030 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11031 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11032 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11033 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11034 | |
| 11035 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11036 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11037 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11038 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5 |
| 11039 | $as_echo_n "checking for flock declaration... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11040 | if ${ac_cv_flock_decl+:} false; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11041 | $as_echo_n "(cached) " >&6 |
| 11042 | else |
| 11043 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11044 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11045 | #include <sys/file.h> |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11046 | int |
| 11047 | main () |
| 11048 | { |
| 11049 | void* p = flock |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11050 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11051 | ; |
| 11052 | return 0; |
| 11053 | } |
| 11054 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11055 | if ac_fn_c_try_compile "$LINENO"; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11056 | ac_cv_flock_decl=yes |
| 11057 | else |
| 11058 | ac_cv_flock_decl=no |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11059 | |
| 11060 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11061 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11062 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11063 | fi |
| 11064 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5 |
| 11065 | $as_echo "$ac_cv_flock_decl" >&6; } |
| 11066 | if test "x${ac_cv_flock_decl}" = xyes; then |
| 11067 | for ac_func in flock |
| 11068 | do : |
| 11069 | ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11070 | if test "x$ac_cv_func_flock" = xyes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11071 | cat >>confdefs.h <<_ACEOF |
| 11072 | #define HAVE_FLOCK 1 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11073 | _ACEOF |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11074 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11075 | else |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11076 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock in -lbsd" >&5 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11077 | $as_echo_n "checking for flock in -lbsd... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11078 | if ${ac_cv_lib_bsd_flock+:} false; then : |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11079 | $as_echo_n "(cached) " >&6 |
| 11080 | else |
| 11081 | ac_check_lib_save_LIBS=$LIBS |
| 11082 | LIBS="-lbsd $LIBS" |
| 11083 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11084 | /* end confdefs.h. */ |
| 11085 | |
| 11086 | /* Override any GCC internal prototype to avoid an error. |
| 11087 | Use char because int might match the return type of a GCC |
| 11088 | builtin and then its argument prototype would still apply. */ |
| 11089 | #ifdef __cplusplus |
| 11090 | extern "C" |
| 11091 | #endif |
| 11092 | char flock (); |
| 11093 | int |
| 11094 | main () |
| 11095 | { |
| 11096 | return flock (); |
| 11097 | ; |
| 11098 | return 0; |
| 11099 | } |
| 11100 | _ACEOF |
| 11101 | if ac_fn_c_try_link "$LINENO"; then : |
| 11102 | ac_cv_lib_bsd_flock=yes |
| 11103 | else |
| 11104 | ac_cv_lib_bsd_flock=no |
| 11105 | fi |
| 11106 | rm -f core conftest.err conftest.$ac_objext \ |
| 11107 | conftest$ac_exeext conftest.$ac_ext |
| 11108 | LIBS=$ac_check_lib_save_LIBS |
| 11109 | fi |
| 11110 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5 |
| 11111 | $as_echo "$ac_cv_lib_bsd_flock" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11112 | if test "x$ac_cv_lib_bsd_flock" = xyes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11113 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11114 | |
| 11115 | |
| 11116 | $as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h |
| 11117 | |
| 11118 | |
| 11119 | fi |
| 11120 | |
| 11121 | |
| 11122 | fi |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 11123 | done |
| 11124 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 11125 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11126 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11127 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 11128 | $as_echo_n "checking for getpagesize... " >&6; } |
| 11129 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11130 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11131 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11132 | #include <unistd.h> |
| 11133 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11134 | int |
| 11135 | main () |
| 11136 | { |
| 11137 | void* p = getpagesize |
| 11138 | ; |
| 11139 | return 0; |
| 11140 | } |
| 11141 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11142 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11143 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11144 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11145 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11146 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11147 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11148 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11149 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11150 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11151 | |
| 11152 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11153 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 11154 | |
Victor Stinner | 984890f | 2011-11-24 13:53:38 +0100 | [diff] [blame] | 11155 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken unsetenv" >&5 |
| 11156 | $as_echo_n "checking for broken unsetenv... " >&6; } |
| 11157 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11158 | /* end confdefs.h. */ |
| 11159 | |
| 11160 | #include <stdlib.h> |
| 11161 | |
| 11162 | int |
| 11163 | main () |
| 11164 | { |
| 11165 | int res = unsetenv("DUMMY") |
| 11166 | ; |
| 11167 | return 0; |
| 11168 | } |
| 11169 | _ACEOF |
| 11170 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11171 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11172 | $as_echo "no" >&6; } |
| 11173 | else |
| 11174 | |
| 11175 | $as_echo "#define HAVE_BROKEN_UNSETENV 1" >>confdefs.h |
| 11176 | |
| 11177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11178 | $as_echo "yes" >&6; } |
| 11179 | |
| 11180 | fi |
| 11181 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11182 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11183 | for ac_prog in true |
| 11184 | do |
| 11185 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 11186 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11187 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 11188 | $as_echo_n "checking for $ac_word... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11189 | if ${ac_cv_prog_TRUE+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11190 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11191 | else |
| 11192 | if test -n "$TRUE"; then |
| 11193 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 11194 | else |
| 11195 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 11196 | for as_dir in $PATH |
| 11197 | do |
| 11198 | IFS=$as_save_IFS |
| 11199 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11200 | for ac_exec_ext in '' $ac_executable_extensions; do |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 11201 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11202 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11203 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11204 | break 2 |
| 11205 | fi |
| 11206 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11207 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11208 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11209 | |
| 11210 | fi |
| 11211 | fi |
| 11212 | TRUE=$ac_cv_prog_TRUE |
| 11213 | if test -n "$TRUE"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 11215 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11216 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11217 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11218 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11219 | fi |
| 11220 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11221 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11222 | test -n "$TRUE" && break |
| 11223 | done |
| 11224 | test -n "$TRUE" || TRUE="/bin/true" |
| 11225 | |
| 11226 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11227 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 11228 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11229 | if ${ac_cv_lib_c_inet_aton+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11230 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11231 | else |
| 11232 | ac_check_lib_save_LIBS=$LIBS |
| 11233 | LIBS="-lc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11234 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11235 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11236 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11237 | /* Override any GCC internal prototype to avoid an error. |
| 11238 | Use char because int might match the return type of a GCC |
| 11239 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11240 | #ifdef __cplusplus |
| 11241 | extern "C" |
| 11242 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11243 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11244 | int |
| 11245 | main () |
| 11246 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11247 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11248 | ; |
| 11249 | return 0; |
| 11250 | } |
| 11251 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11252 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11253 | ac_cv_lib_c_inet_aton=yes |
| 11254 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11255 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11256 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11257 | rm -f core conftest.err conftest.$ac_objext \ |
| 11258 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11259 | LIBS=$ac_check_lib_save_LIBS |
| 11260 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11261 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 11262 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11263 | if test "x$ac_cv_lib_c_inet_aton" = xyes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 11264 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11265 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11266 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 11267 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11268 | if ${ac_cv_lib_resolv_inet_aton+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11269 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11270 | else |
| 11271 | ac_check_lib_save_LIBS=$LIBS |
| 11272 | LIBS="-lresolv $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11274 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11275 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11276 | /* Override any GCC internal prototype to avoid an error. |
| 11277 | Use char because int might match the return type of a GCC |
| 11278 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11279 | #ifdef __cplusplus |
| 11280 | extern "C" |
| 11281 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11282 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11283 | int |
| 11284 | main () |
| 11285 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11286 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11287 | ; |
| 11288 | return 0; |
| 11289 | } |
| 11290 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11291 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11292 | ac_cv_lib_resolv_inet_aton=yes |
| 11293 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11294 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11295 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11296 | rm -f core conftest.err conftest.$ac_objext \ |
| 11297 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11298 | LIBS=$ac_check_lib_save_LIBS |
| 11299 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11300 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 11301 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11302 | if test "x$ac_cv_lib_resolv_inet_aton" = xyes; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11303 | cat >>confdefs.h <<_ACEOF |
| 11304 | #define HAVE_LIBRESOLV 1 |
| 11305 | _ACEOF |
| 11306 | |
| 11307 | LIBS="-lresolv $LIBS" |
| 11308 | |
| 11309 | fi |
| 11310 | |
| 11311 | |
| 11312 | fi |
| 11313 | |
| 11314 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11315 | # On Tru64, chflags seems to be present, but calling it will |
| 11316 | # exit Python |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11317 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 11318 | $as_echo_n "checking for chflags... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11319 | if ${ac_cv_have_chflags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11320 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11321 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11322 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11323 | ac_cv_have_chflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11324 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11325 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11326 | /* end confdefs.h. */ |
Ned Deily | 3eb67d5 | 2011-06-28 00:00:28 -0700 | [diff] [blame] | 11327 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11328 | #include <sys/stat.h> |
| 11329 | #include <unistd.h> |
| 11330 | int main(int argc, char*argv[]) |
| 11331 | { |
| 11332 | if(chflags(argv[0], 0) != 0) |
| 11333 | return 1; |
| 11334 | return 0; |
| 11335 | } |
Ned Deily | 3eb67d5 | 2011-06-28 00:00:28 -0700 | [diff] [blame] | 11336 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11337 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11338 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11339 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 11340 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11341 | ac_cv_have_chflags=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 11342 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11343 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11344 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 11345 | fi |
| 11346 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 11347 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11348 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 11350 | $as_echo "$ac_cv_have_chflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11351 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11352 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11353 | if test "x$ac_cv_func_chflags" = xyes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11354 | ac_cv_have_chflags="yes" |
| 11355 | else |
| 11356 | ac_cv_have_chflags="no" |
| 11357 | fi |
| 11358 | |
| 11359 | fi |
| 11360 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11361 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11362 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11363 | |
| 11364 | fi |
| 11365 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11366 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 11367 | $as_echo_n "checking for lchflags... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11368 | if ${ac_cv_have_lchflags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11369 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11370 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11371 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11372 | ac_cv_have_lchflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11373 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11374 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11375 | /* end confdefs.h. */ |
Ned Deily | 3eb67d5 | 2011-06-28 00:00:28 -0700 | [diff] [blame] | 11376 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11377 | #include <sys/stat.h> |
| 11378 | #include <unistd.h> |
| 11379 | int main(int argc, char*argv[]) |
| 11380 | { |
| 11381 | if(lchflags(argv[0], 0) != 0) |
| 11382 | return 1; |
| 11383 | return 0; |
| 11384 | } |
Ned Deily | 3eb67d5 | 2011-06-28 00:00:28 -0700 | [diff] [blame] | 11385 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11386 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11387 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11388 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 11389 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11390 | ac_cv_have_lchflags=no |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 11391 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11392 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11393 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 11394 | fi |
| 11395 | |
| 11396 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11397 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11398 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 11399 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11400 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11401 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11402 | if test "x$ac_cv_func_lchflags" = xyes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 11403 | ac_cv_have_lchflags="yes" |
| 11404 | else |
| 11405 | ac_cv_have_lchflags="no" |
| 11406 | fi |
| 11407 | |
| 11408 | fi |
| 11409 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11410 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11411 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 11412 | |
| 11413 | fi |
| 11414 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11415 | case $ac_sys_system/$ac_sys_release in |
| 11416 | Darwin/*) |
| 11417 | _CUR_CFLAGS="${CFLAGS}" |
| 11418 | _CUR_LDFLAGS="${LDFLAGS}" |
| 11419 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 11420 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 11421 | ;; |
| 11422 | esac |
| 11423 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 11425 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11426 | if ${ac_cv_lib_z_inflateCopy+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11427 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11428 | else |
| 11429 | ac_check_lib_save_LIBS=$LIBS |
| 11430 | LIBS="-lz $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11431 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11432 | /* end confdefs.h. */ |
| 11433 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11434 | /* Override any GCC internal prototype to avoid an error. |
| 11435 | Use char because int might match the return type of a GCC |
| 11436 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11437 | #ifdef __cplusplus |
| 11438 | extern "C" |
| 11439 | #endif |
| 11440 | char inflateCopy (); |
| 11441 | int |
| 11442 | main () |
| 11443 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11444 | return inflateCopy (); |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11445 | ; |
| 11446 | return 0; |
| 11447 | } |
| 11448 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11449 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11450 | ac_cv_lib_z_inflateCopy=yes |
| 11451 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11452 | ac_cv_lib_z_inflateCopy=no |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11453 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11454 | rm -f core conftest.err conftest.$ac_objext \ |
| 11455 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11456 | LIBS=$ac_check_lib_save_LIBS |
| 11457 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11458 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 11459 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11460 | if test "x$ac_cv_lib_z_inflateCopy" = xyes; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11461 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11462 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 11463 | |
| 11464 | fi |
| 11465 | |
| 11466 | |
| 11467 | case $ac_sys_system/$ac_sys_release in |
| 11468 | Darwin/*) |
| 11469 | CFLAGS="${_CUR_CFLAGS}" |
| 11470 | LDFLAGS="${_CUR_LDFLAGS}" |
| 11471 | ;; |
| 11472 | esac |
| 11473 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11474 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 11475 | $as_echo_n "checking for hstrerror... " >&6; } |
| 11476 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11477 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11478 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11479 | #include <netdb.h> |
| 11480 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11481 | int |
| 11482 | main () |
| 11483 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11484 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11485 | ; |
| 11486 | return 0; |
| 11487 | } |
| 11488 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11489 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11490 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11491 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11492 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11493 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11494 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11495 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11496 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11497 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11498 | |
| 11499 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11500 | rm -f core conftest.err conftest.$ac_objext \ |
| 11501 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11502 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11503 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 11504 | $as_echo_n "checking for inet_aton... " >&6; } |
| 11505 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11506 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11507 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 11508 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11509 | #include <sys/socket.h> |
| 11510 | #include <netinet/in.h> |
| 11511 | #include <arpa/inet.h> |
| 11512 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11513 | int |
| 11514 | main () |
| 11515 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 11516 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11517 | ; |
| 11518 | return 0; |
| 11519 | } |
| 11520 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11521 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11522 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11523 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11524 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11525 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11526 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11527 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11528 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11529 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11530 | |
| 11531 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11532 | rm -f core conftest.err conftest.$ac_objext \ |
| 11533 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11534 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11535 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 11536 | $as_echo_n "checking for inet_pton... " >&6; } |
| 11537 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11538 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11539 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 11540 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11541 | #include <sys/socket.h> |
| 11542 | #include <netinet/in.h> |
| 11543 | #include <arpa/inet.h> |
| 11544 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11545 | int |
| 11546 | main () |
| 11547 | { |
| 11548 | void* p = inet_pton |
| 11549 | ; |
| 11550 | return 0; |
| 11551 | } |
| 11552 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11553 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11554 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11555 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11556 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11557 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11558 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11559 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11560 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11561 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11562 | |
| 11563 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11564 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 11565 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 11566 | # On some systems, setgroups is in unistd.h, on others, in grp.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11567 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 11568 | $as_echo_n "checking for setgroups... " >&6; } |
| 11569 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11570 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11571 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 11572 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 11573 | #ifdef HAVE_GRP_H |
| 11574 | #include <grp.h> |
| 11575 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11576 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11577 | int |
| 11578 | main () |
| 11579 | { |
| 11580 | void* p = setgroups |
| 11581 | ; |
| 11582 | return 0; |
| 11583 | } |
| 11584 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11585 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11586 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11587 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11588 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11589 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11590 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11591 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11593 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11594 | |
| 11595 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11596 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 11597 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 11598 | # check for openpty and forkpty |
| 11599 | |
| 11600 | for ac_func in openpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11601 | do : |
| 11602 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11603 | if test "x$ac_cv_func_openpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11604 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11605 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11606 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 11607 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 11608 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 11610 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11611 | if ${ac_cv_lib_util_openpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11612 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11613 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11614 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11615 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11616 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11617 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11618 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11619 | /* Override any GCC internal prototype to avoid an error. |
| 11620 | Use char because int might match the return type of a GCC |
| 11621 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11622 | #ifdef __cplusplus |
| 11623 | extern "C" |
| 11624 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11625 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11626 | int |
| 11627 | main () |
| 11628 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11629 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11630 | ; |
| 11631 | return 0; |
| 11632 | } |
| 11633 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11634 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11635 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11636 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11637 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11638 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11639 | rm -f core conftest.err conftest.$ac_objext \ |
| 11640 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11641 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11642 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11643 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 11644 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11645 | if test "x$ac_cv_lib_util_openpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11646 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11647 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11648 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11649 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 11650 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11651 | if ${ac_cv_lib_bsd_openpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11652 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11653 | else |
| 11654 | ac_check_lib_save_LIBS=$LIBS |
| 11655 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11656 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11657 | /* end confdefs.h. */ |
| 11658 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11659 | /* Override any GCC internal prototype to avoid an error. |
| 11660 | Use char because int might match the return type of a GCC |
| 11661 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11662 | #ifdef __cplusplus |
| 11663 | extern "C" |
| 11664 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11665 | char openpty (); |
| 11666 | int |
| 11667 | main () |
| 11668 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11669 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11670 | ; |
| 11671 | return 0; |
| 11672 | } |
| 11673 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11674 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11675 | ac_cv_lib_bsd_openpty=yes |
| 11676 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11677 | ac_cv_lib_bsd_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11678 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11679 | rm -f core conftest.err conftest.$ac_objext \ |
| 11680 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11681 | LIBS=$ac_check_lib_save_LIBS |
| 11682 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11683 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 11684 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11685 | if test "x$ac_cv_lib_bsd_openpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11686 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11687 | LIBS="$LIBS -lbsd" |
| 11688 | fi |
| 11689 | |
| 11690 | |
| 11691 | fi |
| 11692 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11693 | |
| 11694 | fi |
| 11695 | done |
| 11696 | |
| 11697 | for ac_func in forkpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11698 | do : |
| 11699 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11700 | if test "x$ac_cv_func_forkpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11701 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11702 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11703 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11704 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11705 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11706 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 11707 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11708 | if ${ac_cv_lib_util_forkpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11709 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11710 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11711 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11712 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11713 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11714 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11715 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11716 | /* Override any GCC internal prototype to avoid an error. |
| 11717 | Use char because int might match the return type of a GCC |
| 11718 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11719 | #ifdef __cplusplus |
| 11720 | extern "C" |
| 11721 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11722 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11723 | int |
| 11724 | main () |
| 11725 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11726 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11727 | ; |
| 11728 | return 0; |
| 11729 | } |
| 11730 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11731 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11732 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11733 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11734 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11735 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11736 | rm -f core conftest.err conftest.$ac_objext \ |
| 11737 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11738 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11739 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 11741 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11742 | if test "x$ac_cv_lib_util_forkpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11743 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11744 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11745 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 11747 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11748 | if ${ac_cv_lib_bsd_forkpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11749 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11750 | else |
| 11751 | ac_check_lib_save_LIBS=$LIBS |
| 11752 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11753 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11754 | /* end confdefs.h. */ |
| 11755 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11756 | /* Override any GCC internal prototype to avoid an error. |
| 11757 | Use char because int might match the return type of a GCC |
| 11758 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11759 | #ifdef __cplusplus |
| 11760 | extern "C" |
| 11761 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11762 | char forkpty (); |
| 11763 | int |
| 11764 | main () |
| 11765 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11766 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11767 | ; |
| 11768 | return 0; |
| 11769 | } |
| 11770 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11771 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11772 | ac_cv_lib_bsd_forkpty=yes |
| 11773 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11774 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11775 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11776 | rm -f core conftest.err conftest.$ac_objext \ |
| 11777 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11778 | LIBS=$ac_check_lib_save_LIBS |
| 11779 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 11781 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11782 | if test "x$ac_cv_lib_bsd_forkpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11783 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 11784 | LIBS="$LIBS -lbsd" |
| 11785 | fi |
| 11786 | |
| 11787 | |
| 11788 | fi |
| 11789 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11790 | |
| 11791 | fi |
| 11792 | done |
| 11793 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11794 | |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 11795 | # Stuff for expat. |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 11796 | for ac_func in memmove |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11797 | do : |
| 11798 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11799 | if test "x$ac_cv_func_memmove" = xyes; then : |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 11800 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11801 | #define HAVE_MEMMOVE 1 |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 11802 | _ACEOF |
| 11803 | |
| 11804 | fi |
| 11805 | done |
| 11806 | |
| 11807 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11808 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 11809 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11810 | do : |
| 11811 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11812 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11813 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11814 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11815 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11816 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11817 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11818 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11819 | done |
| 11820 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11821 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11822 | ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11823 | if test "x$ac_cv_func_dup2" = xyes; then : |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11824 | $as_echo "#define HAVE_DUP2 1" >>confdefs.h |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 11825 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 11826 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11827 | case " $LIBOBJS " in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11828 | *" dup2.$ac_objext "* ) ;; |
| 11829 | *) LIBOBJS="$LIBOBJS dup2.$ac_objext" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11830 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 11831 | esac |
| 11832 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 11833 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11834 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11835 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11836 | if test "x$ac_cv_func_strdup" = xyes; then : |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 11837 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h |
| 11838 | |
| 11839 | else |
| 11840 | case " $LIBOBJS " in |
| 11841 | *" strdup.$ac_objext "* ) ;; |
| 11842 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" |
| 11843 | ;; |
| 11844 | esac |
| 11845 | |
| 11846 | fi |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 11847 | |
| 11848 | |
| 11849 | for ac_func in getpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11850 | do : |
| 11851 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11852 | if test "x$ac_cv_func_getpgrp" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11853 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11854 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11855 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11856 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11857 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11858 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11859 | int |
| 11860 | main () |
| 11861 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11862 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11863 | ; |
| 11864 | return 0; |
| 11865 | } |
| 11866 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11867 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11868 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11869 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11870 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11871 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11872 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11873 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11874 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11875 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11876 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11877 | for ac_func in setpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11878 | do : |
| 11879 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11880 | if test "x$ac_cv_func_setpgrp" = xyes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11881 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11882 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11883 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11884 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11885 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11886 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11887 | int |
| 11888 | main () |
| 11889 | { |
| 11890 | setpgrp(0,0); |
| 11891 | ; |
| 11892 | return 0; |
| 11893 | } |
| 11894 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11895 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11896 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11897 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11898 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 11899 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11900 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 11901 | |
| 11902 | fi |
| 11903 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 11904 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11905 | for ac_func in gettimeofday |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11906 | do : |
| 11907 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11908 | if test "x$ac_cv_func_gettimeofday" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11909 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11910 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11911 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11912 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11913 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11914 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11915 | int |
| 11916 | main () |
| 11917 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11918 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11919 | ; |
| 11920 | return 0; |
| 11921 | } |
| 11922 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11923 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11924 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11925 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11926 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11927 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11928 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11929 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11930 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11931 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11932 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11933 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11934 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11935 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11936 | |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11937 | for ac_func in clock_gettime |
| 11938 | do : |
| 11939 | ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime" |
| 11940 | if test "x$ac_cv_func_clock_gettime" = xyes; then : |
| 11941 | cat >>confdefs.h <<_ACEOF |
| 11942 | #define HAVE_CLOCK_GETTIME 1 |
| 11943 | _ACEOF |
| 11944 | |
| 11945 | else |
| 11946 | |
| 11947 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5 |
| 11948 | $as_echo_n "checking for clock_gettime in -lrt... " >&6; } |
| 11949 | if ${ac_cv_lib_rt_clock_gettime+:} false; then : |
| 11950 | $as_echo_n "(cached) " >&6 |
| 11951 | else |
| 11952 | ac_check_lib_save_LIBS=$LIBS |
| 11953 | LIBS="-lrt $LIBS" |
| 11954 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11955 | /* end confdefs.h. */ |
| 11956 | |
| 11957 | /* Override any GCC internal prototype to avoid an error. |
| 11958 | Use char because int might match the return type of a GCC |
| 11959 | builtin and then its argument prototype would still apply. */ |
| 11960 | #ifdef __cplusplus |
| 11961 | extern "C" |
| 11962 | #endif |
| 11963 | char clock_gettime (); |
| 11964 | int |
| 11965 | main () |
| 11966 | { |
| 11967 | return clock_gettime (); |
| 11968 | ; |
| 11969 | return 0; |
| 11970 | } |
| 11971 | _ACEOF |
| 11972 | if ac_fn_c_try_link "$LINENO"; then : |
| 11973 | ac_cv_lib_rt_clock_gettime=yes |
| 11974 | else |
| 11975 | ac_cv_lib_rt_clock_gettime=no |
| 11976 | fi |
| 11977 | rm -f core conftest.err conftest.$ac_objext \ |
| 11978 | conftest$ac_exeext conftest.$ac_ext |
| 11979 | LIBS=$ac_check_lib_save_LIBS |
| 11980 | fi |
| 11981 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5 |
| 11982 | $as_echo "$ac_cv_lib_rt_clock_gettime" >&6; } |
| 11983 | if test "x$ac_cv_lib_rt_clock_gettime" = xyes; then : |
| 11984 | |
Victor Stinner | 7efb833 | 2014-08-29 15:41:08 +0200 | [diff] [blame] | 11985 | LIBS="$LIBS -lrt" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 11986 | $as_echo "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h |
| 11987 | |
| 11988 | |
| 11989 | $as_echo "#define TIMEMODULE_LIB rt" >>confdefs.h |
| 11990 | |
| 11991 | |
| 11992 | fi |
| 11993 | |
| 11994 | |
| 11995 | fi |
| 11996 | done |
| 11997 | |
| 11998 | |
| 11999 | for ac_func in clock_getres |
| 12000 | do : |
| 12001 | ac_fn_c_check_func "$LINENO" "clock_getres" "ac_cv_func_clock_getres" |
| 12002 | if test "x$ac_cv_func_clock_getres" = xyes; then : |
| 12003 | cat >>confdefs.h <<_ACEOF |
| 12004 | #define HAVE_CLOCK_GETRES 1 |
| 12005 | _ACEOF |
| 12006 | |
| 12007 | else |
| 12008 | |
| 12009 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_getres in -lrt" >&5 |
| 12010 | $as_echo_n "checking for clock_getres in -lrt... " >&6; } |
| 12011 | if ${ac_cv_lib_rt_clock_getres+:} false; then : |
| 12012 | $as_echo_n "(cached) " >&6 |
| 12013 | else |
| 12014 | ac_check_lib_save_LIBS=$LIBS |
| 12015 | LIBS="-lrt $LIBS" |
| 12016 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12017 | /* end confdefs.h. */ |
| 12018 | |
| 12019 | /* Override any GCC internal prototype to avoid an error. |
| 12020 | Use char because int might match the return type of a GCC |
| 12021 | builtin and then its argument prototype would still apply. */ |
| 12022 | #ifdef __cplusplus |
| 12023 | extern "C" |
| 12024 | #endif |
| 12025 | char clock_getres (); |
| 12026 | int |
| 12027 | main () |
| 12028 | { |
| 12029 | return clock_getres (); |
| 12030 | ; |
| 12031 | return 0; |
| 12032 | } |
| 12033 | _ACEOF |
| 12034 | if ac_fn_c_try_link "$LINENO"; then : |
| 12035 | ac_cv_lib_rt_clock_getres=yes |
| 12036 | else |
| 12037 | ac_cv_lib_rt_clock_getres=no |
| 12038 | fi |
| 12039 | rm -f core conftest.err conftest.$ac_objext \ |
| 12040 | conftest$ac_exeext conftest.$ac_ext |
| 12041 | LIBS=$ac_check_lib_save_LIBS |
| 12042 | fi |
| 12043 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_getres" >&5 |
| 12044 | $as_echo "$ac_cv_lib_rt_clock_getres" >&6; } |
| 12045 | if test "x$ac_cv_lib_rt_clock_getres" = xyes; then : |
| 12046 | |
| 12047 | $as_echo "#define HAVE_CLOCK_GETRES 1" >>confdefs.h |
| 12048 | |
| 12049 | |
| 12050 | fi |
| 12051 | |
| 12052 | |
| 12053 | fi |
| 12054 | done |
| 12055 | |
| 12056 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12057 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 12058 | $as_echo_n "checking for major... " >&6; } |
| 12059 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12060 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12061 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 12062 | #if defined(MAJOR_IN_MKDEV) |
| 12063 | #include <sys/mkdev.h> |
| 12064 | #elif defined(MAJOR_IN_SYSMACROS) |
| 12065 | #include <sys/sysmacros.h> |
| 12066 | #else |
| 12067 | #include <sys/types.h> |
| 12068 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12069 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12070 | int |
| 12071 | main () |
| 12072 | { |
| 12073 | |
| 12074 | makedev(major(0),minor(0)); |
| 12075 | |
| 12076 | ; |
| 12077 | return 0; |
| 12078 | } |
| 12079 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12080 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12081 | |
| 12082 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12083 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12084 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12085 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 12086 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12087 | |
| 12088 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12089 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12090 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 12091 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 12092 | |
| 12093 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12094 | rm -f core conftest.err conftest.$ac_objext \ |
| 12095 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12096 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12097 | # On OSF/1 V5.1, getaddrinfo is available, but a define |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12098 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12099 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 12100 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 12101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12102 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12103 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 12104 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12105 | #include <sys/socket.h> |
| 12106 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 12107 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12108 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12109 | int |
| 12110 | main () |
| 12111 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12112 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12113 | ; |
| 12114 | return 0; |
| 12115 | } |
| 12116 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12117 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12118 | have_getaddrinfo=yes |
| 12119 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12120 | have_getaddrinfo=no |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12121 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12122 | rm -f core conftest.err conftest.$ac_objext \ |
| 12123 | conftest$ac_exeext conftest.$ac_ext |
| 12124 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 12125 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12126 | if test $have_getaddrinfo = yes |
| 12127 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 12129 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12130 | if ${ac_cv_buggy_getaddrinfo+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12131 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12132 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12133 | if test "$cross_compiling" = yes; then : |
Matthias Klose | 9635013 | 2012-03-15 20:42:23 +0100 | [diff] [blame] | 12134 | |
| 12135 | if test "${enable_ipv6+set}" = set; then |
| 12136 | ac_cv_buggy_getaddrinfo="no -- configured with --(en|dis)able-ipv6" |
| 12137 | else |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12138 | ac_cv_buggy_getaddrinfo=yes |
Matthias Klose | 9635013 | 2012-03-15 20:42:23 +0100 | [diff] [blame] | 12139 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12140 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12141 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12142 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12143 | |
Stefan Krah | 19c2139 | 2012-11-22 23:47:32 +0100 | [diff] [blame] | 12144 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12145 | #include <sys/types.h> |
| 12146 | #include <netdb.h> |
| 12147 | #include <string.h> |
| 12148 | #include <sys/socket.h> |
| 12149 | #include <netinet/in.h> |
| 12150 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12151 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12152 | { |
| 12153 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 12154 | struct addrinfo hints, *ai, *aitop; |
| 12155 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 12156 | |
| 12157 | for (passive = 0; passive <= 1; passive++) { |
| 12158 | memset(&hints, 0, sizeof(hints)); |
| 12159 | hints.ai_family = AF_UNSPEC; |
| 12160 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 12161 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 12162 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12163 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 12164 | (void)gai_strerror(gaierr); |
| 12165 | goto bad; |
| 12166 | } |
| 12167 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 12168 | if (ai->ai_addr == NULL || |
| 12169 | ai->ai_addrlen == 0 || |
| 12170 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 12171 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 12172 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 12173 | goto bad; |
| 12174 | } |
| 12175 | switch (ai->ai_family) { |
| 12176 | case AF_INET: |
| 12177 | if (strcmp(strport, "54321") != 0) { |
| 12178 | goto bad; |
| 12179 | } |
| 12180 | if (passive) { |
| 12181 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 12182 | goto bad; |
| 12183 | } |
| 12184 | } else { |
| 12185 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 12186 | goto bad; |
| 12187 | } |
| 12188 | } |
| 12189 | inet4++; |
| 12190 | break; |
| 12191 | case AF_INET6: |
| 12192 | if (strcmp(strport, "54321") != 0) { |
| 12193 | goto bad; |
| 12194 | } |
| 12195 | if (passive) { |
| 12196 | if (strcmp(straddr, "::") != 0) { |
| 12197 | goto bad; |
| 12198 | } |
| 12199 | } else { |
| 12200 | if (strcmp(straddr, "::1") != 0) { |
| 12201 | goto bad; |
| 12202 | } |
| 12203 | } |
| 12204 | inet6++; |
| 12205 | break; |
| 12206 | case AF_UNSPEC: |
| 12207 | goto bad; |
| 12208 | break; |
| 12209 | default: |
| 12210 | /* another family support? */ |
| 12211 | break; |
| 12212 | } |
| 12213 | } |
| 12214 | } |
| 12215 | |
| 12216 | if (!(inet4 == 0 || inet4 == 2)) |
| 12217 | goto bad; |
| 12218 | if (!(inet6 == 0 || inet6 == 2)) |
| 12219 | goto bad; |
| 12220 | |
| 12221 | if (aitop) |
| 12222 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12223 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12224 | |
| 12225 | bad: |
| 12226 | if (aitop) |
| 12227 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12228 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12229 | } |
| 12230 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12231 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12232 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12233 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12234 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12235 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12236 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12237 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12238 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12239 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12240 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12241 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12242 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12243 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12244 | |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 12245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5 |
| 12246 | $as_echo "$ac_cv_buggy_getaddrinfo" >&6; } |
| 12247 | |
doko@ubuntu.com | 9c7817e | 2012-06-30 17:05:13 +0200 | [diff] [blame] | 12248 | if test $have_getaddrinfo = no || test "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12249 | then |
| 12250 | if test $ipv6 = yes |
| 12251 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12252 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 12253 | echo ' or you can specify "--disable-ipv6"'. |
| 12254 | exit 1 |
| 12255 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12256 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12257 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12258 | $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 12259 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12260 | fi |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 12261 | |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 12262 | for ac_func in getnameinfo |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12263 | do : |
| 12264 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12265 | if test "x$ac_cv_func_getnameinfo" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12266 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12267 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12268 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12269 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12270 | fi |
| 12271 | done |
| 12272 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12273 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12274 | # checks for structures |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12275 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 12276 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12277 | if ${ac_cv_header_time+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12278 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12279 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12280 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12281 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12282 | #include <sys/types.h> |
| 12283 | #include <sys/time.h> |
| 12284 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12285 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12286 | int |
| 12287 | main () |
| 12288 | { |
| 12289 | if ((struct tm *) 0) |
| 12290 | return 0; |
| 12291 | ; |
| 12292 | return 0; |
| 12293 | } |
| 12294 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12295 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12296 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12297 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12298 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12299 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12300 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12301 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12302 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 12303 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12304 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12305 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12306 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12307 | |
| 12308 | fi |
| 12309 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12310 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 12311 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12312 | if ${ac_cv_struct_tm+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12313 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12314 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12315 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12316 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12317 | #include <sys/types.h> |
| 12318 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12319 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12320 | int |
| 12321 | main () |
| 12322 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12323 | struct tm tm; |
| 12324 | int *p = &tm.tm_sec; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12325 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12326 | ; |
| 12327 | return 0; |
| 12328 | } |
| 12329 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12330 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12331 | ac_cv_struct_tm=time.h |
| 12332 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12333 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12334 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12335 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12336 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12337 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
| 12338 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12339 | if test $ac_cv_struct_tm = sys/time.h; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12340 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12341 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12342 | |
| 12343 | fi |
| 12344 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12345 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12346 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12347 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12348 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12349 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12350 | |
| 12351 | cat >>confdefs.h <<_ACEOF |
| 12352 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 12353 | _ACEOF |
| 12354 | |
| 12355 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12356 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 12357 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12358 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 12359 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12360 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12361 | |
| 12362 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12363 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 12364 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12365 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12366 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12367 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12368 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12369 | fi |
| 12370 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12371 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12372 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12373 | _ACEOF |
| 12374 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12375 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 12376 | $as_echo_n "checking for tzname... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12377 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12378 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12379 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12380 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12381 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12382 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12383 | #if !HAVE_DECL_TZNAME |
| 12384 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12385 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12386 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12387 | int |
| 12388 | main () |
| 12389 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12390 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12391 | ; |
| 12392 | return 0; |
| 12393 | } |
| 12394 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12395 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12396 | ac_cv_var_tzname=yes |
| 12397 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12398 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12399 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12400 | rm -f core conftest.err conftest.$ac_objext \ |
| 12401 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12402 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12403 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 12404 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12405 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12406 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12407 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12408 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12409 | fi |
| 12410 | fi |
| 12411 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12412 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12413 | if test "x$ac_cv_member_struct_stat_st_rdev" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12414 | |
| 12415 | cat >>confdefs.h <<_ACEOF |
| 12416 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 12417 | _ACEOF |
| 12418 | |
| 12419 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 12420 | fi |
| 12421 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12422 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12423 | if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 12424 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12425 | cat >>confdefs.h <<_ACEOF |
| 12426 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 12427 | _ACEOF |
| 12428 | |
| 12429 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 12430 | fi |
| 12431 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12432 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12433 | if test "x$ac_cv_member_struct_stat_st_flags" = xyes; then : |
Hye-Shik Chang | 5f937a7 | 2005-06-02 13:09:30 +0000 | [diff] [blame] | 12434 | |
| 12435 | cat >>confdefs.h <<_ACEOF |
| 12436 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 12437 | _ACEOF |
| 12438 | |
| 12439 | |
| 12440 | fi |
| 12441 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12442 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12443 | if test "x$ac_cv_member_struct_stat_st_gen" = xyes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 12444 | |
| 12445 | cat >>confdefs.h <<_ACEOF |
| 12446 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 12447 | _ACEOF |
| 12448 | |
| 12449 | |
| 12450 | fi |
| 12451 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12452 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12453 | if test "x$ac_cv_member_struct_stat_st_birthtime" = xyes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 12454 | |
| 12455 | cat >>confdefs.h <<_ACEOF |
| 12456 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 12457 | _ACEOF |
| 12458 | |
| 12459 | |
| 12460 | fi |
| 12461 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12462 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12463 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 12464 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12465 | cat >>confdefs.h <<_ACEOF |
| 12466 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 12467 | _ACEOF |
| 12468 | |
| 12469 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12470 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 12471 | |
| 12472 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12473 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 12474 | *" fileblocks.$ac_objext "* ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12475 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 12476 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 12477 | esac |
| 12478 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 12479 | fi |
| 12480 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12481 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12482 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12483 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 12484 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12485 | if ${ac_cv_header_time_altzone+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12486 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12487 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12488 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12489 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12490 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12491 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12492 | int |
| 12493 | main () |
| 12494 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12495 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12496 | ; |
| 12497 | return 0; |
| 12498 | } |
| 12499 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12500 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12501 | ac_cv_header_time_altzone=yes |
| 12502 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12503 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12504 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12505 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12506 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12507 | fi |
| 12508 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12509 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 12510 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12511 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12512 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12513 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12514 | |
| 12515 | fi |
| 12516 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12517 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12518 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 12519 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 12520 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12521 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12522 | |
| 12523 | #include <sys/types.h> |
| 12524 | #include <sys/select.h> |
| 12525 | #include <sys/time.h> |
| 12526 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12527 | int |
| 12528 | main () |
| 12529 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12530 | ; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12531 | ; |
| 12532 | return 0; |
| 12533 | } |
| 12534 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12535 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12536 | |
| 12537 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12538 | $as_echo "#define SYS_SELECT_WITH_SYS_TIME 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12539 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12540 | was_it_defined=yes |
| 12541 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12542 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12543 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12544 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 12545 | $as_echo "$was_it_defined" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12546 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12547 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 12548 | $as_echo_n "checking for addrinfo... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12549 | if ${ac_cv_struct_addrinfo+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12550 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12551 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12552 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12553 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12554 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12555 | int |
| 12556 | main () |
| 12557 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12558 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12559 | ; |
| 12560 | return 0; |
| 12561 | } |
| 12562 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12563 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12564 | ac_cv_struct_addrinfo=yes |
| 12565 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12566 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12567 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12568 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12569 | fi |
| 12570 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 12572 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12573 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12574 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12575 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12576 | |
| 12577 | fi |
| 12578 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12579 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 12580 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12581 | if ${ac_cv_struct_sockaddr_storage+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12582 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12583 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12584 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12585 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12586 | |
| 12587 | # include <sys/types.h> |
| 12588 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12589 | int |
| 12590 | main () |
| 12591 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12592 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12593 | ; |
| 12594 | return 0; |
| 12595 | } |
| 12596 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12597 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12598 | ac_cv_struct_sockaddr_storage=yes |
| 12599 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12600 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12601 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12602 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12603 | fi |
| 12604 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12605 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 12606 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12607 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12608 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12609 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12610 | |
| 12611 | fi |
| 12612 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12613 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12614 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12615 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 12616 | $as_echo_n "checking whether char is unsigned... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12617 | if ${ac_cv_c_char_unsigned+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12618 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 12619 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12620 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12621 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12622 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12623 | int |
| 12624 | main () |
| 12625 | { |
| 12626 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12627 | test_array [0] = 0; |
| 12628 | return test_array [0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12629 | |
| 12630 | ; |
| 12631 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12632 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12633 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12634 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12635 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12636 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12637 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12638 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12639 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12640 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12641 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 12642 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12643 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12644 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12645 | |
| 12646 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12647 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12648 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 12649 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12650 | if ${ac_cv_c_const+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12651 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12652 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12653 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12654 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12655 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12656 | int |
| 12657 | main () |
| 12658 | { |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12659 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12660 | #ifndef __cplusplus |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12661 | /* Ultrix mips cc rejects this sort of thing. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12662 | typedef int charset[2]; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12663 | const charset cs = { 0, 0 }; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12664 | /* SunOS 4.1.1 cc rejects this. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12665 | char const *const *pcpcc; |
| 12666 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12667 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 12668 | struct point {int x, y;}; |
| 12669 | static struct point const zero = {0,0}; |
| 12670 | /* AIX XL C 1.02.0.0 rejects this. |
| 12671 | It does not let you subtract one const X* pointer from another in |
| 12672 | an arm of an if-expression whose if-part is not a constant |
| 12673 | expression */ |
| 12674 | const char *g = "string"; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12675 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12676 | /* HPUX 7.0 cc rejects these. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12677 | ++pcpcc; |
| 12678 | ppc = (char**) pcpcc; |
| 12679 | pcpcc = (char const *const *) ppc; |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12680 | { /* SCO 3.2v4 cc rejects this sort of thing. */ |
| 12681 | char tx; |
| 12682 | char *t = &tx; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12683 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12684 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12685 | *t++ = 0; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12686 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12687 | } |
| 12688 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 12689 | int x[] = {25, 17}; |
| 12690 | const int *foo = &x[0]; |
| 12691 | ++foo; |
| 12692 | } |
| 12693 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 12694 | typedef const int *iptr; |
| 12695 | iptr p = 0; |
| 12696 | ++p; |
| 12697 | } |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12698 | { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12699 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 12700 | struct s { int j; const int *ap[3]; } bx; |
| 12701 | struct s *b = &bx; b->j = 5; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12702 | } |
| 12703 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 12704 | const int foo = 10; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12705 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12706 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12707 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12708 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12709 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12710 | ; |
| 12711 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12712 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12713 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12714 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12715 | ac_cv_c_const=yes |
| 12716 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12717 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12718 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12719 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12720 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12721 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 12722 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12723 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12724 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12725 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12726 | |
| 12727 | fi |
| 12728 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12729 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12730 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 12732 | $as_echo_n "checking for working volatile... " >&6; } |
| 12733 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12734 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12735 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12736 | int |
| 12737 | main () |
| 12738 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12739 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12740 | ; |
| 12741 | return 0; |
| 12742 | } |
| 12743 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12744 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12745 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12746 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12747 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12748 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12749 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12750 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12751 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12752 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12753 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 12754 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12755 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12756 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12757 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 12758 | $as_echo_n "checking for working signed char... " >&6; } |
| 12759 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12760 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 12761 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12762 | int |
| 12763 | main () |
| 12764 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12765 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12766 | ; |
| 12767 | return 0; |
| 12768 | } |
| 12769 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12770 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12771 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 12772 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12773 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12774 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12775 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12776 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12777 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12778 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12779 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 12780 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12781 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12782 | have_prototypes=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12783 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 12784 | $as_echo_n "checking for prototypes... " >&6; } |
| 12785 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12786 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12787 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12788 | int |
| 12789 | main () |
| 12790 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12791 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12792 | ; |
| 12793 | return 0; |
| 12794 | } |
| 12795 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12796 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12797 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12798 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12799 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12800 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12801 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12802 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12803 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 12804 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12805 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12806 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12807 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 12808 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 12809 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12810 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12811 | |
| 12812 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 12813 | int foo(int x, ...) { |
| 12814 | va_list va; |
| 12815 | va_start(va, x); |
| 12816 | va_arg(va, int); |
| 12817 | va_arg(va, char *); |
| 12818 | va_arg(va, double); |
| 12819 | return 0; |
| 12820 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 12821 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12822 | int |
| 12823 | main () |
| 12824 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 12825 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12826 | ; |
| 12827 | return 0; |
| 12828 | } |
| 12829 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12830 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12831 | |
| 12832 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12833 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12834 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12835 | works=yes |
| 12836 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 12837 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12838 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12839 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 12840 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12841 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12842 | # check for socketpair |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12843 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 12844 | $as_echo_n "checking for socketpair... " >&6; } |
| 12845 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12846 | /* end confdefs.h. */ |
| 12847 | |
| 12848 | #include <sys/types.h> |
| 12849 | #include <sys/socket.h> |
| 12850 | |
| 12851 | int |
| 12852 | main () |
| 12853 | { |
| 12854 | void *x=socketpair |
| 12855 | ; |
| 12856 | return 0; |
| 12857 | } |
| 12858 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12859 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12860 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12861 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12862 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12863 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12864 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12865 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12866 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 12867 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12868 | |
| 12869 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12870 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 12871 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12872 | # check if sockaddr has sa_len member |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12873 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 12874 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 12875 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12876 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12877 | #include <sys/types.h> |
| 12878 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12879 | int |
| 12880 | main () |
| 12881 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12882 | struct sockaddr x; |
| 12883 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12884 | ; |
| 12885 | return 0; |
| 12886 | } |
| 12887 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12888 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12889 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 12890 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12891 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12892 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12893 | |
| 12894 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12895 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 12896 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12897 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12898 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12899 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 12900 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12901 | va_list_is_array=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12902 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 12903 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 12904 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12905 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12906 | |
| 12907 | #ifdef HAVE_STDARG_PROTOTYPES |
| 12908 | #include <stdarg.h> |
| 12909 | #else |
| 12910 | #include <varargs.h> |
| 12911 | #endif |
| 12912 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12913 | int |
| 12914 | main () |
| 12915 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12916 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12917 | ; |
| 12918 | return 0; |
| 12919 | } |
| 12920 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12921 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12922 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12923 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12924 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12925 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12926 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12927 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 12928 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12929 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12930 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12931 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12932 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 12933 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12934 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12935 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12936 | |
| 12937 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12938 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 12939 | if test "x$ac_cv_func_gethostbyname_r" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12940 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12941 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 12942 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12943 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 12944 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12945 | OLD_CFLAGS=$CFLAGS |
| 12946 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12947 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12948 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12949 | |
| 12950 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12951 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12952 | int |
| 12953 | main () |
| 12954 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12955 | |
| 12956 | char *name; |
| 12957 | struct hostent *he, *res; |
| 12958 | char buffer[2048]; |
| 12959 | int buflen = 2048; |
| 12960 | int h_errnop; |
| 12961 | |
| 12962 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12963 | |
| 12964 | ; |
| 12965 | return 0; |
| 12966 | } |
| 12967 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12968 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12969 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12970 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 12971 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12972 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12973 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12974 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 12976 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12977 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12978 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12979 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12980 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 12981 | $as_echo "no" >&6; } |
| 12982 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 12983 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 12984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12985 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12986 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12987 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12988 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12989 | int |
| 12990 | main () |
| 12991 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12992 | |
| 12993 | char *name; |
| 12994 | struct hostent *he; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12995 | char buffer[2048]; |
| 12996 | int buflen = 2048; |
| 12997 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 12998 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12999 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13000 | |
| 13001 | ; |
| 13002 | return 0; |
| 13003 | } |
| 13004 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13005 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13006 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13007 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 13008 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13009 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13010 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13011 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13013 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13014 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13015 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13016 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13017 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13018 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13019 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 13020 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 13021 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13022 | /* end confdefs.h. */ |
| 13023 | |
| 13024 | # include <netdb.h> |
| 13025 | |
| 13026 | int |
| 13027 | main () |
| 13028 | { |
| 13029 | |
| 13030 | char *name; |
| 13031 | struct hostent *he; |
| 13032 | struct hostent_data data; |
| 13033 | |
| 13034 | (void) gethostbyname_r(name, he, &data); |
| 13035 | |
| 13036 | ; |
| 13037 | return 0; |
| 13038 | } |
| 13039 | _ACEOF |
| 13040 | if ac_fn_c_try_compile "$LINENO"; then : |
| 13041 | |
| 13042 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 13043 | |
| 13044 | |
| 13045 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 13046 | |
| 13047 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13048 | $as_echo "yes" >&6; } |
| 13049 | |
| 13050 | else |
| 13051 | |
| 13052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13053 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13054 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13055 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13056 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13057 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13058 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13059 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13060 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13061 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13062 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13063 | CFLAGS=$OLD_CFLAGS |
| 13064 | |
| 13065 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13066 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13067 | for ac_func in gethostbyname |
| 13068 | do : |
| 13069 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13070 | if test "x$ac_cv_func_gethostbyname" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13071 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13072 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13073 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13074 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13075 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 13076 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13077 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13078 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 13079 | fi |
| 13080 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13081 | |
| 13082 | |
| 13083 | |
| 13084 | |
| 13085 | |
| 13086 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13087 | # checks for system services |
| 13088 | # (none yet) |
| 13089 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13090 | # Linux requires this for correct f.p. operations |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13091 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13092 | if test "x$ac_cv_func___fpu_control" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13093 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 13094 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13095 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 13096 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13097 | if ${ac_cv_lib_ieee___fpu_control+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13098 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13099 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13100 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13101 | LIBS="-lieee $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13102 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13103 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13104 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13105 | /* Override any GCC internal prototype to avoid an error. |
| 13106 | Use char because int might match the return type of a GCC |
| 13107 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13108 | #ifdef __cplusplus |
| 13109 | extern "C" |
| 13110 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13111 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13112 | int |
| 13113 | main () |
| 13114 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13115 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13116 | ; |
| 13117 | return 0; |
| 13118 | } |
| 13119 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13120 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13121 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13122 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13123 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13124 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13125 | rm -f core conftest.err conftest.$ac_objext \ |
| 13126 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13127 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13128 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13129 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 13130 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13131 | if test "x$ac_cv_lib_ieee___fpu_control" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13132 | cat >>confdefs.h <<_ACEOF |
| 13133 | #define HAVE_LIBIEEE 1 |
| 13134 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13135 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13136 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13137 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13138 | fi |
| 13139 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13140 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 13141 | fi |
| 13142 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13143 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13144 | # Check for --with-fpectl |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13145 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 13146 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13147 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13148 | # Check whether --with-fpectl was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13149 | if test "${with_fpectl+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13150 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13151 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13152 | then |
| 13153 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13154 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13155 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13156 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13157 | $as_echo "yes" >&6; } |
| 13158 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13159 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13160 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13161 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13163 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13164 | fi |
| 13165 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13166 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13167 | # check for --with-libm=... |
| 13168 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 13169 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 13170 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 13171 | *) LIBM=-lm |
| 13172 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13173 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 13174 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13175 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13176 | # Check whether --with-libm was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13177 | if test "${with_libm+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13178 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13179 | if test "$withval" = no |
| 13180 | then LIBM= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13181 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 13182 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13183 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13184 | then LIBM=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 13186 | $as_echo "set LIBM=\"$withval\"" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 13187 | else as_fn_error $? "proper usage is --with-libm=STRING" "$LINENO" 5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13188 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13189 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 13191 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13192 | fi |
| 13193 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13194 | |
| 13195 | # check for --with-libc=... |
| 13196 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 13198 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13199 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13200 | # Check whether --with-libc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13201 | if test "${with_libc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13202 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13203 | if test "$withval" = no |
| 13204 | then LIBC= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13205 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 13206 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13207 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13208 | then LIBC=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 13210 | $as_echo "set LIBC=\"$withval\"" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 13211 | else as_fn_error $? "proper usage is --with-libc=STRING" "$LINENO" 5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13212 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 13213 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 13215 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13216 | fi |
| 13217 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 13218 | |
Stefan Krah | 1919b7e | 2012-03-21 18:25:23 +0100 | [diff] [blame] | 13219 | # ************************************** |
| 13220 | # * Check for gcc x64 inline assembler * |
| 13221 | # ************************************** |
| 13222 | |
| 13223 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x64 gcc inline assembler" >&5 |
| 13224 | $as_echo_n "checking for x64 gcc inline assembler... " >&6; } |
| 13225 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13226 | /* end confdefs.h. */ |
| 13227 | |
| 13228 | int |
| 13229 | main () |
| 13230 | { |
| 13231 | |
| 13232 | __asm__ __volatile__ ("movq %rcx, %rax"); |
| 13233 | |
| 13234 | ; |
| 13235 | return 0; |
| 13236 | } |
| 13237 | _ACEOF |
| 13238 | if ac_fn_c_try_compile "$LINENO"; then : |
| 13239 | have_gcc_asm_for_x64=yes |
| 13240 | else |
| 13241 | have_gcc_asm_for_x64=no |
| 13242 | fi |
| 13243 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13244 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x64" >&5 |
| 13245 | $as_echo "$have_gcc_asm_for_x64" >&6; } |
| 13246 | if test "$have_gcc_asm_for_x64" = yes |
| 13247 | then |
| 13248 | |
| 13249 | $as_echo "#define HAVE_GCC_ASM_FOR_X64 1" >>confdefs.h |
| 13250 | |
| 13251 | fi |
| 13252 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13253 | # ************************************************** |
| 13254 | # * Check for various properties of floating point * |
| 13255 | # ************************************************** |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13256 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13257 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 13258 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13259 | if ${ac_cv_little_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13260 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13261 | else |
| 13262 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13263 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13264 | ac_cv_little_endian_double=no |
| 13265 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13266 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13267 | /* end confdefs.h. */ |
| 13268 | |
| 13269 | #include <string.h> |
| 13270 | int main() { |
| 13271 | double x = 9006104071832581.0; |
| 13272 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 13273 | return 0; |
| 13274 | else |
| 13275 | return 1; |
| 13276 | } |
| 13277 | |
| 13278 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13279 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13280 | ac_cv_little_endian_double=yes |
| 13281 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13282 | ac_cv_little_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13283 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13284 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13285 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13286 | fi |
| 13287 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13288 | fi |
| 13289 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13290 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 13291 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13292 | if test "$ac_cv_little_endian_double" = yes |
| 13293 | then |
| 13294 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13295 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13296 | |
| 13297 | fi |
| 13298 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 13300 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13301 | if ${ac_cv_big_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13302 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13303 | else |
| 13304 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13305 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13306 | ac_cv_big_endian_double=no |
| 13307 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13308 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13309 | /* end confdefs.h. */ |
| 13310 | |
| 13311 | #include <string.h> |
| 13312 | int main() { |
| 13313 | double x = 9006104071832581.0; |
| 13314 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 13315 | return 0; |
| 13316 | else |
| 13317 | return 1; |
| 13318 | } |
| 13319 | |
| 13320 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13321 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13322 | ac_cv_big_endian_double=yes |
| 13323 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13324 | ac_cv_big_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13325 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13326 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13327 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13328 | fi |
| 13329 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13330 | fi |
| 13331 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 13333 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13334 | if test "$ac_cv_big_endian_double" = yes |
| 13335 | then |
| 13336 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13337 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13338 | |
| 13339 | fi |
| 13340 | |
| 13341 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 13342 | # While Python doesn't currently have full support for these platforms |
| 13343 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 13344 | # conversions work. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13345 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 13346 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13347 | if ${ac_cv_mixed_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13348 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13349 | else |
| 13350 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13351 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13352 | ac_cv_mixed_endian_double=no |
| 13353 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13354 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13355 | /* end confdefs.h. */ |
| 13356 | |
| 13357 | #include <string.h> |
| 13358 | int main() { |
| 13359 | double x = 9006104071832581.0; |
| 13360 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 13361 | return 0; |
| 13362 | else |
| 13363 | return 1; |
| 13364 | } |
| 13365 | |
| 13366 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13367 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13368 | ac_cv_mixed_endian_double=yes |
| 13369 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13370 | ac_cv_mixed_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13371 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13372 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13373 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13374 | fi |
| 13375 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13376 | fi |
| 13377 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13378 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 13379 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13380 | if test "$ac_cv_mixed_endian_double" = yes |
| 13381 | then |
| 13382 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13383 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13384 | |
| 13385 | fi |
| 13386 | |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 13387 | # The short float repr introduced in Python 3.1 requires the |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13388 | # correctly-rounded string <-> double conversion functions from |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 13389 | # Python/dtoa.c, which in turn require that the FPU uses 53-bit |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13390 | # rounding; this is a problem on x86, where the x87 FPU has a default |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 13391 | # rounding precision of 64 bits. For gcc/x86, we can fix this by |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13392 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 13393 | |
| 13394 | # This inline assembler syntax may also work for suncc and icc, |
| 13395 | # so we try it on all platforms. |
| 13396 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13397 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 13398 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 13399 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13400 | /* end confdefs.h. */ |
| 13401 | |
| 13402 | int |
| 13403 | main () |
| 13404 | { |
| 13405 | |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 13406 | unsigned short cw; |
| 13407 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 13408 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13409 | |
| 13410 | ; |
| 13411 | return 0; |
| 13412 | } |
| 13413 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13414 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13415 | have_gcc_asm_for_x87=yes |
| 13416 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13417 | have_gcc_asm_for_x87=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13418 | fi |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13419 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13420 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 13421 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 13422 | if test "$have_gcc_asm_for_x87" = yes |
| 13423 | then |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13424 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13425 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13426 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13427 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13428 | |
Benjamin Peterson | 8bdeb16 | 2014-04-17 00:00:31 -0400 | [diff] [blame] | 13429 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set mc68881 fpcr" >&5 |
| 13430 | $as_echo_n "checking whether we can use gcc inline assembler to get and set mc68881 fpcr... " >&6; } |
| 13431 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13432 | /* end confdefs.h. */ |
| 13433 | |
| 13434 | int |
| 13435 | main () |
| 13436 | { |
| 13437 | |
| 13438 | unsigned int fpcr; |
| 13439 | __asm__ __volatile__ ("fmove.l %%fpcr,%0" : "=g" (fpcr)); |
| 13440 | __asm__ __volatile__ ("fmove.l %0,%%fpcr" : : "g" (fpcr)); |
| 13441 | |
| 13442 | ; |
| 13443 | return 0; |
| 13444 | } |
| 13445 | _ACEOF |
| 13446 | if ac_fn_c_try_compile "$LINENO"; then : |
| 13447 | have_gcc_asm_for_mc68881=yes |
| 13448 | else |
| 13449 | have_gcc_asm_for_mc68881=no |
| 13450 | fi |
| 13451 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13452 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_mc68881" >&5 |
| 13453 | $as_echo "$have_gcc_asm_for_mc68881" >&6; } |
| 13454 | if test "$have_gcc_asm_for_mc68881" = yes |
| 13455 | then |
| 13456 | |
| 13457 | $as_echo "#define HAVE_GCC_ASM_FOR_MC68881 1" >>confdefs.h |
| 13458 | |
| 13459 | fi |
| 13460 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13461 | # Detect whether system arithmetic is subject to x87-style double |
| 13462 | # rounding issues. The result of this test has little meaning on non |
| 13463 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 13464 | # mode is round-to-nearest and double rounding issues are present, and |
| 13465 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13466 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 13467 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13468 | # $BASECFLAGS may affect the result |
| 13469 | ac_save_cc="$CC" |
| 13470 | CC="$CC $BASECFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13471 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13472 | ac_cv_x87_double_rounding=no |
| 13473 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13474 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13475 | /* end confdefs.h. */ |
| 13476 | |
| 13477 | #include <stdlib.h> |
| 13478 | #include <math.h> |
| 13479 | int main() { |
| 13480 | volatile double x, y, z; |
| 13481 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 13482 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 13483 | y = 1./x; |
| 13484 | if (y != 1.) |
| 13485 | exit(0); |
| 13486 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 13487 | x = 1e16; |
| 13488 | y = 2.99999; |
| 13489 | z = x + y; |
| 13490 | if (z != 1e16+4.) |
| 13491 | exit(0); |
| 13492 | /* both tests show evidence of double rounding */ |
| 13493 | exit(1); |
| 13494 | } |
| 13495 | |
| 13496 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13497 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13498 | ac_cv_x87_double_rounding=no |
| 13499 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13500 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13501 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13502 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13503 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13504 | fi |
| 13505 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13506 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13507 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 13508 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13509 | if test "$ac_cv_x87_double_rounding" = yes |
| 13510 | then |
| 13511 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13512 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13513 | |
| 13514 | fi |
| 13515 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 13516 | # ************************************ |
| 13517 | # * Check for mathematical functions * |
| 13518 | # ************************************ |
| 13519 | |
| 13520 | LIBS_SAVE=$LIBS |
| 13521 | LIBS="$LIBS $LIBM" |
| 13522 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13523 | for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma |
| 13524 | do : |
| 13525 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 13526 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 13527 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13528 | cat >>confdefs.h <<_ACEOF |
| 13529 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 13530 | _ACEOF |
| 13531 | |
| 13532 | fi |
| 13533 | done |
| 13534 | |
Victor Stinner | 8f9f8d6 | 2011-05-09 12:45:41 +0200 | [diff] [blame] | 13535 | for ac_func in hypot lgamma log1p log2 round tgamma |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13536 | do : |
| 13537 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 13538 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 13539 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13540 | cat >>confdefs.h <<_ACEOF |
| 13541 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 13542 | _ACEOF |
| 13543 | |
| 13544 | fi |
| 13545 | done |
| 13546 | |
| 13547 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 13548 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13549 | if test "x$ac_cv_have_decl_isinf" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13550 | ac_have_decl=1 |
| 13551 | else |
| 13552 | ac_have_decl=0 |
| 13553 | fi |
| 13554 | |
| 13555 | cat >>confdefs.h <<_ACEOF |
| 13556 | #define HAVE_DECL_ISINF $ac_have_decl |
| 13557 | _ACEOF |
| 13558 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 13559 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13560 | if test "x$ac_cv_have_decl_isnan" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13561 | ac_have_decl=1 |
| 13562 | else |
| 13563 | ac_have_decl=0 |
| 13564 | fi |
| 13565 | |
| 13566 | cat >>confdefs.h <<_ACEOF |
| 13567 | #define HAVE_DECL_ISNAN $ac_have_decl |
| 13568 | _ACEOF |
| 13569 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 13570 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13571 | if test "x$ac_cv_have_decl_isfinite" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13572 | ac_have_decl=1 |
| 13573 | else |
| 13574 | ac_have_decl=0 |
| 13575 | fi |
| 13576 | |
| 13577 | cat >>confdefs.h <<_ACEOF |
| 13578 | #define HAVE_DECL_ISFINITE $ac_have_decl |
| 13579 | _ACEOF |
| 13580 | |
| 13581 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13582 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 13583 | # -0. on some architectures. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13584 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 13585 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13586 | if ${ac_cv_tanh_preserves_zero_sign+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13587 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13588 | else |
| 13589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13590 | if test "$cross_compiling" = yes; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13591 | ac_cv_tanh_preserves_zero_sign=no |
| 13592 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13593 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13594 | /* end confdefs.h. */ |
| 13595 | |
| 13596 | #include <math.h> |
| 13597 | #include <stdlib.h> |
| 13598 | int main() { |
| 13599 | /* return 0 if either negative zeros don't exist |
| 13600 | on this platform or if negative zeros exist |
| 13601 | and tanh(-0.) == -0. */ |
| 13602 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 13603 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 13604 | else exit(1); |
| 13605 | } |
| 13606 | |
| 13607 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13608 | if ac_fn_c_try_run "$LINENO"; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13609 | ac_cv_tanh_preserves_zero_sign=yes |
| 13610 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13611 | ac_cv_tanh_preserves_zero_sign=no |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13612 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13613 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13614 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13615 | fi |
| 13616 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13617 | fi |
| 13618 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13619 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 13620 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13621 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 13622 | then |
| 13623 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13624 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 13625 | |
| 13626 | fi |
| 13627 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13628 | if test "$ac_cv_func_log1p" = yes |
| 13629 | then |
| 13630 | # On some versions of AIX, log1p(-0.) returns 0. instead of |
| 13631 | # -0. See issue #9920. |
| 13632 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether log1p drops the sign of negative zero" >&5 |
| 13633 | $as_echo_n "checking whether log1p drops the sign of negative zero... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13634 | if ${ac_cv_log1p_drops_zero_sign+:} false; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13635 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13636 | else |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13637 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13638 | if test "$cross_compiling" = yes; then : |
| 13639 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13640 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13641 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13642 | /* end confdefs.h. */ |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13643 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13644 | #include <math.h> |
| 13645 | #include <stdlib.h> |
| 13646 | int main() { |
| 13647 | /* Fail if the signs of log1p(-0.) and -0. can be |
| 13648 | distinguished. */ |
| 13649 | if (atan2(log1p(-0.), -1.) == atan2(-0., -1.)) |
| 13650 | return 0; |
| 13651 | else |
| 13652 | return 1; |
| 13653 | } |
| 13654 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13655 | _ACEOF |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13656 | if ac_fn_c_try_run "$LINENO"; then : |
| 13657 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13658 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13659 | ac_cv_log1p_drops_zero_sign=yes |
| 13660 | fi |
| 13661 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13662 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13663 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13664 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13665 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13666 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 13667 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_log1p_drops_zero_sign" >&5 |
| 13668 | $as_echo "$ac_cv_log1p_drops_zero_sign" >&6; } |
| 13669 | fi |
| 13670 | if test "$ac_cv_log1p_drops_zero_sign" = yes |
| 13671 | then |
| 13672 | |
| 13673 | $as_echo "#define LOG1P_DROPS_ZERO_SIGN 1" >>confdefs.h |
| 13674 | |
| 13675 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 13676 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 13677 | LIBS=$LIBS_SAVE |
| 13678 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13679 | # For multiprocessing module, check that sem_open |
| 13680 | # actually works. For FreeBSD versions <= 7.2, |
| 13681 | # the kernel module that provides POSIX semaphores |
| 13682 | # isn't loaded by default, so an attempt to call |
| 13683 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13684 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 13685 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13686 | if ${ac_cv_posix_semaphores_enabled+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13687 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13688 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13689 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13690 | ac_cv_posix_semaphores_enabled=yes |
| 13691 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13692 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13693 | /* end confdefs.h. */ |
| 13694 | |
| 13695 | #include <unistd.h> |
| 13696 | #include <fcntl.h> |
| 13697 | #include <stdio.h> |
| 13698 | #include <semaphore.h> |
| 13699 | #include <sys/stat.h> |
| 13700 | |
| 13701 | int main(void) { |
| 13702 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 13703 | if (a == SEM_FAILED) { |
| 13704 | perror("sem_open"); |
| 13705 | return 1; |
| 13706 | } |
| 13707 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 13708 | sem_unlink("/autoconf"); |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13709 | return 0; |
| 13710 | } |
| 13711 | |
| 13712 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13713 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13714 | ac_cv_posix_semaphores_enabled=yes |
| 13715 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13716 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13717 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13718 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13719 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13720 | fi |
| 13721 | |
| 13722 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13723 | fi |
| 13724 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13725 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 13726 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13727 | if test $ac_cv_posix_semaphores_enabled = no |
| 13728 | then |
| 13729 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13730 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 13731 | |
| 13732 | fi |
| 13733 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13734 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13735 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 13736 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13737 | if ${ac_cv_broken_sem_getvalue+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13738 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13739 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13740 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13741 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13742 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13743 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13744 | /* end confdefs.h. */ |
| 13745 | |
| 13746 | #include <unistd.h> |
| 13747 | #include <fcntl.h> |
| 13748 | #include <stdio.h> |
| 13749 | #include <semaphore.h> |
| 13750 | #include <sys/stat.h> |
| 13751 | |
| 13752 | int main(void){ |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 13753 | sem_t *a = sem_open("/autocftw", O_CREAT, S_IRUSR|S_IWUSR, 0); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13754 | int count; |
| 13755 | int res; |
| 13756 | if(a==SEM_FAILED){ |
| 13757 | perror("sem_open"); |
| 13758 | return 1; |
| 13759 | |
| 13760 | } |
| 13761 | res = sem_getvalue(a, &count); |
| 13762 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 13763 | sem_unlink("/autocftw"); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13764 | return res==-1 ? 1 : 0; |
| 13765 | } |
| 13766 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13767 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13768 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13769 | ac_cv_broken_sem_getvalue=no |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 13770 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13771 | ac_cv_broken_sem_getvalue=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13772 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13773 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13774 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 13775 | fi |
| 13776 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13777 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13778 | fi |
| 13779 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 13781 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13782 | if test $ac_cv_broken_sem_getvalue = yes |
| 13783 | then |
| 13784 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13785 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13786 | |
| 13787 | fi |
| 13788 | |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13789 | # determine what size digit to use for Python's longs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13790 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 13791 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13792 | # Check whether --enable-big-digits was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13793 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13794 | enableval=$enable_big_digits; case $enable_big_digits in |
| 13795 | yes) |
| 13796 | enable_big_digits=30 ;; |
| 13797 | no) |
| 13798 | enable_big_digits=15 ;; |
| 13799 | 15|30) |
| 13800 | ;; |
| 13801 | *) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13802 | as_fn_error $? "bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" "$LINENO" 5 ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13803 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 13805 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13806 | |
| 13807 | cat >>confdefs.h <<_ACEOF |
| 13808 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 13809 | _ACEOF |
| 13810 | |
| 13811 | |
| 13812 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13813 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 13814 | $as_echo "no value specified" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 13815 | fi |
| 13816 | |
| 13817 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13818 | # check for wchar.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13819 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13820 | if test "x$ac_cv_header_wchar_h" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13821 | |
| 13822 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13823 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13824 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 13825 | wchar_h="yes" |
| 13826 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13827 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13828 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13829 | |
| 13830 | fi |
| 13831 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13832 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13833 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13834 | # determine wchar_t size |
| 13835 | if test "$wchar_h" = yes |
| 13836 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13837 | # The cast to long int works around a bug in the HP C Compiler |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13838 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 13839 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 13840 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13841 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 13842 | $as_echo_n "checking size of wchar_t... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13843 | if ${ac_cv_sizeof_wchar_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13844 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13845 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13846 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 13847 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13848 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13849 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13850 | if test "$ac_cv_type_wchar_t" = yes; then |
| 13851 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 13852 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 13853 | as_fn_error 77 "cannot compute sizeof (wchar_t) |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13854 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13855 | else |
| 13856 | ac_cv_sizeof_wchar_t=0 |
| 13857 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13858 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13859 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13860 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 13862 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13863 | |
| 13864 | |
| 13865 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13866 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13867 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13868 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13869 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13870 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13871 | fi |
| 13872 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13873 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 13874 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13875 | have_ucs4_tcl=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13876 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13877 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13878 | |
| 13879 | #include <tcl.h> |
| 13880 | #if TCL_UTF_MAX != 6 |
| 13881 | # error "NOT UCS4_TCL" |
| 13882 | #endif |
| 13883 | int |
| 13884 | main () |
| 13885 | { |
| 13886 | |
| 13887 | ; |
| 13888 | return 0; |
| 13889 | } |
| 13890 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13891 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13892 | |
| 13893 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13894 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13895 | |
| 13896 | have_ucs4_tcl=yes |
| 13897 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13898 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13899 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13900 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 13901 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 13902 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13903 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13904 | if test "$wchar_h" = yes |
| 13905 | then |
| 13906 | # check whether wchar_t is signed or not |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13907 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 13908 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13909 | if ${ac_cv_wchar_t_signed+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13910 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13911 | else |
| 13912 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13913 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13914 | ac_cv_wchar_t_signed=yes |
| 13915 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13916 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13917 | /* end confdefs.h. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13918 | |
| 13919 | #include <wchar.h> |
| 13920 | int main() |
| 13921 | { |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 13922 | /* Success: exit code 0 */ |
| 13923 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13924 | } |
| 13925 | |
| 13926 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13927 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13928 | ac_cv_wchar_t_signed=yes |
| 13929 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13930 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13931 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13932 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13933 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13934 | fi |
| 13935 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 13936 | fi |
| 13937 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13938 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 13939 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13940 | fi |
| 13941 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 13942 | # wchar_t is only usable if it maps to an unsigned type |
Martin v. Löwis | d63a3b8 | 2011-09-28 07:41:54 +0200 | [diff] [blame] | 13943 | if test "$ac_cv_sizeof_wchar_t" -ge 2 \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 13944 | -a "$ac_cv_wchar_t_signed" = "no" |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 13945 | then |
Martin v. Löwis | d63a3b8 | 2011-09-28 07:41:54 +0200 | [diff] [blame] | 13946 | HAVE_USABLE_WCHAR_T="yes" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13947 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13948 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13949 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 13950 | else |
Martin v. Löwis | d63a3b8 | 2011-09-28 07:41:54 +0200 | [diff] [blame] | 13951 | HAVE_USABLE_WCHAR_T="no usable wchar_t found" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 13952 | fi |
Martin v. Löwis | d63a3b8 | 2011-09-28 07:41:54 +0200 | [diff] [blame] | 13953 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_USABLE_WCHAR_T" >&5 |
| 13954 | $as_echo "$HAVE_USABLE_WCHAR_T" >&6; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13955 | |
| 13956 | # check for endianness |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13957 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 13958 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 13959 | if ${ac_cv_c_bigendian+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13960 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 13961 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13962 | ac_cv_c_bigendian=unknown |
| 13963 | # See if we're dealing with a universal compiler. |
| 13964 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13965 | /* end confdefs.h. */ |
| 13966 | #ifndef __APPLE_CC__ |
| 13967 | not a universal capable compiler |
| 13968 | #endif |
| 13969 | typedef int dummy; |
| 13970 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13971 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13972 | if ac_fn_c_try_compile "$LINENO"; then : |
| 13973 | |
| 13974 | # Check for potential -arch flags. It is not universal unless |
| 13975 | # there are at least two -arch flags with different values. |
| 13976 | ac_arch= |
| 13977 | ac_prev= |
| 13978 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 13979 | if test -n "$ac_prev"; then |
| 13980 | case $ac_word in |
| 13981 | i?86 | x86_64 | ppc | ppc64) |
| 13982 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 13983 | ac_arch=$ac_word |
| 13984 | else |
| 13985 | ac_cv_c_bigendian=universal |
| 13986 | break |
| 13987 | fi |
| 13988 | ;; |
| 13989 | esac |
| 13990 | ac_prev= |
| 13991 | elif test "x$ac_word" = "x-arch"; then |
| 13992 | ac_prev=arch |
| 13993 | fi |
| 13994 | done |
| 13995 | fi |
| 13996 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13997 | if test $ac_cv_c_bigendian = unknown; then |
| 13998 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 13999 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14000 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14001 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14002 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14003 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14004 | int |
| 14005 | main () |
| 14006 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14007 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 14008 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 14009 | && LITTLE_ENDIAN) |
| 14010 | bogus endian macros |
| 14011 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14012 | |
| 14013 | ; |
| 14014 | return 0; |
| 14015 | } |
| 14016 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14017 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14018 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14019 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14020 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14021 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14022 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14023 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14024 | int |
| 14025 | main () |
| 14026 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14027 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14028 | not big endian |
| 14029 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14030 | |
| 14031 | ; |
| 14032 | return 0; |
| 14033 | } |
| 14034 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14035 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14036 | ac_cv_c_bigendian=yes |
| 14037 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14038 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14039 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14040 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14041 | fi |
| 14042 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 14043 | fi |
| 14044 | if test $ac_cv_c_bigendian = unknown; then |
| 14045 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 14046 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14047 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14048 | #include <limits.h> |
| 14049 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14050 | int |
| 14051 | main () |
| 14052 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14053 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 14054 | bogus endian macros |
| 14055 | #endif |
| 14056 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14057 | ; |
| 14058 | return 0; |
| 14059 | } |
| 14060 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14061 | if ac_fn_c_try_compile "$LINENO"; then : |
| 14062 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 14063 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 14064 | /* end confdefs.h. */ |
| 14065 | #include <limits.h> |
| 14066 | |
| 14067 | int |
| 14068 | main () |
| 14069 | { |
| 14070 | #ifndef _BIG_ENDIAN |
| 14071 | not big endian |
| 14072 | #endif |
| 14073 | |
| 14074 | ; |
| 14075 | return 0; |
| 14076 | } |
| 14077 | _ACEOF |
| 14078 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14079 | ac_cv_c_bigendian=yes |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 14080 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14081 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14082 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14083 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 14084 | fi |
| 14085 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 14086 | fi |
| 14087 | if test $ac_cv_c_bigendian = unknown; then |
| 14088 | # Compile a test program. |
| 14089 | if test "$cross_compiling" = yes; then : |
| 14090 | # Try to guess by grepping values from an object file. |
| 14091 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 14092 | /* end confdefs.h. */ |
| 14093 | short int ascii_mm[] = |
| 14094 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 14095 | short int ascii_ii[] = |
| 14096 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 14097 | int use_ascii (int i) { |
| 14098 | return ascii_mm[i] + ascii_ii[i]; |
| 14099 | } |
| 14100 | short int ebcdic_ii[] = |
| 14101 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 14102 | short int ebcdic_mm[] = |
| 14103 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 14104 | int use_ebcdic (int i) { |
| 14105 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 14106 | } |
| 14107 | extern int foo; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14108 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14109 | int |
| 14110 | main () |
| 14111 | { |
| 14112 | return use_ascii (foo) == use_ebcdic (foo); |
| 14113 | ; |
| 14114 | return 0; |
| 14115 | } |
| 14116 | _ACEOF |
| 14117 | if ac_fn_c_try_compile "$LINENO"; then : |
| 14118 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 14119 | ac_cv_c_bigendian=yes |
| 14120 | fi |
| 14121 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 14122 | if test "$ac_cv_c_bigendian" = unknown; then |
| 14123 | ac_cv_c_bigendian=no |
| 14124 | else |
| 14125 | # finding both strings is unlikely to happen, but who knows? |
| 14126 | ac_cv_c_bigendian=unknown |
| 14127 | fi |
| 14128 | fi |
| 14129 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14130 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14131 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14132 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14133 | /* end confdefs.h. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14134 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14135 | int |
| 14136 | main () |
| 14137 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14138 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14139 | /* Are we little or big endian? From Harbison&Steele. */ |
| 14140 | union |
| 14141 | { |
| 14142 | long int l; |
| 14143 | char c[sizeof (long int)]; |
| 14144 | } u; |
| 14145 | u.l = 1; |
| 14146 | return u.c[sizeof (long int) - 1] == 1; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14147 | |
| 14148 | ; |
| 14149 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14150 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14151 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14152 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14153 | ac_cv_c_bigendian=no |
| 14154 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14155 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14156 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14157 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 14158 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14159 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14160 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14161 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14162 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14163 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 14164 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 14165 | case $ac_cv_c_bigendian in #( |
| 14166 | yes) |
| 14167 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 14168 | ;; #( |
| 14169 | no) |
| 14170 | ;; #( |
| 14171 | universal) |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14172 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14173 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 14174 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14175 | ;; #( |
| 14176 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 14177 | as_fn_error $? "unknown endianness |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14178 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14179 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 14180 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14181 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 14182 | # ABI version string for Python extension modules. This appears between the |
| 14183 | # periods in shared library file names, e.g. foo.<SOABI>.so. It is calculated |
| 14184 | # from the following attributes which affect the ABI of this Python build (in |
| 14185 | # this order): |
| 14186 | # |
| 14187 | # * The Python implementation (always 'cpython-' for us) |
| 14188 | # * The major and minor version numbers |
| 14189 | # * --with-pydebug (adds a 'd') |
| 14190 | # * --with-pymalloc (adds a 'm') |
| 14191 | # * --with-wide-unicode (adds a 'u') |
| 14192 | # |
| 14193 | # Thus for example, Python 3.2 built with wide unicode, pydebug, and pymalloc, |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14194 | # would get a shared library ABI version tag of 'cpython-32dmu' and shared |
| 14195 | # libraries would be named 'foo.cpython-32dmu.so'. |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 14196 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 14197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ABIFLAGS" >&5 |
| 14198 | $as_echo_n "checking ABIFLAGS... " >&6; } |
| 14199 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ABIFLAGS" >&5 |
| 14200 | $as_echo "$ABIFLAGS" >&6; } |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 14201 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5 |
| 14202 | $as_echo_n "checking SOABI... " >&6; } |
Antoine Pitrou | 5bd7bf5 | 2015-03-08 20:43:10 +0100 | [diff] [blame] | 14203 | |
| 14204 | case $ac_sys_system in |
| 14205 | Linux*|GNU*) |
| 14206 | BITNESS_SUFFIX=-$(($ac_cv_sizeof_void_p * 8))b;; |
| 14207 | *) |
| 14208 | BITNESS_SUFFIX=;; |
| 14209 | esac |
| 14210 | SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS}${BITNESS_SUFFIX} |
| 14211 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 14212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5 |
| 14213 | $as_echo "$SOABI" >&6; } |
| 14214 | |
doko@ubuntu.com | d5537d0 | 2013-03-21 13:21:49 -0700 | [diff] [blame] | 14215 | |
| 14216 | case $ac_sys_system in |
| 14217 | Linux*|GNU*) |
| 14218 | EXT_SUFFIX=.${SOABI}${SHLIB_SUFFIX};; |
| 14219 | *) |
| 14220 | EXT_SUFFIX=${SHLIB_SUFFIX};; |
| 14221 | esac |
| 14222 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 14223 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5 |
| 14224 | $as_echo_n "checking LDVERSION... " >&6; } |
| 14225 | LDVERSION='$(VERSION)$(ABIFLAGS)' |
| 14226 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5 |
| 14227 | $as_echo "$LDVERSION" >&6; } |
| 14228 | |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 14229 | |
| 14230 | LIBPL="${prefix}/lib/python${VERSION}/config-${LDVERSION}" |
| 14231 | |
| 14232 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14233 | # Check whether right shifting a negative integer extends the sign bit |
| 14234 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14235 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 14236 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14237 | if ${ac_cv_rshift_extends_sign+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14238 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14239 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14240 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14241 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 14242 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14243 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14244 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14245 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14246 | |
| 14247 | int main() |
| 14248 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14249 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14250 | } |
| 14251 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14252 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14253 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14254 | ac_cv_rshift_extends_sign=yes |
| 14255 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14256 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14257 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14258 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 14259 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14260 | fi |
| 14261 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14262 | fi |
| 14263 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14264 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 14265 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 14266 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14267 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14268 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14269 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14270 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14271 | fi |
| 14272 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14273 | # check for getc_unlocked and related locking functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14274 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 14275 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14276 | if ${ac_cv_have_getc_unlocked+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14277 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14278 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14279 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14280 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14281 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14282 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14283 | int |
| 14284 | main () |
| 14285 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14286 | |
| 14287 | FILE *f = fopen("/dev/null", "r"); |
| 14288 | flockfile(f); |
| 14289 | getc_unlocked(f); |
| 14290 | funlockfile(f); |
| 14291 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14292 | ; |
| 14293 | return 0; |
| 14294 | } |
| 14295 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14296 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14297 | ac_cv_have_getc_unlocked=yes |
| 14298 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14299 | ac_cv_have_getc_unlocked=no |
| 14300 | fi |
| 14301 | rm -f core conftest.err conftest.$ac_objext \ |
| 14302 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14303 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14304 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14305 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 14306 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14307 | if test "$ac_cv_have_getc_unlocked" = yes |
| 14308 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14309 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14310 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 14311 | |
| 14312 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 14313 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14314 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 14315 | # save the value of LIBS so we don't actually link Python with readline |
| 14316 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14317 | |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14318 | # On some systems we need to link readline to a termcap compatible |
| 14319 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 14320 | # with setup.py. |
| 14321 | py_cv_lib_readline=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14322 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 14323 | $as_echo_n "checking how to link readline libs... " >&6; } |
doko@ubuntu.com | f2967c7 | 2012-06-30 17:32:23 +0200 | [diff] [blame] | 14324 | for py_libtermcap in "" tinfo ncursesw ncurses curses termcap; do |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14325 | if test -z "$py_libtermcap"; then |
| 14326 | READLINE_LIBS="-lreadline" |
| 14327 | else |
| 14328 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 14329 | fi |
| 14330 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14331 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14332 | /* end confdefs.h. */ |
| 14333 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14334 | /* Override any GCC internal prototype to avoid an error. |
| 14335 | Use char because int might match the return type of a GCC |
| 14336 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14337 | #ifdef __cplusplus |
| 14338 | extern "C" |
| 14339 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14340 | char readline (); |
| 14341 | int |
| 14342 | main () |
| 14343 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14344 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14345 | ; |
| 14346 | return 0; |
| 14347 | } |
| 14348 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14349 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14350 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14351 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14352 | rm -f core conftest.err conftest.$ac_objext \ |
| 14353 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14354 | if test $py_cv_lib_readline = yes; then |
| 14355 | break |
| 14356 | fi |
| 14357 | done |
| 14358 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 14359 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | 3856c37 | 2008-09-07 19:24:00 +0000 | [diff] [blame] | 14360 | if test $py_cv_lib_readline = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14361 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 14362 | $as_echo "none" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14363 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14364 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 14365 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14366 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14367 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14368 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 14369 | fi |
| 14370 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14371 | # check for readline 2.1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14372 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 14373 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14374 | if ${ac_cv_lib_readline_rl_callback_handler_install+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14375 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14376 | else |
| 14377 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14378 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14379 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14380 | /* end confdefs.h. */ |
| 14381 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14382 | /* Override any GCC internal prototype to avoid an error. |
| 14383 | Use char because int might match the return type of a GCC |
| 14384 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14385 | #ifdef __cplusplus |
| 14386 | extern "C" |
| 14387 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14388 | char rl_callback_handler_install (); |
| 14389 | int |
| 14390 | main () |
| 14391 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14392 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14393 | ; |
| 14394 | return 0; |
| 14395 | } |
| 14396 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14397 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14398 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 14399 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14400 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14401 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14402 | rm -f core conftest.err conftest.$ac_objext \ |
| 14403 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14404 | LIBS=$ac_check_lib_save_LIBS |
| 14405 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14406 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 14407 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14408 | if test "x$ac_cv_lib_readline_rl_callback_handler_install" = xyes; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14409 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14410 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14411 | |
| 14412 | fi |
| 14413 | |
| 14414 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14415 | # check for readline 2.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14416 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14417 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14418 | #include <readline/readline.h> |
| 14419 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14420 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14421 | have_readline=yes |
| 14422 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14423 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 14424 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14425 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 14426 | rm -f conftest.err conftest.i conftest.$ac_ext |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14427 | if test $have_readline = yes |
| 14428 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14429 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14430 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14431 | #include <readline/readline.h> |
| 14432 | |
| 14433 | _ACEOF |
| 14434 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14435 | $EGREP "extern int rl_completion_append_character;" >/dev/null 2>&1; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14436 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14437 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14438 | |
| 14439 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 14440 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14441 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14442 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 14443 | /* end confdefs.h. */ |
| 14444 | #include <readline/readline.h> |
| 14445 | |
| 14446 | _ACEOF |
| 14447 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14448 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 14449 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14450 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 14451 | |
| 14452 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 14453 | rm -f conftest* |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 14454 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 14455 | fi |
| 14456 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14457 | # check for readline 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14458 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 14459 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14460 | if ${ac_cv_lib_readline_rl_pre_input_hook+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14461 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 14462 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14463 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14464 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14465 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14466 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14467 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14468 | /* Override any GCC internal prototype to avoid an error. |
| 14469 | Use char because int might match the return type of a GCC |
| 14470 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14471 | #ifdef __cplusplus |
| 14472 | extern "C" |
| 14473 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14474 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14475 | int |
| 14476 | main () |
| 14477 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14478 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14479 | ; |
| 14480 | return 0; |
| 14481 | } |
| 14482 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14483 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14484 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14485 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14486 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14487 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14488 | rm -f core conftest.err conftest.$ac_objext \ |
| 14489 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14490 | LIBS=$ac_check_lib_save_LIBS |
| 14491 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14492 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 14493 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14494 | if test "x$ac_cv_lib_readline_rl_pre_input_hook" = xyes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14495 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14496 | $as_echo "#define HAVE_RL_PRE_INPUT_HOOK 1" >>confdefs.h |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14497 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14498 | fi |
| 14499 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14500 | |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14501 | # also in 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14502 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 14503 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14504 | if ${ac_cv_lib_readline_rl_completion_display_matches_hook+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14505 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14506 | else |
| 14507 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14508 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14510 | /* end confdefs.h. */ |
| 14511 | |
| 14512 | /* Override any GCC internal prototype to avoid an error. |
| 14513 | Use char because int might match the return type of a GCC |
| 14514 | builtin and then its argument prototype would still apply. */ |
| 14515 | #ifdef __cplusplus |
| 14516 | extern "C" |
| 14517 | #endif |
| 14518 | char rl_completion_display_matches_hook (); |
| 14519 | int |
| 14520 | main () |
| 14521 | { |
| 14522 | return rl_completion_display_matches_hook (); |
| 14523 | ; |
| 14524 | return 0; |
| 14525 | } |
| 14526 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14527 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14528 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 14529 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14530 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14531 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14532 | rm -f core conftest.err conftest.$ac_objext \ |
| 14533 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14534 | LIBS=$ac_check_lib_save_LIBS |
| 14535 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14536 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 14537 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14538 | if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = xyes; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14539 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14540 | $as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 14541 | |
| 14542 | fi |
| 14543 | |
| 14544 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14545 | # check for readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 14547 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14548 | if ${ac_cv_lib_readline_rl_completion_matches+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14549 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 14550 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14551 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 14552 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14554 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14555 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14556 | /* Override any GCC internal prototype to avoid an error. |
| 14557 | Use char because int might match the return type of a GCC |
| 14558 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14559 | #ifdef __cplusplus |
| 14560 | extern "C" |
| 14561 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14562 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14563 | int |
| 14564 | main () |
| 14565 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14566 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14567 | ; |
| 14568 | return 0; |
| 14569 | } |
| 14570 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14571 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14572 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 14573 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14574 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 14575 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14576 | rm -f core conftest.err conftest.$ac_objext \ |
| 14577 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14578 | LIBS=$ac_check_lib_save_LIBS |
| 14579 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14580 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 14581 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14582 | if test "x$ac_cv_lib_readline_rl_completion_matches" = xyes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14583 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14584 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 14585 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 14586 | fi |
| 14587 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 14588 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14589 | # also in readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14590 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14591 | /* end confdefs.h. */ |
| 14592 | #include <readline/readline.h> |
| 14593 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14594 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14595 | have_readline=yes |
| 14596 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14597 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 14598 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14599 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 14600 | rm -f conftest.err conftest.i conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14601 | if test $have_readline = yes |
| 14602 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14603 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14604 | /* end confdefs.h. */ |
| 14605 | #include <readline/readline.h> |
| 14606 | |
| 14607 | _ACEOF |
| 14608 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14609 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14610 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14611 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14612 | |
| 14613 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 14614 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 14615 | |
| 14616 | fi |
| 14617 | |
Benjamin Peterson | d1e22ba | 2014-11-26 14:35:12 -0600 | [diff] [blame] | 14618 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for append_history in -lreadline" >&5 |
| 14619 | $as_echo_n "checking for append_history in -lreadline... " >&6; } |
| 14620 | if ${ac_cv_lib_readline_append_history+:} false; then : |
| 14621 | $as_echo_n "(cached) " >&6 |
| 14622 | else |
| 14623 | ac_check_lib_save_LIBS=$LIBS |
| 14624 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
| 14625 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 14626 | /* end confdefs.h. */ |
| 14627 | |
| 14628 | /* Override any GCC internal prototype to avoid an error. |
| 14629 | Use char because int might match the return type of a GCC |
| 14630 | builtin and then its argument prototype would still apply. */ |
| 14631 | #ifdef __cplusplus |
| 14632 | extern "C" |
| 14633 | #endif |
| 14634 | char append_history (); |
| 14635 | int |
| 14636 | main () |
| 14637 | { |
| 14638 | return append_history (); |
| 14639 | ; |
| 14640 | return 0; |
| 14641 | } |
| 14642 | _ACEOF |
| 14643 | if ac_fn_c_try_link "$LINENO"; then : |
| 14644 | ac_cv_lib_readline_append_history=yes |
| 14645 | else |
| 14646 | ac_cv_lib_readline_append_history=no |
| 14647 | fi |
| 14648 | rm -f core conftest.err conftest.$ac_objext \ |
| 14649 | conftest$ac_exeext conftest.$ac_ext |
| 14650 | LIBS=$ac_check_lib_save_LIBS |
| 14651 | fi |
| 14652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_append_history" >&5 |
| 14653 | $as_echo "$ac_cv_lib_readline_append_history" >&6; } |
| 14654 | if test "x$ac_cv_lib_readline_append_history" = xyes; then : |
| 14655 | |
| 14656 | $as_echo "#define HAVE_RL_APPEND_HISTORY 1" >>confdefs.h |
| 14657 | |
| 14658 | fi |
| 14659 | |
| 14660 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 14661 | # End of readline checks: restore LIBS |
| 14662 | LIBS=$LIBS_no_readline |
| 14663 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14664 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 14665 | $as_echo_n "checking for broken nice()... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14666 | if ${ac_cv_broken_nice+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14667 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14668 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14669 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14670 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 14671 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14672 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14673 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14674 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14675 | |
| 14676 | int main() |
| 14677 | { |
| 14678 | int val1 = nice(1); |
| 14679 | if (val1 != -1 && val1 == nice(2)) |
| 14680 | exit(0); |
| 14681 | exit(1); |
| 14682 | } |
| 14683 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14684 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14685 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14686 | ac_cv_broken_nice=yes |
| 14687 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14688 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14689 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14690 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 14691 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14692 | fi |
| 14693 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14694 | fi |
| 14695 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 14697 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14698 | if test "$ac_cv_broken_nice" = yes |
| 14699 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14700 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14701 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 14702 | |
| 14703 | fi |
| 14704 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14705 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 14706 | $as_echo_n "checking for broken poll()... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14707 | if ${ac_cv_broken_poll+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14708 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14709 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14710 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14711 | ac_cv_broken_poll=no |
| 14712 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14713 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14714 | /* end confdefs.h. */ |
| 14715 | |
| 14716 | #include <poll.h> |
| 14717 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14718 | int main() |
| 14719 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14720 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14721 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14722 | |
| 14723 | close (42); |
| 14724 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14725 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14726 | if (poll_test < 0) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14727 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14728 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14729 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14730 | else |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14731 | return 1; |
| 14732 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14733 | |
| 14734 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14735 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14736 | ac_cv_broken_poll=yes |
| 14737 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14738 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14739 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14740 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 14741 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14742 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14743 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 14744 | fi |
| 14745 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14746 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 14747 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14748 | if test "$ac_cv_broken_poll" = yes |
| 14749 | then |
| 14750 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14751 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14752 | |
| 14753 | fi |
| 14754 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14755 | # Before we can test tzset, we need to check if struct tm has a tm_zone |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 14756 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 14757 | # tzname[] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14758 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14759 | #include <$ac_cv_struct_tm> |
| 14760 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14761 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14762 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14763 | |
| 14764 | cat >>confdefs.h <<_ACEOF |
| 14765 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 14766 | _ACEOF |
| 14767 | |
| 14768 | |
| 14769 | fi |
| 14770 | |
| 14771 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 14772 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14773 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14774 | |
| 14775 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14776 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 14777 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14778 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14779 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14780 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14781 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14782 | fi |
| 14783 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14784 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14785 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14786 | _ACEOF |
| 14787 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14788 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 14789 | $as_echo_n "checking for tzname... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14790 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14791 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14793 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14794 | /* end confdefs.h. */ |
| 14795 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14796 | #if !HAVE_DECL_TZNAME |
| 14797 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14798 | #endif |
| 14799 | |
| 14800 | int |
| 14801 | main () |
| 14802 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14803 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14804 | ; |
| 14805 | return 0; |
| 14806 | } |
| 14807 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14808 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14809 | ac_cv_var_tzname=yes |
| 14810 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14811 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14812 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14813 | rm -f core conftest.err conftest.$ac_objext \ |
| 14814 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14815 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 14817 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14818 | if test $ac_cv_var_tzname = yes; then |
| 14819 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14820 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14821 | |
| 14822 | fi |
| 14823 | fi |
| 14824 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 14825 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 14826 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14827 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 14828 | $as_echo_n "checking for working tzset()... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14829 | if ${ac_cv_working_tzset+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14830 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14831 | else |
| 14832 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14833 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14834 | ac_cv_working_tzset=no |
| 14835 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14836 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14837 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14838 | |
| 14839 | #include <stdlib.h> |
| 14840 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14841 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14842 | |
| 14843 | #if HAVE_TZNAME |
| 14844 | extern char *tzname[]; |
| 14845 | #endif |
| 14846 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14847 | int main() |
| 14848 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14849 | /* Note that we need to ensure that not only does tzset(3) |
| 14850 | do 'something' with localtime, but it works as documented |
| 14851 | in the library reference and as expected by the test suite. |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 14852 | This includes making sure that tzname is set properly if |
| 14853 | tm->tm_zone does not exist since it is the alternative way |
| 14854 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14855 | |
| 14856 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 14857 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14858 | */ |
| 14859 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 14860 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14861 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 14862 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 14863 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14864 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14865 | if (localtime(&groundhogday)->tm_hour != 0) |
| 14866 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14867 | #if HAVE_TZNAME |
| 14868 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 14869 | if (strcmp(tzname[0], "UTC") || |
| 14870 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 14871 | exit(1); |
| 14872 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14873 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 14874 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14875 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14876 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14877 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14878 | #if HAVE_TZNAME |
| 14879 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 14880 | exit(1); |
| 14881 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14882 | |
| 14883 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 14884 | tzset(); |
| 14885 | if (localtime(&groundhogday)->tm_hour != 11) |
| 14886 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14887 | #if HAVE_TZNAME |
| 14888 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 14889 | exit(1); |
| 14890 | #endif |
| 14891 | |
| 14892 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14893 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 14894 | exit(1); |
| 14895 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 14896 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 14897 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 14898 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14899 | exit(0); |
| 14900 | } |
| 14901 | |
| 14902 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14903 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14904 | ac_cv_working_tzset=yes |
| 14905 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14906 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14907 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14908 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 14909 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14910 | fi |
| 14911 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14912 | fi |
| 14913 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14914 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 14915 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14916 | if test "$ac_cv_working_tzset" = yes |
| 14917 | then |
| 14918 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14919 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 14920 | |
| 14921 | fi |
| 14922 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14923 | # Look for subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14924 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 14925 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14926 | if ${ac_cv_stat_tv_nsec+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14927 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14928 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14929 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14930 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14931 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14932 | int |
| 14933 | main () |
| 14934 | { |
| 14935 | |
| 14936 | struct stat st; |
| 14937 | st.st_mtim.tv_nsec = 1; |
| 14938 | |
| 14939 | ; |
| 14940 | return 0; |
| 14941 | } |
| 14942 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14943 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 14944 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14945 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14946 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14947 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14948 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 14949 | fi |
| 14950 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14951 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 14952 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14953 | if test "$ac_cv_stat_tv_nsec" = yes |
| 14954 | then |
| 14955 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14956 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 14957 | |
| 14958 | fi |
| 14959 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14960 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14961 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 14962 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 14963 | if ${ac_cv_stat_tv_nsec2+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14964 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14965 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14966 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14967 | /* end confdefs.h. */ |
| 14968 | #include <sys/stat.h> |
| 14969 | int |
| 14970 | main () |
| 14971 | { |
| 14972 | |
| 14973 | struct stat st; |
| 14974 | st.st_mtimespec.tv_nsec = 1; |
| 14975 | |
| 14976 | ; |
| 14977 | return 0; |
| 14978 | } |
| 14979 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14980 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14981 | ac_cv_stat_tv_nsec2=yes |
| 14982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14983 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14984 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14985 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 14986 | fi |
| 14987 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 14989 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14990 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 14991 | then |
| 14992 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14993 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 14994 | |
| 14995 | fi |
| 14996 | |
doko@ubuntu.com | 1a4f561 | 2014-04-17 20:13:44 +0200 | [diff] [blame] | 14997 | # first curses header check |
doko@ubuntu.com | 9dc823d | 2012-07-07 03:06:42 +0200 | [diff] [blame] | 14998 | ac_save_cppflags="$CPPFLAGS" |
| 14999 | CPPFLAGS="$CPPFLAGS -I/usr/include/ncursesw" |
doko@ubuntu.com | 1a4f561 | 2014-04-17 20:13:44 +0200 | [diff] [blame] | 15000 | |
| 15001 | for ac_header in curses.h ncurses.h |
| 15002 | do : |
| 15003 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 15004 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
| 15005 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
| 15006 | cat >>confdefs.h <<_ACEOF |
| 15007 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 15008 | _ACEOF |
| 15009 | |
| 15010 | fi |
| 15011 | |
| 15012 | done |
| 15013 | |
| 15014 | |
| 15015 | # On Solaris, term.h requires curses.h |
| 15016 | for ac_header in term.h |
| 15017 | do : |
| 15018 | ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" " |
| 15019 | #ifdef HAVE_CURSES_H |
| 15020 | #include <curses.h> |
| 15021 | #endif |
| 15022 | |
| 15023 | " |
| 15024 | if test "x$ac_cv_header_term_h" = xyes; then : |
| 15025 | cat >>confdefs.h <<_ACEOF |
| 15026 | #define HAVE_TERM_H 1 |
| 15027 | _ACEOF |
| 15028 | |
| 15029 | fi |
| 15030 | |
| 15031 | done |
| 15032 | |
| 15033 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15034 | # On HP/UX 11.0, mvwdelch is a block with a return statement |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15035 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 15036 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15037 | if ${ac_cv_mvwdelch_is_expression+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15038 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15039 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15040 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15041 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15042 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15043 | int |
| 15044 | main () |
| 15045 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15046 | |
| 15047 | int rtn; |
| 15048 | rtn = mvwdelch(0,0,0); |
| 15049 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15050 | ; |
| 15051 | return 0; |
| 15052 | } |
| 15053 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15054 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15055 | ac_cv_mvwdelch_is_expression=yes |
| 15056 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15057 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15058 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15059 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15060 | fi |
| 15061 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15062 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 15063 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15064 | |
| 15065 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 15066 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15067 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15068 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15069 | |
| 15070 | fi |
| 15071 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15072 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 15073 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15074 | if ${ac_cv_window_has_flags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15075 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15076 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15077 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15078 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15079 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15080 | int |
| 15081 | main () |
| 15082 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15083 | |
| 15084 | WINDOW *w; |
| 15085 | w->_flags = 0; |
| 15086 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15087 | ; |
| 15088 | return 0; |
| 15089 | } |
| 15090 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15091 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15092 | ac_cv_window_has_flags=yes |
| 15093 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15094 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15095 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15096 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15097 | fi |
| 15098 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15099 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 15100 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 15101 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15102 | |
| 15103 | if test "$ac_cv_window_has_flags" = yes |
| 15104 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15105 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15106 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 15107 | |
| 15108 | fi |
| 15109 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 15111 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 15112 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15113 | /* end confdefs.h. */ |
| 15114 | #include <curses.h> |
| 15115 | int |
| 15116 | main () |
| 15117 | { |
| 15118 | void *x=is_term_resized |
| 15119 | ; |
| 15120 | return 0; |
| 15121 | } |
| 15122 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15123 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 15124 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15125 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15126 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 15127 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15128 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15129 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15130 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 15131 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15132 | |
| 15133 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15134 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15135 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15136 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 15137 | $as_echo_n "checking for resize_term... " >&6; } |
| 15138 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15139 | /* end confdefs.h. */ |
| 15140 | #include <curses.h> |
| 15141 | int |
| 15142 | main () |
| 15143 | { |
| 15144 | void *x=resize_term |
| 15145 | ; |
| 15146 | return 0; |
| 15147 | } |
| 15148 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15149 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15150 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15151 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15152 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 15153 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15154 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15155 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15156 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 15157 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15158 | |
| 15159 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15160 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15161 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15162 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 15163 | $as_echo_n "checking for resizeterm... " >&6; } |
| 15164 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15165 | /* end confdefs.h. */ |
| 15166 | #include <curses.h> |
| 15167 | int |
| 15168 | main () |
| 15169 | { |
| 15170 | void *x=resizeterm |
| 15171 | ; |
| 15172 | return 0; |
| 15173 | } |
| 15174 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15175 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15176 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15177 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15178 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 15179 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15180 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15181 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15182 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 15183 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 15184 | |
| 15185 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15186 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
doko@ubuntu.com | 9dc823d | 2012-07-07 03:06:42 +0200 | [diff] [blame] | 15187 | # last curses configure check |
| 15188 | CPPFLAGS=$ac_save_cppflags |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15189 | |
doko@ubuntu.com | b457b9b | 2012-06-30 19:28:16 +0200 | [diff] [blame] | 15190 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for device files" >&5 |
| 15191 | $as_echo "$as_me: checking for device files" >&6;} |
| 15192 | |
| 15193 | if test "x$cross_compiling" = xyes; then |
| 15194 | if test "${ac_cv_file__dev_ptmx+set}" != set; then |
| 15195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 15196 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
| 15197 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not set" >&5 |
| 15198 | $as_echo "not set" >&6; } |
| 15199 | as_fn_error $? "set ac_cv_file__dev_ptmx to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5 |
| 15200 | fi |
| 15201 | if test "${ac_cv_file__dev_ptc+set}" != set; then |
| 15202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 15203 | $as_echo_n "checking for /dev/ptc... " >&6; } |
| 15204 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not set" >&5 |
| 15205 | $as_echo "not set" >&6; } |
| 15206 | as_fn_error $? "set ac_cv_file__dev_ptc to yes/no in your CONFIG_SITE file when cross compiling" "$LINENO" 5 |
| 15207 | fi |
| 15208 | fi |
| 15209 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15210 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 15211 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
doko@ubuntu.com | b457b9b | 2012-06-30 19:28:16 +0200 | [diff] [blame] | 15212 | if ${ac_cv_file__dev_ptmx+:} false; then : |
| 15213 | $as_echo_n "(cached) " >&6 |
| 15214 | else |
| 15215 | test "$cross_compiling" = yes && |
| 15216 | as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 |
| 15217 | if test -r "/dev/ptmx"; then |
| 15218 | ac_cv_file__dev_ptmx=yes |
| 15219 | else |
| 15220 | ac_cv_file__dev_ptmx=no |
| 15221 | fi |
| 15222 | fi |
| 15223 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptmx" >&5 |
| 15224 | $as_echo "$ac_cv_file__dev_ptmx" >&6; } |
| 15225 | if test "x$ac_cv_file__dev_ptmx" = xyes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 15226 | |
doko@ubuntu.com | b457b9b | 2012-06-30 19:28:16 +0200 | [diff] [blame] | 15227 | fi |
| 15228 | |
| 15229 | if test "x$ac_cv_file__dev_ptmx" = xyes; then |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 15230 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15231 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 15232 | |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 15233 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15234 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 15235 | $as_echo_n "checking for /dev/ptc... " >&6; } |
doko@ubuntu.com | b457b9b | 2012-06-30 19:28:16 +0200 | [diff] [blame] | 15236 | if ${ac_cv_file__dev_ptc+:} false; then : |
| 15237 | $as_echo_n "(cached) " >&6 |
| 15238 | else |
| 15239 | test "$cross_compiling" = yes && |
| 15240 | as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 |
| 15241 | if test -r "/dev/ptc"; then |
| 15242 | ac_cv_file__dev_ptc=yes |
| 15243 | else |
| 15244 | ac_cv_file__dev_ptc=no |
| 15245 | fi |
| 15246 | fi |
| 15247 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_ptc" >&5 |
| 15248 | $as_echo "$ac_cv_file__dev_ptc" >&6; } |
| 15249 | if test "x$ac_cv_file__dev_ptc" = xyes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 15250 | |
doko@ubuntu.com | b457b9b | 2012-06-30 19:28:16 +0200 | [diff] [blame] | 15251 | fi |
| 15252 | |
| 15253 | if test "x$ac_cv_file__dev_ptc" = xyes; then |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 15254 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15255 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 15256 | |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 15257 | fi |
| 15258 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15259 | if test "$have_long_long" = yes |
| 15260 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15261 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 15262 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15263 | if ${ac_cv_have_long_long_format+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15264 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15265 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15266 | if test "$cross_compiling" = yes; then : |
Matthias Klose | 3b739b1 | 2012-03-15 19:31:06 +0100 | [diff] [blame] | 15267 | ac_cv_have_long_long_format="cross -- assuming no" |
| 15268 | if test x$GCC = xyes; then |
| 15269 | save_CFLAGS=$CFLAGS |
| 15270 | CFLAGS="$CFLAGS -Werror -Wformat" |
| 15271 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15272 | /* end confdefs.h. */ |
| 15273 | |
| 15274 | #include <stdio.h> |
| 15275 | #include <stddef.h> |
| 15276 | |
| 15277 | int |
| 15278 | main () |
| 15279 | { |
| 15280 | |
| 15281 | char *buffer; |
| 15282 | sprintf(buffer, "%lld", (long long)123); |
| 15283 | sprintf(buffer, "%lld", (long long)-123); |
| 15284 | sprintf(buffer, "%llu", (unsigned long long)123); |
| 15285 | |
| 15286 | ; |
| 15287 | return 0; |
| 15288 | } |
| 15289 | _ACEOF |
| 15290 | if ac_fn_c_try_compile "$LINENO"; then : |
| 15291 | ac_cv_have_long_long_format=yes |
| 15292 | |
| 15293 | fi |
| 15294 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15295 | CFLAGS=$save_CFLAGS |
| 15296 | fi |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15297 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15298 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15299 | /* end confdefs.h. */ |
| 15300 | |
| 15301 | #include <stdio.h> |
| 15302 | #include <stddef.h> |
| 15303 | #include <string.h> |
| 15304 | |
| 15305 | #ifdef HAVE_SYS_TYPES_H |
| 15306 | #include <sys/types.h> |
| 15307 | #endif |
| 15308 | |
| 15309 | int main() |
| 15310 | { |
| 15311 | char buffer[256]; |
| 15312 | |
| 15313 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 15314 | return 1; |
| 15315 | if (strcmp(buffer, "123")) |
| 15316 | return 1; |
| 15317 | |
| 15318 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 15319 | return 1; |
| 15320 | if (strcmp(buffer, "-123")) |
| 15321 | return 1; |
| 15322 | |
| 15323 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 15324 | return 1; |
| 15325 | if (strcmp(buffer, "123")) |
| 15326 | return 1; |
| 15327 | |
| 15328 | return 0; |
| 15329 | } |
| 15330 | |
| 15331 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15332 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15333 | ac_cv_have_long_long_format=yes |
| 15334 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15335 | ac_cv_have_long_long_format=no |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15336 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15337 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15338 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15339 | fi |
| 15340 | |
| 15341 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15342 | fi |
| 15343 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15344 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 15345 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15346 | fi |
| 15347 | |
Mark Dickinson | 89d7d41 | 2009-12-31 20:50:59 +0000 | [diff] [blame] | 15348 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15349 | then |
| 15350 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15351 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15352 | |
| 15353 | fi |
| 15354 | |
Ronald Oussoren | 3c1928a | 2009-11-19 17:15:31 +0000 | [diff] [blame] | 15355 | if test $ac_sys_system = Darwin |
| 15356 | then |
| 15357 | LIBS="$LIBS -framework CoreFoundation" |
| 15358 | fi |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 15359 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 15361 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15362 | if ${ac_cv_have_size_t_format+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15363 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15364 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15365 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 15366 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 15367 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15368 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15369 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15370 | /* end confdefs.h. */ |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15371 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15372 | #include <stdio.h> |
| 15373 | #include <stddef.h> |
| 15374 | #include <string.h> |
| 15375 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 15376 | #ifdef HAVE_SYS_TYPES_H |
| 15377 | #include <sys/types.h> |
| 15378 | #endif |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 15379 | |
| 15380 | #ifdef HAVE_SSIZE_T |
| 15381 | typedef ssize_t Py_ssize_t; |
| 15382 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 15383 | typedef long Py_ssize_t; |
| 15384 | #else |
| 15385 | typedef int Py_ssize_t; |
| 15386 | #endif |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15387 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 15388 | int main() |
| 15389 | { |
| 15390 | char buffer[256]; |
| 15391 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15392 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 15393 | return 1; |
| 15394 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 15395 | if (strcmp(buffer, "123")) |
| 15396 | return 1; |
| 15397 | |
| 15398 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 15399 | return 1; |
| 15400 | |
| 15401 | if (strcmp(buffer, "-123")) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15402 | return 1; |
| 15403 | |
| 15404 | return 0; |
| 15405 | } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15406 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15407 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15408 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15409 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 15410 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15411 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 15412 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15413 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15414 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 15415 | fi |
| 15416 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15417 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15418 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 15419 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 15420 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15421 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15422 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15423 | |
| 15424 | fi |
| 15425 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15426 | ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" " |
Martin v. Löwis | 01c0401 | 2002-11-11 14:58:44 +0000 | [diff] [blame] | 15427 | #ifdef HAVE_SYS_TYPES_H |
| 15428 | #include <sys/types.h> |
| 15429 | #endif |
| 15430 | #ifdef HAVE_SYS_SOCKET_H |
| 15431 | #include <sys/socket.h> |
| 15432 | #endif |
| 15433 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15434 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15435 | if test "x$ac_cv_type_socklen_t" = xyes; then : |
Martin v. Löwis | 01c0401 | 2002-11-11 14:58:44 +0000 | [diff] [blame] | 15436 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15437 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 15438 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15439 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 15440 | |
| 15441 | fi |
| 15442 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 15443 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15444 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5 |
| 15445 | $as_echo_n "checking for broken mbstowcs... " >&6; } |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15446 | if ${ac_cv_broken_mbstowcs+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15447 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15448 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15449 | if test "$cross_compiling" = yes; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15450 | ac_cv_broken_mbstowcs=no |
| 15451 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15452 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15453 | /* end confdefs.h. */ |
| 15454 | |
Stefan Krah | 19c2139 | 2012-11-22 23:47:32 +0100 | [diff] [blame] | 15455 | #include <stdio.h> |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15456 | #include<stdlib.h> |
| 15457 | int main() { |
| 15458 | size_t len = -1; |
| 15459 | const char *str = "text"; |
| 15460 | len = mbstowcs(NULL, str, 0); |
| 15461 | return (len != 4); |
| 15462 | } |
| 15463 | |
| 15464 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15465 | if ac_fn_c_try_run "$LINENO"; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15466 | ac_cv_broken_mbstowcs=no |
| 15467 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15468 | ac_cv_broken_mbstowcs=yes |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15469 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15470 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15471 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15472 | fi |
| 15473 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 15474 | fi |
| 15475 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15476 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5 |
| 15477 | $as_echo "$ac_cv_broken_mbstowcs" >&6; } |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15478 | if test "$ac_cv_broken_mbstowcs" = yes |
| 15479 | then |
| 15480 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15481 | $as_echo "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 15482 | |
| 15483 | fi |
| 15484 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15485 | # Check for --with-computed-gotos |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15486 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5 |
| 15487 | $as_echo_n "checking for --with-computed-gotos... " >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15488 | |
| 15489 | # Check whether --with-computed-gotos was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15490 | if test "${with_computed_gotos+set}" = set; then : |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15491 | withval=$with_computed_gotos; |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 15492 | if test "$withval" = yes |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15493 | then |
| 15494 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15495 | $as_echo "#define USE_COMPUTED_GOTOS 1" >>confdefs.h |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15496 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15497 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 15498 | $as_echo "yes" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15499 | fi |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 15500 | if test "$withval" = no |
| 15501 | then |
| 15502 | |
| 15503 | $as_echo "#define USE_COMPUTED_GOTOS 0" >>confdefs.h |
| 15504 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15505 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 15506 | $as_echo "no" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15507 | fi |
| 15508 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 15509 | else |
| 15510 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 15511 | $as_echo "no value specified" >&6; } |
| 15512 | fi |
| 15513 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15514 | |
Matthias Klose | b17289e | 2012-03-15 19:51:34 +0100 | [diff] [blame] | 15515 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5 |
| 15516 | $as_echo_n "checking whether $CC supports computed gotos... " >&6; } |
| 15517 | if ${ac_cv_computed_gotos+:} false; then : |
| 15518 | $as_echo_n "(cached) " >&6 |
| 15519 | else |
| 15520 | if test "$cross_compiling" = yes; then : |
| 15521 | if test "${with_computed_gotos+set}" = set; then |
| 15522 | ac_cv_computed_gotos="$with_computed_gotos -- configured --with(out)-computed-gotos" |
| 15523 | else |
| 15524 | ac_cv_computed_gotos=no |
| 15525 | fi |
| 15526 | else |
| 15527 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15528 | /* end confdefs.h. */ |
| 15529 | |
| 15530 | int main(int argc, char **argv) |
| 15531 | { |
| 15532 | static void *targets[1] = { &&LABEL1 }; |
| 15533 | goto LABEL2; |
| 15534 | LABEL1: |
| 15535 | return 0; |
| 15536 | LABEL2: |
| 15537 | goto *targets[0]; |
| 15538 | return 1; |
| 15539 | } |
| 15540 | |
| 15541 | _ACEOF |
| 15542 | if ac_fn_c_try_run "$LINENO"; then : |
| 15543 | ac_cv_computed_gotos=yes |
| 15544 | else |
| 15545 | ac_cv_computed_gotos=no |
| 15546 | fi |
| 15547 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15548 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 15549 | fi |
| 15550 | |
| 15551 | fi |
| 15552 | |
| 15553 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5 |
| 15554 | $as_echo "$ac_cv_computed_gotos" >&6; } |
| 15555 | case "$ac_cv_computed_gotos" in yes*) |
| 15556 | |
| 15557 | $as_echo "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h |
| 15558 | |
| 15559 | esac |
| 15560 | |
Benjamin Peterson | d8d835b | 2010-10-15 23:14:46 +0000 | [diff] [blame] | 15561 | case $ac_sys_system in |
| 15562 | AIX*) |
| 15563 | |
| 15564 | $as_echo "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h |
| 15565 | ;; |
| 15566 | esac |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 15567 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 15568 | |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 15569 | |
| 15570 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 15571 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 15572 | do |
| 15573 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 15574 | done |
| 15575 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 15576 | |
Ned Deily | 0db50cf | 2014-07-25 12:41:31 -0700 | [diff] [blame] | 15577 | SRCDIRS="Parser Grammar Objects Python Modules Mac Programs" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15578 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 15579 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 15580 | for dir in $SRCDIRS; do |
| 15581 | if test ! -d $dir; then |
| 15582 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 15583 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 15584 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 15586 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 15587 | |
Stefan Krah | 1919b7e | 2012-03-21 18:25:23 +0100 | [diff] [blame] | 15588 | # Availability of -O2: |
| 15589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -O2" >&5 |
| 15590 | $as_echo_n "checking for -O2... " >&6; } |
| 15591 | saved_cflags="$CFLAGS" |
| 15592 | CFLAGS="-O2" |
| 15593 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15594 | /* end confdefs.h. */ |
| 15595 | |
| 15596 | int |
| 15597 | main () |
| 15598 | { |
| 15599 | |
| 15600 | |
| 15601 | ; |
| 15602 | return 0; |
| 15603 | } |
| 15604 | _ACEOF |
| 15605 | if ac_fn_c_try_compile "$LINENO"; then : |
| 15606 | have_O2=yes |
| 15607 | else |
| 15608 | have_O2=no |
| 15609 | fi |
| 15610 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 15611 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_O2" >&5 |
| 15612 | $as_echo "$have_O2" >&6; } |
| 15613 | CFLAGS="$saved_cflags" |
| 15614 | |
| 15615 | # _FORTIFY_SOURCE wrappers for memmove and bcopy are incorrect: |
| 15616 | # http://sourceware.org/ml/libc-alpha/2010-12/msg00009.html |
| 15617 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for glibc _FORTIFY_SOURCE/memmove bug" >&5 |
| 15618 | $as_echo_n "checking for glibc _FORTIFY_SOURCE/memmove bug... " >&6; } |
| 15619 | saved_cflags="$CFLAGS" |
| 15620 | CFLAGS="-O2 -D_FORTIFY_SOURCE=2" |
| 15621 | if test "$have_O2" = no; then |
| 15622 | CFLAGS="" |
| 15623 | fi |
| 15624 | if test "$cross_compiling" = yes; then : |
| 15625 | have_glibc_memmove_bug=undefined |
| 15626 | else |
| 15627 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15628 | /* end confdefs.h. */ |
| 15629 | |
| 15630 | #include <stdio.h> |
| 15631 | #include <stdlib.h> |
| 15632 | #include <string.h> |
| 15633 | void foo(void *p, void *q) { memmove(p, q, 19); } |
| 15634 | int main() { |
| 15635 | char a[32] = "123456789000000000"; |
| 15636 | foo(&a[9], a); |
| 15637 | if (strcmp(a, "123456789123456789000000000") != 0) |
| 15638 | return 1; |
| 15639 | foo(a, &a[9]); |
| 15640 | if (strcmp(a, "123456789000000000") != 0) |
| 15641 | return 1; |
| 15642 | return 0; |
| 15643 | } |
| 15644 | |
| 15645 | _ACEOF |
| 15646 | if ac_fn_c_try_run "$LINENO"; then : |
| 15647 | have_glibc_memmove_bug=no |
| 15648 | else |
| 15649 | have_glibc_memmove_bug=yes |
| 15650 | fi |
| 15651 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15652 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 15653 | fi |
| 15654 | |
| 15655 | CFLAGS="$saved_cflags" |
| 15656 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_glibc_memmove_bug" >&5 |
| 15657 | $as_echo "$have_glibc_memmove_bug" >&6; } |
| 15658 | if test "$have_glibc_memmove_bug" = yes; then |
| 15659 | |
| 15660 | $as_echo "#define HAVE_GLIBC_MEMMOVE_BUG 1" >>confdefs.h |
| 15661 | |
| 15662 | fi |
| 15663 | |
| 15664 | if test "$have_gcc_asm_for_x87" = yes; then |
| 15665 | # Some versions of gcc miscompile inline asm: |
| 15666 | # http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46491 |
| 15667 | # http://gcc.gnu.org/ml/gcc/2010-11/msg00366.html |
| 15668 | case $CC in |
| 15669 | *gcc*) |
| 15670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc ipa-pure-const bug" >&5 |
| 15671 | $as_echo_n "checking for gcc ipa-pure-const bug... " >&6; } |
| 15672 | saved_cflags="$CFLAGS" |
| 15673 | CFLAGS="-O2" |
| 15674 | if test "$cross_compiling" = yes; then : |
| 15675 | have_ipa_pure_const_bug=undefined |
| 15676 | else |
| 15677 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15678 | /* end confdefs.h. */ |
| 15679 | |
| 15680 | __attribute__((noinline)) int |
| 15681 | foo(int *p) { |
| 15682 | int r; |
| 15683 | asm ( "movl \$6, (%1)\n\t" |
| 15684 | "xorl %0, %0\n\t" |
| 15685 | : "=r" (r) : "r" (p) : "memory" |
| 15686 | ); |
| 15687 | return r; |
| 15688 | } |
| 15689 | int main() { |
| 15690 | int p = 8; |
| 15691 | if ((foo(&p) ? : p) != 6) |
| 15692 | return 1; |
| 15693 | return 0; |
| 15694 | } |
| 15695 | |
| 15696 | _ACEOF |
| 15697 | if ac_fn_c_try_run "$LINENO"; then : |
| 15698 | have_ipa_pure_const_bug=no |
| 15699 | else |
| 15700 | have_ipa_pure_const_bug=yes |
| 15701 | fi |
| 15702 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 15703 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 15704 | fi |
| 15705 | |
| 15706 | CFLAGS="$saved_cflags" |
| 15707 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ipa_pure_const_bug" >&5 |
| 15708 | $as_echo "$have_ipa_pure_const_bug" >&6; } |
| 15709 | if test "$have_ipa_pure_const_bug" = yes; then |
| 15710 | |
| 15711 | $as_echo "#define HAVE_IPA_PURE_CONST_BUG 1" >>confdefs.h |
| 15712 | |
| 15713 | fi |
| 15714 | ;; |
| 15715 | esac |
| 15716 | fi |
| 15717 | |
Victor Stinner | 4f5366e | 2015-01-09 02:13:19 +0100 | [diff] [blame] | 15718 | # Check for stdatomic.h |
| 15719 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdatomic.h" >&5 |
| 15720 | $as_echo_n "checking for stdatomic.h... " >&6; } |
| 15721 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15722 | /* end confdefs.h. */ |
| 15723 | |
| 15724 | |
| 15725 | #include <stdatomic.h> |
Victor Stinner | 923e06f | 2015-01-14 16:01:46 +0100 | [diff] [blame] | 15726 | atomic_int value = ATOMIC_VAR_INIT(1); |
| 15727 | _Atomic void *py_atomic_address = (void*) &value; |
Victor Stinner | 4f5366e | 2015-01-09 02:13:19 +0100 | [diff] [blame] | 15728 | int main() { |
| 15729 | int loaded_value = atomic_load(&value); |
| 15730 | return 0; |
| 15731 | } |
| 15732 | |
| 15733 | |
| 15734 | _ACEOF |
| 15735 | if ac_fn_c_try_link "$LINENO"; then : |
| 15736 | have_stdatomic_h=yes |
| 15737 | else |
| 15738 | have_stdatomic_h=no |
| 15739 | fi |
| 15740 | rm -f core conftest.err conftest.$ac_objext \ |
| 15741 | conftest$ac_exeext conftest.$ac_ext |
| 15742 | |
| 15743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_stdatomic_h" >&5 |
| 15744 | $as_echo "$have_stdatomic_h" >&6; } |
| 15745 | |
| 15746 | if test "$have_stdatomic_h" = yes; then |
| 15747 | |
| 15748 | $as_echo "#define HAVE_STD_ATOMIC 1" >>confdefs.h |
| 15749 | |
| 15750 | fi |
| 15751 | |
| 15752 | # Check for GCC >= 4.7 __atomic builtins |
| 15753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCC >= 4.7 __atomic builtins" >&5 |
| 15754 | $as_echo_n "checking for GCC >= 4.7 __atomic builtins... " >&6; } |
| 15755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15756 | /* end confdefs.h. */ |
| 15757 | |
| 15758 | |
| 15759 | volatile int val = 1; |
| 15760 | int main() { |
| 15761 | __atomic_load_n(&val, __ATOMIC_SEQ_CST); |
| 15762 | return 0; |
| 15763 | } |
| 15764 | |
| 15765 | |
| 15766 | _ACEOF |
| 15767 | if ac_fn_c_try_link "$LINENO"; then : |
| 15768 | have_builtin_atomic=yes |
| 15769 | else |
| 15770 | have_builtin_atomic=no |
| 15771 | fi |
| 15772 | rm -f core conftest.err conftest.$ac_objext \ |
| 15773 | conftest$ac_exeext conftest.$ac_ext |
| 15774 | |
| 15775 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_builtin_atomic" >&5 |
| 15776 | $as_echo "$have_builtin_atomic" >&6; } |
| 15777 | |
| 15778 | if test "$have_builtin_atomic" = yes; then |
| 15779 | |
| 15780 | $as_echo "#define HAVE_BUILTIN_ATOMIC 1" >>confdefs.h |
| 15781 | |
| 15782 | fi |
| 15783 | |
Ned Deily | 322f5ba | 2013-11-21 23:01:59 -0800 | [diff] [blame] | 15784 | # ensurepip option |
| 15785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ensurepip" >&5 |
| 15786 | $as_echo_n "checking for ensurepip... " >&6; } |
| 15787 | |
| 15788 | # Check whether --with-ensurepip was given. |
| 15789 | if test "${with_ensurepip+set}" = set; then : |
| 15790 | withval=$with_ensurepip; |
| 15791 | else |
| 15792 | with_ensurepip=upgrade |
| 15793 | fi |
| 15794 | |
| 15795 | case $with_ensurepip in #( |
| 15796 | yes|upgrade) : |
| 15797 | ENSUREPIP=upgrade ;; #( |
| 15798 | install) : |
| 15799 | ENSUREPIP=install ;; #( |
| 15800 | no) : |
| 15801 | ENSUREPIP=no ;; #( |
| 15802 | *) : |
| 15803 | as_fn_error $? "--with-ensurepip=upgrade|install|no" "$LINENO" 5 ;; |
| 15804 | esac |
| 15805 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENSUREPIP" >&5 |
| 15806 | $as_echo "$ENSUREPIP" >&6; } |
| 15807 | |
| 15808 | |
Victor Stinner | 35a97c0 | 2015-03-08 02:59:09 +0100 | [diff] [blame] | 15809 | # check if the dirent structure of a d_type field and DT_UNKNOWN is defined |
| 15810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the dirent structure of a d_type field" >&5 |
| 15811 | $as_echo_n "checking if the dirent structure of a d_type field... " >&6; } |
| 15812 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 15813 | /* end confdefs.h. */ |
| 15814 | |
| 15815 | |
| 15816 | #include <dirent.h> |
| 15817 | |
| 15818 | int main() { |
| 15819 | struct dirent entry; |
| 15820 | return entry.d_type == DT_UNKNOWN; |
| 15821 | } |
| 15822 | |
| 15823 | |
| 15824 | _ACEOF |
| 15825 | if ac_fn_c_try_link "$LINENO"; then : |
| 15826 | have_dirent_d_type=yes |
| 15827 | else |
| 15828 | have_dirent_d_type=no |
| 15829 | fi |
| 15830 | rm -f core conftest.err conftest.$ac_objext \ |
| 15831 | conftest$ac_exeext conftest.$ac_ext |
| 15832 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_dirent_d_type" >&5 |
| 15833 | $as_echo "$have_dirent_d_type" >&6; } |
| 15834 | |
| 15835 | if test "$have_dirent_d_type" = yes; then |
| 15836 | |
| 15837 | $as_echo "#define HAVE_DIRENT_D_TYPE 1" >>confdefs.h |
| 15838 | |
| 15839 | fi |
| 15840 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15841 | # generate output files |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 15842 | ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config Misc/python.pc Misc/python-config.sh" |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 15843 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 15844 | ac_config_files="$ac_config_files Modules/ld_so_aix" |
| 15845 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15846 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15847 | # This file is a shell script that caches the results of configure |
| 15848 | # tests run on this system so they can be shared between configure |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15849 | # scripts and configure runs, see configure's option --config-cache. |
| 15850 | # It is not useful on other systems. If it contains results you don't |
| 15851 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15852 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15853 | # config.status only pays attention to the cache file if you give it |
| 15854 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15855 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15856 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15857 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 15858 | # following values. |
| 15859 | |
| 15860 | _ACEOF |
| 15861 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 15862 | # The following way of writing the cache mishandles newlines in values, |
| 15863 | # but we know of no workaround that is simple, portable, and efficient. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15864 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 15865 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 15866 | # and sets the high bit in the cache file unless we assign to the vars. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15867 | ( |
| 15868 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 15869 | eval ac_val=\$$ac_var |
| 15870 | case $ac_val in #( |
| 15871 | *${as_nl}*) |
| 15872 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15873 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 15874 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15875 | esac |
| 15876 | case $ac_var in #( |
| 15877 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15878 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 15879 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15880 | esac ;; |
| 15881 | esac |
| 15882 | done |
| 15883 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15884 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15885 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 15886 | *${as_nl}ac_space=\ *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15887 | # `set' does not quote correctly, so add quotes: double-quote |
| 15888 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15889 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 15890 | "s/'/'\\\\''/g; |
| 15891 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15892 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15893 | *) |
| 15894 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15895 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15896 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15897 | esac | |
| 15898 | sort |
| 15899 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15900 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15901 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15902 | t clear |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15903 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15904 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 15905 | t end |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15906 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 15907 | :end' >>confcache |
| 15908 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 15909 | if test -w "$cache_file"; then |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15910 | if test "x$cache_file" != "x/dev/null"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15911 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 15912 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15913 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
| 15914 | cat confcache >"$cache_file" |
| 15915 | else |
| 15916 | case $cache_file in #( |
| 15917 | */* | ?:*) |
| 15918 | mv -f confcache "$cache_file"$$ && |
| 15919 | mv -f "$cache_file"$$ "$cache_file" ;; #( |
| 15920 | *) |
| 15921 | mv -f confcache "$cache_file" ;; |
| 15922 | esac |
| 15923 | fi |
| 15924 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 15925 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15926 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 15927 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 15928 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15929 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 15930 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 15931 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15932 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 15933 | # Let make expand exec_prefix. |
| 15934 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 15935 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15936 | DEFS=-DHAVE_CONFIG_H |
| 15937 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15938 | ac_libobjs= |
| 15939 | ac_ltlibobjs= |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 15940 | U= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15941 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 15942 | # 1. Remove the extension, and $U if already installed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15943 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15944 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15945 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 15946 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15947 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 15948 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15949 | done |
| 15950 | LIBOBJS=$ac_libobjs |
| 15951 | |
| 15952 | LTLIBOBJS=$ac_ltlibobjs |
| 15953 | |
| 15954 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15955 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15956 | |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 15957 | : "${CONFIG_STATUS=./config.status}" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15958 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15959 | ac_clean_files_save=$ac_clean_files |
| 15960 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15961 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 15962 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 15963 | as_write_fail=0 |
| 15964 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15965 | #! $SHELL |
| 15966 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15967 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15968 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15969 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15970 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15971 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15972 | ac_cs_recheck=false |
| 15973 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 15974 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15975 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 15976 | export SHELL |
| 15977 | _ASEOF |
| 15978 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 15979 | ## -------------------- ## |
| 15980 | ## M4sh Initialization. ## |
| 15981 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 15982 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15983 | # Be more Bourne compatible |
| 15984 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15985 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15986 | emulate sh |
| 15987 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15988 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15989 | # is contrary to our usage. Disable this feature. |
| 15990 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15991 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 15992 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15993 | case `(set -o) 2>/dev/null` in #( |
| 15994 | *posix*) : |
| 15995 | set -o posix ;; #( |
| 15996 | *) : |
| 15997 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15998 | esac |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 15999 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 16000 | |
| 16001 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16002 | as_nl=' |
| 16003 | ' |
| 16004 | export as_nl |
| 16005 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 16006 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 16007 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 16008 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 16009 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 16010 | # but without wasting forks for bash or zsh. |
| 16011 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 16012 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 16013 | as_echo='print -r --' |
| 16014 | as_echo_n='print -rn --' |
| 16015 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 16016 | as_echo='printf %s\n' |
| 16017 | as_echo_n='printf %s' |
| 16018 | else |
| 16019 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 16020 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 16021 | as_echo_n='/usr/ucb/echo -n' |
| 16022 | else |
| 16023 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 16024 | as_echo_n_body='eval |
| 16025 | arg=$1; |
| 16026 | case $arg in #( |
| 16027 | *"$as_nl"*) |
| 16028 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 16029 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 16030 | esac; |
| 16031 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 16032 | ' |
| 16033 | export as_echo_n_body |
| 16034 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 16035 | fi |
| 16036 | export as_echo_body |
| 16037 | as_echo='sh -c $as_echo_body as_echo' |
| 16038 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16039 | |
| 16040 | # The user is always right. |
| 16041 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16042 | PATH_SEPARATOR=: |
| 16043 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 16044 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 16045 | PATH_SEPARATOR=';' |
| 16046 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16047 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16048 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16049 | |
| 16050 | # IFS |
| 16051 | # We need space, tab and new line, in precisely that order. Quoting is |
| 16052 | # there to prevent editors from complaining about space-tab. |
| 16053 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 16054 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16055 | IFS=" "" $as_nl" |
| 16056 | |
| 16057 | # Find who we are. Look in the path if we contain no directory separator. |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16058 | as_myself= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16059 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16060 | *[\\/]* ) as_myself=$0 ;; |
| 16061 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16062 | for as_dir in $PATH |
| 16063 | do |
| 16064 | IFS=$as_save_IFS |
| 16065 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16066 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 16067 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16068 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16069 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16070 | ;; |
| 16071 | esac |
| 16072 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 16073 | # in which case we are not to be found in the path. |
| 16074 | if test "x$as_myself" = x; then |
| 16075 | as_myself=$0 |
| 16076 | fi |
| 16077 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16078 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 16079 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16080 | fi |
| 16081 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16082 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 16083 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 16084 | # suppresses any "Segmentation fault" message there. '((' could |
| 16085 | # trigger a bug in pdksh 5.2.14. |
| 16086 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 16087 | do eval test x\${$as_var+set} = xset \ |
| 16088 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16089 | done |
| 16090 | PS1='$ ' |
| 16091 | PS2='> ' |
| 16092 | PS4='+ ' |
| 16093 | |
| 16094 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16095 | LC_ALL=C |
| 16096 | export LC_ALL |
| 16097 | LANGUAGE=C |
| 16098 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16099 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16100 | # CDPATH. |
| 16101 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 16102 | |
| 16103 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16104 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 16105 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16106 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 16107 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16108 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16109 | as_fn_error () |
| 16110 | { |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16111 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 16112 | if test "$4"; then |
| 16113 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 16114 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16115 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16116 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16117 | as_fn_exit $as_status |
| 16118 | } # as_fn_error |
| 16119 | |
| 16120 | |
| 16121 | # as_fn_set_status STATUS |
| 16122 | # ----------------------- |
| 16123 | # Set $? to STATUS, without forking. |
| 16124 | as_fn_set_status () |
| 16125 | { |
| 16126 | return $1 |
| 16127 | } # as_fn_set_status |
| 16128 | |
| 16129 | # as_fn_exit STATUS |
| 16130 | # ----------------- |
| 16131 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 16132 | as_fn_exit () |
| 16133 | { |
| 16134 | set +e |
| 16135 | as_fn_set_status $1 |
| 16136 | exit $1 |
| 16137 | } # as_fn_exit |
| 16138 | |
| 16139 | # as_fn_unset VAR |
| 16140 | # --------------- |
| 16141 | # Portably unset VAR. |
| 16142 | as_fn_unset () |
| 16143 | { |
| 16144 | { eval $1=; unset $1;} |
| 16145 | } |
| 16146 | as_unset=as_fn_unset |
| 16147 | # as_fn_append VAR VALUE |
| 16148 | # ---------------------- |
| 16149 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 16150 | # advantage of any shell optimizations that allow amortized linear growth over |
| 16151 | # repeated appends, instead of the typical quadratic growth present in naive |
| 16152 | # implementations. |
| 16153 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 16154 | eval 'as_fn_append () |
| 16155 | { |
| 16156 | eval $1+=\$2 |
| 16157 | }' |
| 16158 | else |
| 16159 | as_fn_append () |
| 16160 | { |
| 16161 | eval $1=\$$1\$2 |
| 16162 | } |
| 16163 | fi # as_fn_append |
| 16164 | |
| 16165 | # as_fn_arith ARG... |
| 16166 | # ------------------ |
| 16167 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 16168 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 16169 | # must be portable across $(()) and expr. |
| 16170 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 16171 | eval 'as_fn_arith () |
| 16172 | { |
| 16173 | as_val=$(( $* )) |
| 16174 | }' |
| 16175 | else |
| 16176 | as_fn_arith () |
| 16177 | { |
| 16178 | as_val=`expr "$@" || test $? -eq 1` |
| 16179 | } |
| 16180 | fi # as_fn_arith |
| 16181 | |
| 16182 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16183 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 16184 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 16185 | as_expr=expr |
| 16186 | else |
| 16187 | as_expr=false |
| 16188 | fi |
| 16189 | |
| 16190 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 16191 | as_basename=basename |
| 16192 | else |
| 16193 | as_basename=false |
| 16194 | fi |
| 16195 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16196 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 16197 | as_dirname=dirname |
| 16198 | else |
| 16199 | as_dirname=false |
| 16200 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16201 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16202 | as_me=`$as_basename -- "$0" || |
| 16203 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 16204 | X"$0" : 'X\(//\)$' \| \ |
| 16205 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16206 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16207 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 16208 | s//\1/ |
| 16209 | q |
| 16210 | } |
| 16211 | /^X\/\(\/\/\)$/{ |
| 16212 | s//\1/ |
| 16213 | q |
| 16214 | } |
| 16215 | /^X\/\(\/\).*/{ |
| 16216 | s//\1/ |
| 16217 | q |
| 16218 | } |
| 16219 | s/.*/./; q'` |
| 16220 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16221 | # Avoid depending upon Character Ranges. |
| 16222 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 16223 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 16224 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 16225 | as_cr_digits='0123456789' |
| 16226 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16227 | |
| 16228 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16229 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16230 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16231 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16232 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16233 | xy) ECHO_C='\c';; |
| 16234 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 16235 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16236 | esac;; |
| 16237 | *) |
| 16238 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16239 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 16240 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16241 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16242 | if test -d conf$$.dir; then |
| 16243 | rm -f conf$$.dir/conf$$.file |
| 16244 | else |
| 16245 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16246 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16247 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16248 | if (echo >conf$$.file) 2>/dev/null; then |
| 16249 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 16250 | as_ln_s='ln -s' |
| 16251 | # ... but there are two gotchas: |
| 16252 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 16253 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16254 | # In both cases, we have to default to `cp -pR'. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16255 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16256 | as_ln_s='cp -pR' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16257 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 16258 | as_ln_s=ln |
| 16259 | else |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16260 | as_ln_s='cp -pR' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16261 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16262 | else |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16263 | as_ln_s='cp -pR' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16264 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16265 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 16266 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16267 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16268 | |
| 16269 | # as_fn_mkdir_p |
| 16270 | # ------------- |
| 16271 | # Create "$as_dir" as a directory, including parents if necessary. |
| 16272 | as_fn_mkdir_p () |
| 16273 | { |
| 16274 | |
| 16275 | case $as_dir in #( |
| 16276 | -*) as_dir=./$as_dir;; |
| 16277 | esac |
| 16278 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 16279 | as_dirs= |
| 16280 | while :; do |
| 16281 | case $as_dir in #( |
| 16282 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 16283 | *) as_qdir=$as_dir;; |
| 16284 | esac |
| 16285 | as_dirs="'$as_qdir' $as_dirs" |
| 16286 | as_dir=`$as_dirname -- "$as_dir" || |
| 16287 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 16288 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 16289 | X"$as_dir" : 'X\(//\)$' \| \ |
| 16290 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 16291 | $as_echo X"$as_dir" | |
| 16292 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 16293 | s//\1/ |
| 16294 | q |
| 16295 | } |
| 16296 | /^X\(\/\/\)[^/].*/{ |
| 16297 | s//\1/ |
| 16298 | q |
| 16299 | } |
| 16300 | /^X\(\/\/\)$/{ |
| 16301 | s//\1/ |
| 16302 | q |
| 16303 | } |
| 16304 | /^X\(\/\).*/{ |
| 16305 | s//\1/ |
| 16306 | q |
| 16307 | } |
| 16308 | s/.*/./; q'` |
| 16309 | test -d "$as_dir" && break |
| 16310 | done |
| 16311 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16312 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16313 | |
| 16314 | |
| 16315 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16316 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16317 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16318 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 16319 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16320 | as_mkdir_p=false |
| 16321 | fi |
| 16322 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16323 | |
| 16324 | # as_fn_executable_p FILE |
| 16325 | # ----------------------- |
| 16326 | # Test if FILE is an executable regular file. |
| 16327 | as_fn_executable_p () |
| 16328 | { |
| 16329 | test -f "$1" && test -x "$1" |
| 16330 | } # as_fn_executable_p |
| 16331 | as_test_x='test -x' |
| 16332 | as_executable_p=as_fn_executable_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16333 | |
| 16334 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 16335 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16336 | |
| 16337 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 16338 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16339 | |
| 16340 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16341 | exec 6>&1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16342 | ## ----------------------------------- ## |
| 16343 | ## Main body of $CONFIG_STATUS script. ## |
| 16344 | ## ----------------------------------- ## |
| 16345 | _ASEOF |
| 16346 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16347 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16348 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 16349 | # Save the log message, to keep $0 and so on meaningful, and to |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16350 | # report actual input values of CONFIG_FILES etc. instead of their |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16351 | # values after options handling. |
| 16352 | ac_log=" |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 16353 | This file was extended by python $as_me 3.5, which was |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16354 | generated by GNU Autoconf 2.69. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16355 | |
| 16356 | CONFIG_FILES = $CONFIG_FILES |
| 16357 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 16358 | CONFIG_LINKS = $CONFIG_LINKS |
| 16359 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 16360 | $ $0 $@ |
| 16361 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16362 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 16363 | " |
| 16364 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16365 | _ACEOF |
| 16366 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16367 | case $ac_config_files in *" |
| 16368 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 16369 | esac |
| 16370 | |
| 16371 | case $ac_config_headers in *" |
| 16372 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 16373 | esac |
| 16374 | |
| 16375 | |
| 16376 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16377 | # Files that config.status was made for. |
Charles-François Natali | 6613c18 | 2011-11-27 12:41:06 +0100 | [diff] [blame] | 16378 | config_files="$ac_config_files" |
| 16379 | config_headers="$ac_config_headers" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16380 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16381 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16382 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16383 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16384 | ac_cs_usage="\ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16385 | \`$as_me' instantiates files and other configuration actions |
| 16386 | from templates according to the current configuration. Unless the files |
| 16387 | and actions are specified as TAGs, all are instantiated by default. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16388 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16389 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16390 | |
| 16391 | -h, --help print this help, then exit |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16392 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16393 | --config print configuration, then exit |
| 16394 | -q, --quiet, --silent |
| 16395 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16396 | -d, --debug don't remove temporary files |
| 16397 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16398 | --file=FILE[:TEMPLATE] |
| 16399 | instantiate the configuration file FILE |
| 16400 | --header=FILE[:TEMPLATE] |
| 16401 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16402 | |
| 16403 | Configuration files: |
| 16404 | $config_files |
| 16405 | |
| 16406 | Configuration headers: |
| 16407 | $config_headers |
| 16408 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16409 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 16410 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16411 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16412 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 16413 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16414 | ac_cs_version="\\ |
Larry Hastings | f5002bd | 2014-03-16 23:05:59 -0700 | [diff] [blame] | 16415 | python config.status 3.5 |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16416 | configured by $0, generated by GNU Autoconf 2.69, |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16417 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16418 | |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16419 | Copyright (C) 2012 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16420 | This config.status script is free software; the Free Software Foundation |
| 16421 | gives unlimited permission to copy, distribute and modify it." |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16422 | |
| 16423 | ac_pwd='$ac_pwd' |
| 16424 | srcdir='$srcdir' |
| 16425 | INSTALL='$INSTALL' |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 16426 | MKDIR_P='$MKDIR_P' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16427 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16428 | _ACEOF |
| 16429 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16430 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 16431 | # The default lists apply if the user does not specify any file. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16432 | ac_need_defaults=: |
| 16433 | while test $# != 0 |
| 16434 | do |
| 16435 | case $1 in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16436 | --*=?*) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16437 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 16438 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16439 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16440 | ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16441 | --*=) |
| 16442 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 16443 | ac_optarg= |
| 16444 | ac_shift=: |
| 16445 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16446 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16447 | ac_option=$1 |
| 16448 | ac_optarg=$2 |
| 16449 | ac_shift=shift |
| 16450 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16451 | esac |
| 16452 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16453 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16454 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16455 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 16456 | ac_cs_recheck=: ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16457 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16458 | $as_echo "$ac_cs_version"; exit ;; |
| 16459 | --config | --confi | --conf | --con | --co | --c ) |
| 16460 | $as_echo "$ac_cs_config"; exit ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16461 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16462 | debug=: ;; |
| 16463 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16464 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16465 | case $ac_optarg in |
| 16466 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16467 | '') as_fn_error $? "missing file argument" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16468 | esac |
| 16469 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16470 | ac_need_defaults=false;; |
| 16471 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16472 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16473 | case $ac_optarg in |
| 16474 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 16475 | esac |
| 16476 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16477 | ac_need_defaults=false;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16478 | --he | --h) |
| 16479 | # Conflict between --help and --header |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16480 | as_fn_error $? "ambiguous option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16481 | Try \`$0 --help' for more information.";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16482 | --help | --hel | -h ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16483 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16484 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 16485 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 16486 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16487 | |
| 16488 | # This is an error. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16489 | -*) as_fn_error $? "unrecognized option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16490 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16491 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16492 | *) as_fn_append ac_config_targets " $1" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16493 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16494 | |
| 16495 | esac |
| 16496 | shift |
| 16497 | done |
| 16498 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16499 | ac_configure_extra_args= |
| 16500 | |
| 16501 | if $ac_cs_silent; then |
| 16502 | exec 6>/dev/null |
| 16503 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 16504 | fi |
| 16505 | |
| 16506 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16507 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16508 | if \$ac_cs_recheck; then |
Ross Lagerwall | 1b863eb | 2012-10-29 17:31:54 +0000 | [diff] [blame] | 16509 | set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16510 | shift |
| 16511 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 16512 | CONFIG_SHELL='$SHELL' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16513 | export CONFIG_SHELL |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16514 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16515 | fi |
| 16516 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16517 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16518 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16519 | exec 5>>config.log |
| 16520 | { |
| 16521 | echo |
| 16522 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 16523 | ## Running $as_me. ## |
| 16524 | _ASBOX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16525 | $as_echo "$ac_log" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16526 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16527 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16528 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16529 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16530 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16531 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16532 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16533 | |
| 16534 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16535 | for ac_config_target in $ac_config_targets |
| 16536 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16537 | case $ac_config_target in |
| 16538 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 16539 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 16540 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 16541 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 16542 | "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16543 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 16544 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 16545 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
doko@python.org | 8742119 | 2013-01-26 11:39:31 +0100 | [diff] [blame] | 16546 | "Misc/python-config.sh") CONFIG_FILES="$CONFIG_FILES Misc/python-config.sh" ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 16547 | "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16548 | |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16549 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16550 | esac |
| 16551 | done |
| 16552 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16553 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16554 | # If the user did not use the arguments to specify the items to instantiate, |
| 16555 | # then the envvar interface is used. Set only those that are not. |
| 16556 | # We use the long form for the default assignment because of an extremely |
| 16557 | # bizarre bug on SunOS 4.1.3. |
| 16558 | if $ac_need_defaults; then |
| 16559 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 16560 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 16561 | fi |
| 16562 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16563 | # Have a temporary directory for convenience. Make it in the build tree |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16564 | # simply because there is no reason against having it here, and in addition, |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16565 | # creating and moving files from /tmp can sometimes cause problems. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16566 | # Hook for its removal unless debugging. |
| 16567 | # Note that there is a small window in which the directory will not be cleaned: |
| 16568 | # after its creation but before its name has been assigned to `$tmp'. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16569 | $debug || |
| 16570 | { |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16571 | tmp= ac_tmp= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16572 | trap 'exit_status=$? |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16573 | : "${ac_tmp:=$tmp}" |
| 16574 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16575 | ' 0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16576 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16577 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16578 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 16579 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16580 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16581 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16582 | test -d "$tmp" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16583 | } || |
| 16584 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16585 | tmp=./conf$$-$RANDOM |
| 16586 | (umask 077 && mkdir "$tmp") |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16587 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16588 | ac_tmp=$tmp |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16590 | # Set up the scripts for CONFIG_FILES section. |
| 16591 | # No need to generate them if there are no CONFIG_FILES. |
| 16592 | # This happens for instance with `./config.status config.h'. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16593 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16594 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16595 | |
| 16596 | ac_cr=`echo X | tr X '\015'` |
| 16597 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 16598 | # But we know of no other shell where ac_cr would be empty at this |
| 16599 | # point, so we can use a bashism as a fallback. |
| 16600 | if test "x$ac_cr" = x; then |
| 16601 | eval ac_cr=\$\'\\r\' |
| 16602 | fi |
| 16603 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 16604 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16605 | ac_cs_awk_cr='\\r' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16606 | else |
| 16607 | ac_cs_awk_cr=$ac_cr |
| 16608 | fi |
| 16609 | |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16610 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16611 | _ACEOF |
| 16612 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16613 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16614 | { |
| 16615 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 16616 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 16617 | echo "_ACEOF" |
| 16618 | } >conf$$subs.sh || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16619 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 16620 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16621 | ac_delim='%!_!# ' |
| 16622 | for ac_last_try in false false false false false :; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16623 | . ./conf$$subs.sh || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16624 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16625 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16626 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 16627 | if test $ac_delim_n = $ac_delim_num; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16628 | break |
| 16629 | elif $ac_last_try; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16630 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16631 | else |
| 16632 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16633 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16634 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16635 | rm -f conf$$subs.sh |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16636 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16637 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16638 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16639 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16640 | sed -n ' |
| 16641 | h |
| 16642 | s/^/S["/; s/!.*/"]=/ |
| 16643 | p |
| 16644 | g |
| 16645 | s/^[^!]*!// |
| 16646 | :repl |
| 16647 | t repl |
| 16648 | s/'"$ac_delim"'$// |
| 16649 | t delim |
| 16650 | :nl |
| 16651 | h |
| 16652 | s/\(.\{148\}\)..*/\1/ |
| 16653 | t more1 |
| 16654 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 16655 | p |
| 16656 | n |
| 16657 | b repl |
| 16658 | :more1 |
| 16659 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 16660 | p |
| 16661 | g |
| 16662 | s/.\{148\}// |
| 16663 | t nl |
| 16664 | :delim |
| 16665 | h |
| 16666 | s/\(.\{148\}\)..*/\1/ |
| 16667 | t more2 |
| 16668 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 16669 | p |
| 16670 | b |
| 16671 | :more2 |
| 16672 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 16673 | p |
| 16674 | g |
| 16675 | s/.\{148\}// |
| 16676 | t delim |
| 16677 | ' <conf$$subs.awk | sed ' |
| 16678 | /^[^""]/{ |
| 16679 | N |
| 16680 | s/\n// |
| 16681 | } |
| 16682 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 16683 | rm -f conf$$subs.awk |
| 16684 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 16685 | _ACAWK |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16686 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16687 | for (key in S) S_is_set[key] = 1 |
| 16688 | FS = "" |
| 16689 | |
| 16690 | } |
| 16691 | { |
| 16692 | line = $ 0 |
| 16693 | nfields = split(line, field, "@") |
| 16694 | substed = 0 |
| 16695 | len = length(field[1]) |
| 16696 | for (i = 2; i < nfields; i++) { |
| 16697 | key = field[i] |
| 16698 | keylen = length(key) |
| 16699 | if (S_is_set[key]) { |
| 16700 | value = S[key] |
| 16701 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 16702 | len += length(value) + length(field[++i]) |
| 16703 | substed = 1 |
| 16704 | } else |
| 16705 | len += 1 + keylen |
| 16706 | } |
| 16707 | |
| 16708 | print line |
| 16709 | } |
| 16710 | |
| 16711 | _ACAWK |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16712 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16713 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 16714 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 16715 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 16716 | else |
| 16717 | cat |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16718 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16719 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 16720 | _ACEOF |
| 16721 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16722 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
| 16723 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16724 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 16725 | # (actually we leave an empty line to preserve line numbers). |
| 16726 | if test "x$srcdir" = x.; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16727 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
| 16728 | h |
| 16729 | s/// |
| 16730 | s/^/:/ |
| 16731 | s/[ ]*$/:/ |
| 16732 | s/:\$(srcdir):/:/g |
| 16733 | s/:\${srcdir}:/:/g |
| 16734 | s/:@srcdir@:/:/g |
| 16735 | s/^:*// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16736 | s/:*$// |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16737 | x |
| 16738 | s/\(=[ ]*\).*/\1/ |
| 16739 | G |
| 16740 | s/\n// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16741 | s/^[^=]*=[ ]*$// |
| 16742 | }' |
| 16743 | fi |
| 16744 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16745 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16746 | fi # test -n "$CONFIG_FILES" |
| 16747 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16748 | # Set up the scripts for CONFIG_HEADERS section. |
| 16749 | # No need to generate them if there are no CONFIG_HEADERS. |
| 16750 | # This happens for instance with `./config.status Makefile'. |
| 16751 | if test -n "$CONFIG_HEADERS"; then |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16752 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16753 | BEGIN { |
| 16754 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16755 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16756 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 16757 | # here-document in config.status, that substitutes the proper values into |
| 16758 | # config.h.in to produce config.h. |
| 16759 | |
| 16760 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 16761 | # handling of long lines. |
| 16762 | ac_delim='%!_!# ' |
| 16763 | for ac_last_try in false false :; do |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16764 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
| 16765 | if test -z "$ac_tt"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16766 | break |
| 16767 | elif $ac_last_try; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16768 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16769 | else |
| 16770 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 16771 | fi |
| 16772 | done |
| 16773 | |
| 16774 | # For the awk script, D is an array of macro values keyed by name, |
| 16775 | # likewise P contains macro parameters if any. Preserve backslash |
| 16776 | # newline sequences. |
| 16777 | |
| 16778 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 16779 | sed -n ' |
| 16780 | s/.\{148\}/&'"$ac_delim"'/g |
| 16781 | t rset |
| 16782 | :rset |
| 16783 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 16784 | t def |
| 16785 | d |
| 16786 | :def |
| 16787 | s/\\$// |
| 16788 | t bsnl |
| 16789 | s/["\\]/\\&/g |
| 16790 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 16791 | D["\1"]=" \3"/p |
| 16792 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 16793 | d |
| 16794 | :bsnl |
| 16795 | s/["\\]/\\&/g |
| 16796 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 16797 | D["\1"]=" \3\\\\\\n"\\/p |
| 16798 | t cont |
| 16799 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 16800 | t cont |
| 16801 | d |
| 16802 | :cont |
| 16803 | n |
| 16804 | s/.\{148\}/&'"$ac_delim"'/g |
| 16805 | t clear |
| 16806 | :clear |
| 16807 | s/\\$// |
| 16808 | t bsnlc |
| 16809 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 16810 | d |
| 16811 | :bsnlc |
| 16812 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 16813 | b cont |
| 16814 | ' <confdefs.h | sed ' |
| 16815 | s/'"$ac_delim"'/"\\\ |
| 16816 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 16817 | |
| 16818 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 16819 | for (key in D) D_is_set[key] = 1 |
| 16820 | FS = "" |
| 16821 | } |
| 16822 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 16823 | line = \$ 0 |
| 16824 | split(line, arg, " ") |
| 16825 | if (arg[1] == "#") { |
| 16826 | defundef = arg[2] |
| 16827 | mac1 = arg[3] |
| 16828 | } else { |
| 16829 | defundef = substr(arg[1], 2) |
| 16830 | mac1 = arg[2] |
| 16831 | } |
| 16832 | split(mac1, mac2, "(") #) |
| 16833 | macro = mac2[1] |
| 16834 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 16835 | if (D_is_set[macro]) { |
| 16836 | # Preserve the white space surrounding the "#". |
| 16837 | print prefix "define", macro P[macro] D[macro] |
| 16838 | next |
| 16839 | } else { |
| 16840 | # Replace #undef with comments. This is necessary, for example, |
| 16841 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 16842 | # on some systems where configure will not decide to define it. |
| 16843 | if (defundef == "undef") { |
| 16844 | print "/*", prefix defundef, macro, "*/" |
| 16845 | next |
| 16846 | } |
| 16847 | } |
| 16848 | } |
| 16849 | { print } |
| 16850 | _ACAWK |
| 16851 | _ACEOF |
| 16852 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 16853 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16854 | fi # test -n "$CONFIG_HEADERS" |
| 16855 | |
| 16856 | |
| 16857 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 16858 | shift |
| 16859 | for ac_tag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16860 | do |
| 16861 | case $ac_tag in |
| 16862 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 16863 | esac |
| 16864 | case $ac_mode$ac_tag in |
| 16865 | :[FHL]*:*);; |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16866 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16867 | :[FH]-) ac_tag=-:-;; |
| 16868 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 16869 | esac |
| 16870 | ac_save_IFS=$IFS |
| 16871 | IFS=: |
| 16872 | set x $ac_tag |
| 16873 | IFS=$ac_save_IFS |
| 16874 | shift |
| 16875 | ac_file=$1 |
| 16876 | shift |
| 16877 | |
| 16878 | case $ac_mode in |
| 16879 | :L) ac_source=$1;; |
| 16880 | :[FH]) |
| 16881 | ac_file_inputs= |
| 16882 | for ac_f |
| 16883 | do |
| 16884 | case $ac_f in |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16885 | -) ac_f="$ac_tmp/stdin";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16886 | *) # Look for the file first in the build tree, then in the source tree |
| 16887 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 16888 | # because $ac_f cannot contain `:'. |
| 16889 | test -f "$ac_f" || |
| 16890 | case $ac_f in |
| 16891 | [\\/$]*) false;; |
| 16892 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 16893 | esac || |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16894 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16895 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16896 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 16897 | as_fn_append ac_file_inputs " '$ac_f'" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16898 | done |
| 16899 | |
| 16900 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 16901 | # use $as_me), people would be surprised to read: |
| 16902 | # /* config.h. Generated by config.status. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16903 | configure_input='Generated from '` |
| 16904 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 16905 | `' by configure.' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16906 | if test x"$ac_file" != x-; then |
| 16907 | configure_input="$ac_file. $configure_input" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16908 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 16909 | $as_echo "$as_me: creating $ac_file" >&6;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16910 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16911 | # Neutralize special characters interpreted by sed in replacement strings. |
| 16912 | case $configure_input in #( |
| 16913 | *\&* | *\|* | *\\* ) |
| 16914 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 16915 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 16916 | *) ac_sed_conf_input=$configure_input;; |
| 16917 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16918 | |
| 16919 | case $ac_tag in |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 16920 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
| 16921 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16922 | esac |
| 16923 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16924 | esac |
| 16925 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16926 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16927 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 16928 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 16929 | X"$ac_file" : 'X\(//\)$' \| \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16930 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16931 | $as_echo X"$ac_file" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16932 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 16933 | s//\1/ |
| 16934 | q |
| 16935 | } |
| 16936 | /^X\(\/\/\)[^/].*/{ |
| 16937 | s//\1/ |
| 16938 | q |
| 16939 | } |
| 16940 | /^X\(\/\/\)$/{ |
| 16941 | s//\1/ |
| 16942 | q |
| 16943 | } |
| 16944 | /^X\(\/\).*/{ |
| 16945 | s//\1/ |
| 16946 | q |
| 16947 | } |
| 16948 | s/.*/./; q'` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16949 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16950 | ac_builddir=. |
| 16951 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16952 | case "$ac_dir" in |
| 16953 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 16954 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16955 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16956 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16957 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16958 | case $ac_top_builddir_sub in |
| 16959 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 16960 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 16961 | esac ;; |
| 16962 | esac |
| 16963 | ac_abs_top_builddir=$ac_pwd |
| 16964 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 16965 | # for backward compatibility: |
| 16966 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16967 | |
| 16968 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16969 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16970 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16971 | ac_top_srcdir=$ac_top_builddir_sub |
| 16972 | ac_abs_top_srcdir=$ac_pwd ;; |
| 16973 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16974 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16975 | ac_top_srcdir=$srcdir |
| 16976 | ac_abs_top_srcdir=$srcdir ;; |
| 16977 | *) # Relative name. |
| 16978 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 16979 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 16980 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16981 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16982 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 16983 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16984 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16985 | case $ac_mode in |
| 16986 | :F) |
| 16987 | # |
| 16988 | # CONFIG_FILE |
| 16989 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16990 | |
| 16991 | case $INSTALL in |
| 16992 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 16993 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 16994 | esac |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 16995 | ac_MKDIR_P=$MKDIR_P |
| 16996 | case $MKDIR_P in |
| 16997 | [\\/$]* | ?:[\\/]* ) ;; |
| 16998 | */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; |
| 16999 | esac |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 17000 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17001 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17002 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17003 | # If the template does not know about datarootdir, expand it. |
| 17004 | # FIXME: This hack should be removed a few years after 2.60. |
| 17005 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17006 | ac_sed_dataroot=' |
| 17007 | /datarootdir/ { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17008 | p |
| 17009 | q |
| 17010 | } |
| 17011 | /@datadir@/p |
| 17012 | /@docdir@/p |
| 17013 | /@infodir@/p |
| 17014 | /@localedir@/p |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17015 | /@mandir@/p' |
| 17016 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17017 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 17018 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17019 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 17020 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17021 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17022 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17023 | ac_datarootdir_hack=' |
| 17024 | s&@datadir@&$datadir&g |
| 17025 | s&@docdir@&$docdir&g |
| 17026 | s&@infodir@&$infodir&g |
| 17027 | s&@localedir@&$localedir&g |
| 17028 | s&@mandir@&$mandir&g |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17029 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17030 | esac |
| 17031 | _ACEOF |
| 17032 | |
| 17033 | # Neutralize VPATH when `$srcdir' = `.'. |
| 17034 | # Shell code in configure.ac might set extrasub. |
| 17035 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17036 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 17037 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17038 | $extrasub |
| 17039 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17040 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17041 | :t |
| 17042 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17043 | s|@configure_input@|$ac_sed_conf_input|;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17044 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17045 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17046 | s&@srcdir@&$ac_srcdir&;t t |
| 17047 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 17048 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 17049 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 17050 | s&@builddir@&$ac_builddir&;t t |
| 17051 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 17052 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 17053 | s&@INSTALL@&$ac_INSTALL&;t t |
Matthias Klose | 93a0ef1 | 2012-03-15 18:08:34 +0100 | [diff] [blame] | 17054 | s&@MKDIR_P@&$ac_MKDIR_P&;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17055 | $ac_datarootdir_hack |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17056 | " |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17057 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
| 17058 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 17059 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17060 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17061 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
| 17062 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ |
| 17063 | "$ac_tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17064 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17065 | which seems to be undefined. Please make sure it is defined" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17066 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17067 | which seems to be undefined. Please make sure it is defined" >&2;} |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 17068 | |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17069 | rm -f "$ac_tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17070 | case $ac_file in |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17071 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
| 17072 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17073 | esac \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17074 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17075 | ;; |
| 17076 | :H) |
| 17077 | # |
| 17078 | # CONFIG_HEADER |
| 17079 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17080 | if test x"$ac_file" != x-; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17081 | { |
| 17082 | $as_echo "/* $configure_input */" \ |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17083 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
| 17084 | } >"$ac_tmp/config.h" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17085 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17086 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17087 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 17088 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17089 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17090 | rm -f "$ac_file" |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17091 | mv "$ac_tmp/config.h" "$ac_file" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17092 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17093 | fi |
| 17094 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17095 | $as_echo "/* $configure_input */" \ |
Victor Stinner | e0be423 | 2011-10-25 13:06:09 +0200 | [diff] [blame] | 17096 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17097 | || as_fn_error $? "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17098 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17099 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 17100 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17101 | |
| 17102 | esac |
| 17103 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 17104 | |
| 17105 | case $ac_file$ac_mode in |
| 17106 | "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;; |
| 17107 | |
| 17108 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 17109 | done # for ac_tag |
| 17110 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 17111 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17112 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17113 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17114 | ac_clean_files=$ac_clean_files_save |
| 17115 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17116 | test $ac_write_fail = 0 || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17117 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17118 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17119 | |
| 17120 | # configure is writing to config.log, and then calls config.status. |
| 17121 | # config.status does its own redirection, appending to config.log. |
| 17122 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 17123 | # by configure, so config.status won't be able to write to it; its |
| 17124 | # output is simply discarded. So we exec the FD to /dev/null, |
| 17125 | # effectively closing config.log, so it can be properly (re)opened and |
| 17126 | # appended to by config.status. When coming back to configure, we |
| 17127 | # need to make the FD available again. |
| 17128 | if test "$no_create" != yes; then |
| 17129 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 17130 | ac_config_status_args= |
| 17131 | test "$silent" = yes && |
| 17132 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17133 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 17134 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17135 | exec 5>>config.log |
| 17136 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 17137 | # would make configure fail if this is the last instruction. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame] | 17138 | $ac_cs_success || as_fn_exit 1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 17139 | fi |
| 17140 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 17141 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 17142 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 17143 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 17144 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 17145 | |
Christian Heimes | 75ed890 | 2013-11-20 01:11:18 +0100 | [diff] [blame] | 17146 | echo "creating Modules/Setup" >&6 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 17147 | if test ! -f Modules/Setup |
| 17148 | then |
| 17149 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 17150 | fi |
| 17151 | |
Christian Heimes | 75ed890 | 2013-11-20 01:11:18 +0100 | [diff] [blame] | 17152 | echo "creating Modules/Setup.local" >&6 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 17153 | if test ! -f Modules/Setup.local |
| 17154 | then |
| 17155 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 17156 | fi |
| 17157 | |
Christian Heimes | 75ed890 | 2013-11-20 01:11:18 +0100 | [diff] [blame] | 17158 | echo "creating Makefile" >&6 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 17159 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 17160 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 17161 | Modules/Setup.local Modules/Setup |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 17162 | mv config.c Modules |