Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Georg Brandl | 94800df | 2011-02-25 11:09:02 +0000 | [diff] [blame] | 2 | # From configure.in Revision: 88568 . |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3 | # Guess values for system-dependent variables and create Makefiles. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4 | # Generated by GNU Autoconf 2.68 for python 2.7. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5 | # |
Georg Brandl | 464432d | 2009-05-20 18:24:08 +0000 | [diff] [blame] | 6 | # Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 7 | # |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8 | # |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software |
| 11 | # Foundation, Inc. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12 | # |
| 13 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14 | # This configure script is free software; the Free Software Foundation |
| 15 | # gives unlimited permission to copy, distribute and modify it. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 16 | ## -------------------- ## |
| 17 | ## M4sh Initialization. ## |
| 18 | ## -------------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 19 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 20 | # Be more Bourne compatible |
| 21 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 22 | 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] | 23 | emulate sh |
| 24 | NULLCMD=: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 25 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 26 | # is contrary to our usage. Disable this feature. |
| 27 | alias -g '${1+"$@"}'='"$@"' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 28 | setopt NO_GLOB_SUBST |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 29 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 30 | case `(set -o) 2>/dev/null` in #( |
| 31 | *posix*) : |
| 32 | set -o posix ;; #( |
| 33 | *) : |
| 34 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 35 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 36 | fi |
| 37 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 38 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 39 | as_nl=' |
| 40 | ' |
| 41 | export as_nl |
| 42 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 43 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 44 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 45 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 46 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 47 | # but without wasting forks for bash or zsh. |
| 48 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 49 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 50 | as_echo='print -r --' |
| 51 | as_echo_n='print -rn --' |
| 52 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 53 | as_echo='printf %s\n' |
| 54 | as_echo_n='printf %s' |
| 55 | else |
| 56 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 57 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 58 | as_echo_n='/usr/ucb/echo -n' |
| 59 | else |
| 60 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 61 | as_echo_n_body='eval |
| 62 | arg=$1; |
| 63 | case $arg in #( |
| 64 | *"$as_nl"*) |
| 65 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 66 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 67 | esac; |
| 68 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 69 | ' |
| 70 | export as_echo_n_body |
| 71 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 72 | fi |
| 73 | export as_echo_body |
| 74 | as_echo='sh -c $as_echo_body as_echo' |
| 75 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 76 | |
| 77 | # The user is always right. |
| 78 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 79 | PATH_SEPARATOR=: |
| 80 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 81 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 82 | PATH_SEPARATOR=';' |
| 83 | } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 84 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 85 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 86 | |
| 87 | # IFS |
| 88 | # We need space, tab and new line, in precisely that order. Quoting is |
| 89 | # there to prevent editors from complaining about space-tab. |
| 90 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 91 | # splitting by setting IFS to empty value.) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 92 | IFS=" "" $as_nl" |
| 93 | |
| 94 | # Find who we are. Look in the path if we contain no directory separator. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 95 | as_myself= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 96 | case $0 in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 97 | *[\\/]* ) as_myself=$0 ;; |
| 98 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 99 | for as_dir in $PATH |
| 100 | do |
| 101 | IFS=$as_save_IFS |
| 102 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 103 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 104 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 105 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 106 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 107 | ;; |
| 108 | esac |
| 109 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 110 | # in which case we are not to be found in the path. |
| 111 | if test "x$as_myself" = x; then |
| 112 | as_myself=$0 |
| 113 | fi |
| 114 | if test ! -f "$as_myself"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 115 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 116 | exit 1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 117 | fi |
| 118 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 119 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 120 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 121 | # suppresses any "Segmentation fault" message there. '((' could |
| 122 | # trigger a bug in pdksh 5.2.14. |
| 123 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 124 | do eval test x\${$as_var+set} = xset \ |
| 125 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 126 | done |
| 127 | PS1='$ ' |
| 128 | PS2='> ' |
| 129 | PS4='+ ' |
| 130 | |
| 131 | # NLS nuisances. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 132 | LC_ALL=C |
| 133 | export LC_ALL |
| 134 | LANGUAGE=C |
| 135 | export LANGUAGE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 136 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 137 | # CDPATH. |
| 138 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 139 | |
| 140 | if test "x$CONFIG_SHELL" = x; then |
| 141 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 142 | emulate sh |
| 143 | NULLCMD=: |
| 144 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 145 | # is contrary to our usage. Disable this feature. |
| 146 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 147 | setopt NO_GLOB_SUBST |
| 148 | else |
| 149 | case \`(set -o) 2>/dev/null\` in #( |
| 150 | *posix*) : |
| 151 | set -o posix ;; #( |
| 152 | *) : |
| 153 | ;; |
| 154 | esac |
| 155 | fi |
| 156 | " |
| 157 | as_required="as_fn_return () { (exit \$1); } |
| 158 | as_fn_success () { as_fn_return 0; } |
| 159 | as_fn_failure () { as_fn_return 1; } |
| 160 | as_fn_ret_success () { return 0; } |
| 161 | as_fn_ret_failure () { return 1; } |
| 162 | |
| 163 | exitcode=0 |
| 164 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 165 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 166 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 167 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 168 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 169 | |
| 170 | else |
| 171 | exitcode=1; echo positional parameters were not saved. |
| 172 | fi |
| 173 | test x\$exitcode = x0 || exit 1" |
| 174 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 175 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 176 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 177 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 178 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 179 | if (eval "$as_required") 2>/dev/null; then : |
| 180 | as_have_required=yes |
| 181 | else |
| 182 | as_have_required=no |
| 183 | fi |
| 184 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 185 | |
| 186 | else |
| 187 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 188 | as_found=false |
| 189 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 190 | do |
| 191 | IFS=$as_save_IFS |
| 192 | test -z "$as_dir" && as_dir=. |
| 193 | as_found=: |
| 194 | case $as_dir in #( |
| 195 | /*) |
| 196 | for as_base in sh bash ksh sh5; do |
| 197 | # Try only shells that exist, to save several forks. |
| 198 | as_shell=$as_dir/$as_base |
| 199 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 200 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 201 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 202 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 203 | break 2 |
| 204 | fi |
| 205 | fi |
| 206 | done;; |
| 207 | esac |
| 208 | as_found=false |
| 209 | done |
| 210 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 211 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 212 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 213 | fi; } |
| 214 | IFS=$as_save_IFS |
| 215 | |
| 216 | |
| 217 | if test "x$CONFIG_SHELL" != x; then : |
| 218 | # We cannot yet assume a decent shell, so we have to provide a |
| 219 | # neutralization value for shells without unset; and this also |
| 220 | # works around shells that cannot unset nonexistent variables. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 221 | # Preserve -v and -x to the replacement shell. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 222 | BASH_ENV=/dev/null |
| 223 | ENV=/dev/null |
| 224 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 225 | export CONFIG_SHELL |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 226 | case $- in # (((( |
| 227 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 228 | *v* ) as_opts=-v ;; |
| 229 | *x* ) as_opts=-x ;; |
| 230 | * ) as_opts= ;; |
| 231 | esac |
| 232 | exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 233 | fi |
| 234 | |
| 235 | if test x$as_have_required = xno; then : |
| 236 | $as_echo "$0: This script requires a shell more modern than all" |
| 237 | $as_echo "$0: the shells that I found on your system." |
| 238 | if test x${ZSH_VERSION+set} = xset ; then |
| 239 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 240 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 241 | else |
| 242 | $as_echo "$0: Please tell bug-autoconf@gnu.org and |
| 243 | $0: http://bugs.python.org/ about your system, including |
| 244 | $0: any error possibly output before this message. Then |
| 245 | $0: install a modern shell, or manually run the script |
| 246 | $0: under such a shell if you do have one." |
| 247 | fi |
| 248 | exit 1 |
| 249 | fi |
| 250 | fi |
| 251 | fi |
| 252 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 253 | export SHELL |
| 254 | # Unset more variables known to interfere with behavior of common tools. |
| 255 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 256 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 257 | |
| 258 | ## --------------------- ## |
| 259 | ## M4sh Shell Functions. ## |
| 260 | ## --------------------- ## |
| 261 | # as_fn_unset VAR |
| 262 | # --------------- |
| 263 | # Portably unset VAR. |
| 264 | as_fn_unset () |
| 265 | { |
| 266 | { eval $1=; unset $1;} |
| 267 | } |
| 268 | as_unset=as_fn_unset |
| 269 | |
| 270 | # as_fn_set_status STATUS |
| 271 | # ----------------------- |
| 272 | # Set $? to STATUS, without forking. |
| 273 | as_fn_set_status () |
| 274 | { |
| 275 | return $1 |
| 276 | } # as_fn_set_status |
| 277 | |
| 278 | # as_fn_exit STATUS |
| 279 | # ----------------- |
| 280 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 281 | as_fn_exit () |
| 282 | { |
| 283 | set +e |
| 284 | as_fn_set_status $1 |
| 285 | exit $1 |
| 286 | } # as_fn_exit |
| 287 | |
| 288 | # as_fn_mkdir_p |
| 289 | # ------------- |
| 290 | # Create "$as_dir" as a directory, including parents if necessary. |
| 291 | as_fn_mkdir_p () |
| 292 | { |
| 293 | |
| 294 | case $as_dir in #( |
| 295 | -*) as_dir=./$as_dir;; |
| 296 | esac |
| 297 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 298 | as_dirs= |
| 299 | while :; do |
| 300 | case $as_dir in #( |
| 301 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 302 | *) as_qdir=$as_dir;; |
| 303 | esac |
| 304 | as_dirs="'$as_qdir' $as_dirs" |
| 305 | as_dir=`$as_dirname -- "$as_dir" || |
| 306 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 307 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 308 | X"$as_dir" : 'X\(//\)$' \| \ |
| 309 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 310 | $as_echo X"$as_dir" | |
| 311 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 312 | s//\1/ |
| 313 | q |
| 314 | } |
| 315 | /^X\(\/\/\)[^/].*/{ |
| 316 | s//\1/ |
| 317 | q |
| 318 | } |
| 319 | /^X\(\/\/\)$/{ |
| 320 | s//\1/ |
| 321 | q |
| 322 | } |
| 323 | /^X\(\/\).*/{ |
| 324 | s//\1/ |
| 325 | q |
| 326 | } |
| 327 | s/.*/./; q'` |
| 328 | test -d "$as_dir" && break |
| 329 | done |
| 330 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 331 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 332 | |
| 333 | |
| 334 | } # as_fn_mkdir_p |
| 335 | # as_fn_append VAR VALUE |
| 336 | # ---------------------- |
| 337 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 338 | # advantage of any shell optimizations that allow amortized linear growth over |
| 339 | # repeated appends, instead of the typical quadratic growth present in naive |
| 340 | # implementations. |
| 341 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 342 | eval 'as_fn_append () |
| 343 | { |
| 344 | eval $1+=\$2 |
| 345 | }' |
| 346 | else |
| 347 | as_fn_append () |
| 348 | { |
| 349 | eval $1=\$$1\$2 |
| 350 | } |
| 351 | fi # as_fn_append |
| 352 | |
| 353 | # as_fn_arith ARG... |
| 354 | # ------------------ |
| 355 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 356 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 357 | # must be portable across $(()) and expr. |
| 358 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 359 | eval 'as_fn_arith () |
| 360 | { |
| 361 | as_val=$(( $* )) |
| 362 | }' |
| 363 | else |
| 364 | as_fn_arith () |
| 365 | { |
| 366 | as_val=`expr "$@" || test $? -eq 1` |
| 367 | } |
| 368 | fi # as_fn_arith |
| 369 | |
| 370 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 371 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 372 | # ---------------------------------------- |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 373 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 374 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 375 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 376 | as_fn_error () |
| 377 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 378 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 379 | if test "$4"; then |
| 380 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 381 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 382 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 383 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 384 | as_fn_exit $as_status |
| 385 | } # as_fn_error |
| 386 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 387 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 388 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 389 | as_expr=expr |
| 390 | else |
| 391 | as_expr=false |
| 392 | fi |
| 393 | |
| 394 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 395 | as_basename=basename |
| 396 | else |
| 397 | as_basename=false |
| 398 | fi |
| 399 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 400 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 401 | as_dirname=dirname |
| 402 | else |
| 403 | as_dirname=false |
| 404 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 405 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 406 | as_me=`$as_basename -- "$0" || |
| 407 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 408 | X"$0" : 'X\(//\)$' \| \ |
| 409 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 410 | $as_echo X/"$0" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 411 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 412 | s//\1/ |
| 413 | q |
| 414 | } |
| 415 | /^X\/\(\/\/\)$/{ |
| 416 | s//\1/ |
| 417 | q |
| 418 | } |
| 419 | /^X\/\(\/\).*/{ |
| 420 | s//\1/ |
| 421 | q |
| 422 | } |
| 423 | s/.*/./; q'` |
| 424 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 425 | # Avoid depending upon Character Ranges. |
| 426 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 427 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 428 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 429 | as_cr_digits='0123456789' |
| 430 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 431 | |
| 432 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 433 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 434 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 435 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 436 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 437 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 438 | sed -n ' |
| 439 | p |
| 440 | /[$]LINENO/= |
| 441 | ' <$as_myself | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 442 | sed ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 443 | s/[$]LINENO.*/&-/ |
| 444 | t lineno |
| 445 | b |
| 446 | :lineno |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 447 | N |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 448 | :loop |
| 449 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 450 | t loop |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 451 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 452 | ' >$as_me.lineno && |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 453 | chmod +x "$as_me.lineno" || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 454 | { $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] | 455 | |
| 456 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 457 | # (the dirname of $[0] is not the place where we might find the |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 458 | # original and so on. Autoconf is especially sensitive to this). |
| 459 | . "./$as_me.lineno" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 460 | # Exit status is that of the last command. |
| 461 | exit |
| 462 | } |
| 463 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 464 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 465 | case `echo -n x` in #((((( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 466 | -n*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 467 | case `echo 'xy\c'` in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 468 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 469 | xy) ECHO_C='\c';; |
| 470 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 471 | ECHO_T=' ';; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 472 | esac;; |
| 473 | *) |
| 474 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 475 | esac |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 476 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 477 | rm -f conf$$ conf$$.exe conf$$.file |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 478 | if test -d conf$$.dir; then |
| 479 | rm -f conf$$.dir/conf$$.file |
| 480 | else |
| 481 | rm -f conf$$.dir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 482 | mkdir conf$$.dir 2>/dev/null |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 483 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 484 | if (echo >conf$$.file) 2>/dev/null; then |
| 485 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 486 | as_ln_s='ln -s' |
| 487 | # ... but there are two gotchas: |
| 488 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 489 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 490 | # In both cases, we have to default to `cp -p'. |
| 491 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 492 | as_ln_s='cp -p' |
| 493 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 494 | as_ln_s=ln |
| 495 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 496 | as_ln_s='cp -p' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 497 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 498 | else |
| 499 | as_ln_s='cp -p' |
| 500 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 501 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 502 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 503 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 504 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 505 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 506 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 507 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 508 | as_mkdir_p=false |
| 509 | fi |
| 510 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 511 | if test -x / >/dev/null 2>&1; then |
| 512 | as_test_x='test -x' |
| 513 | else |
| 514 | if ls -dL / >/dev/null 2>&1; then |
| 515 | as_ls_L_option=L |
| 516 | else |
| 517 | as_ls_L_option= |
| 518 | fi |
| 519 | as_test_x=' |
| 520 | eval sh -c '\'' |
| 521 | if test -d "$1"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 522 | test -d "$1/."; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 523 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 524 | case $1 in #( |
| 525 | -*)set "./$1";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 526 | esac; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 527 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 528 | ???[sx]*):;;*)false;;esac;fi |
| 529 | '\'' sh |
| 530 | ' |
| 531 | fi |
| 532 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 533 | |
| 534 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 535 | 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] | 536 | |
| 537 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 538 | 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] | 539 | |
| 540 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 541 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 542 | exec 6>&1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 543 | |
| 544 | # Name of the host. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 545 | # 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] | 546 | # so uname gets run too. |
| 547 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 548 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 549 | # |
| 550 | # Initializations. |
| 551 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 552 | ac_default_prefix=/usr/local |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 553 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 554 | ac_config_libobj_dir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 555 | LIBOBJS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 556 | cross_compiling=no |
| 557 | subdirs= |
| 558 | MFLAGS= |
| 559 | MAKEFLAGS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 560 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 561 | # Identity of this package. |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 562 | PACKAGE_NAME='python' |
| 563 | PACKAGE_TARNAME='python' |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 564 | PACKAGE_VERSION='2.7' |
| 565 | PACKAGE_STRING='python 2.7' |
Georg Brandl | 464432d | 2009-05-20 18:24:08 +0000 | [diff] [blame] | 566 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 567 | PACKAGE_URL='' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 568 | |
| 569 | ac_unique_file="Include/object.h" |
| 570 | # Factoring default headers for most tests. |
| 571 | ac_includes_default="\ |
| 572 | #include <stdio.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 573 | #ifdef HAVE_SYS_TYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 574 | # include <sys/types.h> |
| 575 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 576 | #ifdef HAVE_SYS_STAT_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 577 | # include <sys/stat.h> |
| 578 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 579 | #ifdef STDC_HEADERS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 580 | # include <stdlib.h> |
| 581 | # include <stddef.h> |
| 582 | #else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 583 | # ifdef HAVE_STDLIB_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 584 | # include <stdlib.h> |
| 585 | # endif |
| 586 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 587 | #ifdef HAVE_STRING_H |
| 588 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 589 | # include <memory.h> |
| 590 | # endif |
| 591 | # include <string.h> |
| 592 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 593 | #ifdef HAVE_STRINGS_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 594 | # include <strings.h> |
| 595 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 596 | #ifdef HAVE_INTTYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 597 | # include <inttypes.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 598 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 599 | #ifdef HAVE_STDINT_H |
| 600 | # include <stdint.h> |
| 601 | #endif |
| 602 | #ifdef HAVE_UNISTD_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 603 | # include <unistd.h> |
| 604 | #endif" |
| 605 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 606 | ac_subst_vars='LTLIBOBJS |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 607 | SRCDIRS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 608 | THREADHEADERS |
| 609 | UNICODE_OBJS |
| 610 | LIBC |
| 611 | LIBM |
| 612 | HAVE_GETHOSTBYNAME |
| 613 | HAVE_GETHOSTBYNAME_R |
| 614 | HAVE_GETHOSTBYNAME_R_3_ARG |
| 615 | HAVE_GETHOSTBYNAME_R_5_ARG |
| 616 | HAVE_GETHOSTBYNAME_R_6_ARG |
| 617 | LIBOBJS |
| 618 | TRUE |
| 619 | MACHDEP_OBJS |
| 620 | DYNLOADFILE |
| 621 | DLINCLDIR |
| 622 | THREADOBJ |
| 623 | LDLAST |
| 624 | USE_THREAD_MODULE |
| 625 | SIGNAL_OBJS |
| 626 | USE_SIGNAL_MODULE |
| 627 | LIBFFI_INCLUDEDIR |
| 628 | PKG_CONFIG |
| 629 | SHLIBS |
| 630 | CFLAGSFORSHARED |
| 631 | LINKFORSHARED |
| 632 | CCSHARED |
| 633 | BLDSHARED |
| 634 | LDCXXSHARED |
| 635 | LDSHARED |
| 636 | SO |
| 637 | LIBTOOL_CRUFT |
| 638 | OTHER_LIBTOOL_OPT |
| 639 | UNIVERSAL_ARCH_FLAGS |
| 640 | BASECFLAGS |
| 641 | OPT |
| 642 | LN |
| 643 | INSTALL_DATA |
| 644 | INSTALL_SCRIPT |
| 645 | INSTALL_PROGRAM |
| 646 | SVNVERSION |
| 647 | ARFLAGS |
| 648 | AR |
| 649 | RANLIB |
| 650 | GNULD |
| 651 | LINKCC |
| 652 | RUNSHARED |
| 653 | INSTSONAME |
| 654 | LDLIBRARYDIR |
| 655 | BLDLIBRARY |
| 656 | DLLLIBRARY |
| 657 | LDLIBRARY |
| 658 | LIBRARY |
| 659 | BUILDEXEEXT |
| 660 | EGREP |
| 661 | GREP |
| 662 | CPP |
| 663 | MAINCC |
| 664 | CXX |
| 665 | OBJEXT |
| 666 | EXEEXT |
| 667 | ac_ct_CC |
| 668 | CPPFLAGS |
| 669 | LDFLAGS |
| 670 | CFLAGS |
| 671 | CC |
| 672 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 673 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 674 | EXTRAMACHDEPPATH |
| 675 | EXTRAPLATDIR |
| 676 | SGI_ABI |
| 677 | MACHDEP |
| 678 | FRAMEWORKINSTALLAPPSPREFIX |
| 679 | FRAMEWORKUNIXTOOLSPREFIX |
| 680 | FRAMEWORKALTINSTALLLAST |
| 681 | FRAMEWORKALTINSTALLFIRST |
| 682 | FRAMEWORKINSTALLLAST |
| 683 | FRAMEWORKINSTALLFIRST |
| 684 | PYTHONFRAMEWORKINSTALLDIR |
| 685 | PYTHONFRAMEWORKPREFIX |
| 686 | PYTHONFRAMEWORKDIR |
| 687 | PYTHONFRAMEWORKIDENTIFIER |
| 688 | PYTHONFRAMEWORK |
| 689 | LIPO_32BIT_FLAGS |
| 690 | ARCH_RUN_32BIT |
| 691 | UNIVERSALSDK |
| 692 | CONFIG_ARGS |
| 693 | SOVERSION |
| 694 | VERSION |
| 695 | target_alias |
| 696 | host_alias |
| 697 | build_alias |
| 698 | LIBS |
| 699 | ECHO_T |
| 700 | ECHO_N |
| 701 | ECHO_C |
| 702 | DEFS |
| 703 | mandir |
| 704 | localedir |
| 705 | libdir |
| 706 | psdir |
| 707 | pdfdir |
| 708 | dvidir |
| 709 | htmldir |
| 710 | infodir |
| 711 | docdir |
| 712 | oldincludedir |
| 713 | includedir |
| 714 | localstatedir |
| 715 | sharedstatedir |
| 716 | sysconfdir |
| 717 | datadir |
| 718 | datarootdir |
| 719 | libexecdir |
| 720 | sbindir |
| 721 | bindir |
| 722 | program_transform_name |
| 723 | prefix |
| 724 | exec_prefix |
| 725 | PACKAGE_URL |
| 726 | PACKAGE_BUGREPORT |
| 727 | PACKAGE_STRING |
| 728 | PACKAGE_VERSION |
| 729 | PACKAGE_TARNAME |
| 730 | PACKAGE_NAME |
| 731 | PATH_SEPARATOR |
| 732 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 733 | ac_subst_files='' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 734 | ac_user_opts=' |
| 735 | enable_option_checking |
| 736 | enable_universalsdk |
| 737 | with_universal_archs |
| 738 | with_framework_name |
| 739 | enable_framework |
| 740 | with_gcc |
| 741 | with_cxx_main |
| 742 | with_suffix |
| 743 | enable_shared |
| 744 | enable_profiling |
| 745 | with_pydebug |
| 746 | enable_toolbox_glue |
| 747 | with_libs |
| 748 | with_system_expat |
| 749 | with_system_ffi |
| 750 | with_dbmliborder |
| 751 | with_signal_module |
| 752 | with_dec_threads |
| 753 | with_threads |
| 754 | with_thread |
| 755 | with_pth |
| 756 | enable_ipv6 |
| 757 | with_doc_strings |
| 758 | with_tsc |
| 759 | with_pymalloc |
| 760 | with_valgrind |
| 761 | with_wctype_functions |
| 762 | with_fpectl |
| 763 | with_libm |
| 764 | with_libc |
| 765 | enable_big_digits |
| 766 | enable_unicode |
| 767 | ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 768 | ac_precious_vars='build_alias |
| 769 | host_alias |
| 770 | target_alias |
| 771 | CC |
| 772 | CFLAGS |
| 773 | LDFLAGS |
| 774 | LIBS |
| 775 | CPPFLAGS |
| 776 | CPP' |
| 777 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 778 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 779 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 780 | ac_init_help= |
| 781 | ac_init_version=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 782 | ac_unrecognized_opts= |
| 783 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 784 | # The variables have the same names as the options, with |
| 785 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 786 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 787 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 788 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 789 | no_recursion= |
| 790 | prefix=NONE |
| 791 | program_prefix=NONE |
| 792 | program_suffix=NONE |
| 793 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 794 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 795 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 796 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 797 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 798 | x_includes=NONE |
| 799 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 800 | |
| 801 | # Installation directory options. |
| 802 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 803 | # and all the variables that are supposed to be based on exec_prefix |
| 804 | # by default will actually change. |
| 805 | # Use braces instead of parens because sh, perl, etc. also accept them. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 806 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 807 | bindir='${exec_prefix}/bin' |
| 808 | sbindir='${exec_prefix}/sbin' |
| 809 | libexecdir='${exec_prefix}/libexec' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 810 | datarootdir='${prefix}/share' |
| 811 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 812 | sysconfdir='${prefix}/etc' |
| 813 | sharedstatedir='${prefix}/com' |
| 814 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 815 | includedir='${prefix}/include' |
| 816 | oldincludedir='/usr/include' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 817 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 818 | infodir='${datarootdir}/info' |
| 819 | htmldir='${docdir}' |
| 820 | dvidir='${docdir}' |
| 821 | pdfdir='${docdir}' |
| 822 | psdir='${docdir}' |
| 823 | libdir='${exec_prefix}/lib' |
| 824 | localedir='${datarootdir}/locale' |
| 825 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 826 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 827 | ac_prev= |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 828 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 829 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 830 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 831 | # If the previous option needs an argument, assign it. |
| 832 | if test -n "$ac_prev"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 833 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 834 | ac_prev= |
| 835 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 836 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 837 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 838 | case $ac_option in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 839 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 840 | *=) ac_optarg= ;; |
| 841 | *) ac_optarg=yes ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 842 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 843 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 844 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 845 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 846 | case $ac_dashdash$ac_option in |
| 847 | --) |
| 848 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 849 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 850 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 851 | ac_prev=bindir ;; |
| 852 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 853 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 854 | |
| 855 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 856 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 857 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 858 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 859 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 860 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 861 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 862 | ac_prev=cache_file ;; |
| 863 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 864 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 865 | cache_file=$ac_optarg ;; |
| 866 | |
| 867 | --config-cache | -C) |
| 868 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 869 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 870 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 871 | ac_prev=datadir ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 872 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 873 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 874 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 875 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 876 | | --dataroo | --dataro | --datar) |
| 877 | ac_prev=datarootdir ;; |
| 878 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 879 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 880 | datarootdir=$ac_optarg ;; |
| 881 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 882 | -disable-* | --disable-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 883 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 884 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 885 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 886 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 887 | ac_useropt_orig=$ac_useropt |
| 888 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 889 | case $ac_user_opts in |
| 890 | *" |
| 891 | "enable_$ac_useropt" |
| 892 | "*) ;; |
| 893 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 894 | ac_unrecognized_sep=', ';; |
| 895 | esac |
| 896 | eval enable_$ac_useropt=no ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 897 | |
| 898 | -docdir | --docdir | --docdi | --doc | --do) |
| 899 | ac_prev=docdir ;; |
| 900 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 901 | docdir=$ac_optarg ;; |
| 902 | |
| 903 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 904 | ac_prev=dvidir ;; |
| 905 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 906 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 907 | |
| 908 | -enable-* | --enable-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 909 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 910 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 911 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 912 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 913 | ac_useropt_orig=$ac_useropt |
| 914 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 915 | case $ac_user_opts in |
| 916 | *" |
| 917 | "enable_$ac_useropt" |
| 918 | "*) ;; |
| 919 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 920 | ac_unrecognized_sep=', ';; |
| 921 | esac |
| 922 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 923 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 924 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 925 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 926 | | --exec | --exe | --ex) |
| 927 | ac_prev=exec_prefix ;; |
| 928 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 929 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 930 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 931 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 932 | |
| 933 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 934 | # Obsolete; use --with-gas. |
| 935 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 936 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 937 | -help | --help | --hel | --he | -h) |
| 938 | ac_init_help=long ;; |
| 939 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 940 | ac_init_help=recursive ;; |
| 941 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 942 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 943 | |
| 944 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 945 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 946 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 947 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 948 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 949 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 950 | ac_prev=htmldir ;; |
| 951 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 952 | | --ht=*) |
| 953 | htmldir=$ac_optarg ;; |
| 954 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 955 | -includedir | --includedir | --includedi | --included | --include \ |
| 956 | | --includ | --inclu | --incl | --inc) |
| 957 | ac_prev=includedir ;; |
| 958 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 959 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 960 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 961 | |
| 962 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 963 | ac_prev=infodir ;; |
| 964 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 965 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 966 | |
| 967 | -libdir | --libdir | --libdi | --libd) |
| 968 | ac_prev=libdir ;; |
| 969 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 970 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 971 | |
| 972 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 973 | | --libexe | --libex | --libe) |
| 974 | ac_prev=libexecdir ;; |
| 975 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 976 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 977 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 978 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 979 | -localedir | --localedir | --localedi | --localed | --locale) |
| 980 | ac_prev=localedir ;; |
| 981 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 982 | localedir=$ac_optarg ;; |
| 983 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 984 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 985 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 986 | ac_prev=localstatedir ;; |
| 987 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 988 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 989 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 990 | |
| 991 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 992 | ac_prev=mandir ;; |
| 993 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 994 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 995 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 996 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 997 | # Obsolete; use --without-fp. |
| 998 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 999 | |
| 1000 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1001 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1002 | no_create=yes ;; |
| 1003 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1004 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 1005 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 1006 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1007 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1008 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 1009 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 1010 | | --oldin | --oldi | --old | --ol | --o) |
| 1011 | ac_prev=oldincludedir ;; |
| 1012 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1013 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1014 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1015 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1016 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1017 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1018 | ac_prev=prefix ;; |
| 1019 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1020 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1021 | |
| 1022 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1023 | | --program-pre | --program-pr | --program-p) |
| 1024 | ac_prev=program_prefix ;; |
| 1025 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1026 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1027 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1028 | |
| 1029 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1030 | | --program-suf | --program-su | --program-s) |
| 1031 | ac_prev=program_suffix ;; |
| 1032 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1033 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1034 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1035 | |
| 1036 | -program-transform-name | --program-transform-name \ |
| 1037 | | --program-transform-nam | --program-transform-na \ |
| 1038 | | --program-transform-n | --program-transform- \ |
| 1039 | | --program-transform | --program-transfor \ |
| 1040 | | --program-transfo | --program-transf \ |
| 1041 | | --program-trans | --program-tran \ |
| 1042 | | --progr-tra | --program-tr | --program-t) |
| 1043 | ac_prev=program_transform_name ;; |
| 1044 | -program-transform-name=* | --program-transform-name=* \ |
| 1045 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1046 | | --program-transform-n=* | --program-transform-=* \ |
| 1047 | | --program-transform=* | --program-transfor=* \ |
| 1048 | | --program-transfo=* | --program-transf=* \ |
| 1049 | | --program-trans=* | --program-tran=* \ |
| 1050 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1051 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1052 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1053 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1054 | ac_prev=pdfdir ;; |
| 1055 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1056 | pdfdir=$ac_optarg ;; |
| 1057 | |
| 1058 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1059 | ac_prev=psdir ;; |
| 1060 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1061 | psdir=$ac_optarg ;; |
| 1062 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1063 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1064 | | -silent | --silent | --silen | --sile | --sil) |
| 1065 | silent=yes ;; |
| 1066 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1067 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1068 | ac_prev=sbindir ;; |
| 1069 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1070 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1071 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1072 | |
| 1073 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1074 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1075 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1076 | | --sha | --sh) |
| 1077 | ac_prev=sharedstatedir ;; |
| 1078 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1079 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1080 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1081 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1082 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1083 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1084 | -site | --site | --sit) |
| 1085 | ac_prev=site ;; |
| 1086 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1087 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1088 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1089 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1090 | ac_prev=srcdir ;; |
| 1091 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1092 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1093 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1094 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1095 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1096 | ac_prev=sysconfdir ;; |
| 1097 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1098 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1099 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1100 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1101 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1102 | ac_prev=target_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1103 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1104 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1105 | |
| 1106 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1107 | verbose=yes ;; |
| 1108 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1109 | -version | --version | --versio | --versi | --vers | -V) |
| 1110 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1111 | |
| 1112 | -with-* | --with-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1113 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1114 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1115 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1116 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1117 | ac_useropt_orig=$ac_useropt |
| 1118 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1119 | case $ac_user_opts in |
| 1120 | *" |
| 1121 | "with_$ac_useropt" |
| 1122 | "*) ;; |
| 1123 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1124 | ac_unrecognized_sep=', ';; |
| 1125 | esac |
| 1126 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1127 | |
| 1128 | -without-* | --without-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1129 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1130 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1131 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1132 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1133 | ac_useropt_orig=$ac_useropt |
| 1134 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1135 | case $ac_user_opts in |
| 1136 | *" |
| 1137 | "with_$ac_useropt" |
| 1138 | "*) ;; |
| 1139 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1140 | ac_unrecognized_sep=', ';; |
| 1141 | esac |
| 1142 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1143 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1144 | --x) |
| 1145 | # Obsolete; use --with-x. |
| 1146 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1147 | |
| 1148 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1149 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1150 | ac_prev=x_includes ;; |
| 1151 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1152 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1153 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1154 | |
| 1155 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1156 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1157 | ac_prev=x_libraries ;; |
| 1158 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1159 | | --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] | 1160 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1161 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1162 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
| 1163 | Try \`$0 --help' for more information" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1164 | ;; |
| 1165 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1166 | *=*) |
| 1167 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1168 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1169 | case $ac_envvar in #( |
| 1170 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1171 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1172 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1173 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1174 | export $ac_envvar ;; |
| 1175 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1176 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1177 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1178 | $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] | 1179 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1180 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1181 | : "${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] | 1182 | ;; |
| 1183 | |
| 1184 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1185 | done |
| 1186 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1187 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1188 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1189 | as_fn_error $? "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1190 | fi |
| 1191 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1192 | if test -n "$ac_unrecognized_opts"; then |
| 1193 | case $enable_option_checking in |
| 1194 | no) ;; |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1195 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1196 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1197 | esac |
| 1198 | fi |
| 1199 | |
| 1200 | # Check all directory arguments for consistency. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1201 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1202 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1203 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1204 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1205 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1206 | eval ac_val=\$$ac_var |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1207 | # Remove trailing slashes. |
| 1208 | case $ac_val in |
| 1209 | */ ) |
| 1210 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1211 | eval $ac_var=\$ac_val;; |
| 1212 | esac |
| 1213 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1214 | case $ac_val in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1215 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1216 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1217 | esac |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1218 | 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] | 1219 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1220 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1221 | # There might be people who depend on the old broken behavior: `$host' |
| 1222 | # used to hold the argument of --host etc. |
| 1223 | # FIXME: To remove some day. |
| 1224 | build=$build_alias |
| 1225 | host=$host_alias |
| 1226 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1227 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1228 | # FIXME: To remove some day. |
| 1229 | if test "x$host_alias" != x; then |
| 1230 | if test "x$build_alias" = x; then |
| 1231 | cross_compiling=maybe |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1232 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. |
| 1233 | If a cross compiler is detected then cross compile mode will be used" >&2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1234 | elif test "x$build_alias" != "x$host_alias"; then |
| 1235 | cross_compiling=yes |
| 1236 | fi |
| 1237 | fi |
| 1238 | |
| 1239 | ac_tool_prefix= |
| 1240 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1241 | |
| 1242 | test "$silent" = yes && exec 6>/dev/null |
| 1243 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1244 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1245 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1246 | ac_ls_di=`ls -di .` && |
| 1247 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1248 | as_fn_error $? "working directory cannot be determined" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1249 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1250 | as_fn_error $? "pwd does not report name of working directory" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1251 | |
| 1252 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1253 | # Find the source files, if location was not specified. |
| 1254 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1255 | ac_srcdir_defaulted=yes |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1256 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1257 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1258 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1259 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1260 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1261 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1262 | $as_echo X"$as_myself" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1263 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1264 | s//\1/ |
| 1265 | q |
| 1266 | } |
| 1267 | /^X\(\/\/\)[^/].*/{ |
| 1268 | s//\1/ |
| 1269 | q |
| 1270 | } |
| 1271 | /^X\(\/\/\)$/{ |
| 1272 | s//\1/ |
| 1273 | q |
| 1274 | } |
| 1275 | /^X\(\/\).*/{ |
| 1276 | s//\1/ |
| 1277 | q |
| 1278 | } |
| 1279 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1280 | srcdir=$ac_confdir |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1281 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1282 | srcdir=.. |
| 1283 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1284 | else |
| 1285 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1286 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1287 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1288 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1289 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 1290 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1291 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1292 | ac_abs_confdir=`( |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1293 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1294 | pwd)` |
| 1295 | # When building in place, set srcdir=. |
| 1296 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1297 | srcdir=. |
| 1298 | fi |
| 1299 | # Remove unnecessary trailing slashes from srcdir. |
| 1300 | # Double slashes in file names in object file debugging info |
| 1301 | # mess up M-x gdb in Emacs. |
| 1302 | case $srcdir in |
| 1303 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1304 | esac |
| 1305 | for ac_var in $ac_precious_vars; do |
| 1306 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1307 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1308 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1309 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1310 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1311 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1312 | # |
| 1313 | # Report the --help message. |
| 1314 | # |
| 1315 | if test "$ac_init_help" = "long"; then |
| 1316 | # Omit some internal or obsolete options to make the list less imposing. |
| 1317 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1318 | cat <<_ACEOF |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1319 | \`configure' configures python 2.7 to adapt to many kinds of systems. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1320 | |
| 1321 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1322 | |
| 1323 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1324 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1325 | |
| 1326 | Defaults for the options are specified in brackets. |
| 1327 | |
| 1328 | Configuration: |
| 1329 | -h, --help display this help and exit |
| 1330 | --help=short display options specific to this package |
| 1331 | --help=recursive display the short help of all the included packages |
| 1332 | -V, --version display version information and exit |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1333 | -q, --quiet, --silent do not print \`checking ...' messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1334 | --cache-file=FILE cache test results in FILE [disabled] |
| 1335 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1336 | -n, --no-create do not create output files |
| 1337 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1338 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1339 | Installation directories: |
| 1340 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1341 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1342 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1343 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1344 | |
| 1345 | By default, \`make install' will install all the files in |
| 1346 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1347 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1348 | for instance \`--prefix=\$HOME'. |
| 1349 | |
| 1350 | For better control, use the options below. |
| 1351 | |
| 1352 | Fine tuning of the installation directories: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1353 | --bindir=DIR user executables [EPREFIX/bin] |
| 1354 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1355 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1356 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1357 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1358 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1359 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1360 | --includedir=DIR C header files [PREFIX/include] |
| 1361 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1362 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1363 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1364 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1365 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1366 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1367 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1368 | --htmldir=DIR html documentation [DOCDIR] |
| 1369 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1370 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1371 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1372 | _ACEOF |
| 1373 | |
| 1374 | cat <<\_ACEOF |
| 1375 | _ACEOF |
| 1376 | fi |
| 1377 | |
| 1378 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1379 | case $ac_init_help in |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1380 | short | recursive ) echo "Configuration of python 2.7:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1381 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1382 | cat <<\_ACEOF |
| 1383 | |
| 1384 | Optional Features: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1385 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1386 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1387 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Brett Cannon | 91a1dec | 2008-02-13 19:15:44 +0000 | [diff] [blame] | 1388 | --enable-universalsdk[=SDKDIR] |
Brett Cannon | 9a8bb0e | 2008-02-03 02:07:55 +0000 | [diff] [blame] | 1389 | Build against Mac OS X 10.4u SDK (ppc/i386) |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1390 | --enable-framework[=INSTALLDIR] |
| 1391 | Build (MacOSX|Darwin) framework |
| 1392 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1393 | --enable-profiling enable C-level code profiling |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1394 | --enable-toolbox-glue disable/enable MacOSX glue code for extensions |
| 1395 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1396 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 1397 | --enable-big-digits[=BITS] |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1398 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1399 | --enable-unicode[=ucs[24]] |
Benjamin Peterson | 66556b0 | 2010-05-25 02:23:32 +0000 | [diff] [blame] | 1400 | Enable Unicode strings (default is ucs2) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1401 | |
| 1402 | Optional Packages: |
| 1403 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1404 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 1405 | --with-universal-archs=ARCH |
| 1406 | select architectures for universal build ("32-bit", |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 1407 | "64-bit", "3-way", "intel" or "all") |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 1408 | --with-framework-name=FRAMEWORK |
| 1409 | specify an alternate name of the framework built |
| 1410 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1411 | --without-gcc never use gcc |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 1412 | --with-cxx-main=<compiler> |
| 1413 | compile main() and link python executable with C++ |
| 1414 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1415 | --with-suffix=.exe set executable suffix |
| 1416 | --with-pydebug build with Py_DEBUG defined |
| 1417 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | 2c19674 | 2009-12-31 03:17:18 +0000 | [diff] [blame] | 1418 | --with-system-expat build pyexpat module using an installed expat |
| 1419 | library |
Martin v. Löwis | 9176fc1 | 2006-04-11 11:12:43 +0000 | [diff] [blame] | 1420 | --with-system-ffi build _ctypes module using an installed ffi library |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 1421 | --with-dbmliborder=db1:db2:... |
| 1422 | order to check db backends for dbm. Valid value is a |
| 1423 | colon separated string with the backend names |
| 1424 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1425 | --with-signal-module disable/enable signal module |
| 1426 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries |
| 1427 | --with(out)-threads[=DIRECTORY] |
| 1428 | disable/enable thread support |
| 1429 | --with(out)-thread[=DIRECTORY] |
| 1430 | deprecated; use --with(out)-threads |
| 1431 | --with-pth use GNU pth threading libraries |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1432 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1433 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1434 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 1435 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1436 | --with-wctype-functions use wctype.h functions |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1437 | --with-fpectl enable SIGFPE catching |
| 1438 | --with-libm=STRING math library |
| 1439 | --with-libc=STRING C library |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1440 | |
| 1441 | Some influential environment variables: |
| 1442 | CC C compiler command |
| 1443 | CFLAGS C compiler flags |
| 1444 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1445 | nonstandard directory <lib dir> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1446 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1447 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1448 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1449 | CPP C preprocessor |
| 1450 | |
| 1451 | Use these variables to override the choices made by `configure' or to help |
| 1452 | it to find libraries and programs with nonstandard names/locations. |
| 1453 | |
Georg Brandl | 464432d | 2009-05-20 18:24:08 +0000 | [diff] [blame] | 1454 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1455 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1456 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1457 | fi |
| 1458 | |
| 1459 | if test "$ac_init_help" = "recursive"; then |
| 1460 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1461 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1462 | test -d "$ac_dir" || |
| 1463 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1464 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1465 | ac_builddir=. |
| 1466 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1467 | case "$ac_dir" in |
| 1468 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1469 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1470 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1471 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1472 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1473 | case $ac_top_builddir_sub in |
| 1474 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1475 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1476 | esac ;; |
| 1477 | esac |
| 1478 | ac_abs_top_builddir=$ac_pwd |
| 1479 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1480 | # for backward compatibility: |
| 1481 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1482 | |
| 1483 | case $srcdir in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1484 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1485 | ac_srcdir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1486 | ac_top_srcdir=$ac_top_builddir_sub |
| 1487 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1488 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1489 | ac_srcdir=$srcdir$ac_dir_suffix; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1490 | ac_top_srcdir=$srcdir |
| 1491 | ac_abs_top_srcdir=$srcdir ;; |
| 1492 | *) # Relative name. |
| 1493 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1494 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1495 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1496 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1497 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1498 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1499 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1500 | # Check for guested configure. |
| 1501 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1502 | echo && |
| 1503 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1504 | elif test -f "$ac_srcdir/configure"; then |
| 1505 | echo && |
| 1506 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1507 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1508 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1509 | fi || ac_status=$? |
| 1510 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1511 | done |
| 1512 | fi |
| 1513 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1514 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1515 | if $ac_init_version; then |
| 1516 | cat <<\_ACEOF |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1517 | python configure 2.7 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1518 | generated by GNU Autoconf 2.68 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1519 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1520 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1521 | This configure script is free software; the Free Software Foundation |
| 1522 | gives unlimited permission to copy, distribute and modify it. |
| 1523 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1524 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1525 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1526 | |
| 1527 | ## ------------------------ ## |
| 1528 | ## Autoconf initialization. ## |
| 1529 | ## ------------------------ ## |
| 1530 | |
| 1531 | # ac_fn_c_try_compile LINENO |
| 1532 | # -------------------------- |
| 1533 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1534 | ac_fn_c_try_compile () |
| 1535 | { |
| 1536 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1537 | rm -f conftest.$ac_objext |
| 1538 | if { { ac_try="$ac_compile" |
| 1539 | case "(($ac_try" in |
| 1540 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1541 | *) ac_try_echo=$ac_try;; |
| 1542 | esac |
| 1543 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1544 | $as_echo "$ac_try_echo"; } >&5 |
| 1545 | (eval "$ac_compile") 2>conftest.err |
| 1546 | ac_status=$? |
| 1547 | if test -s conftest.err; then |
| 1548 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1549 | cat conftest.er1 >&5 |
| 1550 | mv -f conftest.er1 conftest.err |
| 1551 | fi |
| 1552 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1553 | test $ac_status = 0; } && { |
| 1554 | test -z "$ac_c_werror_flag" || |
| 1555 | test ! -s conftest.err |
| 1556 | } && test -s conftest.$ac_objext; then : |
| 1557 | ac_retval=0 |
| 1558 | else |
| 1559 | $as_echo "$as_me: failed program was:" >&5 |
| 1560 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1561 | |
| 1562 | ac_retval=1 |
| 1563 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1564 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1565 | as_fn_set_status $ac_retval |
| 1566 | |
| 1567 | } # ac_fn_c_try_compile |
| 1568 | |
| 1569 | # ac_fn_c_try_cpp LINENO |
| 1570 | # ---------------------- |
| 1571 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1572 | ac_fn_c_try_cpp () |
| 1573 | { |
| 1574 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1575 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1576 | case "(($ac_try" in |
| 1577 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1578 | *) ac_try_echo=$ac_try;; |
| 1579 | esac |
| 1580 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1581 | $as_echo "$ac_try_echo"; } >&5 |
| 1582 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1583 | ac_status=$? |
| 1584 | if test -s conftest.err; then |
| 1585 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1586 | cat conftest.er1 >&5 |
| 1587 | mv -f conftest.er1 conftest.err |
| 1588 | fi |
| 1589 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1590 | test $ac_status = 0; } > conftest.i && { |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1591 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1592 | test ! -s conftest.err |
| 1593 | }; then : |
| 1594 | ac_retval=0 |
| 1595 | else |
| 1596 | $as_echo "$as_me: failed program was:" >&5 |
| 1597 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1598 | |
| 1599 | ac_retval=1 |
| 1600 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1601 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1602 | as_fn_set_status $ac_retval |
| 1603 | |
| 1604 | } # ac_fn_c_try_cpp |
| 1605 | |
| 1606 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1607 | # ------------------------------------------------------- |
| 1608 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1609 | # the include files in INCLUDES and setting the cache variable VAR |
| 1610 | # accordingly. |
| 1611 | ac_fn_c_check_header_mongrel () |
| 1612 | { |
| 1613 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1614 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1615 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1616 | $as_echo_n "checking for $2... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1617 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1618 | $as_echo_n "(cached) " >&6 |
| 1619 | fi |
| 1620 | eval ac_res=\$$3 |
| 1621 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1622 | $as_echo "$ac_res" >&6; } |
| 1623 | else |
| 1624 | # Is the header compilable? |
| 1625 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1626 | $as_echo_n "checking $2 usability... " >&6; } |
| 1627 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1628 | /* end confdefs.h. */ |
| 1629 | $4 |
| 1630 | #include <$2> |
| 1631 | _ACEOF |
| 1632 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1633 | ac_header_compiler=yes |
| 1634 | else |
| 1635 | ac_header_compiler=no |
| 1636 | fi |
| 1637 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1638 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1639 | $as_echo "$ac_header_compiler" >&6; } |
| 1640 | |
| 1641 | # Is the header present? |
| 1642 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1643 | $as_echo_n "checking $2 presence... " >&6; } |
| 1644 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1645 | /* end confdefs.h. */ |
| 1646 | #include <$2> |
| 1647 | _ACEOF |
| 1648 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1649 | ac_header_preproc=yes |
| 1650 | else |
| 1651 | ac_header_preproc=no |
| 1652 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1653 | rm -f conftest.err conftest.i conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1654 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1655 | $as_echo "$ac_header_preproc" >&6; } |
| 1656 | |
| 1657 | # So? What about this header? |
| 1658 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1659 | yes:no: ) |
| 1660 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1661 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1662 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1663 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1664 | ;; |
| 1665 | no:yes:* ) |
| 1666 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1667 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1668 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1669 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1670 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1671 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1672 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1673 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1674 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1675 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1676 | ( $as_echo "## -------------------------------------- ## |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1677 | ## Report this to http://bugs.python.org/ ## |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1678 | ## -------------------------------------- ##" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1679 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1680 | ;; |
| 1681 | esac |
| 1682 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1683 | $as_echo_n "checking for $2... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1684 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1685 | $as_echo_n "(cached) " >&6 |
| 1686 | else |
| 1687 | eval "$3=\$ac_header_compiler" |
| 1688 | fi |
| 1689 | eval ac_res=\$$3 |
| 1690 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1691 | $as_echo "$ac_res" >&6; } |
| 1692 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1693 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1694 | |
| 1695 | } # ac_fn_c_check_header_mongrel |
| 1696 | |
| 1697 | # ac_fn_c_try_run LINENO |
| 1698 | # ---------------------- |
| 1699 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1700 | # that executables *can* be run. |
| 1701 | ac_fn_c_try_run () |
| 1702 | { |
| 1703 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1704 | if { { ac_try="$ac_link" |
| 1705 | case "(($ac_try" in |
| 1706 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1707 | *) ac_try_echo=$ac_try;; |
| 1708 | esac |
| 1709 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1710 | $as_echo "$ac_try_echo"; } >&5 |
| 1711 | (eval "$ac_link") 2>&5 |
| 1712 | ac_status=$? |
| 1713 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1714 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1715 | { { case "(($ac_try" in |
| 1716 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1717 | *) ac_try_echo=$ac_try;; |
| 1718 | esac |
| 1719 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1720 | $as_echo "$ac_try_echo"; } >&5 |
| 1721 | (eval "$ac_try") 2>&5 |
| 1722 | ac_status=$? |
| 1723 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1724 | test $ac_status = 0; }; }; then : |
| 1725 | ac_retval=0 |
| 1726 | else |
| 1727 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1728 | $as_echo "$as_me: failed program was:" >&5 |
| 1729 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1730 | |
| 1731 | ac_retval=$ac_status |
| 1732 | fi |
| 1733 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1734 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1735 | as_fn_set_status $ac_retval |
| 1736 | |
| 1737 | } # ac_fn_c_try_run |
| 1738 | |
| 1739 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1740 | # ------------------------------------------------------- |
| 1741 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1742 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1743 | ac_fn_c_check_header_compile () |
| 1744 | { |
| 1745 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1747 | $as_echo_n "checking for $2... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1748 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1749 | $as_echo_n "(cached) " >&6 |
| 1750 | else |
| 1751 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1752 | /* end confdefs.h. */ |
| 1753 | $4 |
| 1754 | #include <$2> |
| 1755 | _ACEOF |
| 1756 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1757 | eval "$3=yes" |
| 1758 | else |
| 1759 | eval "$3=no" |
| 1760 | fi |
| 1761 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1762 | fi |
| 1763 | eval ac_res=\$$3 |
| 1764 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1765 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1766 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1767 | |
| 1768 | } # ac_fn_c_check_header_compile |
| 1769 | |
| 1770 | # ac_fn_c_try_link LINENO |
| 1771 | # ----------------------- |
| 1772 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1773 | ac_fn_c_try_link () |
| 1774 | { |
| 1775 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1776 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1777 | if { { ac_try="$ac_link" |
| 1778 | case "(($ac_try" in |
| 1779 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1780 | *) ac_try_echo=$ac_try;; |
| 1781 | esac |
| 1782 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1783 | $as_echo "$ac_try_echo"; } >&5 |
| 1784 | (eval "$ac_link") 2>conftest.err |
| 1785 | ac_status=$? |
| 1786 | if test -s conftest.err; then |
| 1787 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1788 | cat conftest.er1 >&5 |
| 1789 | mv -f conftest.er1 conftest.err |
| 1790 | fi |
| 1791 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1792 | test $ac_status = 0; } && { |
| 1793 | test -z "$ac_c_werror_flag" || |
| 1794 | test ! -s conftest.err |
| 1795 | } && test -s conftest$ac_exeext && { |
| 1796 | test "$cross_compiling" = yes || |
| 1797 | $as_test_x conftest$ac_exeext |
| 1798 | }; then : |
| 1799 | ac_retval=0 |
| 1800 | else |
| 1801 | $as_echo "$as_me: failed program was:" >&5 |
| 1802 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1803 | |
| 1804 | ac_retval=1 |
| 1805 | fi |
| 1806 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1807 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1808 | # interfere with the next link command; also delete a directory that is |
| 1809 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1810 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1811 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1812 | as_fn_set_status $ac_retval |
| 1813 | |
| 1814 | } # ac_fn_c_try_link |
| 1815 | |
| 1816 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1817 | # ------------------------------------------- |
| 1818 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1819 | # variable VAR accordingly. |
| 1820 | ac_fn_c_check_type () |
| 1821 | { |
| 1822 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1823 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1824 | $as_echo_n "checking for $2... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1825 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1826 | $as_echo_n "(cached) " >&6 |
| 1827 | else |
| 1828 | eval "$3=no" |
| 1829 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1830 | /* end confdefs.h. */ |
| 1831 | $4 |
| 1832 | int |
| 1833 | main () |
| 1834 | { |
| 1835 | if (sizeof ($2)) |
| 1836 | return 0; |
| 1837 | ; |
| 1838 | return 0; |
| 1839 | } |
| 1840 | _ACEOF |
| 1841 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1842 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1843 | /* end confdefs.h. */ |
| 1844 | $4 |
| 1845 | int |
| 1846 | main () |
| 1847 | { |
| 1848 | if (sizeof (($2))) |
| 1849 | return 0; |
| 1850 | ; |
| 1851 | return 0; |
| 1852 | } |
| 1853 | _ACEOF |
| 1854 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1855 | |
| 1856 | else |
| 1857 | eval "$3=yes" |
| 1858 | fi |
| 1859 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1860 | fi |
| 1861 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1862 | fi |
| 1863 | eval ac_res=\$$3 |
| 1864 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1865 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1866 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1867 | |
| 1868 | } # ac_fn_c_check_type |
| 1869 | |
| 1870 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1871 | # ------------------------------------ |
| 1872 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1873 | # accordingly. |
| 1874 | ac_fn_c_find_uintX_t () |
| 1875 | { |
| 1876 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1877 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1878 | $as_echo_n "checking for uint$2_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1879 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1880 | $as_echo_n "(cached) " >&6 |
| 1881 | else |
| 1882 | eval "$3=no" |
| 1883 | # Order is important - never check a type that is potentially smaller |
| 1884 | # than half of the expected target width. |
| 1885 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1886 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1887 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1888 | /* end confdefs.h. */ |
| 1889 | $ac_includes_default |
| 1890 | int |
| 1891 | main () |
| 1892 | { |
| 1893 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
| 1894 | test_array [0] = 0 |
| 1895 | |
| 1896 | ; |
| 1897 | return 0; |
| 1898 | } |
| 1899 | _ACEOF |
| 1900 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1901 | case $ac_type in #( |
| 1902 | uint$2_t) : |
| 1903 | eval "$3=yes" ;; #( |
| 1904 | *) : |
| 1905 | eval "$3=\$ac_type" ;; |
| 1906 | esac |
| 1907 | fi |
| 1908 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1909 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1910 | |
| 1911 | else |
| 1912 | break |
| 1913 | fi |
| 1914 | done |
| 1915 | fi |
| 1916 | eval ac_res=\$$3 |
| 1917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1918 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1919 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1920 | |
| 1921 | } # ac_fn_c_find_uintX_t |
| 1922 | |
| 1923 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 1924 | # ----------------------------------- |
| 1925 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 1926 | # accordingly. |
| 1927 | ac_fn_c_find_intX_t () |
| 1928 | { |
| 1929 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1930 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 1931 | $as_echo_n "checking for int$2_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1932 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1933 | $as_echo_n "(cached) " >&6 |
| 1934 | else |
| 1935 | eval "$3=no" |
| 1936 | # Order is important - never check a type that is potentially smaller |
| 1937 | # than half of the expected target width. |
| 1938 | for ac_type in int$2_t 'int' 'long int' \ |
| 1939 | 'long long int' 'short int' 'signed char'; do |
| 1940 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1941 | /* end confdefs.h. */ |
| 1942 | $ac_includes_default |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1943 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1944 | int |
| 1945 | main () |
| 1946 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1947 | static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1948 | test_array [0] = 0 |
| 1949 | |
| 1950 | ; |
| 1951 | return 0; |
| 1952 | } |
| 1953 | _ACEOF |
| 1954 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1955 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1956 | /* end confdefs.h. */ |
| 1957 | $ac_includes_default |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1958 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1959 | int |
| 1960 | main () |
| 1961 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1962 | static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1963 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
| 1964 | test_array [0] = 0 |
| 1965 | |
| 1966 | ; |
| 1967 | return 0; |
| 1968 | } |
| 1969 | _ACEOF |
| 1970 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1971 | |
| 1972 | else |
| 1973 | case $ac_type in #( |
| 1974 | int$2_t) : |
| 1975 | eval "$3=yes" ;; #( |
| 1976 | *) : |
| 1977 | eval "$3=\$ac_type" ;; |
| 1978 | esac |
| 1979 | fi |
| 1980 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1981 | fi |
| 1982 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1983 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1984 | |
| 1985 | else |
| 1986 | break |
| 1987 | fi |
| 1988 | done |
| 1989 | fi |
| 1990 | eval ac_res=\$$3 |
| 1991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1992 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 1993 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1994 | |
| 1995 | } # ac_fn_c_find_intX_t |
| 1996 | |
| 1997 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 1998 | # -------------------------------------------- |
| 1999 | # Tries to find the compile-time value of EXPR in a program that includes |
| 2000 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 2001 | # computed |
| 2002 | ac_fn_c_compute_int () |
| 2003 | { |
| 2004 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2005 | if test "$cross_compiling" = yes; then |
| 2006 | # Depending upon the size, compute the lo and hi bounds. |
| 2007 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2008 | /* end confdefs.h. */ |
| 2009 | $4 |
| 2010 | int |
| 2011 | main () |
| 2012 | { |
| 2013 | static int test_array [1 - 2 * !(($2) >= 0)]; |
| 2014 | test_array [0] = 0 |
| 2015 | |
| 2016 | ; |
| 2017 | return 0; |
| 2018 | } |
| 2019 | _ACEOF |
| 2020 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2021 | ac_lo=0 ac_mid=0 |
| 2022 | while :; do |
| 2023 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2024 | /* end confdefs.h. */ |
| 2025 | $4 |
| 2026 | int |
| 2027 | main () |
| 2028 | { |
| 2029 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2030 | test_array [0] = 0 |
| 2031 | |
| 2032 | ; |
| 2033 | return 0; |
| 2034 | } |
| 2035 | _ACEOF |
| 2036 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2037 | ac_hi=$ac_mid; break |
| 2038 | else |
| 2039 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2040 | if test $ac_lo -le $ac_mid; then |
| 2041 | ac_lo= ac_hi= |
| 2042 | break |
| 2043 | fi |
| 2044 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2045 | fi |
| 2046 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2047 | done |
| 2048 | else |
| 2049 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2050 | /* end confdefs.h. */ |
| 2051 | $4 |
| 2052 | int |
| 2053 | main () |
| 2054 | { |
| 2055 | static int test_array [1 - 2 * !(($2) < 0)]; |
| 2056 | test_array [0] = 0 |
| 2057 | |
| 2058 | ; |
| 2059 | return 0; |
| 2060 | } |
| 2061 | _ACEOF |
| 2062 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2063 | ac_hi=-1 ac_mid=-1 |
| 2064 | while :; do |
| 2065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2066 | /* end confdefs.h. */ |
| 2067 | $4 |
| 2068 | int |
| 2069 | main () |
| 2070 | { |
| 2071 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
| 2072 | test_array [0] = 0 |
| 2073 | |
| 2074 | ; |
| 2075 | return 0; |
| 2076 | } |
| 2077 | _ACEOF |
| 2078 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2079 | ac_lo=$ac_mid; break |
| 2080 | else |
| 2081 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2082 | if test $ac_mid -le $ac_hi; then |
| 2083 | ac_lo= ac_hi= |
| 2084 | break |
| 2085 | fi |
| 2086 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2087 | fi |
| 2088 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2089 | done |
| 2090 | else |
| 2091 | ac_lo= ac_hi= |
| 2092 | fi |
| 2093 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2094 | fi |
| 2095 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2096 | # Binary search between lo and hi bounds. |
| 2097 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2098 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2099 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2100 | /* end confdefs.h. */ |
| 2101 | $4 |
| 2102 | int |
| 2103 | main () |
| 2104 | { |
| 2105 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2106 | test_array [0] = 0 |
| 2107 | |
| 2108 | ; |
| 2109 | return 0; |
| 2110 | } |
| 2111 | _ACEOF |
| 2112 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2113 | ac_hi=$ac_mid |
| 2114 | else |
| 2115 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2116 | fi |
| 2117 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2118 | done |
| 2119 | case $ac_lo in #(( |
| 2120 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2121 | '') ac_retval=1 ;; |
| 2122 | esac |
| 2123 | else |
| 2124 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2125 | /* end confdefs.h. */ |
| 2126 | $4 |
| 2127 | static long int longval () { return $2; } |
| 2128 | static unsigned long int ulongval () { return $2; } |
| 2129 | #include <stdio.h> |
| 2130 | #include <stdlib.h> |
| 2131 | int |
| 2132 | main () |
| 2133 | { |
| 2134 | |
| 2135 | FILE *f = fopen ("conftest.val", "w"); |
| 2136 | if (! f) |
| 2137 | return 1; |
| 2138 | if (($2) < 0) |
| 2139 | { |
| 2140 | long int i = longval (); |
| 2141 | if (i != ($2)) |
| 2142 | return 1; |
| 2143 | fprintf (f, "%ld", i); |
| 2144 | } |
| 2145 | else |
| 2146 | { |
| 2147 | unsigned long int i = ulongval (); |
| 2148 | if (i != ($2)) |
| 2149 | return 1; |
| 2150 | fprintf (f, "%lu", i); |
| 2151 | } |
| 2152 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2153 | on some platforms. */ |
| 2154 | return ferror (f) || fclose (f) != 0; |
| 2155 | |
| 2156 | ; |
| 2157 | return 0; |
| 2158 | } |
| 2159 | _ACEOF |
| 2160 | if ac_fn_c_try_run "$LINENO"; then : |
| 2161 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2162 | else |
| 2163 | ac_retval=1 |
| 2164 | fi |
| 2165 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2166 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2167 | rm -f conftest.val |
| 2168 | |
| 2169 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2170 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2171 | as_fn_set_status $ac_retval |
| 2172 | |
| 2173 | } # ac_fn_c_compute_int |
| 2174 | |
| 2175 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2176 | # ---------------------------------- |
| 2177 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2178 | ac_fn_c_check_func () |
| 2179 | { |
| 2180 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2181 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2182 | $as_echo_n "checking for $2... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2183 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2184 | $as_echo_n "(cached) " >&6 |
| 2185 | else |
| 2186 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2187 | /* end confdefs.h. */ |
| 2188 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2189 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2190 | #define $2 innocuous_$2 |
| 2191 | |
| 2192 | /* System header to define __stub macros and hopefully few prototypes, |
| 2193 | which can conflict with char $2 (); below. |
| 2194 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2195 | <limits.h> exists even on freestanding compilers. */ |
| 2196 | |
| 2197 | #ifdef __STDC__ |
| 2198 | # include <limits.h> |
| 2199 | #else |
| 2200 | # include <assert.h> |
| 2201 | #endif |
| 2202 | |
| 2203 | #undef $2 |
| 2204 | |
| 2205 | /* Override any GCC internal prototype to avoid an error. |
| 2206 | Use char because int might match the return type of a GCC |
| 2207 | builtin and then its argument prototype would still apply. */ |
| 2208 | #ifdef __cplusplus |
| 2209 | extern "C" |
| 2210 | #endif |
| 2211 | char $2 (); |
| 2212 | /* The GNU C library defines this for functions which it implements |
| 2213 | to always fail with ENOSYS. Some functions are actually named |
| 2214 | something starting with __ and the normal name is an alias. */ |
| 2215 | #if defined __stub_$2 || defined __stub___$2 |
| 2216 | choke me |
| 2217 | #endif |
| 2218 | |
| 2219 | int |
| 2220 | main () |
| 2221 | { |
| 2222 | return $2 (); |
| 2223 | ; |
| 2224 | return 0; |
| 2225 | } |
| 2226 | _ACEOF |
| 2227 | if ac_fn_c_try_link "$LINENO"; then : |
| 2228 | eval "$3=yes" |
| 2229 | else |
| 2230 | eval "$3=no" |
| 2231 | fi |
| 2232 | rm -f core conftest.err conftest.$ac_objext \ |
| 2233 | conftest$ac_exeext conftest.$ac_ext |
| 2234 | fi |
| 2235 | eval ac_res=\$$3 |
| 2236 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2237 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2238 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2239 | |
| 2240 | } # ac_fn_c_check_func |
| 2241 | |
| 2242 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2243 | # ---------------------------------------------------- |
| 2244 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2245 | # INCLUDES, setting cache variable VAR accordingly. |
| 2246 | ac_fn_c_check_member () |
| 2247 | { |
| 2248 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2250 | $as_echo_n "checking for $2.$3... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2251 | if eval \${$4+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2252 | $as_echo_n "(cached) " >&6 |
| 2253 | else |
| 2254 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2255 | /* end confdefs.h. */ |
| 2256 | $5 |
| 2257 | int |
| 2258 | main () |
| 2259 | { |
| 2260 | static $2 ac_aggr; |
| 2261 | if (ac_aggr.$3) |
| 2262 | return 0; |
| 2263 | ; |
| 2264 | return 0; |
| 2265 | } |
| 2266 | _ACEOF |
| 2267 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2268 | eval "$4=yes" |
| 2269 | else |
| 2270 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2271 | /* end confdefs.h. */ |
| 2272 | $5 |
| 2273 | int |
| 2274 | main () |
| 2275 | { |
| 2276 | static $2 ac_aggr; |
| 2277 | if (sizeof ac_aggr.$3) |
| 2278 | return 0; |
| 2279 | ; |
| 2280 | return 0; |
| 2281 | } |
| 2282 | _ACEOF |
| 2283 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2284 | eval "$4=yes" |
| 2285 | else |
| 2286 | eval "$4=no" |
| 2287 | fi |
| 2288 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2289 | fi |
| 2290 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2291 | fi |
| 2292 | eval ac_res=\$$4 |
| 2293 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2294 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2295 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2296 | |
| 2297 | } # ac_fn_c_check_member |
| 2298 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2299 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
| 2300 | # --------------------------------------------- |
| 2301 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR |
| 2302 | # accordingly. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2303 | ac_fn_c_check_decl () |
| 2304 | { |
| 2305 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2306 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
| 2307 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` |
| 2308 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 |
| 2309 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } |
| 2310 | if eval \${$3+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2311 | $as_echo_n "(cached) " >&6 |
| 2312 | else |
| 2313 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2314 | /* end confdefs.h. */ |
| 2315 | $4 |
| 2316 | int |
| 2317 | main () |
| 2318 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2319 | #ifndef $as_decl_name |
| 2320 | #ifdef __cplusplus |
| 2321 | (void) $as_decl_use; |
| 2322 | #else |
| 2323 | (void) $as_decl_name; |
| 2324 | #endif |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2325 | #endif |
| 2326 | |
| 2327 | ; |
| 2328 | return 0; |
| 2329 | } |
| 2330 | _ACEOF |
| 2331 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2332 | eval "$3=yes" |
| 2333 | else |
| 2334 | eval "$3=no" |
| 2335 | fi |
| 2336 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2337 | fi |
| 2338 | eval ac_res=\$$3 |
| 2339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2340 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2341 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2342 | |
| 2343 | } # ac_fn_c_check_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2344 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2345 | This file contains any messages produced by compilers while |
| 2346 | running configure, to aid debugging if configure makes a mistake. |
| 2347 | |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 2348 | It was created by python $as_me 2.7, which was |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2349 | generated by GNU Autoconf 2.68. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2350 | |
| 2351 | $ $0 $@ |
| 2352 | |
| 2353 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2354 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2355 | { |
| 2356 | cat <<_ASUNAME |
| 2357 | ## --------- ## |
| 2358 | ## Platform. ## |
| 2359 | ## --------- ## |
| 2360 | |
| 2361 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2362 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2363 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2364 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2365 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2366 | |
| 2367 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2368 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2369 | |
| 2370 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2371 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2372 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2373 | /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] | 2374 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2375 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2376 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2377 | |
| 2378 | _ASUNAME |
| 2379 | |
| 2380 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2381 | for as_dir in $PATH |
| 2382 | do |
| 2383 | IFS=$as_save_IFS |
| 2384 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2385 | $as_echo "PATH: $as_dir" |
| 2386 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2387 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2388 | |
| 2389 | } >&5 |
| 2390 | |
| 2391 | cat >&5 <<_ACEOF |
| 2392 | |
| 2393 | |
| 2394 | ## ----------- ## |
| 2395 | ## Core tests. ## |
| 2396 | ## ----------- ## |
| 2397 | |
| 2398 | _ACEOF |
| 2399 | |
| 2400 | |
| 2401 | # Keep a trace of the command line. |
| 2402 | # 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] | 2403 | # 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] | 2404 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2405 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2406 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2407 | ac_configure_args0= |
| 2408 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2409 | ac_must_keep_next=false |
| 2410 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2411 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2412 | for ac_arg |
| 2413 | do |
| 2414 | case $ac_arg in |
| 2415 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2416 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2417 | | -silent | --silent | --silen | --sile | --sil) |
| 2418 | continue ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2419 | *\'*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2420 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2421 | esac |
| 2422 | case $ac_pass in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2423 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2424 | 2) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2425 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2426 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2427 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2428 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2429 | case $ac_arg in |
| 2430 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2431 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2432 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2433 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2434 | case "$ac_configure_args0 " in |
| 2435 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2436 | esac |
| 2437 | ;; |
| 2438 | -* ) ac_must_keep_next=true ;; |
| 2439 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2440 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2441 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2442 | ;; |
| 2443 | esac |
| 2444 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2445 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2446 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2447 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2448 | |
| 2449 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2450 | # config.log. We remove comments because anyway the quotes in there |
| 2451 | # would cause problems or look ugly. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2452 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2453 | # 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] | 2454 | trap 'exit_status=$? |
| 2455 | # Save into config.log some information that might help in debugging. |
| 2456 | { |
| 2457 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2458 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2459 | $as_echo "## ---------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2460 | ## Cache variables. ## |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2461 | ## ---------------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2462 | echo |
| 2463 | # The following way of writing the cache mishandles newlines in values, |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2464 | ( |
| 2465 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2466 | eval ac_val=\$$ac_var |
| 2467 | case $ac_val in #( |
| 2468 | *${as_nl}*) |
| 2469 | case $ac_var in #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2470 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2471 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2472 | esac |
| 2473 | case $ac_var in #( |
| 2474 | _ | IFS | as_nl) ;; #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2475 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2476 | *) { eval $ac_var=; unset $ac_var;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2477 | esac ;; |
| 2478 | esac |
| 2479 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2480 | (set) 2>&1 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2481 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2482 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2483 | sed -n \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2484 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2485 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2486 | ;; #( |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 2487 | *) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2488 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 2489 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2490 | esac | |
| 2491 | sort |
| 2492 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2493 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2494 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2495 | $as_echo "## ----------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2496 | ## Output variables. ## |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2497 | ## ----------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2498 | echo |
| 2499 | for ac_var in $ac_subst_vars |
| 2500 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2501 | eval ac_val=\$$ac_var |
| 2502 | case $ac_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2503 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2504 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2505 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2506 | done | sort |
| 2507 | echo |
| 2508 | |
| 2509 | if test -n "$ac_subst_files"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2510 | $as_echo "## ------------------- ## |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2511 | ## File substitutions. ## |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2512 | ## ------------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2513 | echo |
| 2514 | for ac_var in $ac_subst_files |
| 2515 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2516 | eval ac_val=\$$ac_var |
| 2517 | case $ac_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2518 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2519 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2520 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2521 | done | sort |
| 2522 | echo |
| 2523 | fi |
| 2524 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2525 | if test -s confdefs.h; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2526 | $as_echo "## ----------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2527 | ## confdefs.h. ## |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2528 | ## ----------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2529 | echo |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2530 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2531 | echo |
| 2532 | fi |
| 2533 | test "$ac_signal" != 0 && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2534 | $as_echo "$as_me: caught signal $ac_signal" |
| 2535 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2536 | } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2537 | rm -f core *.core core.conftest.* && |
| 2538 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2539 | exit $exit_status |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2540 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2541 | for ac_signal in 1 2 13 15; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2542 | 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] | 2543 | done |
| 2544 | ac_signal=0 |
| 2545 | |
| 2546 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2547 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2548 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2549 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2550 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2551 | # Predefined preprocessor variables. |
| 2552 | |
| 2553 | cat >>confdefs.h <<_ACEOF |
| 2554 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2555 | _ACEOF |
| 2556 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2557 | cat >>confdefs.h <<_ACEOF |
| 2558 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2559 | _ACEOF |
| 2560 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2561 | cat >>confdefs.h <<_ACEOF |
| 2562 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2563 | _ACEOF |
| 2564 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2565 | cat >>confdefs.h <<_ACEOF |
| 2566 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2567 | _ACEOF |
| 2568 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2569 | cat >>confdefs.h <<_ACEOF |
| 2570 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2571 | _ACEOF |
| 2572 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2573 | cat >>confdefs.h <<_ACEOF |
| 2574 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2575 | _ACEOF |
| 2576 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2577 | |
| 2578 | # Let the site file select an alternate cache file if it wants to. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2579 | # Prefer an explicitly selected file to automatically selected ones. |
| 2580 | ac_site_file1=NONE |
| 2581 | ac_site_file2=NONE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2582 | if test -n "$CONFIG_SITE"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2583 | # We do not want a PATH search for config.site. |
| 2584 | case $CONFIG_SITE in #(( |
| 2585 | -*) ac_site_file1=./$CONFIG_SITE;; |
| 2586 | */*) ac_site_file1=$CONFIG_SITE;; |
| 2587 | *) ac_site_file1=./$CONFIG_SITE;; |
| 2588 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2589 | elif test "x$prefix" != xNONE; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2590 | ac_site_file1=$prefix/share/config.site |
| 2591 | ac_site_file2=$prefix/etc/config.site |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2592 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2593 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2594 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2595 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2596 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2597 | do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2598 | test "x$ac_site_file" = xNONE && continue |
| 2599 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2600 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2601 | $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] | 2602 | sed 's/^/| /' "$ac_site_file" >&5 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2603 | . "$ac_site_file" \ |
| 2604 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2605 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2606 | as_fn_error $? "failed to load site script $ac_site_file |
| 2607 | See \`config.log' for more details" "$LINENO" 5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2608 | fi |
| 2609 | done |
| 2610 | |
| 2611 | if test -r "$cache_file"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2612 | # Some versions of bash will fail to source /dev/null (special files |
| 2613 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2614 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2615 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2616 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2617 | case $cache_file in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2618 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2619 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2620 | esac |
| 2621 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2622 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2623 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2624 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2625 | >$cache_file |
| 2626 | fi |
| 2627 | |
| 2628 | # Check that the precious variables saved in the cache have kept the same |
| 2629 | # value. |
| 2630 | ac_cache_corrupted=false |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2631 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2632 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2633 | eval ac_new_set=\$ac_env_${ac_var}_set |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2634 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2635 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2636 | case $ac_old_set,$ac_new_set in |
| 2637 | set,) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2638 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2639 | $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] | 2640 | ac_cache_corrupted=: ;; |
| 2641 | ,set) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2642 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2643 | $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] | 2644 | ac_cache_corrupted=: ;; |
| 2645 | ,);; |
| 2646 | *) |
| 2647 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2648 | # differences in whitespace do not lead to failure. |
| 2649 | ac_old_val_w=`echo x $ac_old_val` |
| 2650 | ac_new_val_w=`echo x $ac_new_val` |
| 2651 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2652 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2653 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2654 | ac_cache_corrupted=: |
| 2655 | else |
| 2656 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2657 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2658 | eval $ac_var=\$ac_old_val |
| 2659 | fi |
| 2660 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2661 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2662 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2663 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2664 | fi;; |
| 2665 | esac |
| 2666 | # Pass precious variables to config.status. |
| 2667 | if test "$ac_new_set" = set; then |
| 2668 | case $ac_new_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2669 | *\'*) 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] | 2670 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2671 | esac |
| 2672 | case " $ac_configure_args " in |
| 2673 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2674 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2675 | esac |
| 2676 | fi |
| 2677 | done |
| 2678 | if $ac_cache_corrupted; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2679 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2680 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2681 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2682 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2683 | 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] | 2684 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2685 | ## -------------------- ## |
| 2686 | ## Main body of script. ## |
| 2687 | ## -------------------- ## |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2688 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2689 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2690 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2691 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2692 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2693 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2694 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2695 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2696 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2697 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2698 | |
| 2699 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2700 | |
Georg Brandl | bcd64a3 | 2009-03-31 21:45:18 +0000 | [diff] [blame] | 2701 | if test "$prefix" != "/"; then |
| 2702 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2703 | fi |
| 2704 | |
| 2705 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2706 | |
| 2707 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 2708 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 2709 | # with other autoconf-based packages that include Python.h |
| 2710 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 2711 | rm confdefs.h |
| 2712 | mv confdefs.h.new confdefs.h |
| 2713 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 2714 | |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 2715 | VERSION=2.7 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 2716 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 2717 | |
| 2718 | SOVERSION=1.0 |
| 2719 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2720 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 2721 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 2722 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2723 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2724 | |
| 2725 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2726 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2727 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 2728 | # them. |
| 2729 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2730 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2731 | |
| 2732 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2733 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2734 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 2735 | # them. |
| 2736 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2737 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2738 | |
| 2739 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2740 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2741 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 2742 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2743 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2744 | |
| 2745 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2746 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2747 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 2748 | # them. |
| 2749 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2750 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2751 | |
| 2752 | |
| 2753 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2754 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2755 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 2756 | # Arguments passed to configure. |
| 2757 | |
| 2758 | CONFIG_ARGS="$ac_configure_args" |
| 2759 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2760 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 2761 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2762 | # Check whether --enable-universalsdk was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2763 | if test "${enable_universalsdk+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2764 | enableval=$enable_universalsdk; |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2765 | case $enableval in |
| 2766 | yes) |
| 2767 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2768 | if test ! -d "${enableval}" |
| 2769 | then |
| 2770 | enableval=/ |
| 2771 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2772 | ;; |
| 2773 | esac |
| 2774 | case $enableval in |
| 2775 | no) |
| 2776 | UNIVERSALSDK= |
| 2777 | enable_universalsdk= |
| 2778 | ;; |
| 2779 | *) |
| 2780 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2781 | if test ! -d "${UNIVERSALSDK}" |
| 2782 | then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2783 | as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2784 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2785 | ;; |
| 2786 | esac |
| 2787 | |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2788 | |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2789 | else |
| 2790 | |
| 2791 | UNIVERSALSDK= |
| 2792 | enable_universalsdk= |
| 2793 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2794 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2795 | |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2796 | if test -n "${UNIVERSALSDK}" |
| 2797 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 2799 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2800 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2801 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2802 | $as_echo "no" >&6; } |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2803 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2804 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2805 | |
Benjamin Peterson | 0e6ea5d | 2008-07-16 20:17:04 +0000 | [diff] [blame] | 2806 | |
| 2807 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2808 | UNIVERSAL_ARCHS="32-bit" |
Ronald Oussoren | 92919a6 | 2009-12-24 13:30:58 +0000 | [diff] [blame] | 2809 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 2811 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2812 | |
| 2813 | # Check whether --with-universal-archs was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2814 | if test "${with_universal_archs+set}" = set; then : |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2815 | withval=$with_universal_archs; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 2817 | $as_echo "$withval" >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2818 | UNIVERSAL_ARCHS="$withval" |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2819 | if test "${enable_universalsdk}" ; then |
| 2820 | : |
| 2821 | else |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2822 | as_fn_error $? "--with-universal-archs without --enable-universalsdk. See Mac/README" "$LINENO" 5 |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2823 | fi |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2824 | |
| 2825 | else |
| 2826 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2827 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 32-bit" >&5 |
| 2828 | $as_echo "32-bit" >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2829 | |
| 2830 | fi |
| 2831 | |
| 2832 | |
| 2833 | |
| 2834 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2835 | |
| 2836 | # Check whether --with-framework-name was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2837 | if test "${with_framework_name+set}" = set; then : |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2838 | withval=$with_framework_name; |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2839 | if test "${enable_framework}"; then |
| 2840 | : |
| 2841 | else |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 2842 | as_fn_error $? "--with-framework-name without --enable-framework. See Mac/README" "$LINENO" 5 |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2843 | fi |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2844 | PYTHONFRAMEWORK=${withval} |
| 2845 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 2846 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 2847 | |
| 2848 | else |
| 2849 | |
| 2850 | PYTHONFRAMEWORK=Python |
| 2851 | PYTHONFRAMEWORKDIR=Python.framework |
| 2852 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 2853 | |
| 2854 | fi |
| 2855 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2856 | # Check whether --enable-framework was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2857 | if test "${enable_framework+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2858 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2859 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2860 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2861 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2862 | esac |
| 2863 | case $enableval in |
| 2864 | no) |
| 2865 | PYTHONFRAMEWORK= |
| 2866 | PYTHONFRAMEWORKDIR=no-framework |
| 2867 | PYTHONFRAMEWORKPREFIX= |
| 2868 | PYTHONFRAMEWORKINSTALLDIR= |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2869 | FRAMEWORKINSTALLFIRST= |
| 2870 | FRAMEWORKINSTALLLAST= |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2871 | FRAMEWORKALTINSTALLFIRST= |
| 2872 | FRAMEWORKALTINSTALLLAST= |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2873 | if test "x${prefix}" = "xNONE"; then |
| 2874 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2875 | else |
| 2876 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2877 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2878 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2879 | ;; |
| 2880 | *) |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2881 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2882 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2883 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2884 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure bininstall maninstall" |
Ronald Oussoren | 92919a6 | 2009-12-24 13:30:58 +0000 | [diff] [blame] | 2885 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 2886 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2887 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2888 | |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2889 | if test "x${prefix}" = "xNONE" ; then |
| 2890 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2891 | |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2892 | else |
| 2893 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2894 | fi |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2895 | |
| 2896 | case "${enableval}" in |
| 2897 | /System*) |
| 2898 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2899 | if test "${prefix}" = "NONE" ; then |
| 2900 | # See below |
| 2901 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 2902 | fi |
| 2903 | ;; |
| 2904 | |
| 2905 | /Library*) |
| 2906 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2907 | ;; |
| 2908 | |
| 2909 | */Library/Frameworks) |
| 2910 | MDIR="`dirname "${enableval}"`" |
| 2911 | MDIR="`dirname "${MDIR}"`" |
| 2912 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 2913 | |
| 2914 | if test "${prefix}" = "NONE"; then |
| 2915 | # User hasn't specified the |
| 2916 | # --prefix option, but wants to install |
| 2917 | # the framework in a non-default location, |
| 2918 | # ensure that the compatibility links get |
| 2919 | # installed relative to that prefix as well |
| 2920 | # instead of in /usr/local. |
| 2921 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 2922 | fi |
| 2923 | ;; |
| 2924 | |
| 2925 | *) |
| 2926 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2927 | ;; |
| 2928 | esac |
| 2929 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2930 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2931 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2932 | # Add files for Mac specific code to the list of output |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2933 | # files: |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2934 | ac_config_files="$ac_config_files Mac/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2935 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2936 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2937 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2938 | ac_config_files="$ac_config_files Mac/IDLE/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2939 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2940 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 2941 | |
| 2942 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 2943 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2944 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2945 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2946 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2947 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2948 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2949 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2950 | PYTHONFRAMEWORKPREFIX= |
| 2951 | PYTHONFRAMEWORKINSTALLDIR= |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2952 | FRAMEWORKINSTALLFIRST= |
| 2953 | FRAMEWORKINSTALLLAST= |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2954 | FRAMEWORKALTINSTALLFIRST= |
| 2955 | FRAMEWORKALTINSTALLLAST= |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2956 | if test "x${prefix}" = "xNONE" ; then |
| 2957 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2958 | else |
| 2959 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2960 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2961 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2962 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2963 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2964 | fi |
| 2965 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2966 | |
| 2967 | |
| 2968 | |
| 2969 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2970 | |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2971 | |
| 2972 | |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2973 | |
| 2974 | |
| 2975 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2976 | |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2977 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2978 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 22520ea | 2010-05-08 10:14:46 +0000 | [diff] [blame] | 2979 | ## AS_HELP_STRING([--with-dyld], |
| 2980 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2981 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2982 | # Set name for machine-dependent library files |
| 2983 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2984 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 2985 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2986 | if test -z "$MACHDEP" |
| 2987 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2988 | ac_sys_system=`uname -s` |
Georg Brandl | fe18a11 | 2009-09-04 07:55:14 +0000 | [diff] [blame] | 2989 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 2990 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2991 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2992 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2993 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2994 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2995 | ac_md_system=`echo $ac_sys_system | |
| 2996 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 2997 | ac_md_release=`echo $ac_sys_release | |
Guido van Rossum | 67b2659 | 2001-10-20 14:21:45 +0000 | [diff] [blame] | 2998 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2999 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3000 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 3001 | case $MACHDEP in |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 3002 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 3003 | darwin*) MACHDEP="darwin";; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 3004 | atheos*) MACHDEP="atheos";; |
Martin v. Löwis | f332228 | 2003-07-13 09:46:13 +0000 | [diff] [blame] | 3005 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 3006 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3007 | esac |
| 3008 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3009 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3010 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 3011 | # disable features if it is defined, without any means to access these |
| 3012 | # features as extensions. For these systems, we skip the definition of |
| 3013 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 3014 | # some feature, make sure there is no alternative way to access this |
| 3015 | # feature. Also, when using wildcards, make sure you have verified the |
| 3016 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 3017 | # wildcard, and that the wildcard does not include future systems |
| 3018 | # (which may remove their limitations). |
| 3019 | case $ac_sys_system/$ac_sys_release in |
| 3020 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 3021 | # 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] | 3022 | # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish. |
Martin v. Löwis | 7875ef6 | 2010-02-15 21:41:12 +0000 | [diff] [blame] | 3023 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 3024 | # OpenBSD 4.6, but is fixed in 4.7. |
| 3025 | OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123456]) |
Martin v. Löwis | cb78de6 | 2007-12-29 18:49:21 +0000 | [diff] [blame] | 3026 | define_xopen_source=no |
| 3027 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3028 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3029 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3030 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3031 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | cb78de6 | 2007-12-29 18:49:21 +0000 | [diff] [blame] | 3032 | |
| 3033 | ;; |
Martin v. Löwis | 7875ef6 | 2010-02-15 21:41:12 +0000 | [diff] [blame] | 3034 | OpenBSD/4.[789]) |
Martin v. Löwis | 5e2dd86 | 2010-02-15 08:32:00 +0000 | [diff] [blame] | 3035 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3036 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3037 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3038 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3039 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 5e2dd86 | 2010-02-15 08:32:00 +0000 | [diff] [blame] | 3040 | |
| 3041 | ;; |
Martin v. Löwis | 4d542ec | 2006-11-25 15:39:19 +0000 | [diff] [blame] | 3042 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3043 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3044 | # Marc Recht |
Benjamin Peterson | eac68f4 | 2008-11-16 17:54:55 +0000 | [diff] [blame] | 3045 | NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S]) |
Martin v. Löwis | 4d542ec | 2006-11-25 15:39:19 +0000 | [diff] [blame] | 3046 | define_xopen_source=no;; |
Martin v. Löwis | b41afb5 | 2010-05-28 15:28:47 +0000 | [diff] [blame] | 3047 | # From the perspective of Solaris, _XOPEN_SOURCE is not so much a |
| 3048 | # request to enable features supported by the standard as a request |
| 3049 | # to disable features not supported by the standard. The best way |
| 3050 | # for Python to use Solaris is simply to leave _XOPEN_SOURCE out |
| 3051 | # entirely and define __EXTENSIONS__ instead. |
| 3052 | SunOS/*) |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3053 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3054 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3055 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3056 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3057 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3058 | define_xopen_source=no;; |
| 3059 | # 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] | 3060 | # 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] | 3061 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3062 | define_xopen_source=no;; |
Martin v. Löwis | bb86d83 | 2008-11-04 20:40:09 +0000 | [diff] [blame] | 3063 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3064 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3065 | FreeBSD/4.*) |
| 3066 | define_xopen_source=no;; |
| 3067 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3068 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3069 | # identifies itself as Darwin/7.* |
| 3070 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3071 | # disables platform specific features beyond repair. |
| 3072 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3073 | # has no effect, don't bother defining them |
| 3074 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3075 | define_xopen_source=no;; |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 3076 | Darwin/1[0-9].*) |
| 3077 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3078 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3079 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3080 | # 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] | 3081 | AIX/4) |
| 3082 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3083 | AIX/5) |
| 3084 | if test `uname -r` -eq 1; then |
| 3085 | define_xopen_source=no |
| 3086 | fi |
| 3087 | ;; |
Martin v. Löwis | 8c255e4 | 2008-05-23 15:06:50 +0000 | [diff] [blame] | 3088 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3089 | # defining NI_NUMERICHOST. |
| 3090 | QNX/6.3.2) |
| 3091 | define_xopen_source=no |
| 3092 | ;; |
Martin v. Löwis | a058836 | 2006-04-04 06:03:50 +0000 | [diff] [blame] | 3093 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3094 | esac |
| 3095 | |
| 3096 | if test $define_xopen_source = yes |
| 3097 | then |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3098 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3099 | $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3100 | |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3101 | |
| 3102 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3103 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3104 | # several APIs are not declared. Since this is also needed in some |
| 3105 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3106 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3107 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3108 | |
| 3109 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3110 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3111 | $as_echo "#define _POSIX_C_SOURCE 200112L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3112 | |
| 3113 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3114 | fi |
| 3115 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3116 | # |
| 3117 | # SGI compilers allow the specification of the both the ABI and the |
| 3118 | # ISA on the command line. Depending on the values of these switches, |
| 3119 | # different and often incompatable code will be generated. |
| 3120 | # |
| 3121 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3122 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3123 | # variable is also adjusted. |
| 3124 | # |
| 3125 | |
| 3126 | if test ! -z "$SGI_ABI" |
| 3127 | then |
| 3128 | CC="cc $SGI_ABI" |
| 3129 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3130 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3131 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3132 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3133 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3134 | |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3135 | # And add extra plat-mac for darwin |
| 3136 | |
Jack Jansen | 7b59b42 | 2003-03-17 15:44:10 +0000 | [diff] [blame] | 3137 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3138 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking EXTRAPLATDIR" >&5 |
| 3139 | $as_echo_n "checking EXTRAPLATDIR... " >&6; } |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3140 | if test -z "$EXTRAPLATDIR" |
| 3141 | then |
| 3142 | case $MACHDEP in |
Jack Jansen | 7b59b42 | 2003-03-17 15:44:10 +0000 | [diff] [blame] | 3143 | darwin) |
| 3144 | EXTRAPLATDIR="\$(PLATMACDIRS)" |
| 3145 | EXTRAMACHDEPPATH="\$(PLATMACPATH)" |
| 3146 | ;; |
| 3147 | *) |
| 3148 | EXTRAPLATDIR="" |
| 3149 | EXTRAMACHDEPPATH="" |
| 3150 | ;; |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3151 | esac |
| 3152 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3153 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRAPLATDIR" >&5 |
| 3154 | $as_echo "$EXTRAPLATDIR" >&6; } |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3155 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3156 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3157 | # it may influence the way we can build extensions, so distutils |
| 3158 | # needs to check it |
| 3159 | |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 3160 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3161 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 3162 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3163 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3164 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking machine type as reported by uname -m" >&5 |
| 3165 | $as_echo_n "checking machine type as reported by uname -m... " >&6; } |
Mark Dickinson | 6513466 | 2008-04-25 16:11:04 +0000 | [diff] [blame] | 3166 | ac_sys_machine=`uname -m` |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3167 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_sys_machine" >&5 |
| 3168 | $as_echo "$ac_sys_machine" >&6; } |
Mark Dickinson | 6513466 | 2008-04-25 16:11:04 +0000 | [diff] [blame] | 3169 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3170 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3171 | |
| 3172 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3173 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3174 | # just to get things to compile and link. Users are free to override OPT |
| 3175 | # when running configure or make. The build should not break if they do. |
| 3176 | # BASECFLAGS should generally not be messed with, however. |
| 3177 | |
| 3178 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3179 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3180 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3181 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3182 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3183 | # Check whether --with-gcc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3184 | if test "${with_gcc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3185 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3186 | case $withval in |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 3187 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3188 | without_gcc=yes;; |
| 3189 | yes) CC=gcc |
| 3190 | without_gcc=no;; |
| 3191 | *) CC=$withval |
| 3192 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3193 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3194 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3195 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3196 | case $ac_sys_system in |
Antoine Pitrou | 285cd16 | 2010-09-21 15:23:17 +0000 | [diff] [blame] | 3197 | AIX*) CC=${CC:-xlc_r} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3198 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3199 | BeOS*) |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3200 | case $BE_HOST_CPU in |
| 3201 | ppc) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 3202 | CC=mwcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3203 | without_gcc=yes |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3204 | BASECFLAGS="$BASECFLAGS -export pragma" |
| 3205 | OPT="$OPT -O" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3206 | LDFLAGS="$LDFLAGS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3207 | ;; |
| 3208 | x86) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 3209 | CC=gcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3210 | without_gcc=no |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3211 | OPT="$OPT -O" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3212 | ;; |
| 3213 | *) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3214 | as_fn_error $? "Unknown BeOS platform \"$BE_HOST_CPU\"" "$LINENO" 5 |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3215 | ;; |
| 3216 | esac |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3217 | AR="\$(srcdir)/Modules/ar_beos" |
| 3218 | RANLIB=: |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3219 | ;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3220 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3221 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3222 | fi |
| 3223 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3224 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3225 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3226 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3227 | # If the user switches compilers, we can't believe the cache |
| 3228 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3229 | then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3230 | as_fn_error $? "cached CC is different -- throw away $cache_file |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3231 | (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] | 3232 | fi |
| 3233 | |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 3234 | # If the user set CFLAGS, use this instead of the automatically |
| 3235 | # determined setting |
| 3236 | preset_cflags="$CFLAGS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3237 | ac_ext=c |
| 3238 | ac_cpp='$CPP $CPPFLAGS' |
| 3239 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3240 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3241 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3242 | if test -n "$ac_tool_prefix"; then |
| 3243 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3244 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3246 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3247 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3248 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3249 | else |
| 3250 | if test -n "$CC"; then |
| 3251 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3252 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3253 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3254 | for as_dir in $PATH |
| 3255 | do |
| 3256 | IFS=$as_save_IFS |
| 3257 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3258 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3259 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3260 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3261 | $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] | 3262 | break 2 |
| 3263 | fi |
| 3264 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3265 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3266 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3267 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3268 | fi |
| 3269 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3270 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3271 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3273 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3274 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3275 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3276 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3277 | fi |
| 3278 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3279 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3280 | fi |
| 3281 | if test -z "$ac_cv_prog_CC"; then |
| 3282 | ac_ct_CC=$CC |
| 3283 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3284 | set dummy gcc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3285 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3286 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3287 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3288 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3289 | else |
| 3290 | if test -n "$ac_ct_CC"; then |
| 3291 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3292 | else |
| 3293 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3294 | for as_dir in $PATH |
| 3295 | do |
| 3296 | IFS=$as_save_IFS |
| 3297 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3298 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3299 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3300 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3301 | $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] | 3302 | break 2 |
| 3303 | fi |
| 3304 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3305 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3306 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3307 | |
| 3308 | fi |
| 3309 | fi |
| 3310 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3311 | if test -n "$ac_ct_CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3313 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3314 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3315 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3316 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3317 | fi |
| 3318 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3319 | if test "x$ac_ct_CC" = x; then |
| 3320 | CC="" |
| 3321 | else |
| 3322 | case $cross_compiling:$ac_tool_warned in |
| 3323 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3324 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3325 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3326 | ac_tool_warned=yes ;; |
| 3327 | esac |
| 3328 | CC=$ac_ct_CC |
| 3329 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3330 | else |
| 3331 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3332 | fi |
| 3333 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3334 | if test -z "$CC"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3335 | if test -n "$ac_tool_prefix"; then |
| 3336 | # 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] | 3337 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3339 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3340 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3341 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3342 | else |
| 3343 | if test -n "$CC"; then |
| 3344 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3345 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3346 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3347 | for as_dir in $PATH |
| 3348 | do |
| 3349 | IFS=$as_save_IFS |
| 3350 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3351 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3352 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3353 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3354 | $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] | 3355 | break 2 |
| 3356 | fi |
| 3357 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3358 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3359 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3360 | |
| 3361 | fi |
| 3362 | fi |
| 3363 | CC=$ac_cv_prog_CC |
| 3364 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3365 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3366 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3367 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3368 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3369 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3370 | fi |
| 3371 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3372 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3373 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3374 | fi |
| 3375 | if test -z "$CC"; then |
| 3376 | # Extract the first word of "cc", so it can be a program name with args. |
| 3377 | set dummy cc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3378 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3379 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3380 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3381 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3382 | else |
| 3383 | if test -n "$CC"; then |
| 3384 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3385 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3386 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3387 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3388 | for as_dir in $PATH |
| 3389 | do |
| 3390 | IFS=$as_save_IFS |
| 3391 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3392 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3393 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3394 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3395 | ac_prog_rejected=yes |
| 3396 | continue |
| 3397 | fi |
| 3398 | ac_cv_prog_CC="cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3399 | $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] | 3400 | break 2 |
| 3401 | fi |
| 3402 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3403 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3404 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3405 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3406 | if test $ac_prog_rejected = yes; then |
| 3407 | # We found a bogon in the path, so make sure we never use it. |
| 3408 | set dummy $ac_cv_prog_CC |
| 3409 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3410 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3411 | # We chose a different compiler from the bogus one. |
| 3412 | # However, it has the same basename, so the bogon will be chosen |
| 3413 | # first if we set CC to just the basename; use the full file name. |
| 3414 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3415 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3416 | fi |
| 3417 | fi |
| 3418 | fi |
| 3419 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3420 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3421 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3422 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3423 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3424 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3426 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3427 | fi |
| 3428 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3429 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3430 | fi |
| 3431 | if test -z "$CC"; then |
| 3432 | if test -n "$ac_tool_prefix"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3433 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3434 | do |
| 3435 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3436 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3437 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3438 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3439 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3440 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3441 | else |
| 3442 | if test -n "$CC"; then |
| 3443 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3444 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3445 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3446 | for as_dir in $PATH |
| 3447 | do |
| 3448 | IFS=$as_save_IFS |
| 3449 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3450 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3451 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3452 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3453 | $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] | 3454 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3455 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3456 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3457 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3458 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3459 | |
| 3460 | fi |
| 3461 | fi |
| 3462 | CC=$ac_cv_prog_CC |
| 3463 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3465 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3466 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3468 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3469 | fi |
| 3470 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3471 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3472 | test -n "$CC" && break |
| 3473 | done |
| 3474 | fi |
| 3475 | if test -z "$CC"; then |
| 3476 | ac_ct_CC=$CC |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3477 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3478 | do |
| 3479 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3480 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3481 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3482 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3483 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3484 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3485 | else |
| 3486 | if test -n "$ac_ct_CC"; then |
| 3487 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3488 | else |
| 3489 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3490 | for as_dir in $PATH |
| 3491 | do |
| 3492 | IFS=$as_save_IFS |
| 3493 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3494 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3495 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3496 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3497 | $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] | 3498 | break 2 |
| 3499 | fi |
| 3500 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3501 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3502 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3503 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3504 | fi |
| 3505 | fi |
| 3506 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3507 | if test -n "$ac_ct_CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3508 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3509 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3510 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3511 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3512 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3513 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3514 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3515 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3516 | test -n "$ac_ct_CC" && break |
| 3517 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3518 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3519 | if test "x$ac_ct_CC" = x; then |
| 3520 | CC="" |
| 3521 | else |
| 3522 | case $cross_compiling:$ac_tool_warned in |
| 3523 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3524 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3525 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3526 | ac_tool_warned=yes ;; |
| 3527 | esac |
| 3528 | CC=$ac_ct_CC |
| 3529 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3530 | fi |
| 3531 | |
| 3532 | fi |
| 3533 | |
| 3534 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3535 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3536 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3537 | as_fn_error $? "no acceptable C compiler found in \$PATH |
| 3538 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3539 | |
| 3540 | # Provide some information about the compiler. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3541 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3542 | set X $ac_compile |
| 3543 | ac_compiler=$2 |
| 3544 | for ac_option in --version -v -V -qversion; do |
| 3545 | { { ac_try="$ac_compiler $ac_option >&5" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3546 | case "(($ac_try" in |
| 3547 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3548 | *) ac_try_echo=$ac_try;; |
| 3549 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3550 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3551 | $as_echo "$ac_try_echo"; } >&5 |
| 3552 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3553 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3554 | if test -s conftest.err; then |
| 3555 | sed '10a\ |
| 3556 | ... rest of stderr output deleted ... |
| 3557 | 10q' conftest.err >conftest.er1 |
| 3558 | cat conftest.er1 >&5 |
| 3559 | fi |
| 3560 | rm -f conftest.er1 conftest.err |
| 3561 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3562 | test $ac_status = 0; } |
| 3563 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3564 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3565 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3566 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3567 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3568 | int |
| 3569 | main () |
| 3570 | { |
| 3571 | |
| 3572 | ; |
| 3573 | return 0; |
| 3574 | } |
| 3575 | _ACEOF |
| 3576 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3577 | 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] | 3578 | # Try to create an executable without -o first, disregard a.out. |
| 3579 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3580 | # of exeext. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3581 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3582 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3583 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3584 | |
| 3585 | # The possible output files: |
| 3586 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3587 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3588 | ac_rmfiles= |
| 3589 | for ac_file in $ac_files |
| 3590 | do |
| 3591 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3592 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3593 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3594 | esac |
| 3595 | done |
| 3596 | rm -f $ac_rmfiles |
| 3597 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3598 | if { { ac_try="$ac_link_default" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3599 | case "(($ac_try" in |
| 3600 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3601 | *) ac_try_echo=$ac_try;; |
| 3602 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3603 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3604 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3605 | (eval "$ac_link_default") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3606 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3607 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3608 | test $ac_status = 0; }; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3609 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3610 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3611 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3612 | # so that the user can short-circuit this test for compilers unknown to |
| 3613 | # Autoconf. |
| 3614 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3615 | do |
| 3616 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3617 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3618 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3619 | ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3620 | [ab].out ) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3621 | # We found the default executable, but exeext='' is most |
| 3622 | # certainly right. |
| 3623 | break;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3624 | *.* ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3625 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3626 | then :; else |
| 3627 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3628 | fi |
| 3629 | # We set ac_cv_exeext here because the later test for it is not |
| 3630 | # safe: cross compilers may not add the suffix if given an `-o' |
| 3631 | # argument, so we may need to know it at that point already. |
| 3632 | # Even if this section looks crufty: it has the advantage of |
| 3633 | # actually working. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3634 | break;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3635 | * ) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3636 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3637 | esac |
| 3638 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3639 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 3640 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3641 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3642 | ac_file='' |
| 3643 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3644 | if test -z "$ac_file"; then : |
| 3645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3646 | $as_echo "no" >&6; } |
| 3647 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3648 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3649 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3650 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3651 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3652 | as_fn_error 77 "C compiler cannot create executables |
| 3653 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3654 | else |
| 3655 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 3656 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3657 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3658 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 3659 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 3660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 3661 | $as_echo "$ac_file" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3662 | ac_exeext=$ac_cv_exeext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3663 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3664 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3665 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3666 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 3667 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 3668 | if { { ac_try="$ac_link" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3669 | case "(($ac_try" in |
| 3670 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3671 | *) ac_try_echo=$ac_try;; |
| 3672 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3673 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3674 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3675 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3676 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3677 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3678 | test $ac_status = 0; }; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3679 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 3680 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 3681 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 3682 | # `rm'. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3683 | for ac_file in conftest.exe conftest conftest.*; do |
| 3684 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3685 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3686 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3687 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3688 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3689 | * ) break;; |
| 3690 | esac |
| 3691 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3692 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3693 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3694 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3695 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
| 3696 | See \`config.log' for more details" "$LINENO" 5; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3697 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3698 | rm -f conftest conftest$ac_cv_exeext |
| 3699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 3700 | $as_echo "$ac_cv_exeext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3701 | |
| 3702 | rm -f conftest.$ac_ext |
| 3703 | EXEEXT=$ac_cv_exeext |
| 3704 | ac_exeext=$EXEEXT |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3705 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3706 | /* end confdefs.h. */ |
| 3707 | #include <stdio.h> |
| 3708 | int |
| 3709 | main () |
| 3710 | { |
| 3711 | FILE *f = fopen ("conftest.out", "w"); |
| 3712 | return ferror (f) || fclose (f) != 0; |
| 3713 | |
| 3714 | ; |
| 3715 | return 0; |
| 3716 | } |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3717 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3718 | ac_clean_files="$ac_clean_files conftest.out" |
| 3719 | # Check that the compiler produces executables we can run. If not, either |
| 3720 | # the compiler is broken, or we cross compile. |
| 3721 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3722 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3723 | if test "$cross_compiling" != yes; then |
| 3724 | { { ac_try="$ac_link" |
| 3725 | case "(($ac_try" in |
| 3726 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3727 | *) ac_try_echo=$ac_try;; |
| 3728 | esac |
| 3729 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3730 | $as_echo "$ac_try_echo"; } >&5 |
| 3731 | (eval "$ac_link") 2>&5 |
| 3732 | ac_status=$? |
| 3733 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3734 | test $ac_status = 0; } |
| 3735 | if { ac_try='./conftest$ac_cv_exeext' |
| 3736 | { { case "(($ac_try" in |
| 3737 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3738 | *) ac_try_echo=$ac_try;; |
| 3739 | esac |
| 3740 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3741 | $as_echo "$ac_try_echo"; } >&5 |
| 3742 | (eval "$ac_try") 2>&5 |
| 3743 | ac_status=$? |
| 3744 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3745 | test $ac_status = 0; }; }; then |
| 3746 | cross_compiling=no |
| 3747 | else |
| 3748 | if test "$cross_compiling" = maybe; then |
| 3749 | cross_compiling=yes |
| 3750 | else |
| 3751 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3752 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3753 | as_fn_error $? "cannot run C compiled programs. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3754 | If you meant to cross compile, use \`--host'. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3755 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3756 | fi |
| 3757 | fi |
| 3758 | fi |
| 3759 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3760 | $as_echo "$cross_compiling" >&6; } |
| 3761 | |
| 3762 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3763 | ac_clean_files=$ac_clean_files_save |
| 3764 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3765 | $as_echo_n "checking for suffix of object files... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3766 | if ${ac_cv_objext+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3767 | $as_echo_n "(cached) " >&6 |
| 3768 | else |
| 3769 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3770 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3771 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3772 | int |
| 3773 | main () |
| 3774 | { |
| 3775 | |
| 3776 | ; |
| 3777 | return 0; |
| 3778 | } |
| 3779 | _ACEOF |
| 3780 | rm -f conftest.o conftest.obj |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3781 | if { { ac_try="$ac_compile" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3782 | case "(($ac_try" in |
| 3783 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3784 | *) ac_try_echo=$ac_try;; |
| 3785 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3786 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3787 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3788 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3789 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3790 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3791 | test $ac_status = 0; }; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3792 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3793 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3794 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3795 | *.$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] | 3796 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3797 | break;; |
| 3798 | esac |
| 3799 | done |
| 3800 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3801 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3802 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3803 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3804 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3805 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3806 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
| 3807 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3808 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3809 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
| 3810 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3811 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3812 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3813 | OBJEXT=$ac_cv_objext |
| 3814 | ac_objext=$OBJEXT |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3816 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3817 | if ${ac_cv_c_compiler_gnu+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3818 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3819 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3820 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3821 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3822 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3823 | int |
| 3824 | main () |
| 3825 | { |
| 3826 | #ifndef __GNUC__ |
| 3827 | choke me |
| 3828 | #endif |
| 3829 | |
| 3830 | ; |
| 3831 | return 0; |
| 3832 | } |
| 3833 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3834 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3835 | ac_compiler_gnu=yes |
| 3836 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3837 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3838 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3839 | 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] | 3840 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3841 | |
| 3842 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3843 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 3844 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3845 | if test $ac_compiler_gnu = yes; then |
| 3846 | GCC=yes |
| 3847 | else |
| 3848 | GCC= |
| 3849 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3850 | ac_test_CFLAGS=${CFLAGS+set} |
| 3851 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3852 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3853 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3854 | if ${ac_cv_prog_cc_g+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3855 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3856 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3857 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3858 | ac_c_werror_flag=yes |
| 3859 | ac_cv_prog_cc_g=no |
| 3860 | CFLAGS="-g" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3861 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3862 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3863 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3864 | int |
| 3865 | main () |
| 3866 | { |
| 3867 | |
| 3868 | ; |
| 3869 | return 0; |
| 3870 | } |
| 3871 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3872 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3873 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3874 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3875 | CFLAGS="" |
| 3876 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3877 | /* end confdefs.h. */ |
| 3878 | |
| 3879 | int |
| 3880 | main () |
| 3881 | { |
| 3882 | |
| 3883 | ; |
| 3884 | return 0; |
| 3885 | } |
| 3886 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3887 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3888 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3889 | else |
| 3890 | ac_c_werror_flag=$ac_save_c_werror_flag |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3891 | CFLAGS="-g" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3892 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3893 | /* end confdefs.h. */ |
| 3894 | |
| 3895 | int |
| 3896 | main () |
| 3897 | { |
| 3898 | |
| 3899 | ; |
| 3900 | return 0; |
| 3901 | } |
| 3902 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3903 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3904 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3905 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3906 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3907 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3908 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3909 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3910 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3911 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3912 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3913 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3914 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3915 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3916 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3917 | elif test $ac_cv_prog_cc_g = yes; then |
| 3918 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3919 | CFLAGS="-g -O2" |
| 3920 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3921 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3922 | fi |
| 3923 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3924 | if test "$GCC" = yes; then |
| 3925 | CFLAGS="-O2" |
| 3926 | else |
| 3927 | CFLAGS= |
| 3928 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3929 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3930 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3931 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 3932 | if ${ac_cv_prog_cc_c89+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3933 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3934 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3935 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3936 | ac_save_CC=$CC |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3937 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3938 | /* end confdefs.h. */ |
| 3939 | #include <stdarg.h> |
| 3940 | #include <stdio.h> |
| 3941 | #include <sys/types.h> |
| 3942 | #include <sys/stat.h> |
| 3943 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3944 | struct buf { int x; }; |
| 3945 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3946 | static char *e (p, i) |
| 3947 | char **p; |
| 3948 | int i; |
| 3949 | { |
| 3950 | return p[i]; |
| 3951 | } |
| 3952 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3953 | { |
| 3954 | char *s; |
| 3955 | va_list v; |
| 3956 | va_start (v,p); |
| 3957 | s = g (p, va_arg (v,int)); |
| 3958 | va_end (v); |
| 3959 | return s; |
| 3960 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3961 | |
| 3962 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3963 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3964 | These don't provoke an error unfortunately, instead are silently treated |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3965 | 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] | 3966 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3967 | array size at least. It's necessary to write '\x00'==0 to get something |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3968 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3969 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3970 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3971 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3972 | inside strings and character constants. */ |
| 3973 | #define FOO(x) 'x' |
| 3974 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3975 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3976 | int test (int i, double x); |
| 3977 | struct s1 {int (*f) (int a);}; |
| 3978 | struct s2 {int (*f) (double a);}; |
| 3979 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3980 | int argc; |
| 3981 | char **argv; |
| 3982 | int |
| 3983 | main () |
| 3984 | { |
| 3985 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3986 | ; |
| 3987 | return 0; |
| 3988 | } |
| 3989 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3990 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3991 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3992 | do |
| 3993 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3994 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3995 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3996 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3997 | rm -f core conftest.err conftest.$ac_objext |
| 3998 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3999 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4000 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4001 | CC=$ac_save_CC |
| 4002 | |
| 4003 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4004 | # AC_CACHE_VAL |
| 4005 | case "x$ac_cv_prog_cc_c89" in |
| 4006 | x) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4007 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 4008 | $as_echo "none needed" >&6; } ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4009 | xno) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4010 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 4011 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4012 | *) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4013 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4014 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 4015 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4016 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4017 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4018 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4019 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4020 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4021 | ac_ext=c |
| 4022 | ac_cpp='$CPP $CPPFLAGS' |
| 4023 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4024 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4025 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4026 | |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 4027 | if test ! -z "$preset_cflags" |
| 4028 | then |
| 4029 | CFLAGS=$preset_cflags |
| 4030 | fi |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4031 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4032 | |
| 4033 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4034 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 4035 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4036 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4037 | # Check whether --with-cxx_main was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4038 | if test "${with_cxx_main+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4039 | withval=$with_cxx_main; |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4040 | |
| 4041 | case $withval in |
| 4042 | no) with_cxx_main=no |
| 4043 | MAINCC='$(CC)';; |
| 4044 | yes) with_cxx_main=yes |
| 4045 | MAINCC='$(CXX)';; |
| 4046 | *) with_cxx_main=yes |
| 4047 | MAINCC=$withval |
| 4048 | if test -z "$CXX" |
| 4049 | then |
| 4050 | CXX=$withval |
| 4051 | fi;; |
| 4052 | esac |
| 4053 | else |
| 4054 | |
| 4055 | with_cxx_main=no |
| 4056 | MAINCC='$(CC)' |
| 4057 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4058 | fi |
| 4059 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4060 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 4061 | $as_echo "$with_cxx_main" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4062 | |
| 4063 | preset_cxx="$CXX" |
| 4064 | if test -z "$CXX" |
| 4065 | then |
| 4066 | case "$CC" in |
| 4067 | gcc) # Extract the first word of "g++", so it can be a program name with args. |
| 4068 | set dummy g++; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4069 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4070 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4071 | if ${ac_cv_path_CXX+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4072 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4073 | else |
| 4074 | case $CXX in |
| 4075 | [\\/]* | ?:[\\/]*) |
| 4076 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4077 | ;; |
| 4078 | *) |
| 4079 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4080 | for as_dir in notfound |
| 4081 | do |
| 4082 | IFS=$as_save_IFS |
| 4083 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4084 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4085 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4086 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4087 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4088 | break 2 |
| 4089 | fi |
| 4090 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4091 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4092 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4093 | |
| 4094 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++" |
| 4095 | ;; |
| 4096 | esac |
| 4097 | fi |
| 4098 | CXX=$ac_cv_path_CXX |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4099 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4101 | $as_echo "$CXX" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4102 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4103 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4104 | $as_echo "no" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4105 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4106 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4107 | ;; |
| 4108 | cc) # Extract the first word of "c++", so it can be a program name with args. |
| 4109 | set dummy c++; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4111 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4112 | if ${ac_cv_path_CXX+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4113 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4114 | else |
| 4115 | case $CXX in |
| 4116 | [\\/]* | ?:[\\/]*) |
| 4117 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4118 | ;; |
| 4119 | *) |
| 4120 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4121 | for as_dir in notfound |
| 4122 | do |
| 4123 | IFS=$as_save_IFS |
| 4124 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4125 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4126 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4127 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4128 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4129 | break 2 |
| 4130 | fi |
| 4131 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4132 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4133 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4134 | |
| 4135 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++" |
| 4136 | ;; |
| 4137 | esac |
| 4138 | fi |
| 4139 | CXX=$ac_cv_path_CXX |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4140 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4142 | $as_echo "$CXX" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4143 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4144 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4145 | $as_echo "no" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4146 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4147 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4148 | ;; |
| 4149 | esac |
| 4150 | if test "$CXX" = "notfound" |
| 4151 | then |
| 4152 | CXX="" |
| 4153 | fi |
| 4154 | fi |
| 4155 | if test -z "$CXX" |
| 4156 | then |
| 4157 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4158 | do |
| 4159 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4160 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4161 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4162 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4163 | if ${ac_cv_prog_CXX+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4164 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4165 | else |
| 4166 | if test -n "$CXX"; then |
| 4167 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4168 | else |
| 4169 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4170 | for as_dir in $PATH |
| 4171 | do |
| 4172 | IFS=$as_save_IFS |
| 4173 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4174 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4175 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4176 | ac_cv_prog_CXX="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4177 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4178 | break 2 |
| 4179 | fi |
| 4180 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4181 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4182 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4183 | |
| 4184 | fi |
| 4185 | fi |
| 4186 | CXX=$ac_cv_prog_CXX |
| 4187 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4188 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4189 | $as_echo "$CXX" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4190 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4191 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4192 | $as_echo "no" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4193 | fi |
| 4194 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4195 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4196 | test -n "$CXX" && break |
| 4197 | done |
| 4198 | test -n "$CXX" || CXX="notfound" |
| 4199 | |
| 4200 | if test "$CXX" = "notfound" |
| 4201 | then |
| 4202 | CXX="" |
| 4203 | fi |
| 4204 | fi |
| 4205 | if test "$preset_cxx" != "$CXX" |
| 4206 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4207 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4208 | |
| 4209 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4210 | If this is not intended, then set CXX on the configure command line. |
| 4211 | " >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4212 | $as_echo "$as_me: WARNING: |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4213 | |
| 4214 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4215 | If this is not intended, then set CXX on the configure command line. |
| 4216 | " >&2;} |
| 4217 | fi |
| 4218 | |
| 4219 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4220 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4221 | |
| 4222 | ac_ext=c |
| 4223 | ac_cpp='$CPP $CPPFLAGS' |
| 4224 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4225 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4226 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4227 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4228 | $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] | 4229 | # On Suns, sometimes $CPP names a directory. |
| 4230 | if test -n "$CPP" && test -d "$CPP"; then |
| 4231 | CPP= |
| 4232 | fi |
| 4233 | if test -z "$CPP"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4234 | if ${ac_cv_prog_CPP+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4235 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4236 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4237 | # Double quotes because CPP needs to be expanded |
| 4238 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4239 | do |
| 4240 | ac_preproc_ok=false |
| 4241 | for ac_c_preproc_warn_flag in '' yes |
| 4242 | do |
| 4243 | # Use a header file that comes with gcc, so configuring glibc |
| 4244 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4245 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4246 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4247 | # 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] | 4248 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4249 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4250 | /* end confdefs.h. */ |
| 4251 | #ifdef __STDC__ |
| 4252 | # include <limits.h> |
| 4253 | #else |
| 4254 | # include <assert.h> |
| 4255 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4256 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4257 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4258 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4259 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4260 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4261 | # Broken: fails on valid input. |
| 4262 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4263 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4264 | rm -f conftest.err conftest.i conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4265 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4266 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4267 | # can be detected and how. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4268 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4269 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4270 | #include <ac_nonexistent.h> |
| 4271 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4272 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4273 | # Broken: success on invalid input. |
| 4274 | continue |
| 4275 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4276 | # Passes both tests. |
| 4277 | ac_preproc_ok=: |
| 4278 | break |
| 4279 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4280 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4281 | |
| 4282 | done |
| 4283 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4284 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4285 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4286 | break |
| 4287 | fi |
| 4288 | |
| 4289 | done |
| 4290 | ac_cv_prog_CPP=$CPP |
| 4291 | |
| 4292 | fi |
| 4293 | CPP=$ac_cv_prog_CPP |
| 4294 | else |
| 4295 | ac_cv_prog_CPP=$CPP |
| 4296 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4298 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4299 | ac_preproc_ok=false |
| 4300 | for ac_c_preproc_warn_flag in '' yes |
| 4301 | do |
| 4302 | # Use a header file that comes with gcc, so configuring glibc |
| 4303 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4304 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4305 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4306 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4307 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4308 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4309 | /* end confdefs.h. */ |
| 4310 | #ifdef __STDC__ |
| 4311 | # include <limits.h> |
| 4312 | #else |
| 4313 | # include <assert.h> |
| 4314 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4315 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4316 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4317 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4318 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4319 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4320 | # Broken: fails on valid input. |
| 4321 | continue |
| 4322 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4323 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4324 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4325 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4326 | # can be detected and how. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4327 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4328 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4329 | #include <ac_nonexistent.h> |
| 4330 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4331 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4332 | # Broken: success on invalid input. |
| 4333 | continue |
| 4334 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4335 | # Passes both tests. |
| 4336 | ac_preproc_ok=: |
| 4337 | break |
| 4338 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4339 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4340 | |
| 4341 | done |
| 4342 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4343 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4344 | if $ac_preproc_ok; then : |
| 4345 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4346 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4347 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4348 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4349 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
| 4350 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4351 | fi |
| 4352 | |
| 4353 | ac_ext=c |
| 4354 | ac_cpp='$CPP $CPPFLAGS' |
| 4355 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4356 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4357 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 4358 | |
| 4359 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 4361 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4362 | if ${ac_cv_path_GREP+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4363 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4364 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4365 | if test -z "$GREP"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4366 | ac_path_GREP_found=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4367 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4368 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4369 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4370 | do |
| 4371 | IFS=$as_save_IFS |
| 4372 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4373 | for ac_prog in grep ggrep; do |
| 4374 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4375 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4376 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue |
| 4377 | # Check for GNU ac_path_GREP and select it if it is found. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4378 | # Check for GNU $ac_path_GREP |
| 4379 | case `"$ac_path_GREP" --version 2>&1` in |
| 4380 | *GNU*) |
| 4381 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 4382 | *) |
| 4383 | ac_count=0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4384 | $as_echo_n 0123456789 >"conftest.in" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4385 | while : |
| 4386 | do |
| 4387 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4388 | mv "conftest.tmp" "conftest.in" |
| 4389 | cp "conftest.in" "conftest.nl" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4390 | $as_echo 'GREP' >> "conftest.nl" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4391 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4392 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4393 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4394 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 4395 | # Best one so far, save it but keep looking for a better one |
| 4396 | ac_cv_path_GREP="$ac_path_GREP" |
| 4397 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4398 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4399 | # 10*(2^10) chars as input seems more than enough |
| 4400 | test $ac_count -gt 10 && break |
| 4401 | done |
| 4402 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4403 | esac |
| 4404 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4405 | $ac_path_GREP_found && break 3 |
| 4406 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4407 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4408 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4409 | IFS=$as_save_IFS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4410 | if test -z "$ac_cv_path_GREP"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4411 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4412 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4413 | else |
| 4414 | ac_cv_path_GREP=$GREP |
| 4415 | fi |
| 4416 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4417 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4418 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 4419 | $as_echo "$ac_cv_path_GREP" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4420 | GREP="$ac_cv_path_GREP" |
| 4421 | |
| 4422 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 4424 | $as_echo_n "checking for egrep... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4425 | if ${ac_cv_path_EGREP+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4426 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4427 | else |
| 4428 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 4429 | then ac_cv_path_EGREP="$GREP -E" |
| 4430 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4431 | if test -z "$EGREP"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4432 | ac_path_EGREP_found=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4433 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4434 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4435 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4436 | do |
| 4437 | IFS=$as_save_IFS |
| 4438 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4439 | for ac_prog in egrep; do |
| 4440 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4441 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4442 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
| 4443 | # Check for GNU ac_path_EGREP and select it if it is found. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4444 | # Check for GNU $ac_path_EGREP |
| 4445 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4446 | *GNU*) |
| 4447 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4448 | *) |
| 4449 | ac_count=0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4450 | $as_echo_n 0123456789 >"conftest.in" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4451 | while : |
| 4452 | do |
| 4453 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4454 | mv "conftest.tmp" "conftest.in" |
| 4455 | cp "conftest.in" "conftest.nl" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4456 | $as_echo 'EGREP' >> "conftest.nl" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4457 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4458 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4459 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4460 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4461 | # Best one so far, save it but keep looking for a better one |
| 4462 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4463 | ac_path_EGREP_max=$ac_count |
| 4464 | fi |
| 4465 | # 10*(2^10) chars as input seems more than enough |
| 4466 | test $ac_count -gt 10 && break |
| 4467 | done |
| 4468 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4469 | esac |
| 4470 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4471 | $ac_path_EGREP_found && break 3 |
| 4472 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4473 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4474 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4475 | IFS=$as_save_IFS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4476 | if test -z "$ac_cv_path_EGREP"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4477 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4478 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4479 | else |
| 4480 | ac_cv_path_EGREP=$EGREP |
| 4481 | fi |
| 4482 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4483 | fi |
| 4484 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4486 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4487 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4488 | |
| 4489 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4490 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4491 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4492 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4493 | $as_echo_n "(cached) " >&6 |
| 4494 | else |
| 4495 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4496 | /* end confdefs.h. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4497 | #include <stdlib.h> |
| 4498 | #include <stdarg.h> |
| 4499 | #include <string.h> |
| 4500 | #include <float.h> |
| 4501 | |
| 4502 | int |
| 4503 | main () |
| 4504 | { |
| 4505 | |
| 4506 | ; |
| 4507 | return 0; |
| 4508 | } |
| 4509 | _ACEOF |
| 4510 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4511 | ac_cv_header_stdc=yes |
| 4512 | else |
| 4513 | ac_cv_header_stdc=no |
| 4514 | fi |
| 4515 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4516 | |
| 4517 | if test $ac_cv_header_stdc = yes; then |
| 4518 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4519 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4520 | /* end confdefs.h. */ |
| 4521 | #include <string.h> |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4522 | |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4523 | _ACEOF |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4524 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4525 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4526 | |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4527 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4528 | ac_cv_header_stdc=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4529 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 4530 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4531 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4532 | fi |
| 4533 | |
| 4534 | if test $ac_cv_header_stdc = yes; then |
| 4535 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4536 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4537 | /* end confdefs.h. */ |
| 4538 | #include <stdlib.h> |
| 4539 | |
| 4540 | _ACEOF |
| 4541 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4542 | $EGREP "free" >/dev/null 2>&1; then : |
| 4543 | |
| 4544 | else |
| 4545 | ac_cv_header_stdc=no |
| 4546 | fi |
| 4547 | rm -f conftest* |
| 4548 | |
| 4549 | fi |
| 4550 | |
| 4551 | if test $ac_cv_header_stdc = yes; then |
| 4552 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4553 | if test "$cross_compiling" = yes; then : |
| 4554 | : |
| 4555 | else |
| 4556 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4557 | /* end confdefs.h. */ |
| 4558 | #include <ctype.h> |
| 4559 | #include <stdlib.h> |
| 4560 | #if ((' ' & 0x0FF) == 0x020) |
| 4561 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4562 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4563 | #else |
| 4564 | # define ISLOWER(c) \ |
| 4565 | (('a' <= (c) && (c) <= 'i') \ |
| 4566 | || ('j' <= (c) && (c) <= 'r') \ |
| 4567 | || ('s' <= (c) && (c) <= 'z')) |
| 4568 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4569 | #endif |
| 4570 | |
| 4571 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4572 | int |
| 4573 | main () |
| 4574 | { |
| 4575 | int i; |
| 4576 | for (i = 0; i < 256; i++) |
| 4577 | if (XOR (islower (i), ISLOWER (i)) |
| 4578 | || toupper (i) != TOUPPER (i)) |
| 4579 | return 2; |
| 4580 | return 0; |
| 4581 | } |
| 4582 | _ACEOF |
| 4583 | if ac_fn_c_try_run "$LINENO"; then : |
| 4584 | |
| 4585 | else |
| 4586 | ac_cv_header_stdc=no |
| 4587 | fi |
| 4588 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4589 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 4590 | fi |
| 4591 | |
| 4592 | fi |
| 4593 | fi |
| 4594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4595 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 4596 | if test $ac_cv_header_stdc = yes; then |
| 4597 | |
| 4598 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 4599 | |
| 4600 | fi |
| 4601 | |
| 4602 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 4603 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4604 | inttypes.h stdint.h unistd.h |
| 4605 | do : |
| 4606 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4607 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4608 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4609 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4610 | cat >>confdefs.h <<_ACEOF |
| 4611 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4612 | _ACEOF |
| 4613 | |
| 4614 | fi |
| 4615 | |
| 4616 | done |
| 4617 | |
| 4618 | |
| 4619 | |
| 4620 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4621 | if test "x$ac_cv_header_minix_config_h" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4622 | MINIX=yes |
| 4623 | else |
| 4624 | MINIX= |
| 4625 | fi |
| 4626 | |
| 4627 | |
| 4628 | if test "$MINIX" = yes; then |
| 4629 | |
| 4630 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 4631 | |
| 4632 | |
| 4633 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 4634 | |
| 4635 | |
| 4636 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 4637 | |
| 4638 | fi |
| 4639 | |
| 4640 | |
| 4641 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 4642 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4643 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4644 | $as_echo_n "(cached) " >&6 |
| 4645 | else |
| 4646 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4647 | /* end confdefs.h. */ |
| 4648 | |
| 4649 | # define __EXTENSIONS__ 1 |
| 4650 | $ac_includes_default |
| 4651 | int |
| 4652 | main () |
| 4653 | { |
| 4654 | |
| 4655 | ; |
| 4656 | return 0; |
| 4657 | } |
| 4658 | _ACEOF |
| 4659 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4660 | ac_cv_safe_to_define___extensions__=yes |
| 4661 | else |
| 4662 | ac_cv_safe_to_define___extensions__=no |
| 4663 | fi |
| 4664 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4665 | fi |
| 4666 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 4667 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 4668 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 4669 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 4670 | |
| 4671 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 4672 | |
| 4673 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 4674 | |
| 4675 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 4676 | |
| 4677 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 4678 | |
| 4679 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4680 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4681 | # Check for unsupported systems |
| 4682 | case $ac_sys_system/$ac_sys_release in |
| 4683 | atheos*|Linux*/1*) |
| 4684 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 4685 | echo See README for details. |
| 4686 | exit 1;; |
| 4687 | esac |
| 4688 | |
| 4689 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4690 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 4691 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4692 | |
| 4693 | # Check whether --with-suffix was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4694 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4695 | withval=$with_suffix; |
| 4696 | case $withval in |
| 4697 | no) EXEEXT=;; |
| 4698 | yes) EXEEXT=.exe;; |
| 4699 | *) EXEEXT=$withval;; |
| 4700 | esac |
| 4701 | fi |
| 4702 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4703 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 4704 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4705 | |
| 4706 | # Test whether we're running on a non-case-sensitive system, in which |
| 4707 | # case we give a warning if no ext is given |
| 4708 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4709 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 4710 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4711 | if test ! -d CaseSensitiveTestDir; then |
| 4712 | mkdir CaseSensitiveTestDir |
| 4713 | fi |
| 4714 | |
| 4715 | if test -d casesensitivetestdir |
| 4716 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4718 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4719 | BUILDEXEEXT=.exe |
| 4720 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4721 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4722 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4723 | BUILDEXEEXT=$EXEEXT |
| 4724 | fi |
| 4725 | rmdir CaseSensitiveTestDir |
| 4726 | |
| 4727 | case $MACHDEP in |
| 4728 | bsdos*) |
| 4729 | case $CC in |
| 4730 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 4731 | esac;; |
| 4732 | esac |
| 4733 | |
| 4734 | case $ac_sys_system in |
| 4735 | hp*|HP*) |
| 4736 | case $CC in |
| 4737 | cc|*/cc) CC="$CC -Ae";; |
| 4738 | esac;; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4739 | SunOS*) |
| 4740 | # Some functions have a prototype only with that define, e.g. confstr |
| 4741 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4742 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4743 | |
| 4744 | ;; |
| 4745 | esac |
| 4746 | |
| 4747 | |
| 4748 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4749 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 4750 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4751 | if test -z "$LIBRARY" |
| 4752 | then |
| 4753 | LIBRARY='libpython$(VERSION).a' |
| 4754 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 4756 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4757 | |
| 4758 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 4759 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 4760 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 4761 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 4762 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 4763 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 4764 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 4765 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 4766 | # |
| 4767 | # RUNSHARED is used to run shared python without installed libraries |
| 4768 | # |
| 4769 | # INSTSONAME is the name of the shared library that will be use to install |
| 4770 | # on the system - some systems like version suffix, others don't |
| 4771 | |
| 4772 | |
| 4773 | |
| 4774 | |
| 4775 | |
| 4776 | |
| 4777 | LDLIBRARY="$LIBRARY" |
| 4778 | BLDLIBRARY='$(LDLIBRARY)' |
| 4779 | INSTSONAME='$(LDLIBRARY)' |
| 4780 | DLLLIBRARY='' |
| 4781 | LDLIBRARYDIR='' |
| 4782 | RUNSHARED='' |
| 4783 | |
| 4784 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 4785 | # If CXX is set, and if it is needed to link a main function that was |
| 4786 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 4787 | # python might then depend on the C++ runtime |
| 4788 | # This is altered for AIX in order to build the export list before |
| 4789 | # linking. |
| 4790 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4791 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 4792 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4793 | if test -z "$LINKCC" |
| 4794 | then |
| 4795 | LINKCC='$(PURIFY) $(MAINCC)' |
| 4796 | case $ac_sys_system in |
| 4797 | AIX*) |
| 4798 | exp_extra="\"\"" |
| 4799 | if test $ac_sys_release -ge 5 -o \ |
| 4800 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 4801 | exp_extra="." |
| 4802 | fi |
| 4803 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4804 | QNX*) |
| 4805 | # qcc must be used because the other compilers do not |
| 4806 | # support -N. |
| 4807 | LINKCC=qcc;; |
| 4808 | esac |
| 4809 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4810 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 4811 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4812 | |
| 4813 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 4814 | # make sure we default having it set to "no": this is used by |
| 4815 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 4816 | # to linker command lines, and failing to detect GNU ld simply results |
| 4817 | # in the same bahaviour as before. |
| 4818 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4819 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 4820 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4821 | ac_prog=ld |
| 4822 | if test "$GCC" = yes; then |
| 4823 | ac_prog=`$CC -print-prog-name=ld` |
| 4824 | fi |
| 4825 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 4826 | *GNU*) |
| 4827 | GNULD=yes;; |
| 4828 | *) |
| 4829 | GNULD=no;; |
| 4830 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4831 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 4832 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4833 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4834 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 4835 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4836 | # Check whether --enable-shared was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4837 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4838 | enableval=$enable_shared; |
| 4839 | fi |
| 4840 | |
| 4841 | |
| 4842 | if test -z "$enable_shared" |
| 4843 | then |
| 4844 | case $ac_sys_system in |
| 4845 | CYGWIN* | atheos*) |
| 4846 | enable_shared="yes";; |
| 4847 | *) |
| 4848 | enable_shared="no";; |
| 4849 | esac |
| 4850 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4851 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 4852 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4853 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4854 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 4855 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4856 | # Check whether --enable-profiling was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4857 | if test "${enable_profiling+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4858 | enableval=$enable_profiling; ac_save_cc="$CC" |
| 4859 | CC="$CC -pg" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4860 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4861 | ac_enable_profiling="no" |
| 4862 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4863 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4864 | /* end confdefs.h. */ |
| 4865 | int main() { return 0; } |
| 4866 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4867 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4868 | ac_enable_profiling="yes" |
| 4869 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4870 | ac_enable_profiling="no" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4871 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4872 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4873 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4874 | fi |
| 4875 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4876 | CC="$ac_save_cc" |
| 4877 | fi |
| 4878 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_profiling" >&5 |
| 4880 | $as_echo "$ac_enable_profiling" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4881 | |
| 4882 | case "$ac_enable_profiling" in |
| 4883 | "yes") |
| 4884 | BASECFLAGS="-pg $BASECFLAGS" |
| 4885 | LDFLAGS="-pg $LDFLAGS" |
| 4886 | ;; |
| 4887 | esac |
| 4888 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4889 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 4890 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4891 | |
| 4892 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 4893 | # library that we build, but we do not want to link against it (we |
| 4894 | # will find it with a -framework option). For this reason there is an |
| 4895 | # extra variable BLDLIBRARY against which Python and the extension |
| 4896 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 4897 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 4898 | if test "$enable_framework" |
| 4899 | then |
| 4900 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 4901 | RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH" |
| 4902 | BLDLIBRARY='' |
| 4903 | else |
| 4904 | BLDLIBRARY='$(LDLIBRARY)' |
| 4905 | fi |
| 4906 | |
| 4907 | # Other platforms follow |
| 4908 | if test $enable_shared = "yes"; then |
| 4909 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4910 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4911 | |
| 4912 | case $ac_sys_system in |
| 4913 | BeOS*) |
| 4914 | LDLIBRARY='libpython$(VERSION).so' |
| 4915 | ;; |
| 4916 | CYGWIN*) |
| 4917 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4918 | DLLLIBRARY='libpython$(VERSION).dll' |
| 4919 | ;; |
| 4920 | SunOS*) |
| 4921 | LDLIBRARY='libpython$(VERSION).so' |
| 4922 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4923 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4924 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4925 | ;; |
| 4926 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*) |
| 4927 | LDLIBRARY='libpython$(VERSION).so' |
| 4928 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4929 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4930 | case $ac_sys_system in |
| 4931 | FreeBSD*) |
| 4932 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 4933 | ;; |
| 4934 | esac |
| 4935 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4936 | ;; |
| 4937 | hp*|HP*) |
| 4938 | case `uname -m` in |
| 4939 | ia64) |
| 4940 | LDLIBRARY='libpython$(VERSION).so' |
| 4941 | ;; |
| 4942 | *) |
| 4943 | LDLIBRARY='libpython$(VERSION).sl' |
| 4944 | ;; |
| 4945 | esac |
| 4946 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4947 | RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH} |
| 4948 | ;; |
| 4949 | OSF*) |
| 4950 | LDLIBRARY='libpython$(VERSION).so' |
| 4951 | BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)' |
| 4952 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4953 | ;; |
| 4954 | atheos*) |
| 4955 | LDLIBRARY='libpython$(VERSION).so' |
| 4956 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4957 | RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib} |
| 4958 | ;; |
| 4959 | Darwin*) |
| 4960 | LDLIBRARY='libpython$(VERSION).dylib' |
| 4961 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4962 | RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}' |
| 4963 | ;; |
Antoine Pitrou | aabdceb | 2010-09-10 20:03:17 +0000 | [diff] [blame] | 4964 | AIX*) |
| 4965 | LDLIBRARY='libpython$(VERSION).so' |
| 4966 | RUNSHARED=LIBPATH=`pwd`:${LIBPATH} |
| 4967 | ;; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4968 | |
| 4969 | esac |
| 4970 | else # shared is disabled |
| 4971 | case $ac_sys_system in |
| 4972 | CYGWIN*) |
| 4973 | BLDLIBRARY='$(LIBRARY)' |
| 4974 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4975 | ;; |
| 4976 | esac |
| 4977 | fi |
| 4978 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 4980 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4981 | |
| 4982 | if test -n "$ac_tool_prefix"; then |
| 4983 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 4984 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4985 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4986 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 4987 | if ${ac_cv_prog_RANLIB+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4988 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4989 | else |
| 4990 | if test -n "$RANLIB"; then |
| 4991 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 4992 | else |
| 4993 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4994 | for as_dir in $PATH |
| 4995 | do |
| 4996 | IFS=$as_save_IFS |
| 4997 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4998 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4999 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5000 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5001 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5002 | break 2 |
| 5003 | fi |
| 5004 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5005 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5006 | IFS=$as_save_IFS |
| 5007 | |
| 5008 | fi |
| 5009 | fi |
| 5010 | RANLIB=$ac_cv_prog_RANLIB |
| 5011 | if test -n "$RANLIB"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 5013 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5014 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5015 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5016 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5017 | fi |
| 5018 | |
| 5019 | |
| 5020 | fi |
| 5021 | if test -z "$ac_cv_prog_RANLIB"; then |
| 5022 | ac_ct_RANLIB=$RANLIB |
| 5023 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 5024 | set dummy ranlib; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5025 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5026 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5027 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5028 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5029 | else |
| 5030 | if test -n "$ac_ct_RANLIB"; then |
| 5031 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5032 | else |
| 5033 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5034 | for as_dir in $PATH |
| 5035 | do |
| 5036 | IFS=$as_save_IFS |
| 5037 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5038 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5039 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5040 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5041 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5042 | break 2 |
| 5043 | fi |
| 5044 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5045 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5046 | IFS=$as_save_IFS |
| 5047 | |
| 5048 | fi |
| 5049 | fi |
| 5050 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5051 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5053 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5054 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5056 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5057 | fi |
| 5058 | |
| 5059 | if test "x$ac_ct_RANLIB" = x; then |
| 5060 | RANLIB=":" |
| 5061 | else |
| 5062 | case $cross_compiling:$ac_tool_warned in |
| 5063 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5064 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5065 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5066 | ac_tool_warned=yes ;; |
| 5067 | esac |
| 5068 | RANLIB=$ac_ct_RANLIB |
| 5069 | fi |
| 5070 | else |
| 5071 | RANLIB="$ac_cv_prog_RANLIB" |
| 5072 | fi |
| 5073 | |
| 5074 | |
| 5075 | for ac_prog in ar aal |
| 5076 | do |
| 5077 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5078 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5079 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5080 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5081 | if ${ac_cv_prog_AR+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5082 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5083 | else |
| 5084 | if test -n "$AR"; then |
| 5085 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5086 | else |
| 5087 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5088 | for as_dir in $PATH |
| 5089 | do |
| 5090 | IFS=$as_save_IFS |
| 5091 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5092 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5093 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5094 | ac_cv_prog_AR="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5095 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5096 | break 2 |
| 5097 | fi |
| 5098 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5099 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5100 | IFS=$as_save_IFS |
| 5101 | |
| 5102 | fi |
| 5103 | fi |
| 5104 | AR=$ac_cv_prog_AR |
| 5105 | if test -n "$AR"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5106 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5107 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5108 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5109 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5110 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5111 | fi |
| 5112 | |
| 5113 | |
| 5114 | test -n "$AR" && break |
| 5115 | done |
| 5116 | test -n "$AR" || AR="ar" |
| 5117 | |
| 5118 | |
| 5119 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5120 | |
| 5121 | if test -z "$ARFLAGS" |
| 5122 | then |
| 5123 | ARFLAGS="rc" |
| 5124 | fi |
| 5125 | |
| 5126 | |
| 5127 | # Extract the first word of "svnversion", so it can be a program name with args. |
| 5128 | set dummy svnversion; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5129 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5130 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5131 | if ${ac_cv_prog_SVNVERSION+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5132 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5133 | else |
| 5134 | if test -n "$SVNVERSION"; then |
| 5135 | ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test. |
| 5136 | else |
| 5137 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5138 | for as_dir in $PATH |
| 5139 | do |
| 5140 | IFS=$as_save_IFS |
| 5141 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5142 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5143 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5144 | ac_cv_prog_SVNVERSION="found" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5145 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5146 | break 2 |
| 5147 | fi |
| 5148 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5149 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5150 | IFS=$as_save_IFS |
| 5151 | |
| 5152 | test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found" |
| 5153 | fi |
| 5154 | fi |
| 5155 | SVNVERSION=$ac_cv_prog_SVNVERSION |
| 5156 | if test -n "$SVNVERSION"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5157 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SVNVERSION" >&5 |
| 5158 | $as_echo "$SVNVERSION" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5159 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5160 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5161 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5162 | fi |
| 5163 | |
| 5164 | |
| 5165 | if test $SVNVERSION = found |
| 5166 | then |
| 5167 | SVNVERSION="svnversion \$(srcdir)" |
| 5168 | else |
| 5169 | SVNVERSION="echo Unversioned directory" |
| 5170 | fi |
| 5171 | |
| 5172 | case $MACHDEP in |
| 5173 | bsdos*|hp*|HP*) |
| 5174 | # install -d does not work on BSDI or HP-UX |
| 5175 | if test -z "$INSTALL" |
| 5176 | then |
| 5177 | INSTALL="${srcdir}/install-sh -c" |
| 5178 | fi |
| 5179 | esac |
| 5180 | ac_aux_dir= |
| 5181 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5182 | if test -f "$ac_dir/install-sh"; then |
| 5183 | ac_aux_dir=$ac_dir |
| 5184 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 5185 | break |
| 5186 | elif test -f "$ac_dir/install.sh"; then |
| 5187 | ac_aux_dir=$ac_dir |
| 5188 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 5189 | break |
| 5190 | elif test -f "$ac_dir/shtool"; then |
| 5191 | ac_aux_dir=$ac_dir |
| 5192 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 5193 | break |
| 5194 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5195 | done |
| 5196 | if test -z "$ac_aux_dir"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5197 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5198 | fi |
| 5199 | |
| 5200 | # These three variables are undocumented and unsupported, |
| 5201 | # and are intended to be withdrawn in a future Autoconf release. |
| 5202 | # They can cause serious problems if a builder's source tree is in a directory |
| 5203 | # whose full name contains unusual characters. |
| 5204 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 5205 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 5206 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 5207 | |
| 5208 | |
| 5209 | # Find a good install program. We prefer a C program (faster), |
| 5210 | # so one script is as good as another. But avoid the broken or |
| 5211 | # incompatible versions: |
| 5212 | # SysV /etc/install, /usr/sbin/install |
| 5213 | # SunOS /usr/etc/install |
| 5214 | # IRIX /sbin/install |
| 5215 | # AIX /bin/install |
| 5216 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 5217 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 5218 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 5219 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 5220 | # OS/2's system install, which has a completely different semantic |
| 5221 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5222 | # Reject install programs that cannot install multiple files. |
| 5223 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 5224 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5225 | if test -z "$INSTALL"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5226 | if ${ac_cv_path_install+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5227 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5228 | else |
| 5229 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5230 | for as_dir in $PATH |
| 5231 | do |
| 5232 | IFS=$as_save_IFS |
| 5233 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5234 | # Account for people who put trailing slashes in PATH elements. |
| 5235 | case $as_dir/ in #(( |
| 5236 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5237 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5238 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5239 | /usr/ucb/* ) ;; |
| 5240 | *) |
| 5241 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 5242 | # Don't use installbsd from OSF since it installs stuff as root |
| 5243 | # by default. |
| 5244 | for ac_prog in ginstall scoinst install; do |
| 5245 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5246 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
| 5247 | if test $ac_prog = install && |
| 5248 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5249 | # AIX install. It has an incompatible calling convention. |
| 5250 | : |
| 5251 | elif test $ac_prog = install && |
| 5252 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5253 | # program-specific install script used by HP pwplus--don't use. |
| 5254 | : |
| 5255 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5256 | rm -rf conftest.one conftest.two conftest.dir |
| 5257 | echo one > conftest.one |
| 5258 | echo two > conftest.two |
| 5259 | mkdir conftest.dir |
| 5260 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 5261 | test -s conftest.one && test -s conftest.two && |
| 5262 | test -s conftest.dir/conftest.one && |
| 5263 | test -s conftest.dir/conftest.two |
| 5264 | then |
| 5265 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 5266 | break 3 |
| 5267 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5268 | fi |
| 5269 | fi |
| 5270 | done |
| 5271 | done |
| 5272 | ;; |
| 5273 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5274 | |
| 5275 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5276 | IFS=$as_save_IFS |
| 5277 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5278 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5279 | |
| 5280 | fi |
| 5281 | if test "${ac_cv_path_install+set}" = set; then |
| 5282 | INSTALL=$ac_cv_path_install |
| 5283 | else |
| 5284 | # As a last resort, use the slow shell script. Don't cache a |
| 5285 | # value for INSTALL within a source directory, because that will |
| 5286 | # break other packages using the cache if that directory is |
| 5287 | # removed, or if the value is a relative name. |
| 5288 | INSTALL=$ac_install_sh |
| 5289 | fi |
| 5290 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5291 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 5292 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5293 | |
| 5294 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 5295 | # It thinks the first close brace ends the variable substitution. |
| 5296 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 5297 | |
| 5298 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 5299 | |
| 5300 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 5301 | |
| 5302 | |
| 5303 | # Not every filesystem supports hard links |
| 5304 | |
| 5305 | if test -z "$LN" ; then |
| 5306 | case $ac_sys_system in |
| 5307 | BeOS*) LN="ln -s";; |
| 5308 | CYGWIN*) LN="ln -s";; |
| 5309 | atheos*) LN="ln -s";; |
| 5310 | *) LN=ln;; |
| 5311 | esac |
| 5312 | fi |
| 5313 | |
| 5314 | # Check for --with-pydebug |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 5316 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5317 | |
| 5318 | # Check whether --with-pydebug was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5319 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5320 | withval=$with_pydebug; |
| 5321 | if test "$withval" != no |
| 5322 | then |
| 5323 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5324 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5325 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5326 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5327 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5328 | Py_DEBUG='true' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5329 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5330 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5331 | fi |
| 5332 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5333 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5334 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5335 | fi |
| 5336 | |
| 5337 | |
| 5338 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 5339 | # merged with this chunk of code? |
| 5340 | |
| 5341 | # Optimizer/debugger flags |
| 5342 | # ------------------------ |
| 5343 | # (The following bit of code is complicated enough - please keep things |
| 5344 | # indented properly. Just pretend you're editing Python code. ;-) |
| 5345 | |
| 5346 | # There are two parallel sets of case statements below, one that checks to |
| 5347 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 5348 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 5349 | # user set OPT. |
| 5350 | |
| 5351 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 5352 | # it on the command line |
| 5353 | |
Benjamin Peterson | d4b721b | 2010-03-23 20:58:37 +0000 | [diff] [blame] | 5354 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5355 | then |
| 5356 | case $GCC in |
| 5357 | yes) |
| 5358 | if test "$CC" != 'g++' ; then |
| 5359 | STRICT_PROTO="-Wstrict-prototypes" |
| 5360 | fi |
| 5361 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 5362 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 5363 | WRAP="-fwrapv" |
| 5364 | fi |
| 5365 | case $ac_cv_prog_cc_g in |
| 5366 | yes) |
| 5367 | if test "$Py_DEBUG" = 'true' ; then |
| 5368 | # Optimization messes up debuggers, so turn it off for |
| 5369 | # debug builds. |
Mark Dickinson | d2f3e3f | 2010-05-05 22:23:58 +0000 | [diff] [blame] | 5370 | OPT="-g -O0 -Wall $STRICT_PROTO" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5371 | else |
| 5372 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 5373 | fi |
| 5374 | ;; |
| 5375 | *) |
| 5376 | OPT="-O3 -Wall $STRICT_PROTO" |
| 5377 | ;; |
| 5378 | esac |
| 5379 | case $ac_sys_system in |
| 5380 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 5381 | ;; |
| 5382 | esac |
| 5383 | ;; |
| 5384 | |
| 5385 | *) |
| 5386 | OPT="-O" |
| 5387 | ;; |
| 5388 | esac |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5389 | fi |
| 5390 | |
| 5391 | |
| 5392 | |
| 5393 | # The -arch flags for universal builds on OSX |
| 5394 | UNIVERSAL_ARCH_FLAGS= |
| 5395 | |
| 5396 | |
| 5397 | # tweak BASECFLAGS based on compiler and platform |
| 5398 | case $GCC in |
| 5399 | yes) |
| 5400 | # Python violates C99 rules, by casting between incompatible |
| 5401 | # pointer types. GCC may generate bad code as a result of that, |
| 5402 | # so use -fno-strict-aliasing if supported. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5403 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -fno-strict-aliasing" >&5 |
| 5404 | $as_echo_n "checking whether $CC accepts -fno-strict-aliasing... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5405 | ac_save_cc="$CC" |
| 5406 | CC="$CC -fno-strict-aliasing" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5407 | if ${ac_cv_no_strict_aliasing_ok+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5408 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 5409 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5410 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5411 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5412 | |
| 5413 | int |
| 5414 | main () |
| 5415 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5416 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5417 | ; |
| 5418 | return 0; |
| 5419 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5420 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5421 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5422 | ac_cv_no_strict_aliasing_ok=yes |
| 5423 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5424 | ac_cv_no_strict_aliasing_ok=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5425 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5426 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 5427 | fi |
| 5428 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5429 | CC="$ac_save_cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing_ok" >&5 |
| 5431 | $as_echo "$ac_cv_no_strict_aliasing_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5432 | if test $ac_cv_no_strict_aliasing_ok = yes |
| 5433 | then |
| 5434 | BASECFLAGS="$BASECFLAGS -fno-strict-aliasing" |
| 5435 | fi |
| 5436 | |
| 5437 | # if using gcc on alpha, use -mieee to get (near) full IEEE 754 |
| 5438 | # support. Without this, treatment of subnormals doesn't follow |
| 5439 | # the standard. |
| 5440 | case $ac_sys_machine in |
| 5441 | alpha*) |
| 5442 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5443 | ;; |
| 5444 | esac |
| 5445 | |
| 5446 | case $ac_sys_system in |
| 5447 | SCO_SV*) |
| 5448 | BASECFLAGS="$BASECFLAGS -m486 -DSCO5" |
| 5449 | ;; |
| 5450 | # is there any other compiler on Darwin besides gcc? |
| 5451 | Darwin*) |
| 5452 | # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd |
| 5453 | # used to be here, but non-Apple gcc doesn't accept them. |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5454 | if test "${CC}" = gcc |
| 5455 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5456 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5 |
| 5457 | $as_echo_n "checking which compiler should be used... " >&6; } |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5458 | case "${UNIVERSALSDK}" in |
| 5459 | */MacOSX10.4u.sdk) |
| 5460 | # Build using 10.4 SDK, force usage of gcc when the |
| 5461 | # compiler is gcc, otherwise the user will get very |
| 5462 | # confusing error messages when building on OSX 10.6 |
| 5463 | CC=gcc-4.0 |
| 5464 | CPP=cpp-4.0 |
| 5465 | ;; |
| 5466 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 5468 | $as_echo "$CC" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5469 | fi |
| 5470 | |
| 5471 | # Calculate the right deployment target for this build. |
| 5472 | # |
| 5473 | cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'` |
| 5474 | if test ${cur_target} '>' 10.2; then |
| 5475 | cur_target=10.3 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5476 | if test ${enable_universalsdk}; then |
| 5477 | if test "${UNIVERSAL_ARCHS}" = "all"; then |
| 5478 | # Ensure that the default platform for a |
| 5479 | # 4-way universal build is OSX 10.5, |
| 5480 | # that's the first OS release where |
| 5481 | # 4-way builds make sense. |
| 5482 | cur_target='10.5' |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 5483 | |
| 5484 | elif test "${UNIVERSAL_ARCHS}" = "3-way"; then |
| 5485 | cur_target='10.5' |
| 5486 | |
| 5487 | elif test "${UNIVERSAL_ARCHS}" = "intel"; then |
| 5488 | cur_target='10.5' |
| 5489 | |
| 5490 | elif test "${UNIVERSAL_ARCHS}" = "64-bit"; then |
| 5491 | cur_target='10.5' |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5492 | fi |
| 5493 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 5494 | if test `/usr/bin/arch` = "i386"; then |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5495 | # On Intel macs default to a deployment |
| 5496 | # target of 10.4, that's the first OSX |
| 5497 | # release with Intel support. |
| 5498 | cur_target="10.4" |
| 5499 | fi |
| 5500 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5501 | fi |
| 5502 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
| 5503 | |
| 5504 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 5505 | # environment with a value that is the same as what we'll use |
| 5506 | # in the Makefile to ensure that we'll get the same compiler |
| 5507 | # environment during configure and build time. |
| 5508 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 5509 | export MACOSX_DEPLOYMENT_TARGET |
| 5510 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 5511 | |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5512 | if test "${enable_universalsdk}"; then |
| 5513 | UNIVERSAL_ARCH_FLAGS="" |
| 5514 | if test "$UNIVERSAL_ARCHS" = "32-bit" ; then |
| 5515 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 5516 | ARCH_RUN_32BIT="" |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 5517 | LIPO_32BIT_FLAGS="" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5518 | |
| 5519 | elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then |
| 5520 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
| 5521 | LIPO_32BIT_FLAGS="" |
| 5522 | ARCH_RUN_32BIT="true" |
| 5523 | |
| 5524 | elif test "$UNIVERSAL_ARCHS" = "all" ; then |
| 5525 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
| 5526 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 92397ce | 2010-01-17 19:32:00 +0000 | [diff] [blame] | 5527 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5528 | |
| 5529 | elif test "$UNIVERSAL_ARCHS" = "intel" ; then |
| 5530 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
| 5531 | LIPO_32BIT_FLAGS="-extract i386" |
Ronald Oussoren | 92397ce | 2010-01-17 19:32:00 +0000 | [diff] [blame] | 5532 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5533 | |
| 5534 | elif test "$UNIVERSAL_ARCHS" = "3-way" ; then |
| 5535 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
| 5536 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 9922f17 | 2010-02-11 13:19:34 +0000 | [diff] [blame] | 5537 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5538 | |
| 5539 | else |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5540 | as_fn_error $? "proper usage is --with-universal-arch=32-bit|64-bit|all|intel|3-way" "$LINENO" 5 |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5541 | |
| 5542 | fi |
| 5543 | |
| 5544 | |
Ronald Oussoren | 974eb5e | 2010-04-18 17:59:37 +0000 | [diff] [blame] | 5545 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} ${CFLAGS}" |
| 5546 | if test "${UNIVERSALSDK}" != "/" |
| 5547 | then |
| 5548 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
| 5549 | LDFLAGS="-isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
| 5550 | CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5551 | fi |
| 5552 | |
| 5553 | fi |
| 5554 | |
| 5555 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5556 | ;; |
| 5557 | OSF*) |
| 5558 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5559 | ;; |
| 5560 | esac |
| 5561 | ;; |
| 5562 | |
| 5563 | *) |
| 5564 | case $ac_sys_system in |
| 5565 | OpenUNIX*|UnixWare*) |
| 5566 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 5567 | ;; |
| 5568 | OSF*) |
| 5569 | BASECFLAGS="$BASECFLAGS -ieee -std" |
| 5570 | ;; |
| 5571 | SCO_SV*) |
| 5572 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 5573 | ;; |
| 5574 | esac |
| 5575 | ;; |
| 5576 | esac |
| 5577 | |
| 5578 | if test "$Py_DEBUG" = 'true'; then |
| 5579 | : |
| 5580 | else |
| 5581 | OPT="-DNDEBUG $OPT" |
| 5582 | fi |
| 5583 | |
| 5584 | if test "$ac_arch_flags" |
| 5585 | then |
| 5586 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 5587 | fi |
| 5588 | |
| 5589 | # disable check for icc since it seems to pass, but generates a warning |
| 5590 | if test "$CC" = icc |
| 5591 | then |
| 5592 | ac_cv_opt_olimit_ok=no |
| 5593 | fi |
| 5594 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5595 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -OPT:Olimit=0" >&5 |
| 5596 | $as_echo_n "checking whether $CC accepts -OPT:Olimit=0... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5597 | if ${ac_cv_opt_olimit_ok+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5598 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5599 | else |
| 5600 | ac_save_cc="$CC" |
| 5601 | CC="$CC -OPT:Olimit=0" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5602 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5603 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5604 | |
| 5605 | int |
| 5606 | main () |
| 5607 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5608 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5609 | ; |
| 5610 | return 0; |
| 5611 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5612 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5613 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5614 | ac_cv_opt_olimit_ok=yes |
| 5615 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5616 | ac_cv_opt_olimit_ok=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5617 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5618 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5619 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5620 | CC="$ac_save_cc" |
| 5621 | fi |
| 5622 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5623 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_opt_olimit_ok" >&5 |
| 5624 | $as_echo "$ac_cv_opt_olimit_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5625 | if test $ac_cv_opt_olimit_ok = yes; then |
| 5626 | case $ac_sys_system in |
| 5627 | # XXX is this branch needed? On MacOSX 10.2.2 the result of the |
| 5628 | # olimit_ok test is "no". Is it "yes" in some other Darwin-esque |
| 5629 | # environment? |
| 5630 | Darwin*) |
| 5631 | ;; |
| 5632 | *) |
| 5633 | BASECFLAGS="$BASECFLAGS -OPT:Olimit=0" |
| 5634 | ;; |
| 5635 | esac |
| 5636 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5637 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Olimit 1500" >&5 |
| 5638 | $as_echo_n "checking whether $CC accepts -Olimit 1500... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5639 | if ${ac_cv_olimit_ok+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5640 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5641 | else |
| 5642 | ac_save_cc="$CC" |
| 5643 | CC="$CC -Olimit 1500" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5644 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5645 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5646 | |
| 5647 | int |
| 5648 | main () |
| 5649 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5650 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5651 | ; |
| 5652 | return 0; |
| 5653 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5654 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5655 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5656 | ac_cv_olimit_ok=yes |
| 5657 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5658 | ac_cv_olimit_ok=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5659 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5660 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5661 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5662 | CC="$ac_save_cc" |
| 5663 | fi |
| 5664 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_olimit_ok" >&5 |
| 5666 | $as_echo "$ac_cv_olimit_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5667 | if test $ac_cv_olimit_ok = yes; then |
| 5668 | BASECFLAGS="$BASECFLAGS -Olimit 1500" |
| 5669 | fi |
| 5670 | fi |
| 5671 | |
| 5672 | # Check whether GCC supports PyArg_ParseTuple format |
| 5673 | if test "$GCC" = "yes" |
| 5674 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5675 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc supports ParseTuple __format__" >&5 |
| 5676 | $as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5677 | save_CFLAGS=$CFLAGS |
| 5678 | CFLAGS="$CFLAGS -Werror" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5679 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5680 | /* end confdefs.h. */ |
| 5681 | |
| 5682 | void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2))); |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5683 | int |
| 5684 | main () |
| 5685 | { |
| 5686 | |
| 5687 | ; |
| 5688 | return 0; |
| 5689 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5690 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5691 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5692 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5693 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5694 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5695 | $as_echo "#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5696 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5698 | $as_echo "yes" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5699 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5700 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5701 | |
| 5702 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5703 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5704 | |
| 5705 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5706 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5707 | CFLAGS=$save_CFLAGS |
| 5708 | fi |
| 5709 | |
| 5710 | # On some compilers, pthreads are available without further options |
| 5711 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 5712 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 5713 | # So we have to see first whether pthreads are available without |
| 5714 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5715 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 5716 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5717 | if ${ac_cv_pthread_is_default+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5718 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5719 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5720 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5721 | ac_cv_pthread_is_default=no |
| 5722 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5723 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5724 | /* end confdefs.h. */ |
| 5725 | |
| 5726 | #include <pthread.h> |
| 5727 | |
| 5728 | void* routine(void* p){return NULL;} |
| 5729 | |
| 5730 | int main(){ |
| 5731 | pthread_t p; |
| 5732 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5733 | return 1; |
| 5734 | (void)pthread_detach(p); |
| 5735 | return 0; |
| 5736 | } |
| 5737 | |
| 5738 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5739 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5740 | |
| 5741 | ac_cv_pthread_is_default=yes |
| 5742 | ac_cv_kthread=no |
| 5743 | ac_cv_pthread=no |
| 5744 | |
| 5745 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5746 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5747 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5748 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5749 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5750 | fi |
| 5751 | |
| 5752 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5753 | fi |
| 5754 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 5756 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5757 | |
| 5758 | |
| 5759 | if test $ac_cv_pthread_is_default = yes |
| 5760 | then |
| 5761 | ac_cv_kpthread=no |
| 5762 | else |
| 5763 | # -Kpthread, if available, provides the right #defines |
| 5764 | # and linker options to make pthread_create available |
| 5765 | # Some compilers won't report that they do not support -Kpthread, |
| 5766 | # so we need to run a program to see whether it really made the |
| 5767 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 5769 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5770 | if ${ac_cv_kpthread+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5771 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5772 | else |
| 5773 | ac_save_cc="$CC" |
| 5774 | CC="$CC -Kpthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5775 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5776 | ac_cv_kpthread=no |
| 5777 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5778 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5779 | /* end confdefs.h. */ |
| 5780 | |
| 5781 | #include <pthread.h> |
| 5782 | |
| 5783 | void* routine(void* p){return NULL;} |
| 5784 | |
| 5785 | int main(){ |
| 5786 | pthread_t p; |
| 5787 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5788 | return 1; |
| 5789 | (void)pthread_detach(p); |
| 5790 | return 0; |
| 5791 | } |
| 5792 | |
| 5793 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5794 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5795 | ac_cv_kpthread=yes |
| 5796 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5797 | ac_cv_kpthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5798 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5799 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5800 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5801 | fi |
| 5802 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5803 | CC="$ac_save_cc" |
| 5804 | fi |
| 5805 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5806 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 5807 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5808 | fi |
| 5809 | |
| 5810 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 5811 | then |
| 5812 | # -Kthread, if available, provides the right #defines |
| 5813 | # and linker options to make pthread_create available |
| 5814 | # Some compilers won't report that they do not support -Kthread, |
| 5815 | # so we need to run a program to see whether it really made the |
| 5816 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5817 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 5818 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5819 | if ${ac_cv_kthread+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5820 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5821 | else |
| 5822 | ac_save_cc="$CC" |
| 5823 | CC="$CC -Kthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5824 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5825 | ac_cv_kthread=no |
| 5826 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5828 | /* end confdefs.h. */ |
| 5829 | |
| 5830 | #include <pthread.h> |
| 5831 | |
| 5832 | void* routine(void* p){return NULL;} |
| 5833 | |
| 5834 | int main(){ |
| 5835 | pthread_t p; |
| 5836 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5837 | return 1; |
| 5838 | (void)pthread_detach(p); |
| 5839 | return 0; |
| 5840 | } |
| 5841 | |
| 5842 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5843 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5844 | ac_cv_kthread=yes |
| 5845 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5846 | ac_cv_kthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5847 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5848 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5849 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5850 | fi |
| 5851 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5852 | CC="$ac_save_cc" |
| 5853 | fi |
| 5854 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 5856 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5857 | fi |
| 5858 | |
| 5859 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 5860 | then |
| 5861 | # -pthread, if available, provides the right #defines |
| 5862 | # and linker options to make pthread_create available |
| 5863 | # Some compilers won't report that they do not support -pthread, |
| 5864 | # so we need to run a program to see whether it really made the |
| 5865 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5866 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 5867 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5868 | if ${ac_cv_thread+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5869 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5870 | else |
| 5871 | ac_save_cc="$CC" |
| 5872 | CC="$CC -pthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5873 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5874 | ac_cv_pthread=no |
| 5875 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5876 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5877 | /* end confdefs.h. */ |
| 5878 | |
| 5879 | #include <pthread.h> |
| 5880 | |
| 5881 | void* routine(void* p){return NULL;} |
| 5882 | |
| 5883 | int main(){ |
| 5884 | pthread_t p; |
| 5885 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5886 | return 1; |
| 5887 | (void)pthread_detach(p); |
| 5888 | return 0; |
| 5889 | } |
| 5890 | |
| 5891 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5892 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5893 | ac_cv_pthread=yes |
| 5894 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5895 | ac_cv_pthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5896 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5897 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5898 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5899 | fi |
| 5900 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5901 | CC="$ac_save_cc" |
| 5902 | fi |
| 5903 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5904 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 5905 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5906 | fi |
| 5907 | |
| 5908 | # If we have set a CC compiler flag for thread support then |
| 5909 | # check if it works for CXX, too. |
| 5910 | ac_cv_cxx_thread=no |
| 5911 | if test ! -z "$CXX" |
| 5912 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5913 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 5914 | $as_echo_n "checking whether $CXX also accepts flags for thread support... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5915 | ac_save_cxx="$CXX" |
| 5916 | |
| 5917 | if test "$ac_cv_kpthread" = "yes" |
| 5918 | then |
| 5919 | CXX="$CXX -Kpthread" |
| 5920 | ac_cv_cxx_thread=yes |
| 5921 | elif test "$ac_cv_kthread" = "yes" |
| 5922 | then |
| 5923 | CXX="$CXX -Kthread" |
| 5924 | ac_cv_cxx_thread=yes |
| 5925 | elif test "$ac_cv_pthread" = "yes" |
| 5926 | then |
| 5927 | CXX="$CXX -pthread" |
| 5928 | ac_cv_cxx_thread=yes |
| 5929 | fi |
| 5930 | |
| 5931 | if test $ac_cv_cxx_thread = yes |
| 5932 | then |
| 5933 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 5934 | $CXX -c conftest.$ac_ext 2>&5 |
| 5935 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 5936 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 5937 | then |
| 5938 | ac_cv_cxx_thread=yes |
| 5939 | else |
| 5940 | ac_cv_cxx_thread=no |
| 5941 | fi |
| 5942 | rm -fr conftest* |
| 5943 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5944 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 5945 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5946 | fi |
| 5947 | CXX="$ac_save_cxx" |
| 5948 | |
| 5949 | |
| 5950 | # checks for header files |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5951 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5952 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 5953 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5954 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5955 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5956 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5957 | /* end confdefs.h. */ |
| 5958 | #include <stdlib.h> |
| 5959 | #include <stdarg.h> |
| 5960 | #include <string.h> |
| 5961 | #include <float.h> |
| 5962 | |
| 5963 | int |
| 5964 | main () |
| 5965 | { |
| 5966 | |
| 5967 | ; |
| 5968 | return 0; |
| 5969 | } |
| 5970 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5971 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5972 | ac_cv_header_stdc=yes |
| 5973 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5974 | ac_cv_header_stdc=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5975 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5976 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5977 | |
| 5978 | if test $ac_cv_header_stdc = yes; then |
| 5979 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5980 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5981 | /* end confdefs.h. */ |
| 5982 | #include <string.h> |
| 5983 | |
| 5984 | _ACEOF |
| 5985 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5986 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 5987 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5988 | else |
| 5989 | ac_cv_header_stdc=no |
| 5990 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 5991 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5992 | |
| 5993 | fi |
| 5994 | |
| 5995 | if test $ac_cv_header_stdc = yes; then |
| 5996 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5997 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5998 | /* end confdefs.h. */ |
| 5999 | #include <stdlib.h> |
| 6000 | |
| 6001 | _ACEOF |
| 6002 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6003 | $EGREP "free" >/dev/null 2>&1; then : |
| 6004 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6005 | else |
| 6006 | ac_cv_header_stdc=no |
| 6007 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6008 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6009 | |
| 6010 | fi |
| 6011 | |
| 6012 | if test $ac_cv_header_stdc = yes; then |
| 6013 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6014 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6015 | : |
| 6016 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6017 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6018 | /* end confdefs.h. */ |
| 6019 | #include <ctype.h> |
| 6020 | #include <stdlib.h> |
| 6021 | #if ((' ' & 0x0FF) == 0x020) |
| 6022 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 6023 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 6024 | #else |
| 6025 | # define ISLOWER(c) \ |
| 6026 | (('a' <= (c) && (c) <= 'i') \ |
| 6027 | || ('j' <= (c) && (c) <= 'r') \ |
| 6028 | || ('s' <= (c) && (c) <= 'z')) |
| 6029 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 6030 | #endif |
| 6031 | |
| 6032 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 6033 | int |
| 6034 | main () |
| 6035 | { |
| 6036 | int i; |
| 6037 | for (i = 0; i < 256; i++) |
| 6038 | if (XOR (islower (i), ISLOWER (i)) |
| 6039 | || toupper (i) != TOUPPER (i)) |
| 6040 | return 2; |
| 6041 | return 0; |
| 6042 | } |
| 6043 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6044 | if ac_fn_c_try_run "$LINENO"; then : |
| 6045 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6046 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6047 | ac_cv_header_stdc=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6048 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6049 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6050 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6051 | fi |
| 6052 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6053 | fi |
| 6054 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 6056 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6057 | if test $ac_cv_header_stdc = yes; then |
| 6058 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6059 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6060 | |
| 6061 | fi |
| 6062 | |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6063 | for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ |
| 6064 | fcntl.h grp.h \ |
Neal Norwitz | 9fdfaaf | 2008-03-28 05:34:59 +0000 | [diff] [blame] | 6065 | ieeefp.h io.h langinfo.h libintl.h ncurses.h poll.h process.h pthread.h \ |
Martin v. Löwis | 40e9aed | 2006-10-02 15:20:37 +0000 | [diff] [blame] | 6066 | shadow.h signal.h stdint.h stropts.h termios.h thread.h \ |
Martin v. Löwis | 14e73b1 | 2003-01-01 09:51:12 +0000 | [diff] [blame] | 6067 | unistd.h utime.h \ |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 6068 | sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \ |
| 6069 | sys/lock.h sys/mkdev.h sys/modem.h \ |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6070 | sys/param.h sys/poll.h sys/select.h sys/socket.h sys/statvfs.h sys/stat.h \ |
Martin v. Löwis | 8c255e4 | 2008-05-23 15:06:50 +0000 | [diff] [blame] | 6071 | sys/termio.h sys/time.h \ |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6072 | sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
Martin v. Löwis | 0347a9a | 2006-10-27 07:06:52 +0000 | [diff] [blame] | 6073 | sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 6074 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6075 | do : |
| 6076 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6077 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6078 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6079 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6080 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6081 | _ACEOF |
| 6082 | |
| 6083 | fi |
| 6084 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6085 | done |
| 6086 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6087 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6088 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6089 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 6090 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 6091 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6092 | if eval \${$as_ac_Header+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6093 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6094 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6095 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6096 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6097 | #include <sys/types.h> |
| 6098 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6099 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6100 | int |
| 6101 | main () |
| 6102 | { |
| 6103 | if ((DIR *) 0) |
| 6104 | return 0; |
| 6105 | ; |
| 6106 | return 0; |
| 6107 | } |
| 6108 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6109 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6110 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6111 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6112 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6113 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6114 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6115 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6116 | eval ac_res=\$$as_ac_Header |
| 6117 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 6118 | $as_echo "$ac_res" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6119 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6120 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6121 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6122 | _ACEOF |
| 6123 | |
| 6124 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6125 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6126 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6127 | done |
| 6128 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 6129 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6130 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6131 | $as_echo_n "checking for library containing opendir... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6132 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6133 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6134 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6135 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6136 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6137 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6138 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6139 | /* Override any GCC internal prototype to avoid an error. |
| 6140 | Use char because int might match the return type of a GCC |
| 6141 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6142 | #ifdef __cplusplus |
| 6143 | extern "C" |
| 6144 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6145 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6146 | int |
| 6147 | main () |
| 6148 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6149 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6150 | ; |
| 6151 | return 0; |
| 6152 | } |
| 6153 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6154 | for ac_lib in '' dir; do |
| 6155 | if test -z "$ac_lib"; then |
| 6156 | ac_res="none required" |
| 6157 | else |
| 6158 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6159 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6160 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6161 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6162 | ac_cv_search_opendir=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 6163 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6164 | rm -f core conftest.err conftest.$ac_objext \ |
| 6165 | conftest$ac_exeext |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6166 | if ${ac_cv_search_opendir+:} false; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6167 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6168 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6169 | done |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6170 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6171 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6172 | else |
| 6173 | ac_cv_search_opendir=no |
| 6174 | fi |
| 6175 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6176 | LIBS=$ac_func_search_save_LIBS |
| 6177 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6179 | $as_echo "$ac_cv_search_opendir" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6180 | ac_res=$ac_cv_search_opendir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6181 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6182 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6183 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6184 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6185 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6186 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6187 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6188 | $as_echo_n "checking for library containing opendir... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6189 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6190 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6191 | else |
| 6192 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6193 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6194 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6195 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6196 | /* Override any GCC internal prototype to avoid an error. |
| 6197 | Use char because int might match the return type of a GCC |
| 6198 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6199 | #ifdef __cplusplus |
| 6200 | extern "C" |
| 6201 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6202 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6203 | int |
| 6204 | main () |
| 6205 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6206 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6207 | ; |
| 6208 | return 0; |
| 6209 | } |
| 6210 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6211 | for ac_lib in '' x; do |
| 6212 | if test -z "$ac_lib"; then |
| 6213 | ac_res="none required" |
| 6214 | else |
| 6215 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6216 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6217 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6218 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6219 | ac_cv_search_opendir=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 6220 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6221 | rm -f core conftest.err conftest.$ac_objext \ |
| 6222 | conftest$ac_exeext |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6223 | if ${ac_cv_search_opendir+:} false; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6224 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6225 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6226 | done |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6227 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6228 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6229 | else |
| 6230 | ac_cv_search_opendir=no |
| 6231 | fi |
| 6232 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6233 | LIBS=$ac_func_search_save_LIBS |
| 6234 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6235 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6236 | $as_echo "$ac_cv_search_opendir" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6237 | ac_res=$ac_cv_search_opendir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6238 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6239 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6240 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6241 | fi |
| 6242 | |
| 6243 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6244 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 6246 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6247 | if ${ac_cv_header_sys_types_h_makedev+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6248 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6249 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6250 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6251 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6252 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6253 | int |
| 6254 | main () |
| 6255 | { |
| 6256 | return makedev(0, 0); |
| 6257 | ; |
| 6258 | return 0; |
| 6259 | } |
| 6260 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6261 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6262 | ac_cv_header_sys_types_h_makedev=yes |
| 6263 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6264 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6265 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6266 | rm -f core conftest.err conftest.$ac_objext \ |
| 6267 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6268 | |
| 6269 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6270 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 6271 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6272 | |
| 6273 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6274 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6275 | if test "x$ac_cv_header_sys_mkdev_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6276 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6277 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6278 | |
| 6279 | fi |
| 6280 | |
| 6281 | |
| 6282 | |
| 6283 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6284 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6285 | if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6286 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6287 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6288 | |
| 6289 | fi |
| 6290 | |
| 6291 | |
| 6292 | fi |
| 6293 | fi |
| 6294 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6295 | |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6296 | # On Solaris, term.h requires curses.h |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6297 | for ac_header in term.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6298 | do : |
| 6299 | ac_fn_c_check_header_compile "$LINENO" "term.h" "ac_cv_header_term_h" " |
Martin v. Löwis | 5d52e78 | 2004-09-18 10:07:03 +0000 | [diff] [blame] | 6300 | #ifdef HAVE_CURSES_H |
| 6301 | #include <curses.h> |
| 6302 | #endif |
| 6303 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6304 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6305 | if test "x$ac_cv_header_term_h" = xyes; then : |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6306 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6307 | #define HAVE_TERM_H 1 |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6308 | _ACEOF |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6309 | |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6310 | fi |
| 6311 | |
| 6312 | done |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6313 | |
| 6314 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6315 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6316 | for ac_header in linux/netlink.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6317 | do : |
| 6318 | 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] | 6319 | #ifdef HAVE_ASM_TYPES_H |
| 6320 | #include <asm/types.h> |
| 6321 | #endif |
| 6322 | #ifdef HAVE_SYS_SOCKET_H |
| 6323 | #include <sys/socket.h> |
| 6324 | #endif |
| 6325 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6326 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6327 | 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] | 6328 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6329 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6330 | _ACEOF |
| 6331 | |
| 6332 | fi |
| 6333 | |
| 6334 | done |
| 6335 | |
| 6336 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6337 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6338 | was_it_defined=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6339 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 6340 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 6341 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6342 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6343 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6344 | |
| 6345 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6346 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6347 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6348 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6349 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6350 | |
| 6351 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6352 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6353 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6354 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6355 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6356 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6357 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6358 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 6359 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6360 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6361 | # Check whether using makedev requires defining _OSF_SOURCE |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6362 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 6363 | $as_echo_n "checking for makedev... " >&6; } |
| 6364 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6365 | /* end confdefs.h. */ |
Jesus Cea | 616de77 | 2010-04-28 10:32:30 +0000 | [diff] [blame] | 6366 | |
| 6367 | #if defined(MAJOR_IN_MKDEV) |
| 6368 | #include <sys/mkdev.h> |
| 6369 | #elif defined(MAJOR_IN_SYSMACROS) |
| 6370 | #include <sys/sysmacros.h> |
| 6371 | #else |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6372 | #include <sys/types.h> |
Jesus Cea | 616de77 | 2010-04-28 10:32:30 +0000 | [diff] [blame] | 6373 | #endif |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6374 | int |
| 6375 | main () |
| 6376 | { |
| 6377 | makedev(0, 0) |
| 6378 | ; |
| 6379 | return 0; |
| 6380 | } |
| 6381 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6382 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6383 | ac_cv_has_makedev=yes |
| 6384 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6385 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6386 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6387 | rm -f core conftest.err conftest.$ac_objext \ |
| 6388 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6389 | if test "$ac_cv_has_makedev" = "no"; then |
| 6390 | # we didn't link, try if _OSF_SOURCE will allow us to link |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6392 | /* end confdefs.h. */ |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6393 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6394 | #define _OSF_SOURCE 1 |
| 6395 | #include <sys/types.h> |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6396 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6397 | int |
| 6398 | main () |
| 6399 | { |
| 6400 | makedev(0, 0) |
| 6401 | ; |
| 6402 | return 0; |
| 6403 | } |
| 6404 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6405 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6406 | ac_cv_has_makedev=yes |
| 6407 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6408 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6409 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6410 | rm -f core conftest.err conftest.$ac_objext \ |
| 6411 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6412 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6413 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6414 | $as_echo "#define _OSF_SOURCE 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6415 | |
| 6416 | fi |
| 6417 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6418 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 6419 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6420 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6421 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6422 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6423 | |
| 6424 | fi |
| 6425 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6426 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 6427 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 6428 | # defined, but the compiler does not support pragma redefine_extname, |
| 6429 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 6430 | # structures (such as rlimit64) without declaring them. As a |
| 6431 | # work-around, disable LFS on such configurations |
| 6432 | |
| 6433 | use_lfs=yes |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 6435 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 6436 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6437 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6438 | |
| 6439 | #define _LARGEFILE_SOURCE 1 |
| 6440 | #define _FILE_OFFSET_BITS 64 |
| 6441 | #include <sys/resource.h> |
| 6442 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6443 | int |
| 6444 | main () |
| 6445 | { |
| 6446 | struct rlimit foo; |
| 6447 | ; |
| 6448 | return 0; |
| 6449 | } |
| 6450 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6451 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6452 | sol_lfs_bug=no |
| 6453 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6454 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6455 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6456 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6457 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 6458 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6459 | if test "$sol_lfs_bug" = "yes"; then |
| 6460 | use_lfs=no |
| 6461 | fi |
| 6462 | |
| 6463 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6464 | # Two defines needed to enable largefile support on various platforms |
| 6465 | # These may affect some typedefs |
Georg Brandl | 94800df | 2011-02-25 11:09:02 +0000 | [diff] [blame] | 6466 | case $ac_sys_system/$ac_sys_release in |
| 6467 | AIX*) |
| 6468 | |
| 6469 | $as_echo "#define _LARGE_FILES 1" >>confdefs.h |
| 6470 | |
| 6471 | ;; |
| 6472 | esac |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6473 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6474 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6475 | |
| 6476 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6477 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6478 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6479 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6480 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 6481 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 6482 | cat >> confdefs.h <<\EOF |
| 6483 | #if defined(SCO_DS) |
| 6484 | #undef _OFF_T |
| 6485 | #endif |
| 6486 | EOF |
| 6487 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6488 | # Type availability checks |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6489 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6490 | if test "x$ac_cv_type_mode_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6491 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6492 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6493 | |
| 6494 | cat >>confdefs.h <<_ACEOF |
| 6495 | #define mode_t int |
| 6496 | _ACEOF |
| 6497 | |
| 6498 | fi |
| 6499 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6500 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6501 | if test "x$ac_cv_type_off_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6502 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6503 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6504 | |
| 6505 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6506 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6507 | _ACEOF |
| 6508 | |
| 6509 | fi |
| 6510 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6511 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6512 | if test "x$ac_cv_type_pid_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6513 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6514 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6515 | |
| 6516 | cat >>confdefs.h <<_ACEOF |
| 6517 | #define pid_t int |
| 6518 | _ACEOF |
| 6519 | |
| 6520 | fi |
| 6521 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6522 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6523 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | cbf54b1 | 2010-05-08 11:04:18 +0000 | [diff] [blame] | 6524 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6525 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6526 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6527 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6528 | if test "x$ac_cv_type_size_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6529 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6530 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6531 | |
| 6532 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6533 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6534 | _ACEOF |
| 6535 | |
| 6536 | fi |
| 6537 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6538 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 6539 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6540 | if ${ac_cv_type_uid_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6541 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6542 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6543 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6544 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6545 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6546 | |
| 6547 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6548 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6549 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6550 | ac_cv_type_uid_t=yes |
| 6551 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6552 | ac_cv_type_uid_t=no |
| 6553 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6554 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6555 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6556 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6557 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 6558 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6559 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6560 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6561 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6562 | |
| 6563 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6564 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6565 | |
| 6566 | fi |
| 6567 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6568 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 6569 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6570 | no|yes) ;; #( |
| 6571 | *) |
| 6572 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6573 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6574 | |
| 6575 | |
| 6576 | cat >>confdefs.h <<_ACEOF |
| 6577 | #define uint32_t $ac_cv_c_uint32_t |
| 6578 | _ACEOF |
| 6579 | ;; |
| 6580 | esac |
| 6581 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6582 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 6583 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6584 | no|yes) ;; #( |
| 6585 | *) |
| 6586 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6587 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6588 | |
| 6589 | |
| 6590 | cat >>confdefs.h <<_ACEOF |
| 6591 | #define uint64_t $ac_cv_c_uint64_t |
| 6592 | _ACEOF |
| 6593 | ;; |
| 6594 | esac |
| 6595 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6596 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 6597 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6598 | no|yes) ;; #( |
| 6599 | *) |
| 6600 | |
| 6601 | cat >>confdefs.h <<_ACEOF |
| 6602 | #define int32_t $ac_cv_c_int32_t |
| 6603 | _ACEOF |
| 6604 | ;; |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6605 | esac |
| 6606 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6607 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 6608 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6609 | no|yes) ;; #( |
| 6610 | *) |
| 6611 | |
| 6612 | cat >>confdefs.h <<_ACEOF |
| 6613 | #define int64_t $ac_cv_c_int64_t |
| 6614 | _ACEOF |
| 6615 | ;; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6616 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6617 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6618 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6619 | if test "x$ac_cv_type_ssize_t" = xyes; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6620 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6621 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6622 | |
| 6623 | fi |
| 6624 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 6625 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6626 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 6627 | # ANSI C requires sizeof(char) == 1, so no need to check it |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6628 | # The cast to long int works around a bug in the HP C Compiler |
| 6629 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6630 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6631 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6632 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 6633 | $as_echo_n "checking size of int... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6634 | if ${ac_cv_sizeof_int+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6635 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6636 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6637 | 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] | 6638 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6639 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6640 | if test "$ac_cv_type_int" = yes; then |
| 6641 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6642 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6643 | as_fn_error 77 "cannot compute sizeof (int) |
| 6644 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6645 | else |
| 6646 | ac_cv_sizeof_int=0 |
| 6647 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6648 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6649 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6650 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6651 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 6652 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6653 | |
| 6654 | |
| 6655 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6656 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6657 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6658 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6659 | |
| 6660 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6661 | # The cast to long int works around a bug in the HP C Compiler |
| 6662 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6663 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6664 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6665 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 6666 | $as_echo_n "checking size of long... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6667 | if ${ac_cv_sizeof_long+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6668 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6669 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6670 | 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] | 6671 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6672 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6673 | if test "$ac_cv_type_long" = yes; then |
| 6674 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6675 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6676 | as_fn_error 77 "cannot compute sizeof (long) |
| 6677 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6678 | else |
| 6679 | ac_cv_sizeof_long=0 |
| 6680 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6681 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6682 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6683 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6684 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 6685 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6686 | |
| 6687 | |
| 6688 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6689 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6690 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6691 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6692 | |
| 6693 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6694 | # The cast to long int works around a bug in the HP C Compiler |
| 6695 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6696 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6697 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6698 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 6699 | $as_echo_n "checking size of void *... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6700 | if ${ac_cv_sizeof_void_p+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6701 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6702 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6703 | 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] | 6704 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6705 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6706 | if test "$ac_cv_type_void_p" = yes; then |
| 6707 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6708 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6709 | as_fn_error 77 "cannot compute sizeof (void *) |
| 6710 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6711 | else |
| 6712 | ac_cv_sizeof_void_p=0 |
| 6713 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6714 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6715 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6716 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 6718 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6719 | |
| 6720 | |
| 6721 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6722 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6723 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6724 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6725 | |
| 6726 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6727 | # The cast to long int works around a bug in the HP C Compiler |
| 6728 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6729 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6730 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 6732 | $as_echo_n "checking size of short... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6733 | if ${ac_cv_sizeof_short+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6734 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6735 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6736 | 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] | 6737 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6738 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6739 | if test "$ac_cv_type_short" = yes; then |
| 6740 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6741 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6742 | as_fn_error 77 "cannot compute sizeof (short) |
| 6743 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6744 | else |
| 6745 | ac_cv_sizeof_short=0 |
| 6746 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6747 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6748 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6749 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 6751 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6752 | |
| 6753 | |
| 6754 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6755 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6756 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6757 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6758 | |
| 6759 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6760 | # The cast to long int works around a bug in the HP C Compiler |
| 6761 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6762 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6763 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6764 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 6765 | $as_echo_n "checking size of float... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6766 | if ${ac_cv_sizeof_float+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6767 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6768 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6769 | 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] | 6770 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6771 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6772 | if test "$ac_cv_type_float" = yes; then |
| 6773 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6774 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6775 | as_fn_error 77 "cannot compute sizeof (float) |
| 6776 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6777 | else |
| 6778 | ac_cv_sizeof_float=0 |
| 6779 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6780 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6781 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6782 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6783 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 6784 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6785 | |
| 6786 | |
| 6787 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6788 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6789 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6790 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6791 | |
| 6792 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6793 | # The cast to long int works around a bug in the HP C Compiler |
| 6794 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6795 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6796 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6797 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 6798 | $as_echo_n "checking size of double... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6799 | if ${ac_cv_sizeof_double+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6800 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6801 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6802 | 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] | 6803 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6804 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6805 | if test "$ac_cv_type_double" = yes; then |
| 6806 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6807 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6808 | as_fn_error 77 "cannot compute sizeof (double) |
| 6809 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6810 | else |
| 6811 | ac_cv_sizeof_double=0 |
| 6812 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6813 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6814 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6815 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 6817 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6818 | |
| 6819 | |
| 6820 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6821 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6822 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6823 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6824 | |
| 6825 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6826 | # The cast to long int works around a bug in the HP C Compiler |
| 6827 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6828 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6829 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6830 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 6831 | $as_echo_n "checking size of fpos_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6832 | if ${ac_cv_sizeof_fpos_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6833 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6834 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6835 | 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] | 6836 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6837 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6838 | if test "$ac_cv_type_fpos_t" = yes; then |
| 6839 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6840 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6841 | as_fn_error 77 "cannot compute sizeof (fpos_t) |
| 6842 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6843 | else |
| 6844 | ac_cv_sizeof_fpos_t=0 |
| 6845 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6846 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6847 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6848 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6849 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 6850 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6851 | |
| 6852 | |
| 6853 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6854 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6855 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6856 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6857 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6858 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6859 | # The cast to long int works around a bug in the HP C Compiler |
| 6860 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6861 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6862 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6863 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 6864 | $as_echo_n "checking size of size_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6865 | if ${ac_cv_sizeof_size_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6866 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6867 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6868 | 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] | 6869 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6870 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6871 | if test "$ac_cv_type_size_t" = yes; then |
| 6872 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6873 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6874 | as_fn_error 77 "cannot compute sizeof (size_t) |
| 6875 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6876 | else |
| 6877 | ac_cv_sizeof_size_t=0 |
| 6878 | fi |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6879 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6880 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6881 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6882 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 |
| 6883 | $as_echo "$ac_cv_sizeof_size_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6884 | |
| 6885 | |
| 6886 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6887 | cat >>confdefs.h <<_ACEOF |
| 6888 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t |
| 6889 | _ACEOF |
| 6890 | |
| 6891 | |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6892 | # The cast to long int works around a bug in the HP C Compiler |
| 6893 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6894 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6895 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6896 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5 |
| 6897 | $as_echo_n "checking size of pid_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6898 | if ${ac_cv_sizeof_pid_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6899 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6900 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6901 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pid_t))" "ac_cv_sizeof_pid_t" "$ac_includes_default"; then : |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6902 | |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6903 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6904 | if test "$ac_cv_type_pid_t" = yes; then |
| 6905 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6906 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6907 | as_fn_error 77 "cannot compute sizeof (pid_t) |
| 6908 | See \`config.log' for more details" "$LINENO" 5; } |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6909 | else |
| 6910 | ac_cv_sizeof_pid_t=0 |
| 6911 | fi |
| 6912 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6913 | |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6914 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6915 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 6916 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6917 | |
| 6918 | |
| 6919 | |
| 6920 | cat >>confdefs.h <<_ACEOF |
| 6921 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 6922 | _ACEOF |
| 6923 | |
| 6924 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6925 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6926 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 6927 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6928 | have_long_long=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6929 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6930 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6931 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6932 | int |
| 6933 | main () |
| 6934 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6935 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6936 | ; |
| 6937 | return 0; |
| 6938 | } |
| 6939 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6940 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6941 | |
| 6942 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6943 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6944 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6945 | have_long_long=yes |
| 6946 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6947 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6948 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 6950 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 6951 | if test "$have_long_long" = yes ; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6952 | # The cast to long int works around a bug in the HP C Compiler |
| 6953 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6954 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6955 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6956 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 6957 | $as_echo_n "checking size of long long... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6958 | if ${ac_cv_sizeof_long_long+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6959 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6960 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6961 | 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] | 6962 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6963 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6964 | if test "$ac_cv_type_long_long" = yes; then |
| 6965 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6966 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 6967 | as_fn_error 77 "cannot compute sizeof (long long) |
| 6968 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6969 | else |
| 6970 | ac_cv_sizeof_long_long=0 |
| 6971 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6972 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6973 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6974 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 6976 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6977 | |
| 6978 | |
| 6979 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6980 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6981 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6982 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6983 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6984 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6985 | fi |
| 6986 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6987 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 6988 | $as_echo_n "checking for long double support... " >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6989 | have_long_double=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6990 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6991 | /* end confdefs.h. */ |
| 6992 | |
| 6993 | int |
| 6994 | main () |
| 6995 | { |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 6996 | long double x; x = (long double)0; |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6997 | ; |
| 6998 | return 0; |
| 6999 | } |
| 7000 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7001 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7002 | |
| 7003 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7004 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7005 | |
| 7006 | have_long_double=yes |
| 7007 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7008 | fi |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7009 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7010 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 7011 | $as_echo "$have_long_double" >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7012 | if test "$have_long_double" = yes ; then |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7013 | # The cast to long int works around a bug in the HP C Compiler |
| 7014 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7015 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7016 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7017 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 7018 | $as_echo_n "checking size of long double... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7019 | if ${ac_cv_sizeof_long_double+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7020 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7021 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7022 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double" "$ac_includes_default"; then : |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7023 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7024 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7025 | if test "$ac_cv_type_long_double" = yes; then |
| 7026 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7027 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7028 | as_fn_error 77 "cannot compute sizeof (long double) |
| 7029 | See \`config.log' for more details" "$LINENO" 5; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7030 | else |
| 7031 | ac_cv_sizeof_long_double=0 |
| 7032 | fi |
| 7033 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7034 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7035 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7036 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 7037 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7038 | |
| 7039 | |
| 7040 | |
| 7041 | cat >>confdefs.h <<_ACEOF |
| 7042 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 7043 | _ACEOF |
| 7044 | |
| 7045 | |
| 7046 | fi |
| 7047 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7048 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 7049 | $as_echo_n "checking for _Bool support... " >&6; } |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7050 | have_c99_bool=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7051 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7052 | /* end confdefs.h. */ |
| 7053 | |
| 7054 | int |
| 7055 | main () |
| 7056 | { |
| 7057 | _Bool x; x = (_Bool)0; |
| 7058 | ; |
| 7059 | return 0; |
| 7060 | } |
| 7061 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7062 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7063 | |
| 7064 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7065 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7066 | |
| 7067 | have_c99_bool=yes |
| 7068 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7069 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7070 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7071 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 7072 | $as_echo "$have_c99_bool" >&6; } |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7073 | if test "$have_c99_bool" = yes ; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7074 | # The cast to long int works around a bug in the HP C Compiler |
| 7075 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7076 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7077 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7078 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 7079 | $as_echo_n "checking size of _Bool... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7080 | if ${ac_cv_sizeof__Bool+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7081 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7082 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7083 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (_Bool))" "ac_cv_sizeof__Bool" "$ac_includes_default"; then : |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7084 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7085 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7086 | if test "$ac_cv_type__Bool" = yes; then |
| 7087 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7088 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7089 | as_fn_error 77 "cannot compute sizeof (_Bool) |
| 7090 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7091 | else |
| 7092 | ac_cv_sizeof__Bool=0 |
| 7093 | fi |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7094 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7095 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7096 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 7098 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7099 | |
| 7100 | |
| 7101 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7102 | cat >>confdefs.h <<_ACEOF |
| 7103 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 7104 | _ACEOF |
| 7105 | |
| 7106 | |
| 7107 | fi |
| 7108 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7109 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "#ifdef HAVE_STDINT_H |
Martin v. Löwis | 40e9aed | 2006-10-02 15:20:37 +0000 | [diff] [blame] | 7110 | #include <stdint.h> |
| 7111 | #endif |
Antoine Pitrou | 7be5a65 | 2010-10-10 08:14:41 +0000 | [diff] [blame] | 7112 | #ifdef HAVE_INTTYPES_H |
| 7113 | #include <inttypes.h> |
| 7114 | #endif |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7115 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7116 | if test "x$ac_cv_type_uintptr_t" = xyes; then : |
Martin v. Löwis | ebe2670 | 2006-10-02 14:55:51 +0000 | [diff] [blame] | 7117 | |
| 7118 | cat >>confdefs.h <<_ACEOF |
| 7119 | #define HAVE_UINTPTR_T 1 |
| 7120 | _ACEOF |
| 7121 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7122 | # The cast to long int works around a bug in the HP C Compiler |
| 7123 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7124 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7125 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7126 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 7127 | $as_echo_n "checking size of uintptr_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7128 | if ${ac_cv_sizeof_uintptr_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7129 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7130 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7131 | 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] | 7132 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7133 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7134 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 7135 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7136 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7137 | as_fn_error 77 "cannot compute sizeof (uintptr_t) |
| 7138 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7139 | else |
| 7140 | ac_cv_sizeof_uintptr_t=0 |
| 7141 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7142 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7143 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7144 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 7146 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7147 | |
| 7148 | |
| 7149 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7150 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7151 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7152 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7153 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7154 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7155 | fi |
| 7156 | |
Martin v. Löwis | ebe2670 | 2006-10-02 14:55:51 +0000 | [diff] [blame] | 7157 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7158 | # The cast to long int works around a bug in the HP C Compiler |
| 7159 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7160 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7161 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7162 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 7163 | $as_echo_n "checking size of off_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7164 | if ${ac_cv_sizeof_off_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7165 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7166 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7167 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" " |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7168 | #ifdef HAVE_SYS_TYPES_H |
| 7169 | #include <sys/types.h> |
| 7170 | #endif |
| 7171 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7172 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7173 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7174 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7175 | if test "$ac_cv_type_off_t" = yes; then |
| 7176 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7177 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7178 | as_fn_error 77 "cannot compute sizeof (off_t) |
| 7179 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7180 | else |
| 7181 | ac_cv_sizeof_off_t=0 |
| 7182 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7183 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7184 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7185 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7186 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 7187 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7188 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7189 | |
| 7190 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7191 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7192 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7193 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7194 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7195 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7196 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 7198 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7199 | if test "$have_long_long" = yes |
| 7200 | then |
| 7201 | 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] | 7202 | "$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] | 7203 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7204 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7205 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7206 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7207 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7208 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7210 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7211 | fi |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7212 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7213 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7214 | $as_echo "no" >&6; } |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7215 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7216 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7217 | # The cast to long int works around a bug in the HP C Compiler |
| 7218 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7219 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7220 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 7222 | $as_echo_n "checking size of time_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7223 | if ${ac_cv_sizeof_time_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7224 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7225 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7226 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" " |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7227 | #ifdef HAVE_SYS_TYPES_H |
| 7228 | #include <sys/types.h> |
| 7229 | #endif |
| 7230 | #ifdef HAVE_TIME_H |
| 7231 | #include <time.h> |
| 7232 | #endif |
| 7233 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7234 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7235 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7236 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7237 | if test "$ac_cv_type_time_t" = yes; then |
| 7238 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7239 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7240 | as_fn_error 77 "cannot compute sizeof (time_t) |
| 7241 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7242 | else |
| 7243 | ac_cv_sizeof_time_t=0 |
| 7244 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7245 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7246 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7247 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7248 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 7249 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7250 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7251 | |
| 7252 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7253 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7254 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7255 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7256 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7257 | |
| 7258 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7259 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7260 | ac_save_cc="$CC" |
| 7261 | if test "$ac_cv_kpthread" = "yes" |
| 7262 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 7263 | elif test "$ac_cv_kthread" = "yes" |
| 7264 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 7265 | elif test "$ac_cv_pthread" = "yes" |
| 7266 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7267 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7268 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 7269 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7270 | have_pthread_t=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7271 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7272 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 7273 | |
| 7274 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7275 | int |
| 7276 | main () |
| 7277 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 7278 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7279 | ; |
| 7280 | return 0; |
| 7281 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 7282 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7283 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7284 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7285 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7286 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7287 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7288 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 7289 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7290 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7291 | # The cast to long int works around a bug in the HP C Compiler |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7292 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7293 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7294 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7295 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 7296 | $as_echo_n "checking size of pthread_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7297 | if ${ac_cv_sizeof_pthread_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7298 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7299 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7300 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" " |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7301 | #ifdef HAVE_PTHREAD_H |
| 7302 | #include <pthread.h> |
| 7303 | #endif |
| 7304 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7305 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7306 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7307 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7308 | if test "$ac_cv_type_pthread_t" = yes; then |
| 7309 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7310 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7311 | as_fn_error 77 "cannot compute sizeof (pthread_t) |
| 7312 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7313 | else |
| 7314 | ac_cv_sizeof_pthread_t=0 |
| 7315 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7316 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7317 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7318 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7319 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 7320 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7321 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7322 | |
| 7323 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7324 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7325 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7326 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7327 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7328 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7329 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7330 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7331 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7332 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-toolbox-glue" >&5 |
| 7333 | $as_echo_n "checking for --enable-toolbox-glue... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7334 | # Check whether --enable-toolbox-glue was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7335 | if test "${enable_toolbox_glue+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7336 | enableval=$enable_toolbox_glue; |
| 7337 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7338 | |
| 7339 | |
| 7340 | if test -z "$enable_toolbox_glue" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7341 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7342 | case $ac_sys_system/$ac_sys_release in |
| 7343 | Darwin/*) |
| 7344 | enable_toolbox_glue="yes";; |
| 7345 | *) |
| 7346 | enable_toolbox_glue="no";; |
| 7347 | esac |
| 7348 | fi |
| 7349 | case "$enable_toolbox_glue" in |
| 7350 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7351 | extra_machdep_objs="Python/mactoolboxglue.o" |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7352 | extra_undefs="-u _PyMac_Error" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7353 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7354 | $as_echo "#define USE_TOOLBOX_OBJECT_GLUE 1" >>confdefs.h |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7355 | |
| 7356 | ;; |
| 7357 | *) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7358 | extra_machdep_objs="" |
Jack Jansen | 591cbed | 2001-08-15 13:55:15 +0000 | [diff] [blame] | 7359 | extra_undefs="" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7360 | ;; |
| 7361 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7362 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_toolbox_glue" >&5 |
| 7363 | $as_echo "$enable_toolbox_glue" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7364 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7365 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 7366 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7367 | case $ac_sys_system/$ac_sys_release in |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 7368 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7369 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 7370 | ;; |
| 7371 | Darwin/*) |
| 7372 | OTHER_LIBTOOL_OPT="" |
| 7373 | ;; |
| 7374 | esac |
| 7375 | |
| 7376 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7377 | ARCH_RUN_32BIT="" |
| 7378 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7379 | case $ac_sys_system/$ac_sys_release in |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 7380 | Darwin/[01567]\..*) |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7381 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 7382 | if test "${enable_universalsdk}"; then |
| 7383 | : |
| 7384 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7385 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7386 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7387 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7388 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 7389 | Darwin/*) |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 7390 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7391 | if test ${gcc_version} '<' 4.0 |
| 7392 | then |
| 7393 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 7394 | else |
| 7395 | LIBTOOL_CRUFT="" |
| 7396 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7397 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7398 | ac_osx_32bit=yes |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7399 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7400 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7401 | /* end confdefs.h. */ |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7402 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7403 | #include <unistd.h> |
| 7404 | int main(int argc, char*argv[]) |
| 7405 | { |
| 7406 | if (sizeof(long) == 4) { |
| 7407 | return 0; |
| 7408 | } else { |
| 7409 | return 1; |
| 7410 | } |
Ronald Oussoren | 84ddd72 | 2009-09-08 07:17:10 +0000 | [diff] [blame] | 7411 | } |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7412 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7413 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7414 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7415 | ac_osx_32bit=yes |
| 7416 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7417 | ac_osx_32bit=no |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7418 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7419 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7420 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7421 | fi |
| 7422 | |
| 7423 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7424 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7425 | case `/usr/bin/arch` in |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7426 | i386) |
| 7427 | MACOSX_DEFAULT_ARCH="i386" |
| 7428 | ;; |
| 7429 | ppc) |
| 7430 | MACOSX_DEFAULT_ARCH="ppc" |
| 7431 | ;; |
| 7432 | *) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7433 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7434 | ;; |
| 7435 | esac |
| 7436 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7437 | case `/usr/bin/arch` in |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7438 | i386) |
| 7439 | MACOSX_DEFAULT_ARCH="x86_64" |
| 7440 | ;; |
| 7441 | ppc) |
| 7442 | MACOSX_DEFAULT_ARCH="ppc64" |
| 7443 | ;; |
| 7444 | *) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7445 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7446 | ;; |
| 7447 | esac |
| 7448 | |
| 7449 | #ARCH_RUN_32BIT="true" |
| 7450 | fi |
| 7451 | |
| 7452 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7453 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7454 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7455 | esac |
| 7456 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7457 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 7458 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7459 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7460 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 7461 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7462 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7463 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7464 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7465 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7466 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7468 | $as_echo "yes" >&6; } |
Ronald Oussoren | 450d561 | 2009-06-08 21:12:41 +0000 | [diff] [blame] | 7469 | if test $enable_shared = "yes" |
| 7470 | then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7471 | as_fn_error $? "Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead. See Mac/README." "$LINENO" 5 |
Ronald Oussoren | 450d561 | 2009-06-08 21:12:41 +0000 | [diff] [blame] | 7472 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7473 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7474 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7475 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7476 | fi |
| 7477 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7478 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 7479 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7480 | case $ac_sys_system/$ac_sys_release in |
| 7481 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7482 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7483 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7484 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 7486 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7487 | ;; |
| 7488 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7489 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7490 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7491 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7492 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7493 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7494 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7495 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7496 | |
| 7497 | |
| 7498 | |
| 7499 | |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7500 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7501 | # SO is the extension of shared libraries `(including the dot!) |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 7502 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7503 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5 |
| 7504 | $as_echo_n "checking SO... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7505 | if test -z "$SO" |
| 7506 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7507 | case $ac_sys_system in |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7508 | hp*|HP*) |
| 7509 | case `uname -m` in |
| 7510 | ia64) SO=.so;; |
| 7511 | *) SO=.sl;; |
| 7512 | esac |
| 7513 | ;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 7514 | CYGWIN*) SO=.dll;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 7515 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7516 | esac |
Martin v. Löwis | 368de8f | 2003-06-14 14:46:38 +0000 | [diff] [blame] | 7517 | else |
| 7518 | # this might also be a termcap variable, see #610332 |
| 7519 | echo |
| 7520 | echo '=====================================================================' |
| 7521 | echo '+ +' |
| 7522 | echo '+ WARNING: You have set SO in your environment. +' |
| 7523 | echo '+ Do you really mean to change the extension for shared libraries? +' |
| 7524 | echo '+ Continuing in 10 seconds to let you to ponder. +' |
| 7525 | echo '+ +' |
| 7526 | echo '=====================================================================' |
| 7527 | sleep 10 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7528 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7529 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5 |
| 7530 | $as_echo "$SO" >&6; } |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7531 | |
Ronald Oussoren | 79f9049 | 2009-01-02 10:44:46 +0000 | [diff] [blame] | 7532 | |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7533 | cat >>confdefs.h <<_ACEOF |
| 7534 | #define SHLIB_EXT "$SO" |
| 7535 | _ACEOF |
| 7536 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7537 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 7538 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7539 | # (Shared libraries in this instance are shared modules to be loaded into |
| 7540 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7541 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 7542 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7543 | if test -z "$LDSHARED" |
| 7544 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7545 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7546 | AIX*) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7547 | 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] | 7548 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7549 | ;; |
| 7550 | BeOS*) |
| 7551 | BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 7552 | LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7553 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7554 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7555 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7556 | SunOS/5*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7557 | if test "$GCC" = "yes" ; then |
| 7558 | LDSHARED='$(CC) -shared' |
| 7559 | LDCXXSHARED='$(CXX) -shared' |
| 7560 | else |
| 7561 | LDSHARED='$(CC) -G' |
| 7562 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a66 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 7563 | fi ;; |
Thomas Heller | dc96a77 | 2008-04-04 10:07:55 +0000 | [diff] [blame] | 7564 | hp*|HP*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7565 | if test "$GCC" = "yes" ; then |
| 7566 | LDSHARED='$(CC) -shared' |
| 7567 | LDCXXSHARED='$(CXX) -shared' |
| 7568 | else |
| 7569 | LDSHARED='ld -b' |
Thomas Heller | dc96a77 | 2008-04-04 10:07:55 +0000 | [diff] [blame] | 7570 | fi ;; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7571 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7572 | Darwin/1.3*) |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7573 | LDSHARED='$(CC) -bundle' |
| 7574 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7575 | if test "$enable_framework" ; then |
| 7576 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7577 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7578 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7579 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7580 | else |
| 7581 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7582 | LDSHARED="$LDSHARED -undefined suppress" |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7583 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7584 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7585 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7586 | LDSHARED='$(CC) -bundle' |
| 7587 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7588 | if test "$enable_framework" ; then |
| 7589 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7590 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7591 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7592 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7593 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 7594 | # No framework, use the Python app as bundle-loader |
| 7595 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 7596 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7597 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7598 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7599 | Darwin/*) |
| 7600 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 7601 | # This allows an extension to be used in any Python |
Ronald Oussoren | 38f1b98 | 2007-09-02 09:46:07 +0000 | [diff] [blame] | 7602 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 7603 | if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7604 | then |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7605 | if test "${enable_universalsdk}"; then |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 7606 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7607 | fi |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7608 | LDSHARED='$(CC) -bundle -undefined dynamic_lookup' |
| 7609 | LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7610 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7611 | else |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7612 | LDSHARED='$(CC) -bundle' |
| 7613 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7614 | if test "$enable_framework" ; then |
| 7615 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7616 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7617 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7618 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7619 | else |
| 7620 | # No framework, use the Python app as bundle-loader |
| 7621 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 7622 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7623 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7624 | fi |
| 7625 | fi |
| 7626 | ;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7627 | Linux*|GNU*|QNX*) |
| 7628 | LDSHARED='$(CC) -shared' |
| 7629 | LDCXXSHARED='$(CXX) -shared';; |
| 7630 | BSD/OS*/4*) |
| 7631 | LDSHARED="gcc -shared" |
| 7632 | LDCXXSHARED="g++ -shared";; |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7633 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 7634 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7635 | then |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7636 | LDSHARED='$(CC) -shared' |
| 7637 | LDCXXSHARED='$(CXX) -shared' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7638 | else |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7639 | LDSHARED="ld -Bshareable" |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7640 | fi;; |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7641 | OpenBSD*) |
| 7642 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7643 | then |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7644 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7645 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7646 | else |
| 7647 | case `uname -r` in |
| 7648 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 7649 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7650 | ;; |
| 7651 | *) |
Stefan Krah | 3a3e203 | 2010-11-28 15:30:05 +0000 | [diff] [blame] | 7652 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7653 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7654 | ;; |
| 7655 | esac |
| 7656 | fi;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7657 | NetBSD*|DragonFly*) |
Antoine Pitrou | cb40277 | 2011-01-02 20:51:34 +0000 | [diff] [blame] | 7658 | LDSHARED='$(CC) -shared' |
| 7659 | LDCXXSHARED='$(CXX) -shared';; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7660 | OpenUNIX*|UnixWare*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7661 | if test "$GCC" = "yes" ; then |
| 7662 | LDSHARED='$(CC) -shared' |
| 7663 | LDCXXSHARED='$(CXX) -shared' |
| 7664 | else |
| 7665 | LDSHARED='$(CC) -G' |
| 7666 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7667 | fi;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7668 | SCO_SV*) |
| 7669 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 7670 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 7671 | CYGWIN*) |
| 7672 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 7673 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
| 7674 | atheos*) |
| 7675 | LDSHARED="gcc -shared" |
| 7676 | LDCXXSHARED="g++ -shared";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7677 | *) LDSHARED="ld";; |
| 7678 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7679 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7680 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 7681 | $as_echo "$LDSHARED" >&6; } |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7682 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7683 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7684 | # 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] | 7685 | # library (module) -- this is only needed for a few systems |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7686 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 7687 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7688 | if test -z "$CCSHARED" |
| 7689 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7690 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7691 | SunOS*) if test "$GCC" = yes; |
Martin v. Löwis | eb62357 | 2007-03-12 10:50:39 +0000 | [diff] [blame] | 7692 | then CCSHARED="-fPIC"; |
| 7693 | elif test `uname -p` = sparc; |
| 7694 | then CCSHARED="-xcode=pic32"; |
| 7695 | else CCSHARED="-Kpic"; |
| 7696 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7697 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 7698 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7699 | else CCSHARED="+z"; |
| 7700 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7701 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7702 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7703 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7704 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7705 | if test "$GCC" = "yes" |
| 7706 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 7707 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7708 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7709 | SCO_SV*) |
| 7710 | if test "$GCC" = "yes" |
| 7711 | then CCSHARED="-fPIC" |
| 7712 | else CCSHARED="-Kpic -belf" |
| 7713 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7714 | IRIX*/6*) case $CC in |
| 7715 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 7716 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7717 | esac;; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7718 | atheos*) CCSHARED="-fPIC";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7719 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7720 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7721 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 7722 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7723 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7724 | # the python executable -- this is only needed for a few systems |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 7726 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7727 | if test -z "$LINKFORSHARED" |
| 7728 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7729 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7730 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7731 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 7732 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 7733 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7734 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7735 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7736 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7737 | Darwin/*) |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7738 | # -u _PyMac_Error is needed to pull in the mac toolbox glue, |
| 7739 | # which is |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7740 | # not used by the core itself but which needs to be in the core so |
| 7741 | # that dynamically loaded extension modules have access to it. |
Jack Jansen | 97e3f00 | 2003-02-23 22:59:01 +0000 | [diff] [blame] | 7742 | # -prebind is no longer used, because it actually seems to give a |
| 7743 | # slowdown in stead of a speedup, maybe due to the large number of |
| 7744 | # dynamic loads Python does. |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7745 | |
| 7746 | LINKFORSHARED="$extra_undefs" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7747 | if test "$enable_framework" |
| 7748 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7749 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7750 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7751 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7752 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7753 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 7754 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7755 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 7756 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7757 | then |
| 7758 | LINKFORSHARED="-Wl,--export-dynamic" |
| 7759 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7760 | SunOS/5*) case $CC in |
| 7761 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 7762 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 7763 | then |
| 7764 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7765 | fi;; |
| 7766 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 7767 | CYGWIN*) |
| 7768 | if test $enable_shared = "no" |
| 7769 | then |
| 7770 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 7771 | fi;; |
Martin v. Löwis | 8c255e4 | 2008-05-23 15:06:50 +0000 | [diff] [blame] | 7772 | QNX*) |
| 7773 | # -Wl,-E causes the symbols to be added to the dynamic |
| 7774 | # symbol table so that they can be found when a module |
| 7775 | # is loaded. -N 2048K causes the stack size to be set |
| 7776 | # to 2048 kilobytes so that the stack doesn't overflow |
| 7777 | # when running test_compile.py. |
| 7778 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7779 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7780 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 7782 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7783 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7784 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 7785 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7786 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 7787 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7788 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 7789 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 7790 | case $ac_sys_system in |
| 7791 | CYGWIN*) |
| 7792 | # Cygwin needs CCSHARED when building extension DLLs |
| 7793 | # but not when building the interpreter DLL. |
| 7794 | CFLAGSFORSHARED='';; |
| 7795 | *) |
| 7796 | CFLAGSFORSHARED='$(CCSHARED)' |
| 7797 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7798 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7799 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 7800 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7801 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7802 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 7803 | # library (with --enable-shared). |
| 7804 | # 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] | 7805 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 7806 | # if it is not required, since it creates a dependency of the shared library |
| 7807 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 7808 | # don't need to link LIBS explicitly. The default should be only changed |
| 7809 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7810 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7811 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 7812 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7813 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7814 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 7815 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7816 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 7818 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7819 | |
| 7820 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7821 | # checks for libraries |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 7823 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7824 | if ${ac_cv_lib_dl_dlopen+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7825 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7826 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7827 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7828 | LIBS="-ldl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7829 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7830 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7831 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7832 | /* Override any GCC internal prototype to avoid an error. |
| 7833 | Use char because int might match the return type of a GCC |
| 7834 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7835 | #ifdef __cplusplus |
| 7836 | extern "C" |
| 7837 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7838 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7839 | int |
| 7840 | main () |
| 7841 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7842 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7843 | ; |
| 7844 | return 0; |
| 7845 | } |
| 7846 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7847 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7848 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7849 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7850 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7851 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7852 | rm -f core conftest.err conftest.$ac_objext \ |
| 7853 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7854 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7855 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7856 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 7857 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7858 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7859 | cat >>confdefs.h <<_ACEOF |
| 7860 | #define HAVE_LIBDL 1 |
| 7861 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7862 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7863 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7864 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7865 | fi |
| 7866 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7867 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 7868 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7869 | if ${ac_cv_lib_dld_shl_load+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7870 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7871 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7872 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7873 | LIBS="-ldld $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7874 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7875 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7876 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7877 | /* Override any GCC internal prototype to avoid an error. |
| 7878 | Use char because int might match the return type of a GCC |
| 7879 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7880 | #ifdef __cplusplus |
| 7881 | extern "C" |
| 7882 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7883 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7884 | int |
| 7885 | main () |
| 7886 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7887 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7888 | ; |
| 7889 | return 0; |
| 7890 | } |
| 7891 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7892 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7893 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7894 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7895 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7896 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7897 | rm -f core conftest.err conftest.$ac_objext \ |
| 7898 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7899 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7900 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 7902 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7903 | 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] | 7904 | cat >>confdefs.h <<_ACEOF |
| 7905 | #define HAVE_LIBDLD 1 |
| 7906 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7907 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7908 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7909 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7910 | fi |
| 7911 | # Dynamic linking for HP-UX |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7912 | |
Ronald Oussoren | 79f9049 | 2009-01-02 10:44:46 +0000 | [diff] [blame] | 7913 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7914 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7915 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 7916 | $as_echo_n "checking for library containing sem_init... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7917 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7918 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7919 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7920 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7921 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7922 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7923 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7924 | /* Override any GCC internal prototype to avoid an error. |
| 7925 | Use char because int might match the return type of a GCC |
| 7926 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7927 | #ifdef __cplusplus |
| 7928 | extern "C" |
| 7929 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7930 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7931 | int |
| 7932 | main () |
| 7933 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7934 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7935 | ; |
| 7936 | return 0; |
| 7937 | } |
| 7938 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7939 | for ac_lib in '' pthread rt posix4; do |
| 7940 | if test -z "$ac_lib"; then |
| 7941 | ac_res="none required" |
| 7942 | else |
| 7943 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 7944 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7945 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7946 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7947 | ac_cv_search_sem_init=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 7948 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7949 | rm -f core conftest.err conftest.$ac_objext \ |
| 7950 | conftest$ac_exeext |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7951 | if ${ac_cv_search_sem_init+:} false; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7952 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 7953 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7954 | done |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7955 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7956 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7957 | else |
| 7958 | ac_cv_search_sem_init=no |
| 7959 | fi |
| 7960 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7961 | LIBS=$ac_func_search_save_LIBS |
| 7962 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7963 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 7964 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7965 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7966 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7967 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7968 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7969 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 7970 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7971 | # posix4 on Solaris 2.6 |
| 7972 | # pthread (first!) on Linux |
| 7973 | fi |
| 7974 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7975 | # check if we need libintl for locale functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7976 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 7977 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 7978 | if ${ac_cv_lib_intl_textdomain+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7979 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7980 | else |
| 7981 | ac_check_lib_save_LIBS=$LIBS |
| 7982 | LIBS="-lintl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7983 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7984 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7985 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7986 | /* Override any GCC internal prototype to avoid an error. |
| 7987 | Use char because int might match the return type of a GCC |
| 7988 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7989 | #ifdef __cplusplus |
| 7990 | extern "C" |
| 7991 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7992 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7993 | int |
| 7994 | main () |
| 7995 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7996 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7997 | ; |
| 7998 | return 0; |
| 7999 | } |
| 8000 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8001 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8002 | ac_cv_lib_intl_textdomain=yes |
| 8003 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8004 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8005 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8006 | rm -f core conftest.err conftest.$ac_objext \ |
| 8007 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8008 | LIBS=$ac_check_lib_save_LIBS |
| 8009 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8010 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 8011 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8012 | if test "x$ac_cv_lib_intl_textdomain" = xyes; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8013 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8014 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8015 | |
| 8016 | fi |
| 8017 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8018 | |
| 8019 | # checks for system dependent C++ extensions support |
| 8020 | case "$ac_sys_system" in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8021 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 8022 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 8023 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8024 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8025 | |
Georg Brandl | 94800df | 2011-02-25 11:09:02 +0000 | [diff] [blame] | 8026 | #include <load.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8027 | int |
| 8028 | main () |
| 8029 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8030 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8031 | ; |
| 8032 | return 0; |
| 8033 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8034 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8035 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8036 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8037 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8038 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8039 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8040 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8041 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8042 | $as_echo "yes" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8043 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8044 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8045 | |
| 8046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8047 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8048 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8049 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8050 | rm -f core conftest.err conftest.$ac_objext \ |
| 8051 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8052 | *) ;; |
| 8053 | esac |
| 8054 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8055 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8056 | # BeOS' sockets are stashed in libnet. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8057 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 8058 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8059 | if ${ac_cv_lib_nsl_t_open+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8060 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8061 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8062 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8063 | LIBS="-lnsl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8064 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8065 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8066 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8067 | /* Override any GCC internal prototype to avoid an error. |
| 8068 | Use char because int might match the return type of a GCC |
| 8069 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8070 | #ifdef __cplusplus |
| 8071 | extern "C" |
| 8072 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8073 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8074 | int |
| 8075 | main () |
| 8076 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8077 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8078 | ; |
| 8079 | return 0; |
| 8080 | } |
| 8081 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8082 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8083 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8084 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8085 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8086 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8087 | rm -f core conftest.err conftest.$ac_objext \ |
| 8088 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8089 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8090 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 8092 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8093 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8094 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8095 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 8096 | # SVR4 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8097 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 8098 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8099 | if ${ac_cv_lib_socket_socket+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8100 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8101 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8102 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8103 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8104 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8105 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8106 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8107 | /* Override any GCC internal prototype to avoid an error. |
| 8108 | Use char because int might match the return type of a GCC |
| 8109 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8110 | #ifdef __cplusplus |
| 8111 | extern "C" |
| 8112 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8113 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8114 | int |
| 8115 | main () |
| 8116 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8117 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8118 | ; |
| 8119 | return 0; |
| 8120 | } |
| 8121 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8122 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8123 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8124 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8125 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8126 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8127 | rm -f core conftest.err conftest.$ac_objext \ |
| 8128 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8129 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8130 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8131 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 8132 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8133 | if test "x$ac_cv_lib_socket_socket" = xyes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8134 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8135 | fi |
| 8136 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 8137 | |
Jeremy Hylton | cb25d5e | 2000-07-27 21:23:28 +0000 | [diff] [blame] | 8138 | case "$ac_sys_system" in |
| 8139 | BeOS*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8140 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lnet" >&5 |
| 8141 | $as_echo_n "checking for socket in -lnet... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8142 | if ${ac_cv_lib_net_socket+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8143 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8144 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8145 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8146 | LIBS="-lnet $LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8147 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8148 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8149 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8150 | /* Override any GCC internal prototype to avoid an error. |
| 8151 | Use char because int might match the return type of a GCC |
| 8152 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8153 | #ifdef __cplusplus |
| 8154 | extern "C" |
| 8155 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8156 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8157 | int |
| 8158 | main () |
| 8159 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8160 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8161 | ; |
| 8162 | return 0; |
| 8163 | } |
| 8164 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8165 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8166 | ac_cv_lib_net_socket=yes |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8167 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8168 | ac_cv_lib_net_socket=no |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8169 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8170 | rm -f core conftest.err conftest.$ac_objext \ |
| 8171 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8172 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8173 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8174 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_net_socket" >&5 |
| 8175 | $as_echo "$ac_cv_lib_net_socket" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8176 | if test "x$ac_cv_lib_net_socket" = xyes; then : |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8177 | LIBS="-lnet $LIBS" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8178 | fi |
| 8179 | # BeOS |
| 8180 | ;; |
| 8181 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8182 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8183 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 8184 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8185 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8186 | # Check whether --with-libs was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8187 | if test "${with_libs+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8188 | withval=$with_libs; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8190 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 8191 | LIBS="$withval $LIBS" |
| 8192 | |
| 8193 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8195 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8196 | fi |
| 8197 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 8198 | |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8199 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8200 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 8201 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8203 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8204 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8205 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8206 | else |
| 8207 | case $PKG_CONFIG in |
| 8208 | [\\/]* | ?:[\\/]*) |
| 8209 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 8210 | ;; |
| 8211 | *) |
| 8212 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8213 | for as_dir in $PATH |
| 8214 | do |
| 8215 | IFS=$as_save_IFS |
| 8216 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8217 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8218 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8219 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8220 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8221 | break 2 |
| 8222 | fi |
| 8223 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8224 | done |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8225 | IFS=$as_save_IFS |
| 8226 | |
| 8227 | ;; |
| 8228 | esac |
| 8229 | fi |
| 8230 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 8231 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 8233 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8234 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8235 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8236 | $as_echo "no" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8237 | fi |
| 8238 | |
| 8239 | |
| 8240 | fi |
| 8241 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 8242 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 8243 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8244 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8246 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8247 | if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8248 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8249 | else |
| 8250 | case $ac_pt_PKG_CONFIG in |
| 8251 | [\\/]* | ?:[\\/]*) |
| 8252 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 8253 | ;; |
| 8254 | *) |
| 8255 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8256 | for as_dir in $PATH |
| 8257 | do |
| 8258 | IFS=$as_save_IFS |
| 8259 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8260 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8261 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8262 | ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8263 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8264 | break 2 |
| 8265 | fi |
| 8266 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8267 | done |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8268 | IFS=$as_save_IFS |
| 8269 | |
| 8270 | ;; |
| 8271 | esac |
| 8272 | fi |
| 8273 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 8274 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8275 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 8276 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8277 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8278 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8279 | $as_echo "no" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8280 | fi |
| 8281 | |
| 8282 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 8283 | PKG_CONFIG="" |
| 8284 | else |
| 8285 | case $cross_compiling:$ac_tool_warned in |
| 8286 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8287 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 8288 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8289 | ac_tool_warned=yes ;; |
| 8290 | esac |
| 8291 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 8292 | fi |
| 8293 | else |
| 8294 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 8295 | fi |
| 8296 | |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8297 | |
| 8298 | # Check for use of the system expat library |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 8300 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8301 | |
| 8302 | # Check whether --with-system_expat was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8303 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8304 | withval=$with_system_expat; |
Benjamin Peterson | f2d1b2a | 2010-10-31 16:53:53 +0000 | [diff] [blame] | 8305 | else |
| 8306 | with_system_expat="no" |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8307 | fi |
| 8308 | |
| 8309 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8310 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 8311 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8312 | |
| 8313 | # Check for use of the system libffi library |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8314 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 8315 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8316 | |
| 8317 | # Check whether --with-system_ffi was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8318 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8319 | withval=$with_system_ffi; |
Benjamin Peterson | f2d1b2a | 2010-10-31 16:53:53 +0000 | [diff] [blame] | 8320 | else |
| 8321 | with_system_ffi="no" |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8322 | fi |
| 8323 | |
| 8324 | |
| 8325 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8326 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 8327 | else |
| 8328 | LIBFFI_INCLUDEDIR="" |
| 8329 | fi |
| 8330 | |
| 8331 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 8333 | $as_echo "$with_system_ffi" >&6; } |
Martin v. Löwis | 9176fc1 | 2006-04-11 11:12:43 +0000 | [diff] [blame] | 8334 | |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8335 | # Check for --with-dbmliborder |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 8337 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8338 | |
| 8339 | # Check whether --with-dbmliborder was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8340 | if test "${with_dbmliborder+set}" = set; then : |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8341 | withval=$with_dbmliborder; |
| 8342 | if test x$with_dbmliborder = xyes |
| 8343 | then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8344 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8345 | else |
| 8346 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 8347 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 8348 | then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8349 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8350 | fi |
| 8351 | done |
| 8352 | fi |
| 8353 | fi |
| 8354 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 8356 | $as_echo "$with_dbmliborder" >&6; } |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8357 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8358 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8359 | |
| 8360 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8361 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 8362 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8363 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8364 | # Check whether --with-signal-module was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8365 | if test "${with_signal_module+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8366 | withval=$with_signal_module; |
| 8367 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8368 | |
| 8369 | |
| 8370 | if test -z "$with_signal_module" |
| 8371 | then with_signal_module="yes" |
| 8372 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 8374 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8375 | |
| 8376 | if test "${with_signal_module}" = "yes"; then |
| 8377 | USE_SIGNAL_MODULE="" |
| 8378 | SIGNAL_OBJS="" |
| 8379 | else |
| 8380 | USE_SIGNAL_MODULE="#" |
| 8381 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 8382 | fi |
| 8383 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 8384 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8385 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8386 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8387 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8388 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dec-threads" >&5 |
| 8389 | $as_echo_n "checking for --with-dec-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8390 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8391 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8392 | # Check whether --with-dec-threads was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8393 | if test "${with_dec_threads+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8394 | withval=$with_dec_threads; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8395 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8396 | $as_echo "$withval" >&6; } |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8397 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8398 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8399 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8400 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8401 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8403 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8404 | fi |
| 8405 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8406 | |
| 8407 | # Templates for things AC_DEFINEd more than once. |
| 8408 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8409 | |
| 8410 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8411 | |
| 8412 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8413 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 8414 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8415 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8416 | # Check whether --with-threads was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8417 | if test "${with_threads+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8418 | withval=$with_threads; |
| 8419 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8420 | |
| 8421 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8422 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8423 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8424 | # Check whether --with-thread was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8425 | if test "${with_thread+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8426 | withval=$with_thread; with_threads=$with_thread |
| 8427 | fi |
| 8428 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8429 | |
| 8430 | if test -z "$with_threads" |
| 8431 | then with_threads="yes" |
| 8432 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8433 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 8434 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8435 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8436 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8437 | if test "$with_threads" = "no" |
| 8438 | then |
| 8439 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8440 | elif test "$ac_cv_pthread_is_default" = yes |
| 8441 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8442 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8443 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8444 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8445 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8446 | |
| 8447 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8448 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8449 | elif test "$ac_cv_kpthread" = "yes" |
| 8450 | then |
| 8451 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8452 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8453 | CXX="$CXX -Kpthread" |
| 8454 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8455 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 8456 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8457 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8458 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8459 | elif test "$ac_cv_kthread" = "yes" |
| 8460 | then |
| 8461 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8462 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8463 | CXX="$CXX -Kthread" |
| 8464 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8465 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8466 | |
| 8467 | posix_threads=yes |
| 8468 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8469 | elif test "$ac_cv_pthread" = "yes" |
| 8470 | then |
| 8471 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8472 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8473 | CXX="$CXX -pthread" |
| 8474 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8475 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8476 | |
| 8477 | posix_threads=yes |
| 8478 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8479 | else |
| 8480 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 8481 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 8482 | fi |
| 8483 | if test ! -z "$withval" -a -d "$withval" |
| 8484 | then LDFLAGS="$LDFLAGS -L$withval" |
| 8485 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8486 | |
| 8487 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 8488 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 8489 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8490 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 8491 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 8492 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8493 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8494 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8495 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8496 | #ifdef _POSIX_THREADS |
| 8497 | yes |
| 8498 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8499 | |
| 8500 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8501 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8502 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8503 | unistd_defines_pthreads=yes |
| 8504 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8505 | unistd_defines_pthreads=no |
| 8506 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 8507 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8508 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8509 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 8510 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8511 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8512 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 8513 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8514 | ac_fn_c_check_header_mongrel "$LINENO" "cthreads.h" "ac_cv_header_cthreads_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8515 | if test "x$ac_cv_header_cthreads_h" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8516 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8517 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8518 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8519 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8520 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8521 | $as_echo "#define HURD_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8522 | |
| 8523 | LIBS="$LIBS -lthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8524 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8525 | else |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8526 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8527 | ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8528 | if test "x$ac_cv_header_mach_cthreads_h" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8529 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8530 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8531 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8532 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8533 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8534 | $as_echo "#define MACH_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8535 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8536 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8537 | else |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8538 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8539 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pth" >&5 |
| 8540 | $as_echo_n "checking for --with-pth... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8541 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8542 | # Check whether --with-pth was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8543 | if test "${with_pth+set}" = set; then : |
| 8544 | withval=$with_pth; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8545 | $as_echo "$withval" >&6; } |
| 8546 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8547 | |
| 8548 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8549 | $as_echo "#define HAVE_PTH 1" >>confdefs.h |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 8550 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8551 | LIBS="-lpth $LIBS" |
| 8552 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 8553 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8554 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8555 | $as_echo "no" >&6; } |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8556 | |
| 8557 | # Just looking for pthread_create in libpthread is not enough: |
| 8558 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 8559 | # So we really have to include pthread.h, and then link. |
| 8560 | _libs=$LIBS |
| 8561 | LIBS="$LIBS -lpthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8562 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 8563 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 8564 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8565 | /* end confdefs.h. */ |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8566 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8567 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8568 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8569 | int |
| 8570 | main () |
| 8571 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8572 | |
| 8573 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8574 | ; |
| 8575 | return 0; |
| 8576 | } |
| 8577 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8578 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8579 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8580 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8581 | $as_echo "yes" >&6; } |
| 8582 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8583 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8584 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8585 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8586 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8587 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8588 | LIBS=$_libs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8589 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8590 | if test "x$ac_cv_func_pthread_detach" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8591 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8592 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8593 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8594 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8595 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8596 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8597 | ac_fn_c_check_header_mongrel "$LINENO" "atheos/threads.h" "ac_cv_header_atheos_threads_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8598 | if test "x$ac_cv_header_atheos_threads_h" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8599 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8600 | |
| 8601 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8602 | $as_echo "#define ATHEOS_THREADS 1" >>confdefs.h |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8603 | |
| 8604 | THREADOBJ="Python/thread.o" |
| 8605 | else |
| 8606 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8607 | ac_fn_c_check_header_mongrel "$LINENO" "kernel/OS.h" "ac_cv_header_kernel_OS_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8608 | if test "x$ac_cv_header_kernel_OS_h" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8609 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8610 | |
| 8611 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8612 | $as_echo "#define BEOS_THREADS 1" >>confdefs.h |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8613 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8614 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8615 | else |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8616 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8617 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 8618 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8619 | if ${ac_cv_lib_pthreads_pthread_create+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8620 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8621 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8622 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8623 | LIBS="-lpthreads $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8624 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8625 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8626 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8627 | /* Override any GCC internal prototype to avoid an error. |
| 8628 | Use char because int might match the return type of a GCC |
| 8629 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8630 | #ifdef __cplusplus |
| 8631 | extern "C" |
| 8632 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8633 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8634 | int |
| 8635 | main () |
| 8636 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8637 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8638 | ; |
| 8639 | return 0; |
| 8640 | } |
| 8641 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8642 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8643 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8644 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8645 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8646 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8647 | rm -f core conftest.err conftest.$ac_objext \ |
| 8648 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8649 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8650 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8651 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 8652 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8653 | if test "x$ac_cv_lib_pthreads_pthread_create" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8654 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8655 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8656 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8657 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8658 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8659 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8660 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8661 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 8662 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8663 | if ${ac_cv_lib_c_r_pthread_create+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8664 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8665 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8666 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8667 | LIBS="-lc_r $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8668 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8669 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8670 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8671 | /* Override any GCC internal prototype to avoid an error. |
| 8672 | Use char because int might match the return type of a GCC |
| 8673 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8674 | #ifdef __cplusplus |
| 8675 | extern "C" |
| 8676 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8677 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8678 | int |
| 8679 | main () |
| 8680 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8681 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8682 | ; |
| 8683 | return 0; |
| 8684 | } |
| 8685 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8686 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8687 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8688 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8689 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8690 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8691 | rm -f core conftest.err conftest.$ac_objext \ |
| 8692 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8693 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8694 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8695 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 8696 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8697 | if test "x$ac_cv_lib_c_r_pthread_create" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8698 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8699 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8700 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8701 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8702 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8703 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8704 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8705 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 8706 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8707 | if ${ac_cv_lib_pthread___pthread_create_system+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8708 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8709 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8710 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8711 | LIBS="-lpthread $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8712 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8713 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8714 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8715 | /* Override any GCC internal prototype to avoid an error. |
| 8716 | Use char because int might match the return type of a GCC |
| 8717 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8718 | #ifdef __cplusplus |
| 8719 | extern "C" |
| 8720 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8721 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8722 | int |
| 8723 | main () |
| 8724 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8725 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8726 | ; |
| 8727 | return 0; |
| 8728 | } |
| 8729 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8730 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8731 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8732 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8733 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8734 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8735 | rm -f core conftest.err conftest.$ac_objext \ |
| 8736 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8737 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8738 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8739 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 8740 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8741 | if test "x$ac_cv_lib_pthread___pthread_create_system" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8742 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8743 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8744 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8745 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8746 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8747 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8748 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8749 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 8750 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8751 | if ${ac_cv_lib_cma_pthread_create+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8752 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8753 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8754 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8755 | LIBS="-lcma $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8756 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8757 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8758 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8759 | /* Override any GCC internal prototype to avoid an error. |
| 8760 | Use char because int might match the return type of a GCC |
| 8761 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8762 | #ifdef __cplusplus |
| 8763 | extern "C" |
| 8764 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8765 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8766 | int |
| 8767 | main () |
| 8768 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8769 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8770 | ; |
| 8771 | return 0; |
| 8772 | } |
| 8773 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8774 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8775 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8776 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8777 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8778 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8779 | rm -f core conftest.err conftest.$ac_objext \ |
| 8780 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8781 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8782 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8783 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 8784 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8785 | if test "x$ac_cv_lib_cma_pthread_create" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8786 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8787 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8788 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8789 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8790 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8791 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 8792 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8793 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 8794 | fi |
| 8795 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8796 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8797 | fi |
| 8798 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 8799 | fi |
| 8800 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8801 | fi |
| 8802 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8803 | fi |
| 8804 | |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8805 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8806 | fi |
| 8807 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8808 | |
| 8809 | fi |
| 8810 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8811 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8812 | rm -f core conftest.err conftest.$ac_objext \ |
| 8813 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8814 | fi |
| 8815 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8816 | fi |
| 8817 | |
| 8818 | |
| 8819 | fi |
| 8820 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8821 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8822 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8823 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 8824 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8825 | if ${ac_cv_lib_mpc_usconfig+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8826 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8827 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8828 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8829 | LIBS="-lmpc $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8830 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8831 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8832 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8833 | /* Override any GCC internal prototype to avoid an error. |
| 8834 | Use char because int might match the return type of a GCC |
| 8835 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8836 | #ifdef __cplusplus |
| 8837 | extern "C" |
| 8838 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8839 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8840 | int |
| 8841 | main () |
| 8842 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8843 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8844 | ; |
| 8845 | return 0; |
| 8846 | } |
| 8847 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8848 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8849 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8850 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8851 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8852 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8853 | rm -f core conftest.err conftest.$ac_objext \ |
| 8854 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8855 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8856 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8857 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 8858 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8859 | if test "x$ac_cv_lib_mpc_usconfig" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8860 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8861 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8862 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8863 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8864 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8865 | fi |
| 8866 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8867 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 8868 | if test "$posix_threads" != "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8869 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 8870 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8871 | if ${ac_cv_lib_thread_thr_create+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8872 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8873 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8874 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8875 | LIBS="-lthread $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8876 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8877 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8878 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8879 | /* Override any GCC internal prototype to avoid an error. |
| 8880 | Use char because int might match the return type of a GCC |
| 8881 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8882 | #ifdef __cplusplus |
| 8883 | extern "C" |
| 8884 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8885 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8886 | int |
| 8887 | main () |
| 8888 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8889 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8890 | ; |
| 8891 | return 0; |
| 8892 | } |
| 8893 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8894 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8895 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8896 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8897 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8898 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8899 | rm -f core conftest.err conftest.$ac_objext \ |
| 8900 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8901 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8902 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8903 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 8904 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8905 | if test "x$ac_cv_lib_thread_thr_create" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8906 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8907 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8908 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8909 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8910 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8911 | fi |
| 8912 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8913 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8914 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8915 | if test "$USE_THREAD_MODULE" != "#" |
| 8916 | then |
| 8917 | # If the above checks didn't disable threads, (at least) OSF1 |
| 8918 | # needs this '-threads' argument during linking. |
| 8919 | case $ac_sys_system in |
| 8920 | OSF1) LDLAST=-threads;; |
| 8921 | esac |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 8922 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8923 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8924 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8925 | if test "$posix_threads" = "yes"; then |
| 8926 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8927 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8928 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8929 | |
| 8930 | fi |
| 8931 | |
| 8932 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 8933 | case $ac_sys_system/$ac_sys_release in |
| 8934 | SunOS/5.6) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8935 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8936 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8937 | ;; |
| 8938 | SunOS/5.8) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8939 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8940 | |
| 8941 | ;; |
Christian Heimes | cba36bb | 2008-01-30 22:54:18 +0000 | [diff] [blame] | 8942 | AIX/5) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8943 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | cba36bb | 2008-01-30 22:54:18 +0000 | [diff] [blame] | 8944 | |
| 8945 | ;; |
Antoine Pitrou | b41947b | 2010-08-30 14:55:30 +0000 | [diff] [blame] | 8946 | AIX/6) |
| 8947 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
| 8948 | |
| 8949 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8950 | esac |
| 8951 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8952 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 8953 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8954 | if ${ac_cv_pthread_system_supported+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8955 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8956 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8957 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8958 | ac_cv_pthread_system_supported=no |
| 8959 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8960 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8961 | /* end confdefs.h. */ |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8962 | #include <pthread.h> |
| 8963 | void *foo(void *parm) { |
| 8964 | return NULL; |
| 8965 | } |
| 8966 | main() { |
| 8967 | pthread_attr_t attr; |
| 8968 | pthread_t id; |
| 8969 | if (pthread_attr_init(&attr)) exit(-1); |
| 8970 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 8971 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 8972 | exit(0); |
| 8973 | } |
| 8974 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8975 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8976 | ac_cv_pthread_system_supported=yes |
| 8977 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8978 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8979 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8980 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8981 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8982 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8983 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8984 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8985 | fi |
| 8986 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8987 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 8988 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8989 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 8990 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8991 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8992 | |
| 8993 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8994 | for ac_func in pthread_sigmask |
| 8995 | do : |
| 8996 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 8997 | if test "x$ac_cv_func_pthread_sigmask" = xyes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8998 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8999 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9000 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 9001 | case $ac_sys_system in |
| 9002 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9003 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9004 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 9005 | |
| 9006 | ;; |
| 9007 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9008 | fi |
| 9009 | done |
| 9010 | |
| 9011 | fi |
| 9012 | |
| 9013 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9014 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9015 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9016 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 9017 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9018 | # Check whether --enable-ipv6 was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9019 | if test "${enable_ipv6+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9020 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9021 | no) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9022 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9023 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9024 | ipv6=no |
| 9025 | ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9026 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9027 | $as_echo "yes" >&6; } |
| 9028 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9029 | |
| 9030 | ipv6=yes |
| 9031 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9032 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9033 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9034 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9035 | if test "$cross_compiling" = yes; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9036 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9037 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9038 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9039 | ipv6=no |
| 9040 | |
| 9041 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9042 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9043 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9044 | /* AF_INET6 available check */ |
| 9045 | #include <sys/types.h> |
| 9046 | #include <sys/socket.h> |
| 9047 | main() |
| 9048 | { |
| 9049 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 9050 | exit(1); |
| 9051 | else |
| 9052 | exit(0); |
| 9053 | } |
| 9054 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9055 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9056 | if ac_fn_c_try_run "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9057 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9058 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9059 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9060 | ipv6=yes |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9061 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9062 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9063 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9064 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9065 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9066 | ipv6=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9067 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9068 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9069 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9070 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9071 | fi |
| 9072 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9073 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9074 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9075 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 9076 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 9077 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9078 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9079 | |
| 9080 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9081 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9082 | int |
| 9083 | main () |
| 9084 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9085 | struct sockaddr_in6 x; |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9086 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9087 | ; |
| 9088 | return 0; |
| 9089 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9090 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9091 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9092 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9093 | |
| 9094 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9095 | $as_echo "yes" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9096 | ipv6=yes |
| 9097 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9098 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9099 | |
| 9100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9101 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9102 | ipv6=no |
| 9103 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9104 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9105 | 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] | 9106 | fi |
| 9107 | |
| 9108 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9109 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9110 | |
| 9111 | fi |
| 9112 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9113 | fi |
| 9114 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9115 | |
| 9116 | ipv6type=unknown |
| 9117 | ipv6lib=none |
| 9118 | ipv6trylibc=no |
| 9119 | |
| 9120 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9121 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 9122 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 9123 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 9124 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9125 | case $i in |
| 9126 | inria) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9127 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9128 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9129 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9130 | #include <netinet/in.h> |
| 9131 | #ifdef IPV6_INRIA_VERSION |
| 9132 | yes |
| 9133 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9134 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9135 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9136 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9137 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9138 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9139 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9140 | |
| 9141 | ;; |
| 9142 | kame) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9143 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9144 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9145 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9146 | #include <netinet/in.h> |
| 9147 | #ifdef __KAME__ |
| 9148 | yes |
| 9149 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9150 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9151 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9152 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9153 | ipv6type=$i; |
| 9154 | ipv6lib=inet6 |
| 9155 | ipv6libdir=/usr/local/v6/lib |
| 9156 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9157 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9158 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9159 | |
| 9160 | ;; |
| 9161 | linux-glibc) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9162 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9163 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9164 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9165 | #include <features.h> |
| 9166 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 9167 | yes |
| 9168 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9169 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9170 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9171 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9172 | ipv6type=$i; |
| 9173 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9174 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9175 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9176 | |
| 9177 | ;; |
| 9178 | linux-inet6) |
| 9179 | if test -d /usr/inet6; then |
| 9180 | ipv6type=$i |
| 9181 | ipv6lib=inet6 |
| 9182 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9183 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9184 | fi |
| 9185 | ;; |
| 9186 | solaris) |
| 9187 | if test -f /etc/netconfig; then |
Antoine Pitrou | 31e8595 | 2011-01-03 18:57:14 +0000 | [diff] [blame] | 9188 | if $GREP -q tcp6 /etc/netconfig; then |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9189 | ipv6type=$i |
| 9190 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9191 | fi |
| 9192 | fi |
| 9193 | ;; |
| 9194 | toshiba) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9195 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9196 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9197 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9198 | #include <sys/param.h> |
| 9199 | #ifdef _TOSHIBA_INET6 |
| 9200 | yes |
| 9201 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9202 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9203 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9204 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9205 | ipv6type=$i; |
| 9206 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9207 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9208 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9209 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9210 | |
| 9211 | ;; |
| 9212 | v6d) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9213 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9214 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9215 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9216 | #include </usr/local/v6/include/sys/v6config.h> |
| 9217 | #ifdef __V6D__ |
| 9218 | yes |
| 9219 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9220 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9221 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9222 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9223 | ipv6type=$i; |
| 9224 | ipv6lib=v6; |
| 9225 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9226 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9227 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9228 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9229 | |
| 9230 | ;; |
| 9231 | zeta) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9232 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9233 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9234 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9235 | #include <sys/param.h> |
| 9236 | #ifdef _ZETA_MINAMI_INET6 |
| 9237 | yes |
| 9238 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9239 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9240 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9241 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9242 | ipv6type=$i; |
| 9243 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9244 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9245 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9246 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9247 | |
| 9248 | ;; |
| 9249 | esac |
| 9250 | if test "$ipv6type" != "unknown"; then |
| 9251 | break |
| 9252 | fi |
| 9253 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9254 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 9255 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9256 | fi |
| 9257 | |
| 9258 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 9259 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 9260 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 9261 | echo "using lib$ipv6lib" |
| 9262 | else |
| 9263 | if test $ipv6trylibc = "yes"; then |
| 9264 | echo "using libc" |
| 9265 | else |
| 9266 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 9267 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 9268 | echo 'ipv6 kit and compile beforehand.' |
| 9269 | exit 1 |
| 9270 | fi |
| 9271 | fi |
| 9272 | fi |
| 9273 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9274 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 9275 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 9276 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9277 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9278 | |
| 9279 | #include <Carbon/Carbon.h> |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9280 | int |
| 9281 | main () |
| 9282 | { |
| 9283 | FSIORefNum fRef = 0 |
| 9284 | ; |
| 9285 | return 0; |
| 9286 | } |
Mark Dickinson | 0712b56 | 2010-05-08 19:13:21 +0000 | [diff] [blame] | 9287 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9288 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9289 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9290 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9291 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9292 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9293 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9294 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9295 | $as_echo "yes" >&6; } |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9296 | |
Mark Dickinson | 0712b56 | 2010-05-08 19:13:21 +0000 | [diff] [blame] | 9297 | else |
| 9298 | |
| 9299 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9300 | $as_echo "no" >&6; } |
| 9301 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9302 | fi |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9303 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9304 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9305 | # Check for --with-doc-strings |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9306 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 9307 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9308 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9309 | # Check whether --with-doc-strings was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9310 | if test "${with_doc_strings+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9311 | withval=$with_doc_strings; |
| 9312 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9313 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9314 | |
| 9315 | if test -z "$with_doc_strings" |
| 9316 | then with_doc_strings="yes" |
| 9317 | fi |
| 9318 | if test "$with_doc_strings" != "no" |
| 9319 | then |
| 9320 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9321 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9322 | |
| 9323 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9324 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 9325 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9326 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9327 | # Check for Python-specific malloc support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9328 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 9329 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9330 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9331 | # Check whether --with-tsc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9332 | if test "${with_tsc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9333 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9334 | if test "$withval" != no |
| 9335 | then |
| 9336 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9337 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9338 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9340 | $as_echo "yes" >&6; } |
| 9341 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9342 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9343 | fi |
| 9344 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9345 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9346 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9347 | fi |
| 9348 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9349 | |
| 9350 | # Check for Python-specific malloc support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9351 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 9352 | $as_echo_n "checking for --with-pymalloc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9353 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9354 | # Check whether --with-pymalloc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9355 | if test "${with_pymalloc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9356 | withval=$with_pymalloc; |
| 9357 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9358 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9359 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9360 | if test -z "$with_pymalloc" |
| 9361 | then with_pymalloc="yes" |
| 9362 | fi |
| 9363 | if test "$with_pymalloc" != "no" |
| 9364 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9365 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9366 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9367 | |
| 9368 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 9370 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9371 | |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9372 | # Check for Valgrind support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9373 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 9374 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9375 | |
| 9376 | # Check whether --with-valgrind was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9377 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9378 | withval=$with_valgrind; |
| 9379 | else |
| 9380 | with_valgrind=no |
| 9381 | fi |
| 9382 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9383 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 9384 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9385 | if test "$with_valgrind" != no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9386 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9387 | if test "x$ac_cv_header_valgrind_valgrind_h" = xyes; then : |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9388 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9389 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9390 | |
| 9391 | else |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9392 | as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9393 | |
| 9394 | fi |
| 9395 | |
| 9396 | |
| 9397 | fi |
| 9398 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9399 | # Check for --with-wctype-functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9400 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-wctype-functions" >&5 |
| 9401 | $as_echo_n "checking for --with-wctype-functions... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9402 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9403 | # Check whether --with-wctype-functions was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9404 | if test "${with_wctype_functions+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9405 | withval=$with_wctype_functions; |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9406 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9407 | then |
| 9408 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9409 | $as_echo "#define WANT_WCTYPE_FUNCTIONS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9410 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9411 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9412 | $as_echo "yes" >&6; } |
| 9413 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9414 | $as_echo "no" >&6; } |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9415 | fi |
| 9416 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9417 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9418 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9419 | fi |
| 9420 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9421 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 9422 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9423 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 9424 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9425 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9426 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 9427 | # 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] | 9428 | for ac_func in dlopen |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9429 | do : |
| 9430 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9431 | if test "x$ac_cv_func_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9432 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9433 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9434 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9435 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9436 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 9437 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9438 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9439 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9440 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 9441 | # loading of modules. |
| 9442 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9443 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 9444 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9445 | if test -z "$DYNLOADFILE" |
| 9446 | then |
| 9447 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 9448 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 9449 | if test "$ac_cv_func_dlopen" = yes |
| 9450 | then DYNLOADFILE="dynload_shlib.o" |
| 9451 | else DYNLOADFILE="dynload_aix.o" |
| 9452 | fi |
| 9453 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9454 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 9455 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 9456 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 9457 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 9458 | atheos*) DYNLOADFILE="dynload_atheos.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9459 | *) |
| 9460 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 9461 | # out any dynamic loading |
| 9462 | if test "$ac_cv_func_dlopen" = yes |
| 9463 | then DYNLOADFILE="dynload_shlib.o" |
| 9464 | else DYNLOADFILE="dynload_stub.o" |
| 9465 | fi |
| 9466 | ;; |
| 9467 | esac |
| 9468 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 9470 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9471 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 9472 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9473 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9474 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9475 | |
| 9476 | fi |
| 9477 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9478 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 9479 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9480 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9481 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 9482 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9483 | if test -z "$MACHDEP_OBJS" |
| 9484 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 9485 | MACHDEP_OBJS=$extra_machdep_objs |
| 9486 | else |
| 9487 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9488 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9489 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: MACHDEP_OBJS" >&5 |
| 9490 | $as_echo "MACHDEP_OBJS" >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9491 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9492 | # checks for library functions |
Martin v. Löwis | aef18b1 | 2008-03-24 13:31:16 +0000 | [diff] [blame] | 9493 | for ac_func in alarm setitimer getitimer bind_textdomain_codeset chown \ |
| 9494 | clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \ |
Martin v. Löwis | 438b534 | 2002-12-27 10:16:42 +0000 | [diff] [blame] | 9495 | gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 50ea456 | 2009-11-27 13:56:01 +0000 | [diff] [blame] | 9496 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Antoine Pitrou | 30b3b35 | 2009-12-02 20:37:54 +0000 | [diff] [blame] | 9497 | initgroups kill killpg lchmod lchown lstat mkfifo mknod mktime \ |
Martin v. Löwis | a5f0907 | 2002-10-11 05:37:59 +0000 | [diff] [blame] | 9498 | mremap nice pathconf pause plock poll pthread_init \ |
Guido van Rossum | 162e38c | 2003-02-19 15:25:10 +0000 | [diff] [blame] | 9499 | putenv readlink realpath \ |
Jesse Noller | 355b126 | 2009-04-02 00:03:28 +0000 | [diff] [blame] | 9500 | select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \ |
| 9501 | setgid \ |
Martin v. Löwis | 4daacb1 | 2003-03-28 18:37:01 +0000 | [diff] [blame] | 9502 | setlocale setregid setreuid setsid setpgid setpgrp setuid setvbuf snprintf \ |
Martin v. Löwis | 50ea456 | 2009-11-27 13:56:01 +0000 | [diff] [blame] | 9503 | setlocale setregid setreuid setresuid setresgid \ |
| 9504 | setsid setpgid setpgrp setuid setvbuf snprintf \ |
Skip Montanaro | 7e11a01 | 2004-02-07 12:55:46 +0000 | [diff] [blame] | 9505 | sigaction siginterrupt sigrelse strftime \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 9506 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Neal Norwitz | 05a4559 | 2006-03-20 06:30:08 +0000 | [diff] [blame] | 9507 | truncate uname unsetenv utimes waitpid wait3 wait4 wcscoll _getpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9508 | do : |
| 9509 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9510 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9511 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9512 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9513 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9514 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 9515 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9516 | fi |
| 9517 | done |
| 9518 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9519 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9520 | # For some functions, having a definition is not sufficient, since |
| 9521 | # we want to take their address. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9522 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 9523 | $as_echo_n "checking for chroot... " >&6; } |
| 9524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9525 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9526 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9527 | int |
| 9528 | main () |
| 9529 | { |
| 9530 | void *x=chroot |
| 9531 | ; |
| 9532 | return 0; |
| 9533 | } |
| 9534 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9535 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9536 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9537 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9538 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9539 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9540 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9541 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9542 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9543 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9544 | |
| 9545 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9546 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9547 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 9548 | $as_echo_n "checking for link... " >&6; } |
| 9549 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9550 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9551 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9552 | int |
| 9553 | main () |
| 9554 | { |
| 9555 | void *x=link |
| 9556 | ; |
| 9557 | return 0; |
| 9558 | } |
| 9559 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9560 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9561 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9562 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9563 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9564 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9565 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9566 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9567 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9568 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9569 | |
| 9570 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9571 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9572 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 9573 | $as_echo_n "checking for symlink... " >&6; } |
| 9574 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9575 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9576 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9577 | int |
| 9578 | main () |
| 9579 | { |
| 9580 | void *x=symlink |
| 9581 | ; |
| 9582 | return 0; |
| 9583 | } |
| 9584 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9585 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9586 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9587 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9588 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9589 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9590 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9591 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9593 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9594 | |
| 9595 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9596 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9597 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 9598 | $as_echo_n "checking for fchdir... " >&6; } |
| 9599 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9600 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9601 | #include <unistd.h> |
| 9602 | int |
| 9603 | main () |
| 9604 | { |
| 9605 | void *x=fchdir |
| 9606 | ; |
| 9607 | return 0; |
| 9608 | } |
| 9609 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9610 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9611 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9612 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9613 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9614 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9615 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9616 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9617 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9618 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9619 | |
| 9620 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9621 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9622 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 9623 | $as_echo_n "checking for fsync... " >&6; } |
| 9624 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9625 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9626 | #include <unistd.h> |
| 9627 | int |
| 9628 | main () |
| 9629 | { |
| 9630 | void *x=fsync |
| 9631 | ; |
| 9632 | return 0; |
| 9633 | } |
| 9634 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9635 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9636 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9637 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9638 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9639 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9640 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9641 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9642 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9643 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9644 | |
| 9645 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9646 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9647 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 9648 | $as_echo_n "checking for fdatasync... " >&6; } |
| 9649 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9650 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9651 | #include <unistd.h> |
| 9652 | int |
| 9653 | main () |
| 9654 | { |
| 9655 | void *x=fdatasync |
| 9656 | ; |
| 9657 | return 0; |
| 9658 | } |
| 9659 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9660 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9661 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9662 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9663 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9664 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9665 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9666 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9667 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9668 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9669 | |
| 9670 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9671 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 9673 | $as_echo_n "checking for epoll... " >&6; } |
| 9674 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9675 | /* end confdefs.h. */ |
| 9676 | #include <sys/epoll.h> |
| 9677 | int |
| 9678 | main () |
| 9679 | { |
| 9680 | void *x=epoll_create |
| 9681 | ; |
| 9682 | return 0; |
| 9683 | } |
| 9684 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9685 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9686 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9687 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9688 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9689 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9690 | $as_echo "yes" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9691 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9692 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9693 | $as_echo "no" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9694 | |
| 9695 | fi |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9696 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9697 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 9698 | $as_echo_n "checking for kqueue... " >&6; } |
| 9699 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9700 | /* end confdefs.h. */ |
| 9701 | |
| 9702 | #include <sys/types.h> |
| 9703 | #include <sys/event.h> |
| 9704 | |
| 9705 | int |
| 9706 | main () |
| 9707 | { |
| 9708 | int x=kqueue() |
| 9709 | ; |
| 9710 | return 0; |
| 9711 | } |
| 9712 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9713 | if ac_fn_c_try_compile "$LINENO"; then : |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9714 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9715 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9716 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9718 | $as_echo "yes" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9719 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9720 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9721 | $as_echo "no" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9722 | |
| 9723 | fi |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9724 | 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] | 9725 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 9726 | # functions ctermid_r, setgroups in the library, but no prototype |
| 9727 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 9728 | # address to avoid compiler warnings and potential miscompilations |
| 9729 | # because of the missing prototypes. |
| 9730 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 9732 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 9733 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9734 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9735 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9736 | #include <stdio.h> |
| 9737 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9738 | int |
| 9739 | main () |
| 9740 | { |
| 9741 | void* p = ctermid_r |
| 9742 | ; |
| 9743 | return 0; |
| 9744 | } |
| 9745 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9746 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9747 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9748 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9749 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9751 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9752 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9753 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9754 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9755 | |
| 9756 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9757 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9758 | |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9759 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5 |
| 9760 | $as_echo_n "checking for flock declaration... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9761 | if ${ac_cv_flock_decl+:} false; then : |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9762 | $as_echo_n "(cached) " >&6 |
| 9763 | else |
| 9764 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9765 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9766 | #include <sys/file.h> |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9767 | int |
| 9768 | main () |
| 9769 | { |
| 9770 | void* p = flock |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9771 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9772 | ; |
| 9773 | return 0; |
| 9774 | } |
| 9775 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9776 | if ac_fn_c_try_compile "$LINENO"; then : |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9777 | ac_cv_flock_decl=yes |
| 9778 | else |
| 9779 | ac_cv_flock_decl=no |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9780 | |
| 9781 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9782 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9783 | |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9784 | fi |
| 9785 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5 |
| 9786 | $as_echo "$ac_cv_flock_decl" >&6; } |
| 9787 | if test "x${ac_cv_flock_decl}" = xyes; then |
| 9788 | for ac_func in flock |
| 9789 | do : |
| 9790 | ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9791 | if test "x$ac_cv_func_flock" = xyes; then : |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9792 | cat >>confdefs.h <<_ACEOF |
| 9793 | #define HAVE_FLOCK 1 |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9794 | _ACEOF |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9795 | |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9796 | else |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9797 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock in -lbsd" >&5 |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9798 | $as_echo_n "checking for flock in -lbsd... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9799 | if ${ac_cv_lib_bsd_flock+:} false; then : |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9800 | $as_echo_n "(cached) " >&6 |
| 9801 | else |
| 9802 | ac_check_lib_save_LIBS=$LIBS |
| 9803 | LIBS="-lbsd $LIBS" |
| 9804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9805 | /* end confdefs.h. */ |
| 9806 | |
| 9807 | /* Override any GCC internal prototype to avoid an error. |
| 9808 | Use char because int might match the return type of a GCC |
| 9809 | builtin and then its argument prototype would still apply. */ |
| 9810 | #ifdef __cplusplus |
| 9811 | extern "C" |
| 9812 | #endif |
| 9813 | char flock (); |
| 9814 | int |
| 9815 | main () |
| 9816 | { |
| 9817 | return flock (); |
| 9818 | ; |
| 9819 | return 0; |
| 9820 | } |
| 9821 | _ACEOF |
| 9822 | if ac_fn_c_try_link "$LINENO"; then : |
| 9823 | ac_cv_lib_bsd_flock=yes |
| 9824 | else |
| 9825 | ac_cv_lib_bsd_flock=no |
| 9826 | fi |
| 9827 | rm -f core conftest.err conftest.$ac_objext \ |
| 9828 | conftest$ac_exeext conftest.$ac_ext |
| 9829 | LIBS=$ac_check_lib_save_LIBS |
| 9830 | fi |
| 9831 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5 |
| 9832 | $as_echo "$ac_cv_lib_bsd_flock" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9833 | if test "x$ac_cv_lib_bsd_flock" = xyes; then : |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9834 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9835 | |
| 9836 | |
| 9837 | $as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h |
| 9838 | |
| 9839 | |
| 9840 | fi |
| 9841 | |
| 9842 | |
| 9843 | fi |
Antoine Pitrou | b170f17 | 2010-09-10 18:47:36 +0000 | [diff] [blame] | 9844 | done |
| 9845 | |
Antoine Pitrou | 8572981 | 2010-09-07 14:55:24 +0000 | [diff] [blame] | 9846 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9847 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9848 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 9849 | $as_echo_n "checking for getpagesize... " >&6; } |
| 9850 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9851 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9852 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9853 | #include <unistd.h> |
| 9854 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9855 | int |
| 9856 | main () |
| 9857 | { |
| 9858 | void* p = getpagesize |
| 9859 | ; |
| 9860 | return 0; |
| 9861 | } |
| 9862 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9863 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9864 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9865 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9866 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9868 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9869 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9870 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9871 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9872 | |
| 9873 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9874 | 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] | 9875 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9876 | for ac_prog in true |
| 9877 | do |
| 9878 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 9879 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9880 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9881 | $as_echo_n "checking for $ac_word... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9882 | if ${ac_cv_prog_TRUE+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9883 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9884 | else |
| 9885 | if test -n "$TRUE"; then |
| 9886 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 9887 | else |
| 9888 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9889 | for as_dir in $PATH |
| 9890 | do |
| 9891 | IFS=$as_save_IFS |
| 9892 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9893 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9894 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9895 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9896 | $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] | 9897 | break 2 |
| 9898 | fi |
| 9899 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9900 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9901 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9902 | |
| 9903 | fi |
| 9904 | fi |
| 9905 | TRUE=$ac_cv_prog_TRUE |
| 9906 | if test -n "$TRUE"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9907 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 9908 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9909 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9910 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9911 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9912 | fi |
| 9913 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9914 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9915 | test -n "$TRUE" && break |
| 9916 | done |
| 9917 | test -n "$TRUE" || TRUE="/bin/true" |
| 9918 | |
| 9919 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9920 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 9921 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9922 | if ${ac_cv_lib_c_inet_aton+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9923 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9924 | else |
| 9925 | ac_check_lib_save_LIBS=$LIBS |
| 9926 | LIBS="-lc $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9927 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9928 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9929 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9930 | /* Override any GCC internal prototype to avoid an error. |
| 9931 | Use char because int might match the return type of a GCC |
| 9932 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9933 | #ifdef __cplusplus |
| 9934 | extern "C" |
| 9935 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9936 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9937 | int |
| 9938 | main () |
| 9939 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9940 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9941 | ; |
| 9942 | return 0; |
| 9943 | } |
| 9944 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9945 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9946 | ac_cv_lib_c_inet_aton=yes |
| 9947 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9948 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9949 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9950 | rm -f core conftest.err conftest.$ac_objext \ |
| 9951 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9952 | LIBS=$ac_check_lib_save_LIBS |
| 9953 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9954 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 9955 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9956 | 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] | 9957 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9958 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9959 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 9960 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9961 | if ${ac_cv_lib_resolv_inet_aton+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9962 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9963 | else |
| 9964 | ac_check_lib_save_LIBS=$LIBS |
| 9965 | LIBS="-lresolv $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9966 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9967 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9968 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9969 | /* Override any GCC internal prototype to avoid an error. |
| 9970 | Use char because int might match the return type of a GCC |
| 9971 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9972 | #ifdef __cplusplus |
| 9973 | extern "C" |
| 9974 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9975 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9976 | int |
| 9977 | main () |
| 9978 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9979 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9980 | ; |
| 9981 | return 0; |
| 9982 | } |
| 9983 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9984 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9985 | ac_cv_lib_resolv_inet_aton=yes |
| 9986 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9987 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9988 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9989 | rm -f core conftest.err conftest.$ac_objext \ |
| 9990 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9991 | LIBS=$ac_check_lib_save_LIBS |
| 9992 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9993 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 9994 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 9995 | 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] | 9996 | cat >>confdefs.h <<_ACEOF |
| 9997 | #define HAVE_LIBRESOLV 1 |
| 9998 | _ACEOF |
| 9999 | |
| 10000 | LIBS="-lresolv $LIBS" |
| 10001 | |
| 10002 | fi |
| 10003 | |
| 10004 | |
| 10005 | fi |
| 10006 | |
| 10007 | |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10008 | # On Tru64, chflags seems to be present, but calling it will |
| 10009 | # exit Python |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10010 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 10011 | $as_echo_n "checking for chflags... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10012 | if ${ac_cv_have_chflags+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10013 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10014 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10015 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10016 | ac_cv_have_chflags=cross |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10017 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10018 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10019 | /* end confdefs.h. */ |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10020 | [ |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10021 | #include <sys/stat.h> |
| 10022 | #include <unistd.h> |
| 10023 | int main(int argc, char*argv[]) |
| 10024 | { |
| 10025 | if(chflags(argv[0], 0) != 0) |
| 10026 | return 1; |
| 10027 | return 0; |
| 10028 | } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10029 | ] |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10030 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10031 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10032 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10033 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10034 | ac_cv_have_chflags=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10035 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10036 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10037 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 10038 | fi |
| 10039 | |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10040 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10041 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10042 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 10043 | $as_echo "$ac_cv_have_chflags" >&6; } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10044 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10045 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10046 | if test "x$ac_cv_func_chflags" = xyes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10047 | ac_cv_have_chflags="yes" |
| 10048 | else |
| 10049 | ac_cv_have_chflags="no" |
| 10050 | fi |
| 10051 | |
| 10052 | fi |
| 10053 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10054 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10055 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10056 | |
| 10057 | fi |
| 10058 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10059 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 10060 | $as_echo_n "checking for lchflags... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10061 | if ${ac_cv_have_lchflags+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10062 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10063 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10064 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10065 | ac_cv_have_lchflags=cross |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10066 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10067 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10068 | /* end confdefs.h. */ |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10069 | [ |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10070 | #include <sys/stat.h> |
| 10071 | #include <unistd.h> |
| 10072 | int main(int argc, char*argv[]) |
| 10073 | { |
| 10074 | if(lchflags(argv[0], 0) != 0) |
| 10075 | return 1; |
| 10076 | return 0; |
| 10077 | } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10078 | ] |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10079 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10080 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10081 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10082 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10083 | ac_cv_have_lchflags=no |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10084 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10085 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10086 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10087 | fi |
| 10088 | |
| 10089 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10090 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 10092 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10093 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10094 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10095 | if test "x$ac_cv_func_lchflags" = xyes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10096 | ac_cv_have_lchflags="yes" |
| 10097 | else |
| 10098 | ac_cv_have_lchflags="no" |
| 10099 | fi |
| 10100 | |
| 10101 | fi |
| 10102 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10103 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10104 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10105 | |
| 10106 | fi |
| 10107 | |
Ronald Oussoren | f875264 | 2006-07-06 10:13:35 +0000 | [diff] [blame] | 10108 | case $ac_sys_system/$ac_sys_release in |
| 10109 | Darwin/*) |
| 10110 | _CUR_CFLAGS="${CFLAGS}" |
| 10111 | _CUR_LDFLAGS="${LDFLAGS}" |
| 10112 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 10113 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 10114 | ;; |
| 10115 | esac |
| 10116 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10117 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 10118 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10119 | if ${ac_cv_lib_z_inflateCopy+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10120 | $as_echo_n "(cached) " >&6 |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10121 | else |
| 10122 | ac_check_lib_save_LIBS=$LIBS |
| 10123 | LIBS="-lz $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10124 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10125 | /* end confdefs.h. */ |
| 10126 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10127 | /* Override any GCC internal prototype to avoid an error. |
| 10128 | Use char because int might match the return type of a GCC |
| 10129 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10130 | #ifdef __cplusplus |
| 10131 | extern "C" |
| 10132 | #endif |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10133 | char inflateCopy (); |
| 10134 | int |
| 10135 | main () |
| 10136 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10137 | return inflateCopy (); |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10138 | ; |
| 10139 | return 0; |
| 10140 | } |
| 10141 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10142 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10143 | ac_cv_lib_z_inflateCopy=yes |
| 10144 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10145 | ac_cv_lib_z_inflateCopy=no |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10146 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10147 | rm -f core conftest.err conftest.$ac_objext \ |
| 10148 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10149 | LIBS=$ac_check_lib_save_LIBS |
| 10150 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10151 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 10152 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10153 | if test "x$ac_cv_lib_z_inflateCopy" = xyes; then : |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10154 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10155 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10156 | |
| 10157 | fi |
| 10158 | |
| 10159 | |
Ronald Oussoren | f875264 | 2006-07-06 10:13:35 +0000 | [diff] [blame] | 10160 | case $ac_sys_system/$ac_sys_release in |
| 10161 | Darwin/*) |
| 10162 | CFLAGS="${_CUR_CFLAGS}" |
| 10163 | LDFLAGS="${_CUR_LDFLAGS}" |
| 10164 | ;; |
| 10165 | esac |
| 10166 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10167 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 10168 | $as_echo_n "checking for hstrerror... " >&6; } |
| 10169 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10170 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10171 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10172 | #include <netdb.h> |
| 10173 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10174 | int |
| 10175 | main () |
| 10176 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10177 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10178 | ; |
| 10179 | return 0; |
| 10180 | } |
| 10181 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10182 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10183 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10184 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10185 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10186 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10187 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10188 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10190 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10191 | |
| 10192 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10193 | rm -f core conftest.err conftest.$ac_objext \ |
| 10194 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10195 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10196 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 10197 | $as_echo_n "checking for inet_aton... " >&6; } |
| 10198 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10199 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10200 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 10201 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10202 | #include <sys/socket.h> |
| 10203 | #include <netinet/in.h> |
| 10204 | #include <arpa/inet.h> |
| 10205 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10206 | int |
| 10207 | main () |
| 10208 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10209 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10210 | ; |
| 10211 | return 0; |
| 10212 | } |
| 10213 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10214 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10215 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10216 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10217 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10219 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10220 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10222 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10223 | |
| 10224 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10225 | rm -f core conftest.err conftest.$ac_objext \ |
| 10226 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10227 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10228 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 10229 | $as_echo_n "checking for inet_pton... " >&6; } |
| 10230 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10231 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10232 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10233 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10234 | #include <sys/socket.h> |
| 10235 | #include <netinet/in.h> |
| 10236 | #include <arpa/inet.h> |
| 10237 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10238 | int |
| 10239 | main () |
| 10240 | { |
| 10241 | void* p = inet_pton |
| 10242 | ; |
| 10243 | return 0; |
| 10244 | } |
| 10245 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10246 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10247 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10248 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10249 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10250 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10251 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10252 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10254 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10255 | |
| 10256 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10257 | 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] | 10258 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10259 | # On some systems, setgroups is in unistd.h, on others, in grp.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10260 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 10261 | $as_echo_n "checking for setgroups... " >&6; } |
| 10262 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10263 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10264 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10265 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10266 | #ifdef HAVE_GRP_H |
| 10267 | #include <grp.h> |
| 10268 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10269 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10270 | int |
| 10271 | main () |
| 10272 | { |
| 10273 | void* p = setgroups |
| 10274 | ; |
| 10275 | return 0; |
| 10276 | } |
| 10277 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10278 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10279 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10280 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10281 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10282 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10283 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10284 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10285 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10286 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10287 | |
| 10288 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10289 | 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] | 10290 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10291 | # check for openpty and forkpty |
| 10292 | |
| 10293 | for ac_func in openpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10294 | do : |
| 10295 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10296 | if test "x$ac_cv_func_openpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10297 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10298 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10299 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10300 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10301 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10302 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 10303 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10304 | if ${ac_cv_lib_util_openpty+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10305 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10306 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10307 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10308 | LIBS="-lutil $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10309 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10310 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10311 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10312 | /* Override any GCC internal prototype to avoid an error. |
| 10313 | Use char because int might match the return type of a GCC |
| 10314 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10315 | #ifdef __cplusplus |
| 10316 | extern "C" |
| 10317 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10318 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10319 | int |
| 10320 | main () |
| 10321 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10322 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10323 | ; |
| 10324 | return 0; |
| 10325 | } |
| 10326 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10327 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10328 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10329 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10330 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10331 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10332 | rm -f core conftest.err conftest.$ac_objext \ |
| 10333 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10334 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10335 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 10337 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10338 | if test "x$ac_cv_lib_util_openpty" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10339 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10340 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10341 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 10343 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10344 | if ${ac_cv_lib_bsd_openpty+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10345 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10346 | else |
| 10347 | ac_check_lib_save_LIBS=$LIBS |
| 10348 | LIBS="-lbsd $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10349 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10350 | /* end confdefs.h. */ |
| 10351 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10352 | /* Override any GCC internal prototype to avoid an error. |
| 10353 | Use char because int might match the return type of a GCC |
| 10354 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10355 | #ifdef __cplusplus |
| 10356 | extern "C" |
| 10357 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10358 | char openpty (); |
| 10359 | int |
| 10360 | main () |
| 10361 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10362 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10363 | ; |
| 10364 | return 0; |
| 10365 | } |
| 10366 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10367 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10368 | ac_cv_lib_bsd_openpty=yes |
| 10369 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10370 | ac_cv_lib_bsd_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10371 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10372 | rm -f core conftest.err conftest.$ac_objext \ |
| 10373 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10374 | LIBS=$ac_check_lib_save_LIBS |
| 10375 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 10377 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10378 | if test "x$ac_cv_lib_bsd_openpty" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10379 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10380 | LIBS="$LIBS -lbsd" |
| 10381 | fi |
| 10382 | |
| 10383 | |
| 10384 | fi |
| 10385 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10386 | |
| 10387 | fi |
| 10388 | done |
| 10389 | |
| 10390 | for ac_func in forkpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10391 | do : |
| 10392 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10393 | if test "x$ac_cv_func_forkpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10394 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10395 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10396 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10397 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10398 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10399 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 10400 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10401 | if ${ac_cv_lib_util_forkpty+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10402 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10403 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10404 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10405 | LIBS="-lutil $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10406 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10407 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10408 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10409 | /* Override any GCC internal prototype to avoid an error. |
| 10410 | Use char because int might match the return type of a GCC |
| 10411 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10412 | #ifdef __cplusplus |
| 10413 | extern "C" |
| 10414 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10415 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10416 | int |
| 10417 | main () |
| 10418 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10419 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10420 | ; |
| 10421 | return 0; |
| 10422 | } |
| 10423 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10424 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10425 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10426 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10427 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10428 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10429 | rm -f core conftest.err conftest.$ac_objext \ |
| 10430 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10431 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10432 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10433 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 10434 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10435 | if test "x$ac_cv_lib_util_forkpty" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10436 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10437 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10438 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10439 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 10440 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10441 | if ${ac_cv_lib_bsd_forkpty+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10442 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10443 | else |
| 10444 | ac_check_lib_save_LIBS=$LIBS |
| 10445 | LIBS="-lbsd $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10446 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10447 | /* end confdefs.h. */ |
| 10448 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10449 | /* Override any GCC internal prototype to avoid an error. |
| 10450 | Use char because int might match the return type of a GCC |
| 10451 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10452 | #ifdef __cplusplus |
| 10453 | extern "C" |
| 10454 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10455 | char forkpty (); |
| 10456 | int |
| 10457 | main () |
| 10458 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10459 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10460 | ; |
| 10461 | return 0; |
| 10462 | } |
| 10463 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10464 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10465 | ac_cv_lib_bsd_forkpty=yes |
| 10466 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10467 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10468 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10469 | rm -f core conftest.err conftest.$ac_objext \ |
| 10470 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10471 | LIBS=$ac_check_lib_save_LIBS |
| 10472 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 10474 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10475 | if test "x$ac_cv_lib_bsd_forkpty" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10476 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10477 | LIBS="$LIBS -lbsd" |
| 10478 | fi |
| 10479 | |
| 10480 | |
| 10481 | fi |
| 10482 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10483 | |
| 10484 | fi |
| 10485 | done |
| 10486 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10487 | |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10488 | # Stuff for expat. |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10489 | for ac_func in memmove |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10490 | do : |
| 10491 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10492 | if test "x$ac_cv_func_memmove" = xyes; then : |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10493 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10494 | #define HAVE_MEMMOVE 1 |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10495 | _ACEOF |
| 10496 | |
| 10497 | fi |
| 10498 | done |
| 10499 | |
| 10500 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10501 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10502 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10503 | do : |
| 10504 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10505 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10506 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10507 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10508 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10509 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10510 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10511 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10512 | done |
| 10513 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10514 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10515 | ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2" |
| 10516 | if test "x$ac_cv_func_dup2" = xyes; then : |
| 10517 | $as_echo "#define HAVE_DUP2 1" >>confdefs.h |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10518 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10519 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10520 | case " $LIBOBJS " in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10521 | *" dup2.$ac_objext "* ) ;; |
| 10522 | *) LIBOBJS="$LIBOBJS dup2.$ac_objext" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10523 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10524 | esac |
| 10525 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10526 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10527 | |
| 10528 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" |
| 10529 | if test "x$ac_cv_func_getcwd" = xyes; then : |
| 10530 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h |
| 10531 | |
| 10532 | else |
| 10533 | case " $LIBOBJS " in |
| 10534 | *" getcwd.$ac_objext "* ) ;; |
| 10535 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
| 10536 | ;; |
| 10537 | esac |
| 10538 | |
| 10539 | fi |
| 10540 | |
| 10541 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" |
| 10542 | if test "x$ac_cv_func_strdup" = xyes; then : |
| 10543 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h |
| 10544 | |
| 10545 | else |
| 10546 | case " $LIBOBJS " in |
| 10547 | *" strdup.$ac_objext "* ) ;; |
| 10548 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" |
| 10549 | ;; |
| 10550 | esac |
| 10551 | |
| 10552 | fi |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10553 | |
| 10554 | |
| 10555 | for ac_func in getpgrp |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10556 | do : |
| 10557 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10558 | if test "x$ac_cv_func_getpgrp" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10559 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10560 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10561 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10562 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10563 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10564 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10565 | int |
| 10566 | main () |
| 10567 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10568 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10569 | ; |
| 10570 | return 0; |
| 10571 | } |
| 10572 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10573 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10574 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10575 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10576 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10577 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10578 | 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] | 10579 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10580 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10581 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10582 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10583 | for ac_func in setpgrp |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10584 | do : |
| 10585 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10586 | if test "x$ac_cv_func_setpgrp" = xyes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10587 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10588 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10589 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10590 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10591 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10592 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10593 | int |
| 10594 | main () |
| 10595 | { |
| 10596 | setpgrp(0,0); |
| 10597 | ; |
| 10598 | return 0; |
| 10599 | } |
| 10600 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10601 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10602 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10603 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10604 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10605 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10606 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10607 | |
| 10608 | fi |
| 10609 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10610 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10611 | for ac_func in gettimeofday |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10612 | do : |
| 10613 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10614 | if test "x$ac_cv_func_gettimeofday" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10615 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10616 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10617 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10618 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10619 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10620 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10621 | int |
| 10622 | main () |
| 10623 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10624 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10625 | ; |
| 10626 | return 0; |
| 10627 | } |
| 10628 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10629 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10630 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10631 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10632 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10633 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10634 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10635 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10636 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10637 | 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] | 10638 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10639 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10640 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10641 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10642 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10643 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 10644 | $as_echo_n "checking for major... " >&6; } |
| 10645 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10646 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10647 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 10648 | #if defined(MAJOR_IN_MKDEV) |
| 10649 | #include <sys/mkdev.h> |
| 10650 | #elif defined(MAJOR_IN_SYSMACROS) |
| 10651 | #include <sys/sysmacros.h> |
| 10652 | #else |
| 10653 | #include <sys/types.h> |
| 10654 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10655 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10656 | int |
| 10657 | main () |
| 10658 | { |
| 10659 | |
| 10660 | makedev(major(0),minor(0)); |
| 10661 | |
| 10662 | ; |
| 10663 | return 0; |
| 10664 | } |
| 10665 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10666 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10667 | |
| 10668 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10669 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10670 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10671 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10672 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10673 | |
| 10674 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10675 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10676 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10677 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10678 | |
| 10679 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10680 | rm -f core conftest.err conftest.$ac_objext \ |
| 10681 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10682 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10683 | # 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] | 10684 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10685 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 10686 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 10687 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10688 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10689 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10690 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10691 | #include <sys/socket.h> |
| 10692 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10693 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10694 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10695 | int |
| 10696 | main () |
| 10697 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10698 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10699 | ; |
| 10700 | return 0; |
| 10701 | } |
| 10702 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10703 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10704 | have_getaddrinfo=yes |
| 10705 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10706 | have_getaddrinfo=no |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10707 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10708 | rm -f core conftest.err conftest.$ac_objext \ |
| 10709 | conftest$ac_exeext conftest.$ac_ext |
| 10710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 10711 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10712 | if test $have_getaddrinfo = yes |
| 10713 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 10715 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10716 | if ${ac_cv_buggy_getaddrinfo+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10717 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10718 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10719 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10720 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10721 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10722 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10723 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10724 | |
| 10725 | #include <sys/types.h> |
| 10726 | #include <netdb.h> |
| 10727 | #include <string.h> |
| 10728 | #include <sys/socket.h> |
| 10729 | #include <netinet/in.h> |
| 10730 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10731 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10732 | { |
| 10733 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 10734 | struct addrinfo hints, *ai, *aitop; |
| 10735 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 10736 | |
| 10737 | for (passive = 0; passive <= 1; passive++) { |
| 10738 | memset(&hints, 0, sizeof(hints)); |
| 10739 | hints.ai_family = AF_UNSPEC; |
| 10740 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 10741 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 10742 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10743 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 10744 | (void)gai_strerror(gaierr); |
| 10745 | goto bad; |
| 10746 | } |
| 10747 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 10748 | if (ai->ai_addr == NULL || |
| 10749 | ai->ai_addrlen == 0 || |
| 10750 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 10751 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 10752 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 10753 | goto bad; |
| 10754 | } |
| 10755 | switch (ai->ai_family) { |
| 10756 | case AF_INET: |
| 10757 | if (strcmp(strport, "54321") != 0) { |
| 10758 | goto bad; |
| 10759 | } |
| 10760 | if (passive) { |
| 10761 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 10762 | goto bad; |
| 10763 | } |
| 10764 | } else { |
| 10765 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 10766 | goto bad; |
| 10767 | } |
| 10768 | } |
| 10769 | inet4++; |
| 10770 | break; |
| 10771 | case AF_INET6: |
| 10772 | if (strcmp(strport, "54321") != 0) { |
| 10773 | goto bad; |
| 10774 | } |
| 10775 | if (passive) { |
| 10776 | if (strcmp(straddr, "::") != 0) { |
| 10777 | goto bad; |
| 10778 | } |
| 10779 | } else { |
| 10780 | if (strcmp(straddr, "::1") != 0) { |
| 10781 | goto bad; |
| 10782 | } |
| 10783 | } |
| 10784 | inet6++; |
| 10785 | break; |
| 10786 | case AF_UNSPEC: |
| 10787 | goto bad; |
| 10788 | break; |
| 10789 | default: |
| 10790 | /* another family support? */ |
| 10791 | break; |
| 10792 | } |
| 10793 | } |
| 10794 | } |
| 10795 | |
| 10796 | if (!(inet4 == 0 || inet4 == 2)) |
| 10797 | goto bad; |
| 10798 | if (!(inet6 == 0 || inet6 == 2)) |
| 10799 | goto bad; |
| 10800 | |
| 10801 | if (aitop) |
| 10802 | freeaddrinfo(aitop); |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10803 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10804 | |
| 10805 | bad: |
| 10806 | if (aitop) |
| 10807 | freeaddrinfo(aitop); |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10808 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10809 | } |
| 10810 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10811 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10812 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10813 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10814 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10815 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10816 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10817 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10818 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10819 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10820 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10821 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10822 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10823 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10824 | |
Benjamin Peterson | 75fed81 | 2010-11-01 01:47:19 +0000 | [diff] [blame] | 10825 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5 |
| 10826 | $as_echo "$ac_cv_buggy_getaddrinfo" >&6; } |
| 10827 | |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 10828 | if test $have_getaddrinfo = no -o "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10829 | then |
| 10830 | if test $ipv6 = yes |
| 10831 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10832 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 10833 | echo ' or you can specify "--disable-ipv6"'. |
| 10834 | exit 1 |
| 10835 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10836 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10837 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10838 | $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10839 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10840 | fi |
Benjamin Peterson | 75fed81 | 2010-11-01 01:47:19 +0000 | [diff] [blame] | 10841 | |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 10842 | for ac_func in getnameinfo |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10843 | do : |
| 10844 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10845 | if test "x$ac_cv_func_getnameinfo" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10846 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10847 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10848 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10849 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10850 | fi |
| 10851 | done |
| 10852 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10853 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10854 | # checks for structures |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10855 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 10856 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10857 | if ${ac_cv_header_time+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10858 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10859 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10860 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10861 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10862 | #include <sys/types.h> |
| 10863 | #include <sys/time.h> |
| 10864 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10865 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10866 | int |
| 10867 | main () |
| 10868 | { |
| 10869 | if ((struct tm *) 0) |
| 10870 | return 0; |
| 10871 | ; |
| 10872 | return 0; |
| 10873 | } |
| 10874 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10875 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10876 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10877 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10878 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10879 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10880 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10881 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10882 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 10883 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10884 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10885 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10886 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10887 | |
| 10888 | fi |
| 10889 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10890 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 10891 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10892 | if ${ac_cv_struct_tm+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10893 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10894 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10895 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10896 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10897 | #include <sys/types.h> |
| 10898 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10899 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10900 | int |
| 10901 | main () |
| 10902 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10903 | struct tm tm; |
| 10904 | int *p = &tm.tm_sec; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10905 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10906 | ; |
| 10907 | return 0; |
| 10908 | } |
| 10909 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10910 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10911 | ac_cv_struct_tm=time.h |
| 10912 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10913 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10914 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10915 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10916 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
| 10918 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10919 | if test $ac_cv_struct_tm = sys/time.h; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10920 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10921 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10922 | |
| 10923 | fi |
| 10924 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10925 | 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] | 10926 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10927 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10928 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10929 | 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] | 10930 | |
| 10931 | cat >>confdefs.h <<_ACEOF |
| 10932 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 10933 | _ACEOF |
| 10934 | |
| 10935 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10936 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10937 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10938 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 10939 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10940 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10941 | |
| 10942 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10943 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 10944 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10945 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10946 | ac_have_decl=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10947 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10948 | ac_have_decl=0 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10949 | fi |
| 10950 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10951 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10952 | #define HAVE_DECL_TZNAME $ac_have_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10953 | _ACEOF |
| 10954 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10955 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 10956 | $as_echo_n "checking for tzname... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10957 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10958 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10959 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10960 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10961 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10962 | #include <time.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10963 | #if !HAVE_DECL_TZNAME |
| 10964 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10965 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10966 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10967 | int |
| 10968 | main () |
| 10969 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10970 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10971 | ; |
| 10972 | return 0; |
| 10973 | } |
| 10974 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10975 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10976 | ac_cv_var_tzname=yes |
| 10977 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10978 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10979 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10980 | rm -f core conftest.err conftest.$ac_objext \ |
| 10981 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10982 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 10984 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10985 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10986 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10987 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10988 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10989 | fi |
| 10990 | fi |
| 10991 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10992 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 10993 | 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] | 10994 | |
| 10995 | cat >>confdefs.h <<_ACEOF |
| 10996 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 10997 | _ACEOF |
| 10998 | |
| 10999 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 11000 | fi |
| 11001 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11002 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11003 | if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11004 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11005 | cat >>confdefs.h <<_ACEOF |
| 11006 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 11007 | _ACEOF |
| 11008 | |
| 11009 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 11010 | fi |
| 11011 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11012 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11013 | 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] | 11014 | |
| 11015 | cat >>confdefs.h <<_ACEOF |
| 11016 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 11017 | _ACEOF |
| 11018 | |
| 11019 | |
| 11020 | fi |
| 11021 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11022 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11023 | 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] | 11024 | |
| 11025 | cat >>confdefs.h <<_ACEOF |
| 11026 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 11027 | _ACEOF |
| 11028 | |
| 11029 | |
| 11030 | fi |
| 11031 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11032 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11033 | 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] | 11034 | |
| 11035 | cat >>confdefs.h <<_ACEOF |
| 11036 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 11037 | _ACEOF |
| 11038 | |
| 11039 | |
| 11040 | fi |
| 11041 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11042 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11043 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11044 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11045 | cat >>confdefs.h <<_ACEOF |
| 11046 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 11047 | _ACEOF |
| 11048 | |
| 11049 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11050 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 11051 | |
| 11052 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11053 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 11054 | *" fileblocks.$ac_objext "* ) ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11055 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 11056 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 11057 | esac |
| 11058 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 11059 | fi |
| 11060 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11061 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11062 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11063 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 11064 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11065 | if ${ac_cv_header_time_altzone+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11066 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11067 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11068 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11069 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11070 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11071 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11072 | int |
| 11073 | main () |
| 11074 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11075 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11076 | ; |
| 11077 | return 0; |
| 11078 | } |
| 11079 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11080 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11081 | ac_cv_header_time_altzone=yes |
| 11082 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11083 | ac_cv_header_time_altzone=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11084 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11085 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11086 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11087 | fi |
| 11088 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11089 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 11090 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11091 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11092 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11093 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11094 | |
| 11095 | fi |
| 11096 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11097 | was_it_defined=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11098 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 11099 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 11100 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11101 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11102 | |
| 11103 | #include <sys/types.h> |
| 11104 | #include <sys/select.h> |
| 11105 | #include <sys/time.h> |
| 11106 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11107 | int |
| 11108 | main () |
| 11109 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11110 | ; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11111 | ; |
| 11112 | return 0; |
| 11113 | } |
| 11114 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11115 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11116 | |
| 11117 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11118 | $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] | 11119 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11120 | was_it_defined=yes |
| 11121 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11122 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11123 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11124 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 11125 | $as_echo "$was_it_defined" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11126 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11127 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 11128 | $as_echo_n "checking for addrinfo... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11129 | if ${ac_cv_struct_addrinfo+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11130 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11131 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11132 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11133 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11134 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11135 | int |
| 11136 | main () |
| 11137 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11138 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11139 | ; |
| 11140 | return 0; |
| 11141 | } |
| 11142 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11143 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11144 | ac_cv_struct_addrinfo=yes |
| 11145 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11146 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11147 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11148 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11149 | fi |
| 11150 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11151 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 11152 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11153 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11154 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11155 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11156 | |
| 11157 | fi |
| 11158 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 11160 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11161 | if ${ac_cv_struct_sockaddr_storage+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11162 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11163 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11164 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11165 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11166 | |
| 11167 | # include <sys/types.h> |
| 11168 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11169 | int |
| 11170 | main () |
| 11171 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11172 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11173 | ; |
| 11174 | return 0; |
| 11175 | } |
| 11176 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11177 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11178 | ac_cv_struct_sockaddr_storage=yes |
| 11179 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11180 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11181 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11182 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11183 | fi |
| 11184 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 11186 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11187 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11188 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11189 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11190 | |
| 11191 | fi |
| 11192 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11193 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11194 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 11196 | $as_echo_n "checking whether char is unsigned... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11197 | if ${ac_cv_c_char_unsigned+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11198 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11199 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11200 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11201 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11202 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11203 | int |
| 11204 | main () |
| 11205 | { |
| 11206 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
| 11207 | test_array [0] = 0 |
| 11208 | |
| 11209 | ; |
| 11210 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11211 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11212 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11213 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11214 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11215 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11216 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11217 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11218 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11219 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11220 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 11221 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11222 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11223 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11224 | |
| 11225 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11226 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11227 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 11228 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11229 | if ${ac_cv_c_const+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11230 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11231 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11232 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11233 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11234 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11235 | int |
| 11236 | main () |
| 11237 | { |
| 11238 | /* FIXME: Include the comments suggested by Paul. */ |
| 11239 | #ifndef __cplusplus |
| 11240 | /* Ultrix mips cc rejects this. */ |
| 11241 | typedef int charset[2]; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11242 | const charset cs; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11243 | /* SunOS 4.1.1 cc rejects this. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11244 | char const *const *pcpcc; |
| 11245 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11246 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 11247 | struct point {int x, y;}; |
| 11248 | static struct point const zero = {0,0}; |
| 11249 | /* AIX XL C 1.02.0.0 rejects this. |
| 11250 | It does not let you subtract one const X* pointer from another in |
| 11251 | an arm of an if-expression whose if-part is not a constant |
| 11252 | expression */ |
| 11253 | const char *g = "string"; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11254 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11255 | /* HPUX 7.0 cc rejects these. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11256 | ++pcpcc; |
| 11257 | ppc = (char**) pcpcc; |
| 11258 | pcpcc = (char const *const *) ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11259 | { /* SCO 3.2v4 cc rejects this. */ |
| 11260 | char *t; |
| 11261 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11262 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11263 | *t++ = 0; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11264 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11265 | } |
| 11266 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 11267 | int x[] = {25, 17}; |
| 11268 | const int *foo = &x[0]; |
| 11269 | ++foo; |
| 11270 | } |
| 11271 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 11272 | typedef const int *iptr; |
| 11273 | iptr p = 0; |
| 11274 | ++p; |
| 11275 | } |
| 11276 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 11277 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 11278 | struct s { int j; const int *ap[3]; }; |
| 11279 | struct s *b; b->j = 5; |
| 11280 | } |
| 11281 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 11282 | const int foo = 10; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11283 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11284 | } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11285 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11286 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11287 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11288 | ; |
| 11289 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11290 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11291 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11292 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11293 | ac_cv_c_const=yes |
| 11294 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11295 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11296 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11297 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11298 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11299 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 11300 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11301 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11302 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11303 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11304 | |
| 11305 | fi |
| 11306 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11307 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11308 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11309 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 11310 | $as_echo_n "checking for working volatile... " >&6; } |
| 11311 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11312 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11313 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11314 | int |
| 11315 | main () |
| 11316 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11317 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11318 | ; |
| 11319 | return 0; |
| 11320 | } |
| 11321 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11322 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11323 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11324 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11325 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11326 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11327 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11328 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11329 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11330 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11331 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11332 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11333 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11334 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11335 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 11336 | $as_echo_n "checking for working signed char... " >&6; } |
| 11337 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11338 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11339 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11340 | int |
| 11341 | main () |
| 11342 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11343 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11344 | ; |
| 11345 | return 0; |
| 11346 | } |
| 11347 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11348 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11349 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11350 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11351 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11352 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11353 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11354 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11355 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11356 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11358 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11359 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11360 | have_prototypes=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11361 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 11362 | $as_echo_n "checking for prototypes... " >&6; } |
| 11363 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11364 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11365 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11366 | int |
| 11367 | main () |
| 11368 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11369 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11370 | ; |
| 11371 | return 0; |
| 11372 | } |
| 11373 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11374 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11375 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11376 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11377 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11378 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11379 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11380 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11381 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 11382 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11383 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11384 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11385 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 11386 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 11387 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11388 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11389 | |
| 11390 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11391 | int foo(int x, ...) { |
| 11392 | va_list va; |
| 11393 | va_start(va, x); |
| 11394 | va_arg(va, int); |
| 11395 | va_arg(va, char *); |
| 11396 | va_arg(va, double); |
| 11397 | return 0; |
| 11398 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11399 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11400 | int |
| 11401 | main () |
| 11402 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11403 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11404 | ; |
| 11405 | return 0; |
| 11406 | } |
| 11407 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11408 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11409 | |
| 11410 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11411 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11412 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11413 | works=yes |
| 11414 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11415 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11416 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11417 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11418 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11419 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11420 | # check for socketpair |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 11422 | $as_echo_n "checking for socketpair... " >&6; } |
| 11423 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11424 | /* end confdefs.h. */ |
| 11425 | |
| 11426 | #include <sys/types.h> |
| 11427 | #include <sys/socket.h> |
| 11428 | |
| 11429 | int |
| 11430 | main () |
| 11431 | { |
| 11432 | void *x=socketpair |
| 11433 | ; |
| 11434 | return 0; |
| 11435 | } |
| 11436 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11437 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11438 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11439 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11440 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11442 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11443 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11444 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11445 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11446 | |
| 11447 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11448 | 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] | 11449 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11450 | # check if sockaddr has sa_len member |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11451 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 11452 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 11453 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11454 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11455 | #include <sys/types.h> |
| 11456 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11457 | int |
| 11458 | main () |
| 11459 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11460 | struct sockaddr x; |
| 11461 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11462 | ; |
| 11463 | return 0; |
| 11464 | } |
| 11465 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11466 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11468 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11469 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11470 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11471 | |
| 11472 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11474 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11475 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11476 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11477 | 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] | 11478 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11479 | va_list_is_array=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11480 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 11481 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 11482 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11483 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11484 | |
| 11485 | #ifdef HAVE_STDARG_PROTOTYPES |
| 11486 | #include <stdarg.h> |
| 11487 | #else |
| 11488 | #include <varargs.h> |
| 11489 | #endif |
| 11490 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11491 | int |
| 11492 | main () |
| 11493 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11494 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11495 | ; |
| 11496 | return 0; |
| 11497 | } |
| 11498 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11499 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11500 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11501 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11502 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11503 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11504 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11505 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11506 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11507 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11508 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11509 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11510 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 11511 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11512 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11513 | # 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] | 11514 | |
| 11515 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11516 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11517 | if test "x$ac_cv_func_gethostbyname_r" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11518 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11519 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 11520 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11521 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 11522 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11523 | OLD_CFLAGS=$CFLAGS |
| 11524 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11525 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11526 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11527 | |
| 11528 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11529 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11530 | int |
| 11531 | main () |
| 11532 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11533 | |
| 11534 | char *name; |
| 11535 | struct hostent *he, *res; |
| 11536 | char buffer[2048]; |
| 11537 | int buflen = 2048; |
| 11538 | int h_errnop; |
| 11539 | |
| 11540 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11541 | |
| 11542 | ; |
| 11543 | return 0; |
| 11544 | } |
| 11545 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11546 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11547 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11548 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11549 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11550 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11551 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11552 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11553 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11554 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11555 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11556 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11557 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11558 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11559 | $as_echo "no" >&6; } |
| 11560 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 11561 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 11562 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11563 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11564 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11565 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11566 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11567 | int |
| 11568 | main () |
| 11569 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11570 | |
| 11571 | char *name; |
| 11572 | struct hostent *he; |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11573 | char buffer[2048]; |
| 11574 | int buflen = 2048; |
| 11575 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11576 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11577 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11578 | |
| 11579 | ; |
| 11580 | return 0; |
| 11581 | } |
| 11582 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11583 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11584 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11585 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11586 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11587 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11588 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11589 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11591 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11592 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11593 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11594 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11596 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11597 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 11598 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 11599 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11600 | /* end confdefs.h. */ |
| 11601 | |
| 11602 | # include <netdb.h> |
| 11603 | |
| 11604 | int |
| 11605 | main () |
| 11606 | { |
| 11607 | |
| 11608 | char *name; |
| 11609 | struct hostent *he; |
| 11610 | struct hostent_data data; |
| 11611 | |
| 11612 | (void) gethostbyname_r(name, he, &data); |
| 11613 | |
| 11614 | ; |
| 11615 | return 0; |
| 11616 | } |
| 11617 | _ACEOF |
| 11618 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11619 | |
| 11620 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 11621 | |
| 11622 | |
| 11623 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 11624 | |
| 11625 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11626 | $as_echo "yes" >&6; } |
| 11627 | |
| 11628 | else |
| 11629 | |
| 11630 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11631 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11632 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11633 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11634 | 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] | 11635 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11636 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11637 | 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] | 11638 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11639 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11640 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11641 | CFLAGS=$OLD_CFLAGS |
| 11642 | |
| 11643 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11644 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11645 | for ac_func in gethostbyname |
| 11646 | do : |
| 11647 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11648 | if test "x$ac_cv_func_gethostbyname" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11649 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11650 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11651 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11652 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11653 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11654 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11655 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11656 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11657 | fi |
| 11658 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11659 | |
| 11660 | |
| 11661 | |
| 11662 | |
| 11663 | |
| 11664 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11665 | # checks for system services |
| 11666 | # (none yet) |
| 11667 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11668 | # Linux requires this for correct f.p. operations |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11669 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11670 | if test "x$ac_cv_func___fpu_control" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11671 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11672 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11673 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 11674 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11675 | if ${ac_cv_lib_ieee___fpu_control+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11676 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11677 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11678 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11679 | LIBS="-lieee $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11680 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11681 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11682 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11683 | /* Override any GCC internal prototype to avoid an error. |
| 11684 | Use char because int might match the return type of a GCC |
| 11685 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11686 | #ifdef __cplusplus |
| 11687 | extern "C" |
| 11688 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11689 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11690 | int |
| 11691 | main () |
| 11692 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11693 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11694 | ; |
| 11695 | return 0; |
| 11696 | } |
| 11697 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11698 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11699 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11700 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11701 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11702 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11703 | rm -f core conftest.err conftest.$ac_objext \ |
| 11704 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11705 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11706 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11707 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 11708 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11709 | 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] | 11710 | cat >>confdefs.h <<_ACEOF |
| 11711 | #define HAVE_LIBIEEE 1 |
| 11712 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11713 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11714 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11715 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11716 | fi |
| 11717 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11718 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11719 | fi |
| 11720 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11721 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11722 | # Check for --with-fpectl |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11723 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 11724 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11725 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11726 | # Check whether --with-fpectl was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11727 | if test "${with_fpectl+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11728 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11729 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11730 | then |
| 11731 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11732 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11733 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11735 | $as_echo "yes" >&6; } |
| 11736 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11737 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11738 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 11739 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11741 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11742 | fi |
| 11743 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11744 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11745 | # check for --with-libm=... |
| 11746 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11747 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 11748 | Darwin) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 11749 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11750 | *) LIBM=-lm |
| 11751 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11752 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 11753 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11754 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11755 | # Check whether --with-libm was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11756 | if test "${with_libm+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11757 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11758 | if test "$withval" = no |
| 11759 | then LIBM= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11760 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 11761 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11762 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11763 | then LIBM=$withval |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11764 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 11765 | $as_echo "set LIBM=\"$withval\"" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11766 | 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] | 11767 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11768 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11769 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 11770 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11771 | fi |
| 11772 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11773 | |
| 11774 | # check for --with-libc=... |
| 11775 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11776 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 11777 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11778 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11779 | # Check whether --with-libc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11780 | if test "${with_libc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11781 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11782 | if test "$withval" = no |
| 11783 | then LIBC= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11784 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 11785 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11786 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11787 | then LIBC=$withval |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 11789 | $as_echo "set LIBC=\"$withval\"" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11790 | 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] | 11791 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11792 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11793 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 11794 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11795 | fi |
| 11796 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11797 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11798 | # ************************************************** |
| 11799 | # * Check for various properties of floating point * |
| 11800 | # ************************************************** |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11801 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11802 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 11803 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11804 | if ${ac_cv_little_endian_double+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11805 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11806 | else |
| 11807 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11808 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11809 | ac_cv_little_endian_double=no |
| 11810 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11811 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11812 | /* end confdefs.h. */ |
| 11813 | |
| 11814 | #include <string.h> |
| 11815 | int main() { |
| 11816 | double x = 9006104071832581.0; |
| 11817 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 11818 | return 0; |
| 11819 | else |
| 11820 | return 1; |
| 11821 | } |
| 11822 | |
| 11823 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11824 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11825 | ac_cv_little_endian_double=yes |
| 11826 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11827 | ac_cv_little_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11828 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11829 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11830 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11831 | fi |
| 11832 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11833 | fi |
| 11834 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 11836 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11837 | if test "$ac_cv_little_endian_double" = yes |
| 11838 | then |
| 11839 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11840 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11841 | |
| 11842 | fi |
| 11843 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11844 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 11845 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11846 | if ${ac_cv_big_endian_double+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11847 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11848 | else |
| 11849 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11850 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11851 | ac_cv_big_endian_double=no |
| 11852 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11853 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11854 | /* end confdefs.h. */ |
| 11855 | |
| 11856 | #include <string.h> |
| 11857 | int main() { |
| 11858 | double x = 9006104071832581.0; |
| 11859 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 11860 | return 0; |
| 11861 | else |
| 11862 | return 1; |
| 11863 | } |
| 11864 | |
| 11865 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11866 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11867 | ac_cv_big_endian_double=yes |
| 11868 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11869 | ac_cv_big_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11870 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11871 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11872 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11873 | fi |
| 11874 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11875 | fi |
| 11876 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11877 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 11878 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11879 | if test "$ac_cv_big_endian_double" = yes |
| 11880 | then |
| 11881 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11882 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11883 | |
| 11884 | fi |
| 11885 | |
| 11886 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 11887 | # While Python doesn't currently have full support for these platforms |
| 11888 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 11889 | # conversions work. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11890 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 11891 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 11892 | if ${ac_cv_mixed_endian_double+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11893 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11894 | else |
| 11895 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11896 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11897 | ac_cv_mixed_endian_double=no |
| 11898 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11899 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11900 | /* end confdefs.h. */ |
| 11901 | |
| 11902 | #include <string.h> |
| 11903 | int main() { |
| 11904 | double x = 9006104071832581.0; |
| 11905 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 11906 | return 0; |
| 11907 | else |
| 11908 | return 1; |
| 11909 | } |
| 11910 | |
| 11911 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11912 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11913 | ac_cv_mixed_endian_double=yes |
| 11914 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11915 | ac_cv_mixed_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11916 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11917 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11918 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11919 | fi |
| 11920 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11921 | fi |
| 11922 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 11924 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11925 | if test "$ac_cv_mixed_endian_double" = yes |
| 11926 | then |
| 11927 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11928 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11929 | |
| 11930 | fi |
| 11931 | |
| 11932 | # The short float repr introduced in Python 3.1 requires the |
| 11933 | # correctly-rounded string <-> double conversion functions from |
| 11934 | # Python/dtoa.c, which in turn require that the FPU uses 53-bit |
| 11935 | # rounding; this is a problem on x86, where the x87 FPU has a default |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11936 | # rounding precision of 64 bits. For gcc/x86, we can fix this by |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11937 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11938 | |
| 11939 | # This inline assembler syntax may also work for suncc and icc, |
| 11940 | # so we try it on all platforms. |
| 11941 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11942 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 11943 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 11944 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11945 | /* end confdefs.h. */ |
| 11946 | |
| 11947 | int |
| 11948 | main () |
| 11949 | { |
| 11950 | |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11951 | unsigned short cw; |
| 11952 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 11953 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11954 | |
| 11955 | ; |
| 11956 | return 0; |
| 11957 | } |
| 11958 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11959 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11960 | have_gcc_asm_for_x87=yes |
| 11961 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11962 | have_gcc_asm_for_x87=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11963 | fi |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11964 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11965 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 11966 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11967 | if test "$have_gcc_asm_for_x87" = yes |
| 11968 | then |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11969 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11970 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11971 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11972 | fi |
Mark Dickinson | 7a3d864 | 2008-04-22 00:54:27 +0000 | [diff] [blame] | 11973 | |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11974 | # Detect whether system arithmetic is subject to x87-style double |
| 11975 | # rounding issues. The result of this test has little meaning on non |
| 11976 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 11977 | # mode is round-to-nearest and double rounding issues are present, and |
| 11978 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11979 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 11980 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | 99abd14 | 2009-10-24 13:44:16 +0000 | [diff] [blame] | 11981 | # $BASECFLAGS may affect the result |
| 11982 | ac_save_cc="$CC" |
| 11983 | CC="$CC $BASECFLAGS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11984 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11985 | ac_cv_x87_double_rounding=no |
| 11986 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11987 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11988 | /* end confdefs.h. */ |
| 11989 | |
| 11990 | #include <stdlib.h> |
| 11991 | #include <math.h> |
| 11992 | int main() { |
| 11993 | volatile double x, y, z; |
| 11994 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 11995 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 11996 | y = 1./x; |
| 11997 | if (y != 1.) |
| 11998 | exit(0); |
| 11999 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 12000 | x = 1e16; |
| 12001 | y = 2.99999; |
| 12002 | z = x + y; |
| 12003 | if (z != 1e16+4.) |
| 12004 | exit(0); |
| 12005 | /* both tests show evidence of double rounding */ |
| 12006 | exit(1); |
| 12007 | } |
| 12008 | |
| 12009 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12010 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 12011 | ac_cv_x87_double_rounding=no |
| 12012 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12013 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 12014 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12015 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12016 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 12017 | fi |
| 12018 | |
Mark Dickinson | 99abd14 | 2009-10-24 13:44:16 +0000 | [diff] [blame] | 12019 | CC="$ac_save_cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12020 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 12021 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 12022 | if test "$ac_cv_x87_double_rounding" = yes |
| 12023 | then |
| 12024 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12025 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 12026 | |
| 12027 | fi |
| 12028 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 12029 | # ************************************ |
| 12030 | # * Check for mathematical functions * |
| 12031 | # ************************************ |
| 12032 | |
| 12033 | LIBS_SAVE=$LIBS |
| 12034 | LIBS="$LIBS $LIBM" |
| 12035 | |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12036 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 12037 | # -0. on some architectures. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12038 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 12039 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12040 | if ${ac_cv_tanh_preserves_zero_sign+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12041 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12042 | else |
| 12043 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12044 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12045 | ac_cv_tanh_preserves_zero_sign=no |
| 12046 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12047 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12048 | /* end confdefs.h. */ |
| 12049 | |
| 12050 | #include <math.h> |
Mark Dickinson | 7a3d864 | 2008-04-22 00:54:27 +0000 | [diff] [blame] | 12051 | #include <stdlib.h> |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12052 | int main() { |
| 12053 | /* return 0 if either negative zeros don't exist |
| 12054 | on this platform or if negative zeros exist |
| 12055 | and tanh(-0.) == -0. */ |
| 12056 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 12057 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 12058 | else exit(1); |
| 12059 | } |
| 12060 | |
| 12061 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12062 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12063 | ac_cv_tanh_preserves_zero_sign=yes |
| 12064 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12065 | ac_cv_tanh_preserves_zero_sign=no |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12066 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12067 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12068 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12069 | fi |
| 12070 | |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12071 | fi |
| 12072 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12073 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 12074 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12075 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 12076 | then |
| 12077 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12078 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 12079 | |
| 12080 | fi |
| 12081 | |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12082 | for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12083 | do : |
| 12084 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 12085 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12086 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12087 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12088 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12089 | _ACEOF |
| 12090 | |
| 12091 | fi |
| 12092 | done |
| 12093 | |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12094 | for ac_func in hypot lgamma log1p round tgamma |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12095 | do : |
| 12096 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 12097 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12098 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Christian Heimes | 0a8143f | 2007-12-18 23:22:54 +0000 | [diff] [blame] | 12099 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12100 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Christian Heimes | 0a8143f | 2007-12-18 23:22:54 +0000 | [diff] [blame] | 12101 | _ACEOF |
| 12102 | |
| 12103 | fi |
| 12104 | done |
| 12105 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12106 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 12107 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12108 | if test "x$ac_cv_have_decl_isinf" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12109 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12110 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12111 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12112 | fi |
| 12113 | |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12114 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12115 | #define HAVE_DECL_ISINF $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12116 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12117 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 12118 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12119 | if test "x$ac_cv_have_decl_isnan" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12120 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12121 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12122 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12123 | fi |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12124 | |
| 12125 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12126 | #define HAVE_DECL_ISNAN $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12127 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12128 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 12129 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12130 | if test "x$ac_cv_have_decl_isfinite" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12131 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12132 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12133 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12134 | fi |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12135 | |
| 12136 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12137 | #define HAVE_DECL_ISFINITE $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12138 | _ACEOF |
| 12139 | |
| 12140 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 12141 | LIBS=$LIBS_SAVE |
| 12142 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12143 | # For multiprocessing module, check that sem_open |
| 12144 | # actually works. For FreeBSD versions <= 7.2, |
| 12145 | # the kernel module that provides POSIX semaphores |
| 12146 | # isn't loaded by default, so an attempt to call |
| 12147 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12148 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 12149 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12150 | if ${ac_cv_posix_semaphores_enabled+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12151 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12152 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12153 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12154 | ac_cv_posix_semaphores_enabled=yes |
| 12155 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12156 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12157 | /* end confdefs.h. */ |
| 12158 | |
| 12159 | #include <unistd.h> |
| 12160 | #include <fcntl.h> |
| 12161 | #include <stdio.h> |
| 12162 | #include <semaphore.h> |
| 12163 | #include <sys/stat.h> |
| 12164 | |
| 12165 | int main(void) { |
| 12166 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 12167 | if (a == SEM_FAILED) { |
| 12168 | perror("sem_open"); |
| 12169 | return 1; |
| 12170 | } |
| 12171 | sem_close(a); |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12172 | sem_unlink("/autoconf"); |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12173 | return 0; |
| 12174 | } |
| 12175 | |
| 12176 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12177 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12178 | ac_cv_posix_semaphores_enabled=yes |
| 12179 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12180 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12181 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12182 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12183 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12184 | fi |
| 12185 | |
| 12186 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12187 | fi |
| 12188 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 12190 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12191 | if test $ac_cv_posix_semaphores_enabled = no |
| 12192 | then |
| 12193 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12194 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12195 | |
| 12196 | fi |
| 12197 | |
| 12198 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12199 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 12200 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12201 | if ${ac_cv_broken_sem_getvalue+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12202 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12203 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12204 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12205 | ac_cv_broken_sem_getvalue=yes |
| 12206 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12207 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12208 | /* end confdefs.h. */ |
| 12209 | |
| 12210 | #include <unistd.h> |
| 12211 | #include <fcntl.h> |
| 12212 | #include <stdio.h> |
| 12213 | #include <semaphore.h> |
| 12214 | #include <sys/stat.h> |
| 12215 | |
| 12216 | int main(void){ |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12217 | sem_t *a = sem_open("/autocftw", O_CREAT, S_IRUSR|S_IWUSR, 0); |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12218 | int count; |
| 12219 | int res; |
| 12220 | if(a==SEM_FAILED){ |
| 12221 | perror("sem_open"); |
| 12222 | return 1; |
| 12223 | |
| 12224 | } |
| 12225 | res = sem_getvalue(a, &count); |
| 12226 | sem_close(a); |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12227 | sem_unlink("/autocftw"); |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12228 | return res==-1 ? 1 : 0; |
| 12229 | } |
| 12230 | |
| 12231 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12232 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12233 | ac_cv_broken_sem_getvalue=no |
| 12234 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12235 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12236 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +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 |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12239 | fi |
| 12240 | |
| 12241 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12242 | fi |
| 12243 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12244 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 12245 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12246 | if test $ac_cv_broken_sem_getvalue = yes |
| 12247 | then |
| 12248 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12249 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12250 | |
| 12251 | fi |
| 12252 | |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12253 | # determine what size digit to use for Python's longs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12254 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 12255 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12256 | # Check whether --enable-big-digits was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12257 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12258 | enableval=$enable_big_digits; case $enable_big_digits in |
| 12259 | yes) |
| 12260 | enable_big_digits=30 ;; |
| 12261 | no) |
| 12262 | enable_big_digits=15 ;; |
| 12263 | 15|30) |
| 12264 | ;; |
| 12265 | *) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12266 | as_fn_error $? "bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" "$LINENO" 5 ;; |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12267 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 12269 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12270 | |
| 12271 | cat >>confdefs.h <<_ACEOF |
| 12272 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 12273 | _ACEOF |
| 12274 | |
| 12275 | |
| 12276 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 12278 | $as_echo "no value specified" >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12279 | fi |
| 12280 | |
| 12281 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12282 | # check for wchar.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12283 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12284 | if test "x$ac_cv_header_wchar_h" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12285 | |
| 12286 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12287 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12288 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12289 | wchar_h="yes" |
| 12290 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12291 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12292 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12293 | |
| 12294 | fi |
| 12295 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12296 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12297 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12298 | # determine wchar_t size |
| 12299 | if test "$wchar_h" = yes |
| 12300 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12301 | # The cast to long int works around a bug in the HP C Compiler |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12302 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 12303 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 12304 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12305 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 12306 | $as_echo_n "checking size of wchar_t... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12307 | if ${ac_cv_sizeof_wchar_t+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12308 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12309 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12310 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 12311 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12312 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12313 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12314 | if test "$ac_cv_type_wchar_t" = yes; then |
| 12315 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 12316 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12317 | as_fn_error 77 "cannot compute sizeof (wchar_t) |
| 12318 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12319 | else |
| 12320 | ac_cv_sizeof_wchar_t=0 |
| 12321 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12322 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12323 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12324 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 12326 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12327 | |
| 12328 | |
| 12329 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12330 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12331 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12332 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12333 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12334 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12335 | fi |
| 12336 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 12338 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12339 | have_ucs4_tcl=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12340 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12341 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12342 | |
| 12343 | #include <tcl.h> |
| 12344 | #if TCL_UTF_MAX != 6 |
| 12345 | # error "NOT UCS4_TCL" |
| 12346 | #endif |
| 12347 | int |
| 12348 | main () |
| 12349 | { |
| 12350 | |
| 12351 | ; |
| 12352 | return 0; |
| 12353 | } |
| 12354 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12355 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12356 | |
| 12357 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12358 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12359 | |
| 12360 | have_ucs4_tcl=yes |
| 12361 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12362 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12363 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12364 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 12365 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12366 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12367 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12368 | if test "$wchar_h" = yes |
| 12369 | then |
| 12370 | # check whether wchar_t is signed or not |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 12372 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12373 | if ${ac_cv_wchar_t_signed+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12374 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12375 | else |
| 12376 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12377 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12378 | ac_cv_wchar_t_signed=yes |
| 12379 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +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. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12382 | |
| 12383 | #include <wchar.h> |
| 12384 | int main() |
| 12385 | { |
Martin v. Löwis | 44fe0e4 | 2006-04-11 07:15:30 +0000 | [diff] [blame] | 12386 | /* Success: exit code 0 */ |
| 12387 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12388 | } |
| 12389 | |
| 12390 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12391 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12392 | ac_cv_wchar_t_signed=yes |
| 12393 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12394 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12395 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12396 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12397 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12398 | fi |
| 12399 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12400 | fi |
| 12401 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 12403 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12404 | fi |
| 12405 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12406 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type to use for unicode" >&5 |
| 12407 | $as_echo_n "checking what type to use for unicode... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12408 | # Check whether --enable-unicode was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12409 | if test "${enable_unicode+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12410 | enableval=$enable_unicode; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12411 | else |
| 12412 | enable_unicode=yes |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12413 | fi |
| 12414 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12415 | |
| 12416 | if test $enable_unicode = yes |
| 12417 | then |
Martin v. Löwis | fd91779 | 2001-06-27 20:22:04 +0000 | [diff] [blame] | 12418 | # Without any arguments, Py_UNICODE defaults to two-byte mode |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12419 | case "$have_ucs4_tcl" in |
| 12420 | yes) enable_unicode="ucs4" |
| 12421 | ;; |
| 12422 | *) enable_unicode="ucs2" |
| 12423 | ;; |
| 12424 | esac |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12425 | fi |
| 12426 | |
Martin v. Löwis | 0036cba | 2002-04-12 09:58:45 +0000 | [diff] [blame] | 12427 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12428 | case "$enable_unicode" in |
| 12429 | ucs2) unicode_size="2" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12430 | $as_echo "#define Py_UNICODE_SIZE 2" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12431 | |
| 12432 | ;; |
| 12433 | ucs4) unicode_size="4" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12434 | $as_echo "#define Py_UNICODE_SIZE 4" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12435 | |
| 12436 | ;; |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12437 | *) as_fn_error $? "invalid value for --enable-unicode. Use either ucs2 or ucs4 (lowercase)." "$LINENO" 5 ;; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12438 | esac |
| 12439 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12440 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12441 | |
| 12442 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12443 | if test "$enable_unicode" = "no" |
| 12444 | then |
Martin v. Löwis | 339d0f7 | 2001-08-17 18:39:25 +0000 | [diff] [blame] | 12445 | UNICODE_OBJS="" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12446 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not used" >&5 |
| 12447 | $as_echo "not used" >&6; } |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12448 | else |
Martin v. Löwis | 339d0f7 | 2001-08-17 18:39:25 +0000 | [diff] [blame] | 12449 | UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12450 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12451 | $as_echo "#define Py_USING_UNICODE 1" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12452 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12453 | |
| 12454 | # wchar_t is only usable if it maps to an unsigned type |
| 12455 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 12456 | -a "$ac_cv_wchar_t_signed" = "no" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12457 | then |
| 12458 | PY_UNICODE_TYPE="wchar_t" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12459 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12460 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12461 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12462 | $as_echo "#define PY_UNICODE_TYPE wchar_t" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12463 | |
| 12464 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 12465 | then |
| 12466 | PY_UNICODE_TYPE="unsigned short" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12467 | $as_echo "#define PY_UNICODE_TYPE unsigned short" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12468 | |
| 12469 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 12470 | then |
| 12471 | PY_UNICODE_TYPE="unsigned long" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12472 | $as_echo "#define PY_UNICODE_TYPE unsigned long" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12473 | |
| 12474 | else |
| 12475 | PY_UNICODE_TYPE="no type found" |
| 12476 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12477 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PY_UNICODE_TYPE" >&5 |
| 12478 | $as_echo "$PY_UNICODE_TYPE" >&6; } |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12479 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12480 | |
| 12481 | # check for endianness |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12482 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 12483 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12484 | if ${ac_cv_c_bigendian+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12485 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12486 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12487 | ac_cv_c_bigendian=unknown |
| 12488 | # See if we're dealing with a universal compiler. |
| 12489 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12490 | /* end confdefs.h. */ |
| 12491 | #ifndef __APPLE_CC__ |
| 12492 | not a universal capable compiler |
| 12493 | #endif |
| 12494 | typedef int dummy; |
| 12495 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12496 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12497 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12498 | |
| 12499 | # Check for potential -arch flags. It is not universal unless |
| 12500 | # there are at least two -arch flags with different values. |
| 12501 | ac_arch= |
| 12502 | ac_prev= |
| 12503 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 12504 | if test -n "$ac_prev"; then |
| 12505 | case $ac_word in |
| 12506 | i?86 | x86_64 | ppc | ppc64) |
| 12507 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 12508 | ac_arch=$ac_word |
| 12509 | else |
| 12510 | ac_cv_c_bigendian=universal |
| 12511 | break |
| 12512 | fi |
| 12513 | ;; |
| 12514 | esac |
| 12515 | ac_prev= |
| 12516 | elif test "x$ac_word" = "x-arch"; then |
| 12517 | ac_prev=arch |
| 12518 | fi |
| 12519 | done |
| 12520 | fi |
| 12521 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12522 | if test $ac_cv_c_bigendian = unknown; then |
| 12523 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 12524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12525 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12526 | #include <sys/types.h> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12527 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12528 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12529 | int |
| 12530 | main () |
| 12531 | { |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12532 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 12533 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 12534 | && LITTLE_ENDIAN) |
| 12535 | bogus endian macros |
| 12536 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12537 | |
| 12538 | ; |
| 12539 | return 0; |
| 12540 | } |
| 12541 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12542 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12543 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12544 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12545 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12546 | #include <sys/types.h> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12547 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12548 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12549 | int |
| 12550 | main () |
| 12551 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12552 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12553 | not big endian |
| 12554 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12555 | |
| 12556 | ; |
| 12557 | return 0; |
| 12558 | } |
| 12559 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12560 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12561 | ac_cv_c_bigendian=yes |
| 12562 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12563 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12564 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12565 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12566 | fi |
| 12567 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12568 | fi |
| 12569 | if test $ac_cv_c_bigendian = unknown; then |
| 12570 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 12571 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12572 | /* end confdefs.h. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12573 | #include <limits.h> |
| 12574 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12575 | int |
| 12576 | main () |
| 12577 | { |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12578 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 12579 | bogus endian macros |
| 12580 | #endif |
| 12581 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12582 | ; |
| 12583 | return 0; |
| 12584 | } |
| 12585 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12586 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12587 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 12588 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12589 | /* end confdefs.h. */ |
| 12590 | #include <limits.h> |
| 12591 | |
| 12592 | int |
| 12593 | main () |
| 12594 | { |
| 12595 | #ifndef _BIG_ENDIAN |
| 12596 | not big endian |
| 12597 | #endif |
| 12598 | |
| 12599 | ; |
| 12600 | return 0; |
| 12601 | } |
| 12602 | _ACEOF |
| 12603 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12604 | ac_cv_c_bigendian=yes |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 12605 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12606 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12607 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12608 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12609 | fi |
| 12610 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12611 | fi |
| 12612 | if test $ac_cv_c_bigendian = unknown; then |
| 12613 | # Compile a test program. |
| 12614 | if test "$cross_compiling" = yes; then : |
| 12615 | # Try to guess by grepping values from an object file. |
| 12616 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12617 | /* end confdefs.h. */ |
| 12618 | short int ascii_mm[] = |
| 12619 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 12620 | short int ascii_ii[] = |
| 12621 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 12622 | int use_ascii (int i) { |
| 12623 | return ascii_mm[i] + ascii_ii[i]; |
| 12624 | } |
| 12625 | short int ebcdic_ii[] = |
| 12626 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 12627 | short int ebcdic_mm[] = |
| 12628 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 12629 | int use_ebcdic (int i) { |
| 12630 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 12631 | } |
| 12632 | extern int foo; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12633 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12634 | int |
| 12635 | main () |
| 12636 | { |
| 12637 | return use_ascii (foo) == use_ebcdic (foo); |
| 12638 | ; |
| 12639 | return 0; |
| 12640 | } |
| 12641 | _ACEOF |
| 12642 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12643 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 12644 | ac_cv_c_bigendian=yes |
| 12645 | fi |
| 12646 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 12647 | if test "$ac_cv_c_bigendian" = unknown; then |
| 12648 | ac_cv_c_bigendian=no |
| 12649 | else |
| 12650 | # finding both strings is unlikely to happen, but who knows? |
| 12651 | ac_cv_c_bigendian=unknown |
| 12652 | fi |
| 12653 | fi |
| 12654 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12655 | 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] | 12656 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12657 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12658 | /* end confdefs.h. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12659 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12660 | int |
| 12661 | main () |
| 12662 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12663 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12664 | /* Are we little or big endian? From Harbison&Steele. */ |
| 12665 | union |
| 12666 | { |
| 12667 | long int l; |
| 12668 | char c[sizeof (long int)]; |
| 12669 | } u; |
| 12670 | u.l = 1; |
| 12671 | return u.c[sizeof (long int) - 1] == 1; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12672 | |
| 12673 | ; |
| 12674 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12675 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12676 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12677 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12678 | ac_cv_c_bigendian=no |
| 12679 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12680 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12681 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12682 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12683 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12684 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12685 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12686 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12687 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12688 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 12689 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 12690 | case $ac_cv_c_bigendian in #( |
| 12691 | yes) |
| 12692 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 12693 | ;; #( |
| 12694 | no) |
| 12695 | ;; #( |
| 12696 | universal) |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 12697 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12698 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 12699 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12700 | ;; #( |
| 12701 | *) |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12702 | as_fn_error $? "unknown endianness |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12703 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
| 12704 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12705 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12706 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12707 | # Check whether right shifting a negative integer extends the sign bit |
| 12708 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12709 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 12710 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12711 | if ${ac_cv_rshift_extends_sign+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12712 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12713 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12714 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12715 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12716 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12717 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12718 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12719 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12720 | |
| 12721 | int main() |
| 12722 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12723 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12724 | } |
| 12725 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12726 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12727 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12728 | ac_cv_rshift_extends_sign=yes |
| 12729 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12730 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12731 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12732 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12733 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12734 | fi |
| 12735 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12736 | fi |
| 12737 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12738 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 12739 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12740 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12741 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12742 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12743 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12744 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12745 | fi |
| 12746 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12747 | # check for getc_unlocked and related locking functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12748 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 12749 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12750 | if ${ac_cv_have_getc_unlocked+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12751 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12752 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12753 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12754 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12755 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12756 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12757 | int |
| 12758 | main () |
| 12759 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12760 | |
| 12761 | FILE *f = fopen("/dev/null", "r"); |
| 12762 | flockfile(f); |
| 12763 | getc_unlocked(f); |
| 12764 | funlockfile(f); |
| 12765 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12766 | ; |
| 12767 | return 0; |
| 12768 | } |
| 12769 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12770 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12771 | ac_cv_have_getc_unlocked=yes |
| 12772 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12773 | ac_cv_have_getc_unlocked=no |
| 12774 | fi |
| 12775 | rm -f core conftest.err conftest.$ac_objext \ |
| 12776 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12777 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12778 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12779 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 12780 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12781 | if test "$ac_cv_have_getc_unlocked" = yes |
| 12782 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12783 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12784 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12785 | |
| 12786 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12787 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12788 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12789 | # save the value of LIBS so we don't actually link Python with readline |
| 12790 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12791 | |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12792 | # On some systems we need to link readline to a termcap compatible |
| 12793 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 12794 | # with setup.py. |
| 12795 | py_cv_lib_readline=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12796 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 12797 | $as_echo_n "checking how to link readline libs... " >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12798 | for py_libtermcap in "" ncursesw ncurses curses termcap; do |
| 12799 | if test -z "$py_libtermcap"; then |
| 12800 | READLINE_LIBS="-lreadline" |
| 12801 | else |
| 12802 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 12803 | fi |
| 12804 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12805 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12806 | /* end confdefs.h. */ |
| 12807 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12808 | /* Override any GCC internal prototype to avoid an error. |
| 12809 | Use char because int might match the return type of a GCC |
| 12810 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12811 | #ifdef __cplusplus |
| 12812 | extern "C" |
| 12813 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12814 | char readline (); |
| 12815 | int |
| 12816 | main () |
| 12817 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12818 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12819 | ; |
| 12820 | return 0; |
| 12821 | } |
| 12822 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12823 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12824 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12825 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12826 | rm -f core conftest.err conftest.$ac_objext \ |
| 12827 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12828 | if test $py_cv_lib_readline = yes; then |
| 12829 | break |
| 12830 | fi |
| 12831 | done |
| 12832 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 12833 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | e080cdf | 2008-09-07 19:19:04 +0000 | [diff] [blame] | 12834 | if test $py_cv_lib_readline = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 12836 | $as_echo "none" >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12837 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 12839 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12840 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12841 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12842 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12843 | fi |
| 12844 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12845 | # check for readline 2.1 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12846 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 12847 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12848 | if ${ac_cv_lib_readline_rl_callback_handler_install+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12849 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12850 | else |
| 12851 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12852 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12853 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12854 | /* end confdefs.h. */ |
| 12855 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12856 | /* Override any GCC internal prototype to avoid an error. |
| 12857 | Use char because int might match the return type of a GCC |
| 12858 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12859 | #ifdef __cplusplus |
| 12860 | extern "C" |
| 12861 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12862 | char rl_callback_handler_install (); |
| 12863 | int |
| 12864 | main () |
| 12865 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12866 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12867 | ; |
| 12868 | return 0; |
| 12869 | } |
| 12870 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12871 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12872 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 12873 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12874 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12875 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12876 | rm -f core conftest.err conftest.$ac_objext \ |
| 12877 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12878 | LIBS=$ac_check_lib_save_LIBS |
| 12879 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12880 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 12881 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12882 | 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] | 12883 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12884 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12885 | |
| 12886 | fi |
| 12887 | |
| 12888 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12889 | # check for readline 2.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12890 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12891 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12892 | #include <readline/readline.h> |
| 12893 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12894 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12895 | have_readline=yes |
| 12896 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12897 | have_readline=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 12898 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12899 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12900 | rm -f conftest.err conftest.i conftest.$ac_ext |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12901 | if test $have_readline = yes |
| 12902 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12903 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12904 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12905 | #include <readline/readline.h> |
| 12906 | |
| 12907 | _ACEOF |
| 12908 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12909 | $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] | 12910 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12911 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12912 | |
| 12913 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 12914 | rm -f conftest* |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12915 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12916 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12917 | /* end confdefs.h. */ |
| 12918 | #include <readline/readline.h> |
| 12919 | |
| 12920 | _ACEOF |
| 12921 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12922 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12923 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12924 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12925 | |
| 12926 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 12927 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12928 | |
| 12929 | fi |
| 12930 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12931 | # check for readline 4.0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12932 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 12933 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12934 | if ${ac_cv_lib_readline_rl_pre_input_hook+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12935 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12936 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12937 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12938 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12939 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12940 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12941 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12942 | /* Override any GCC internal prototype to avoid an error. |
| 12943 | Use char because int might match the return type of a GCC |
| 12944 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12945 | #ifdef __cplusplus |
| 12946 | extern "C" |
| 12947 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12948 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12949 | int |
| 12950 | main () |
| 12951 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12952 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12953 | ; |
| 12954 | return 0; |
| 12955 | } |
| 12956 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12957 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12958 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12959 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12960 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12961 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12962 | rm -f core conftest.err conftest.$ac_objext \ |
| 12963 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12964 | LIBS=$ac_check_lib_save_LIBS |
| 12965 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12966 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 12967 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12968 | 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] | 12969 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12970 | $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] | 12971 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12972 | fi |
| 12973 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12974 | |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12975 | # also in 4.0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12976 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 12977 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 12978 | if ${ac_cv_lib_readline_rl_completion_display_matches_hook+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12979 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12980 | else |
| 12981 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12982 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12983 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12984 | /* end confdefs.h. */ |
| 12985 | |
| 12986 | /* Override any GCC internal prototype to avoid an error. |
| 12987 | Use char because int might match the return type of a GCC |
| 12988 | builtin and then its argument prototype would still apply. */ |
| 12989 | #ifdef __cplusplus |
| 12990 | extern "C" |
| 12991 | #endif |
| 12992 | char rl_completion_display_matches_hook (); |
| 12993 | int |
| 12994 | main () |
| 12995 | { |
| 12996 | return rl_completion_display_matches_hook (); |
| 12997 | ; |
| 12998 | return 0; |
| 12999 | } |
| 13000 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13001 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 13002 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 13003 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13004 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 13005 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13006 | rm -f core conftest.err conftest.$ac_objext \ |
| 13007 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 13008 | LIBS=$ac_check_lib_save_LIBS |
| 13009 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13010 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 13011 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13012 | if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = xyes; then : |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 13013 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13014 | $as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 13015 | |
| 13016 | fi |
| 13017 | |
| 13018 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 13019 | # check for readline 4.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13020 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 13021 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13022 | if ${ac_cv_lib_readline_rl_completion_matches+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13023 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 13024 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13025 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 13026 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13027 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13028 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13029 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13030 | /* Override any GCC internal prototype to avoid an error. |
| 13031 | Use char because int might match the return type of a GCC |
| 13032 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13033 | #ifdef __cplusplus |
| 13034 | extern "C" |
| 13035 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13036 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13037 | int |
| 13038 | main () |
| 13039 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13040 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13041 | ; |
| 13042 | return 0; |
| 13043 | } |
| 13044 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13045 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13046 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13047 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13048 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13049 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13050 | rm -f core conftest.err conftest.$ac_objext \ |
| 13051 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13052 | LIBS=$ac_check_lib_save_LIBS |
| 13053 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13054 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 13055 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13056 | 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] | 13057 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13058 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13059 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13060 | fi |
| 13061 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13062 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13063 | # also in readline 4.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13064 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13065 | /* end confdefs.h. */ |
| 13066 | #include <readline/readline.h> |
| 13067 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13068 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13069 | have_readline=yes |
| 13070 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13071 | have_readline=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13072 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13073 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13074 | rm -f conftest.err conftest.i conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13075 | if test $have_readline = yes |
| 13076 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13077 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13078 | /* end confdefs.h. */ |
| 13079 | #include <readline/readline.h> |
| 13080 | |
| 13081 | _ACEOF |
| 13082 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13083 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13084 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13085 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13086 | |
| 13087 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 13088 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13089 | |
| 13090 | fi |
| 13091 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 13092 | # End of readline checks: restore LIBS |
| 13093 | LIBS=$LIBS_no_readline |
| 13094 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13095 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 13096 | $as_echo_n "checking for broken nice()... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13097 | if ${ac_cv_broken_nice+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13098 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13099 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13100 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13101 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 13102 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13103 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13104 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13105 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13106 | |
| 13107 | int main() |
| 13108 | { |
| 13109 | int val1 = nice(1); |
| 13110 | if (val1 != -1 && val1 == nice(2)) |
| 13111 | exit(0); |
| 13112 | exit(1); |
| 13113 | } |
| 13114 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13115 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13116 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13117 | ac_cv_broken_nice=yes |
| 13118 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13119 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13120 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13121 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13122 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13123 | fi |
| 13124 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13125 | fi |
| 13126 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13127 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 13128 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13129 | if test "$ac_cv_broken_nice" = yes |
| 13130 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13131 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13132 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13133 | |
| 13134 | fi |
| 13135 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13136 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 13137 | $as_echo_n "checking for broken poll()... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13138 | if ${ac_cv_broken_poll+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13139 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13140 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13141 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13142 | ac_cv_broken_poll=no |
| 13143 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13144 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13145 | /* end confdefs.h. */ |
| 13146 | |
| 13147 | #include <poll.h> |
| 13148 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13149 | int main() |
| 13150 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13151 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13152 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13153 | |
| 13154 | close (42); |
| 13155 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13156 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13157 | if (poll_test < 0) |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13158 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13159 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13160 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13161 | else |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13162 | return 1; |
| 13163 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13164 | |
| 13165 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13166 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13167 | ac_cv_broken_poll=yes |
| 13168 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13169 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13170 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13171 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13172 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13173 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13174 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13175 | fi |
| 13176 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 13178 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13179 | if test "$ac_cv_broken_poll" = yes |
| 13180 | then |
| 13181 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13182 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13183 | |
| 13184 | fi |
| 13185 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13186 | # 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] | 13187 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 13188 | # tzname[] |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13189 | 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] | 13190 | #include <$ac_cv_struct_tm> |
| 13191 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13192 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13193 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13194 | |
| 13195 | cat >>confdefs.h <<_ACEOF |
| 13196 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 13197 | _ACEOF |
| 13198 | |
| 13199 | |
| 13200 | fi |
| 13201 | |
| 13202 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 13203 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13204 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13205 | |
| 13206 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13207 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 13208 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13209 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13210 | ac_have_decl=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13211 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13212 | ac_have_decl=0 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13213 | fi |
| 13214 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13215 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13216 | #define HAVE_DECL_TZNAME $ac_have_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13217 | _ACEOF |
| 13218 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13219 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 13220 | $as_echo_n "checking for tzname... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13221 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13222 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13223 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13224 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13225 | /* end confdefs.h. */ |
| 13226 | #include <time.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13227 | #if !HAVE_DECL_TZNAME |
| 13228 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13229 | #endif |
| 13230 | |
| 13231 | int |
| 13232 | main () |
| 13233 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13234 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13235 | ; |
| 13236 | return 0; |
| 13237 | } |
| 13238 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13239 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13240 | ac_cv_var_tzname=yes |
| 13241 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13242 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13243 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13244 | rm -f core conftest.err conftest.$ac_objext \ |
| 13245 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13246 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13247 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 13248 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13249 | if test $ac_cv_var_tzname = yes; then |
| 13250 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13251 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13252 | |
| 13253 | fi |
| 13254 | fi |
| 13255 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13256 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13257 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13258 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 13259 | $as_echo_n "checking for working tzset()... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13260 | if ${ac_cv_working_tzset+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13261 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13262 | else |
| 13263 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13264 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13265 | ac_cv_working_tzset=no |
| 13266 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13267 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13268 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13269 | |
| 13270 | #include <stdlib.h> |
| 13271 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13272 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13273 | |
| 13274 | #if HAVE_TZNAME |
| 13275 | extern char *tzname[]; |
| 13276 | #endif |
| 13277 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13278 | int main() |
| 13279 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13280 | /* Note that we need to ensure that not only does tzset(3) |
| 13281 | do 'something' with localtime, but it works as documented |
| 13282 | 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] | 13283 | This includes making sure that tzname is set properly if |
| 13284 | tm->tm_zone does not exist since it is the alternative way |
| 13285 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13286 | |
| 13287 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13288 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13289 | */ |
| 13290 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13291 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13292 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 13293 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13294 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13295 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13296 | if (localtime(&groundhogday)->tm_hour != 0) |
| 13297 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13298 | #if HAVE_TZNAME |
| 13299 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 13300 | if (strcmp(tzname[0], "UTC") || |
| 13301 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 13302 | exit(1); |
| 13303 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13304 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13305 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13306 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13307 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13308 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13309 | #if HAVE_TZNAME |
| 13310 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 13311 | exit(1); |
| 13312 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13313 | |
| 13314 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 13315 | tzset(); |
| 13316 | if (localtime(&groundhogday)->tm_hour != 11) |
| 13317 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13318 | #if HAVE_TZNAME |
| 13319 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 13320 | exit(1); |
| 13321 | #endif |
| 13322 | |
| 13323 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13324 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 13325 | exit(1); |
| 13326 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 13327 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13328 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13329 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13330 | exit(0); |
| 13331 | } |
| 13332 | |
| 13333 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13334 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13335 | ac_cv_working_tzset=yes |
| 13336 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13337 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13338 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13339 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13340 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13341 | fi |
| 13342 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13343 | fi |
| 13344 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13345 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 13346 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13347 | if test "$ac_cv_working_tzset" = yes |
| 13348 | then |
| 13349 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13350 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13351 | |
| 13352 | fi |
| 13353 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13354 | # Look for subsecond timestamps in struct stat |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13355 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 13356 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13357 | if ${ac_cv_stat_tv_nsec+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13358 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13359 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13360 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13361 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13362 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13363 | int |
| 13364 | main () |
| 13365 | { |
| 13366 | |
| 13367 | struct stat st; |
| 13368 | st.st_mtim.tv_nsec = 1; |
| 13369 | |
| 13370 | ; |
| 13371 | return 0; |
| 13372 | } |
| 13373 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13374 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 13375 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13376 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13377 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13378 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13379 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13380 | fi |
| 13381 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13382 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 13383 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13384 | if test "$ac_cv_stat_tv_nsec" = yes |
| 13385 | then |
| 13386 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13387 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13388 | |
| 13389 | fi |
| 13390 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13391 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13392 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 13393 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13394 | if ${ac_cv_stat_tv_nsec2+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13395 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13396 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13397 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13398 | /* end confdefs.h. */ |
| 13399 | #include <sys/stat.h> |
| 13400 | int |
| 13401 | main () |
| 13402 | { |
| 13403 | |
| 13404 | struct stat st; |
| 13405 | st.st_mtimespec.tv_nsec = 1; |
| 13406 | |
| 13407 | ; |
| 13408 | return 0; |
| 13409 | } |
| 13410 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13411 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13412 | ac_cv_stat_tv_nsec2=yes |
| 13413 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13414 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13415 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13416 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13417 | fi |
| 13418 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13419 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 13420 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13421 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 13422 | then |
| 13423 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13424 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13425 | |
| 13426 | fi |
| 13427 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13428 | # On HP/UX 11.0, mvwdelch is a block with a return statement |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13429 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 13430 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13431 | if ${ac_cv_mvwdelch_is_expression+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13432 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13433 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13435 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13436 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13437 | int |
| 13438 | main () |
| 13439 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13440 | |
| 13441 | int rtn; |
| 13442 | rtn = mvwdelch(0,0,0); |
| 13443 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13444 | ; |
| 13445 | return 0; |
| 13446 | } |
| 13447 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13448 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13449 | ac_cv_mvwdelch_is_expression=yes |
| 13450 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13451 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13452 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13453 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13454 | fi |
| 13455 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13456 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 13457 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13458 | |
| 13459 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 13460 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13461 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13462 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13463 | |
| 13464 | fi |
| 13465 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13466 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 13467 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13468 | if ${ac_cv_window_has_flags+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13469 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13470 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13471 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13472 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13473 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13474 | int |
| 13475 | main () |
| 13476 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13477 | |
| 13478 | WINDOW *w; |
| 13479 | w->_flags = 0; |
| 13480 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13481 | ; |
| 13482 | return 0; |
| 13483 | } |
| 13484 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13485 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13486 | ac_cv_window_has_flags=yes |
| 13487 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13488 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13489 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13490 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13491 | fi |
| 13492 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13493 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 13494 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13495 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13496 | |
| 13497 | if test "$ac_cv_window_has_flags" = yes |
| 13498 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13499 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13500 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13501 | |
| 13502 | fi |
| 13503 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13504 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 13505 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 13506 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13507 | /* end confdefs.h. */ |
| 13508 | #include <curses.h> |
| 13509 | int |
| 13510 | main () |
| 13511 | { |
| 13512 | void *x=is_term_resized |
| 13513 | ; |
| 13514 | return 0; |
| 13515 | } |
| 13516 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13517 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13518 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13519 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13520 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13521 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13522 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13523 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13525 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13526 | |
| 13527 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13528 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13529 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13530 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 13531 | $as_echo_n "checking for resize_term... " >&6; } |
| 13532 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13533 | /* end confdefs.h. */ |
| 13534 | #include <curses.h> |
| 13535 | int |
| 13536 | main () |
| 13537 | { |
| 13538 | void *x=resize_term |
| 13539 | ; |
| 13540 | return 0; |
| 13541 | } |
| 13542 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13543 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13544 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13545 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13546 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13547 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13548 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13549 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13551 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13552 | |
| 13553 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13554 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13555 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13556 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 13557 | $as_echo_n "checking for resizeterm... " >&6; } |
| 13558 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13559 | /* end confdefs.h. */ |
| 13560 | #include <curses.h> |
| 13561 | int |
| 13562 | main () |
| 13563 | { |
| 13564 | void *x=resizeterm |
| 13565 | ; |
| 13566 | return 0; |
| 13567 | } |
| 13568 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13569 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13570 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13571 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13572 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13574 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13575 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13576 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13577 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13578 | |
| 13579 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13580 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13581 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13582 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 13583 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13584 | |
| 13585 | if test -r /dev/ptmx |
| 13586 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13587 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13588 | $as_echo "yes" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13589 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13590 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13591 | |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13592 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13593 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13594 | $as_echo "no" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13595 | fi |
| 13596 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13597 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 13598 | $as_echo_n "checking for /dev/ptc... " >&6; } |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13599 | |
| 13600 | if test -r /dev/ptc |
| 13601 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13602 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13603 | $as_echo "yes" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13604 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13605 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13606 | |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13607 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13608 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13609 | $as_echo "no" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13610 | fi |
| 13611 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13612 | if test "$have_long_long" = yes |
| 13613 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 13615 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13616 | if ${ac_cv_have_long_long_format+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13617 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13618 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13619 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13620 | ac_cv_have_long_long_format=no |
| 13621 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13622 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13623 | /* end confdefs.h. */ |
| 13624 | |
| 13625 | #include <stdio.h> |
| 13626 | #include <stddef.h> |
| 13627 | #include <string.h> |
| 13628 | |
| 13629 | #ifdef HAVE_SYS_TYPES_H |
| 13630 | #include <sys/types.h> |
| 13631 | #endif |
| 13632 | |
| 13633 | int main() |
| 13634 | { |
| 13635 | char buffer[256]; |
| 13636 | |
| 13637 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 13638 | return 1; |
| 13639 | if (strcmp(buffer, "123")) |
| 13640 | return 1; |
| 13641 | |
| 13642 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 13643 | return 1; |
| 13644 | if (strcmp(buffer, "-123")) |
| 13645 | return 1; |
| 13646 | |
| 13647 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 13648 | return 1; |
| 13649 | if (strcmp(buffer, "123")) |
| 13650 | return 1; |
| 13651 | |
| 13652 | return 0; |
| 13653 | } |
| 13654 | |
| 13655 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13656 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13657 | ac_cv_have_long_long_format=yes |
| 13658 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13659 | ac_cv_have_long_long_format=no |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13660 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 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 | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13663 | fi |
| 13664 | |
| 13665 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13666 | fi |
| 13667 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13668 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 13669 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13670 | fi |
| 13671 | |
Mark Dickinson | 5ce8474 | 2009-12-31 20:48:04 +0000 | [diff] [blame] | 13672 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13673 | then |
| 13674 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13675 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13676 | |
| 13677 | fi |
| 13678 | |
Ronald Oussoren | 315cd0c | 2009-11-19 16:25:21 +0000 | [diff] [blame] | 13679 | if test $ac_sys_system = Darwin |
| 13680 | then |
| 13681 | LIBS="$LIBS -framework CoreFoundation" |
| 13682 | fi |
| 13683 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13684 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13685 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 13686 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13687 | if ${ac_cv_have_size_t_format+:} false; then : |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13688 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13689 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13690 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | c9ff3a7 | 2009-11-02 02:03:16 +0000 | [diff] [blame] | 13691 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 13692 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13693 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13694 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13695 | /* end confdefs.h. */ |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13696 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13697 | #include <stdio.h> |
| 13698 | #include <stddef.h> |
| 13699 | #include <string.h> |
| 13700 | |
Christian Heimes | db3d6cb | 2007-12-16 21:39:43 +0000 | [diff] [blame] | 13701 | #ifdef HAVE_SYS_TYPES_H |
| 13702 | #include <sys/types.h> |
| 13703 | #endif |
Neal Norwitz | 4a8fbdb | 2006-09-22 08:16:26 +0000 | [diff] [blame] | 13704 | |
| 13705 | #ifdef HAVE_SSIZE_T |
| 13706 | typedef ssize_t Py_ssize_t; |
| 13707 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 13708 | typedef long Py_ssize_t; |
| 13709 | #else |
| 13710 | typedef int Py_ssize_t; |
| 13711 | #endif |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13712 | |
Christian Heimes | db3d6cb | 2007-12-16 21:39:43 +0000 | [diff] [blame] | 13713 | int main() |
| 13714 | { |
| 13715 | char buffer[256]; |
| 13716 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13717 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 13718 | return 1; |
| 13719 | |
Neal Norwitz | 4a8fbdb | 2006-09-22 08:16:26 +0000 | [diff] [blame] | 13720 | if (strcmp(buffer, "123")) |
| 13721 | return 1; |
| 13722 | |
| 13723 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 13724 | return 1; |
| 13725 | |
| 13726 | if (strcmp(buffer, "-123")) |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13727 | return 1; |
| 13728 | |
| 13729 | return 0; |
| 13730 | } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13731 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13732 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13733 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13734 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 13735 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13736 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 13737 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13738 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13739 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 13740 | fi |
| 13741 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13742 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 13744 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Gregory P. Smith | c9ff3a7 | 2009-11-02 02:03:16 +0000 | [diff] [blame] | 13745 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13746 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13747 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13748 | |
| 13749 | fi |
| 13750 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13751 | 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] | 13752 | #ifdef HAVE_SYS_TYPES_H |
| 13753 | #include <sys/types.h> |
| 13754 | #endif |
| 13755 | #ifdef HAVE_SYS_SOCKET_H |
| 13756 | #include <sys/socket.h> |
| 13757 | #endif |
| 13758 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13759 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13760 | if test "x$ac_cv_type_socklen_t" = xyes; then : |
Martin v. Löwis | 01c0401 | 2002-11-11 14:58:44 +0000 | [diff] [blame] | 13761 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13762 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13763 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13764 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13765 | |
| 13766 | fi |
| 13767 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13768 | |
Benjamin Peterson | 7497e91 | 2010-10-16 00:53:39 +0000 | [diff] [blame] | 13769 | case $ac_sys_system in |
| 13770 | AIX*) |
| 13771 | |
| 13772 | $as_echo "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h |
| 13773 | ;; |
| 13774 | esac |
| 13775 | |
| 13776 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13777 | |
| 13778 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 13779 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 13780 | do |
| 13781 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 13782 | done |
| 13783 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13784 | |
Neal Norwitz | d24499d | 2005-12-18 21:36:39 +0000 | [diff] [blame] | 13785 | SRCDIRS="Parser Grammar Objects Python Modules Mac" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13786 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 13787 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13788 | for dir in $SRCDIRS; do |
| 13789 | if test ! -d $dir; then |
| 13790 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 13791 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13792 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13793 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 13794 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 13795 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13796 | # generate output files |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 13797 | ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config Misc/python.pc" |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 13798 | |
Antoine Pitrou | aabdceb | 2010-09-10 20:03:17 +0000 | [diff] [blame] | 13799 | ac_config_files="$ac_config_files Modules/ld_so_aix" |
| 13800 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13801 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13802 | # This file is a shell script that caches the results of configure |
| 13803 | # 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] | 13804 | # scripts and configure runs, see configure's option --config-cache. |
| 13805 | # It is not useful on other systems. If it contains results you don't |
| 13806 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13807 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13808 | # config.status only pays attention to the cache file if you give it |
| 13809 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13810 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13811 | # `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] | 13812 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 13813 | # following values. |
| 13814 | |
| 13815 | _ACEOF |
| 13816 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 13817 | # The following way of writing the cache mishandles newlines in values, |
| 13818 | # but we know of no workaround that is simple, portable, and efficient. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13819 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13820 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 13821 | # and sets the high bit in the cache file unless we assign to the vars. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13822 | ( |
| 13823 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 13824 | eval ac_val=\$$ac_var |
| 13825 | case $ac_val in #( |
| 13826 | *${as_nl}*) |
| 13827 | case $ac_var in #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13828 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 13829 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13830 | esac |
| 13831 | case $ac_var in #( |
| 13832 | _ | IFS | as_nl) ;; #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13833 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 13834 | *) { eval $ac_var=; unset $ac_var;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13835 | esac ;; |
| 13836 | esac |
| 13837 | done |
| 13838 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13839 | (set) 2>&1 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13840 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 13841 | *${as_nl}ac_space=\ *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13842 | # `set' does not quote correctly, so add quotes: double-quote |
| 13843 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13844 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 13845 | "s/'/'\\\\''/g; |
| 13846 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13847 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13848 | *) |
| 13849 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13850 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13851 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13852 | esac | |
| 13853 | sort |
| 13854 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13855 | sed ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13856 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13857 | t clear |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13858 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13859 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 13860 | t end |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13861 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 13862 | :end' >>confcache |
| 13863 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 13864 | if test -w "$cache_file"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13865 | if test "x$cache_file" != "x/dev/null"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13866 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 13867 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13868 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
| 13869 | cat confcache >"$cache_file" |
| 13870 | else |
| 13871 | case $cache_file in #( |
| 13872 | */* | ?:*) |
| 13873 | mv -f confcache "$cache_file"$$ && |
| 13874 | mv -f "$cache_file"$$ "$cache_file" ;; #( |
| 13875 | *) |
| 13876 | mv -f confcache "$cache_file" ;; |
| 13877 | esac |
| 13878 | fi |
| 13879 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13880 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13881 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 13882 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13883 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13884 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13885 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13886 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13887 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 13888 | # Let make expand exec_prefix. |
| 13889 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13890 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13891 | DEFS=-DHAVE_CONFIG_H |
| 13892 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13893 | ac_libobjs= |
| 13894 | ac_ltlibobjs= |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13895 | U= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13896 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 13897 | # 1. Remove the extension, and $U if already installed. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13898 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13899 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13900 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 13901 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13902 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 13903 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13904 | done |
| 13905 | LIBOBJS=$ac_libobjs |
| 13906 | |
| 13907 | LTLIBOBJS=$ac_ltlibobjs |
| 13908 | |
| 13909 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13910 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13911 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 13912 | : "${CONFIG_STATUS=./config.status}" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13913 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13914 | ac_clean_files_save=$ac_clean_files |
| 13915 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13916 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 13917 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 13918 | as_write_fail=0 |
| 13919 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13920 | #! $SHELL |
| 13921 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13922 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13923 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13924 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13925 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13926 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13927 | ac_cs_recheck=false |
| 13928 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13929 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13930 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 13931 | export SHELL |
| 13932 | _ASEOF |
| 13933 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 13934 | ## -------------------- ## |
| 13935 | ## M4sh Initialization. ## |
| 13936 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13937 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13938 | # Be more Bourne compatible |
| 13939 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13940 | 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] | 13941 | emulate sh |
| 13942 | NULLCMD=: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13943 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13944 | # is contrary to our usage. Disable this feature. |
| 13945 | alias -g '${1+"$@"}'='"$@"' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13946 | setopt NO_GLOB_SUBST |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 13947 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13948 | case `(set -o) 2>/dev/null` in #( |
| 13949 | *posix*) : |
| 13950 | set -o posix ;; #( |
| 13951 | *) : |
| 13952 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13953 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13954 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13955 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13956 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13957 | as_nl=' |
| 13958 | ' |
| 13959 | export as_nl |
| 13960 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 13961 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 13962 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13963 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13964 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 13965 | # but without wasting forks for bash or zsh. |
| 13966 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 13967 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13968 | as_echo='print -r --' |
| 13969 | as_echo_n='print -rn --' |
| 13970 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13971 | as_echo='printf %s\n' |
| 13972 | as_echo_n='printf %s' |
| 13973 | else |
| 13974 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 13975 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 13976 | as_echo_n='/usr/ucb/echo -n' |
| 13977 | else |
| 13978 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 13979 | as_echo_n_body='eval |
| 13980 | arg=$1; |
| 13981 | case $arg in #( |
| 13982 | *"$as_nl"*) |
| 13983 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 13984 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 13985 | esac; |
| 13986 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 13987 | ' |
| 13988 | export as_echo_n_body |
| 13989 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 13990 | fi |
| 13991 | export as_echo_body |
| 13992 | as_echo='sh -c $as_echo_body as_echo' |
| 13993 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13994 | |
| 13995 | # The user is always right. |
| 13996 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13997 | PATH_SEPARATOR=: |
| 13998 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 13999 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 14000 | PATH_SEPARATOR=';' |
| 14001 | } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14002 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14003 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14004 | |
| 14005 | # IFS |
| 14006 | # We need space, tab and new line, in precisely that order. Quoting is |
| 14007 | # there to prevent editors from complaining about space-tab. |
| 14008 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 14009 | # splitting by setting IFS to empty value.) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14010 | IFS=" "" $as_nl" |
| 14011 | |
| 14012 | # Find who we are. Look in the path if we contain no directory separator. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14013 | as_myself= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14014 | case $0 in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14015 | *[\\/]* ) as_myself=$0 ;; |
| 14016 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14017 | for as_dir in $PATH |
| 14018 | do |
| 14019 | IFS=$as_save_IFS |
| 14020 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14021 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 14022 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14023 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14024 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14025 | ;; |
| 14026 | esac |
| 14027 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 14028 | # in which case we are not to be found in the path. |
| 14029 | if test "x$as_myself" = x; then |
| 14030 | as_myself=$0 |
| 14031 | fi |
| 14032 | if test ! -f "$as_myself"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14033 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 14034 | exit 1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14035 | fi |
| 14036 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14037 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 14038 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 14039 | # suppresses any "Segmentation fault" message there. '((' could |
| 14040 | # trigger a bug in pdksh 5.2.14. |
| 14041 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 14042 | do eval test x\${$as_var+set} = xset \ |
| 14043 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14044 | done |
| 14045 | PS1='$ ' |
| 14046 | PS2='> ' |
| 14047 | PS4='+ ' |
| 14048 | |
| 14049 | # NLS nuisances. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14050 | LC_ALL=C |
| 14051 | export LC_ALL |
| 14052 | LANGUAGE=C |
| 14053 | export LANGUAGE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14054 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14055 | # CDPATH. |
| 14056 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 14057 | |
| 14058 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14059 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 14060 | # ---------------------------------------- |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14061 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 14062 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14063 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14064 | as_fn_error () |
| 14065 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14066 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 14067 | if test "$4"; then |
| 14068 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 14069 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14070 | fi |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14071 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14072 | as_fn_exit $as_status |
| 14073 | } # as_fn_error |
| 14074 | |
| 14075 | |
| 14076 | # as_fn_set_status STATUS |
| 14077 | # ----------------------- |
| 14078 | # Set $? to STATUS, without forking. |
| 14079 | as_fn_set_status () |
| 14080 | { |
| 14081 | return $1 |
| 14082 | } # as_fn_set_status |
| 14083 | |
| 14084 | # as_fn_exit STATUS |
| 14085 | # ----------------- |
| 14086 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 14087 | as_fn_exit () |
| 14088 | { |
| 14089 | set +e |
| 14090 | as_fn_set_status $1 |
| 14091 | exit $1 |
| 14092 | } # as_fn_exit |
| 14093 | |
| 14094 | # as_fn_unset VAR |
| 14095 | # --------------- |
| 14096 | # Portably unset VAR. |
| 14097 | as_fn_unset () |
| 14098 | { |
| 14099 | { eval $1=; unset $1;} |
| 14100 | } |
| 14101 | as_unset=as_fn_unset |
| 14102 | # as_fn_append VAR VALUE |
| 14103 | # ---------------------- |
| 14104 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 14105 | # advantage of any shell optimizations that allow amortized linear growth over |
| 14106 | # repeated appends, instead of the typical quadratic growth present in naive |
| 14107 | # implementations. |
| 14108 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 14109 | eval 'as_fn_append () |
| 14110 | { |
| 14111 | eval $1+=\$2 |
| 14112 | }' |
| 14113 | else |
| 14114 | as_fn_append () |
| 14115 | { |
| 14116 | eval $1=\$$1\$2 |
| 14117 | } |
| 14118 | fi # as_fn_append |
| 14119 | |
| 14120 | # as_fn_arith ARG... |
| 14121 | # ------------------ |
| 14122 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 14123 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 14124 | # must be portable across $(()) and expr. |
| 14125 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 14126 | eval 'as_fn_arith () |
| 14127 | { |
| 14128 | as_val=$(( $* )) |
| 14129 | }' |
| 14130 | else |
| 14131 | as_fn_arith () |
| 14132 | { |
| 14133 | as_val=`expr "$@" || test $? -eq 1` |
| 14134 | } |
| 14135 | fi # as_fn_arith |
| 14136 | |
| 14137 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14138 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 14139 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 14140 | as_expr=expr |
| 14141 | else |
| 14142 | as_expr=false |
| 14143 | fi |
| 14144 | |
| 14145 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 14146 | as_basename=basename |
| 14147 | else |
| 14148 | as_basename=false |
| 14149 | fi |
| 14150 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14151 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 14152 | as_dirname=dirname |
| 14153 | else |
| 14154 | as_dirname=false |
| 14155 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14156 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14157 | as_me=`$as_basename -- "$0" || |
| 14158 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 14159 | X"$0" : 'X\(//\)$' \| \ |
| 14160 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14161 | $as_echo X/"$0" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14162 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 14163 | s//\1/ |
| 14164 | q |
| 14165 | } |
| 14166 | /^X\/\(\/\/\)$/{ |
| 14167 | s//\1/ |
| 14168 | q |
| 14169 | } |
| 14170 | /^X\/\(\/\).*/{ |
| 14171 | s//\1/ |
| 14172 | q |
| 14173 | } |
| 14174 | s/.*/./; q'` |
| 14175 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14176 | # Avoid depending upon Character Ranges. |
| 14177 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 14178 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14179 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14180 | as_cr_digits='0123456789' |
| 14181 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14182 | |
| 14183 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14184 | case `echo -n x` in #((((( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14185 | -n*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14186 | case `echo 'xy\c'` in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14187 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14188 | xy) ECHO_C='\c';; |
| 14189 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 14190 | ECHO_T=' ';; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14191 | esac;; |
| 14192 | *) |
| 14193 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14194 | esac |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 14195 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14196 | rm -f conf$$ conf$$.exe conf$$.file |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14197 | if test -d conf$$.dir; then |
| 14198 | rm -f conf$$.dir/conf$$.file |
| 14199 | else |
| 14200 | rm -f conf$$.dir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14201 | mkdir conf$$.dir 2>/dev/null |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14202 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14203 | if (echo >conf$$.file) 2>/dev/null; then |
| 14204 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 14205 | as_ln_s='ln -s' |
| 14206 | # ... but there are two gotchas: |
| 14207 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 14208 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 14209 | # In both cases, we have to default to `cp -p'. |
| 14210 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 14211 | as_ln_s='cp -p' |
| 14212 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 14213 | as_ln_s=ln |
| 14214 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14215 | as_ln_s='cp -p' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14216 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14217 | else |
| 14218 | as_ln_s='cp -p' |
| 14219 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14220 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 14221 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14222 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14223 | |
| 14224 | # as_fn_mkdir_p |
| 14225 | # ------------- |
| 14226 | # Create "$as_dir" as a directory, including parents if necessary. |
| 14227 | as_fn_mkdir_p () |
| 14228 | { |
| 14229 | |
| 14230 | case $as_dir in #( |
| 14231 | -*) as_dir=./$as_dir;; |
| 14232 | esac |
| 14233 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 14234 | as_dirs= |
| 14235 | while :; do |
| 14236 | case $as_dir in #( |
| 14237 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 14238 | *) as_qdir=$as_dir;; |
| 14239 | esac |
| 14240 | as_dirs="'$as_qdir' $as_dirs" |
| 14241 | as_dir=`$as_dirname -- "$as_dir" || |
| 14242 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 14243 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 14244 | X"$as_dir" : 'X\(//\)$' \| \ |
| 14245 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 14246 | $as_echo X"$as_dir" | |
| 14247 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14248 | s//\1/ |
| 14249 | q |
| 14250 | } |
| 14251 | /^X\(\/\/\)[^/].*/{ |
| 14252 | s//\1/ |
| 14253 | q |
| 14254 | } |
| 14255 | /^X\(\/\/\)$/{ |
| 14256 | s//\1/ |
| 14257 | q |
| 14258 | } |
| 14259 | /^X\(\/\).*/{ |
| 14260 | s//\1/ |
| 14261 | q |
| 14262 | } |
| 14263 | s/.*/./; q'` |
| 14264 | test -d "$as_dir" && break |
| 14265 | done |
| 14266 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14267 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14268 | |
| 14269 | |
| 14270 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14271 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14272 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14273 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14274 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14275 | as_mkdir_p=false |
| 14276 | fi |
| 14277 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14278 | if test -x / >/dev/null 2>&1; then |
| 14279 | as_test_x='test -x' |
| 14280 | else |
| 14281 | if ls -dL / >/dev/null 2>&1; then |
| 14282 | as_ls_L_option=L |
| 14283 | else |
| 14284 | as_ls_L_option= |
| 14285 | fi |
| 14286 | as_test_x=' |
| 14287 | eval sh -c '\'' |
| 14288 | if test -d "$1"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14289 | test -d "$1/."; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14290 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14291 | case $1 in #( |
| 14292 | -*)set "./$1";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14293 | esac; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14294 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14295 | ???[sx]*):;;*)false;;esac;fi |
| 14296 | '\'' sh |
| 14297 | ' |
| 14298 | fi |
| 14299 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14300 | |
| 14301 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14302 | 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] | 14303 | |
| 14304 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14305 | 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] | 14306 | |
| 14307 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14308 | exec 6>&1 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14309 | ## ----------------------------------- ## |
| 14310 | ## Main body of $CONFIG_STATUS script. ## |
| 14311 | ## ----------------------------------- ## |
| 14312 | _ASEOF |
| 14313 | 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] | 14314 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14315 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14316 | # 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] | 14317 | # report actual input values of CONFIG_FILES etc. instead of their |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14318 | # values after options handling. |
| 14319 | ac_log=" |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 14320 | This file was extended by python $as_me 2.7, which was |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14321 | generated by GNU Autoconf 2.68. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14322 | |
| 14323 | CONFIG_FILES = $CONFIG_FILES |
| 14324 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 14325 | CONFIG_LINKS = $CONFIG_LINKS |
| 14326 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 14327 | $ $0 $@ |
| 14328 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14329 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 14330 | " |
| 14331 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14332 | _ACEOF |
| 14333 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14334 | case $ac_config_files in *" |
| 14335 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 14336 | esac |
| 14337 | |
| 14338 | case $ac_config_headers in *" |
| 14339 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 14340 | esac |
| 14341 | |
| 14342 | |
| 14343 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14344 | # Files that config.status was made for. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14345 | config_files="$ac_config_files" |
| 14346 | config_headers="$ac_config_headers" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14347 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14348 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14349 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14350 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14351 | ac_cs_usage="\ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14352 | \`$as_me' instantiates files and other configuration actions |
| 14353 | from templates according to the current configuration. Unless the files |
| 14354 | 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] | 14355 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14356 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14357 | |
| 14358 | -h, --help print this help, then exit |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14359 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14360 | --config print configuration, then exit |
| 14361 | -q, --quiet, --silent |
| 14362 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14363 | -d, --debug don't remove temporary files |
| 14364 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14365 | --file=FILE[:TEMPLATE] |
| 14366 | instantiate the configuration file FILE |
| 14367 | --header=FILE[:TEMPLATE] |
| 14368 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14369 | |
| 14370 | Configuration files: |
| 14371 | $config_files |
| 14372 | |
| 14373 | Configuration headers: |
| 14374 | $config_headers |
| 14375 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14376 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 14377 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14378 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14379 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14380 | 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] | 14381 | ac_cs_version="\\ |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 14382 | python config.status 2.7 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14383 | configured by $0, generated by GNU Autoconf 2.68, |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14384 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14385 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14386 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14387 | This config.status script is free software; the Free Software Foundation |
| 14388 | gives unlimited permission to copy, distribute and modify it." |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14389 | |
| 14390 | ac_pwd='$ac_pwd' |
| 14391 | srcdir='$srcdir' |
| 14392 | INSTALL='$INSTALL' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14393 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14394 | _ACEOF |
| 14395 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14396 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14397 | # 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] | 14398 | ac_need_defaults=: |
| 14399 | while test $# != 0 |
| 14400 | do |
| 14401 | case $1 in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14402 | --*=?*) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14403 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14404 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14405 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14406 | ;; |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14407 | --*=) |
| 14408 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14409 | ac_optarg= |
| 14410 | ac_shift=: |
| 14411 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14412 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14413 | ac_option=$1 |
| 14414 | ac_optarg=$2 |
| 14415 | ac_shift=shift |
| 14416 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14417 | esac |
| 14418 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14419 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14420 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14421 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 14422 | ac_cs_recheck=: ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14423 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14424 | $as_echo "$ac_cs_version"; exit ;; |
| 14425 | --config | --confi | --conf | --con | --co | --c ) |
| 14426 | $as_echo "$ac_cs_config"; exit ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14427 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14428 | debug=: ;; |
| 14429 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14430 | $ac_shift |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14431 | case $ac_optarg in |
| 14432 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14433 | '') as_fn_error $? "missing file argument" ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14434 | esac |
| 14435 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14436 | ac_need_defaults=false;; |
| 14437 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14438 | $ac_shift |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14439 | case $ac_optarg in |
| 14440 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14441 | esac |
| 14442 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14443 | ac_need_defaults=false;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14444 | --he | --h) |
| 14445 | # Conflict between --help and --header |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14446 | as_fn_error $? "ambiguous option: \`$1' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14447 | Try \`$0 --help' for more information.";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14448 | --help | --hel | -h ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14449 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14450 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 14451 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 14452 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14453 | |
| 14454 | # This is an error. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14455 | -*) as_fn_error $? "unrecognized option: \`$1' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14456 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14457 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14458 | *) as_fn_append ac_config_targets " $1" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14459 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14460 | |
| 14461 | esac |
| 14462 | shift |
| 14463 | done |
| 14464 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14465 | ac_configure_extra_args= |
| 14466 | |
| 14467 | if $ac_cs_silent; then |
| 14468 | exec 6>/dev/null |
| 14469 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 14470 | fi |
| 14471 | |
| 14472 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14473 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14474 | if \$ac_cs_recheck; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14475 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 14476 | shift |
| 14477 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 14478 | CONFIG_SHELL='$SHELL' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14479 | export CONFIG_SHELL |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14480 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14481 | fi |
| 14482 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14483 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14484 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14485 | exec 5>>config.log |
| 14486 | { |
| 14487 | echo |
| 14488 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 14489 | ## Running $as_me. ## |
| 14490 | _ASBOX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14491 | $as_echo "$ac_log" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14492 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14493 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14494 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14495 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14496 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14497 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14498 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14499 | |
| 14500 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14501 | for ac_config_target in $ac_config_targets |
| 14502 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14503 | case $ac_config_target in |
| 14504 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 14505 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 14506 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
| 14507 | "Mac/IDLE/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/IDLE/Makefile" ;; |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 14508 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 14509 | "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14510 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 14511 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 14512 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
Antoine Pitrou | aabdceb | 2010-09-10 20:03:17 +0000 | [diff] [blame] | 14513 | "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14514 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14515 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14516 | esac |
| 14517 | done |
| 14518 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14519 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14520 | # If the user did not use the arguments to specify the items to instantiate, |
| 14521 | # then the envvar interface is used. Set only those that are not. |
| 14522 | # We use the long form for the default assignment because of an extremely |
| 14523 | # bizarre bug on SunOS 4.1.3. |
| 14524 | if $ac_need_defaults; then |
| 14525 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 14526 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 14527 | fi |
| 14528 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14529 | # Have a temporary directory for convenience. Make it in the build tree |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14530 | # 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] | 14531 | # creating and moving files from /tmp can sometimes cause problems. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14532 | # Hook for its removal unless debugging. |
| 14533 | # Note that there is a small window in which the directory will not be cleaned: |
| 14534 | # 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] | 14535 | $debug || |
| 14536 | { |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14537 | tmp= ac_tmp= |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14538 | trap 'exit_status=$? |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14539 | : "${ac_tmp:=$tmp}" |
| 14540 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14541 | ' 0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14542 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14543 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14544 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14545 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14546 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14547 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14548 | test -d "$tmp" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14549 | } || |
| 14550 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14551 | tmp=./conf$$-$RANDOM |
| 14552 | (umask 077 && mkdir "$tmp") |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14553 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
| 14554 | ac_tmp=$tmp |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14555 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14556 | # Set up the scripts for CONFIG_FILES section. |
| 14557 | # No need to generate them if there are no CONFIG_FILES. |
| 14558 | # This happens for instance with `./config.status config.h'. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14559 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14560 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14561 | |
| 14562 | ac_cr=`echo X | tr X '\015'` |
| 14563 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 14564 | # But we know of no other shell where ac_cr would be empty at this |
| 14565 | # point, so we can use a bashism as a fallback. |
| 14566 | if test "x$ac_cr" = x; then |
| 14567 | eval ac_cr=\$\'\\r\' |
| 14568 | fi |
| 14569 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 14570 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14571 | ac_cs_awk_cr='\\r' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14572 | else |
| 14573 | ac_cs_awk_cr=$ac_cr |
| 14574 | fi |
| 14575 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14576 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14577 | _ACEOF |
| 14578 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14579 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14580 | { |
| 14581 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 14582 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 14583 | echo "_ACEOF" |
| 14584 | } >conf$$subs.sh || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14585 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 14586 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14587 | ac_delim='%!_!# ' |
| 14588 | for ac_last_try in false false false false false :; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14589 | . ./conf$$subs.sh || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14590 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14591 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14592 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 14593 | if test $ac_delim_n = $ac_delim_num; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14594 | break |
| 14595 | elif $ac_last_try; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14596 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14597 | else |
| 14598 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14599 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14600 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14601 | rm -f conf$$subs.sh |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14602 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14603 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14604 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14605 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14606 | sed -n ' |
| 14607 | h |
| 14608 | s/^/S["/; s/!.*/"]=/ |
| 14609 | p |
| 14610 | g |
| 14611 | s/^[^!]*!// |
| 14612 | :repl |
| 14613 | t repl |
| 14614 | s/'"$ac_delim"'$// |
| 14615 | t delim |
| 14616 | :nl |
| 14617 | h |
| 14618 | s/\(.\{148\}\)..*/\1/ |
| 14619 | t more1 |
| 14620 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 14621 | p |
| 14622 | n |
| 14623 | b repl |
| 14624 | :more1 |
| 14625 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14626 | p |
| 14627 | g |
| 14628 | s/.\{148\}// |
| 14629 | t nl |
| 14630 | :delim |
| 14631 | h |
| 14632 | s/\(.\{148\}\)..*/\1/ |
| 14633 | t more2 |
| 14634 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 14635 | p |
| 14636 | b |
| 14637 | :more2 |
| 14638 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14639 | p |
| 14640 | g |
| 14641 | s/.\{148\}// |
| 14642 | t delim |
| 14643 | ' <conf$$subs.awk | sed ' |
| 14644 | /^[^""]/{ |
| 14645 | N |
| 14646 | s/\n// |
| 14647 | } |
| 14648 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14649 | rm -f conf$$subs.awk |
| 14650 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14651 | _ACAWK |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14652 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14653 | for (key in S) S_is_set[key] = 1 |
| 14654 | FS = "" |
| 14655 | |
| 14656 | } |
| 14657 | { |
| 14658 | line = $ 0 |
| 14659 | nfields = split(line, field, "@") |
| 14660 | substed = 0 |
| 14661 | len = length(field[1]) |
| 14662 | for (i = 2; i < nfields; i++) { |
| 14663 | key = field[i] |
| 14664 | keylen = length(key) |
| 14665 | if (S_is_set[key]) { |
| 14666 | value = S[key] |
| 14667 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 14668 | len += length(value) + length(field[++i]) |
| 14669 | substed = 1 |
| 14670 | } else |
| 14671 | len += 1 + keylen |
| 14672 | } |
| 14673 | |
| 14674 | print line |
| 14675 | } |
| 14676 | |
| 14677 | _ACAWK |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14678 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14679 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14680 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 14681 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 14682 | else |
| 14683 | cat |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14684 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
| 14685 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 14686 | _ACEOF |
| 14687 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14688 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
| 14689 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14690 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 14691 | # (actually we leave an empty line to preserve line numbers). |
| 14692 | if test "x$srcdir" = x.; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14693 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
| 14694 | h |
| 14695 | s/// |
| 14696 | s/^/:/ |
| 14697 | s/[ ]*$/:/ |
| 14698 | s/:\$(srcdir):/:/g |
| 14699 | s/:\${srcdir}:/:/g |
| 14700 | s/:@srcdir@:/:/g |
| 14701 | s/^:*// |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14702 | s/:*$// |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14703 | x |
| 14704 | s/\(=[ ]*\).*/\1/ |
| 14705 | G |
| 14706 | s/\n// |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14707 | s/^[^=]*=[ ]*$// |
| 14708 | }' |
| 14709 | fi |
| 14710 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14711 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14712 | fi # test -n "$CONFIG_FILES" |
| 14713 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14714 | # Set up the scripts for CONFIG_HEADERS section. |
| 14715 | # No need to generate them if there are no CONFIG_HEADERS. |
| 14716 | # This happens for instance with `./config.status Makefile'. |
| 14717 | if test -n "$CONFIG_HEADERS"; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14718 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14719 | BEGIN { |
| 14720 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14721 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14722 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 14723 | # here-document in config.status, that substitutes the proper values into |
| 14724 | # config.h.in to produce config.h. |
| 14725 | |
| 14726 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 14727 | # handling of long lines. |
| 14728 | ac_delim='%!_!# ' |
| 14729 | for ac_last_try in false false :; do |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14730 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
| 14731 | if test -z "$ac_tt"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14732 | break |
| 14733 | elif $ac_last_try; then |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14734 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14735 | else |
| 14736 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 14737 | fi |
| 14738 | done |
| 14739 | |
| 14740 | # For the awk script, D is an array of macro values keyed by name, |
| 14741 | # likewise P contains macro parameters if any. Preserve backslash |
| 14742 | # newline sequences. |
| 14743 | |
| 14744 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 14745 | sed -n ' |
| 14746 | s/.\{148\}/&'"$ac_delim"'/g |
| 14747 | t rset |
| 14748 | :rset |
| 14749 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 14750 | t def |
| 14751 | d |
| 14752 | :def |
| 14753 | s/\\$// |
| 14754 | t bsnl |
| 14755 | s/["\\]/\\&/g |
| 14756 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14757 | D["\1"]=" \3"/p |
| 14758 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 14759 | d |
| 14760 | :bsnl |
| 14761 | s/["\\]/\\&/g |
| 14762 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14763 | D["\1"]=" \3\\\\\\n"\\/p |
| 14764 | t cont |
| 14765 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 14766 | t cont |
| 14767 | d |
| 14768 | :cont |
| 14769 | n |
| 14770 | s/.\{148\}/&'"$ac_delim"'/g |
| 14771 | t clear |
| 14772 | :clear |
| 14773 | s/\\$// |
| 14774 | t bsnlc |
| 14775 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 14776 | d |
| 14777 | :bsnlc |
| 14778 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 14779 | b cont |
| 14780 | ' <confdefs.h | sed ' |
| 14781 | s/'"$ac_delim"'/"\\\ |
| 14782 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14783 | |
| 14784 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14785 | for (key in D) D_is_set[key] = 1 |
| 14786 | FS = "" |
| 14787 | } |
| 14788 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 14789 | line = \$ 0 |
| 14790 | split(line, arg, " ") |
| 14791 | if (arg[1] == "#") { |
| 14792 | defundef = arg[2] |
| 14793 | mac1 = arg[3] |
| 14794 | } else { |
| 14795 | defundef = substr(arg[1], 2) |
| 14796 | mac1 = arg[2] |
| 14797 | } |
| 14798 | split(mac1, mac2, "(") #) |
| 14799 | macro = mac2[1] |
| 14800 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 14801 | if (D_is_set[macro]) { |
| 14802 | # Preserve the white space surrounding the "#". |
| 14803 | print prefix "define", macro P[macro] D[macro] |
| 14804 | next |
| 14805 | } else { |
| 14806 | # Replace #undef with comments. This is necessary, for example, |
| 14807 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 14808 | # on some systems where configure will not decide to define it. |
| 14809 | if (defundef == "undef") { |
| 14810 | print "/*", prefix defundef, macro, "*/" |
| 14811 | next |
| 14812 | } |
| 14813 | } |
| 14814 | } |
| 14815 | { print } |
| 14816 | _ACAWK |
| 14817 | _ACEOF |
| 14818 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14819 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14820 | fi # test -n "$CONFIG_HEADERS" |
| 14821 | |
| 14822 | |
| 14823 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 14824 | shift |
| 14825 | for ac_tag |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14826 | do |
| 14827 | case $ac_tag in |
| 14828 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 14829 | esac |
| 14830 | case $ac_mode$ac_tag in |
| 14831 | :[FHL]*:*);; |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14832 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14833 | :[FH]-) ac_tag=-:-;; |
| 14834 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 14835 | esac |
| 14836 | ac_save_IFS=$IFS |
| 14837 | IFS=: |
| 14838 | set x $ac_tag |
| 14839 | IFS=$ac_save_IFS |
| 14840 | shift |
| 14841 | ac_file=$1 |
| 14842 | shift |
| 14843 | |
| 14844 | case $ac_mode in |
| 14845 | :L) ac_source=$1;; |
| 14846 | :[FH]) |
| 14847 | ac_file_inputs= |
| 14848 | for ac_f |
| 14849 | do |
| 14850 | case $ac_f in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14851 | -) ac_f="$ac_tmp/stdin";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14852 | *) # Look for the file first in the build tree, then in the source tree |
| 14853 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 14854 | # because $ac_f cannot contain `:'. |
| 14855 | test -f "$ac_f" || |
| 14856 | case $ac_f in |
| 14857 | [\\/$]*) false;; |
| 14858 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 14859 | esac || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14860 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14861 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14862 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 14863 | as_fn_append ac_file_inputs " '$ac_f'" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14864 | done |
| 14865 | |
| 14866 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 14867 | # use $as_me), people would be surprised to read: |
| 14868 | # /* config.h. Generated by config.status. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14869 | configure_input='Generated from '` |
| 14870 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 14871 | `' by configure.' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14872 | if test x"$ac_file" != x-; then |
| 14873 | configure_input="$ac_file. $configure_input" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14874 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 14875 | $as_echo "$as_me: creating $ac_file" >&6;} |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14876 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14877 | # Neutralize special characters interpreted by sed in replacement strings. |
| 14878 | case $configure_input in #( |
| 14879 | *\&* | *\|* | *\\* ) |
| 14880 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 14881 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 14882 | *) ac_sed_conf_input=$configure_input;; |
| 14883 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14884 | |
| 14885 | case $ac_tag in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 14886 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
| 14887 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14888 | esac |
| 14889 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14890 | esac |
| 14891 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14892 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14893 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14894 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 14895 | X"$ac_file" : 'X\(//\)$' \| \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14896 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14897 | $as_echo X"$ac_file" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14898 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14899 | s//\1/ |
| 14900 | q |
| 14901 | } |
| 14902 | /^X\(\/\/\)[^/].*/{ |
| 14903 | s//\1/ |
| 14904 | q |
| 14905 | } |
| 14906 | /^X\(\/\/\)$/{ |
| 14907 | s//\1/ |
| 14908 | q |
| 14909 | } |
| 14910 | /^X\(\/\).*/{ |
| 14911 | s//\1/ |
| 14912 | q |
| 14913 | } |
| 14914 | s/.*/./; q'` |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14915 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14916 | ac_builddir=. |
| 14917 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14918 | case "$ac_dir" in |
| 14919 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14920 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14921 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14922 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14923 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14924 | case $ac_top_builddir_sub in |
| 14925 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14926 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 14927 | esac ;; |
| 14928 | esac |
| 14929 | ac_abs_top_builddir=$ac_pwd |
| 14930 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 14931 | # for backward compatibility: |
| 14932 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14933 | |
| 14934 | case $srcdir in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14935 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14936 | ac_srcdir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14937 | ac_top_srcdir=$ac_top_builddir_sub |
| 14938 | ac_abs_top_srcdir=$ac_pwd ;; |
| 14939 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14940 | ac_srcdir=$srcdir$ac_dir_suffix; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14941 | ac_top_srcdir=$srcdir |
| 14942 | ac_abs_top_srcdir=$srcdir ;; |
| 14943 | *) # Relative name. |
| 14944 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 14945 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 14946 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14947 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14948 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14949 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14950 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14951 | case $ac_mode in |
| 14952 | :F) |
| 14953 | # |
| 14954 | # CONFIG_FILE |
| 14955 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14956 | |
| 14957 | case $INSTALL in |
| 14958 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14959 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14960 | esac |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 14961 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14962 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14963 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14964 | # If the template does not know about datarootdir, expand it. |
| 14965 | # FIXME: This hack should be removed a few years after 2.60. |
| 14966 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14967 | ac_sed_dataroot=' |
| 14968 | /datarootdir/ { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14969 | p |
| 14970 | q |
| 14971 | } |
| 14972 | /@datadir@/p |
| 14973 | /@docdir@/p |
| 14974 | /@infodir@/p |
| 14975 | /@localedir@/p |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14976 | /@mandir@/p' |
| 14977 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14978 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 14979 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14980 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 14981 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14982 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14983 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14984 | ac_datarootdir_hack=' |
| 14985 | s&@datadir@&$datadir&g |
| 14986 | s&@docdir@&$docdir&g |
| 14987 | s&@infodir@&$infodir&g |
| 14988 | s&@localedir@&$localedir&g |
| 14989 | s&@mandir@&$mandir&g |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14990 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14991 | esac |
| 14992 | _ACEOF |
| 14993 | |
| 14994 | # Neutralize VPATH when `$srcdir' = `.'. |
| 14995 | # Shell code in configure.ac might set extrasub. |
| 14996 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14997 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14998 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14999 | $extrasub |
| 15000 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15001 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15002 | :t |
| 15003 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15004 | s|@configure_input@|$ac_sed_conf_input|;t t |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15005 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15006 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15007 | s&@srcdir@&$ac_srcdir&;t t |
| 15008 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 15009 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 15010 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 15011 | s&@builddir@&$ac_builddir&;t t |
| 15012 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 15013 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 15014 | s&@INSTALL@&$ac_INSTALL&;t t |
| 15015 | $ac_datarootdir_hack |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15016 | " |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15017 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
| 15018 | >$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] | 15019 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15020 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15021 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
| 15022 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ |
| 15023 | "$ac_tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15024 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15025 | which seems to be undefined. Please make sure it is defined" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15026 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15027 | which seems to be undefined. Please make sure it is defined" >&2;} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15028 | |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15029 | rm -f "$ac_tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15030 | case $ac_file in |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15031 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
| 15032 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15033 | esac \ |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15034 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15035 | ;; |
| 15036 | :H) |
| 15037 | # |
| 15038 | # CONFIG_HEADER |
| 15039 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15040 | if test x"$ac_file" != x-; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15041 | { |
| 15042 | $as_echo "/* $configure_input */" \ |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15043 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
| 15044 | } >"$ac_tmp/config.h" \ |
| 15045 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
| 15046 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15047 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 15048 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15049 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15050 | rm -f "$ac_file" |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15051 | mv "$ac_tmp/config.h" "$ac_file" \ |
| 15052 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15053 | fi |
| 15054 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15055 | $as_echo "/* $configure_input */" \ |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15056 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
| 15057 | || as_fn_error $? "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15058 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15059 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 15060 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15061 | |
| 15062 | esac |
| 15063 | |
Antoine Pitrou | aabdceb | 2010-09-10 20:03:17 +0000 | [diff] [blame] | 15064 | |
| 15065 | case $ac_file$ac_mode in |
| 15066 | "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;; |
| 15067 | |
| 15068 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 15069 | done # for ac_tag |
| 15070 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15071 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15072 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15073 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15074 | ac_clean_files=$ac_clean_files_save |
| 15075 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15076 | test $ac_write_fail = 0 || |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15077 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15078 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15079 | |
| 15080 | # configure is writing to config.log, and then calls config.status. |
| 15081 | # config.status does its own redirection, appending to config.log. |
| 15082 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 15083 | # by configure, so config.status won't be able to write to it; its |
| 15084 | # output is simply discarded. So we exec the FD to /dev/null, |
| 15085 | # effectively closing config.log, so it can be properly (re)opened and |
| 15086 | # appended to by config.status. When coming back to configure, we |
| 15087 | # need to make the FD available again. |
| 15088 | if test "$no_create" != yes; then |
| 15089 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15090 | ac_config_status_args= |
| 15091 | test "$silent" = yes && |
| 15092 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15093 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15094 | $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] | 15095 | exec 5>>config.log |
| 15096 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 15097 | # would make configure fail if this is the last instruction. |
Georg Brandl | 71f4fbb | 2011-02-25 11:04:50 +0000 | [diff] [blame] | 15098 | $ac_cs_success || as_fn_exit 1 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15099 | fi |
| 15100 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 15101 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 15102 | $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] | 15103 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15104 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15105 | |
Martin v. Löwis | f7afe95 | 2006-04-14 15:16:15 +0000 | [diff] [blame] | 15106 | echo "creating Modules/Setup" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15107 | if test ! -f Modules/Setup |
| 15108 | then |
| 15109 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 15110 | fi |
| 15111 | |
Martin v. Löwis | f7afe95 | 2006-04-14 15:16:15 +0000 | [diff] [blame] | 15112 | echo "creating Modules/Setup.local" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15113 | if test ! -f Modules/Setup.local |
| 15114 | then |
| 15115 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 15116 | fi |
| 15117 | |
| 15118 | echo "creating Makefile" |
| 15119 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 15120 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 15121 | Modules/Setup.local Modules/Setup |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 15122 | |
| 15123 | case $ac_sys_system in |
| 15124 | BeOS) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15125 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 15126 | |
| 15127 | Support for BeOS is deprecated as of Python 2.6. |
| 15128 | See PEP 11 for the gory details. |
| 15129 | " >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15130 | $as_echo "$as_me: WARNING: |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 15131 | |
| 15132 | Support for BeOS is deprecated as of Python 2.6. |
| 15133 | See PEP 11 for the gory details. |
| 15134 | " >&2;} |
| 15135 | ;; |
| 15136 | *) ;; |
| 15137 | esac |
| 15138 | |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 15139 | mv config.c Modules |