Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Benjamin Peterson | 66556b0 | 2010-05-25 02:23:32 +0000 | [diff] [blame^] | 2 | # From configure.in Revision: 81077 . |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3 | # Guess values for system-dependent variables and create Makefiles. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4 | # Generated by GNU Autoconf 2.65 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, |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, |
| 11 | # Inc. |
| 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. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 95 | case $0 in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 96 | *[\\/]* ) as_myself=$0 ;; |
| 97 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 98 | for as_dir in $PATH |
| 99 | do |
| 100 | IFS=$as_save_IFS |
| 101 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 102 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 103 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 104 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 105 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 106 | ;; |
| 107 | esac |
| 108 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 109 | # in which case we are not to be found in the path. |
| 110 | if test "x$as_myself" = x; then |
| 111 | as_myself=$0 |
| 112 | fi |
| 113 | if test ! -f "$as_myself"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 114 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 115 | exit 1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 116 | fi |
| 117 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 118 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 119 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 120 | # suppresses any "Segmentation fault" message there. '((' could |
| 121 | # trigger a bug in pdksh 5.2.14. |
| 122 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 123 | do eval test x\${$as_var+set} = xset \ |
| 124 | && ( (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] | 125 | done |
| 126 | PS1='$ ' |
| 127 | PS2='> ' |
| 128 | PS4='+ ' |
| 129 | |
| 130 | # NLS nuisances. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 131 | LC_ALL=C |
| 132 | export LC_ALL |
| 133 | LANGUAGE=C |
| 134 | export LANGUAGE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 135 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 136 | # CDPATH. |
| 137 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 138 | |
| 139 | if test "x$CONFIG_SHELL" = x; then |
| 140 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 141 | emulate sh |
| 142 | NULLCMD=: |
| 143 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 144 | # is contrary to our usage. Disable this feature. |
| 145 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 146 | setopt NO_GLOB_SUBST |
| 147 | else |
| 148 | case \`(set -o) 2>/dev/null\` in #( |
| 149 | *posix*) : |
| 150 | set -o posix ;; #( |
| 151 | *) : |
| 152 | ;; |
| 153 | esac |
| 154 | fi |
| 155 | " |
| 156 | as_required="as_fn_return () { (exit \$1); } |
| 157 | as_fn_success () { as_fn_return 0; } |
| 158 | as_fn_failure () { as_fn_return 1; } |
| 159 | as_fn_ret_success () { return 0; } |
| 160 | as_fn_ret_failure () { return 1; } |
| 161 | |
| 162 | exitcode=0 |
| 163 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 164 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 165 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 166 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 167 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 168 | |
| 169 | else |
| 170 | exitcode=1; echo positional parameters were not saved. |
| 171 | fi |
| 172 | test x\$exitcode = x0 || exit 1" |
| 173 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 174 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 175 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 176 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 177 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 178 | if (eval "$as_required") 2>/dev/null; then : |
| 179 | as_have_required=yes |
| 180 | else |
| 181 | as_have_required=no |
| 182 | fi |
| 183 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 184 | |
| 185 | else |
| 186 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 187 | as_found=false |
| 188 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 189 | do |
| 190 | IFS=$as_save_IFS |
| 191 | test -z "$as_dir" && as_dir=. |
| 192 | as_found=: |
| 193 | case $as_dir in #( |
| 194 | /*) |
| 195 | for as_base in sh bash ksh sh5; do |
| 196 | # Try only shells that exist, to save several forks. |
| 197 | as_shell=$as_dir/$as_base |
| 198 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 199 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 200 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 201 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 202 | break 2 |
| 203 | fi |
| 204 | fi |
| 205 | done;; |
| 206 | esac |
| 207 | as_found=false |
| 208 | done |
| 209 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 210 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 211 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 212 | fi; } |
| 213 | IFS=$as_save_IFS |
| 214 | |
| 215 | |
| 216 | if test "x$CONFIG_SHELL" != x; then : |
| 217 | # We cannot yet assume a decent shell, so we have to provide a |
| 218 | # neutralization value for shells without unset; and this also |
| 219 | # works around shells that cannot unset nonexistent variables. |
| 220 | BASH_ENV=/dev/null |
| 221 | ENV=/dev/null |
| 222 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 223 | export CONFIG_SHELL |
| 224 | exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} |
| 225 | fi |
| 226 | |
| 227 | if test x$as_have_required = xno; then : |
| 228 | $as_echo "$0: This script requires a shell more modern than all" |
| 229 | $as_echo "$0: the shells that I found on your system." |
| 230 | if test x${ZSH_VERSION+set} = xset ; then |
| 231 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 232 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 233 | else |
| 234 | $as_echo "$0: Please tell bug-autoconf@gnu.org and |
| 235 | $0: http://bugs.python.org/ about your system, including |
| 236 | $0: any error possibly output before this message. Then |
| 237 | $0: install a modern shell, or manually run the script |
| 238 | $0: under such a shell if you do have one." |
| 239 | fi |
| 240 | exit 1 |
| 241 | fi |
| 242 | fi |
| 243 | fi |
| 244 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 245 | export SHELL |
| 246 | # Unset more variables known to interfere with behavior of common tools. |
| 247 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 248 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 249 | |
| 250 | ## --------------------- ## |
| 251 | ## M4sh Shell Functions. ## |
| 252 | ## --------------------- ## |
| 253 | # as_fn_unset VAR |
| 254 | # --------------- |
| 255 | # Portably unset VAR. |
| 256 | as_fn_unset () |
| 257 | { |
| 258 | { eval $1=; unset $1;} |
| 259 | } |
| 260 | as_unset=as_fn_unset |
| 261 | |
| 262 | # as_fn_set_status STATUS |
| 263 | # ----------------------- |
| 264 | # Set $? to STATUS, without forking. |
| 265 | as_fn_set_status () |
| 266 | { |
| 267 | return $1 |
| 268 | } # as_fn_set_status |
| 269 | |
| 270 | # as_fn_exit STATUS |
| 271 | # ----------------- |
| 272 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 273 | as_fn_exit () |
| 274 | { |
| 275 | set +e |
| 276 | as_fn_set_status $1 |
| 277 | exit $1 |
| 278 | } # as_fn_exit |
| 279 | |
| 280 | # as_fn_mkdir_p |
| 281 | # ------------- |
| 282 | # Create "$as_dir" as a directory, including parents if necessary. |
| 283 | as_fn_mkdir_p () |
| 284 | { |
| 285 | |
| 286 | case $as_dir in #( |
| 287 | -*) as_dir=./$as_dir;; |
| 288 | esac |
| 289 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 290 | as_dirs= |
| 291 | while :; do |
| 292 | case $as_dir in #( |
| 293 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 294 | *) as_qdir=$as_dir;; |
| 295 | esac |
| 296 | as_dirs="'$as_qdir' $as_dirs" |
| 297 | as_dir=`$as_dirname -- "$as_dir" || |
| 298 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 299 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 300 | X"$as_dir" : 'X\(//\)$' \| \ |
| 301 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 302 | $as_echo X"$as_dir" | |
| 303 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 304 | s//\1/ |
| 305 | q |
| 306 | } |
| 307 | /^X\(\/\/\)[^/].*/{ |
| 308 | s//\1/ |
| 309 | q |
| 310 | } |
| 311 | /^X\(\/\/\)$/{ |
| 312 | s//\1/ |
| 313 | q |
| 314 | } |
| 315 | /^X\(\/\).*/{ |
| 316 | s//\1/ |
| 317 | q |
| 318 | } |
| 319 | s/.*/./; q'` |
| 320 | test -d "$as_dir" && break |
| 321 | done |
| 322 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
| 323 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" |
| 324 | |
| 325 | |
| 326 | } # as_fn_mkdir_p |
| 327 | # as_fn_append VAR VALUE |
| 328 | # ---------------------- |
| 329 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 330 | # advantage of any shell optimizations that allow amortized linear growth over |
| 331 | # repeated appends, instead of the typical quadratic growth present in naive |
| 332 | # implementations. |
| 333 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 334 | eval 'as_fn_append () |
| 335 | { |
| 336 | eval $1+=\$2 |
| 337 | }' |
| 338 | else |
| 339 | as_fn_append () |
| 340 | { |
| 341 | eval $1=\$$1\$2 |
| 342 | } |
| 343 | fi # as_fn_append |
| 344 | |
| 345 | # as_fn_arith ARG... |
| 346 | # ------------------ |
| 347 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 348 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 349 | # must be portable across $(()) and expr. |
| 350 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 351 | eval 'as_fn_arith () |
| 352 | { |
| 353 | as_val=$(( $* )) |
| 354 | }' |
| 355 | else |
| 356 | as_fn_arith () |
| 357 | { |
| 358 | as_val=`expr "$@" || test $? -eq 1` |
| 359 | } |
| 360 | fi # as_fn_arith |
| 361 | |
| 362 | |
| 363 | # as_fn_error ERROR [LINENO LOG_FD] |
| 364 | # --------------------------------- |
| 365 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 366 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
| 367 | # script with status $?, using 1 if that was 0. |
| 368 | as_fn_error () |
| 369 | { |
| 370 | as_status=$?; test $as_status -eq 0 && as_status=1 |
| 371 | if test "$3"; then |
| 372 | as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 373 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 |
| 374 | fi |
| 375 | $as_echo "$as_me: error: $1" >&2 |
| 376 | as_fn_exit $as_status |
| 377 | } # as_fn_error |
| 378 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 379 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 380 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 381 | as_expr=expr |
| 382 | else |
| 383 | as_expr=false |
| 384 | fi |
| 385 | |
| 386 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 387 | as_basename=basename |
| 388 | else |
| 389 | as_basename=false |
| 390 | fi |
| 391 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 392 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 393 | as_dirname=dirname |
| 394 | else |
| 395 | as_dirname=false |
| 396 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 397 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 398 | as_me=`$as_basename -- "$0" || |
| 399 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 400 | X"$0" : 'X\(//\)$' \| \ |
| 401 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 402 | $as_echo X/"$0" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 403 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 404 | s//\1/ |
| 405 | q |
| 406 | } |
| 407 | /^X\/\(\/\/\)$/{ |
| 408 | s//\1/ |
| 409 | q |
| 410 | } |
| 411 | /^X\/\(\/\).*/{ |
| 412 | s//\1/ |
| 413 | q |
| 414 | } |
| 415 | s/.*/./; q'` |
| 416 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 417 | # Avoid depending upon Character Ranges. |
| 418 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 419 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 420 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 421 | as_cr_digits='0123456789' |
| 422 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 423 | |
| 424 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 425 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 426 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 427 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 428 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 429 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 430 | sed -n ' |
| 431 | p |
| 432 | /[$]LINENO/= |
| 433 | ' <$as_myself | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 434 | sed ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 435 | s/[$]LINENO.*/&-/ |
| 436 | t lineno |
| 437 | b |
| 438 | :lineno |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 439 | N |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 440 | :loop |
| 441 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 442 | t loop |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 443 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 444 | ' >$as_me.lineno && |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 445 | chmod +x "$as_me.lineno" || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 446 | { $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] | 447 | |
| 448 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 449 | # (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] | 450 | # original and so on. Autoconf is especially sensitive to this). |
| 451 | . "./$as_me.lineno" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 452 | # Exit status is that of the last command. |
| 453 | exit |
| 454 | } |
| 455 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 456 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 457 | case `echo -n x` in #((((( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 458 | -n*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 459 | case `echo 'xy\c'` in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 460 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 461 | xy) ECHO_C='\c';; |
| 462 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 463 | ECHO_T=' ';; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 464 | esac;; |
| 465 | *) |
| 466 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 467 | esac |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 468 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 469 | rm -f conf$$ conf$$.exe conf$$.file |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 470 | if test -d conf$$.dir; then |
| 471 | rm -f conf$$.dir/conf$$.file |
| 472 | else |
| 473 | rm -f conf$$.dir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 474 | mkdir conf$$.dir 2>/dev/null |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 475 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 476 | if (echo >conf$$.file) 2>/dev/null; then |
| 477 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 478 | as_ln_s='ln -s' |
| 479 | # ... but there are two gotchas: |
| 480 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 481 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 482 | # In both cases, we have to default to `cp -p'. |
| 483 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 484 | as_ln_s='cp -p' |
| 485 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 486 | as_ln_s=ln |
| 487 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 488 | as_ln_s='cp -p' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 489 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 490 | else |
| 491 | as_ln_s='cp -p' |
| 492 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 493 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 494 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 495 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 496 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 497 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 498 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 499 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 500 | as_mkdir_p=false |
| 501 | fi |
| 502 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 503 | if test -x / >/dev/null 2>&1; then |
| 504 | as_test_x='test -x' |
| 505 | else |
| 506 | if ls -dL / >/dev/null 2>&1; then |
| 507 | as_ls_L_option=L |
| 508 | else |
| 509 | as_ls_L_option= |
| 510 | fi |
| 511 | as_test_x=' |
| 512 | eval sh -c '\'' |
| 513 | if test -d "$1"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 514 | test -d "$1/."; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 515 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 516 | case $1 in #( |
| 517 | -*)set "./$1";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 518 | esac; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 519 | 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] | 520 | ???[sx]*):;;*)false;;esac;fi |
| 521 | '\'' sh |
| 522 | ' |
| 523 | fi |
| 524 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 525 | |
| 526 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 527 | 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] | 528 | |
| 529 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 530 | 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] | 531 | |
| 532 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 533 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 534 | exec 6>&1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 535 | |
| 536 | # Name of the host. |
| 537 | # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, |
| 538 | # so uname gets run too. |
| 539 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 540 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 541 | # |
| 542 | # Initializations. |
| 543 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 544 | ac_default_prefix=/usr/local |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 545 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 546 | ac_config_libobj_dir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 547 | LIBOBJS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 548 | cross_compiling=no |
| 549 | subdirs= |
| 550 | MFLAGS= |
| 551 | MAKEFLAGS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 552 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 553 | # Identity of this package. |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 554 | PACKAGE_NAME='python' |
| 555 | PACKAGE_TARNAME='python' |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 556 | PACKAGE_VERSION='2.7' |
| 557 | PACKAGE_STRING='python 2.7' |
Georg Brandl | 464432d | 2009-05-20 18:24:08 +0000 | [diff] [blame] | 558 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 559 | PACKAGE_URL='' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 560 | |
| 561 | ac_unique_file="Include/object.h" |
| 562 | # Factoring default headers for most tests. |
| 563 | ac_includes_default="\ |
| 564 | #include <stdio.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 565 | #ifdef HAVE_SYS_TYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 566 | # include <sys/types.h> |
| 567 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 568 | #ifdef HAVE_SYS_STAT_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 569 | # include <sys/stat.h> |
| 570 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 571 | #ifdef STDC_HEADERS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 572 | # include <stdlib.h> |
| 573 | # include <stddef.h> |
| 574 | #else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 575 | # ifdef HAVE_STDLIB_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 576 | # include <stdlib.h> |
| 577 | # endif |
| 578 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 579 | #ifdef HAVE_STRING_H |
| 580 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 581 | # include <memory.h> |
| 582 | # endif |
| 583 | # include <string.h> |
| 584 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 585 | #ifdef HAVE_STRINGS_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 586 | # include <strings.h> |
| 587 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 588 | #ifdef HAVE_INTTYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 589 | # include <inttypes.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 590 | #endif |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 591 | #ifdef HAVE_STDINT_H |
| 592 | # include <stdint.h> |
| 593 | #endif |
| 594 | #ifdef HAVE_UNISTD_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 595 | # include <unistd.h> |
| 596 | #endif" |
| 597 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 598 | ac_subst_vars='LTLIBOBJS |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 599 | SRCDIRS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 600 | THREADHEADERS |
| 601 | UNICODE_OBJS |
| 602 | LIBC |
| 603 | LIBM |
| 604 | HAVE_GETHOSTBYNAME |
| 605 | HAVE_GETHOSTBYNAME_R |
| 606 | HAVE_GETHOSTBYNAME_R_3_ARG |
| 607 | HAVE_GETHOSTBYNAME_R_5_ARG |
| 608 | HAVE_GETHOSTBYNAME_R_6_ARG |
| 609 | LIBOBJS |
| 610 | TRUE |
| 611 | MACHDEP_OBJS |
| 612 | DYNLOADFILE |
| 613 | DLINCLDIR |
| 614 | THREADOBJ |
| 615 | LDLAST |
| 616 | USE_THREAD_MODULE |
| 617 | SIGNAL_OBJS |
| 618 | USE_SIGNAL_MODULE |
| 619 | LIBFFI_INCLUDEDIR |
| 620 | PKG_CONFIG |
| 621 | SHLIBS |
| 622 | CFLAGSFORSHARED |
| 623 | LINKFORSHARED |
| 624 | CCSHARED |
| 625 | BLDSHARED |
| 626 | LDCXXSHARED |
| 627 | LDSHARED |
| 628 | SO |
| 629 | LIBTOOL_CRUFT |
| 630 | OTHER_LIBTOOL_OPT |
| 631 | UNIVERSAL_ARCH_FLAGS |
| 632 | BASECFLAGS |
| 633 | OPT |
| 634 | LN |
| 635 | INSTALL_DATA |
| 636 | INSTALL_SCRIPT |
| 637 | INSTALL_PROGRAM |
| 638 | SVNVERSION |
| 639 | ARFLAGS |
| 640 | AR |
| 641 | RANLIB |
| 642 | GNULD |
| 643 | LINKCC |
| 644 | RUNSHARED |
| 645 | INSTSONAME |
| 646 | LDLIBRARYDIR |
| 647 | BLDLIBRARY |
| 648 | DLLLIBRARY |
| 649 | LDLIBRARY |
| 650 | LIBRARY |
| 651 | BUILDEXEEXT |
| 652 | EGREP |
| 653 | GREP |
| 654 | CPP |
| 655 | MAINCC |
| 656 | CXX |
| 657 | OBJEXT |
| 658 | EXEEXT |
| 659 | ac_ct_CC |
| 660 | CPPFLAGS |
| 661 | LDFLAGS |
| 662 | CFLAGS |
| 663 | CC |
| 664 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 665 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 666 | EXTRAMACHDEPPATH |
| 667 | EXTRAPLATDIR |
| 668 | SGI_ABI |
| 669 | MACHDEP |
| 670 | FRAMEWORKINSTALLAPPSPREFIX |
| 671 | FRAMEWORKUNIXTOOLSPREFIX |
| 672 | FRAMEWORKALTINSTALLLAST |
| 673 | FRAMEWORKALTINSTALLFIRST |
| 674 | FRAMEWORKINSTALLLAST |
| 675 | FRAMEWORKINSTALLFIRST |
| 676 | PYTHONFRAMEWORKINSTALLDIR |
| 677 | PYTHONFRAMEWORKPREFIX |
| 678 | PYTHONFRAMEWORKDIR |
| 679 | PYTHONFRAMEWORKIDENTIFIER |
| 680 | PYTHONFRAMEWORK |
| 681 | LIPO_32BIT_FLAGS |
| 682 | ARCH_RUN_32BIT |
| 683 | UNIVERSALSDK |
| 684 | CONFIG_ARGS |
| 685 | SOVERSION |
| 686 | VERSION |
| 687 | target_alias |
| 688 | host_alias |
| 689 | build_alias |
| 690 | LIBS |
| 691 | ECHO_T |
| 692 | ECHO_N |
| 693 | ECHO_C |
| 694 | DEFS |
| 695 | mandir |
| 696 | localedir |
| 697 | libdir |
| 698 | psdir |
| 699 | pdfdir |
| 700 | dvidir |
| 701 | htmldir |
| 702 | infodir |
| 703 | docdir |
| 704 | oldincludedir |
| 705 | includedir |
| 706 | localstatedir |
| 707 | sharedstatedir |
| 708 | sysconfdir |
| 709 | datadir |
| 710 | datarootdir |
| 711 | libexecdir |
| 712 | sbindir |
| 713 | bindir |
| 714 | program_transform_name |
| 715 | prefix |
| 716 | exec_prefix |
| 717 | PACKAGE_URL |
| 718 | PACKAGE_BUGREPORT |
| 719 | PACKAGE_STRING |
| 720 | PACKAGE_VERSION |
| 721 | PACKAGE_TARNAME |
| 722 | PACKAGE_NAME |
| 723 | PATH_SEPARATOR |
| 724 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 725 | ac_subst_files='' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 726 | ac_user_opts=' |
| 727 | enable_option_checking |
| 728 | enable_universalsdk |
| 729 | with_universal_archs |
| 730 | with_framework_name |
| 731 | enable_framework |
| 732 | with_gcc |
| 733 | with_cxx_main |
| 734 | with_suffix |
| 735 | enable_shared |
| 736 | enable_profiling |
| 737 | with_pydebug |
| 738 | enable_toolbox_glue |
| 739 | with_libs |
| 740 | with_system_expat |
| 741 | with_system_ffi |
| 742 | with_dbmliborder |
| 743 | with_signal_module |
| 744 | with_dec_threads |
| 745 | with_threads |
| 746 | with_thread |
| 747 | with_pth |
| 748 | enable_ipv6 |
| 749 | with_doc_strings |
| 750 | with_tsc |
| 751 | with_pymalloc |
| 752 | with_valgrind |
| 753 | with_wctype_functions |
| 754 | with_fpectl |
| 755 | with_libm |
| 756 | with_libc |
| 757 | enable_big_digits |
| 758 | enable_unicode |
| 759 | ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 760 | ac_precious_vars='build_alias |
| 761 | host_alias |
| 762 | target_alias |
| 763 | CC |
| 764 | CFLAGS |
| 765 | LDFLAGS |
| 766 | LIBS |
| 767 | CPPFLAGS |
| 768 | CPP' |
| 769 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 770 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 771 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 772 | ac_init_help= |
| 773 | ac_init_version=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 774 | ac_unrecognized_opts= |
| 775 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 776 | # The variables have the same names as the options, with |
| 777 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 778 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 779 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 780 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 781 | no_recursion= |
| 782 | prefix=NONE |
| 783 | program_prefix=NONE |
| 784 | program_suffix=NONE |
| 785 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 786 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 787 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 788 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 789 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 790 | x_includes=NONE |
| 791 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 792 | |
| 793 | # Installation directory options. |
| 794 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 795 | # and all the variables that are supposed to be based on exec_prefix |
| 796 | # by default will actually change. |
| 797 | # 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] | 798 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 799 | bindir='${exec_prefix}/bin' |
| 800 | sbindir='${exec_prefix}/sbin' |
| 801 | libexecdir='${exec_prefix}/libexec' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 802 | datarootdir='${prefix}/share' |
| 803 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 804 | sysconfdir='${prefix}/etc' |
| 805 | sharedstatedir='${prefix}/com' |
| 806 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 807 | includedir='${prefix}/include' |
| 808 | oldincludedir='/usr/include' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 809 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 810 | infodir='${datarootdir}/info' |
| 811 | htmldir='${docdir}' |
| 812 | dvidir='${docdir}' |
| 813 | pdfdir='${docdir}' |
| 814 | psdir='${docdir}' |
| 815 | libdir='${exec_prefix}/lib' |
| 816 | localedir='${datarootdir}/locale' |
| 817 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 818 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 819 | ac_prev= |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 820 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 821 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 822 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 823 | # If the previous option needs an argument, assign it. |
| 824 | if test -n "$ac_prev"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 825 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 826 | ac_prev= |
| 827 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 828 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 829 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 830 | case $ac_option in |
| 831 | *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 832 | *) ac_optarg=yes ;; |
| 833 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 834 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 835 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 836 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 837 | case $ac_dashdash$ac_option in |
| 838 | --) |
| 839 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 840 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 841 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 842 | ac_prev=bindir ;; |
| 843 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 844 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 845 | |
| 846 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 847 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 848 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 849 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 850 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 851 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 852 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 853 | ac_prev=cache_file ;; |
| 854 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 855 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 856 | cache_file=$ac_optarg ;; |
| 857 | |
| 858 | --config-cache | -C) |
| 859 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 860 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 861 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 862 | ac_prev=datadir ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 863 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 864 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 865 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 866 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 867 | | --dataroo | --dataro | --datar) |
| 868 | ac_prev=datarootdir ;; |
| 869 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 870 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 871 | datarootdir=$ac_optarg ;; |
| 872 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 873 | -disable-* | --disable-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 874 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 875 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 876 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 877 | as_fn_error "invalid feature name: $ac_useropt" |
| 878 | ac_useropt_orig=$ac_useropt |
| 879 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 880 | case $ac_user_opts in |
| 881 | *" |
| 882 | "enable_$ac_useropt" |
| 883 | "*) ;; |
| 884 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 885 | ac_unrecognized_sep=', ';; |
| 886 | esac |
| 887 | eval enable_$ac_useropt=no ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 888 | |
| 889 | -docdir | --docdir | --docdi | --doc | --do) |
| 890 | ac_prev=docdir ;; |
| 891 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 892 | docdir=$ac_optarg ;; |
| 893 | |
| 894 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 895 | ac_prev=dvidir ;; |
| 896 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 897 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 898 | |
| 899 | -enable-* | --enable-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 900 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 901 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 902 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 903 | as_fn_error "invalid feature name: $ac_useropt" |
| 904 | ac_useropt_orig=$ac_useropt |
| 905 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 906 | case $ac_user_opts in |
| 907 | *" |
| 908 | "enable_$ac_useropt" |
| 909 | "*) ;; |
| 910 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 911 | ac_unrecognized_sep=', ';; |
| 912 | esac |
| 913 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 914 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 915 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 916 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 917 | | --exec | --exe | --ex) |
| 918 | ac_prev=exec_prefix ;; |
| 919 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 920 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 921 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 922 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 923 | |
| 924 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 925 | # Obsolete; use --with-gas. |
| 926 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 927 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 928 | -help | --help | --hel | --he | -h) |
| 929 | ac_init_help=long ;; |
| 930 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 931 | ac_init_help=recursive ;; |
| 932 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 933 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 934 | |
| 935 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 936 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 937 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 938 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 939 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 940 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 941 | ac_prev=htmldir ;; |
| 942 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 943 | | --ht=*) |
| 944 | htmldir=$ac_optarg ;; |
| 945 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 946 | -includedir | --includedir | --includedi | --included | --include \ |
| 947 | | --includ | --inclu | --incl | --inc) |
| 948 | ac_prev=includedir ;; |
| 949 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 950 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 951 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 952 | |
| 953 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 954 | ac_prev=infodir ;; |
| 955 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 956 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 957 | |
| 958 | -libdir | --libdir | --libdi | --libd) |
| 959 | ac_prev=libdir ;; |
| 960 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 961 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 962 | |
| 963 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 964 | | --libexe | --libex | --libe) |
| 965 | ac_prev=libexecdir ;; |
| 966 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 967 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 968 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 969 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 970 | -localedir | --localedir | --localedi | --localed | --locale) |
| 971 | ac_prev=localedir ;; |
| 972 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 973 | localedir=$ac_optarg ;; |
| 974 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 975 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 976 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 977 | ac_prev=localstatedir ;; |
| 978 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 979 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 980 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 981 | |
| 982 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 983 | ac_prev=mandir ;; |
| 984 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 985 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 986 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 987 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 988 | # Obsolete; use --without-fp. |
| 989 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 990 | |
| 991 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 992 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 993 | no_create=yes ;; |
| 994 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 995 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 996 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 997 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 998 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 999 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 1000 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 1001 | | --oldin | --oldi | --old | --ol | --o) |
| 1002 | ac_prev=oldincludedir ;; |
| 1003 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1004 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1005 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1006 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1007 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1008 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1009 | ac_prev=prefix ;; |
| 1010 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1011 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1012 | |
| 1013 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1014 | | --program-pre | --program-pr | --program-p) |
| 1015 | ac_prev=program_prefix ;; |
| 1016 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1017 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1018 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1019 | |
| 1020 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1021 | | --program-suf | --program-su | --program-s) |
| 1022 | ac_prev=program_suffix ;; |
| 1023 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1024 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1025 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1026 | |
| 1027 | -program-transform-name | --program-transform-name \ |
| 1028 | | --program-transform-nam | --program-transform-na \ |
| 1029 | | --program-transform-n | --program-transform- \ |
| 1030 | | --program-transform | --program-transfor \ |
| 1031 | | --program-transfo | --program-transf \ |
| 1032 | | --program-trans | --program-tran \ |
| 1033 | | --progr-tra | --program-tr | --program-t) |
| 1034 | ac_prev=program_transform_name ;; |
| 1035 | -program-transform-name=* | --program-transform-name=* \ |
| 1036 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1037 | | --program-transform-n=* | --program-transform-=* \ |
| 1038 | | --program-transform=* | --program-transfor=* \ |
| 1039 | | --program-transfo=* | --program-transf=* \ |
| 1040 | | --program-trans=* | --program-tran=* \ |
| 1041 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1042 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1043 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1044 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1045 | ac_prev=pdfdir ;; |
| 1046 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1047 | pdfdir=$ac_optarg ;; |
| 1048 | |
| 1049 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1050 | ac_prev=psdir ;; |
| 1051 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1052 | psdir=$ac_optarg ;; |
| 1053 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1054 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1055 | | -silent | --silent | --silen | --sile | --sil) |
| 1056 | silent=yes ;; |
| 1057 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1058 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1059 | ac_prev=sbindir ;; |
| 1060 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1061 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1062 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1063 | |
| 1064 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1065 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1066 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1067 | | --sha | --sh) |
| 1068 | ac_prev=sharedstatedir ;; |
| 1069 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1070 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1071 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1072 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1073 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1074 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1075 | -site | --site | --sit) |
| 1076 | ac_prev=site ;; |
| 1077 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1078 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1079 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1080 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1081 | ac_prev=srcdir ;; |
| 1082 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1083 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1084 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1085 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1086 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1087 | ac_prev=sysconfdir ;; |
| 1088 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1089 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1090 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1091 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1092 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1093 | ac_prev=target_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1094 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1095 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1096 | |
| 1097 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1098 | verbose=yes ;; |
| 1099 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1100 | -version | --version | --versio | --versi | --vers | -V) |
| 1101 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1102 | |
| 1103 | -with-* | --with-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1104 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1105 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1106 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 1107 | as_fn_error "invalid package name: $ac_useropt" |
| 1108 | ac_useropt_orig=$ac_useropt |
| 1109 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1110 | case $ac_user_opts in |
| 1111 | *" |
| 1112 | "with_$ac_useropt" |
| 1113 | "*) ;; |
| 1114 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1115 | ac_unrecognized_sep=', ';; |
| 1116 | esac |
| 1117 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1118 | |
| 1119 | -without-* | --without-*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1120 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1121 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1122 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
| 1123 | as_fn_error "invalid package name: $ac_useropt" |
| 1124 | ac_useropt_orig=$ac_useropt |
| 1125 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1126 | case $ac_user_opts in |
| 1127 | *" |
| 1128 | "with_$ac_useropt" |
| 1129 | "*) ;; |
| 1130 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1131 | ac_unrecognized_sep=', ';; |
| 1132 | esac |
| 1133 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1134 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1135 | --x) |
| 1136 | # Obsolete; use --with-x. |
| 1137 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1138 | |
| 1139 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1140 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1141 | ac_prev=x_includes ;; |
| 1142 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1143 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1144 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1145 | |
| 1146 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1147 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1148 | ac_prev=x_libraries ;; |
| 1149 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1150 | | --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] | 1151 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1152 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1153 | -*) as_fn_error "unrecognized option: \`$ac_option' |
| 1154 | Try \`$0 --help' for more information." |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1155 | ;; |
| 1156 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1157 | *=*) |
| 1158 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1159 | # Reject names that are not valid shell variable names. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1160 | case $ac_envvar in #( |
| 1161 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
| 1162 | as_fn_error "invalid variable name: \`$ac_envvar'" ;; |
| 1163 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1164 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1165 | export $ac_envvar ;; |
| 1166 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1167 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1168 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1169 | $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] | 1170 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1171 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1172 | : ${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] | 1173 | ;; |
| 1174 | |
| 1175 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1176 | done |
| 1177 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1178 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1179 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1180 | as_fn_error "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1181 | fi |
| 1182 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1183 | if test -n "$ac_unrecognized_opts"; then |
| 1184 | case $enable_option_checking in |
| 1185 | no) ;; |
| 1186 | fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; |
| 1187 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1188 | esac |
| 1189 | fi |
| 1190 | |
| 1191 | # Check all directory arguments for consistency. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1192 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1193 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1194 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1195 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1196 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1197 | eval ac_val=\$$ac_var |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1198 | # Remove trailing slashes. |
| 1199 | case $ac_val in |
| 1200 | */ ) |
| 1201 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1202 | eval $ac_var=\$ac_val;; |
| 1203 | esac |
| 1204 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1205 | case $ac_val in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1206 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1207 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1208 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1209 | 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] | 1210 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1211 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1212 | # There might be people who depend on the old broken behavior: `$host' |
| 1213 | # used to hold the argument of --host etc. |
| 1214 | # FIXME: To remove some day. |
| 1215 | build=$build_alias |
| 1216 | host=$host_alias |
| 1217 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1218 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1219 | # FIXME: To remove some day. |
| 1220 | if test "x$host_alias" != x; then |
| 1221 | if test "x$build_alias" = x; then |
| 1222 | cross_compiling=maybe |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1223 | $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1224 | If a cross compiler is detected then cross compile mode will be used." >&2 |
| 1225 | elif test "x$build_alias" != "x$host_alias"; then |
| 1226 | cross_compiling=yes |
| 1227 | fi |
| 1228 | fi |
| 1229 | |
| 1230 | ac_tool_prefix= |
| 1231 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1232 | |
| 1233 | test "$silent" = yes && exec 6>/dev/null |
| 1234 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1235 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1236 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1237 | ac_ls_di=`ls -di .` && |
| 1238 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1239 | as_fn_error "working directory cannot be determined" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1240 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1241 | 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] | 1242 | |
| 1243 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1244 | # Find the source files, if location was not specified. |
| 1245 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1246 | ac_srcdir_defaulted=yes |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1247 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1248 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1249 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1250 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1251 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1252 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1253 | $as_echo X"$as_myself" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1254 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1255 | s//\1/ |
| 1256 | q |
| 1257 | } |
| 1258 | /^X\(\/\/\)[^/].*/{ |
| 1259 | s//\1/ |
| 1260 | q |
| 1261 | } |
| 1262 | /^X\(\/\/\)$/{ |
| 1263 | s//\1/ |
| 1264 | q |
| 1265 | } |
| 1266 | /^X\(\/\).*/{ |
| 1267 | s//\1/ |
| 1268 | q |
| 1269 | } |
| 1270 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1271 | srcdir=$ac_confdir |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1272 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1273 | srcdir=.. |
| 1274 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1275 | else |
| 1276 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1277 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1278 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1279 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1280 | as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 1281 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1282 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1283 | ac_abs_confdir=`( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1284 | 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] | 1285 | pwd)` |
| 1286 | # When building in place, set srcdir=. |
| 1287 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1288 | srcdir=. |
| 1289 | fi |
| 1290 | # Remove unnecessary trailing slashes from srcdir. |
| 1291 | # Double slashes in file names in object file debugging info |
| 1292 | # mess up M-x gdb in Emacs. |
| 1293 | case $srcdir in |
| 1294 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1295 | esac |
| 1296 | for ac_var in $ac_precious_vars; do |
| 1297 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1298 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1299 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1300 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1301 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1302 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1303 | # |
| 1304 | # Report the --help message. |
| 1305 | # |
| 1306 | if test "$ac_init_help" = "long"; then |
| 1307 | # Omit some internal or obsolete options to make the list less imposing. |
| 1308 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1309 | cat <<_ACEOF |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1310 | \`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] | 1311 | |
| 1312 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1313 | |
| 1314 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1315 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1316 | |
| 1317 | Defaults for the options are specified in brackets. |
| 1318 | |
| 1319 | Configuration: |
| 1320 | -h, --help display this help and exit |
| 1321 | --help=short display options specific to this package |
| 1322 | --help=recursive display the short help of all the included packages |
| 1323 | -V, --version display version information and exit |
| 1324 | -q, --quiet, --silent do not print \`checking...' messages |
| 1325 | --cache-file=FILE cache test results in FILE [disabled] |
| 1326 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1327 | -n, --no-create do not create output files |
| 1328 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1329 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1330 | Installation directories: |
| 1331 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1332 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1333 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1334 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1335 | |
| 1336 | By default, \`make install' will install all the files in |
| 1337 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1338 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1339 | for instance \`--prefix=\$HOME'. |
| 1340 | |
| 1341 | For better control, use the options below. |
| 1342 | |
| 1343 | Fine tuning of the installation directories: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1344 | --bindir=DIR user executables [EPREFIX/bin] |
| 1345 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1346 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1347 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1348 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1349 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1350 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1351 | --includedir=DIR C header files [PREFIX/include] |
| 1352 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1353 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1354 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1355 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1356 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1357 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1358 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1359 | --htmldir=DIR html documentation [DOCDIR] |
| 1360 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1361 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1362 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1363 | _ACEOF |
| 1364 | |
| 1365 | cat <<\_ACEOF |
| 1366 | _ACEOF |
| 1367 | fi |
| 1368 | |
| 1369 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1370 | case $ac_init_help in |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1371 | short | recursive ) echo "Configuration of python 2.7:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1372 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1373 | cat <<\_ACEOF |
| 1374 | |
| 1375 | Optional Features: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1376 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1377 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1378 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Brett Cannon | 91a1dec | 2008-02-13 19:15:44 +0000 | [diff] [blame] | 1379 | --enable-universalsdk[=SDKDIR] |
Brett Cannon | 9a8bb0e | 2008-02-03 02:07:55 +0000 | [diff] [blame] | 1380 | Build against Mac OS X 10.4u SDK (ppc/i386) |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1381 | --enable-framework[=INSTALLDIR] |
| 1382 | Build (MacOSX|Darwin) framework |
| 1383 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1384 | --enable-profiling enable C-level code profiling |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1385 | --enable-toolbox-glue disable/enable MacOSX glue code for extensions |
| 1386 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1387 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 1388 | --enable-big-digits[=BITS] |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1389 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1390 | --enable-unicode[=ucs[24]] |
Benjamin Peterson | 66556b0 | 2010-05-25 02:23:32 +0000 | [diff] [blame^] | 1391 | Enable Unicode strings (default is ucs2) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1392 | |
| 1393 | Optional Packages: |
| 1394 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1395 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 1396 | --with-universal-archs=ARCH |
| 1397 | select architectures for universal build ("32-bit", |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 1398 | "64-bit", "3-way", "intel" or "all") |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 1399 | --with-framework-name=FRAMEWORK |
| 1400 | specify an alternate name of the framework built |
| 1401 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1402 | --without-gcc never use gcc |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 1403 | --with-cxx-main=<compiler> |
| 1404 | compile main() and link python executable with C++ |
| 1405 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1406 | --with-suffix=.exe set executable suffix |
| 1407 | --with-pydebug build with Py_DEBUG defined |
| 1408 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | 2c19674 | 2009-12-31 03:17:18 +0000 | [diff] [blame] | 1409 | --with-system-expat build pyexpat module using an installed expat |
| 1410 | library |
Martin v. Löwis | 9176fc1 | 2006-04-11 11:12:43 +0000 | [diff] [blame] | 1411 | --with-system-ffi build _ctypes module using an installed ffi library |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 1412 | --with-dbmliborder=db1:db2:... |
| 1413 | order to check db backends for dbm. Valid value is a |
| 1414 | colon separated string with the backend names |
| 1415 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1416 | --with-signal-module disable/enable signal module |
| 1417 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries |
| 1418 | --with(out)-threads[=DIRECTORY] |
| 1419 | disable/enable thread support |
| 1420 | --with(out)-thread[=DIRECTORY] |
| 1421 | deprecated; use --with(out)-threads |
| 1422 | --with-pth use GNU pth threading libraries |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1423 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1424 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1425 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 1426 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1427 | --with-wctype-functions use wctype.h functions |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1428 | --with-fpectl enable SIGFPE catching |
| 1429 | --with-libm=STRING math library |
| 1430 | --with-libc=STRING C library |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1431 | |
| 1432 | Some influential environment variables: |
| 1433 | CC C compiler command |
| 1434 | CFLAGS C compiler flags |
| 1435 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1436 | nonstandard directory <lib dir> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1437 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1438 | 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] | 1439 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1440 | CPP C preprocessor |
| 1441 | |
| 1442 | Use these variables to override the choices made by `configure' or to help |
| 1443 | it to find libraries and programs with nonstandard names/locations. |
| 1444 | |
Georg Brandl | 464432d | 2009-05-20 18:24:08 +0000 | [diff] [blame] | 1445 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1446 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1447 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1448 | fi |
| 1449 | |
| 1450 | if test "$ac_init_help" = "recursive"; then |
| 1451 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1452 | 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] | 1453 | test -d "$ac_dir" || |
| 1454 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1455 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1456 | ac_builddir=. |
| 1457 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1458 | case "$ac_dir" in |
| 1459 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1460 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1461 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1462 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1463 | 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] | 1464 | case $ac_top_builddir_sub in |
| 1465 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1466 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1467 | esac ;; |
| 1468 | esac |
| 1469 | ac_abs_top_builddir=$ac_pwd |
| 1470 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1471 | # for backward compatibility: |
| 1472 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1473 | |
| 1474 | case $srcdir in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1475 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1476 | ac_srcdir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1477 | ac_top_srcdir=$ac_top_builddir_sub |
| 1478 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1479 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1480 | ac_srcdir=$srcdir$ac_dir_suffix; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1481 | ac_top_srcdir=$srcdir |
| 1482 | ac_abs_top_srcdir=$srcdir ;; |
| 1483 | *) # Relative name. |
| 1484 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1485 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1486 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1487 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1488 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1489 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1490 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1491 | # Check for guested configure. |
| 1492 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1493 | echo && |
| 1494 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1495 | elif test -f "$ac_srcdir/configure"; then |
| 1496 | echo && |
| 1497 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1498 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1499 | $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] | 1500 | fi || ac_status=$? |
| 1501 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1502 | done |
| 1503 | fi |
| 1504 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1505 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1506 | if $ac_init_version; then |
| 1507 | cat <<\_ACEOF |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 1508 | python configure 2.7 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1509 | generated by GNU Autoconf 2.65 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1510 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1511 | Copyright (C) 2009 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1512 | This configure script is free software; the Free Software Foundation |
| 1513 | gives unlimited permission to copy, distribute and modify it. |
| 1514 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 1515 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1516 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1517 | |
| 1518 | ## ------------------------ ## |
| 1519 | ## Autoconf initialization. ## |
| 1520 | ## ------------------------ ## |
| 1521 | |
| 1522 | # ac_fn_c_try_compile LINENO |
| 1523 | # -------------------------- |
| 1524 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1525 | ac_fn_c_try_compile () |
| 1526 | { |
| 1527 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1528 | rm -f conftest.$ac_objext |
| 1529 | if { { ac_try="$ac_compile" |
| 1530 | case "(($ac_try" in |
| 1531 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1532 | *) ac_try_echo=$ac_try;; |
| 1533 | esac |
| 1534 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1535 | $as_echo "$ac_try_echo"; } >&5 |
| 1536 | (eval "$ac_compile") 2>conftest.err |
| 1537 | ac_status=$? |
| 1538 | if test -s conftest.err; then |
| 1539 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1540 | cat conftest.er1 >&5 |
| 1541 | mv -f conftest.er1 conftest.err |
| 1542 | fi |
| 1543 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1544 | test $ac_status = 0; } && { |
| 1545 | test -z "$ac_c_werror_flag" || |
| 1546 | test ! -s conftest.err |
| 1547 | } && test -s conftest.$ac_objext; then : |
| 1548 | ac_retval=0 |
| 1549 | else |
| 1550 | $as_echo "$as_me: failed program was:" >&5 |
| 1551 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1552 | |
| 1553 | ac_retval=1 |
| 1554 | fi |
| 1555 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1556 | as_fn_set_status $ac_retval |
| 1557 | |
| 1558 | } # ac_fn_c_try_compile |
| 1559 | |
| 1560 | # ac_fn_c_try_cpp LINENO |
| 1561 | # ---------------------- |
| 1562 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1563 | ac_fn_c_try_cpp () |
| 1564 | { |
| 1565 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1566 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1567 | case "(($ac_try" in |
| 1568 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1569 | *) ac_try_echo=$ac_try;; |
| 1570 | esac |
| 1571 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1572 | $as_echo "$ac_try_echo"; } >&5 |
| 1573 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1574 | ac_status=$? |
| 1575 | if test -s conftest.err; then |
| 1576 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1577 | cat conftest.er1 >&5 |
| 1578 | mv -f conftest.er1 conftest.err |
| 1579 | fi |
| 1580 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1581 | test $ac_status = 0; } >/dev/null && { |
| 1582 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1583 | test ! -s conftest.err |
| 1584 | }; then : |
| 1585 | ac_retval=0 |
| 1586 | else |
| 1587 | $as_echo "$as_me: failed program was:" >&5 |
| 1588 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1589 | |
| 1590 | ac_retval=1 |
| 1591 | fi |
| 1592 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1593 | as_fn_set_status $ac_retval |
| 1594 | |
| 1595 | } # ac_fn_c_try_cpp |
| 1596 | |
| 1597 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1598 | # ------------------------------------------------------- |
| 1599 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1600 | # the include files in INCLUDES and setting the cache variable VAR |
| 1601 | # accordingly. |
| 1602 | ac_fn_c_check_header_mongrel () |
| 1603 | { |
| 1604 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1605 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1606 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1607 | $as_echo_n "checking for $2... " >&6; } |
| 1608 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1609 | $as_echo_n "(cached) " >&6 |
| 1610 | fi |
| 1611 | eval ac_res=\$$3 |
| 1612 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1613 | $as_echo "$ac_res" >&6; } |
| 1614 | else |
| 1615 | # Is the header compilable? |
| 1616 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1617 | $as_echo_n "checking $2 usability... " >&6; } |
| 1618 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1619 | /* end confdefs.h. */ |
| 1620 | $4 |
| 1621 | #include <$2> |
| 1622 | _ACEOF |
| 1623 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1624 | ac_header_compiler=yes |
| 1625 | else |
| 1626 | ac_header_compiler=no |
| 1627 | fi |
| 1628 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1630 | $as_echo "$ac_header_compiler" >&6; } |
| 1631 | |
| 1632 | # Is the header present? |
| 1633 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1634 | $as_echo_n "checking $2 presence... " >&6; } |
| 1635 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1636 | /* end confdefs.h. */ |
| 1637 | #include <$2> |
| 1638 | _ACEOF |
| 1639 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1640 | ac_header_preproc=yes |
| 1641 | else |
| 1642 | ac_header_preproc=no |
| 1643 | fi |
| 1644 | rm -f conftest.err conftest.$ac_ext |
| 1645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1646 | $as_echo "$ac_header_preproc" >&6; } |
| 1647 | |
| 1648 | # So? What about this header? |
| 1649 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1650 | yes:no: ) |
| 1651 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1652 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1653 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1654 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1655 | ;; |
| 1656 | no:yes:* ) |
| 1657 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1658 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1659 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1660 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1661 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1662 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1663 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1664 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1665 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1666 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1667 | ( cat <<\_ASBOX |
| 1668 | ## -------------------------------------- ## |
| 1669 | ## Report this to http://bugs.python.org/ ## |
| 1670 | ## -------------------------------------- ## |
| 1671 | _ASBOX |
| 1672 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1673 | ;; |
| 1674 | esac |
| 1675 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1676 | $as_echo_n "checking for $2... " >&6; } |
| 1677 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1678 | $as_echo_n "(cached) " >&6 |
| 1679 | else |
| 1680 | eval "$3=\$ac_header_compiler" |
| 1681 | fi |
| 1682 | eval ac_res=\$$3 |
| 1683 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1684 | $as_echo "$ac_res" >&6; } |
| 1685 | fi |
| 1686 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1687 | |
| 1688 | } # ac_fn_c_check_header_mongrel |
| 1689 | |
| 1690 | # ac_fn_c_try_run LINENO |
| 1691 | # ---------------------- |
| 1692 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1693 | # that executables *can* be run. |
| 1694 | ac_fn_c_try_run () |
| 1695 | { |
| 1696 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1697 | if { { ac_try="$ac_link" |
| 1698 | case "(($ac_try" in |
| 1699 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1700 | *) ac_try_echo=$ac_try;; |
| 1701 | esac |
| 1702 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1703 | $as_echo "$ac_try_echo"; } >&5 |
| 1704 | (eval "$ac_link") 2>&5 |
| 1705 | ac_status=$? |
| 1706 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1707 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1708 | { { case "(($ac_try" in |
| 1709 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1710 | *) ac_try_echo=$ac_try;; |
| 1711 | esac |
| 1712 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1713 | $as_echo "$ac_try_echo"; } >&5 |
| 1714 | (eval "$ac_try") 2>&5 |
| 1715 | ac_status=$? |
| 1716 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1717 | test $ac_status = 0; }; }; then : |
| 1718 | ac_retval=0 |
| 1719 | else |
| 1720 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1721 | $as_echo "$as_me: failed program was:" >&5 |
| 1722 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1723 | |
| 1724 | ac_retval=$ac_status |
| 1725 | fi |
| 1726 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1727 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1728 | as_fn_set_status $ac_retval |
| 1729 | |
| 1730 | } # ac_fn_c_try_run |
| 1731 | |
| 1732 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1733 | # ------------------------------------------------------- |
| 1734 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1735 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1736 | ac_fn_c_check_header_compile () |
| 1737 | { |
| 1738 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1739 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1740 | $as_echo_n "checking for $2... " >&6; } |
| 1741 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1742 | $as_echo_n "(cached) " >&6 |
| 1743 | else |
| 1744 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1745 | /* end confdefs.h. */ |
| 1746 | $4 |
| 1747 | #include <$2> |
| 1748 | _ACEOF |
| 1749 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1750 | eval "$3=yes" |
| 1751 | else |
| 1752 | eval "$3=no" |
| 1753 | fi |
| 1754 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1755 | fi |
| 1756 | eval ac_res=\$$3 |
| 1757 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1758 | $as_echo "$ac_res" >&6; } |
| 1759 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1760 | |
| 1761 | } # ac_fn_c_check_header_compile |
| 1762 | |
| 1763 | # ac_fn_c_try_link LINENO |
| 1764 | # ----------------------- |
| 1765 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1766 | ac_fn_c_try_link () |
| 1767 | { |
| 1768 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1769 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1770 | if { { ac_try="$ac_link" |
| 1771 | case "(($ac_try" in |
| 1772 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1773 | *) ac_try_echo=$ac_try;; |
| 1774 | esac |
| 1775 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1776 | $as_echo "$ac_try_echo"; } >&5 |
| 1777 | (eval "$ac_link") 2>conftest.err |
| 1778 | ac_status=$? |
| 1779 | if test -s conftest.err; then |
| 1780 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1781 | cat conftest.er1 >&5 |
| 1782 | mv -f conftest.er1 conftest.err |
| 1783 | fi |
| 1784 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1785 | test $ac_status = 0; } && { |
| 1786 | test -z "$ac_c_werror_flag" || |
| 1787 | test ! -s conftest.err |
| 1788 | } && test -s conftest$ac_exeext && { |
| 1789 | test "$cross_compiling" = yes || |
| 1790 | $as_test_x conftest$ac_exeext |
| 1791 | }; then : |
| 1792 | ac_retval=0 |
| 1793 | else |
| 1794 | $as_echo "$as_me: failed program was:" >&5 |
| 1795 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1796 | |
| 1797 | ac_retval=1 |
| 1798 | fi |
| 1799 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1800 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1801 | # interfere with the next link command; also delete a directory that is |
| 1802 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1803 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1804 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1805 | as_fn_set_status $ac_retval |
| 1806 | |
| 1807 | } # ac_fn_c_try_link |
| 1808 | |
| 1809 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1810 | # ------------------------------------------- |
| 1811 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1812 | # variable VAR accordingly. |
| 1813 | ac_fn_c_check_type () |
| 1814 | { |
| 1815 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1816 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1817 | $as_echo_n "checking for $2... " >&6; } |
| 1818 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1819 | $as_echo_n "(cached) " >&6 |
| 1820 | else |
| 1821 | eval "$3=no" |
| 1822 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1823 | /* end confdefs.h. */ |
| 1824 | $4 |
| 1825 | int |
| 1826 | main () |
| 1827 | { |
| 1828 | if (sizeof ($2)) |
| 1829 | return 0; |
| 1830 | ; |
| 1831 | return 0; |
| 1832 | } |
| 1833 | _ACEOF |
| 1834 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1835 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1836 | /* end confdefs.h. */ |
| 1837 | $4 |
| 1838 | int |
| 1839 | main () |
| 1840 | { |
| 1841 | if (sizeof (($2))) |
| 1842 | return 0; |
| 1843 | ; |
| 1844 | return 0; |
| 1845 | } |
| 1846 | _ACEOF |
| 1847 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1848 | |
| 1849 | else |
| 1850 | eval "$3=yes" |
| 1851 | fi |
| 1852 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1853 | fi |
| 1854 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1855 | fi |
| 1856 | eval ac_res=\$$3 |
| 1857 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1858 | $as_echo "$ac_res" >&6; } |
| 1859 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1860 | |
| 1861 | } # ac_fn_c_check_type |
| 1862 | |
| 1863 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1864 | # ------------------------------------ |
| 1865 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1866 | # accordingly. |
| 1867 | ac_fn_c_find_uintX_t () |
| 1868 | { |
| 1869 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1870 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1871 | $as_echo_n "checking for uint$2_t... " >&6; } |
| 1872 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1873 | $as_echo_n "(cached) " >&6 |
| 1874 | else |
| 1875 | eval "$3=no" |
| 1876 | # Order is important - never check a type that is potentially smaller |
| 1877 | # than half of the expected target width. |
| 1878 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1879 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1880 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1881 | /* end confdefs.h. */ |
| 1882 | $ac_includes_default |
| 1883 | int |
| 1884 | main () |
| 1885 | { |
| 1886 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
| 1887 | test_array [0] = 0 |
| 1888 | |
| 1889 | ; |
| 1890 | return 0; |
| 1891 | } |
| 1892 | _ACEOF |
| 1893 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1894 | case $ac_type in #( |
| 1895 | uint$2_t) : |
| 1896 | eval "$3=yes" ;; #( |
| 1897 | *) : |
| 1898 | eval "$3=\$ac_type" ;; |
| 1899 | esac |
| 1900 | fi |
| 1901 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1902 | eval as_val=\$$3 |
| 1903 | if test "x$as_val" = x""no; then : |
| 1904 | |
| 1905 | else |
| 1906 | break |
| 1907 | fi |
| 1908 | done |
| 1909 | fi |
| 1910 | eval ac_res=\$$3 |
| 1911 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1912 | $as_echo "$ac_res" >&6; } |
| 1913 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1914 | |
| 1915 | } # ac_fn_c_find_uintX_t |
| 1916 | |
| 1917 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 1918 | # ----------------------------------- |
| 1919 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 1920 | # accordingly. |
| 1921 | ac_fn_c_find_intX_t () |
| 1922 | { |
| 1923 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1924 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 1925 | $as_echo_n "checking for int$2_t... " >&6; } |
| 1926 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 1927 | $as_echo_n "(cached) " >&6 |
| 1928 | else |
| 1929 | eval "$3=no" |
| 1930 | # Order is important - never check a type that is potentially smaller |
| 1931 | # than half of the expected target width. |
| 1932 | for ac_type in int$2_t 'int' 'long int' \ |
| 1933 | 'long long int' 'short int' 'signed char'; do |
| 1934 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1935 | /* end confdefs.h. */ |
| 1936 | $ac_includes_default |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1937 | int |
| 1938 | main () |
| 1939 | { |
Benjamin Peterson | 66556b0 | 2010-05-25 02:23:32 +0000 | [diff] [blame^] | 1940 | static int test_array [1 - 2 * !(enum { N = $2 / 2 - 1 }; |
| 1941 | 0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1942 | test_array [0] = 0 |
| 1943 | |
| 1944 | ; |
| 1945 | return 0; |
| 1946 | } |
| 1947 | _ACEOF |
| 1948 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1949 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1950 | /* end confdefs.h. */ |
| 1951 | $ac_includes_default |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1952 | int |
| 1953 | main () |
| 1954 | { |
Benjamin Peterson | 66556b0 | 2010-05-25 02:23:32 +0000 | [diff] [blame^] | 1955 | static int test_array [1 - 2 * !(enum { N = $2 / 2 - 1 }; |
| 1956 | ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 1957 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
| 1958 | test_array [0] = 0 |
| 1959 | |
| 1960 | ; |
| 1961 | return 0; |
| 1962 | } |
| 1963 | _ACEOF |
| 1964 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1965 | |
| 1966 | else |
| 1967 | case $ac_type in #( |
| 1968 | int$2_t) : |
| 1969 | eval "$3=yes" ;; #( |
| 1970 | *) : |
| 1971 | eval "$3=\$ac_type" ;; |
| 1972 | esac |
| 1973 | fi |
| 1974 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1975 | fi |
| 1976 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1977 | eval as_val=\$$3 |
| 1978 | if test "x$as_val" = x""no; then : |
| 1979 | |
| 1980 | else |
| 1981 | break |
| 1982 | fi |
| 1983 | done |
| 1984 | fi |
| 1985 | eval ac_res=\$$3 |
| 1986 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1987 | $as_echo "$ac_res" >&6; } |
| 1988 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1989 | |
| 1990 | } # ac_fn_c_find_intX_t |
| 1991 | |
| 1992 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 1993 | # -------------------------------------------- |
| 1994 | # Tries to find the compile-time value of EXPR in a program that includes |
| 1995 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 1996 | # computed |
| 1997 | ac_fn_c_compute_int () |
| 1998 | { |
| 1999 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2000 | if test "$cross_compiling" = yes; then |
| 2001 | # Depending upon the size, compute the lo and hi bounds. |
| 2002 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2003 | /* end confdefs.h. */ |
| 2004 | $4 |
| 2005 | int |
| 2006 | main () |
| 2007 | { |
| 2008 | static int test_array [1 - 2 * !(($2) >= 0)]; |
| 2009 | test_array [0] = 0 |
| 2010 | |
| 2011 | ; |
| 2012 | return 0; |
| 2013 | } |
| 2014 | _ACEOF |
| 2015 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2016 | ac_lo=0 ac_mid=0 |
| 2017 | while :; do |
| 2018 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2019 | /* end confdefs.h. */ |
| 2020 | $4 |
| 2021 | int |
| 2022 | main () |
| 2023 | { |
| 2024 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2025 | test_array [0] = 0 |
| 2026 | |
| 2027 | ; |
| 2028 | return 0; |
| 2029 | } |
| 2030 | _ACEOF |
| 2031 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2032 | ac_hi=$ac_mid; break |
| 2033 | else |
| 2034 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2035 | if test $ac_lo -le $ac_mid; then |
| 2036 | ac_lo= ac_hi= |
| 2037 | break |
| 2038 | fi |
| 2039 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2040 | fi |
| 2041 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2042 | done |
| 2043 | else |
| 2044 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2045 | /* end confdefs.h. */ |
| 2046 | $4 |
| 2047 | int |
| 2048 | main () |
| 2049 | { |
| 2050 | static int test_array [1 - 2 * !(($2) < 0)]; |
| 2051 | test_array [0] = 0 |
| 2052 | |
| 2053 | ; |
| 2054 | return 0; |
| 2055 | } |
| 2056 | _ACEOF |
| 2057 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2058 | ac_hi=-1 ac_mid=-1 |
| 2059 | while :; do |
| 2060 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2061 | /* end confdefs.h. */ |
| 2062 | $4 |
| 2063 | int |
| 2064 | main () |
| 2065 | { |
| 2066 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
| 2067 | test_array [0] = 0 |
| 2068 | |
| 2069 | ; |
| 2070 | return 0; |
| 2071 | } |
| 2072 | _ACEOF |
| 2073 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2074 | ac_lo=$ac_mid; break |
| 2075 | else |
| 2076 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2077 | if test $ac_mid -le $ac_hi; then |
| 2078 | ac_lo= ac_hi= |
| 2079 | break |
| 2080 | fi |
| 2081 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2082 | fi |
| 2083 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2084 | done |
| 2085 | else |
| 2086 | ac_lo= ac_hi= |
| 2087 | fi |
| 2088 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2089 | fi |
| 2090 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2091 | # Binary search between lo and hi bounds. |
| 2092 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2093 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2094 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2095 | /* end confdefs.h. */ |
| 2096 | $4 |
| 2097 | int |
| 2098 | main () |
| 2099 | { |
| 2100 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2101 | test_array [0] = 0 |
| 2102 | |
| 2103 | ; |
| 2104 | return 0; |
| 2105 | } |
| 2106 | _ACEOF |
| 2107 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2108 | ac_hi=$ac_mid |
| 2109 | else |
| 2110 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2111 | fi |
| 2112 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2113 | done |
| 2114 | case $ac_lo in #(( |
| 2115 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2116 | '') ac_retval=1 ;; |
| 2117 | esac |
| 2118 | else |
| 2119 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2120 | /* end confdefs.h. */ |
| 2121 | $4 |
| 2122 | static long int longval () { return $2; } |
| 2123 | static unsigned long int ulongval () { return $2; } |
| 2124 | #include <stdio.h> |
| 2125 | #include <stdlib.h> |
| 2126 | int |
| 2127 | main () |
| 2128 | { |
| 2129 | |
| 2130 | FILE *f = fopen ("conftest.val", "w"); |
| 2131 | if (! f) |
| 2132 | return 1; |
| 2133 | if (($2) < 0) |
| 2134 | { |
| 2135 | long int i = longval (); |
| 2136 | if (i != ($2)) |
| 2137 | return 1; |
| 2138 | fprintf (f, "%ld", i); |
| 2139 | } |
| 2140 | else |
| 2141 | { |
| 2142 | unsigned long int i = ulongval (); |
| 2143 | if (i != ($2)) |
| 2144 | return 1; |
| 2145 | fprintf (f, "%lu", i); |
| 2146 | } |
| 2147 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2148 | on some platforms. */ |
| 2149 | return ferror (f) || fclose (f) != 0; |
| 2150 | |
| 2151 | ; |
| 2152 | return 0; |
| 2153 | } |
| 2154 | _ACEOF |
| 2155 | if ac_fn_c_try_run "$LINENO"; then : |
| 2156 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2157 | else |
| 2158 | ac_retval=1 |
| 2159 | fi |
| 2160 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2161 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2162 | rm -f conftest.val |
| 2163 | |
| 2164 | fi |
| 2165 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2166 | as_fn_set_status $ac_retval |
| 2167 | |
| 2168 | } # ac_fn_c_compute_int |
| 2169 | |
| 2170 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2171 | # ---------------------------------- |
| 2172 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2173 | ac_fn_c_check_func () |
| 2174 | { |
| 2175 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2177 | $as_echo_n "checking for $2... " >&6; } |
| 2178 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 2179 | $as_echo_n "(cached) " >&6 |
| 2180 | else |
| 2181 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2182 | /* end confdefs.h. */ |
| 2183 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2184 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2185 | #define $2 innocuous_$2 |
| 2186 | |
| 2187 | /* System header to define __stub macros and hopefully few prototypes, |
| 2188 | which can conflict with char $2 (); below. |
| 2189 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2190 | <limits.h> exists even on freestanding compilers. */ |
| 2191 | |
| 2192 | #ifdef __STDC__ |
| 2193 | # include <limits.h> |
| 2194 | #else |
| 2195 | # include <assert.h> |
| 2196 | #endif |
| 2197 | |
| 2198 | #undef $2 |
| 2199 | |
| 2200 | /* Override any GCC internal prototype to avoid an error. |
| 2201 | Use char because int might match the return type of a GCC |
| 2202 | builtin and then its argument prototype would still apply. */ |
| 2203 | #ifdef __cplusplus |
| 2204 | extern "C" |
| 2205 | #endif |
| 2206 | char $2 (); |
| 2207 | /* The GNU C library defines this for functions which it implements |
| 2208 | to always fail with ENOSYS. Some functions are actually named |
| 2209 | something starting with __ and the normal name is an alias. */ |
| 2210 | #if defined __stub_$2 || defined __stub___$2 |
| 2211 | choke me |
| 2212 | #endif |
| 2213 | |
| 2214 | int |
| 2215 | main () |
| 2216 | { |
| 2217 | return $2 (); |
| 2218 | ; |
| 2219 | return 0; |
| 2220 | } |
| 2221 | _ACEOF |
| 2222 | if ac_fn_c_try_link "$LINENO"; then : |
| 2223 | eval "$3=yes" |
| 2224 | else |
| 2225 | eval "$3=no" |
| 2226 | fi |
| 2227 | rm -f core conftest.err conftest.$ac_objext \ |
| 2228 | conftest$ac_exeext conftest.$ac_ext |
| 2229 | fi |
| 2230 | eval ac_res=\$$3 |
| 2231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2232 | $as_echo "$ac_res" >&6; } |
| 2233 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2234 | |
| 2235 | } # ac_fn_c_check_func |
| 2236 | |
| 2237 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2238 | # ---------------------------------------------------- |
| 2239 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2240 | # INCLUDES, setting cache variable VAR accordingly. |
| 2241 | ac_fn_c_check_member () |
| 2242 | { |
| 2243 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2244 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2245 | $as_echo_n "checking for $2.$3... " >&6; } |
| 2246 | if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 2247 | $as_echo_n "(cached) " >&6 |
| 2248 | else |
| 2249 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2250 | /* end confdefs.h. */ |
| 2251 | $5 |
| 2252 | int |
| 2253 | main () |
| 2254 | { |
| 2255 | static $2 ac_aggr; |
| 2256 | if (ac_aggr.$3) |
| 2257 | return 0; |
| 2258 | ; |
| 2259 | return 0; |
| 2260 | } |
| 2261 | _ACEOF |
| 2262 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2263 | eval "$4=yes" |
| 2264 | else |
| 2265 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2266 | /* end confdefs.h. */ |
| 2267 | $5 |
| 2268 | int |
| 2269 | main () |
| 2270 | { |
| 2271 | static $2 ac_aggr; |
| 2272 | if (sizeof ac_aggr.$3) |
| 2273 | return 0; |
| 2274 | ; |
| 2275 | return 0; |
| 2276 | } |
| 2277 | _ACEOF |
| 2278 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2279 | eval "$4=yes" |
| 2280 | else |
| 2281 | eval "$4=no" |
| 2282 | fi |
| 2283 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2284 | fi |
| 2285 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2286 | fi |
| 2287 | eval ac_res=\$$4 |
| 2288 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2289 | $as_echo "$ac_res" >&6; } |
| 2290 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2291 | |
| 2292 | } # ac_fn_c_check_member |
| 2293 | |
| 2294 | # ac_fn_c_check_decl LINENO SYMBOL VAR |
| 2295 | # ------------------------------------ |
| 2296 | # Tests whether SYMBOL is declared, setting cache variable VAR accordingly. |
| 2297 | ac_fn_c_check_decl () |
| 2298 | { |
| 2299 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2300 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5 |
| 2301 | $as_echo_n "checking whether $2 is declared... " >&6; } |
| 2302 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 2303 | $as_echo_n "(cached) " >&6 |
| 2304 | else |
| 2305 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2306 | /* end confdefs.h. */ |
| 2307 | $4 |
| 2308 | int |
| 2309 | main () |
| 2310 | { |
| 2311 | #ifndef $2 |
| 2312 | (void) $2; |
| 2313 | #endif |
| 2314 | |
| 2315 | ; |
| 2316 | return 0; |
| 2317 | } |
| 2318 | _ACEOF |
| 2319 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2320 | eval "$3=yes" |
| 2321 | else |
| 2322 | eval "$3=no" |
| 2323 | fi |
| 2324 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2325 | fi |
| 2326 | eval ac_res=\$$3 |
| 2327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2328 | $as_echo "$ac_res" >&6; } |
| 2329 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2330 | |
| 2331 | } # ac_fn_c_check_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2332 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2333 | This file contains any messages produced by compilers while |
| 2334 | running configure, to aid debugging if configure makes a mistake. |
| 2335 | |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 2336 | It was created by python $as_me 2.7, which was |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2337 | generated by GNU Autoconf 2.65. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2338 | |
| 2339 | $ $0 $@ |
| 2340 | |
| 2341 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2342 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2343 | { |
| 2344 | cat <<_ASUNAME |
| 2345 | ## --------- ## |
| 2346 | ## Platform. ## |
| 2347 | ## --------- ## |
| 2348 | |
| 2349 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2350 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2351 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2352 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2353 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2354 | |
| 2355 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2356 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2357 | |
| 2358 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2359 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2360 | /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] | 2361 | /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] | 2362 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2363 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2364 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2365 | |
| 2366 | _ASUNAME |
| 2367 | |
| 2368 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2369 | for as_dir in $PATH |
| 2370 | do |
| 2371 | IFS=$as_save_IFS |
| 2372 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2373 | $as_echo "PATH: $as_dir" |
| 2374 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2375 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2376 | |
| 2377 | } >&5 |
| 2378 | |
| 2379 | cat >&5 <<_ACEOF |
| 2380 | |
| 2381 | |
| 2382 | ## ----------- ## |
| 2383 | ## Core tests. ## |
| 2384 | ## ----------- ## |
| 2385 | |
| 2386 | _ACEOF |
| 2387 | |
| 2388 | |
| 2389 | # Keep a trace of the command line. |
| 2390 | # 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] | 2391 | # 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] | 2392 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2393 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2394 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2395 | ac_configure_args0= |
| 2396 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2397 | ac_must_keep_next=false |
| 2398 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2399 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2400 | for ac_arg |
| 2401 | do |
| 2402 | case $ac_arg in |
| 2403 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2404 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2405 | | -silent | --silent | --silen | --sile | --sil) |
| 2406 | continue ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2407 | *\'*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2408 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2409 | esac |
| 2410 | case $ac_pass in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2411 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2412 | 2) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2413 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2414 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2415 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2416 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2417 | case $ac_arg in |
| 2418 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2419 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2420 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2421 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2422 | case "$ac_configure_args0 " in |
| 2423 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2424 | esac |
| 2425 | ;; |
| 2426 | -* ) ac_must_keep_next=true ;; |
| 2427 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2428 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2429 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2430 | ;; |
| 2431 | esac |
| 2432 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2433 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2434 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2435 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2436 | |
| 2437 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2438 | # config.log. We remove comments because anyway the quotes in there |
| 2439 | # would cause problems or look ugly. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2440 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2441 | # 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] | 2442 | trap 'exit_status=$? |
| 2443 | # Save into config.log some information that might help in debugging. |
| 2444 | { |
| 2445 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2446 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2447 | cat <<\_ASBOX |
| 2448 | ## ---------------- ## |
| 2449 | ## Cache variables. ## |
| 2450 | ## ---------------- ## |
| 2451 | _ASBOX |
| 2452 | echo |
| 2453 | # 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] | 2454 | ( |
| 2455 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2456 | eval ac_val=\$$ac_var |
| 2457 | case $ac_val in #( |
| 2458 | *${as_nl}*) |
| 2459 | case $ac_var in #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2460 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2461 | $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] | 2462 | esac |
| 2463 | case $ac_var in #( |
| 2464 | _ | IFS | as_nl) ;; #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2465 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2466 | *) { eval $ac_var=; unset $ac_var;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2467 | esac ;; |
| 2468 | esac |
| 2469 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2470 | (set) 2>&1 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2471 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2472 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2473 | sed -n \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2474 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2475 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2476 | ;; #( |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 2477 | *) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2478 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 2479 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2480 | esac | |
| 2481 | sort |
| 2482 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2483 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2484 | |
| 2485 | cat <<\_ASBOX |
| 2486 | ## ----------------- ## |
| 2487 | ## Output variables. ## |
| 2488 | ## ----------------- ## |
| 2489 | _ASBOX |
| 2490 | echo |
| 2491 | for ac_var in $ac_subst_vars |
| 2492 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2493 | eval ac_val=\$$ac_var |
| 2494 | case $ac_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2495 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2496 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2497 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2498 | done | sort |
| 2499 | echo |
| 2500 | |
| 2501 | if test -n "$ac_subst_files"; then |
| 2502 | cat <<\_ASBOX |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2503 | ## ------------------- ## |
| 2504 | ## File substitutions. ## |
| 2505 | ## ------------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2506 | _ASBOX |
| 2507 | echo |
| 2508 | for ac_var in $ac_subst_files |
| 2509 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2510 | eval ac_val=\$$ac_var |
| 2511 | case $ac_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2512 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2513 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2514 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2515 | done | sort |
| 2516 | echo |
| 2517 | fi |
| 2518 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2519 | if test -s confdefs.h; then |
| 2520 | cat <<\_ASBOX |
| 2521 | ## ----------- ## |
| 2522 | ## confdefs.h. ## |
| 2523 | ## ----------- ## |
| 2524 | _ASBOX |
| 2525 | echo |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2526 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2527 | echo |
| 2528 | fi |
| 2529 | test "$ac_signal" != 0 && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2530 | $as_echo "$as_me: caught signal $ac_signal" |
| 2531 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2532 | } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2533 | rm -f core *.core core.conftest.* && |
| 2534 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2535 | exit $exit_status |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2536 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2537 | for ac_signal in 1 2 13 15; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2538 | 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] | 2539 | done |
| 2540 | ac_signal=0 |
| 2541 | |
| 2542 | # 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] | 2543 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2544 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2545 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2546 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2547 | # Predefined preprocessor variables. |
| 2548 | |
| 2549 | cat >>confdefs.h <<_ACEOF |
| 2550 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2551 | _ACEOF |
| 2552 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2553 | cat >>confdefs.h <<_ACEOF |
| 2554 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 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_VERSION "$PACKAGE_VERSION" |
| 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_STRING "$PACKAGE_STRING" |
| 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_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2567 | _ACEOF |
| 2568 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2569 | cat >>confdefs.h <<_ACEOF |
| 2570 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2571 | _ACEOF |
| 2572 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2573 | |
| 2574 | # 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] | 2575 | # Prefer an explicitly selected file to automatically selected ones. |
| 2576 | ac_site_file1=NONE |
| 2577 | ac_site_file2=NONE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2578 | if test -n "$CONFIG_SITE"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2579 | ac_site_file1=$CONFIG_SITE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2580 | elif test "x$prefix" != xNONE; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2581 | ac_site_file1=$prefix/share/config.site |
| 2582 | ac_site_file2=$prefix/etc/config.site |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2583 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2584 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2585 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2586 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2587 | 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] | 2588 | do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2589 | test "x$ac_site_file" = xNONE && continue |
| 2590 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2591 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2592 | $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] | 2593 | sed 's/^/| /' "$ac_site_file" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2594 | . "$ac_site_file" |
| 2595 | fi |
| 2596 | done |
| 2597 | |
| 2598 | if test -r "$cache_file"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2599 | # Some versions of bash will fail to source /dev/null (special files |
| 2600 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2601 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2602 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2603 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2604 | case $cache_file in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2605 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2606 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2607 | esac |
| 2608 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2609 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2610 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2611 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2612 | >$cache_file |
| 2613 | fi |
| 2614 | |
| 2615 | # Check that the precious variables saved in the cache have kept the same |
| 2616 | # value. |
| 2617 | ac_cache_corrupted=false |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2618 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2619 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2620 | eval ac_new_set=\$ac_env_${ac_var}_set |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2621 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2622 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2623 | case $ac_old_set,$ac_new_set in |
| 2624 | set,) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2625 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2626 | $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] | 2627 | ac_cache_corrupted=: ;; |
| 2628 | ,set) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2629 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2630 | $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] | 2631 | ac_cache_corrupted=: ;; |
| 2632 | ,);; |
| 2633 | *) |
| 2634 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2635 | # differences in whitespace do not lead to failure. |
| 2636 | ac_old_val_w=`echo x $ac_old_val` |
| 2637 | ac_new_val_w=`echo x $ac_new_val` |
| 2638 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2639 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2640 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2641 | ac_cache_corrupted=: |
| 2642 | else |
| 2643 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2644 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2645 | eval $ac_var=\$ac_old_val |
| 2646 | fi |
| 2647 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2648 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2649 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2650 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2651 | fi;; |
| 2652 | esac |
| 2653 | # Pass precious variables to config.status. |
| 2654 | if test "$ac_new_set" = set; then |
| 2655 | case $ac_new_val in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2656 | *\'*) 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] | 2657 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2658 | esac |
| 2659 | case " $ac_configure_args " in |
| 2660 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2661 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2662 | esac |
| 2663 | fi |
| 2664 | done |
| 2665 | if $ac_cache_corrupted; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2666 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2667 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2668 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2669 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
| 2670 | 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] | 2671 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2672 | ## -------------------- ## |
| 2673 | ## Main body of script. ## |
| 2674 | ## -------------------- ## |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2675 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2676 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2677 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2678 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2679 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2680 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2681 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2682 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2683 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2684 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2685 | |
| 2686 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2687 | |
Georg Brandl | bcd64a3 | 2009-03-31 21:45:18 +0000 | [diff] [blame] | 2688 | if test "$prefix" != "/"; then |
| 2689 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2690 | fi |
| 2691 | |
| 2692 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2693 | |
| 2694 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 2695 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 2696 | # with other autoconf-based packages that include Python.h |
| 2697 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 2698 | rm confdefs.h |
| 2699 | mv confdefs.h.new confdefs.h |
| 2700 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 2701 | |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 2702 | VERSION=2.7 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 2703 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 2704 | |
| 2705 | SOVERSION=1.0 |
| 2706 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2707 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 2708 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 2709 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2710 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2711 | |
| 2712 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2713 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2714 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 2715 | # them. |
| 2716 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2717 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2718 | |
| 2719 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2720 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2721 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 2722 | # them. |
| 2723 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2724 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2725 | |
| 2726 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2727 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2728 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 2729 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2730 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2731 | |
| 2732 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2733 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2734 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 2735 | # them. |
| 2736 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2737 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2738 | |
| 2739 | |
| 2740 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2741 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2742 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 2743 | # Arguments passed to configure. |
| 2744 | |
| 2745 | CONFIG_ARGS="$ac_configure_args" |
| 2746 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2747 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 2748 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2749 | # Check whether --enable-universalsdk was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2750 | if test "${enable_universalsdk+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2751 | enableval=$enable_universalsdk; |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2752 | case $enableval in |
| 2753 | yes) |
| 2754 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2755 | if test ! -d "${enableval}" |
| 2756 | then |
| 2757 | enableval=/ |
| 2758 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2759 | ;; |
| 2760 | esac |
| 2761 | case $enableval in |
| 2762 | no) |
| 2763 | UNIVERSALSDK= |
| 2764 | enable_universalsdk= |
| 2765 | ;; |
| 2766 | *) |
| 2767 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2768 | if test ! -d "${UNIVERSALSDK}" |
| 2769 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2770 | as_fn_error "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2771 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2772 | ;; |
| 2773 | esac |
| 2774 | |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2775 | |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2776 | else |
| 2777 | |
| 2778 | UNIVERSALSDK= |
| 2779 | enable_universalsdk= |
| 2780 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2781 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2782 | |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2783 | if test -n "${UNIVERSALSDK}" |
| 2784 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2785 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 2786 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2787 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2789 | $as_echo "no" >&6; } |
Ronald Oussoren | 3c0a126 | 2010-01-17 19:27:57 +0000 | [diff] [blame] | 2790 | fi |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 2791 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2792 | |
Benjamin Peterson | 0e6ea5d | 2008-07-16 20:17:04 +0000 | [diff] [blame] | 2793 | |
| 2794 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2795 | UNIVERSAL_ARCHS="32-bit" |
Ronald Oussoren | 92919a6 | 2009-12-24 13:30:58 +0000 | [diff] [blame] | 2796 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2797 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 2798 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2799 | |
| 2800 | # Check whether --with-universal-archs was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2801 | if test "${with_universal_archs+set}" = set; then : |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2802 | withval=$with_universal_archs; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2803 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 2804 | $as_echo "$withval" >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2805 | UNIVERSAL_ARCHS="$withval" |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2806 | if test "${enable_universalsdk}" ; then |
| 2807 | : |
| 2808 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2809 | 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] | 2810 | fi |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2811 | |
| 2812 | else |
| 2813 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 32-bit" >&5 |
| 2815 | $as_echo "32-bit" >&6; } |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2816 | |
| 2817 | fi |
| 2818 | |
| 2819 | |
| 2820 | |
| 2821 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2822 | |
| 2823 | # Check whether --with-framework-name was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2824 | if test "${with_framework_name+set}" = set; then : |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2825 | withval=$with_framework_name; |
Ronald Oussoren | 9ebd242 | 2009-09-29 13:00:44 +0000 | [diff] [blame] | 2826 | if test "${enable_framework}"; then |
| 2827 | : |
| 2828 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2829 | 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] | 2830 | fi |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2831 | PYTHONFRAMEWORK=${withval} |
| 2832 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 2833 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 2834 | |
| 2835 | else |
| 2836 | |
| 2837 | PYTHONFRAMEWORK=Python |
| 2838 | PYTHONFRAMEWORKDIR=Python.framework |
| 2839 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 2840 | |
| 2841 | fi |
| 2842 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2843 | # Check whether --enable-framework was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2844 | if test "${enable_framework+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2845 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2846 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2847 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2848 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2849 | esac |
| 2850 | case $enableval in |
| 2851 | no) |
| 2852 | PYTHONFRAMEWORK= |
| 2853 | PYTHONFRAMEWORKDIR=no-framework |
| 2854 | PYTHONFRAMEWORKPREFIX= |
| 2855 | PYTHONFRAMEWORKINSTALLDIR= |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2856 | FRAMEWORKINSTALLFIRST= |
| 2857 | FRAMEWORKINSTALLLAST= |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2858 | FRAMEWORKALTINSTALLFIRST= |
| 2859 | FRAMEWORKALTINSTALLLAST= |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2860 | if test "x${prefix}" = "xNONE"; then |
| 2861 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2862 | else |
| 2863 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2864 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2865 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2866 | ;; |
| 2867 | *) |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2868 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2869 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2870 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2871 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure bininstall maninstall" |
Ronald Oussoren | 92919a6 | 2009-12-24 13:30:58 +0000 | [diff] [blame] | 2872 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 2873 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2874 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2875 | |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2876 | if test "x${prefix}" = "xNONE" ; then |
| 2877 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2878 | |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2879 | else |
| 2880 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2881 | fi |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2882 | |
| 2883 | case "${enableval}" in |
| 2884 | /System*) |
| 2885 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2886 | if test "${prefix}" = "NONE" ; then |
| 2887 | # See below |
| 2888 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 2889 | fi |
| 2890 | ;; |
| 2891 | |
| 2892 | /Library*) |
| 2893 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2894 | ;; |
| 2895 | |
| 2896 | */Library/Frameworks) |
| 2897 | MDIR="`dirname "${enableval}"`" |
| 2898 | MDIR="`dirname "${MDIR}"`" |
| 2899 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 2900 | |
| 2901 | if test "${prefix}" = "NONE"; then |
| 2902 | # User hasn't specified the |
| 2903 | # --prefix option, but wants to install |
| 2904 | # the framework in a non-default location, |
| 2905 | # ensure that the compatibility links get |
| 2906 | # installed relative to that prefix as well |
| 2907 | # instead of in /usr/local. |
| 2908 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 2909 | fi |
| 2910 | ;; |
| 2911 | |
| 2912 | *) |
| 2913 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2914 | ;; |
| 2915 | esac |
| 2916 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2917 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2918 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2919 | # Add files for Mac specific code to the list of output |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2920 | # files: |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2921 | ac_config_files="$ac_config_files Mac/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2922 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2923 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2924 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2925 | ac_config_files="$ac_config_files Mac/IDLE/Makefile" |
Ronald Oussoren | 836b039 | 2006-05-14 19:56:34 +0000 | [diff] [blame] | 2926 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2927 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 2928 | |
| 2929 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 2930 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2931 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2932 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2933 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2934 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2935 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2936 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2937 | PYTHONFRAMEWORKPREFIX= |
| 2938 | PYTHONFRAMEWORKINSTALLDIR= |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2939 | FRAMEWORKINSTALLFIRST= |
| 2940 | FRAMEWORKINSTALLLAST= |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2941 | FRAMEWORKALTINSTALLFIRST= |
| 2942 | FRAMEWORKALTINSTALLLAST= |
Ronald Oussoren | 2db3a8f | 2006-06-07 19:06:01 +0000 | [diff] [blame] | 2943 | if test "x${prefix}" = "xNONE" ; then |
| 2944 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2945 | else |
| 2946 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2947 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2948 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2949 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 2950 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 2951 | fi |
| 2952 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2953 | |
| 2954 | |
| 2955 | |
| 2956 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2957 | |
Ronald Oussoren | 567a8ff | 2006-05-26 11:43:26 +0000 | [diff] [blame] | 2958 | |
| 2959 | |
Ronald Oussoren | 5b78732 | 2006-06-06 19:50:24 +0000 | [diff] [blame] | 2960 | |
| 2961 | |
| 2962 | |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 2963 | |
Ronald Oussoren | 01d149f | 2010-04-30 11:20:14 +0000 | [diff] [blame] | 2964 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2965 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 22520ea | 2010-05-08 10:14:46 +0000 | [diff] [blame] | 2966 | ## AS_HELP_STRING([--with-dyld], |
| 2967 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2968 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2969 | # Set name for machine-dependent library files |
| 2970 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 2971 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 2972 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2973 | if test -z "$MACHDEP" |
| 2974 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2975 | ac_sys_system=`uname -s` |
Georg Brandl | fe18a11 | 2009-09-04 07:55:14 +0000 | [diff] [blame] | 2976 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 2977 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2978 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2979 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2980 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2981 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2982 | ac_md_system=`echo $ac_sys_system | |
| 2983 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 2984 | ac_md_release=`echo $ac_sys_release | |
Guido van Rossum | 67b2659 | 2001-10-20 14:21:45 +0000 | [diff] [blame] | 2985 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2986 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2987 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2988 | case $MACHDEP in |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 2989 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 2990 | darwin*) MACHDEP="darwin";; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 2991 | atheos*) MACHDEP="atheos";; |
Martin v. Löwis | f332228 | 2003-07-13 09:46:13 +0000 | [diff] [blame] | 2992 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2993 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2994 | esac |
| 2995 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2996 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2997 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 2998 | # disable features if it is defined, without any means to access these |
| 2999 | # features as extensions. For these systems, we skip the definition of |
| 3000 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 3001 | # some feature, make sure there is no alternative way to access this |
| 3002 | # feature. Also, when using wildcards, make sure you have verified the |
| 3003 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 3004 | # wildcard, and that the wildcard does not include future systems |
| 3005 | # (which may remove their limitations). |
| 3006 | case $ac_sys_system/$ac_sys_release in |
| 3007 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 3008 | # 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] | 3009 | # 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] | 3010 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 3011 | # OpenBSD 4.6, but is fixed in 4.7. |
| 3012 | OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123456]) |
Martin v. Löwis | cb78de6 | 2007-12-29 18:49:21 +0000 | [diff] [blame] | 3013 | define_xopen_source=no |
| 3014 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3015 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3016 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3017 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3018 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | cb78de6 | 2007-12-29 18:49:21 +0000 | [diff] [blame] | 3019 | |
| 3020 | ;; |
Martin v. Löwis | 7875ef6 | 2010-02-15 21:41:12 +0000 | [diff] [blame] | 3021 | OpenBSD/4.[789]) |
Martin v. Löwis | 5e2dd86 | 2010-02-15 08:32:00 +0000 | [diff] [blame] | 3022 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3023 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3024 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3025 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3026 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 5e2dd86 | 2010-02-15 08:32:00 +0000 | [diff] [blame] | 3027 | |
| 3028 | ;; |
Martin v. Löwis | 4d542ec | 2006-11-25 15:39:19 +0000 | [diff] [blame] | 3029 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3030 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3031 | # Marc Recht |
Benjamin Peterson | eac68f4 | 2008-11-16 17:54:55 +0000 | [diff] [blame] | 3032 | 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] | 3033 | define_xopen_source=no;; |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3034 | # On Solaris 2.6, sys/wait.h is inconsistent in the usage |
| 3035 | # of union __?sigval. Reported by Stuart Bishop. |
| 3036 | SunOS/5.6) |
| 3037 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3038 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3039 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3040 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3041 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3042 | define_xopen_source=no;; |
| 3043 | # 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] | 3044 | # 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] | 3045 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3046 | define_xopen_source=no;; |
Martin v. Löwis | bb86d83 | 2008-11-04 20:40:09 +0000 | [diff] [blame] | 3047 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3048 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3049 | FreeBSD/4.*) |
| 3050 | define_xopen_source=no;; |
| 3051 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3052 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3053 | # identifies itself as Darwin/7.* |
| 3054 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3055 | # disables platform specific features beyond repair. |
| 3056 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3057 | # has no effect, don't bother defining them |
| 3058 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3059 | define_xopen_source=no;; |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 3060 | Darwin/1[0-9].*) |
| 3061 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3062 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3063 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3064 | # 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] | 3065 | AIX/4) |
| 3066 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3067 | AIX/5) |
| 3068 | if test `uname -r` -eq 1; then |
| 3069 | define_xopen_source=no |
| 3070 | fi |
| 3071 | ;; |
Martin v. Löwis | 8c255e4 | 2008-05-23 15:06:50 +0000 | [diff] [blame] | 3072 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3073 | # defining NI_NUMERICHOST. |
| 3074 | QNX/6.3.2) |
| 3075 | define_xopen_source=no |
| 3076 | ;; |
Martin v. Löwis | a058836 | 2006-04-04 06:03:50 +0000 | [diff] [blame] | 3077 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3078 | esac |
| 3079 | |
| 3080 | if test $define_xopen_source = yes |
| 3081 | then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3082 | # On Solaris w/ g++ it appears that _XOPEN_SOURCE has to be |
| 3083 | # defined precisely as g++ defines it |
Martin v. Löwis | 7dece66 | 2005-11-26 11:38:24 +0000 | [diff] [blame] | 3084 | # Furthermore, on Solaris 10, XPG6 requires the use of a C99 |
| 3085 | # compiler |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3086 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | 7dece66 | 2005-11-26 11:38:24 +0000 | [diff] [blame] | 3087 | SunOS/5.8|SunOS/5.9|SunOS/5.10) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3088 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3089 | $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3090 | |
| 3091 | ;; |
| 3092 | *) |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3093 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3094 | $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3095 | |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3096 | ;; |
| 3097 | esac |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3098 | |
| 3099 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3100 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3101 | # several APIs are not declared. Since this is also needed in some |
| 3102 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 7dece66 | 2005-11-26 11:38:24 +0000 | [diff] [blame] | 3103 | # except for Solaris 10, where it must not be defined, |
| 3104 | # as it implies XPG4.2 |
| 3105 | case $ac_sys_system/$ac_sys_release in |
| 3106 | SunOS/5.10) |
| 3107 | ;; |
| 3108 | *) |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3109 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3110 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3111 | |
Martin v. Löwis | 7dece66 | 2005-11-26 11:38:24 +0000 | [diff] [blame] | 3112 | ;; |
| 3113 | esac |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3114 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3115 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3116 | $as_echo "#define _POSIX_C_SOURCE 200112L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3117 | |
| 3118 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3119 | fi |
| 3120 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3121 | # |
| 3122 | # SGI compilers allow the specification of the both the ABI and the |
| 3123 | # ISA on the command line. Depending on the values of these switches, |
| 3124 | # different and often incompatable code will be generated. |
| 3125 | # |
| 3126 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3127 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3128 | # variable is also adjusted. |
| 3129 | # |
| 3130 | |
| 3131 | if test ! -z "$SGI_ABI" |
| 3132 | then |
| 3133 | CC="cc $SGI_ABI" |
| 3134 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3135 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3136 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3138 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3139 | |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3140 | # And add extra plat-mac for darwin |
| 3141 | |
Jack Jansen | 7b59b42 | 2003-03-17 15:44:10 +0000 | [diff] [blame] | 3142 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3143 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking EXTRAPLATDIR" >&5 |
| 3144 | $as_echo_n "checking EXTRAPLATDIR... " >&6; } |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3145 | if test -z "$EXTRAPLATDIR" |
| 3146 | then |
| 3147 | case $MACHDEP in |
Jack Jansen | 7b59b42 | 2003-03-17 15:44:10 +0000 | [diff] [blame] | 3148 | darwin) |
| 3149 | EXTRAPLATDIR="\$(PLATMACDIRS)" |
| 3150 | EXTRAMACHDEPPATH="\$(PLATMACPATH)" |
| 3151 | ;; |
| 3152 | *) |
| 3153 | EXTRAPLATDIR="" |
| 3154 | EXTRAMACHDEPPATH="" |
| 3155 | ;; |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3156 | esac |
| 3157 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3158 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRAPLATDIR" >&5 |
| 3159 | $as_echo "$EXTRAPLATDIR" >&6; } |
Jack Jansen | 83f898c | 2002-12-30 22:23:40 +0000 | [diff] [blame] | 3160 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3161 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3162 | # it may influence the way we can build extensions, so distutils |
| 3163 | # needs to check it |
| 3164 | |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 3165 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3166 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 3167 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3168 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3169 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking machine type as reported by uname -m" >&5 |
| 3170 | $as_echo_n "checking machine type as reported by uname -m... " >&6; } |
Mark Dickinson | 6513466 | 2008-04-25 16:11:04 +0000 | [diff] [blame] | 3171 | ac_sys_machine=`uname -m` |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3172 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_sys_machine" >&5 |
| 3173 | $as_echo "$ac_sys_machine" >&6; } |
Mark Dickinson | 6513466 | 2008-04-25 16:11:04 +0000 | [diff] [blame] | 3174 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3175 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3176 | |
| 3177 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3178 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3179 | # just to get things to compile and link. Users are free to override OPT |
| 3180 | # when running configure or make. The build should not break if they do. |
| 3181 | # BASECFLAGS should generally not be messed with, however. |
| 3182 | |
| 3183 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3184 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3186 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3187 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3188 | # Check whether --with-gcc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3189 | if test "${with_gcc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3190 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3191 | case $withval in |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 3192 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3193 | without_gcc=yes;; |
| 3194 | yes) CC=gcc |
| 3195 | without_gcc=no;; |
| 3196 | *) CC=$withval |
| 3197 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3198 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3199 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3200 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3201 | case $ac_sys_system in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3202 | AIX*) CC=cc_r |
| 3203 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3204 | BeOS*) |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3205 | case $BE_HOST_CPU in |
| 3206 | ppc) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 3207 | CC=mwcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3208 | without_gcc=yes |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3209 | BASECFLAGS="$BASECFLAGS -export pragma" |
| 3210 | OPT="$OPT -O" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3211 | LDFLAGS="$LDFLAGS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3212 | ;; |
| 3213 | x86) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 3214 | CC=gcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3215 | without_gcc=no |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3216 | OPT="$OPT -O" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3217 | ;; |
| 3218 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3219 | as_fn_error "Unknown BeOS platform \"$BE_HOST_CPU\"" "$LINENO" 5 |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3220 | ;; |
| 3221 | esac |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3222 | AR="\$(srcdir)/Modules/ar_beos" |
| 3223 | RANLIB=: |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 3224 | ;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3225 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3226 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3227 | fi |
| 3228 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3229 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3230 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3231 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3232 | # If the user switches compilers, we can't believe the cache |
| 3233 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3234 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3235 | as_fn_error "cached CC is different -- throw away $cache_file |
| 3236 | (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] | 3237 | fi |
| 3238 | |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 3239 | # If the user set CFLAGS, use this instead of the automatically |
| 3240 | # determined setting |
| 3241 | preset_cflags="$CFLAGS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3242 | ac_ext=c |
| 3243 | ac_cpp='$CPP $CPPFLAGS' |
| 3244 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3245 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3246 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3247 | if test -n "$ac_tool_prefix"; then |
| 3248 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3249 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3251 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3252 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3253 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3254 | else |
| 3255 | if test -n "$CC"; then |
| 3256 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3257 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3258 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3259 | for as_dir in $PATH |
| 3260 | do |
| 3261 | IFS=$as_save_IFS |
| 3262 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3263 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3264 | 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] | 3265 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3266 | $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] | 3267 | break 2 |
| 3268 | fi |
| 3269 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3270 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3271 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3272 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3273 | fi |
| 3274 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3275 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3276 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3278 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3279 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3281 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3282 | fi |
| 3283 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3284 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3285 | fi |
| 3286 | if test -z "$ac_cv_prog_CC"; then |
| 3287 | ac_ct_CC=$CC |
| 3288 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3289 | set dummy gcc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3290 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3291 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3292 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
| 3293 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3294 | else |
| 3295 | if test -n "$ac_ct_CC"; then |
| 3296 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3297 | else |
| 3298 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3299 | for as_dir in $PATH |
| 3300 | do |
| 3301 | IFS=$as_save_IFS |
| 3302 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3303 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3304 | 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] | 3305 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3306 | $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] | 3307 | break 2 |
| 3308 | fi |
| 3309 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3310 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3311 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3312 | |
| 3313 | fi |
| 3314 | fi |
| 3315 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3316 | if test -n "$ac_ct_CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3317 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3318 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3319 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3320 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3321 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3322 | fi |
| 3323 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3324 | if test "x$ac_ct_CC" = x; then |
| 3325 | CC="" |
| 3326 | else |
| 3327 | case $cross_compiling:$ac_tool_warned in |
| 3328 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3329 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3330 | $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] | 3331 | ac_tool_warned=yes ;; |
| 3332 | esac |
| 3333 | CC=$ac_ct_CC |
| 3334 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3335 | else |
| 3336 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3337 | fi |
| 3338 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3339 | if test -z "$CC"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3340 | if test -n "$ac_tool_prefix"; then |
| 3341 | # 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] | 3342 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3343 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3344 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3345 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3346 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3347 | else |
| 3348 | if test -n "$CC"; then |
| 3349 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3350 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3351 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3352 | for as_dir in $PATH |
| 3353 | do |
| 3354 | IFS=$as_save_IFS |
| 3355 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3356 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3357 | 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] | 3358 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3359 | $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] | 3360 | break 2 |
| 3361 | fi |
| 3362 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3363 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3364 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3365 | |
| 3366 | fi |
| 3367 | fi |
| 3368 | CC=$ac_cv_prog_CC |
| 3369 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3371 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3372 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3374 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3375 | fi |
| 3376 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3377 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3378 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3379 | fi |
| 3380 | if test -z "$CC"; then |
| 3381 | # Extract the first word of "cc", so it can be a program name with args. |
| 3382 | set dummy cc; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3383 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3384 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3385 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3386 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3387 | else |
| 3388 | if test -n "$CC"; then |
| 3389 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3390 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3391 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3392 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3393 | for as_dir in $PATH |
| 3394 | do |
| 3395 | IFS=$as_save_IFS |
| 3396 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3397 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3398 | 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] | 3399 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3400 | ac_prog_rejected=yes |
| 3401 | continue |
| 3402 | fi |
| 3403 | ac_cv_prog_CC="cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3404 | $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] | 3405 | break 2 |
| 3406 | fi |
| 3407 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3408 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3409 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3410 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3411 | if test $ac_prog_rejected = yes; then |
| 3412 | # We found a bogon in the path, so make sure we never use it. |
| 3413 | set dummy $ac_cv_prog_CC |
| 3414 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3415 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3416 | # We chose a different compiler from the bogus one. |
| 3417 | # However, it has the same basename, so the bogon will be chosen |
| 3418 | # first if we set CC to just the basename; use the full file name. |
| 3419 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3420 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3421 | fi |
| 3422 | fi |
| 3423 | fi |
| 3424 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3425 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3426 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3428 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3429 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3431 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3432 | fi |
| 3433 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3434 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3435 | fi |
| 3436 | if test -z "$CC"; then |
| 3437 | if test -n "$ac_tool_prefix"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3438 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3439 | do |
| 3440 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3441 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3442 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3443 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3444 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3445 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3446 | else |
| 3447 | if test -n "$CC"; then |
| 3448 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3449 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3450 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3451 | for as_dir in $PATH |
| 3452 | do |
| 3453 | IFS=$as_save_IFS |
| 3454 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3455 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3456 | 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] | 3457 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3458 | $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] | 3459 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3460 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3461 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3462 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3463 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3464 | |
| 3465 | fi |
| 3466 | fi |
| 3467 | CC=$ac_cv_prog_CC |
| 3468 | if test -n "$CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3470 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3471 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3472 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3473 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3474 | fi |
| 3475 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3476 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3477 | test -n "$CC" && break |
| 3478 | done |
| 3479 | fi |
| 3480 | if test -z "$CC"; then |
| 3481 | ac_ct_CC=$CC |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3482 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3483 | do |
| 3484 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3485 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3486 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3487 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3488 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
| 3489 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3490 | else |
| 3491 | if test -n "$ac_ct_CC"; then |
| 3492 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3493 | else |
| 3494 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3495 | for as_dir in $PATH |
| 3496 | do |
| 3497 | IFS=$as_save_IFS |
| 3498 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3499 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3500 | 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] | 3501 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3502 | $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] | 3503 | break 2 |
| 3504 | fi |
| 3505 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3506 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3507 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3508 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3509 | fi |
| 3510 | fi |
| 3511 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3512 | if test -n "$ac_ct_CC"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3513 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3514 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3515 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3517 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3518 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3519 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3520 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3521 | test -n "$ac_ct_CC" && break |
| 3522 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3523 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3524 | if test "x$ac_ct_CC" = x; then |
| 3525 | CC="" |
| 3526 | else |
| 3527 | case $cross_compiling:$ac_tool_warned in |
| 3528 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3529 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3530 | $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] | 3531 | ac_tool_warned=yes ;; |
| 3532 | esac |
| 3533 | CC=$ac_ct_CC |
| 3534 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3535 | fi |
| 3536 | |
| 3537 | fi |
| 3538 | |
| 3539 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3540 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3541 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3542 | as_fn_error "no acceptable C compiler found in \$PATH |
| 3543 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3544 | |
| 3545 | # Provide some information about the compiler. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3546 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3547 | set X $ac_compile |
| 3548 | ac_compiler=$2 |
| 3549 | for ac_option in --version -v -V -qversion; do |
| 3550 | { { ac_try="$ac_compiler $ac_option >&5" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3551 | case "(($ac_try" in |
| 3552 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3553 | *) ac_try_echo=$ac_try;; |
| 3554 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3555 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3556 | $as_echo "$ac_try_echo"; } >&5 |
| 3557 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3558 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3559 | if test -s conftest.err; then |
| 3560 | sed '10a\ |
| 3561 | ... rest of stderr output deleted ... |
| 3562 | 10q' conftest.err >conftest.er1 |
| 3563 | cat conftest.er1 >&5 |
| 3564 | fi |
| 3565 | rm -f conftest.er1 conftest.err |
| 3566 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3567 | test $ac_status = 0; } |
| 3568 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3569 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3570 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3571 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3572 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3573 | int |
| 3574 | main () |
| 3575 | { |
| 3576 | |
| 3577 | ; |
| 3578 | return 0; |
| 3579 | } |
| 3580 | _ACEOF |
| 3581 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3582 | 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] | 3583 | # Try to create an executable without -o first, disregard a.out. |
| 3584 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3585 | # of exeext. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3587 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3588 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3589 | |
| 3590 | # The possible output files: |
| 3591 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3592 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3593 | ac_rmfiles= |
| 3594 | for ac_file in $ac_files |
| 3595 | do |
| 3596 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3597 | *.$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] | 3598 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3599 | esac |
| 3600 | done |
| 3601 | rm -f $ac_rmfiles |
| 3602 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3603 | if { { ac_try="$ac_link_default" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3604 | case "(($ac_try" in |
| 3605 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3606 | *) ac_try_echo=$ac_try;; |
| 3607 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3608 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3609 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3610 | (eval "$ac_link_default") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3611 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3612 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3613 | test $ac_status = 0; }; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3614 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3615 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3616 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3617 | # so that the user can short-circuit this test for compilers unknown to |
| 3618 | # Autoconf. |
| 3619 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3620 | do |
| 3621 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3622 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3623 | *.$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] | 3624 | ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3625 | [ab].out ) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3626 | # We found the default executable, but exeext='' is most |
| 3627 | # certainly right. |
| 3628 | break;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3629 | *.* ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3630 | 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] | 3631 | then :; else |
| 3632 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3633 | fi |
| 3634 | # We set ac_cv_exeext here because the later test for it is not |
| 3635 | # safe: cross compilers may not add the suffix if given an `-o' |
| 3636 | # argument, so we may need to know it at that point already. |
| 3637 | # Even if this section looks crufty: it has the advantage of |
| 3638 | # actually working. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3639 | break;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3640 | * ) |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3641 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3642 | esac |
| 3643 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3644 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 3645 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3646 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3647 | ac_file='' |
| 3648 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3649 | if test -z "$ac_file"; then : |
| 3650 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3651 | $as_echo "no" >&6; } |
| 3652 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3653 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3654 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3655 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3656 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3657 | { as_fn_set_status 77 |
| 3658 | as_fn_error "C compiler cannot create executables |
| 3659 | See \`config.log' for more details." "$LINENO" 5; }; } |
| 3660 | else |
| 3661 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 3662 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3663 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3664 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 3665 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 3666 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 3667 | $as_echo "$ac_file" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3668 | ac_exeext=$ac_cv_exeext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3669 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3670 | 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] | 3671 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 3673 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 3674 | if { { ac_try="$ac_link" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3675 | case "(($ac_try" in |
| 3676 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3677 | *) ac_try_echo=$ac_try;; |
| 3678 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3679 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3680 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3681 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3682 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3683 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3684 | test $ac_status = 0; }; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3685 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 3686 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 3687 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 3688 | # `rm'. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3689 | for ac_file in conftest.exe conftest conftest.*; do |
| 3690 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3691 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3692 | *.$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] | 3693 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3694 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3695 | * ) break;; |
| 3696 | esac |
| 3697 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3698 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3699 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3700 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3701 | as_fn_error "cannot compute suffix of executables: cannot compile and link |
| 3702 | See \`config.log' for more details." "$LINENO" 5; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3703 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3704 | rm -f conftest conftest$ac_cv_exeext |
| 3705 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 3706 | $as_echo "$ac_cv_exeext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3707 | |
| 3708 | rm -f conftest.$ac_ext |
| 3709 | EXEEXT=$ac_cv_exeext |
| 3710 | ac_exeext=$EXEEXT |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3711 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3712 | /* end confdefs.h. */ |
| 3713 | #include <stdio.h> |
| 3714 | int |
| 3715 | main () |
| 3716 | { |
| 3717 | FILE *f = fopen ("conftest.out", "w"); |
| 3718 | return ferror (f) || fclose (f) != 0; |
| 3719 | |
| 3720 | ; |
| 3721 | return 0; |
| 3722 | } |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3723 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3724 | ac_clean_files="$ac_clean_files conftest.out" |
| 3725 | # Check that the compiler produces executables we can run. If not, either |
| 3726 | # the compiler is broken, or we cross compile. |
| 3727 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3728 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3729 | if test "$cross_compiling" != yes; then |
| 3730 | { { ac_try="$ac_link" |
| 3731 | case "(($ac_try" in |
| 3732 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3733 | *) ac_try_echo=$ac_try;; |
| 3734 | esac |
| 3735 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3736 | $as_echo "$ac_try_echo"; } >&5 |
| 3737 | (eval "$ac_link") 2>&5 |
| 3738 | ac_status=$? |
| 3739 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3740 | test $ac_status = 0; } |
| 3741 | if { ac_try='./conftest$ac_cv_exeext' |
| 3742 | { { case "(($ac_try" in |
| 3743 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3744 | *) ac_try_echo=$ac_try;; |
| 3745 | esac |
| 3746 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3747 | $as_echo "$ac_try_echo"; } >&5 |
| 3748 | (eval "$ac_try") 2>&5 |
| 3749 | ac_status=$? |
| 3750 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3751 | test $ac_status = 0; }; }; then |
| 3752 | cross_compiling=no |
| 3753 | else |
| 3754 | if test "$cross_compiling" = maybe; then |
| 3755 | cross_compiling=yes |
| 3756 | else |
| 3757 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3758 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3759 | as_fn_error "cannot run C compiled programs. |
| 3760 | If you meant to cross compile, use \`--host'. |
| 3761 | See \`config.log' for more details." "$LINENO" 5; } |
| 3762 | fi |
| 3763 | fi |
| 3764 | fi |
| 3765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3766 | $as_echo "$cross_compiling" >&6; } |
| 3767 | |
| 3768 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3769 | ac_clean_files=$ac_clean_files_save |
| 3770 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3771 | $as_echo_n "checking for suffix of object files... " >&6; } |
| 3772 | if test "${ac_cv_objext+set}" = set; then : |
| 3773 | $as_echo_n "(cached) " >&6 |
| 3774 | else |
| 3775 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3776 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3777 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3778 | int |
| 3779 | main () |
| 3780 | { |
| 3781 | |
| 3782 | ; |
| 3783 | return 0; |
| 3784 | } |
| 3785 | _ACEOF |
| 3786 | rm -f conftest.o conftest.obj |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3787 | if { { ac_try="$ac_compile" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3788 | case "(($ac_try" in |
| 3789 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3790 | *) ac_try_echo=$ac_try;; |
| 3791 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3792 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3793 | $as_echo "$ac_try_echo"; } >&5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3794 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3795 | ac_status=$? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3796 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3797 | test $ac_status = 0; }; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3798 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3799 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3800 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3801 | *.$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] | 3802 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3803 | break;; |
| 3804 | esac |
| 3805 | done |
| 3806 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3807 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3808 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3809 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3810 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3811 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 3812 | as_fn_error "cannot compute suffix of object files: cannot compile |
| 3813 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3814 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3815 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
| 3816 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3818 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3819 | OBJEXT=$ac_cv_objext |
| 3820 | ac_objext=$OBJEXT |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3821 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3822 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
| 3823 | if test "${ac_cv_c_compiler_gnu+set}" = set; then : |
| 3824 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3825 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3826 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3827 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3828 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3829 | int |
| 3830 | main () |
| 3831 | { |
| 3832 | #ifndef __GNUC__ |
| 3833 | choke me |
| 3834 | #endif |
| 3835 | |
| 3836 | ; |
| 3837 | return 0; |
| 3838 | } |
| 3839 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3840 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3841 | ac_compiler_gnu=yes |
| 3842 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3843 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3844 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3845 | 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] | 3846 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3847 | |
| 3848 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3849 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 3850 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3851 | if test $ac_compiler_gnu = yes; then |
| 3852 | GCC=yes |
| 3853 | else |
| 3854 | GCC= |
| 3855 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3856 | ac_test_CFLAGS=${CFLAGS+set} |
| 3857 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3858 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3859 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
| 3860 | if test "${ac_cv_prog_cc_g+set}" = set; then : |
| 3861 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3862 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3863 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3864 | ac_c_werror_flag=yes |
| 3865 | ac_cv_prog_cc_g=no |
| 3866 | CFLAGS="-g" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3867 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3868 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3869 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3870 | int |
| 3871 | main () |
| 3872 | { |
| 3873 | |
| 3874 | ; |
| 3875 | return 0; |
| 3876 | } |
| 3877 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3878 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3879 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3880 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3881 | CFLAGS="" |
| 3882 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3883 | /* end confdefs.h. */ |
| 3884 | |
| 3885 | int |
| 3886 | main () |
| 3887 | { |
| 3888 | |
| 3889 | ; |
| 3890 | return 0; |
| 3891 | } |
| 3892 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3893 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3894 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3895 | else |
| 3896 | ac_c_werror_flag=$ac_save_c_werror_flag |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3897 | CFLAGS="-g" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3898 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3899 | /* end confdefs.h. */ |
| 3900 | |
| 3901 | int |
| 3902 | main () |
| 3903 | { |
| 3904 | |
| 3905 | ; |
| 3906 | return 0; |
| 3907 | } |
| 3908 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3909 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3910 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3911 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3912 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3913 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3914 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3915 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3916 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3917 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3918 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3919 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3920 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3921 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3922 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3923 | elif test $ac_cv_prog_cc_g = yes; then |
| 3924 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3925 | CFLAGS="-g -O2" |
| 3926 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3927 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3928 | fi |
| 3929 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3930 | if test "$GCC" = yes; then |
| 3931 | CFLAGS="-O2" |
| 3932 | else |
| 3933 | CFLAGS= |
| 3934 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3935 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3937 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
| 3938 | if test "${ac_cv_prog_cc_c89+set}" = set; then : |
| 3939 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3940 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3941 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3942 | ac_save_CC=$CC |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 3943 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3944 | /* end confdefs.h. */ |
| 3945 | #include <stdarg.h> |
| 3946 | #include <stdio.h> |
| 3947 | #include <sys/types.h> |
| 3948 | #include <sys/stat.h> |
| 3949 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3950 | struct buf { int x; }; |
| 3951 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3952 | static char *e (p, i) |
| 3953 | char **p; |
| 3954 | int i; |
| 3955 | { |
| 3956 | return p[i]; |
| 3957 | } |
| 3958 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3959 | { |
| 3960 | char *s; |
| 3961 | va_list v; |
| 3962 | va_start (v,p); |
| 3963 | s = g (p, va_arg (v,int)); |
| 3964 | va_end (v); |
| 3965 | return s; |
| 3966 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3967 | |
| 3968 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3969 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3970 | 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] | 3971 | 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] | 3972 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3973 | 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] | 3974 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3975 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3976 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3977 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3978 | inside strings and character constants. */ |
| 3979 | #define FOO(x) 'x' |
| 3980 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3981 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3982 | int test (int i, double x); |
| 3983 | struct s1 {int (*f) (int a);}; |
| 3984 | struct s2 {int (*f) (double a);}; |
| 3985 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3986 | int argc; |
| 3987 | char **argv; |
| 3988 | int |
| 3989 | main () |
| 3990 | { |
| 3991 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3992 | ; |
| 3993 | return 0; |
| 3994 | } |
| 3995 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 3996 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3997 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3998 | do |
| 3999 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4000 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4001 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4002 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4003 | rm -f core conftest.err conftest.$ac_objext |
| 4004 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4005 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4006 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4007 | CC=$ac_save_CC |
| 4008 | |
| 4009 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4010 | # AC_CACHE_VAL |
| 4011 | case "x$ac_cv_prog_cc_c89" in |
| 4012 | x) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 4014 | $as_echo "none needed" >&6; } ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4015 | xno) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4016 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 4017 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4018 | *) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4019 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4020 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 4021 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4022 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4023 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4024 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4025 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4026 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4027 | ac_ext=c |
| 4028 | ac_cpp='$CPP $CPPFLAGS' |
| 4029 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4030 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4031 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4032 | |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 4033 | if test ! -z "$preset_cflags" |
| 4034 | then |
| 4035 | CFLAGS=$preset_cflags |
| 4036 | fi |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4037 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4038 | |
| 4039 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4040 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 4041 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4042 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4043 | # Check whether --with-cxx_main was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4044 | if test "${with_cxx_main+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4045 | withval=$with_cxx_main; |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4046 | |
| 4047 | case $withval in |
| 4048 | no) with_cxx_main=no |
| 4049 | MAINCC='$(CC)';; |
| 4050 | yes) with_cxx_main=yes |
| 4051 | MAINCC='$(CXX)';; |
| 4052 | *) with_cxx_main=yes |
| 4053 | MAINCC=$withval |
| 4054 | if test -z "$CXX" |
| 4055 | then |
| 4056 | CXX=$withval |
| 4057 | fi;; |
| 4058 | esac |
| 4059 | else |
| 4060 | |
| 4061 | with_cxx_main=no |
| 4062 | MAINCC='$(CC)' |
| 4063 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4064 | fi |
| 4065 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4066 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 4067 | $as_echo "$with_cxx_main" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4068 | |
| 4069 | preset_cxx="$CXX" |
| 4070 | if test -z "$CXX" |
| 4071 | then |
| 4072 | case "$CC" in |
| 4073 | gcc) # Extract the first word of "g++", so it can be a program name with args. |
| 4074 | set dummy g++; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4075 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4076 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4077 | if test "${ac_cv_path_CXX+set}" = set; then : |
| 4078 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4079 | else |
| 4080 | case $CXX in |
| 4081 | [\\/]* | ?:[\\/]*) |
| 4082 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4083 | ;; |
| 4084 | *) |
| 4085 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4086 | for as_dir in notfound |
| 4087 | do |
| 4088 | IFS=$as_save_IFS |
| 4089 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4090 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4091 | 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] | 4092 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4093 | $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] | 4094 | break 2 |
| 4095 | fi |
| 4096 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4097 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4098 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4099 | |
| 4100 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++" |
| 4101 | ;; |
| 4102 | esac |
| 4103 | fi |
| 4104 | CXX=$ac_cv_path_CXX |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4105 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4106 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4107 | $as_echo "$CXX" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4108 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4109 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4110 | $as_echo "no" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4111 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4112 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4113 | ;; |
| 4114 | cc) # Extract the first word of "c++", so it can be a program name with args. |
| 4115 | set dummy c++; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4116 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4117 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4118 | if test "${ac_cv_path_CXX+set}" = set; then : |
| 4119 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4120 | else |
| 4121 | case $CXX in |
| 4122 | [\\/]* | ?:[\\/]*) |
| 4123 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4124 | ;; |
| 4125 | *) |
| 4126 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4127 | for as_dir in notfound |
| 4128 | do |
| 4129 | IFS=$as_save_IFS |
| 4130 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4131 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4132 | 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] | 4133 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4134 | $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] | 4135 | break 2 |
| 4136 | fi |
| 4137 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4138 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4139 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4140 | |
| 4141 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++" |
| 4142 | ;; |
| 4143 | esac |
| 4144 | fi |
| 4145 | CXX=$ac_cv_path_CXX |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4146 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4147 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4148 | $as_echo "$CXX" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4149 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4150 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4151 | $as_echo "no" >&6; } |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 4152 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4153 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4154 | ;; |
| 4155 | esac |
| 4156 | if test "$CXX" = "notfound" |
| 4157 | then |
| 4158 | CXX="" |
| 4159 | fi |
| 4160 | fi |
| 4161 | if test -z "$CXX" |
| 4162 | then |
| 4163 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4164 | do |
| 4165 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4166 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4167 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4168 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4169 | if test "${ac_cv_prog_CXX+set}" = set; then : |
| 4170 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4171 | else |
| 4172 | if test -n "$CXX"; then |
| 4173 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4174 | else |
| 4175 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4176 | for as_dir in $PATH |
| 4177 | do |
| 4178 | IFS=$as_save_IFS |
| 4179 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4180 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4181 | 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] | 4182 | ac_cv_prog_CXX="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4183 | $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] | 4184 | break 2 |
| 4185 | fi |
| 4186 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4187 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4188 | IFS=$as_save_IFS |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4189 | |
| 4190 | fi |
| 4191 | fi |
| 4192 | CXX=$ac_cv_prog_CXX |
| 4193 | if test -n "$CXX"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4195 | $as_echo "$CXX" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4196 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4197 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4198 | $as_echo "no" >&6; } |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4199 | fi |
| 4200 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4201 | |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4202 | test -n "$CXX" && break |
| 4203 | done |
| 4204 | test -n "$CXX" || CXX="notfound" |
| 4205 | |
| 4206 | if test "$CXX" = "notfound" |
| 4207 | then |
| 4208 | CXX="" |
| 4209 | fi |
| 4210 | fi |
| 4211 | if test "$preset_cxx" != "$CXX" |
| 4212 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4213 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4214 | |
| 4215 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4216 | If this is not intended, then set CXX on the configure command line. |
| 4217 | " >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4218 | $as_echo "$as_me: WARNING: |
Martin v. Löwis | 0f48d98 | 2006-04-14 14:34:26 +0000 | [diff] [blame] | 4219 | |
| 4220 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4221 | If this is not intended, then set CXX on the configure command line. |
| 4222 | " >&2;} |
| 4223 | fi |
| 4224 | |
| 4225 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4226 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4227 | |
| 4228 | ac_ext=c |
| 4229 | ac_cpp='$CPP $CPPFLAGS' |
| 4230 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4231 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4232 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4233 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4234 | $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] | 4235 | # On Suns, sometimes $CPP names a directory. |
| 4236 | if test -n "$CPP" && test -d "$CPP"; then |
| 4237 | CPP= |
| 4238 | fi |
| 4239 | if test -z "$CPP"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4240 | if test "${ac_cv_prog_CPP+set}" = set; then : |
| 4241 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4242 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4243 | # Double quotes because CPP needs to be expanded |
| 4244 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4245 | do |
| 4246 | ac_preproc_ok=false |
| 4247 | for ac_c_preproc_warn_flag in '' yes |
| 4248 | do |
| 4249 | # Use a header file that comes with gcc, so configuring glibc |
| 4250 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4251 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4252 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4253 | # 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] | 4254 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4255 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4256 | /* end confdefs.h. */ |
| 4257 | #ifdef __STDC__ |
| 4258 | # include <limits.h> |
| 4259 | #else |
| 4260 | # include <assert.h> |
| 4261 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4262 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4263 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4264 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4265 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4266 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4267 | # Broken: fails on valid input. |
| 4268 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4269 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4270 | rm -f conftest.err conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4271 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4272 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4273 | # can be detected and how. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4274 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4275 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4276 | #include <ac_nonexistent.h> |
| 4277 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4278 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4279 | # Broken: success on invalid input. |
| 4280 | continue |
| 4281 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4282 | # Passes both tests. |
| 4283 | ac_preproc_ok=: |
| 4284 | break |
| 4285 | fi |
| 4286 | rm -f conftest.err conftest.$ac_ext |
| 4287 | |
| 4288 | done |
| 4289 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 4290 | rm -f conftest.err conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4291 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4292 | break |
| 4293 | fi |
| 4294 | |
| 4295 | done |
| 4296 | ac_cv_prog_CPP=$CPP |
| 4297 | |
| 4298 | fi |
| 4299 | CPP=$ac_cv_prog_CPP |
| 4300 | else |
| 4301 | ac_cv_prog_CPP=$CPP |
| 4302 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4303 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4304 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4305 | ac_preproc_ok=false |
| 4306 | for ac_c_preproc_warn_flag in '' yes |
| 4307 | do |
| 4308 | # Use a header file that comes with gcc, so configuring glibc |
| 4309 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4310 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4311 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4312 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4313 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4314 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4315 | /* end confdefs.h. */ |
| 4316 | #ifdef __STDC__ |
| 4317 | # include <limits.h> |
| 4318 | #else |
| 4319 | # include <assert.h> |
| 4320 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4321 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4322 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4323 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4324 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4325 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4326 | # Broken: fails on valid input. |
| 4327 | continue |
| 4328 | fi |
| 4329 | rm -f conftest.err conftest.$ac_ext |
| 4330 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4331 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4332 | # can be detected and how. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4333 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4334 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4335 | #include <ac_nonexistent.h> |
| 4336 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4337 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4338 | # Broken: success on invalid input. |
| 4339 | continue |
| 4340 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4341 | # Passes both tests. |
| 4342 | ac_preproc_ok=: |
| 4343 | break |
| 4344 | fi |
| 4345 | rm -f conftest.err conftest.$ac_ext |
| 4346 | |
| 4347 | done |
| 4348 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
| 4349 | rm -f conftest.err conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4350 | if $ac_preproc_ok; then : |
| 4351 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4352 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4353 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4354 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 4355 | as_fn_error "C preprocessor \"$CPP\" fails sanity check |
| 4356 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4357 | fi |
| 4358 | |
| 4359 | ac_ext=c |
| 4360 | ac_cpp='$CPP $CPPFLAGS' |
| 4361 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4362 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4363 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 4364 | |
| 4365 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4366 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 4367 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
| 4368 | if test "${ac_cv_path_GREP+set}" = set; then : |
| 4369 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4370 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4371 | if test -z "$GREP"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4372 | ac_path_GREP_found=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4373 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4374 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4375 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4376 | do |
| 4377 | IFS=$as_save_IFS |
| 4378 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4379 | for ac_prog in grep ggrep; do |
| 4380 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4381 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4382 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue |
| 4383 | # 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] | 4384 | # Check for GNU $ac_path_GREP |
| 4385 | case `"$ac_path_GREP" --version 2>&1` in |
| 4386 | *GNU*) |
| 4387 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 4388 | *) |
| 4389 | ac_count=0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4390 | $as_echo_n 0123456789 >"conftest.in" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4391 | while : |
| 4392 | do |
| 4393 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4394 | mv "conftest.tmp" "conftest.in" |
| 4395 | cp "conftest.in" "conftest.nl" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4396 | $as_echo 'GREP' >> "conftest.nl" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4397 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4398 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4399 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4400 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 4401 | # Best one so far, save it but keep looking for a better one |
| 4402 | ac_cv_path_GREP="$ac_path_GREP" |
| 4403 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4404 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4405 | # 10*(2^10) chars as input seems more than enough |
| 4406 | test $ac_count -gt 10 && break |
| 4407 | done |
| 4408 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4409 | esac |
| 4410 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4411 | $ac_path_GREP_found && break 3 |
| 4412 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4413 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4414 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4415 | IFS=$as_save_IFS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4416 | if test -z "$ac_cv_path_GREP"; then |
| 4417 | as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
| 4418 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4419 | else |
| 4420 | ac_cv_path_GREP=$GREP |
| 4421 | fi |
| 4422 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4423 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 4425 | $as_echo "$ac_cv_path_GREP" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4426 | GREP="$ac_cv_path_GREP" |
| 4427 | |
| 4428 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4429 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 4430 | $as_echo_n "checking for egrep... " >&6; } |
| 4431 | if test "${ac_cv_path_EGREP+set}" = set; then : |
| 4432 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4433 | else |
| 4434 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 4435 | then ac_cv_path_EGREP="$GREP -E" |
| 4436 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4437 | if test -z "$EGREP"; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4438 | ac_path_EGREP_found=false |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4439 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4440 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4441 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4442 | do |
| 4443 | IFS=$as_save_IFS |
| 4444 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4445 | for ac_prog in egrep; do |
| 4446 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4447 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4448 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
| 4449 | # 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] | 4450 | # Check for GNU $ac_path_EGREP |
| 4451 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4452 | *GNU*) |
| 4453 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4454 | *) |
| 4455 | ac_count=0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4456 | $as_echo_n 0123456789 >"conftest.in" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4457 | while : |
| 4458 | do |
| 4459 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4460 | mv "conftest.tmp" "conftest.in" |
| 4461 | cp "conftest.in" "conftest.nl" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4462 | $as_echo 'EGREP' >> "conftest.nl" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4463 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4464 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4465 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4466 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4467 | # Best one so far, save it but keep looking for a better one |
| 4468 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4469 | ac_path_EGREP_max=$ac_count |
| 4470 | fi |
| 4471 | # 10*(2^10) chars as input seems more than enough |
| 4472 | test $ac_count -gt 10 && break |
| 4473 | done |
| 4474 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4475 | esac |
| 4476 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4477 | $ac_path_EGREP_found && break 3 |
| 4478 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4479 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4480 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4481 | IFS=$as_save_IFS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4482 | if test -z "$ac_cv_path_EGREP"; then |
| 4483 | as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
| 4484 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4485 | else |
| 4486 | ac_cv_path_EGREP=$EGREP |
| 4487 | fi |
| 4488 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4489 | fi |
| 4490 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4492 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 4493 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4494 | |
| 4495 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4496 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4497 | $as_echo_n "checking for ANSI C header files... " >&6; } |
| 4498 | if test "${ac_cv_header_stdc+set}" = set; then : |
| 4499 | $as_echo_n "(cached) " >&6 |
| 4500 | else |
| 4501 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4502 | /* end confdefs.h. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4503 | #include <stdlib.h> |
| 4504 | #include <stdarg.h> |
| 4505 | #include <string.h> |
| 4506 | #include <float.h> |
| 4507 | |
| 4508 | int |
| 4509 | main () |
| 4510 | { |
| 4511 | |
| 4512 | ; |
| 4513 | return 0; |
| 4514 | } |
| 4515 | _ACEOF |
| 4516 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4517 | ac_cv_header_stdc=yes |
| 4518 | else |
| 4519 | ac_cv_header_stdc=no |
| 4520 | fi |
| 4521 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4522 | |
| 4523 | if test $ac_cv_header_stdc = yes; then |
| 4524 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4525 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4526 | /* end confdefs.h. */ |
| 4527 | #include <string.h> |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4528 | |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 4529 | _ACEOF |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4530 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4531 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4532 | |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4533 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4534 | ac_cv_header_stdc=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 4535 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 4536 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4537 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4538 | fi |
| 4539 | |
| 4540 | if test $ac_cv_header_stdc = yes; then |
| 4541 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4542 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4543 | /* end confdefs.h. */ |
| 4544 | #include <stdlib.h> |
| 4545 | |
| 4546 | _ACEOF |
| 4547 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4548 | $EGREP "free" >/dev/null 2>&1; then : |
| 4549 | |
| 4550 | else |
| 4551 | ac_cv_header_stdc=no |
| 4552 | fi |
| 4553 | rm -f conftest* |
| 4554 | |
| 4555 | fi |
| 4556 | |
| 4557 | if test $ac_cv_header_stdc = yes; then |
| 4558 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4559 | if test "$cross_compiling" = yes; then : |
| 4560 | : |
| 4561 | else |
| 4562 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4563 | /* end confdefs.h. */ |
| 4564 | #include <ctype.h> |
| 4565 | #include <stdlib.h> |
| 4566 | #if ((' ' & 0x0FF) == 0x020) |
| 4567 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4568 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4569 | #else |
| 4570 | # define ISLOWER(c) \ |
| 4571 | (('a' <= (c) && (c) <= 'i') \ |
| 4572 | || ('j' <= (c) && (c) <= 'r') \ |
| 4573 | || ('s' <= (c) && (c) <= 'z')) |
| 4574 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4575 | #endif |
| 4576 | |
| 4577 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4578 | int |
| 4579 | main () |
| 4580 | { |
| 4581 | int i; |
| 4582 | for (i = 0; i < 256; i++) |
| 4583 | if (XOR (islower (i), ISLOWER (i)) |
| 4584 | || toupper (i) != TOUPPER (i)) |
| 4585 | return 2; |
| 4586 | return 0; |
| 4587 | } |
| 4588 | _ACEOF |
| 4589 | if ac_fn_c_try_run "$LINENO"; then : |
| 4590 | |
| 4591 | else |
| 4592 | ac_cv_header_stdc=no |
| 4593 | fi |
| 4594 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4595 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 4596 | fi |
| 4597 | |
| 4598 | fi |
| 4599 | fi |
| 4600 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4601 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 4602 | if test $ac_cv_header_stdc = yes; then |
| 4603 | |
| 4604 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 4605 | |
| 4606 | fi |
| 4607 | |
| 4608 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 4609 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4610 | inttypes.h stdint.h unistd.h |
| 4611 | do : |
| 4612 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4613 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4614 | " |
| 4615 | eval as_val=\$$as_ac_Header |
| 4616 | if test "x$as_val" = x""yes; then : |
| 4617 | cat >>confdefs.h <<_ACEOF |
| 4618 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4619 | _ACEOF |
| 4620 | |
| 4621 | fi |
| 4622 | |
| 4623 | done |
| 4624 | |
| 4625 | |
| 4626 | |
| 4627 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
| 4628 | if test "x$ac_cv_header_minix_config_h" = x""yes; then : |
| 4629 | MINIX=yes |
| 4630 | else |
| 4631 | MINIX= |
| 4632 | fi |
| 4633 | |
| 4634 | |
| 4635 | if test "$MINIX" = yes; then |
| 4636 | |
| 4637 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 4638 | |
| 4639 | |
| 4640 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 4641 | |
| 4642 | |
| 4643 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 4644 | |
| 4645 | fi |
| 4646 | |
| 4647 | |
| 4648 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 4649 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
| 4650 | if test "${ac_cv_safe_to_define___extensions__+set}" = set; then : |
| 4651 | $as_echo_n "(cached) " >&6 |
| 4652 | else |
| 4653 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4654 | /* end confdefs.h. */ |
| 4655 | |
| 4656 | # define __EXTENSIONS__ 1 |
| 4657 | $ac_includes_default |
| 4658 | int |
| 4659 | main () |
| 4660 | { |
| 4661 | |
| 4662 | ; |
| 4663 | return 0; |
| 4664 | } |
| 4665 | _ACEOF |
| 4666 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4667 | ac_cv_safe_to_define___extensions__=yes |
| 4668 | else |
| 4669 | ac_cv_safe_to_define___extensions__=no |
| 4670 | fi |
| 4671 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4672 | fi |
| 4673 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 4674 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 4675 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 4676 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 4677 | |
| 4678 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 4679 | |
| 4680 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 4681 | |
| 4682 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 4683 | |
| 4684 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 4685 | |
| 4686 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4687 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4688 | # Check for unsupported systems |
| 4689 | case $ac_sys_system/$ac_sys_release in |
| 4690 | atheos*|Linux*/1*) |
| 4691 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 4692 | echo See README for details. |
| 4693 | exit 1;; |
| 4694 | esac |
| 4695 | |
| 4696 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4697 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 4698 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4699 | |
| 4700 | # Check whether --with-suffix was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4701 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4702 | withval=$with_suffix; |
| 4703 | case $withval in |
| 4704 | no) EXEEXT=;; |
| 4705 | yes) EXEEXT=.exe;; |
| 4706 | *) EXEEXT=$withval;; |
| 4707 | esac |
| 4708 | fi |
| 4709 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 4711 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4712 | |
| 4713 | # Test whether we're running on a non-case-sensitive system, in which |
| 4714 | # case we give a warning if no ext is given |
| 4715 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4716 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 4717 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4718 | if test ! -d CaseSensitiveTestDir; then |
| 4719 | mkdir CaseSensitiveTestDir |
| 4720 | fi |
| 4721 | |
| 4722 | if test -d casesensitivetestdir |
| 4723 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4724 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4725 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4726 | BUILDEXEEXT=.exe |
| 4727 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4728 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4729 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4730 | BUILDEXEEXT=$EXEEXT |
| 4731 | fi |
| 4732 | rmdir CaseSensitiveTestDir |
| 4733 | |
| 4734 | case $MACHDEP in |
| 4735 | bsdos*) |
| 4736 | case $CC in |
| 4737 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 4738 | esac;; |
| 4739 | esac |
| 4740 | |
| 4741 | case $ac_sys_system in |
| 4742 | hp*|HP*) |
| 4743 | case $CC in |
| 4744 | cc|*/cc) CC="$CC -Ae";; |
| 4745 | esac;; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4746 | SunOS*) |
| 4747 | # Some functions have a prototype only with that define, e.g. confstr |
| 4748 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4749 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4750 | |
| 4751 | ;; |
| 4752 | esac |
| 4753 | |
| 4754 | |
| 4755 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4756 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 4757 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4758 | if test -z "$LIBRARY" |
| 4759 | then |
| 4760 | LIBRARY='libpython$(VERSION).a' |
| 4761 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4762 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 4763 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4764 | |
| 4765 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 4766 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 4767 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 4768 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 4769 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 4770 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 4771 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 4772 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 4773 | # |
| 4774 | # RUNSHARED is used to run shared python without installed libraries |
| 4775 | # |
| 4776 | # INSTSONAME is the name of the shared library that will be use to install |
| 4777 | # on the system - some systems like version suffix, others don't |
| 4778 | |
| 4779 | |
| 4780 | |
| 4781 | |
| 4782 | |
| 4783 | |
| 4784 | LDLIBRARY="$LIBRARY" |
| 4785 | BLDLIBRARY='$(LDLIBRARY)' |
| 4786 | INSTSONAME='$(LDLIBRARY)' |
| 4787 | DLLLIBRARY='' |
| 4788 | LDLIBRARYDIR='' |
| 4789 | RUNSHARED='' |
| 4790 | |
| 4791 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 4792 | # If CXX is set, and if it is needed to link a main function that was |
| 4793 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 4794 | # python might then depend on the C++ runtime |
| 4795 | # This is altered for AIX in order to build the export list before |
| 4796 | # linking. |
| 4797 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4798 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 4799 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4800 | if test -z "$LINKCC" |
| 4801 | then |
| 4802 | LINKCC='$(PURIFY) $(MAINCC)' |
| 4803 | case $ac_sys_system in |
| 4804 | AIX*) |
| 4805 | exp_extra="\"\"" |
| 4806 | if test $ac_sys_release -ge 5 -o \ |
| 4807 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 4808 | exp_extra="." |
| 4809 | fi |
| 4810 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4811 | QNX*) |
| 4812 | # qcc must be used because the other compilers do not |
| 4813 | # support -N. |
| 4814 | LINKCC=qcc;; |
| 4815 | esac |
| 4816 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 4818 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4819 | |
| 4820 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 4821 | # make sure we default having it set to "no": this is used by |
| 4822 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 4823 | # to linker command lines, and failing to detect GNU ld simply results |
| 4824 | # in the same bahaviour as before. |
| 4825 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4826 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 4827 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4828 | ac_prog=ld |
| 4829 | if test "$GCC" = yes; then |
| 4830 | ac_prog=`$CC -print-prog-name=ld` |
| 4831 | fi |
| 4832 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 4833 | *GNU*) |
| 4834 | GNULD=yes;; |
| 4835 | *) |
| 4836 | GNULD=no;; |
| 4837 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 4839 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4840 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4841 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 4842 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4843 | # Check whether --enable-shared was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4844 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4845 | enableval=$enable_shared; |
| 4846 | fi |
| 4847 | |
| 4848 | |
| 4849 | if test -z "$enable_shared" |
| 4850 | then |
| 4851 | case $ac_sys_system in |
| 4852 | CYGWIN* | atheos*) |
| 4853 | enable_shared="yes";; |
| 4854 | *) |
| 4855 | enable_shared="no";; |
| 4856 | esac |
| 4857 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4858 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 4859 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4860 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4861 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 4862 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4863 | # Check whether --enable-profiling was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4864 | if test "${enable_profiling+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4865 | enableval=$enable_profiling; ac_save_cc="$CC" |
| 4866 | CC="$CC -pg" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4867 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4868 | ac_enable_profiling="no" |
| 4869 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4870 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4871 | /* end confdefs.h. */ |
| 4872 | int main() { return 0; } |
| 4873 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4874 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4875 | ac_enable_profiling="yes" |
| 4876 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4877 | ac_enable_profiling="no" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4878 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4879 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4880 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4881 | fi |
| 4882 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4883 | CC="$ac_save_cc" |
| 4884 | fi |
| 4885 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4886 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_profiling" >&5 |
| 4887 | $as_echo "$ac_enable_profiling" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4888 | |
| 4889 | case "$ac_enable_profiling" in |
| 4890 | "yes") |
| 4891 | BASECFLAGS="-pg $BASECFLAGS" |
| 4892 | LDFLAGS="-pg $LDFLAGS" |
| 4893 | ;; |
| 4894 | esac |
| 4895 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4896 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 4897 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4898 | |
| 4899 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 4900 | # library that we build, but we do not want to link against it (we |
| 4901 | # will find it with a -framework option). For this reason there is an |
| 4902 | # extra variable BLDLIBRARY against which Python and the extension |
| 4903 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 4904 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 4905 | if test "$enable_framework" |
| 4906 | then |
| 4907 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 4908 | RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH" |
| 4909 | BLDLIBRARY='' |
| 4910 | else |
| 4911 | BLDLIBRARY='$(LDLIBRARY)' |
| 4912 | fi |
| 4913 | |
| 4914 | # Other platforms follow |
| 4915 | if test $enable_shared = "yes"; then |
| 4916 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4917 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4918 | |
| 4919 | case $ac_sys_system in |
| 4920 | BeOS*) |
| 4921 | LDLIBRARY='libpython$(VERSION).so' |
| 4922 | ;; |
| 4923 | CYGWIN*) |
| 4924 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4925 | DLLLIBRARY='libpython$(VERSION).dll' |
| 4926 | ;; |
| 4927 | SunOS*) |
| 4928 | LDLIBRARY='libpython$(VERSION).so' |
| 4929 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4930 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4931 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4932 | ;; |
| 4933 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*) |
| 4934 | LDLIBRARY='libpython$(VERSION).so' |
| 4935 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4936 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4937 | case $ac_sys_system in |
| 4938 | FreeBSD*) |
| 4939 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 4940 | ;; |
| 4941 | esac |
| 4942 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4943 | ;; |
| 4944 | hp*|HP*) |
| 4945 | case `uname -m` in |
| 4946 | ia64) |
| 4947 | LDLIBRARY='libpython$(VERSION).so' |
| 4948 | ;; |
| 4949 | *) |
| 4950 | LDLIBRARY='libpython$(VERSION).sl' |
| 4951 | ;; |
| 4952 | esac |
| 4953 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4954 | RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH} |
| 4955 | ;; |
| 4956 | OSF*) |
| 4957 | LDLIBRARY='libpython$(VERSION).so' |
| 4958 | BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)' |
| 4959 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4960 | ;; |
| 4961 | atheos*) |
| 4962 | LDLIBRARY='libpython$(VERSION).so' |
| 4963 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4964 | RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib} |
| 4965 | ;; |
| 4966 | Darwin*) |
| 4967 | LDLIBRARY='libpython$(VERSION).dylib' |
| 4968 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4969 | RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}' |
| 4970 | ;; |
| 4971 | |
| 4972 | esac |
| 4973 | else # shared is disabled |
| 4974 | case $ac_sys_system in |
| 4975 | CYGWIN*) |
| 4976 | BLDLIBRARY='$(LIBRARY)' |
| 4977 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4978 | ;; |
| 4979 | esac |
| 4980 | fi |
| 4981 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4982 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 4983 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4984 | |
| 4985 | if test -n "$ac_tool_prefix"; then |
| 4986 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 4987 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 4988 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4989 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4990 | if test "${ac_cv_prog_RANLIB+set}" = set; then : |
| 4991 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 4992 | else |
| 4993 | if test -n "$RANLIB"; then |
| 4994 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 4995 | else |
| 4996 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4997 | for as_dir in $PATH |
| 4998 | do |
| 4999 | IFS=$as_save_IFS |
| 5000 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5001 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5002 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5003 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5004 | $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] | 5005 | break 2 |
| 5006 | fi |
| 5007 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5008 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5009 | IFS=$as_save_IFS |
| 5010 | |
| 5011 | fi |
| 5012 | fi |
| 5013 | RANLIB=$ac_cv_prog_RANLIB |
| 5014 | if test -n "$RANLIB"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5015 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 5016 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5017 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5018 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5019 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5020 | fi |
| 5021 | |
| 5022 | |
| 5023 | fi |
| 5024 | if test -z "$ac_cv_prog_RANLIB"; then |
| 5025 | ac_ct_RANLIB=$RANLIB |
| 5026 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 5027 | set dummy ranlib; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5028 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5029 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5030 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : |
| 5031 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5032 | else |
| 5033 | if test -n "$ac_ct_RANLIB"; then |
| 5034 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5035 | else |
| 5036 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5037 | for as_dir in $PATH |
| 5038 | do |
| 5039 | IFS=$as_save_IFS |
| 5040 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5041 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5042 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5043 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5044 | $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] | 5045 | break 2 |
| 5046 | fi |
| 5047 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5048 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5049 | IFS=$as_save_IFS |
| 5050 | |
| 5051 | fi |
| 5052 | fi |
| 5053 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5054 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5056 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5057 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5058 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5059 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5060 | fi |
| 5061 | |
| 5062 | if test "x$ac_ct_RANLIB" = x; then |
| 5063 | RANLIB=":" |
| 5064 | else |
| 5065 | case $cross_compiling:$ac_tool_warned in |
| 5066 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5067 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5068 | $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] | 5069 | ac_tool_warned=yes ;; |
| 5070 | esac |
| 5071 | RANLIB=$ac_ct_RANLIB |
| 5072 | fi |
| 5073 | else |
| 5074 | RANLIB="$ac_cv_prog_RANLIB" |
| 5075 | fi |
| 5076 | |
| 5077 | |
| 5078 | for ac_prog in ar aal |
| 5079 | do |
| 5080 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5081 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5082 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5083 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5084 | if test "${ac_cv_prog_AR+set}" = set; then : |
| 5085 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5086 | else |
| 5087 | if test -n "$AR"; then |
| 5088 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5089 | else |
| 5090 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5091 | for as_dir in $PATH |
| 5092 | do |
| 5093 | IFS=$as_save_IFS |
| 5094 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5095 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5096 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5097 | ac_cv_prog_AR="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5098 | $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] | 5099 | break 2 |
| 5100 | fi |
| 5101 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5102 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5103 | IFS=$as_save_IFS |
| 5104 | |
| 5105 | fi |
| 5106 | fi |
| 5107 | AR=$ac_cv_prog_AR |
| 5108 | if test -n "$AR"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5109 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5110 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5111 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5112 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5113 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5114 | fi |
| 5115 | |
| 5116 | |
| 5117 | test -n "$AR" && break |
| 5118 | done |
| 5119 | test -n "$AR" || AR="ar" |
| 5120 | |
| 5121 | |
| 5122 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5123 | |
| 5124 | if test -z "$ARFLAGS" |
| 5125 | then |
| 5126 | ARFLAGS="rc" |
| 5127 | fi |
| 5128 | |
| 5129 | |
| 5130 | # Extract the first word of "svnversion", so it can be a program name with args. |
| 5131 | set dummy svnversion; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5132 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5133 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5134 | if test "${ac_cv_prog_SVNVERSION+set}" = set; then : |
| 5135 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5136 | else |
| 5137 | if test -n "$SVNVERSION"; then |
| 5138 | ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test. |
| 5139 | else |
| 5140 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5141 | for as_dir in $PATH |
| 5142 | do |
| 5143 | IFS=$as_save_IFS |
| 5144 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5145 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5146 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5147 | ac_cv_prog_SVNVERSION="found" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5148 | $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] | 5149 | break 2 |
| 5150 | fi |
| 5151 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5152 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5153 | IFS=$as_save_IFS |
| 5154 | |
| 5155 | test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found" |
| 5156 | fi |
| 5157 | fi |
| 5158 | SVNVERSION=$ac_cv_prog_SVNVERSION |
| 5159 | if test -n "$SVNVERSION"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5160 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SVNVERSION" >&5 |
| 5161 | $as_echo "$SVNVERSION" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5162 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5163 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5164 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5165 | fi |
| 5166 | |
| 5167 | |
| 5168 | if test $SVNVERSION = found |
| 5169 | then |
| 5170 | SVNVERSION="svnversion \$(srcdir)" |
| 5171 | else |
| 5172 | SVNVERSION="echo Unversioned directory" |
| 5173 | fi |
| 5174 | |
| 5175 | case $MACHDEP in |
| 5176 | bsdos*|hp*|HP*) |
| 5177 | # install -d does not work on BSDI or HP-UX |
| 5178 | if test -z "$INSTALL" |
| 5179 | then |
| 5180 | INSTALL="${srcdir}/install-sh -c" |
| 5181 | fi |
| 5182 | esac |
| 5183 | ac_aux_dir= |
| 5184 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5185 | for ac_t in install-sh install.sh shtool; do |
| 5186 | if test -f "$ac_dir/$ac_t"; then |
| 5187 | ac_aux_dir=$ac_dir |
| 5188 | ac_install_sh="$ac_aux_dir/$ac_t -c" |
| 5189 | break 2 |
| 5190 | fi |
| 5191 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5192 | done |
| 5193 | if test -z "$ac_aux_dir"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5194 | 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] | 5195 | fi |
| 5196 | |
| 5197 | # These three variables are undocumented and unsupported, |
| 5198 | # and are intended to be withdrawn in a future Autoconf release. |
| 5199 | # They can cause serious problems if a builder's source tree is in a directory |
| 5200 | # whose full name contains unusual characters. |
| 5201 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 5202 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 5203 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 5204 | |
| 5205 | |
| 5206 | # Find a good install program. We prefer a C program (faster), |
| 5207 | # so one script is as good as another. But avoid the broken or |
| 5208 | # incompatible versions: |
| 5209 | # SysV /etc/install, /usr/sbin/install |
| 5210 | # SunOS /usr/etc/install |
| 5211 | # IRIX /sbin/install |
| 5212 | # AIX /bin/install |
| 5213 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 5214 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 5215 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 5216 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 5217 | # OS/2's system install, which has a completely different semantic |
| 5218 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5219 | # Reject install programs that cannot install multiple files. |
| 5220 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 5221 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5222 | if test -z "$INSTALL"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5223 | if test "${ac_cv_path_install+set}" = set; then : |
| 5224 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5225 | else |
| 5226 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5227 | for as_dir in $PATH |
| 5228 | do |
| 5229 | IFS=$as_save_IFS |
| 5230 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5231 | # Account for people who put trailing slashes in PATH elements. |
| 5232 | case $as_dir/ in #(( |
| 5233 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5234 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5235 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5236 | /usr/ucb/* ) ;; |
| 5237 | *) |
| 5238 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 5239 | # Don't use installbsd from OSF since it installs stuff as root |
| 5240 | # by default. |
| 5241 | for ac_prog in ginstall scoinst install; do |
| 5242 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5243 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
| 5244 | if test $ac_prog = install && |
| 5245 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5246 | # AIX install. It has an incompatible calling convention. |
| 5247 | : |
| 5248 | elif test $ac_prog = install && |
| 5249 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5250 | # program-specific install script used by HP pwplus--don't use. |
| 5251 | : |
| 5252 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5253 | rm -rf conftest.one conftest.two conftest.dir |
| 5254 | echo one > conftest.one |
| 5255 | echo two > conftest.two |
| 5256 | mkdir conftest.dir |
| 5257 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 5258 | test -s conftest.one && test -s conftest.two && |
| 5259 | test -s conftest.dir/conftest.one && |
| 5260 | test -s conftest.dir/conftest.two |
| 5261 | then |
| 5262 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 5263 | break 3 |
| 5264 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5265 | fi |
| 5266 | fi |
| 5267 | done |
| 5268 | done |
| 5269 | ;; |
| 5270 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5271 | |
| 5272 | done |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5273 | IFS=$as_save_IFS |
| 5274 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5275 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5276 | |
| 5277 | fi |
| 5278 | if test "${ac_cv_path_install+set}" = set; then |
| 5279 | INSTALL=$ac_cv_path_install |
| 5280 | else |
| 5281 | # As a last resort, use the slow shell script. Don't cache a |
| 5282 | # value for INSTALL within a source directory, because that will |
| 5283 | # break other packages using the cache if that directory is |
| 5284 | # removed, or if the value is a relative name. |
| 5285 | INSTALL=$ac_install_sh |
| 5286 | fi |
| 5287 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5288 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 5289 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5290 | |
| 5291 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 5292 | # It thinks the first close brace ends the variable substitution. |
| 5293 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 5294 | |
| 5295 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 5296 | |
| 5297 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 5298 | |
| 5299 | |
| 5300 | # Not every filesystem supports hard links |
| 5301 | |
| 5302 | if test -z "$LN" ; then |
| 5303 | case $ac_sys_system in |
| 5304 | BeOS*) LN="ln -s";; |
| 5305 | CYGWIN*) LN="ln -s";; |
| 5306 | atheos*) LN="ln -s";; |
| 5307 | *) LN=ln;; |
| 5308 | esac |
| 5309 | fi |
| 5310 | |
| 5311 | # Check for --with-pydebug |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5312 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 5313 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5314 | |
| 5315 | # Check whether --with-pydebug was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5316 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5317 | withval=$with_pydebug; |
| 5318 | if test "$withval" != no |
| 5319 | then |
| 5320 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5321 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5322 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5323 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5324 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5325 | Py_DEBUG='true' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5326 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5327 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5328 | fi |
| 5329 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5330 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5331 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5332 | fi |
| 5333 | |
| 5334 | |
| 5335 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 5336 | # merged with this chunk of code? |
| 5337 | |
| 5338 | # Optimizer/debugger flags |
| 5339 | # ------------------------ |
| 5340 | # (The following bit of code is complicated enough - please keep things |
| 5341 | # indented properly. Just pretend you're editing Python code. ;-) |
| 5342 | |
| 5343 | # There are two parallel sets of case statements below, one that checks to |
| 5344 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 5345 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 5346 | # user set OPT. |
| 5347 | |
| 5348 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 5349 | # it on the command line |
| 5350 | |
Benjamin Peterson | d4b721b | 2010-03-23 20:58:37 +0000 | [diff] [blame] | 5351 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5352 | then |
| 5353 | case $GCC in |
| 5354 | yes) |
| 5355 | if test "$CC" != 'g++' ; then |
| 5356 | STRICT_PROTO="-Wstrict-prototypes" |
| 5357 | fi |
| 5358 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 5359 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 5360 | WRAP="-fwrapv" |
| 5361 | fi |
| 5362 | case $ac_cv_prog_cc_g in |
| 5363 | yes) |
| 5364 | if test "$Py_DEBUG" = 'true' ; then |
| 5365 | # Optimization messes up debuggers, so turn it off for |
| 5366 | # debug builds. |
Mark Dickinson | d2f3e3f | 2010-05-05 22:23:58 +0000 | [diff] [blame] | 5367 | OPT="-g -O0 -Wall $STRICT_PROTO" |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5368 | else |
| 5369 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 5370 | fi |
| 5371 | ;; |
| 5372 | *) |
| 5373 | OPT="-O3 -Wall $STRICT_PROTO" |
| 5374 | ;; |
| 5375 | esac |
| 5376 | case $ac_sys_system in |
| 5377 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 5378 | ;; |
| 5379 | esac |
| 5380 | ;; |
| 5381 | |
| 5382 | *) |
| 5383 | OPT="-O" |
| 5384 | ;; |
| 5385 | esac |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5386 | fi |
| 5387 | |
| 5388 | |
| 5389 | |
| 5390 | # The -arch flags for universal builds on OSX |
| 5391 | UNIVERSAL_ARCH_FLAGS= |
| 5392 | |
| 5393 | |
| 5394 | # tweak BASECFLAGS based on compiler and platform |
| 5395 | case $GCC in |
| 5396 | yes) |
| 5397 | # Python violates C99 rules, by casting between incompatible |
| 5398 | # pointer types. GCC may generate bad code as a result of that, |
| 5399 | # so use -fno-strict-aliasing if supported. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5400 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -fno-strict-aliasing" >&5 |
| 5401 | $as_echo_n "checking whether $CC accepts -fno-strict-aliasing... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5402 | ac_save_cc="$CC" |
| 5403 | CC="$CC -fno-strict-aliasing" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5404 | if test "${ac_cv_no_strict_aliasing_ok+set}" = set; then : |
| 5405 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 5406 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5407 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5408 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5409 | |
| 5410 | int |
| 5411 | main () |
| 5412 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5413 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5414 | ; |
| 5415 | return 0; |
| 5416 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5417 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5418 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5419 | ac_cv_no_strict_aliasing_ok=yes |
| 5420 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5421 | ac_cv_no_strict_aliasing_ok=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5422 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5423 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 5424 | fi |
| 5425 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5426 | CC="$ac_save_cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing_ok" >&5 |
| 5428 | $as_echo "$ac_cv_no_strict_aliasing_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5429 | if test $ac_cv_no_strict_aliasing_ok = yes |
| 5430 | then |
| 5431 | BASECFLAGS="$BASECFLAGS -fno-strict-aliasing" |
| 5432 | fi |
| 5433 | |
| 5434 | # if using gcc on alpha, use -mieee to get (near) full IEEE 754 |
| 5435 | # support. Without this, treatment of subnormals doesn't follow |
| 5436 | # the standard. |
| 5437 | case $ac_sys_machine in |
| 5438 | alpha*) |
| 5439 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5440 | ;; |
| 5441 | esac |
| 5442 | |
| 5443 | case $ac_sys_system in |
| 5444 | SCO_SV*) |
| 5445 | BASECFLAGS="$BASECFLAGS -m486 -DSCO5" |
| 5446 | ;; |
| 5447 | # is there any other compiler on Darwin besides gcc? |
| 5448 | Darwin*) |
| 5449 | # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd |
| 5450 | # used to be here, but non-Apple gcc doesn't accept them. |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5451 | if test "${CC}" = gcc |
| 5452 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5453 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5 |
| 5454 | $as_echo_n "checking which compiler should be used... " >&6; } |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5455 | case "${UNIVERSALSDK}" in |
| 5456 | */MacOSX10.4u.sdk) |
| 5457 | # Build using 10.4 SDK, force usage of gcc when the |
| 5458 | # compiler is gcc, otherwise the user will get very |
| 5459 | # confusing error messages when building on OSX 10.6 |
| 5460 | CC=gcc-4.0 |
| 5461 | CPP=cpp-4.0 |
| 5462 | ;; |
| 5463 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 5465 | $as_echo "$CC" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5466 | fi |
| 5467 | |
| 5468 | # Calculate the right deployment target for this build. |
| 5469 | # |
| 5470 | cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'` |
| 5471 | if test ${cur_target} '>' 10.2; then |
| 5472 | cur_target=10.3 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5473 | if test ${enable_universalsdk}; then |
| 5474 | if test "${UNIVERSAL_ARCHS}" = "all"; then |
| 5475 | # Ensure that the default platform for a |
| 5476 | # 4-way universal build is OSX 10.5, |
| 5477 | # that's the first OS release where |
| 5478 | # 4-way builds make sense. |
| 5479 | cur_target='10.5' |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 5480 | |
| 5481 | elif test "${UNIVERSAL_ARCHS}" = "3-way"; then |
| 5482 | cur_target='10.5' |
| 5483 | |
| 5484 | elif test "${UNIVERSAL_ARCHS}" = "intel"; then |
| 5485 | cur_target='10.5' |
| 5486 | |
| 5487 | elif test "${UNIVERSAL_ARCHS}" = "64-bit"; then |
| 5488 | cur_target='10.5' |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5489 | fi |
| 5490 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 5491 | if test `/usr/bin/arch` = "i386"; then |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 5492 | # On Intel macs default to a deployment |
| 5493 | # target of 10.4, that's the first OSX |
| 5494 | # release with Intel support. |
| 5495 | cur_target="10.4" |
| 5496 | fi |
| 5497 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5498 | fi |
| 5499 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
| 5500 | |
| 5501 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 5502 | # environment with a value that is the same as what we'll use |
| 5503 | # in the Makefile to ensure that we'll get the same compiler |
| 5504 | # environment during configure and build time. |
| 5505 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 5506 | export MACOSX_DEPLOYMENT_TARGET |
| 5507 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 5508 | |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5509 | if test "${enable_universalsdk}"; then |
| 5510 | UNIVERSAL_ARCH_FLAGS="" |
| 5511 | if test "$UNIVERSAL_ARCHS" = "32-bit" ; then |
| 5512 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 5513 | ARCH_RUN_32BIT="" |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 5514 | LIPO_32BIT_FLAGS="" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5515 | |
| 5516 | elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then |
| 5517 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
| 5518 | LIPO_32BIT_FLAGS="" |
| 5519 | ARCH_RUN_32BIT="true" |
| 5520 | |
| 5521 | elif test "$UNIVERSAL_ARCHS" = "all" ; then |
| 5522 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
| 5523 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 92397ce | 2010-01-17 19:32:00 +0000 | [diff] [blame] | 5524 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5525 | |
| 5526 | elif test "$UNIVERSAL_ARCHS" = "intel" ; then |
| 5527 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
| 5528 | LIPO_32BIT_FLAGS="-extract i386" |
Ronald Oussoren | 92397ce | 2010-01-17 19:32:00 +0000 | [diff] [blame] | 5529 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5530 | |
| 5531 | elif test "$UNIVERSAL_ARCHS" = "3-way" ; then |
| 5532 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
| 5533 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 9922f17 | 2010-02-11 13:19:34 +0000 | [diff] [blame] | 5534 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5535 | |
| 5536 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5537 | 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] | 5538 | |
| 5539 | fi |
| 5540 | |
| 5541 | |
Ronald Oussoren | 974eb5e | 2010-04-18 17:59:37 +0000 | [diff] [blame] | 5542 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} ${CFLAGS}" |
| 5543 | if test "${UNIVERSALSDK}" != "/" |
| 5544 | then |
| 5545 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
| 5546 | LDFLAGS="-isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
| 5547 | CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 5548 | fi |
| 5549 | |
| 5550 | fi |
| 5551 | |
| 5552 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5553 | ;; |
| 5554 | OSF*) |
| 5555 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5556 | ;; |
| 5557 | esac |
| 5558 | ;; |
| 5559 | |
| 5560 | *) |
| 5561 | case $ac_sys_system in |
| 5562 | OpenUNIX*|UnixWare*) |
| 5563 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 5564 | ;; |
| 5565 | OSF*) |
| 5566 | BASECFLAGS="$BASECFLAGS -ieee -std" |
| 5567 | ;; |
| 5568 | SCO_SV*) |
| 5569 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 5570 | ;; |
| 5571 | esac |
| 5572 | ;; |
| 5573 | esac |
| 5574 | |
| 5575 | if test "$Py_DEBUG" = 'true'; then |
| 5576 | : |
| 5577 | else |
| 5578 | OPT="-DNDEBUG $OPT" |
| 5579 | fi |
| 5580 | |
| 5581 | if test "$ac_arch_flags" |
| 5582 | then |
| 5583 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 5584 | fi |
| 5585 | |
| 5586 | # disable check for icc since it seems to pass, but generates a warning |
| 5587 | if test "$CC" = icc |
| 5588 | then |
| 5589 | ac_cv_opt_olimit_ok=no |
| 5590 | fi |
| 5591 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5592 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -OPT:Olimit=0" >&5 |
| 5593 | $as_echo_n "checking whether $CC accepts -OPT:Olimit=0... " >&6; } |
| 5594 | if test "${ac_cv_opt_olimit_ok+set}" = set; then : |
| 5595 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5596 | else |
| 5597 | ac_save_cc="$CC" |
| 5598 | CC="$CC -OPT:Olimit=0" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5599 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5600 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5601 | |
| 5602 | int |
| 5603 | main () |
| 5604 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5605 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5606 | ; |
| 5607 | return 0; |
| 5608 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5609 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5610 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5611 | ac_cv_opt_olimit_ok=yes |
| 5612 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5613 | ac_cv_opt_olimit_ok=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5614 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5615 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5616 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5617 | CC="$ac_save_cc" |
| 5618 | fi |
| 5619 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5620 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_opt_olimit_ok" >&5 |
| 5621 | $as_echo "$ac_cv_opt_olimit_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5622 | if test $ac_cv_opt_olimit_ok = yes; then |
| 5623 | case $ac_sys_system in |
| 5624 | # XXX is this branch needed? On MacOSX 10.2.2 the result of the |
| 5625 | # olimit_ok test is "no". Is it "yes" in some other Darwin-esque |
| 5626 | # environment? |
| 5627 | Darwin*) |
| 5628 | ;; |
| 5629 | *) |
| 5630 | BASECFLAGS="$BASECFLAGS -OPT:Olimit=0" |
| 5631 | ;; |
| 5632 | esac |
| 5633 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5634 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Olimit 1500" >&5 |
| 5635 | $as_echo_n "checking whether $CC accepts -Olimit 1500... " >&6; } |
| 5636 | if test "${ac_cv_olimit_ok+set}" = set; then : |
| 5637 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5638 | else |
| 5639 | ac_save_cc="$CC" |
| 5640 | CC="$CC -Olimit 1500" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5641 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5642 | /* end confdefs.h. */ |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5643 | |
| 5644 | int |
| 5645 | main () |
| 5646 | { |
Mark Dickinson | 5e13e29 | 2010-05-11 08:55:06 +0000 | [diff] [blame] | 5647 | |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5648 | ; |
| 5649 | return 0; |
| 5650 | } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5651 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5652 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5653 | ac_cv_olimit_ok=yes |
| 5654 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5655 | ac_cv_olimit_ok=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5656 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5657 | fi |
Gregory P. Smith | 373469a | 2009-11-01 21:03:38 +0000 | [diff] [blame] | 5658 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5659 | CC="$ac_save_cc" |
| 5660 | fi |
| 5661 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5662 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_olimit_ok" >&5 |
| 5663 | $as_echo "$ac_cv_olimit_ok" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5664 | if test $ac_cv_olimit_ok = yes; then |
| 5665 | BASECFLAGS="$BASECFLAGS -Olimit 1500" |
| 5666 | fi |
| 5667 | fi |
| 5668 | |
| 5669 | # Check whether GCC supports PyArg_ParseTuple format |
| 5670 | if test "$GCC" = "yes" |
| 5671 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc supports ParseTuple __format__" >&5 |
| 5673 | $as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5674 | save_CFLAGS=$CFLAGS |
| 5675 | CFLAGS="$CFLAGS -Werror" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5676 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5677 | /* end confdefs.h. */ |
| 5678 | |
| 5679 | void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2))); |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5680 | int |
| 5681 | main () |
| 5682 | { |
| 5683 | |
| 5684 | ; |
| 5685 | return 0; |
| 5686 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5687 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5688 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5689 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5690 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5691 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5692 | $as_echo "#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1" >>confdefs.h |
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 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5695 | $as_echo "yes" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5696 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5697 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 5698 | |
| 5699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5700 | $as_echo "no" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5701 | |
| 5702 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5703 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5704 | CFLAGS=$save_CFLAGS |
| 5705 | fi |
| 5706 | |
| 5707 | # On some compilers, pthreads are available without further options |
| 5708 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 5709 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 5710 | # So we have to see first whether pthreads are available without |
| 5711 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5712 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 5713 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
| 5714 | if test "${ac_cv_pthread_is_default+set}" = set; then : |
| 5715 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5716 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5717 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5718 | ac_cv_pthread_is_default=no |
| 5719 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5720 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5721 | /* end confdefs.h. */ |
| 5722 | |
| 5723 | #include <pthread.h> |
| 5724 | |
| 5725 | void* routine(void* p){return NULL;} |
| 5726 | |
| 5727 | int main(){ |
| 5728 | pthread_t p; |
| 5729 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5730 | return 1; |
| 5731 | (void)pthread_detach(p); |
| 5732 | return 0; |
| 5733 | } |
| 5734 | |
| 5735 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5736 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5737 | |
| 5738 | ac_cv_pthread_is_default=yes |
| 5739 | ac_cv_kthread=no |
| 5740 | ac_cv_pthread=no |
| 5741 | |
| 5742 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5743 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5744 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5745 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5746 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5747 | fi |
| 5748 | |
| 5749 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5750 | fi |
| 5751 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5752 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 5753 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5754 | |
| 5755 | |
| 5756 | if test $ac_cv_pthread_is_default = yes |
| 5757 | then |
| 5758 | ac_cv_kpthread=no |
| 5759 | else |
| 5760 | # -Kpthread, if available, provides the right #defines |
| 5761 | # and linker options to make pthread_create available |
| 5762 | # Some compilers won't report that they do not support -Kpthread, |
| 5763 | # so we need to run a program to see whether it really made the |
| 5764 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5765 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 5766 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
| 5767 | if test "${ac_cv_kpthread+set}" = set; then : |
| 5768 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5769 | else |
| 5770 | ac_save_cc="$CC" |
| 5771 | CC="$CC -Kpthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5772 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5773 | ac_cv_kpthread=no |
| 5774 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5775 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5776 | /* end confdefs.h. */ |
| 5777 | |
| 5778 | #include <pthread.h> |
| 5779 | |
| 5780 | void* routine(void* p){return NULL;} |
| 5781 | |
| 5782 | int main(){ |
| 5783 | pthread_t p; |
| 5784 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5785 | return 1; |
| 5786 | (void)pthread_detach(p); |
| 5787 | return 0; |
| 5788 | } |
| 5789 | |
| 5790 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5791 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5792 | ac_cv_kpthread=yes |
| 5793 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5794 | ac_cv_kpthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5795 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5796 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5797 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5798 | fi |
| 5799 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5800 | CC="$ac_save_cc" |
| 5801 | fi |
| 5802 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5803 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 5804 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5805 | fi |
| 5806 | |
| 5807 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 5808 | then |
| 5809 | # -Kthread, if available, provides the right #defines |
| 5810 | # and linker options to make pthread_create available |
| 5811 | # Some compilers won't report that they do not support -Kthread, |
| 5812 | # so we need to run a program to see whether it really made the |
| 5813 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5814 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 5815 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
| 5816 | if test "${ac_cv_kthread+set}" = set; then : |
| 5817 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5818 | else |
| 5819 | ac_save_cc="$CC" |
| 5820 | CC="$CC -Kthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5821 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5822 | ac_cv_kthread=no |
| 5823 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5824 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5825 | /* end confdefs.h. */ |
| 5826 | |
| 5827 | #include <pthread.h> |
| 5828 | |
| 5829 | void* routine(void* p){return NULL;} |
| 5830 | |
| 5831 | int main(){ |
| 5832 | pthread_t p; |
| 5833 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5834 | return 1; |
| 5835 | (void)pthread_detach(p); |
| 5836 | return 0; |
| 5837 | } |
| 5838 | |
| 5839 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5840 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5841 | ac_cv_kthread=yes |
| 5842 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5843 | ac_cv_kthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5844 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5845 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5846 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5847 | fi |
| 5848 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5849 | CC="$ac_save_cc" |
| 5850 | fi |
| 5851 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5852 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 5853 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5854 | fi |
| 5855 | |
| 5856 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 5857 | then |
| 5858 | # -pthread, if available, provides the right #defines |
| 5859 | # and linker options to make pthread_create available |
| 5860 | # Some compilers won't report that they do not support -pthread, |
| 5861 | # so we need to run a program to see whether it really made the |
| 5862 | # function available. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5863 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 5864 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
| 5865 | if test "${ac_cv_thread+set}" = set; then : |
| 5866 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5867 | else |
| 5868 | ac_save_cc="$CC" |
| 5869 | CC="$CC -pthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5870 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5871 | ac_cv_pthread=no |
| 5872 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5873 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5874 | /* end confdefs.h. */ |
| 5875 | |
| 5876 | #include <pthread.h> |
| 5877 | |
| 5878 | void* routine(void* p){return NULL;} |
| 5879 | |
| 5880 | int main(){ |
| 5881 | pthread_t p; |
| 5882 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5883 | return 1; |
| 5884 | (void)pthread_detach(p); |
| 5885 | return 0; |
| 5886 | } |
| 5887 | |
| 5888 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5889 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5890 | ac_cv_pthread=yes |
| 5891 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5892 | ac_cv_pthread=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5893 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5894 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5895 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5896 | fi |
| 5897 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5898 | CC="$ac_save_cc" |
| 5899 | fi |
| 5900 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 5902 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5903 | fi |
| 5904 | |
| 5905 | # If we have set a CC compiler flag for thread support then |
| 5906 | # check if it works for CXX, too. |
| 5907 | ac_cv_cxx_thread=no |
| 5908 | if test ! -z "$CXX" |
| 5909 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5910 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 5911 | $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] | 5912 | ac_save_cxx="$CXX" |
| 5913 | |
| 5914 | if test "$ac_cv_kpthread" = "yes" |
| 5915 | then |
| 5916 | CXX="$CXX -Kpthread" |
| 5917 | ac_cv_cxx_thread=yes |
| 5918 | elif test "$ac_cv_kthread" = "yes" |
| 5919 | then |
| 5920 | CXX="$CXX -Kthread" |
| 5921 | ac_cv_cxx_thread=yes |
| 5922 | elif test "$ac_cv_pthread" = "yes" |
| 5923 | then |
| 5924 | CXX="$CXX -pthread" |
| 5925 | ac_cv_cxx_thread=yes |
| 5926 | fi |
| 5927 | |
| 5928 | if test $ac_cv_cxx_thread = yes |
| 5929 | then |
| 5930 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 5931 | $CXX -c conftest.$ac_ext 2>&5 |
| 5932 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 5933 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 5934 | then |
| 5935 | ac_cv_cxx_thread=yes |
| 5936 | else |
| 5937 | ac_cv_cxx_thread=no |
| 5938 | fi |
| 5939 | rm -fr conftest* |
| 5940 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5941 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 5942 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5943 | fi |
| 5944 | CXX="$ac_save_cxx" |
| 5945 | |
| 5946 | |
| 5947 | # checks for header files |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5948 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5949 | $as_echo_n "checking for ANSI C header files... " >&6; } |
| 5950 | if test "${ac_cv_header_stdc+set}" = set; then : |
| 5951 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5952 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5953 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5954 | /* end confdefs.h. */ |
| 5955 | #include <stdlib.h> |
| 5956 | #include <stdarg.h> |
| 5957 | #include <string.h> |
| 5958 | #include <float.h> |
| 5959 | |
| 5960 | int |
| 5961 | main () |
| 5962 | { |
| 5963 | |
| 5964 | ; |
| 5965 | return 0; |
| 5966 | } |
| 5967 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5968 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5969 | ac_cv_header_stdc=yes |
| 5970 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5971 | ac_cv_header_stdc=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5972 | fi |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5973 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5974 | |
| 5975 | if test $ac_cv_header_stdc = yes; then |
| 5976 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5977 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5978 | /* end confdefs.h. */ |
| 5979 | #include <string.h> |
| 5980 | |
| 5981 | _ACEOF |
| 5982 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 5983 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 5984 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5985 | else |
| 5986 | ac_cv_header_stdc=no |
| 5987 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 5988 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5989 | |
| 5990 | fi |
| 5991 | |
| 5992 | if test $ac_cv_header_stdc = yes; then |
| 5993 | # 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] | 5994 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 5995 | /* end confdefs.h. */ |
| 5996 | #include <stdlib.h> |
| 5997 | |
| 5998 | _ACEOF |
| 5999 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6000 | $EGREP "free" >/dev/null 2>&1; then : |
| 6001 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6002 | else |
| 6003 | ac_cv_header_stdc=no |
| 6004 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6005 | rm -f conftest* |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6006 | |
| 6007 | fi |
| 6008 | |
| 6009 | if test $ac_cv_header_stdc = yes; then |
| 6010 | # /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] | 6011 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6012 | : |
| 6013 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6014 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6015 | /* end confdefs.h. */ |
| 6016 | #include <ctype.h> |
| 6017 | #include <stdlib.h> |
| 6018 | #if ((' ' & 0x0FF) == 0x020) |
| 6019 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 6020 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 6021 | #else |
| 6022 | # define ISLOWER(c) \ |
| 6023 | (('a' <= (c) && (c) <= 'i') \ |
| 6024 | || ('j' <= (c) && (c) <= 'r') \ |
| 6025 | || ('s' <= (c) && (c) <= 'z')) |
| 6026 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 6027 | #endif |
| 6028 | |
| 6029 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 6030 | int |
| 6031 | main () |
| 6032 | { |
| 6033 | int i; |
| 6034 | for (i = 0; i < 256; i++) |
| 6035 | if (XOR (islower (i), ISLOWER (i)) |
| 6036 | || toupper (i) != TOUPPER (i)) |
| 6037 | return 2; |
| 6038 | return 0; |
| 6039 | } |
| 6040 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6041 | if ac_fn_c_try_run "$LINENO"; then : |
| 6042 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6043 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6044 | ac_cv_header_stdc=no |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6045 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6046 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6047 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6048 | fi |
| 6049 | |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6050 | fi |
| 6051 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 6053 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6054 | if test $ac_cv_header_stdc = yes; then |
| 6055 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6056 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6057 | |
| 6058 | fi |
| 6059 | |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6060 | for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ |
| 6061 | fcntl.h grp.h \ |
Neal Norwitz | 9fdfaaf | 2008-03-28 05:34:59 +0000 | [diff] [blame] | 6062 | 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] | 6063 | 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] | 6064 | unistd.h utime.h \ |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 6065 | sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \ |
| 6066 | sys/lock.h sys/mkdev.h sys/modem.h \ |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6067 | 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] | 6068 | sys/termio.h sys/time.h \ |
Martin v. Löwis | 0e8bd7e | 2006-06-10 12:23:46 +0000 | [diff] [blame] | 6069 | 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] | 6070 | sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 6071 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6072 | do : |
| 6073 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6074 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
| 6075 | eval as_val=\$$as_ac_Header |
| 6076 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6077 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6078 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6079 | _ACEOF |
| 6080 | |
| 6081 | fi |
| 6082 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6083 | done |
| 6084 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6085 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6086 | 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] | 6087 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 6088 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 6089 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
| 6090 | if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : |
| 6091 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6092 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6093 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6094 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6095 | #include <sys/types.h> |
| 6096 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6097 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6098 | int |
| 6099 | main () |
| 6100 | { |
| 6101 | if ((DIR *) 0) |
| 6102 | return 0; |
| 6103 | ; |
| 6104 | return 0; |
| 6105 | } |
| 6106 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6107 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6108 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6109 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6110 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6111 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6112 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6113 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6114 | eval ac_res=\$$as_ac_Header |
| 6115 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 6116 | $as_echo "$ac_res" >&6; } |
| 6117 | eval as_val=\$$as_ac_Header |
| 6118 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6119 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6120 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6121 | _ACEOF |
| 6122 | |
| 6123 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6124 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6125 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6126 | done |
| 6127 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 6128 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6129 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6130 | $as_echo_n "checking for library containing opendir... " >&6; } |
| 6131 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6132 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6133 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6134 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6135 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6136 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6137 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6138 | /* Override any GCC internal prototype to avoid an error. |
| 6139 | Use char because int might match the return type of a GCC |
| 6140 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6141 | #ifdef __cplusplus |
| 6142 | extern "C" |
| 6143 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6144 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6145 | int |
| 6146 | main () |
| 6147 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6148 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6149 | ; |
| 6150 | return 0; |
| 6151 | } |
| 6152 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6153 | for ac_lib in '' dir; do |
| 6154 | if test -z "$ac_lib"; then |
| 6155 | ac_res="none required" |
| 6156 | else |
| 6157 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6158 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6159 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6160 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6161 | ac_cv_search_opendir=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 6162 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6163 | rm -f core conftest.err conftest.$ac_objext \ |
| 6164 | conftest$ac_exeext |
| 6165 | if test "${ac_cv_search_opendir+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6166 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6167 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6168 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6169 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6170 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6171 | else |
| 6172 | ac_cv_search_opendir=no |
| 6173 | fi |
| 6174 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6175 | LIBS=$ac_func_search_save_LIBS |
| 6176 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6178 | $as_echo "$ac_cv_search_opendir" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6179 | ac_res=$ac_cv_search_opendir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6180 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6181 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6182 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6183 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6184 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6185 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6186 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6187 | $as_echo_n "checking for library containing opendir... " >&6; } |
| 6188 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6189 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6190 | else |
| 6191 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6192 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6193 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6194 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6195 | /* Override any GCC internal prototype to avoid an error. |
| 6196 | Use char because int might match the return type of a GCC |
| 6197 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6198 | #ifdef __cplusplus |
| 6199 | extern "C" |
| 6200 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6201 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6202 | int |
| 6203 | main () |
| 6204 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6205 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6206 | ; |
| 6207 | return 0; |
| 6208 | } |
| 6209 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6210 | for ac_lib in '' x; do |
| 6211 | if test -z "$ac_lib"; then |
| 6212 | ac_res="none required" |
| 6213 | else |
| 6214 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6215 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6216 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6217 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6218 | ac_cv_search_opendir=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 6219 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6220 | rm -f core conftest.err conftest.$ac_objext \ |
| 6221 | conftest$ac_exeext |
| 6222 | if test "${ac_cv_search_opendir+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6223 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 6224 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6225 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6226 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6227 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6228 | else |
| 6229 | ac_cv_search_opendir=no |
| 6230 | fi |
| 6231 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6232 | LIBS=$ac_func_search_save_LIBS |
| 6233 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6234 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6235 | $as_echo "$ac_cv_search_opendir" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6236 | ac_res=$ac_cv_search_opendir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6237 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6238 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6239 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6240 | fi |
| 6241 | |
| 6242 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6243 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6244 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 6245 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
| 6246 | if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then : |
| 6247 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6248 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6249 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6250 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6251 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6252 | int |
| 6253 | main () |
| 6254 | { |
| 6255 | return makedev(0, 0); |
| 6256 | ; |
| 6257 | return 0; |
| 6258 | } |
| 6259 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6260 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6261 | ac_cv_header_sys_types_h_makedev=yes |
| 6262 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6263 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6264 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6265 | rm -f core conftest.err conftest.$ac_objext \ |
| 6266 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6267 | |
| 6268 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6269 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 6270 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6271 | |
| 6272 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6273 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
| 6274 | if test "x$ac_cv_header_sys_mkdev_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6275 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6276 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6277 | |
| 6278 | fi |
| 6279 | |
| 6280 | |
| 6281 | |
| 6282 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6283 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
| 6284 | if test "x$ac_cv_header_sys_sysmacros_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6285 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6286 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6287 | |
| 6288 | fi |
| 6289 | |
| 6290 | |
| 6291 | fi |
| 6292 | fi |
| 6293 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6294 | |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6295 | # On Solaris, term.h requires curses.h |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6296 | for ac_header in term.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6297 | do : |
| 6298 | 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] | 6299 | #ifdef HAVE_CURSES_H |
| 6300 | #include <curses.h> |
| 6301 | #endif |
| 6302 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6303 | " |
| 6304 | if test "x$ac_cv_header_term_h" = x""yes; then : |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6305 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6306 | #define HAVE_TERM_H 1 |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6307 | _ACEOF |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6308 | |
Martin v. Löwis | fd1c69e | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6309 | fi |
| 6310 | |
| 6311 | done |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6312 | |
| 6313 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6314 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6315 | for ac_header in linux/netlink.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6316 | do : |
| 6317 | 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] | 6318 | #ifdef HAVE_ASM_TYPES_H |
| 6319 | #include <asm/types.h> |
| 6320 | #endif |
| 6321 | #ifdef HAVE_SYS_SOCKET_H |
| 6322 | #include <sys/socket.h> |
| 6323 | #endif |
| 6324 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6325 | " |
| 6326 | if test "x$ac_cv_header_linux_netlink_h" = x""yes; then : |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6327 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6328 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6329 | _ACEOF |
| 6330 | |
| 6331 | fi |
| 6332 | |
| 6333 | done |
| 6334 | |
| 6335 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6336 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6337 | was_it_defined=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 6339 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 6340 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6341 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6342 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6343 | |
| 6344 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6345 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6346 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6347 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6348 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6349 | |
| 6350 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6351 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6352 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6353 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6354 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6355 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6356 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 6358 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6359 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6360 | # Check whether using makedev requires defining _OSF_SOURCE |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6361 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 6362 | $as_echo_n "checking for makedev... " >&6; } |
| 6363 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6364 | /* end confdefs.h. */ |
Jesus Cea | 616de77 | 2010-04-28 10:32:30 +0000 | [diff] [blame] | 6365 | |
| 6366 | #if defined(MAJOR_IN_MKDEV) |
| 6367 | #include <sys/mkdev.h> |
| 6368 | #elif defined(MAJOR_IN_SYSMACROS) |
| 6369 | #include <sys/sysmacros.h> |
| 6370 | #else |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6371 | #include <sys/types.h> |
Jesus Cea | 616de77 | 2010-04-28 10:32:30 +0000 | [diff] [blame] | 6372 | #endif |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6373 | int |
| 6374 | main () |
| 6375 | { |
| 6376 | makedev(0, 0) |
| 6377 | ; |
| 6378 | return 0; |
| 6379 | } |
| 6380 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6381 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6382 | ac_cv_has_makedev=yes |
| 6383 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6384 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6385 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6386 | rm -f core conftest.err conftest.$ac_objext \ |
| 6387 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6388 | if test "$ac_cv_has_makedev" = "no"; then |
| 6389 | # 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] | 6390 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6391 | /* end confdefs.h. */ |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6392 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6393 | #define _OSF_SOURCE 1 |
| 6394 | #include <sys/types.h> |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6395 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6396 | int |
| 6397 | main () |
| 6398 | { |
| 6399 | makedev(0, 0) |
| 6400 | ; |
| 6401 | return 0; |
| 6402 | } |
| 6403 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6404 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6405 | ac_cv_has_makedev=yes |
| 6406 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6407 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6408 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6409 | rm -f core conftest.err conftest.$ac_objext \ |
| 6410 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6411 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6412 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6413 | $as_echo "#define _OSF_SOURCE 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6414 | |
| 6415 | fi |
| 6416 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6417 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 6418 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6419 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6420 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6421 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6422 | |
| 6423 | fi |
| 6424 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6425 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 6426 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 6427 | # defined, but the compiler does not support pragma redefine_extname, |
| 6428 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 6429 | # structures (such as rlimit64) without declaring them. As a |
| 6430 | # work-around, disable LFS on such configurations |
| 6431 | |
| 6432 | use_lfs=yes |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6433 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 6434 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 6435 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6436 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6437 | |
| 6438 | #define _LARGEFILE_SOURCE 1 |
| 6439 | #define _FILE_OFFSET_BITS 64 |
| 6440 | #include <sys/resource.h> |
| 6441 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6442 | int |
| 6443 | main () |
| 6444 | { |
| 6445 | struct rlimit foo; |
| 6446 | ; |
| 6447 | return 0; |
| 6448 | } |
| 6449 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6450 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6451 | sol_lfs_bug=no |
| 6452 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6453 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6454 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6455 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6456 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 6457 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6458 | if test "$sol_lfs_bug" = "yes"; then |
| 6459 | use_lfs=no |
| 6460 | fi |
| 6461 | |
| 6462 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6463 | # Two defines needed to enable largefile support on various platforms |
| 6464 | # These may affect some typedefs |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6465 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6466 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6467 | |
| 6468 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6469 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6470 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6471 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6472 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 6473 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 6474 | cat >> confdefs.h <<\EOF |
| 6475 | #if defined(SCO_DS) |
| 6476 | #undef _OFF_T |
| 6477 | #endif |
| 6478 | EOF |
| 6479 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6480 | # Type availability checks |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6481 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
| 6482 | if test "x$ac_cv_type_mode_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6483 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6484 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6485 | |
| 6486 | cat >>confdefs.h <<_ACEOF |
| 6487 | #define mode_t int |
| 6488 | _ACEOF |
| 6489 | |
| 6490 | fi |
| 6491 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6492 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
| 6493 | if test "x$ac_cv_type_off_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6494 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6495 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6496 | |
| 6497 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6498 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6499 | _ACEOF |
| 6500 | |
| 6501 | fi |
| 6502 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6503 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
| 6504 | if test "x$ac_cv_type_pid_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6505 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6506 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6507 | |
| 6508 | cat >>confdefs.h <<_ACEOF |
| 6509 | #define pid_t int |
| 6510 | _ACEOF |
| 6511 | |
| 6512 | fi |
| 6513 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6514 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6515 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | cbf54b1 | 2010-05-08 11:04:18 +0000 | [diff] [blame] | 6516 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6517 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6518 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6519 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
| 6520 | if test "x$ac_cv_type_size_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6521 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6522 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6523 | |
| 6524 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6525 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6526 | _ACEOF |
| 6527 | |
| 6528 | fi |
| 6529 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6530 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 6531 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
| 6532 | if test "${ac_cv_type_uid_t+set}" = set; then : |
| 6533 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6534 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6535 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6536 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6537 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6538 | |
| 6539 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6540 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6541 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6542 | ac_cv_type_uid_t=yes |
| 6543 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6544 | ac_cv_type_uid_t=no |
| 6545 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 6546 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6547 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6548 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 6550 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6551 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6552 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6553 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6554 | |
| 6555 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6556 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6557 | |
| 6558 | fi |
| 6559 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6560 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 6561 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6562 | no|yes) ;; #( |
| 6563 | *) |
| 6564 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6565 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6566 | |
| 6567 | |
| 6568 | cat >>confdefs.h <<_ACEOF |
| 6569 | #define uint32_t $ac_cv_c_uint32_t |
| 6570 | _ACEOF |
| 6571 | ;; |
| 6572 | esac |
| 6573 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6574 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 6575 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6576 | no|yes) ;; #( |
| 6577 | *) |
| 6578 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6579 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6580 | |
| 6581 | |
| 6582 | cat >>confdefs.h <<_ACEOF |
| 6583 | #define uint64_t $ac_cv_c_uint64_t |
| 6584 | _ACEOF |
| 6585 | ;; |
| 6586 | esac |
| 6587 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6588 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 6589 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6590 | no|yes) ;; #( |
| 6591 | *) |
| 6592 | |
| 6593 | cat >>confdefs.h <<_ACEOF |
| 6594 | #define int32_t $ac_cv_c_int32_t |
| 6595 | _ACEOF |
| 6596 | ;; |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6597 | esac |
| 6598 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6599 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 6600 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 6601 | no|yes) ;; #( |
| 6602 | *) |
| 6603 | |
| 6604 | cat >>confdefs.h <<_ACEOF |
| 6605 | #define int64_t $ac_cv_c_int64_t |
| 6606 | _ACEOF |
| 6607 | ;; |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 6608 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6609 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6610 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
| 6611 | if test "x$ac_cv_type_ssize_t" = x""yes; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6612 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6613 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6614 | |
| 6615 | fi |
| 6616 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 6617 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6618 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 6619 | # 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] | 6620 | # The cast to long int works around a bug in the HP C Compiler |
| 6621 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6622 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6623 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6624 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 6625 | $as_echo_n "checking size of int... " >&6; } |
| 6626 | if test "${ac_cv_sizeof_int+set}" = set; then : |
| 6627 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6628 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6629 | 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] | 6630 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6631 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6632 | if test "$ac_cv_type_int" = yes; then |
| 6633 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6634 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6635 | { as_fn_set_status 77 |
| 6636 | as_fn_error "cannot compute sizeof (int) |
| 6637 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6638 | else |
| 6639 | ac_cv_sizeof_int=0 |
| 6640 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6641 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6642 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6643 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6644 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 6645 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6646 | |
| 6647 | |
| 6648 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6649 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6650 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6651 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6652 | |
| 6653 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6654 | # The cast to long int works around a bug in the HP C Compiler |
| 6655 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6656 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6657 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6658 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 6659 | $as_echo_n "checking size of long... " >&6; } |
| 6660 | if test "${ac_cv_sizeof_long+set}" = set; then : |
| 6661 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6662 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6663 | 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] | 6664 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6665 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6666 | if test "$ac_cv_type_long" = yes; then |
| 6667 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6668 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6669 | { as_fn_set_status 77 |
| 6670 | as_fn_error "cannot compute sizeof (long) |
| 6671 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6672 | else |
| 6673 | ac_cv_sizeof_long=0 |
| 6674 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6675 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6676 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6677 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6678 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 6679 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6680 | |
| 6681 | |
| 6682 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6683 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6684 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6685 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6686 | |
| 6687 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6688 | # The cast to long int works around a bug in the HP C Compiler |
| 6689 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6690 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6691 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6692 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 6693 | $as_echo_n "checking size of void *... " >&6; } |
| 6694 | if test "${ac_cv_sizeof_void_p+set}" = set; then : |
| 6695 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6696 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6697 | 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] | 6698 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6699 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6700 | if test "$ac_cv_type_void_p" = yes; then |
| 6701 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6702 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6703 | { as_fn_set_status 77 |
| 6704 | as_fn_error "cannot compute sizeof (void *) |
| 6705 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6706 | else |
| 6707 | ac_cv_sizeof_void_p=0 |
| 6708 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6709 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6710 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6711 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6712 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 6713 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6714 | |
| 6715 | |
| 6716 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6717 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6718 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6719 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6720 | |
| 6721 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6722 | # The cast to long int works around a bug in the HP C Compiler |
| 6723 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6724 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6725 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6726 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 6727 | $as_echo_n "checking size of short... " >&6; } |
| 6728 | if test "${ac_cv_sizeof_short+set}" = set; then : |
| 6729 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6730 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6731 | 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] | 6732 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6733 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6734 | if test "$ac_cv_type_short" = yes; then |
| 6735 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6736 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6737 | { as_fn_set_status 77 |
| 6738 | as_fn_error "cannot compute sizeof (short) |
| 6739 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6740 | else |
| 6741 | ac_cv_sizeof_short=0 |
| 6742 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6743 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6744 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6745 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6746 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 6747 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6748 | |
| 6749 | |
| 6750 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6751 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6752 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6753 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6754 | |
| 6755 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6756 | # The cast to long int works around a bug in the HP C Compiler |
| 6757 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6758 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6759 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6760 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 6761 | $as_echo_n "checking size of float... " >&6; } |
| 6762 | if test "${ac_cv_sizeof_float+set}" = set; then : |
| 6763 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6764 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6765 | 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] | 6766 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6767 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6768 | if test "$ac_cv_type_float" = yes; then |
| 6769 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6770 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6771 | { as_fn_set_status 77 |
| 6772 | as_fn_error "cannot compute sizeof (float) |
| 6773 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6774 | else |
| 6775 | ac_cv_sizeof_float=0 |
| 6776 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6777 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6778 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6779 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 6781 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6782 | |
| 6783 | |
| 6784 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6785 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6786 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6787 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6788 | |
| 6789 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6790 | # The cast to long int works around a bug in the HP C Compiler |
| 6791 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6792 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6793 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6794 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 6795 | $as_echo_n "checking size of double... " >&6; } |
| 6796 | if test "${ac_cv_sizeof_double+set}" = set; then : |
| 6797 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6798 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6799 | 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] | 6800 | |
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 test "$ac_cv_type_double" = yes; then |
| 6803 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6804 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6805 | { as_fn_set_status 77 |
| 6806 | as_fn_error "cannot compute sizeof (double) |
| 6807 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6808 | else |
| 6809 | ac_cv_sizeof_double=0 |
| 6810 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6811 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6812 | |
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 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 6815 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6816 | |
| 6817 | |
| 6818 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6819 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6820 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6821 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6822 | |
| 6823 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6824 | # The cast to long int works around a bug in the HP C Compiler |
| 6825 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6826 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6827 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6828 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 6829 | $as_echo_n "checking size of fpos_t... " >&6; } |
| 6830 | if test "${ac_cv_sizeof_fpos_t+set}" = set; then : |
| 6831 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6832 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6833 | 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] | 6834 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6835 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6836 | if test "$ac_cv_type_fpos_t" = yes; then |
| 6837 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6838 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6839 | { as_fn_set_status 77 |
| 6840 | as_fn_error "cannot compute sizeof (fpos_t) |
| 6841 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6842 | else |
| 6843 | ac_cv_sizeof_fpos_t=0 |
| 6844 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6845 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6846 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6847 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 6849 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6850 | |
| 6851 | |
| 6852 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6853 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6854 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6855 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6856 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6857 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6858 | # The cast to long int works around a bug in the HP C Compiler |
| 6859 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6860 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6861 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6862 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 6863 | $as_echo_n "checking size of size_t... " >&6; } |
| 6864 | if test "${ac_cv_sizeof_size_t+set}" = set; then : |
| 6865 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6866 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6867 | 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] | 6868 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6869 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6870 | if test "$ac_cv_type_size_t" = yes; then |
| 6871 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6872 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6873 | { as_fn_set_status 77 |
| 6874 | as_fn_error "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; } |
| 6898 | if test "${ac_cv_sizeof_pid_t+set}" = set; then : |
| 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;} |
| 6907 | { as_fn_set_status 77 |
| 6908 | as_fn_error "cannot compute sizeof (pid_t) |
| 6909 | See \`config.log' for more details." "$LINENO" 5; }; } |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6910 | else |
| 6911 | ac_cv_sizeof_pid_t=0 |
| 6912 | fi |
| 6913 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6914 | |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6915 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6916 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 6917 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 951cc0f | 2008-01-31 23:08:23 +0000 | [diff] [blame] | 6918 | |
| 6919 | |
| 6920 | |
| 6921 | cat >>confdefs.h <<_ACEOF |
| 6922 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 6923 | _ACEOF |
| 6924 | |
| 6925 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6926 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6927 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 6928 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6929 | have_long_long=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6930 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6931 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6932 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6933 | int |
| 6934 | main () |
| 6935 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6936 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6937 | ; |
| 6938 | return 0; |
| 6939 | } |
| 6940 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6941 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6942 | |
| 6943 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6944 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6945 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6946 | have_long_long=yes |
| 6947 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6948 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6949 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6950 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 6951 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 6952 | if test "$have_long_long" = yes ; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6953 | # The cast to long int works around a bug in the HP C Compiler |
| 6954 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6955 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6956 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6957 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 6958 | $as_echo_n "checking size of long long... " >&6; } |
| 6959 | if test "${ac_cv_sizeof_long_long+set}" = set; then : |
| 6960 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6961 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6962 | 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] | 6963 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6964 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6965 | if test "$ac_cv_type_long_long" = yes; then |
| 6966 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6967 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 6968 | { as_fn_set_status 77 |
| 6969 | as_fn_error "cannot compute sizeof (long long) |
| 6970 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6971 | else |
| 6972 | ac_cv_sizeof_long_long=0 |
| 6973 | fi |
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 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6976 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6977 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 6978 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 6979 | |
| 6980 | |
| 6981 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6982 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6983 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6984 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6985 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6986 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6987 | fi |
| 6988 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6989 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 6990 | $as_echo_n "checking for long double support... " >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6991 | have_long_double=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 6992 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6993 | /* end confdefs.h. */ |
| 6994 | |
| 6995 | int |
| 6996 | main () |
| 6997 | { |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 6998 | long double x; x = (long double)0; |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 6999 | ; |
| 7000 | return 0; |
| 7001 | } |
| 7002 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7003 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7004 | |
| 7005 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7006 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7007 | |
| 7008 | have_long_double=yes |
| 7009 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7010 | fi |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7011 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 7013 | $as_echo "$have_long_double" >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7014 | if test "$have_long_double" = yes ; then |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7015 | # The cast to long int works around a bug in the HP C Compiler |
| 7016 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7017 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7018 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7019 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 7020 | $as_echo_n "checking size of long double... " >&6; } |
| 7021 | if test "${ac_cv_sizeof_long_double+set}" = set; then : |
| 7022 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7023 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7024 | 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] | 7025 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7026 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7027 | if test "$ac_cv_type_long_double" = yes; then |
| 7028 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7029 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7030 | { as_fn_set_status 77 |
| 7031 | as_fn_error "cannot compute sizeof (long double) |
| 7032 | See \`config.log' for more details." "$LINENO" 5; }; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7033 | else |
| 7034 | ac_cv_sizeof_long_double=0 |
| 7035 | fi |
| 7036 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7037 | |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7038 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7039 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 7040 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Mark Dickinson | dc1688a | 2008-06-27 22:20:14 +0000 | [diff] [blame] | 7041 | |
| 7042 | |
| 7043 | |
| 7044 | cat >>confdefs.h <<_ACEOF |
| 7045 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 7046 | _ACEOF |
| 7047 | |
| 7048 | |
| 7049 | fi |
| 7050 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7051 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 7052 | $as_echo_n "checking for _Bool support... " >&6; } |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7053 | have_c99_bool=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7054 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7055 | /* end confdefs.h. */ |
| 7056 | |
| 7057 | int |
| 7058 | main () |
| 7059 | { |
| 7060 | _Bool x; x = (_Bool)0; |
| 7061 | ; |
| 7062 | return 0; |
| 7063 | } |
| 7064 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7065 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7066 | |
| 7067 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7068 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7069 | |
| 7070 | have_c99_bool=yes |
| 7071 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7072 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7073 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7074 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 7075 | $as_echo "$have_c99_bool" >&6; } |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7076 | if test "$have_c99_bool" = yes ; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7077 | # The cast to long int works around a bug in the HP C Compiler |
| 7078 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7079 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7080 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7081 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 7082 | $as_echo_n "checking size of _Bool... " >&6; } |
| 7083 | if test "${ac_cv_sizeof__Bool+set}" = set; then : |
| 7084 | $as_echo_n "(cached) " >&6 |
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 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] | 7087 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7088 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7089 | if test "$ac_cv_type__Bool" = yes; then |
| 7090 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7091 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7092 | { as_fn_set_status 77 |
| 7093 | as_fn_error "cannot compute sizeof (_Bool) |
| 7094 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7095 | else |
| 7096 | ac_cv_sizeof__Bool=0 |
| 7097 | fi |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7098 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7099 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7100 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7101 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 7102 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7103 | |
| 7104 | |
| 7105 | |
Martin v. Löwis | aef4c6b | 2007-01-21 09:33:07 +0000 | [diff] [blame] | 7106 | cat >>confdefs.h <<_ACEOF |
| 7107 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 7108 | _ACEOF |
| 7109 | |
| 7110 | |
| 7111 | fi |
| 7112 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7113 | 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] | 7114 | #include <stdint.h> |
| 7115 | #endif |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7116 | " |
| 7117 | if test "x$ac_cv_type_uintptr_t" = x""yes; then : |
Martin v. Löwis | ebe2670 | 2006-10-02 14:55:51 +0000 | [diff] [blame] | 7118 | |
| 7119 | cat >>confdefs.h <<_ACEOF |
| 7120 | #define HAVE_UINTPTR_T 1 |
| 7121 | _ACEOF |
| 7122 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7123 | # The cast to long int works around a bug in the HP C Compiler |
| 7124 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7125 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7126 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7127 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 7128 | $as_echo_n "checking size of uintptr_t... " >&6; } |
| 7129 | if test "${ac_cv_sizeof_uintptr_t+set}" = set; then : |
| 7130 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7131 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7132 | 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] | 7133 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7134 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7135 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 7136 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7137 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7138 | { as_fn_set_status 77 |
| 7139 | as_fn_error "cannot compute sizeof (uintptr_t) |
| 7140 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7141 | else |
| 7142 | ac_cv_sizeof_uintptr_t=0 |
| 7143 | fi |
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 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7146 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7147 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 7148 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7149 | |
| 7150 | |
| 7151 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7152 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7153 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7154 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7155 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7156 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7157 | fi |
| 7158 | |
Martin v. Löwis | ebe2670 | 2006-10-02 14:55:51 +0000 | [diff] [blame] | 7159 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7160 | # The cast to long int works around a bug in the HP C Compiler |
| 7161 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7162 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7163 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7164 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 7165 | $as_echo_n "checking size of off_t... " >&6; } |
| 7166 | if test "${ac_cv_sizeof_off_t+set}" = set; then : |
| 7167 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7168 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7169 | 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] | 7170 | #ifdef HAVE_SYS_TYPES_H |
| 7171 | #include <sys/types.h> |
| 7172 | #endif |
| 7173 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7174 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7175 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7176 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7177 | if test "$ac_cv_type_off_t" = yes; then |
| 7178 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7179 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7180 | { as_fn_set_status 77 |
| 7181 | as_fn_error "cannot compute sizeof (off_t) |
| 7182 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7183 | else |
| 7184 | ac_cv_sizeof_off_t=0 |
| 7185 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7186 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7187 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7188 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 7190 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7191 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7192 | |
| 7193 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7194 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7195 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7196 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7197 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7198 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7199 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7200 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 7201 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7202 | if test "$have_long_long" = yes |
| 7203 | then |
| 7204 | 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] | 7205 | "$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] | 7206 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7207 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7208 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7210 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7211 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7213 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7214 | fi |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7215 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7216 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7217 | $as_echo "no" >&6; } |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 7218 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7219 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7220 | # The cast to long int works around a bug in the HP C Compiler |
| 7221 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7222 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7223 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7224 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 7225 | $as_echo_n "checking size of time_t... " >&6; } |
| 7226 | if test "${ac_cv_sizeof_time_t+set}" = set; then : |
| 7227 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7228 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7229 | 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] | 7230 | #ifdef HAVE_SYS_TYPES_H |
| 7231 | #include <sys/types.h> |
| 7232 | #endif |
| 7233 | #ifdef HAVE_TIME_H |
| 7234 | #include <time.h> |
| 7235 | #endif |
| 7236 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7237 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7238 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7239 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7240 | if test "$ac_cv_type_time_t" = yes; then |
| 7241 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7242 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7243 | { as_fn_set_status 77 |
| 7244 | as_fn_error "cannot compute sizeof (time_t) |
| 7245 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7246 | else |
| 7247 | ac_cv_sizeof_time_t=0 |
| 7248 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7249 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7250 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7251 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7252 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 7253 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7254 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7255 | |
| 7256 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7257 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7258 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7259 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7260 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7261 | |
| 7262 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7263 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7264 | ac_save_cc="$CC" |
| 7265 | if test "$ac_cv_kpthread" = "yes" |
| 7266 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 7267 | elif test "$ac_cv_kthread" = "yes" |
| 7268 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 7269 | elif test "$ac_cv_pthread" = "yes" |
| 7270 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7271 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7272 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 7273 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7274 | have_pthread_t=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7275 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7276 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 7277 | |
| 7278 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7279 | int |
| 7280 | main () |
| 7281 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 7282 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7283 | ; |
| 7284 | return 0; |
| 7285 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 7286 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7287 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7288 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7289 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7290 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7291 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7292 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 7293 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7294 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7295 | # 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] | 7296 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7297 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7298 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 7300 | $as_echo_n "checking size of pthread_t... " >&6; } |
| 7301 | if test "${ac_cv_sizeof_pthread_t+set}" = set; then : |
| 7302 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7303 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7304 | 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] | 7305 | #ifdef HAVE_PTHREAD_H |
| 7306 | #include <pthread.h> |
| 7307 | #endif |
| 7308 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7309 | "; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7310 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7311 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7312 | if test "$ac_cv_type_pthread_t" = yes; then |
| 7313 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7314 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 7315 | { as_fn_set_status 77 |
| 7316 | as_fn_error "cannot compute sizeof (pthread_t) |
| 7317 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7318 | else |
| 7319 | ac_cv_sizeof_pthread_t=0 |
| 7320 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7321 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7322 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7323 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7324 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 7325 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7326 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7327 | |
| 7328 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7329 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7330 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7331 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7332 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 7333 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7334 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7335 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7336 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-toolbox-glue" >&5 |
| 7338 | $as_echo_n "checking for --enable-toolbox-glue... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7339 | # Check whether --enable-toolbox-glue was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7340 | if test "${enable_toolbox_glue+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7341 | enableval=$enable_toolbox_glue; |
| 7342 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7343 | |
| 7344 | |
| 7345 | if test -z "$enable_toolbox_glue" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7346 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7347 | case $ac_sys_system/$ac_sys_release in |
| 7348 | Darwin/*) |
| 7349 | enable_toolbox_glue="yes";; |
| 7350 | *) |
| 7351 | enable_toolbox_glue="no";; |
| 7352 | esac |
| 7353 | fi |
| 7354 | case "$enable_toolbox_glue" in |
| 7355 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7356 | extra_machdep_objs="Python/mactoolboxglue.o" |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7357 | extra_undefs="-u _PyMac_Error" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7358 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7359 | $as_echo "#define USE_TOOLBOX_OBJECT_GLUE 1" >>confdefs.h |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7360 | |
| 7361 | ;; |
| 7362 | *) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7363 | extra_machdep_objs="" |
Jack Jansen | 591cbed | 2001-08-15 13:55:15 +0000 | [diff] [blame] | 7364 | extra_undefs="" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7365 | ;; |
| 7366 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7367 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_toolbox_glue" >&5 |
| 7368 | $as_echo "$enable_toolbox_glue" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7369 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7370 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 7371 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7372 | case $ac_sys_system/$ac_sys_release in |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 7373 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7374 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 7375 | ;; |
| 7376 | Darwin/*) |
| 7377 | OTHER_LIBTOOL_OPT="" |
| 7378 | ;; |
| 7379 | esac |
| 7380 | |
| 7381 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7382 | ARCH_RUN_32BIT="" |
| 7383 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7384 | case $ac_sys_system/$ac_sys_release in |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 7385 | Darwin/[01567]\..*) |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7386 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 7387 | if test "${enable_universalsdk}"; then |
| 7388 | : |
| 7389 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7390 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7391 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7392 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7393 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 7394 | Darwin/*) |
Ronald Oussoren | a55af9a | 2010-01-17 16:25:57 +0000 | [diff] [blame] | 7395 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7396 | if test ${gcc_version} '<' 4.0 |
| 7397 | then |
| 7398 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 7399 | else |
| 7400 | LIBTOOL_CRUFT="" |
| 7401 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7402 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7403 | ac_osx_32bit=yes |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7404 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7405 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7406 | /* end confdefs.h. */ |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7407 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7408 | #include <unistd.h> |
| 7409 | int main(int argc, char*argv[]) |
| 7410 | { |
| 7411 | if (sizeof(long) == 4) { |
| 7412 | return 0; |
| 7413 | } else { |
| 7414 | return 1; |
| 7415 | } |
Ronald Oussoren | 84ddd72 | 2009-09-08 07:17:10 +0000 | [diff] [blame] | 7416 | } |
Ronald Oussoren | 23d9253 | 2009-09-07 06:12:00 +0000 | [diff] [blame] | 7417 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7418 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7419 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7420 | ac_osx_32bit=yes |
| 7421 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7422 | ac_osx_32bit=no |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7423 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7424 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7425 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7426 | fi |
| 7427 | |
| 7428 | |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7429 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7430 | case `/usr/bin/arch` in |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7431 | i386) |
| 7432 | MACOSX_DEFAULT_ARCH="i386" |
| 7433 | ;; |
| 7434 | ppc) |
| 7435 | MACOSX_DEFAULT_ARCH="ppc" |
| 7436 | ;; |
| 7437 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7438 | as_fn_error "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7439 | ;; |
| 7440 | esac |
| 7441 | else |
Ronald Oussoren | bc0e83c | 2010-02-11 13:26:54 +0000 | [diff] [blame] | 7442 | case `/usr/bin/arch` in |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7443 | i386) |
| 7444 | MACOSX_DEFAULT_ARCH="x86_64" |
| 7445 | ;; |
| 7446 | ppc) |
| 7447 | MACOSX_DEFAULT_ARCH="ppc64" |
| 7448 | ;; |
| 7449 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7450 | as_fn_error "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 2596758 | 2009-09-06 10:00:26 +0000 | [diff] [blame] | 7451 | ;; |
| 7452 | esac |
| 7453 | |
| 7454 | #ARCH_RUN_32BIT="true" |
| 7455 | fi |
| 7456 | |
| 7457 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7458 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7459 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7460 | esac |
| 7461 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7462 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 7463 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7464 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7465 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 7466 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7467 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7468 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7469 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7470 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7471 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7472 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7473 | $as_echo "yes" >&6; } |
Ronald Oussoren | 450d561 | 2009-06-08 21:12:41 +0000 | [diff] [blame] | 7474 | if test $enable_shared = "yes" |
| 7475 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7476 | 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] | 7477 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7478 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7479 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7480 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7481 | fi |
| 7482 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7483 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 7484 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7485 | case $ac_sys_system/$ac_sys_release in |
| 7486 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7487 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7488 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7489 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7490 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 7491 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7492 | ;; |
| 7493 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7494 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7495 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7496 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7497 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7498 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7499 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7500 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7501 | |
| 7502 | |
| 7503 | |
| 7504 | |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7505 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7506 | # SO is the extension of shared libraries `(including the dot!) |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 7507 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7508 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5 |
| 7509 | $as_echo_n "checking SO... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7510 | if test -z "$SO" |
| 7511 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7512 | case $ac_sys_system in |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7513 | hp*|HP*) |
| 7514 | case `uname -m` in |
| 7515 | ia64) SO=.so;; |
| 7516 | *) SO=.sl;; |
| 7517 | esac |
| 7518 | ;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 7519 | CYGWIN*) SO=.dll;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 7520 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7521 | esac |
Martin v. Löwis | 368de8f | 2003-06-14 14:46:38 +0000 | [diff] [blame] | 7522 | else |
| 7523 | # this might also be a termcap variable, see #610332 |
| 7524 | echo |
| 7525 | echo '=====================================================================' |
| 7526 | echo '+ +' |
| 7527 | echo '+ WARNING: You have set SO in your environment. +' |
| 7528 | echo '+ Do you really mean to change the extension for shared libraries? +' |
| 7529 | echo '+ Continuing in 10 seconds to let you to ponder. +' |
| 7530 | echo '+ +' |
| 7531 | echo '=====================================================================' |
| 7532 | sleep 10 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7533 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7534 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5 |
| 7535 | $as_echo "$SO" >&6; } |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7536 | |
Ronald Oussoren | 79f9049 | 2009-01-02 10:44:46 +0000 | [diff] [blame] | 7537 | |
Neal Norwitz | 58e2888 | 2006-05-19 07:00:58 +0000 | [diff] [blame] | 7538 | cat >>confdefs.h <<_ACEOF |
| 7539 | #define SHLIB_EXT "$SO" |
| 7540 | _ACEOF |
| 7541 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7542 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 7543 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7544 | # (Shared libraries in this instance are shared modules to be loaded into |
| 7545 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 7547 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7548 | if test -z "$LDSHARED" |
| 7549 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7550 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7551 | AIX*) |
| 7552 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 7553 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7554 | ;; |
| 7555 | BeOS*) |
| 7556 | BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 7557 | LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7558 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7559 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7560 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7561 | SunOS/5*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7562 | if test "$GCC" = "yes" ; then |
| 7563 | LDSHARED='$(CC) -shared' |
| 7564 | LDCXXSHARED='$(CXX) -shared' |
| 7565 | else |
| 7566 | LDSHARED='$(CC) -G' |
| 7567 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a66 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 7568 | fi ;; |
Thomas Heller | dc96a77 | 2008-04-04 10:07:55 +0000 | [diff] [blame] | 7569 | hp*|HP*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7570 | if test "$GCC" = "yes" ; then |
| 7571 | LDSHARED='$(CC) -shared' |
| 7572 | LDCXXSHARED='$(CXX) -shared' |
| 7573 | else |
| 7574 | LDSHARED='ld -b' |
Thomas Heller | dc96a77 | 2008-04-04 10:07:55 +0000 | [diff] [blame] | 7575 | fi ;; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7576 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7577 | Darwin/1.3*) |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7578 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7579 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7580 | if test "$enable_framework" ; then |
| 7581 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7582 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7583 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7584 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7585 | else |
| 7586 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7587 | LDSHARED="$LDSHARED -undefined suppress" |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7588 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7589 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7590 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7591 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7592 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7593 | if test "$enable_framework" ; then |
| 7594 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7595 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7596 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7597 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7598 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 7599 | # No framework, use the Python app as bundle-loader |
| 7600 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 7601 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7602 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7603 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7604 | Darwin/*) |
| 7605 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 7606 | # This allows an extension to be used in any Python |
Ronald Oussoren | 38f1b98 | 2007-09-02 09:46:07 +0000 | [diff] [blame] | 7607 | |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 7608 | if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7609 | then |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7610 | if test "${enable_universalsdk}"; then |
Ronald Oussoren | 5640ce2 | 2008-06-05 12:58:24 +0000 | [diff] [blame] | 7611 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Ronald Oussoren | 988117f | 2006-04-29 11:31:35 +0000 | [diff] [blame] | 7612 | fi |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7613 | LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined dynamic_lookup' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7614 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle -undefined dynamic_lookup' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7615 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7616 | else |
| 7617 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7618 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7619 | if test "$enable_framework" ; then |
| 7620 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7621 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7622 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7623 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7624 | else |
| 7625 | # No framework, use the Python app as bundle-loader |
| 7626 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 7627 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7628 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7629 | fi |
| 7630 | fi |
| 7631 | ;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7632 | Linux*|GNU*|QNX*) |
| 7633 | LDSHARED='$(CC) -shared' |
| 7634 | LDCXXSHARED='$(CXX) -shared';; |
| 7635 | BSD/OS*/4*) |
| 7636 | LDSHARED="gcc -shared" |
| 7637 | LDCXXSHARED="g++ -shared";; |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7638 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 7639 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7640 | then |
Benjamin Peterson | 3b2abe9 | 2010-03-14 15:06:14 +0000 | [diff] [blame] | 7641 | LDSHARED='$(CC) -shared ${LDFLAGS}' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7642 | LDCXXSHARED='$(CXX) -shared ${LDFLAGS}' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7643 | else |
| 7644 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7645 | fi;; |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7646 | OpenBSD*) |
| 7647 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7648 | then |
| 7649 | LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7650 | LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7651 | else |
| 7652 | case `uname -r` in |
| 7653 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 7654 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7655 | ;; |
| 7656 | *) |
| 7657 | LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7658 | LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' |
Martin v. Löwis | 222c515 | 2006-06-03 07:37:13 +0000 | [diff] [blame] | 7659 | ;; |
| 7660 | esac |
| 7661 | fi;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7662 | NetBSD*|DragonFly*) |
| 7663 | LDSHARED="cc -shared ${LDFLAGS}" |
| 7664 | LDCXXSHARED="c++ -shared ${LDFLAGS}";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7665 | OpenUNIX*|UnixWare*) |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7666 | if test "$GCC" = "yes" ; then |
| 7667 | LDSHARED='$(CC) -shared' |
| 7668 | LDCXXSHARED='$(CXX) -shared' |
| 7669 | else |
| 7670 | LDSHARED='$(CC) -G' |
| 7671 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7672 | fi;; |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7673 | SCO_SV*) |
| 7674 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 7675 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 7676 | CYGWIN*) |
| 7677 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 7678 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
| 7679 | atheos*) |
| 7680 | LDSHARED="gcc -shared" |
| 7681 | LDCXXSHARED="g++ -shared";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7682 | *) LDSHARED="ld";; |
| 7683 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7684 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 7686 | $as_echo "$LDSHARED" >&6; } |
Ronald Oussoren | 7591285 | 2010-04-08 08:13:31 +0000 | [diff] [blame] | 7687 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7688 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7689 | # 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] | 7690 | # library (module) -- this is only needed for a few systems |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7691 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 7692 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7693 | if test -z "$CCSHARED" |
| 7694 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7695 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7696 | SunOS*) if test "$GCC" = yes; |
Martin v. Löwis | eb62357 | 2007-03-12 10:50:39 +0000 | [diff] [blame] | 7697 | then CCSHARED="-fPIC"; |
| 7698 | elif test `uname -p` = sparc; |
| 7699 | then CCSHARED="-xcode=pic32"; |
| 7700 | else CCSHARED="-Kpic"; |
| 7701 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7702 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 7703 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7704 | else CCSHARED="+z"; |
| 7705 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7706 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7707 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7708 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7709 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7710 | if test "$GCC" = "yes" |
| 7711 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 7712 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7713 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7714 | SCO_SV*) |
| 7715 | if test "$GCC" = "yes" |
| 7716 | then CCSHARED="-fPIC" |
| 7717 | else CCSHARED="-Kpic -belf" |
| 7718 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7719 | IRIX*/6*) case $CC in |
| 7720 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 7721 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7722 | esac;; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7723 | atheos*) CCSHARED="-fPIC";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7724 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7725 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7726 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 7727 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7728 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7729 | # the python executable -- this is only needed for a few systems |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7730 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 7731 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7732 | if test -z "$LINKFORSHARED" |
| 7733 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7734 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7735 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7736 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 7737 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 7738 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7739 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7740 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7741 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7742 | Darwin/*) |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7743 | # -u _PyMac_Error is needed to pull in the mac toolbox glue, |
| 7744 | # which is |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7745 | # not used by the core itself but which needs to be in the core so |
| 7746 | # that dynamically loaded extension modules have access to it. |
Jack Jansen | 97e3f00 | 2003-02-23 22:59:01 +0000 | [diff] [blame] | 7747 | # -prebind is no longer used, because it actually seems to give a |
| 7748 | # slowdown in stead of a speedup, maybe due to the large number of |
| 7749 | # dynamic loads Python does. |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7750 | |
| 7751 | LINKFORSHARED="$extra_undefs" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7752 | if test "$enable_framework" |
| 7753 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7754 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7755 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7756 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7757 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7758 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 7759 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7760 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 7761 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7762 | then |
| 7763 | LINKFORSHARED="-Wl,--export-dynamic" |
| 7764 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7765 | SunOS/5*) case $CC in |
| 7766 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 7767 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 7768 | then |
| 7769 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7770 | fi;; |
| 7771 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 7772 | CYGWIN*) |
| 7773 | if test $enable_shared = "no" |
| 7774 | then |
| 7775 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 7776 | fi;; |
Martin v. Löwis | 8c255e4 | 2008-05-23 15:06:50 +0000 | [diff] [blame] | 7777 | QNX*) |
| 7778 | # -Wl,-E causes the symbols to be added to the dynamic |
| 7779 | # symbol table so that they can be found when a module |
| 7780 | # is loaded. -N 2048K causes the stack size to be set |
| 7781 | # to 2048 kilobytes so that the stack doesn't overflow |
| 7782 | # when running test_compile.py. |
| 7783 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7784 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7785 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7786 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 7787 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7788 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7789 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 7790 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7791 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 7792 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7793 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 7794 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 7795 | case $ac_sys_system in |
| 7796 | CYGWIN*) |
| 7797 | # Cygwin needs CCSHARED when building extension DLLs |
| 7798 | # but not when building the interpreter DLL. |
| 7799 | CFLAGSFORSHARED='';; |
| 7800 | *) |
| 7801 | CFLAGSFORSHARED='$(CCSHARED)' |
| 7802 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7803 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 7805 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7806 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7807 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 7808 | # library (with --enable-shared). |
| 7809 | # 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] | 7810 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 7811 | # if it is not required, since it creates a dependency of the shared library |
| 7812 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 7813 | # don't need to link LIBS explicitly. The default should be only changed |
| 7814 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7815 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7816 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 7817 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7818 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7819 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 7820 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7821 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7822 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 7823 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7824 | |
| 7825 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7826 | # checks for libraries |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7827 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 7828 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
| 7829 | if test "${ac_cv_lib_dl_dlopen+set}" = set; then : |
| 7830 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7831 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7832 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7833 | LIBS="-ldl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7834 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7835 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7836 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7837 | /* Override any GCC internal prototype to avoid an error. |
| 7838 | Use char because int might match the return type of a GCC |
| 7839 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7840 | #ifdef __cplusplus |
| 7841 | extern "C" |
| 7842 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7843 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7844 | int |
| 7845 | main () |
| 7846 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7847 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7848 | ; |
| 7849 | return 0; |
| 7850 | } |
| 7851 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7852 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7853 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7854 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7855 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7856 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7857 | rm -f core conftest.err conftest.$ac_objext \ |
| 7858 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7859 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7860 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 7862 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
| 7863 | if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7864 | cat >>confdefs.h <<_ACEOF |
| 7865 | #define HAVE_LIBDL 1 |
| 7866 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7867 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7868 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7869 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7870 | fi |
| 7871 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7872 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 7873 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
| 7874 | if test "${ac_cv_lib_dld_shl_load+set}" = set; then : |
| 7875 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7876 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7877 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7878 | LIBS="-ldld $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7879 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7880 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7881 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7882 | /* Override any GCC internal prototype to avoid an error. |
| 7883 | Use char because int might match the return type of a GCC |
| 7884 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7885 | #ifdef __cplusplus |
| 7886 | extern "C" |
| 7887 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7888 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7889 | int |
| 7890 | main () |
| 7891 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7892 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7893 | ; |
| 7894 | return 0; |
| 7895 | } |
| 7896 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7897 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7898 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7899 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7900 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7901 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7902 | rm -f core conftest.err conftest.$ac_objext \ |
| 7903 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7904 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7905 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7906 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 7907 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
| 7908 | if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7909 | cat >>confdefs.h <<_ACEOF |
| 7910 | #define HAVE_LIBDLD 1 |
| 7911 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7912 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7913 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7914 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7915 | fi |
| 7916 | # Dynamic linking for HP-UX |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7917 | |
Ronald Oussoren | 79f9049 | 2009-01-02 10:44:46 +0000 | [diff] [blame] | 7918 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7919 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7920 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 7921 | $as_echo_n "checking for library containing sem_init... " >&6; } |
| 7922 | if test "${ac_cv_search_sem_init+set}" = set; then : |
| 7923 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7924 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7925 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7926 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7927 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7928 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7929 | /* Override any GCC internal prototype to avoid an error. |
| 7930 | Use char because int might match the return type of a GCC |
| 7931 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7932 | #ifdef __cplusplus |
| 7933 | extern "C" |
| 7934 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7935 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7936 | int |
| 7937 | main () |
| 7938 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7939 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7940 | ; |
| 7941 | return 0; |
| 7942 | } |
| 7943 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7944 | for ac_lib in '' pthread rt posix4; do |
| 7945 | if test -z "$ac_lib"; then |
| 7946 | ac_res="none required" |
| 7947 | else |
| 7948 | ac_res=-l$ac_lib |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 7949 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7950 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7951 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7952 | ac_cv_search_sem_init=$ac_res |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 7953 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7954 | rm -f core conftest.err conftest.$ac_objext \ |
| 7955 | conftest$ac_exeext |
| 7956 | if test "${ac_cv_search_sem_init+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7957 | break |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 7958 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7959 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7960 | if test "${ac_cv_search_sem_init+set}" = set; then : |
| 7961 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7962 | else |
| 7963 | ac_cv_search_sem_init=no |
| 7964 | fi |
| 7965 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7966 | LIBS=$ac_func_search_save_LIBS |
| 7967 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7968 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 7969 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7970 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7971 | if test "$ac_res" != no; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7972 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7973 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7974 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 7975 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7976 | # posix4 on Solaris 2.6 |
| 7977 | # pthread (first!) on Linux |
| 7978 | fi |
| 7979 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7980 | # check if we need libintl for locale functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7981 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 7982 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
| 7983 | if test "${ac_cv_lib_intl_textdomain+set}" = set; then : |
| 7984 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7985 | else |
| 7986 | ac_check_lib_save_LIBS=$LIBS |
| 7987 | LIBS="-lintl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 7988 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7989 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7990 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 7991 | /* Override any GCC internal prototype to avoid an error. |
| 7992 | Use char because int might match the return type of a GCC |
| 7993 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7994 | #ifdef __cplusplus |
| 7995 | extern "C" |
| 7996 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7997 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7998 | int |
| 7999 | main () |
| 8000 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8001 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8002 | ; |
| 8003 | return 0; |
| 8004 | } |
| 8005 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8006 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8007 | ac_cv_lib_intl_textdomain=yes |
| 8008 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8009 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8010 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8011 | rm -f core conftest.err conftest.$ac_objext \ |
| 8012 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8013 | LIBS=$ac_check_lib_save_LIBS |
| 8014 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8015 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 8016 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
| 8017 | if test "x$ac_cv_lib_intl_textdomain" = x""yes; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8018 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8019 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8020 | |
| 8021 | fi |
| 8022 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8023 | |
| 8024 | # checks for system dependent C++ extensions support |
| 8025 | case "$ac_sys_system" in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8026 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 8027 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 8028 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8029 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8030 | |
| 8031 | #include "/usr/lpp/xlC/include/load.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8032 | int |
| 8033 | main () |
| 8034 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8035 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8036 | ; |
| 8037 | return 0; |
| 8038 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8039 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8040 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8041 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8042 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8043 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8044 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8045 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8047 | $as_echo "yes" >&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 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8050 | |
| 8051 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8052 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 8053 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8054 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8055 | rm -f core conftest.err conftest.$ac_objext \ |
| 8056 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8057 | *) ;; |
| 8058 | esac |
| 8059 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8060 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8061 | # BeOS' sockets are stashed in libnet. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 8063 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
| 8064 | if test "${ac_cv_lib_nsl_t_open+set}" = set; then : |
| 8065 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8066 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8067 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8068 | LIBS="-lnsl $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8069 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8070 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8071 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8072 | /* Override any GCC internal prototype to avoid an error. |
| 8073 | Use char because int might match the return type of a GCC |
| 8074 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8075 | #ifdef __cplusplus |
| 8076 | extern "C" |
| 8077 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8078 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8079 | int |
| 8080 | main () |
| 8081 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8082 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8083 | ; |
| 8084 | return 0; |
| 8085 | } |
| 8086 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8087 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8088 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8089 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8090 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8091 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8092 | rm -f core conftest.err conftest.$ac_objext \ |
| 8093 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8094 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8095 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8096 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 8097 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
| 8098 | if test "x$ac_cv_lib_nsl_t_open" = x""yes; then : |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8099 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8100 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 8101 | # SVR4 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8102 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 8103 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
| 8104 | if test "${ac_cv_lib_socket_socket+set}" = set; then : |
| 8105 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8106 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8107 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8108 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8109 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8110 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8111 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8112 | /* Override any GCC internal prototype to avoid an error. |
| 8113 | Use char because int might match the return type of a GCC |
| 8114 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8115 | #ifdef __cplusplus |
| 8116 | extern "C" |
| 8117 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8118 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8119 | int |
| 8120 | main () |
| 8121 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8122 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8123 | ; |
| 8124 | return 0; |
| 8125 | } |
| 8126 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8127 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8128 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8129 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8130 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8131 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8132 | rm -f core conftest.err conftest.$ac_objext \ |
| 8133 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8134 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8135 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8136 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 8137 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
| 8138 | if test "x$ac_cv_lib_socket_socket" = x""yes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8139 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8140 | fi |
| 8141 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 8142 | |
Jeremy Hylton | cb25d5e | 2000-07-27 21:23:28 +0000 | [diff] [blame] | 8143 | case "$ac_sys_system" in |
| 8144 | BeOS*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8145 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lnet" >&5 |
| 8146 | $as_echo_n "checking for socket in -lnet... " >&6; } |
| 8147 | if test "${ac_cv_lib_net_socket+set}" = set; then : |
| 8148 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8149 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8150 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8151 | LIBS="-lnet $LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8152 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8153 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8154 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8155 | /* Override any GCC internal prototype to avoid an error. |
| 8156 | Use char because int might match the return type of a GCC |
| 8157 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8158 | #ifdef __cplusplus |
| 8159 | extern "C" |
| 8160 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8161 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8162 | int |
| 8163 | main () |
| 8164 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8165 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8166 | ; |
| 8167 | return 0; |
| 8168 | } |
| 8169 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8170 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8171 | ac_cv_lib_net_socket=yes |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8172 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8173 | ac_cv_lib_net_socket=no |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8174 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8175 | rm -f core conftest.err conftest.$ac_objext \ |
| 8176 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8177 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8178 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8179 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_net_socket" >&5 |
| 8180 | $as_echo "$ac_cv_lib_net_socket" >&6; } |
| 8181 | if test "x$ac_cv_lib_net_socket" = x""yes; then : |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8182 | LIBS="-lnet $LIBS" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8183 | fi |
| 8184 | # BeOS |
| 8185 | ;; |
| 8186 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8187 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8188 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 8189 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8190 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8191 | # Check whether --with-libs was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8192 | if test "${with_libs+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8193 | withval=$with_libs; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8195 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 8196 | LIBS="$withval $LIBS" |
| 8197 | |
| 8198 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8199 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8200 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8201 | fi |
| 8202 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 8203 | |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8204 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8205 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 8206 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8207 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8208 | $as_echo_n "checking for $ac_word... " >&6; } |
| 8209 | if test "${ac_cv_path_PKG_CONFIG+set}" = set; then : |
| 8210 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8211 | else |
| 8212 | case $PKG_CONFIG in |
| 8213 | [\\/]* | ?:[\\/]*) |
| 8214 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 8215 | ;; |
| 8216 | *) |
| 8217 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8218 | for as_dir in $PATH |
| 8219 | do |
| 8220 | IFS=$as_save_IFS |
| 8221 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8222 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8223 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8224 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8225 | $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] | 8226 | break 2 |
| 8227 | fi |
| 8228 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8229 | done |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8230 | IFS=$as_save_IFS |
| 8231 | |
| 8232 | ;; |
| 8233 | esac |
| 8234 | fi |
| 8235 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 8236 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 8238 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8239 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8240 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8241 | $as_echo "no" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8242 | fi |
| 8243 | |
| 8244 | |
| 8245 | fi |
| 8246 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 8247 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 8248 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8249 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8251 | $as_echo_n "checking for $ac_word... " >&6; } |
| 8252 | if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then : |
| 8253 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8254 | else |
| 8255 | case $ac_pt_PKG_CONFIG in |
| 8256 | [\\/]* | ?:[\\/]*) |
| 8257 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 8258 | ;; |
| 8259 | *) |
| 8260 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8261 | for as_dir in $PATH |
| 8262 | do |
| 8263 | IFS=$as_save_IFS |
| 8264 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8265 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8266 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8267 | 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] | 8268 | $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] | 8269 | break 2 |
| 8270 | fi |
| 8271 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8272 | done |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8273 | IFS=$as_save_IFS |
| 8274 | |
| 8275 | ;; |
| 8276 | esac |
| 8277 | fi |
| 8278 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 8279 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 8281 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8282 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8283 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8284 | $as_echo "no" >&6; } |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8285 | fi |
| 8286 | |
| 8287 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 8288 | PKG_CONFIG="" |
| 8289 | else |
| 8290 | case $cross_compiling:$ac_tool_warned in |
| 8291 | yes:) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8292 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 8293 | $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] | 8294 | ac_tool_warned=yes ;; |
| 8295 | esac |
| 8296 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 8297 | fi |
| 8298 | else |
| 8299 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 8300 | fi |
| 8301 | |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8302 | |
| 8303 | # Check for use of the system expat library |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8304 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 8305 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8306 | |
| 8307 | # Check whether --with-system_expat was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8308 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8309 | withval=$with_system_expat; |
| 8310 | fi |
| 8311 | |
| 8312 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8313 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 8314 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8315 | |
| 8316 | # Check for use of the system libffi library |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8317 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 8318 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8319 | |
| 8320 | # Check whether --with-system_ffi was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8321 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | e9e07bf | 2010-03-09 21:46:54 +0000 | [diff] [blame] | 8322 | withval=$with_system_ffi; |
| 8323 | fi |
| 8324 | |
| 8325 | |
| 8326 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | 1c335e6 | 2010-01-01 15:16:29 +0000 | [diff] [blame] | 8327 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 8328 | else |
| 8329 | LIBFFI_INCLUDEDIR="" |
| 8330 | fi |
| 8331 | |
| 8332 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8333 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 8334 | $as_echo "$with_system_ffi" >&6; } |
Martin v. Löwis | 9176fc1 | 2006-04-11 11:12:43 +0000 | [diff] [blame] | 8335 | |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8336 | # Check for --with-dbmliborder |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 8338 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8339 | |
| 8340 | # Check whether --with-dbmliborder was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8341 | if test "${with_dbmliborder+set}" = set; then : |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8342 | withval=$with_dbmliborder; |
| 8343 | if test x$with_dbmliborder = xyes |
| 8344 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8345 | as_fn_error "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8346 | else |
| 8347 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 8348 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 8349 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8350 | as_fn_error "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8351 | fi |
| 8352 | done |
| 8353 | fi |
| 8354 | fi |
| 8355 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8356 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 8357 | $as_echo "$with_dbmliborder" >&6; } |
Benjamin Peterson | 867475c | 2009-04-29 20:36:25 +0000 | [diff] [blame] | 8358 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8359 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8360 | |
| 8361 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8362 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 8363 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8364 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8365 | # Check whether --with-signal-module was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8366 | if test "${with_signal_module+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8367 | withval=$with_signal_module; |
| 8368 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8369 | |
| 8370 | |
| 8371 | if test -z "$with_signal_module" |
| 8372 | then with_signal_module="yes" |
| 8373 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 8375 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8376 | |
| 8377 | if test "${with_signal_module}" = "yes"; then |
| 8378 | USE_SIGNAL_MODULE="" |
| 8379 | SIGNAL_OBJS="" |
| 8380 | else |
| 8381 | USE_SIGNAL_MODULE="#" |
| 8382 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 8383 | fi |
| 8384 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 8385 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8386 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8387 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8388 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8389 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dec-threads" >&5 |
| 8390 | $as_echo_n "checking for --with-dec-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8391 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8392 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8393 | # Check whether --with-dec-threads was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8394 | if test "${with_dec_threads+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8395 | withval=$with_dec_threads; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8396 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8397 | $as_echo "$withval" >&6; } |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8398 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8399 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8400 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8401 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8402 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8403 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8404 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8405 | fi |
| 8406 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8407 | |
| 8408 | # Templates for things AC_DEFINEd more than once. |
| 8409 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8410 | |
| 8411 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8412 | |
| 8413 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8414 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 8415 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8416 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8417 | # Check whether --with-threads was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8418 | if test "${with_threads+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8419 | withval=$with_threads; |
| 8420 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8421 | |
| 8422 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8423 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8424 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8425 | # Check whether --with-thread was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8426 | if test "${with_thread+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8427 | withval=$with_thread; with_threads=$with_thread |
| 8428 | fi |
| 8429 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8430 | |
| 8431 | if test -z "$with_threads" |
| 8432 | then with_threads="yes" |
| 8433 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8434 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 8435 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8436 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8437 | |
Barry Warsaw | c0d24d8 | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8438 | if test "$with_threads" = "no" |
| 8439 | then |
| 8440 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8441 | elif test "$ac_cv_pthread_is_default" = yes |
| 8442 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8443 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8444 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8445 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8446 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8447 | |
| 8448 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8449 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8450 | elif test "$ac_cv_kpthread" = "yes" |
| 8451 | then |
| 8452 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8453 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8454 | CXX="$CXX -Kpthread" |
| 8455 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8456 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 8457 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8458 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8459 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8460 | elif test "$ac_cv_kthread" = "yes" |
| 8461 | then |
| 8462 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8463 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8464 | CXX="$CXX -Kthread" |
| 8465 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8466 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8467 | |
| 8468 | posix_threads=yes |
| 8469 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8470 | elif test "$ac_cv_pthread" = "yes" |
| 8471 | then |
| 8472 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8473 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8474 | CXX="$CXX -pthread" |
| 8475 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8476 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8477 | |
| 8478 | posix_threads=yes |
| 8479 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8480 | else |
| 8481 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 8482 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 8483 | fi |
| 8484 | if test ! -z "$withval" -a -d "$withval" |
| 8485 | then LDFLAGS="$LDFLAGS -L$withval" |
| 8486 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8487 | |
| 8488 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 8489 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 8490 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8491 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 8492 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 8493 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8494 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8495 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8496 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8497 | #ifdef _POSIX_THREADS |
| 8498 | yes |
| 8499 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8500 | |
| 8501 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8502 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8503 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8504 | unistd_defines_pthreads=yes |
| 8505 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8506 | unistd_defines_pthreads=no |
| 8507 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 8508 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8509 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8510 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 8511 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8512 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8513 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 8514 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8515 | ac_fn_c_check_header_mongrel "$LINENO" "cthreads.h" "ac_cv_header_cthreads_h" "$ac_includes_default" |
| 8516 | if test "x$ac_cv_header_cthreads_h" = x""yes; then : |
| 8517 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8518 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8519 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8520 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8521 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8522 | $as_echo "#define HURD_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8523 | |
| 8524 | LIBS="$LIBS -lthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8525 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8526 | else |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8527 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8528 | ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" |
| 8529 | if test "x$ac_cv_header_mach_cthreads_h" = x""yes; then : |
| 8530 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8531 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8532 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8533 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8534 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8535 | $as_echo "#define MACH_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8536 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8537 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8538 | else |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8539 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8540 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pth" >&5 |
| 8541 | $as_echo_n "checking for --with-pth... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8542 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8543 | # Check whether --with-pth was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8544 | if test "${with_pth+set}" = set; then : |
| 8545 | withval=$with_pth; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8546 | $as_echo "$withval" >&6; } |
| 8547 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8548 | |
| 8549 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8550 | $as_echo "#define HAVE_PTH 1" >>confdefs.h |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 8551 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8552 | LIBS="-lpth $LIBS" |
| 8553 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 8554 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8555 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8556 | $as_echo "no" >&6; } |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8557 | |
| 8558 | # Just looking for pthread_create in libpthread is not enough: |
| 8559 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 8560 | # So we really have to include pthread.h, and then link. |
| 8561 | _libs=$LIBS |
| 8562 | LIBS="$LIBS -lpthread" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8563 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 8564 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 8565 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8566 | /* end confdefs.h. */ |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8567 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8568 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8569 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8570 | int |
| 8571 | main () |
| 8572 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8573 | |
| 8574 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8575 | ; |
| 8576 | return 0; |
| 8577 | } |
| 8578 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8579 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8580 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8581 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8582 | $as_echo "yes" >&6; } |
| 8583 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8584 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8585 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8586 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8587 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8588 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8589 | LIBS=$_libs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8590 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
| 8591 | if test "x$ac_cv_func_pthread_detach" = x""yes; then : |
| 8592 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8593 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8594 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8595 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8596 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8597 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8598 | ac_fn_c_check_header_mongrel "$LINENO" "atheos/threads.h" "ac_cv_header_atheos_threads_h" "$ac_includes_default" |
| 8599 | if test "x$ac_cv_header_atheos_threads_h" = x""yes; then : |
| 8600 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8601 | |
| 8602 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8603 | $as_echo "#define ATHEOS_THREADS 1" >>confdefs.h |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8604 | |
| 8605 | THREADOBJ="Python/thread.o" |
| 8606 | else |
| 8607 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8608 | ac_fn_c_check_header_mongrel "$LINENO" "kernel/OS.h" "ac_cv_header_kernel_OS_h" "$ac_includes_default" |
| 8609 | if test "x$ac_cv_header_kernel_OS_h" = x""yes; then : |
| 8610 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8611 | |
| 8612 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8613 | $as_echo "#define BEOS_THREADS 1" >>confdefs.h |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8614 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8615 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8616 | else |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8617 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8618 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 8619 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
| 8620 | if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then : |
| 8621 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8622 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8623 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8624 | LIBS="-lpthreads $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8625 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8626 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8627 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8628 | /* Override any GCC internal prototype to avoid an error. |
| 8629 | Use char because int might match the return type of a GCC |
| 8630 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8631 | #ifdef __cplusplus |
| 8632 | extern "C" |
| 8633 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8634 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8635 | int |
| 8636 | main () |
| 8637 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8638 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8639 | ; |
| 8640 | return 0; |
| 8641 | } |
| 8642 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8643 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8644 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8645 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8646 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8647 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8648 | rm -f core conftest.err conftest.$ac_objext \ |
| 8649 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8650 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8651 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 8653 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
| 8654 | if test "x$ac_cv_lib_pthreads_pthread_create" = x""yes; then : |
| 8655 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8656 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8657 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8658 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8659 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8660 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8661 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8662 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 8663 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
| 8664 | if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then : |
| 8665 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8666 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8667 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8668 | LIBS="-lc_r $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8669 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8670 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8671 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8672 | /* Override any GCC internal prototype to avoid an error. |
| 8673 | Use char because int might match the return type of a GCC |
| 8674 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8675 | #ifdef __cplusplus |
| 8676 | extern "C" |
| 8677 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8678 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8679 | int |
| 8680 | main () |
| 8681 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8682 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8683 | ; |
| 8684 | return 0; |
| 8685 | } |
| 8686 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8687 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8688 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8689 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8690 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8691 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8692 | rm -f core conftest.err conftest.$ac_objext \ |
| 8693 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8694 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8695 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 8697 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
| 8698 | if test "x$ac_cv_lib_c_r_pthread_create" = x""yes; then : |
| 8699 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8700 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8701 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8702 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8703 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8704 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8705 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8706 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 8707 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
| 8708 | if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then : |
| 8709 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8710 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8711 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8712 | LIBS="-lpthread $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8713 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8714 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8715 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8716 | /* Override any GCC internal prototype to avoid an error. |
| 8717 | Use char because int might match the return type of a GCC |
| 8718 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8719 | #ifdef __cplusplus |
| 8720 | extern "C" |
| 8721 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8722 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8723 | int |
| 8724 | main () |
| 8725 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8726 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8727 | ; |
| 8728 | return 0; |
| 8729 | } |
| 8730 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8731 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8732 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8733 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8734 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8735 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8736 | rm -f core conftest.err conftest.$ac_objext \ |
| 8737 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8738 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8739 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 8741 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
| 8742 | if test "x$ac_cv_lib_pthread___pthread_create_system" = x""yes; then : |
| 8743 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8744 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8745 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8746 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8747 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8748 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8749 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 8751 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
| 8752 | if test "${ac_cv_lib_cma_pthread_create+set}" = set; then : |
| 8753 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8754 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8755 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8756 | LIBS="-lcma $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8757 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8758 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8759 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8760 | /* Override any GCC internal prototype to avoid an error. |
| 8761 | Use char because int might match the return type of a GCC |
| 8762 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8763 | #ifdef __cplusplus |
| 8764 | extern "C" |
| 8765 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8766 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8767 | int |
| 8768 | main () |
| 8769 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8770 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8771 | ; |
| 8772 | return 0; |
| 8773 | } |
| 8774 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8775 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8776 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8777 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8778 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8779 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8780 | rm -f core conftest.err conftest.$ac_objext \ |
| 8781 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8782 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8783 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8784 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 8785 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
| 8786 | if test "x$ac_cv_lib_cma_pthread_create" = x""yes; then : |
| 8787 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8788 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8789 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8790 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8791 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8792 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 8793 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8794 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 8795 | fi |
| 8796 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8797 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8798 | fi |
| 8799 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 8800 | fi |
| 8801 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8802 | fi |
| 8803 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8804 | fi |
| 8805 | |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8806 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8807 | fi |
| 8808 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8809 | |
| 8810 | fi |
| 8811 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8812 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8813 | rm -f core conftest.err conftest.$ac_objext \ |
| 8814 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8815 | fi |
| 8816 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8817 | fi |
| 8818 | |
| 8819 | |
| 8820 | fi |
| 8821 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8822 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8823 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8824 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 8825 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
| 8826 | if test "${ac_cv_lib_mpc_usconfig+set}" = set; then : |
| 8827 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8828 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8829 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8830 | LIBS="-lmpc $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8831 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8832 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8833 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8834 | /* Override any GCC internal prototype to avoid an error. |
| 8835 | Use char because int might match the return type of a GCC |
| 8836 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8837 | #ifdef __cplusplus |
| 8838 | extern "C" |
| 8839 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8840 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8841 | int |
| 8842 | main () |
| 8843 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8844 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8845 | ; |
| 8846 | return 0; |
| 8847 | } |
| 8848 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8849 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8850 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8851 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8852 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8853 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8854 | rm -f core conftest.err conftest.$ac_objext \ |
| 8855 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8856 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8857 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8858 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 8859 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
| 8860 | if test "x$ac_cv_lib_mpc_usconfig" = x""yes; then : |
| 8861 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8862 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8863 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8864 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8865 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8866 | fi |
| 8867 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8868 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 8869 | if test "$posix_threads" != "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8870 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 8871 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
| 8872 | if test "${ac_cv_lib_thread_thr_create+set}" = set; then : |
| 8873 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8874 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8875 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8876 | LIBS="-lthread $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8877 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8878 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8879 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8880 | /* Override any GCC internal prototype to avoid an error. |
| 8881 | Use char because int might match the return type of a GCC |
| 8882 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8883 | #ifdef __cplusplus |
| 8884 | extern "C" |
| 8885 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8886 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8887 | int |
| 8888 | main () |
| 8889 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8890 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8891 | ; |
| 8892 | return 0; |
| 8893 | } |
| 8894 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8895 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8896 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8897 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8898 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8899 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8900 | rm -f core conftest.err conftest.$ac_objext \ |
| 8901 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8902 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8903 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8904 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 8905 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
| 8906 | if test "x$ac_cv_lib_thread_thr_create" = x""yes; then : |
| 8907 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8908 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8909 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8910 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8911 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8912 | fi |
| 8913 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8914 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8915 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8916 | if test "$USE_THREAD_MODULE" != "#" |
| 8917 | then |
| 8918 | # If the above checks didn't disable threads, (at least) OSF1 |
| 8919 | # needs this '-threads' argument during linking. |
| 8920 | case $ac_sys_system in |
| 8921 | OSF1) LDLAST=-threads;; |
| 8922 | esac |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 8923 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8924 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8925 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8926 | if test "$posix_threads" = "yes"; then |
| 8927 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8928 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8929 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8930 | |
| 8931 | fi |
| 8932 | |
| 8933 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 8934 | case $ac_sys_system/$ac_sys_release in |
| 8935 | SunOS/5.6) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8936 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8937 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8938 | ;; |
| 8939 | SunOS/5.8) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8940 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8941 | |
| 8942 | ;; |
Christian Heimes | cba36bb | 2008-01-30 22:54:18 +0000 | [diff] [blame] | 8943 | AIX/5) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8944 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | cba36bb | 2008-01-30 22:54:18 +0000 | [diff] [blame] | 8945 | |
| 8946 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8947 | esac |
| 8948 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8949 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 8950 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
| 8951 | if test "${ac_cv_pthread_system_supported+set}" = set; then : |
| 8952 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8953 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8954 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8955 | ac_cv_pthread_system_supported=no |
| 8956 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8957 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8958 | /* end confdefs.h. */ |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8959 | #include <pthread.h> |
| 8960 | void *foo(void *parm) { |
| 8961 | return NULL; |
| 8962 | } |
| 8963 | main() { |
| 8964 | pthread_attr_t attr; |
| 8965 | pthread_t id; |
| 8966 | if (pthread_attr_init(&attr)) exit(-1); |
| 8967 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 8968 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 8969 | exit(0); |
| 8970 | } |
| 8971 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8972 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8973 | ac_cv_pthread_system_supported=yes |
| 8974 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8975 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8976 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8977 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8978 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8979 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8980 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 8981 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8982 | fi |
| 8983 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 8985 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8986 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 8987 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8988 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8989 | |
| 8990 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8991 | for ac_func in pthread_sigmask |
| 8992 | do : |
| 8993 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
| 8994 | if test "x$ac_cv_func_pthread_sigmask" = x""yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8995 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 8996 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8997 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8998 | case $ac_sys_system in |
| 8999 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9000 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9001 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 9002 | |
| 9003 | ;; |
| 9004 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9005 | fi |
| 9006 | done |
| 9007 | |
| 9008 | fi |
| 9009 | |
| 9010 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9011 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9012 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9013 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 9014 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9015 | # Check whether --enable-ipv6 was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9016 | if test "${enable_ipv6+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9017 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9018 | no) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9019 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9020 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9021 | ipv6=no |
| 9022 | ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9023 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9024 | $as_echo "yes" >&6; } |
| 9025 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9026 | |
| 9027 | ipv6=yes |
| 9028 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9029 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9030 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9031 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9032 | if test "$cross_compiling" = yes; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9033 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9034 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9035 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9036 | ipv6=no |
| 9037 | |
| 9038 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9039 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9040 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9041 | /* AF_INET6 available check */ |
| 9042 | #include <sys/types.h> |
| 9043 | #include <sys/socket.h> |
| 9044 | main() |
| 9045 | { |
| 9046 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 9047 | exit(1); |
| 9048 | else |
| 9049 | exit(0); |
| 9050 | } |
| 9051 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9052 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9053 | if ac_fn_c_try_run "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9054 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9056 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9057 | ipv6=yes |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9058 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9059 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9060 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9061 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9062 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9063 | ipv6=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9064 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9065 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9066 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9067 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9068 | fi |
| 9069 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9070 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9071 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9072 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 9073 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 9074 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9075 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9076 | |
| 9077 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9078 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9079 | int |
| 9080 | main () |
| 9081 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9082 | struct sockaddr_in6 x; |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9083 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9084 | ; |
| 9085 | return 0; |
| 9086 | } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9087 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9088 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9089 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9090 | |
| 9091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9092 | $as_echo "yes" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9093 | ipv6=yes |
| 9094 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9095 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9096 | |
| 9097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9098 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9099 | ipv6=no |
| 9100 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9101 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9102 | 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] | 9103 | fi |
| 9104 | |
| 9105 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9106 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 9107 | |
| 9108 | fi |
| 9109 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9110 | fi |
| 9111 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9112 | |
| 9113 | ipv6type=unknown |
| 9114 | ipv6lib=none |
| 9115 | ipv6trylibc=no |
| 9116 | |
| 9117 | if test "$ipv6" = "yes"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9118 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 9119 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 9120 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 9121 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9122 | case $i in |
| 9123 | inria) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9124 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9125 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9126 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9127 | #include <netinet/in.h> |
| 9128 | #ifdef IPV6_INRIA_VERSION |
| 9129 | yes |
| 9130 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9131 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9132 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9133 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9134 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9135 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9136 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9137 | |
| 9138 | ;; |
| 9139 | kame) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9140 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9141 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9142 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9143 | #include <netinet/in.h> |
| 9144 | #ifdef __KAME__ |
| 9145 | yes |
| 9146 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9147 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9148 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9149 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9150 | ipv6type=$i; |
| 9151 | ipv6lib=inet6 |
| 9152 | ipv6libdir=/usr/local/v6/lib |
| 9153 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9154 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9155 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9156 | |
| 9157 | ;; |
| 9158 | linux-glibc) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9159 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9160 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9161 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9162 | #include <features.h> |
| 9163 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 9164 | yes |
| 9165 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9166 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9167 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9168 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9169 | ipv6type=$i; |
| 9170 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9171 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9172 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9173 | |
| 9174 | ;; |
| 9175 | linux-inet6) |
| 9176 | if test -d /usr/inet6; then |
| 9177 | ipv6type=$i |
| 9178 | ipv6lib=inet6 |
| 9179 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9180 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9181 | fi |
| 9182 | ;; |
| 9183 | solaris) |
| 9184 | if test -f /etc/netconfig; then |
| 9185 | if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then |
| 9186 | ipv6type=$i |
| 9187 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9188 | fi |
| 9189 | fi |
| 9190 | ;; |
| 9191 | toshiba) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9192 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9193 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9194 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9195 | #include <sys/param.h> |
| 9196 | #ifdef _TOSHIBA_INET6 |
| 9197 | yes |
| 9198 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9199 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9200 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9201 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9202 | ipv6type=$i; |
| 9203 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9204 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9205 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9206 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9207 | |
| 9208 | ;; |
| 9209 | v6d) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9210 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9211 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9212 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9213 | #include </usr/local/v6/include/sys/v6config.h> |
| 9214 | #ifdef __V6D__ |
| 9215 | yes |
| 9216 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9217 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9218 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9219 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9220 | ipv6type=$i; |
| 9221 | ipv6lib=v6; |
| 9222 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9223 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9224 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9225 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9226 | |
| 9227 | ;; |
| 9228 | zeta) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9229 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9230 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9231 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9232 | #include <sys/param.h> |
| 9233 | #ifdef _ZETA_MINAMI_INET6 |
| 9234 | yes |
| 9235 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9236 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9237 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9238 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9239 | ipv6type=$i; |
| 9240 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9241 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9242 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 9243 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9244 | |
| 9245 | ;; |
| 9246 | esac |
| 9247 | if test "$ipv6type" != "unknown"; then |
| 9248 | break |
| 9249 | fi |
| 9250 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9251 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 9252 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9253 | fi |
| 9254 | |
| 9255 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 9256 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 9257 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 9258 | echo "using lib$ipv6lib" |
| 9259 | else |
| 9260 | if test $ipv6trylibc = "yes"; then |
| 9261 | echo "using libc" |
| 9262 | else |
| 9263 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 9264 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 9265 | echo 'ipv6 kit and compile beforehand.' |
| 9266 | exit 1 |
| 9267 | fi |
| 9268 | fi |
| 9269 | fi |
| 9270 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9271 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 9272 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 9273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9274 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9275 | |
| 9276 | #include <Carbon/Carbon.h> |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9277 | int |
| 9278 | main () |
| 9279 | { |
| 9280 | FSIORefNum fRef = 0 |
| 9281 | ; |
| 9282 | return 0; |
| 9283 | } |
Mark Dickinson | 0712b56 | 2010-05-08 19:13:21 +0000 | [diff] [blame] | 9284 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9285 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9286 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9287 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9288 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9289 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9290 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9291 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9292 | $as_echo "yes" >&6; } |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9293 | |
Mark Dickinson | 0712b56 | 2010-05-08 19:13:21 +0000 | [diff] [blame] | 9294 | else |
| 9295 | |
| 9296 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9297 | $as_echo "no" >&6; } |
| 9298 | |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9299 | fi |
Ronald Oussoren | 0d236eb | 2008-06-06 21:31:33 +0000 | [diff] [blame] | 9300 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9301 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9302 | # Check for --with-doc-strings |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9303 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 9304 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9305 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9306 | # Check whether --with-doc-strings was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9307 | if test "${with_doc_strings+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9308 | withval=$with_doc_strings; |
| 9309 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9310 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9311 | |
| 9312 | if test -z "$with_doc_strings" |
| 9313 | then with_doc_strings="yes" |
| 9314 | fi |
| 9315 | if test "$with_doc_strings" != "no" |
| 9316 | then |
| 9317 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9318 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9319 | |
| 9320 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9321 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 9322 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9323 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9324 | # Check for Python-specific malloc support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9325 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 9326 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9327 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9328 | # Check whether --with-tsc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9329 | if test "${with_tsc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9330 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9331 | if test "$withval" != no |
| 9332 | then |
| 9333 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9334 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9335 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9337 | $as_echo "yes" >&6; } |
| 9338 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9339 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9340 | fi |
| 9341 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9342 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9343 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9344 | fi |
| 9345 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9346 | |
| 9347 | # Check for Python-specific malloc support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9348 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 9349 | $as_echo_n "checking for --with-pymalloc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9350 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9351 | # Check whether --with-pymalloc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9352 | if test "${with_pymalloc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9353 | withval=$with_pymalloc; |
| 9354 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9355 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9356 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9357 | if test -z "$with_pymalloc" |
| 9358 | then with_pymalloc="yes" |
| 9359 | fi |
| 9360 | if test "$with_pymalloc" != "no" |
| 9361 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9362 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9363 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9364 | |
| 9365 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9366 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 9367 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9368 | |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9369 | # Check for Valgrind support |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9370 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 9371 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9372 | |
| 9373 | # Check whether --with-valgrind was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9374 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9375 | withval=$with_valgrind; |
| 9376 | else |
| 9377 | with_valgrind=no |
| 9378 | fi |
| 9379 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9380 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 9381 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9382 | if test "$with_valgrind" != no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9383 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
| 9384 | if test "x$ac_cv_header_valgrind_valgrind_h" = x""yes; then : |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9385 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9386 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9387 | |
| 9388 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9389 | as_fn_error "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 91c12eb | 2009-12-03 02:52:39 +0000 | [diff] [blame] | 9390 | |
| 9391 | fi |
| 9392 | |
| 9393 | |
| 9394 | fi |
| 9395 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9396 | # Check for --with-wctype-functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9397 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-wctype-functions" >&5 |
| 9398 | $as_echo_n "checking for --with-wctype-functions... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9399 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9400 | # Check whether --with-wctype-functions was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9401 | if test "${with_wctype_functions+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9402 | withval=$with_wctype_functions; |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9403 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9404 | then |
| 9405 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9406 | $as_echo "#define WANT_WCTYPE_FUNCTIONS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9407 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9408 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9409 | $as_echo "yes" >&6; } |
| 9410 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9411 | $as_echo "no" >&6; } |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9412 | fi |
| 9413 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9414 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9415 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9416 | fi |
| 9417 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9418 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 9419 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9420 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 9421 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9422 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9423 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 9424 | # 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] | 9425 | for ac_func in dlopen |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9426 | do : |
| 9427 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
| 9428 | if test "x$ac_cv_func_dlopen" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9429 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9430 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9431 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9432 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9433 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 9434 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9435 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9436 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9437 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 9438 | # loading of modules. |
| 9439 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9440 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 9441 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9442 | if test -z "$DYNLOADFILE" |
| 9443 | then |
| 9444 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 9445 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 9446 | if test "$ac_cv_func_dlopen" = yes |
| 9447 | then DYNLOADFILE="dynload_shlib.o" |
| 9448 | else DYNLOADFILE="dynload_aix.o" |
| 9449 | fi |
| 9450 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9451 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 9452 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Anthony Baxter | 8220174 | 2006-04-09 15:07:40 +0000 | [diff] [blame] | 9453 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 9454 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 9455 | atheos*) DYNLOADFILE="dynload_atheos.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9456 | *) |
| 9457 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 9458 | # out any dynamic loading |
| 9459 | if test "$ac_cv_func_dlopen" = yes |
| 9460 | then DYNLOADFILE="dynload_shlib.o" |
| 9461 | else DYNLOADFILE="dynload_stub.o" |
| 9462 | fi |
| 9463 | ;; |
| 9464 | esac |
| 9465 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9466 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 9467 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9468 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 9469 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9470 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9471 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9472 | |
| 9473 | fi |
| 9474 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9475 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 9476 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9477 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9478 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 9479 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9480 | if test -z "$MACHDEP_OBJS" |
| 9481 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 9482 | MACHDEP_OBJS=$extra_machdep_objs |
| 9483 | else |
| 9484 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9485 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9486 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: MACHDEP_OBJS" >&5 |
| 9487 | $as_echo "MACHDEP_OBJS" >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9488 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9489 | # checks for library functions |
Martin v. Löwis | aef18b1 | 2008-03-24 13:31:16 +0000 | [diff] [blame] | 9490 | for ac_func in alarm setitimer getitimer bind_textdomain_codeset chown \ |
| 9491 | clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \ |
Martin v. Löwis | 438b534 | 2002-12-27 10:16:42 +0000 | [diff] [blame] | 9492 | gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 50ea456 | 2009-11-27 13:56:01 +0000 | [diff] [blame] | 9493 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Antoine Pitrou | 30b3b35 | 2009-12-02 20:37:54 +0000 | [diff] [blame] | 9494 | initgroups kill killpg lchmod lchown lstat mkfifo mknod mktime \ |
Martin v. Löwis | a5f0907 | 2002-10-11 05:37:59 +0000 | [diff] [blame] | 9495 | mremap nice pathconf pause plock poll pthread_init \ |
Guido van Rossum | 162e38c | 2003-02-19 15:25:10 +0000 | [diff] [blame] | 9496 | putenv readlink realpath \ |
Jesse Noller | 355b126 | 2009-04-02 00:03:28 +0000 | [diff] [blame] | 9497 | select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \ |
| 9498 | setgid \ |
Martin v. Löwis | 4daacb1 | 2003-03-28 18:37:01 +0000 | [diff] [blame] | 9499 | setlocale setregid setreuid setsid setpgid setpgrp setuid setvbuf snprintf \ |
Martin v. Löwis | 50ea456 | 2009-11-27 13:56:01 +0000 | [diff] [blame] | 9500 | setlocale setregid setreuid setresuid setresgid \ |
| 9501 | setsid setpgid setpgrp setuid setvbuf snprintf \ |
Skip Montanaro | 7e11a01 | 2004-02-07 12:55:46 +0000 | [diff] [blame] | 9502 | sigaction siginterrupt sigrelse strftime \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 9503 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Neal Norwitz | 05a4559 | 2006-03-20 06:30:08 +0000 | [diff] [blame] | 9504 | truncate uname unsetenv utimes waitpid wait3 wait4 wcscoll _getpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9505 | do : |
| 9506 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9507 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 9508 | eval as_val=\$$as_ac_var |
| 9509 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9510 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9511 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9512 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 9513 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9514 | fi |
| 9515 | done |
| 9516 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9517 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9518 | # For some functions, having a definition is not sufficient, since |
| 9519 | # we want to take their address. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9520 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 9521 | $as_echo_n "checking for chroot... " >&6; } |
| 9522 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9523 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9524 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9525 | int |
| 9526 | main () |
| 9527 | { |
| 9528 | void *x=chroot |
| 9529 | ; |
| 9530 | return 0; |
| 9531 | } |
| 9532 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9533 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9534 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9535 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9536 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9537 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9538 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9539 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9540 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9541 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9542 | |
| 9543 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9544 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9545 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 9546 | $as_echo_n "checking for link... " >&6; } |
| 9547 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9548 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9549 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9550 | int |
| 9551 | main () |
| 9552 | { |
| 9553 | void *x=link |
| 9554 | ; |
| 9555 | return 0; |
| 9556 | } |
| 9557 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9558 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9559 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9560 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9561 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9562 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9563 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9564 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9565 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9566 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9567 | |
| 9568 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9569 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9570 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 9571 | $as_echo_n "checking for symlink... " >&6; } |
| 9572 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9573 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9574 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9575 | int |
| 9576 | main () |
| 9577 | { |
| 9578 | void *x=symlink |
| 9579 | ; |
| 9580 | return 0; |
| 9581 | } |
| 9582 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9583 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9584 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9585 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9586 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9587 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9588 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9589 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9591 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9592 | |
| 9593 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9594 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9595 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 9596 | $as_echo_n "checking for fchdir... " >&6; } |
| 9597 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9598 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9599 | #include <unistd.h> |
| 9600 | int |
| 9601 | main () |
| 9602 | { |
| 9603 | void *x=fchdir |
| 9604 | ; |
| 9605 | return 0; |
| 9606 | } |
| 9607 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9608 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9609 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9610 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9611 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9612 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9613 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9614 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9615 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9616 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9617 | |
| 9618 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9619 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9620 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 9621 | $as_echo_n "checking for fsync... " >&6; } |
| 9622 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9623 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9624 | #include <unistd.h> |
| 9625 | int |
| 9626 | main () |
| 9627 | { |
| 9628 | void *x=fsync |
| 9629 | ; |
| 9630 | return 0; |
| 9631 | } |
| 9632 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9633 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9634 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9635 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9636 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9637 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9638 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9639 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9640 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9641 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9642 | |
| 9643 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9644 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9645 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 9646 | $as_echo_n "checking for fdatasync... " >&6; } |
| 9647 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9648 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9649 | #include <unistd.h> |
| 9650 | int |
| 9651 | main () |
| 9652 | { |
| 9653 | void *x=fdatasync |
| 9654 | ; |
| 9655 | return 0; |
| 9656 | } |
| 9657 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9658 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9659 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9660 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9661 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9662 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9663 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9664 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9666 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9667 | |
| 9668 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9669 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 9671 | $as_echo_n "checking for epoll... " >&6; } |
| 9672 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9673 | /* end confdefs.h. */ |
| 9674 | #include <sys/epoll.h> |
| 9675 | int |
| 9676 | main () |
| 9677 | { |
| 9678 | void *x=epoll_create |
| 9679 | ; |
| 9680 | return 0; |
| 9681 | } |
| 9682 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9683 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9684 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9685 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9686 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9687 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9688 | $as_echo "yes" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9689 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9690 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9691 | $as_echo "no" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9692 | |
| 9693 | fi |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9694 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9695 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 9696 | $as_echo_n "checking for kqueue... " >&6; } |
| 9697 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9698 | /* end confdefs.h. */ |
| 9699 | |
| 9700 | #include <sys/types.h> |
| 9701 | #include <sys/event.h> |
| 9702 | |
| 9703 | int |
| 9704 | main () |
| 9705 | { |
| 9706 | int x=kqueue() |
| 9707 | ; |
| 9708 | return 0; |
| 9709 | } |
| 9710 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9711 | if ac_fn_c_try_compile "$LINENO"; then : |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9712 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9713 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9714 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9716 | $as_echo "yes" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9717 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9718 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9719 | $as_echo "no" >&6; } |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9720 | |
| 9721 | fi |
Christian Heimes | 0e9ab5f | 2008-03-21 23:49:44 +0000 | [diff] [blame] | 9722 | 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] | 9723 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 9724 | # functions ctermid_r, setgroups in the library, but no prototype |
| 9725 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 9726 | # address to avoid compiler warnings and potential miscompilations |
| 9727 | # because of the missing prototypes. |
| 9728 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9729 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 9730 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 9731 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9732 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9733 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9734 | #include <stdio.h> |
| 9735 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9736 | int |
| 9737 | main () |
| 9738 | { |
| 9739 | void* p = ctermid_r |
| 9740 | ; |
| 9741 | return 0; |
| 9742 | } |
| 9743 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9744 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9745 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9746 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9747 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9748 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9749 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9750 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9751 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9752 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9753 | |
| 9754 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9755 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9756 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9757 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock" >&5 |
| 9758 | $as_echo_n "checking for flock... " >&6; } |
| 9759 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9760 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9761 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9762 | #include <sys/file.h> |
| 9763 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9764 | int |
| 9765 | main () |
| 9766 | { |
| 9767 | void* p = flock |
| 9768 | ; |
| 9769 | return 0; |
| 9770 | } |
| 9771 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9772 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9773 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9774 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9775 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9776 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9777 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9778 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9779 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9780 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9781 | |
| 9782 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9783 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9784 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 9786 | $as_echo_n "checking for getpagesize... " >&6; } |
| 9787 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9788 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9789 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9790 | #include <unistd.h> |
| 9791 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9792 | int |
| 9793 | main () |
| 9794 | { |
| 9795 | void* p = getpagesize |
| 9796 | ; |
| 9797 | return 0; |
| 9798 | } |
| 9799 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9800 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9801 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9802 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9803 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 9804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9805 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9806 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9807 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9808 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9809 | |
| 9810 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9811 | 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] | 9812 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9813 | for ac_prog in true |
| 9814 | do |
| 9815 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 9816 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9817 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9818 | $as_echo_n "checking for $ac_word... " >&6; } |
| 9819 | if test "${ac_cv_prog_TRUE+set}" = set; then : |
| 9820 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9821 | else |
| 9822 | if test -n "$TRUE"; then |
| 9823 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 9824 | else |
| 9825 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9826 | for as_dir in $PATH |
| 9827 | do |
| 9828 | IFS=$as_save_IFS |
| 9829 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9830 | for ac_exec_ext in '' $ac_executable_extensions; do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9831 | 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] | 9832 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9833 | $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] | 9834 | break 2 |
| 9835 | fi |
| 9836 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9837 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9838 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9839 | |
| 9840 | fi |
| 9841 | fi |
| 9842 | TRUE=$ac_cv_prog_TRUE |
| 9843 | if test -n "$TRUE"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9844 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 9845 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9846 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9847 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9848 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9849 | fi |
| 9850 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9851 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9852 | test -n "$TRUE" && break |
| 9853 | done |
| 9854 | test -n "$TRUE" || TRUE="/bin/true" |
| 9855 | |
| 9856 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9857 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 9858 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
| 9859 | if test "${ac_cv_lib_c_inet_aton+set}" = set; then : |
| 9860 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9861 | else |
| 9862 | ac_check_lib_save_LIBS=$LIBS |
| 9863 | LIBS="-lc $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9864 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9865 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9866 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9867 | /* Override any GCC internal prototype to avoid an error. |
| 9868 | Use char because int might match the return type of a GCC |
| 9869 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9870 | #ifdef __cplusplus |
| 9871 | extern "C" |
| 9872 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9873 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9874 | int |
| 9875 | main () |
| 9876 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9877 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9878 | ; |
| 9879 | return 0; |
| 9880 | } |
| 9881 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9882 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9883 | ac_cv_lib_c_inet_aton=yes |
| 9884 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9885 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9886 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9887 | rm -f core conftest.err conftest.$ac_objext \ |
| 9888 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9889 | LIBS=$ac_check_lib_save_LIBS |
| 9890 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9891 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 9892 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
| 9893 | if test "x$ac_cv_lib_c_inet_aton" = x""yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9894 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9895 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9896 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 9897 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
| 9898 | if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then : |
| 9899 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9900 | else |
| 9901 | ac_check_lib_save_LIBS=$LIBS |
| 9902 | LIBS="-lresolv $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9903 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9904 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9905 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9906 | /* Override any GCC internal prototype to avoid an error. |
| 9907 | Use char because int might match the return type of a GCC |
| 9908 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9909 | #ifdef __cplusplus |
| 9910 | extern "C" |
| 9911 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9912 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9913 | int |
| 9914 | main () |
| 9915 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 9916 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9917 | ; |
| 9918 | return 0; |
| 9919 | } |
| 9920 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9921 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9922 | ac_cv_lib_resolv_inet_aton=yes |
| 9923 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9924 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9925 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9926 | rm -f core conftest.err conftest.$ac_objext \ |
| 9927 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9928 | LIBS=$ac_check_lib_save_LIBS |
| 9929 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9930 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 9931 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
| 9932 | if test "x$ac_cv_lib_resolv_inet_aton" = x""yes; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9933 | cat >>confdefs.h <<_ACEOF |
| 9934 | #define HAVE_LIBRESOLV 1 |
| 9935 | _ACEOF |
| 9936 | |
| 9937 | LIBS="-lresolv $LIBS" |
| 9938 | |
| 9939 | fi |
| 9940 | |
| 9941 | |
| 9942 | fi |
| 9943 | |
| 9944 | |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 9945 | # On Tru64, chflags seems to be present, but calling it will |
| 9946 | # exit Python |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9947 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 9948 | $as_echo_n "checking for chflags... " >&6; } |
| 9949 | if test "${ac_cv_have_chflags+set}" = set; then : |
| 9950 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 9951 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9952 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 9953 | ac_cv_have_chflags=cross |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 9954 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9955 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 9956 | /* end confdefs.h. */ |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 9957 | [ |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 9958 | #include <sys/stat.h> |
| 9959 | #include <unistd.h> |
| 9960 | int main(int argc, char*argv[]) |
| 9961 | { |
| 9962 | if(chflags(argv[0], 0) != 0) |
| 9963 | return 1; |
| 9964 | return 0; |
| 9965 | } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 9966 | ] |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 9967 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9968 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 9969 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 9970 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9971 | ac_cv_have_chflags=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 9972 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9973 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9974 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 9975 | fi |
| 9976 | |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 9977 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 9978 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 9980 | $as_echo "$ac_cv_have_chflags" >&6; } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 9981 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9982 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
| 9983 | if test "x$ac_cv_func_chflags" = x""yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 9984 | ac_cv_have_chflags="yes" |
| 9985 | else |
| 9986 | ac_cv_have_chflags="no" |
| 9987 | fi |
| 9988 | |
| 9989 | fi |
| 9990 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 9991 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9992 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 9993 | |
| 9994 | fi |
| 9995 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 9996 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 9997 | $as_echo_n "checking for lchflags... " >&6; } |
| 9998 | if test "${ac_cv_have_lchflags+set}" = set; then : |
| 9999 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10000 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10001 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10002 | ac_cv_have_lchflags=cross |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10003 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10004 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10005 | /* end confdefs.h. */ |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10006 | [ |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10007 | #include <sys/stat.h> |
| 10008 | #include <unistd.h> |
| 10009 | int main(int argc, char*argv[]) |
| 10010 | { |
| 10011 | if(lchflags(argv[0], 0) != 0) |
| 10012 | return 1; |
| 10013 | return 0; |
| 10014 | } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10015 | ] |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10016 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10017 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10018 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10019 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10020 | ac_cv_have_lchflags=no |
Martin v. Löwis | a51d5c8 | 2007-12-04 08:37:59 +0000 | [diff] [blame] | 10021 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10022 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10023 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 10024 | fi |
| 10025 | |
| 10026 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10027 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10028 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 10029 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10030 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10031 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
| 10032 | if test "x$ac_cv_func_lchflags" = x""yes; then : |
Gregory P. Smith | 49437c2 | 2009-11-02 01:38:35 +0000 | [diff] [blame] | 10033 | ac_cv_have_lchflags="yes" |
| 10034 | else |
| 10035 | ac_cv_have_lchflags="no" |
| 10036 | fi |
| 10037 | |
| 10038 | fi |
| 10039 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10040 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10041 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10042 | |
| 10043 | fi |
| 10044 | |
Ronald Oussoren | f875264 | 2006-07-06 10:13:35 +0000 | [diff] [blame] | 10045 | case $ac_sys_system/$ac_sys_release in |
| 10046 | Darwin/*) |
| 10047 | _CUR_CFLAGS="${CFLAGS}" |
| 10048 | _CUR_LDFLAGS="${LDFLAGS}" |
| 10049 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 10050 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 10051 | ;; |
| 10052 | esac |
| 10053 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10054 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 10055 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
| 10056 | if test "${ac_cv_lib_z_inflateCopy+set}" = set; then : |
| 10057 | $as_echo_n "(cached) " >&6 |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10058 | else |
| 10059 | ac_check_lib_save_LIBS=$LIBS |
| 10060 | LIBS="-lz $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10061 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10062 | /* end confdefs.h. */ |
| 10063 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10064 | /* Override any GCC internal prototype to avoid an error. |
| 10065 | Use char because int might match the return type of a GCC |
| 10066 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10067 | #ifdef __cplusplus |
| 10068 | extern "C" |
| 10069 | #endif |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10070 | char inflateCopy (); |
| 10071 | int |
| 10072 | main () |
| 10073 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10074 | return inflateCopy (); |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10075 | ; |
| 10076 | return 0; |
| 10077 | } |
| 10078 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10079 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10080 | ac_cv_lib_z_inflateCopy=yes |
| 10081 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10082 | ac_cv_lib_z_inflateCopy=no |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10083 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10084 | rm -f core conftest.err conftest.$ac_objext \ |
| 10085 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10086 | LIBS=$ac_check_lib_save_LIBS |
| 10087 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10088 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 10089 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
| 10090 | if test "x$ac_cv_lib_z_inflateCopy" = x""yes; then : |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10091 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10092 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Neal Norwitz | 6e73aaa | 2006-06-12 03:33:09 +0000 | [diff] [blame] | 10093 | |
| 10094 | fi |
| 10095 | |
| 10096 | |
Ronald Oussoren | f875264 | 2006-07-06 10:13:35 +0000 | [diff] [blame] | 10097 | case $ac_sys_system/$ac_sys_release in |
| 10098 | Darwin/*) |
| 10099 | CFLAGS="${_CUR_CFLAGS}" |
| 10100 | LDFLAGS="${_CUR_LDFLAGS}" |
| 10101 | ;; |
| 10102 | esac |
| 10103 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10104 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 10105 | $as_echo_n "checking for hstrerror... " >&6; } |
| 10106 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10107 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10108 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10109 | #include <netdb.h> |
| 10110 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10111 | int |
| 10112 | main () |
| 10113 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10114 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10115 | ; |
| 10116 | return 0; |
| 10117 | } |
| 10118 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10119 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10120 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10121 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10122 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10123 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10124 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10125 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10126 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10127 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10128 | |
| 10129 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10130 | rm -f core conftest.err conftest.$ac_objext \ |
| 10131 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10132 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10133 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 10134 | $as_echo_n "checking for inet_aton... " >&6; } |
| 10135 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10136 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10137 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 10138 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10139 | #include <sys/socket.h> |
| 10140 | #include <netinet/in.h> |
| 10141 | #include <arpa/inet.h> |
| 10142 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10143 | int |
| 10144 | main () |
| 10145 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10146 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10147 | ; |
| 10148 | return 0; |
| 10149 | } |
| 10150 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10151 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10152 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10153 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10154 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10156 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10157 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10158 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10159 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10160 | |
| 10161 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10162 | rm -f core conftest.err conftest.$ac_objext \ |
| 10163 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10164 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10165 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 10166 | $as_echo_n "checking for inet_pton... " >&6; } |
| 10167 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10168 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10169 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10170 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10171 | #include <sys/socket.h> |
| 10172 | #include <netinet/in.h> |
| 10173 | #include <arpa/inet.h> |
| 10174 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10175 | int |
| 10176 | main () |
| 10177 | { |
| 10178 | void* p = inet_pton |
| 10179 | ; |
| 10180 | return 0; |
| 10181 | } |
| 10182 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10183 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10184 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10185 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10186 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10187 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10188 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10189 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10191 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10192 | |
| 10193 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10194 | 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] | 10195 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10196 | # 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] | 10197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 10198 | $as_echo_n "checking for setgroups... " >&6; } |
| 10199 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10200 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10201 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10202 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10203 | #ifdef HAVE_GRP_H |
| 10204 | #include <grp.h> |
| 10205 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10206 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10207 | int |
| 10208 | main () |
| 10209 | { |
| 10210 | void* p = setgroups |
| 10211 | ; |
| 10212 | return 0; |
| 10213 | } |
| 10214 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10215 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10216 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10217 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10218 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10219 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10220 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10221 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10222 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10223 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10224 | |
| 10225 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10226 | 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] | 10227 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10228 | # check for openpty and forkpty |
| 10229 | |
| 10230 | for ac_func in openpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10231 | do : |
| 10232 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
| 10233 | if test "x$ac_cv_func_openpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10234 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10235 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10236 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10237 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10238 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10239 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 10240 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
| 10241 | if test "${ac_cv_lib_util_openpty+set}" = set; then : |
| 10242 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10243 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10244 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10245 | LIBS="-lutil $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10246 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10247 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10248 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10249 | /* Override any GCC internal prototype to avoid an error. |
| 10250 | Use char because int might match the return type of a GCC |
| 10251 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10252 | #ifdef __cplusplus |
| 10253 | extern "C" |
| 10254 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10255 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10256 | int |
| 10257 | main () |
| 10258 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10259 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10260 | ; |
| 10261 | return 0; |
| 10262 | } |
| 10263 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10264 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10265 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10266 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10267 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10268 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10269 | rm -f core conftest.err conftest.$ac_objext \ |
| 10270 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10271 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10272 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10273 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 10274 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
| 10275 | if test "x$ac_cv_lib_util_openpty" = x""yes; then : |
| 10276 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10277 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10278 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 10280 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
| 10281 | if test "${ac_cv_lib_bsd_openpty+set}" = set; then : |
| 10282 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10283 | else |
| 10284 | ac_check_lib_save_LIBS=$LIBS |
| 10285 | LIBS="-lbsd $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10286 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10287 | /* end confdefs.h. */ |
| 10288 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10289 | /* Override any GCC internal prototype to avoid an error. |
| 10290 | Use char because int might match the return type of a GCC |
| 10291 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10292 | #ifdef __cplusplus |
| 10293 | extern "C" |
| 10294 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10295 | char openpty (); |
| 10296 | int |
| 10297 | main () |
| 10298 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10299 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10300 | ; |
| 10301 | return 0; |
| 10302 | } |
| 10303 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10304 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10305 | ac_cv_lib_bsd_openpty=yes |
| 10306 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10307 | ac_cv_lib_bsd_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10308 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10309 | rm -f core conftest.err conftest.$ac_objext \ |
| 10310 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10311 | LIBS=$ac_check_lib_save_LIBS |
| 10312 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10313 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 10314 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
| 10315 | if test "x$ac_cv_lib_bsd_openpty" = x""yes; then : |
| 10316 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10317 | LIBS="$LIBS -lbsd" |
| 10318 | fi |
| 10319 | |
| 10320 | |
| 10321 | fi |
| 10322 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10323 | |
| 10324 | fi |
| 10325 | done |
| 10326 | |
| 10327 | for ac_func in forkpty |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10328 | do : |
| 10329 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
| 10330 | if test "x$ac_cv_func_forkpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10331 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10332 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10333 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10334 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10335 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 10337 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
| 10338 | if test "${ac_cv_lib_util_forkpty+set}" = set; then : |
| 10339 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10340 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10341 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10342 | LIBS="-lutil $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10343 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10344 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10345 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10346 | /* Override any GCC internal prototype to avoid an error. |
| 10347 | Use char because int might match the return type of a GCC |
| 10348 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10349 | #ifdef __cplusplus |
| 10350 | extern "C" |
| 10351 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10352 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10353 | int |
| 10354 | main () |
| 10355 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10356 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10357 | ; |
| 10358 | return 0; |
| 10359 | } |
| 10360 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10361 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10362 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10363 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10364 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10365 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10366 | rm -f core conftest.err conftest.$ac_objext \ |
| 10367 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10368 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10369 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 10371 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
| 10372 | if test "x$ac_cv_lib_util_forkpty" = x""yes; then : |
| 10373 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10374 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10375 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10376 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 10377 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
| 10378 | if test "${ac_cv_lib_bsd_forkpty+set}" = set; then : |
| 10379 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10380 | else |
| 10381 | ac_check_lib_save_LIBS=$LIBS |
| 10382 | LIBS="-lbsd $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10383 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10384 | /* end confdefs.h. */ |
| 10385 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10386 | /* Override any GCC internal prototype to avoid an error. |
| 10387 | Use char because int might match the return type of a GCC |
| 10388 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10389 | #ifdef __cplusplus |
| 10390 | extern "C" |
| 10391 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10392 | char forkpty (); |
| 10393 | int |
| 10394 | main () |
| 10395 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10396 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10397 | ; |
| 10398 | return 0; |
| 10399 | } |
| 10400 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10401 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10402 | ac_cv_lib_bsd_forkpty=yes |
| 10403 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10404 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10405 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10406 | rm -f core conftest.err conftest.$ac_objext \ |
| 10407 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10408 | LIBS=$ac_check_lib_save_LIBS |
| 10409 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10410 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 10411 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
| 10412 | if test "x$ac_cv_lib_bsd_forkpty" = x""yes; then : |
| 10413 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10414 | LIBS="$LIBS -lbsd" |
| 10415 | fi |
| 10416 | |
| 10417 | |
| 10418 | fi |
| 10419 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10420 | |
| 10421 | fi |
| 10422 | done |
| 10423 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10424 | |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10425 | # Stuff for expat. |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10426 | for ac_func in memmove |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10427 | do : |
| 10428 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
| 10429 | if test "x$ac_cv_func_memmove" = x""yes; then : |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10430 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10431 | #define HAVE_MEMMOVE 1 |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10432 | _ACEOF |
| 10433 | |
| 10434 | fi |
| 10435 | done |
| 10436 | |
| 10437 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10438 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10439 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10440 | do : |
| 10441 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10442 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 10443 | eval as_val=\$$as_ac_var |
| 10444 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10445 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10446 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10447 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10448 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10449 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10450 | done |
| 10451 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10452 | |
Brett Cannon | aa5778d | 2008-03-18 04:09:00 +0000 | [diff] [blame] | 10453 | for ac_func in dup2 getcwd strdup |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10454 | do : |
| 10455 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10456 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 10457 | eval as_val=\$$as_ac_var |
| 10458 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10459 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10460 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10461 | _ACEOF |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10462 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10463 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10464 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10465 | *" $ac_func.$ac_objext "* ) ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10466 | *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" |
| 10467 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10468 | esac |
| 10469 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10470 | fi |
| 10471 | done |
| 10472 | |
| 10473 | |
| 10474 | for ac_func in getpgrp |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10475 | do : |
| 10476 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
| 10477 | if test "x$ac_cv_func_getpgrp" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10478 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10479 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10480 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10481 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10482 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10483 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10484 | int |
| 10485 | main () |
| 10486 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10487 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10488 | ; |
| 10489 | return 0; |
| 10490 | } |
| 10491 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10492 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10493 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10494 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10495 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10496 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10497 | 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] | 10498 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10499 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10500 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10501 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10502 | for ac_func in setpgrp |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10503 | do : |
| 10504 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
| 10505 | if test "x$ac_cv_func_setpgrp" = x""yes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10506 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10507 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10508 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10510 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10511 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10512 | int |
| 10513 | main () |
| 10514 | { |
| 10515 | setpgrp(0,0); |
| 10516 | ; |
| 10517 | return 0; |
| 10518 | } |
| 10519 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10520 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10521 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10522 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10523 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10524 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10525 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10526 | |
| 10527 | fi |
| 10528 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10529 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10530 | for ac_func in gettimeofday |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10531 | do : |
| 10532 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
| 10533 | if test "x$ac_cv_func_gettimeofday" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10534 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10535 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10536 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10537 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10538 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10539 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10540 | int |
| 10541 | main () |
| 10542 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10543 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10544 | ; |
| 10545 | return 0; |
| 10546 | } |
| 10547 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10548 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10549 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10550 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10551 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10552 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10553 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10554 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10555 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10556 | 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] | 10557 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10558 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10559 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10560 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10561 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10562 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 10563 | $as_echo_n "checking for major... " >&6; } |
| 10564 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10565 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10566 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 10567 | #if defined(MAJOR_IN_MKDEV) |
| 10568 | #include <sys/mkdev.h> |
| 10569 | #elif defined(MAJOR_IN_SYSMACROS) |
| 10570 | #include <sys/sysmacros.h> |
| 10571 | #else |
| 10572 | #include <sys/types.h> |
| 10573 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10574 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10575 | int |
| 10576 | main () |
| 10577 | { |
| 10578 | |
| 10579 | makedev(major(0),minor(0)); |
| 10580 | |
| 10581 | ; |
| 10582 | return 0; |
| 10583 | } |
| 10584 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10585 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10586 | |
| 10587 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10588 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10589 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10591 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10592 | |
| 10593 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10594 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10596 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10597 | |
| 10598 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10599 | rm -f core conftest.err conftest.$ac_objext \ |
| 10600 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10601 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10602 | # 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] | 10603 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10604 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 10605 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 10606 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10607 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10608 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10609 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10610 | #include <sys/socket.h> |
| 10611 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10612 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10613 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10614 | int |
| 10615 | main () |
| 10616 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10617 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10618 | ; |
| 10619 | return 0; |
| 10620 | } |
| 10621 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10622 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10623 | have_getaddrinfo=yes |
| 10624 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10625 | have_getaddrinfo=no |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10626 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10627 | rm -f core conftest.err conftest.$ac_objext \ |
| 10628 | conftest$ac_exeext conftest.$ac_ext |
| 10629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 10630 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10631 | if test $have_getaddrinfo = yes |
| 10632 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10633 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 10634 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
| 10635 | if test "${ac_cv_buggy_getaddrinfo+set}" = set; then : |
| 10636 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10637 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10638 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10639 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10640 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10641 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10642 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10643 | |
| 10644 | #include <sys/types.h> |
| 10645 | #include <netdb.h> |
| 10646 | #include <string.h> |
| 10647 | #include <sys/socket.h> |
| 10648 | #include <netinet/in.h> |
| 10649 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10650 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10651 | { |
| 10652 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 10653 | struct addrinfo hints, *ai, *aitop; |
| 10654 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 10655 | |
| 10656 | for (passive = 0; passive <= 1; passive++) { |
| 10657 | memset(&hints, 0, sizeof(hints)); |
| 10658 | hints.ai_family = AF_UNSPEC; |
| 10659 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 10660 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 10661 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10662 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 10663 | (void)gai_strerror(gaierr); |
| 10664 | goto bad; |
| 10665 | } |
| 10666 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 10667 | if (ai->ai_addr == NULL || |
| 10668 | ai->ai_addrlen == 0 || |
| 10669 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 10670 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 10671 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 10672 | goto bad; |
| 10673 | } |
| 10674 | switch (ai->ai_family) { |
| 10675 | case AF_INET: |
| 10676 | if (strcmp(strport, "54321") != 0) { |
| 10677 | goto bad; |
| 10678 | } |
| 10679 | if (passive) { |
| 10680 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 10681 | goto bad; |
| 10682 | } |
| 10683 | } else { |
| 10684 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 10685 | goto bad; |
| 10686 | } |
| 10687 | } |
| 10688 | inet4++; |
| 10689 | break; |
| 10690 | case AF_INET6: |
| 10691 | if (strcmp(strport, "54321") != 0) { |
| 10692 | goto bad; |
| 10693 | } |
| 10694 | if (passive) { |
| 10695 | if (strcmp(straddr, "::") != 0) { |
| 10696 | goto bad; |
| 10697 | } |
| 10698 | } else { |
| 10699 | if (strcmp(straddr, "::1") != 0) { |
| 10700 | goto bad; |
| 10701 | } |
| 10702 | } |
| 10703 | inet6++; |
| 10704 | break; |
| 10705 | case AF_UNSPEC: |
| 10706 | goto bad; |
| 10707 | break; |
| 10708 | default: |
| 10709 | /* another family support? */ |
| 10710 | break; |
| 10711 | } |
| 10712 | } |
| 10713 | } |
| 10714 | |
| 10715 | if (!(inet4 == 0 || inet4 == 2)) |
| 10716 | goto bad; |
| 10717 | if (!(inet6 == 0 || inet6 == 2)) |
| 10718 | goto bad; |
| 10719 | |
| 10720 | if (aitop) |
| 10721 | freeaddrinfo(aitop); |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10722 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10723 | |
| 10724 | bad: |
| 10725 | if (aitop) |
| 10726 | freeaddrinfo(aitop); |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10727 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10728 | } |
| 10729 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10730 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10731 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10732 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10733 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10734 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10735 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10736 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10737 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10738 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10739 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10740 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10741 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10742 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10743 | |
Mark Dickinson | 0ef0b91 | 2009-12-31 21:11:48 +0000 | [diff] [blame] | 10744 | if test $have_getaddrinfo = no -o "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 10745 | then |
| 10746 | if test $ipv6 = yes |
| 10747 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10748 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 10749 | echo ' or you can specify "--disable-ipv6"'. |
| 10750 | exit 1 |
| 10751 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10752 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10753 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10754 | $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10755 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10756 | fi |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 10757 | for ac_func in getnameinfo |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10758 | do : |
| 10759 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
| 10760 | if test "x$ac_cv_func_getnameinfo" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10761 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10762 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10763 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10764 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10765 | fi |
| 10766 | done |
| 10767 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10768 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10769 | # checks for structures |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10770 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 10771 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
| 10772 | if test "${ac_cv_header_time+set}" = set; then : |
| 10773 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10774 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10775 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10776 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10777 | #include <sys/types.h> |
| 10778 | #include <sys/time.h> |
| 10779 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10780 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10781 | int |
| 10782 | main () |
| 10783 | { |
| 10784 | if ((struct tm *) 0) |
| 10785 | return 0; |
| 10786 | ; |
| 10787 | return 0; |
| 10788 | } |
| 10789 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10790 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10791 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10792 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10793 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10794 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10795 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10796 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10797 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 10798 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10799 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10800 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10801 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10802 | |
| 10803 | fi |
| 10804 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10805 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 10806 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
| 10807 | if test "${ac_cv_struct_tm+set}" = set; then : |
| 10808 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10809 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10810 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10811 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10812 | #include <sys/types.h> |
| 10813 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10814 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10815 | int |
| 10816 | main () |
| 10817 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10818 | struct tm tm; |
| 10819 | int *p = &tm.tm_sec; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10820 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10821 | ; |
| 10822 | return 0; |
| 10823 | } |
| 10824 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10825 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10826 | ac_cv_struct_tm=time.h |
| 10827 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10828 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10829 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10830 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10831 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10832 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
| 10833 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10834 | if test $ac_cv_struct_tm = sys/time.h; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10835 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10836 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10837 | |
| 10838 | fi |
| 10839 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10840 | 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] | 10841 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10842 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10843 | " |
| 10844 | if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10845 | |
| 10846 | cat >>confdefs.h <<_ACEOF |
| 10847 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 10848 | _ACEOF |
| 10849 | |
| 10850 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10851 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10852 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10853 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 10854 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10855 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10856 | |
| 10857 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10858 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 10859 | " |
| 10860 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
| 10861 | ac_have_decl=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10862 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10863 | ac_have_decl=0 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10864 | fi |
| 10865 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10866 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10867 | #define HAVE_DECL_TZNAME $ac_have_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10868 | _ACEOF |
| 10869 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10870 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 10871 | $as_echo_n "checking for tzname... " >&6; } |
| 10872 | if test "${ac_cv_var_tzname+set}" = set; then : |
| 10873 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10874 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10875 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10876 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10877 | #include <time.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10878 | #if !HAVE_DECL_TZNAME |
| 10879 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10880 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10881 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10882 | int |
| 10883 | main () |
| 10884 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10885 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10886 | ; |
| 10887 | return 0; |
| 10888 | } |
| 10889 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10890 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10891 | ac_cv_var_tzname=yes |
| 10892 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10893 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10894 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10895 | rm -f core conftest.err conftest.$ac_objext \ |
| 10896 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10897 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10898 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 10899 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10900 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10901 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10902 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10903 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10904 | fi |
| 10905 | fi |
| 10906 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10907 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
| 10908 | if test "x$ac_cv_member_struct_stat_st_rdev" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10909 | |
| 10910 | cat >>confdefs.h <<_ACEOF |
| 10911 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 10912 | _ACEOF |
| 10913 | |
| 10914 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10915 | fi |
| 10916 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10917 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
| 10918 | if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10919 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10920 | cat >>confdefs.h <<_ACEOF |
| 10921 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 10922 | _ACEOF |
| 10923 | |
| 10924 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10925 | fi |
| 10926 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10927 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
| 10928 | if test "x$ac_cv_member_struct_stat_st_flags" = x""yes; then : |
Hye-Shik Chang | 5f937a7 | 2005-06-02 13:09:30 +0000 | [diff] [blame] | 10929 | |
| 10930 | cat >>confdefs.h <<_ACEOF |
| 10931 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 10932 | _ACEOF |
| 10933 | |
| 10934 | |
| 10935 | fi |
| 10936 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10937 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
| 10938 | if test "x$ac_cv_member_struct_stat_st_gen" = x""yes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 10939 | |
| 10940 | cat >>confdefs.h <<_ACEOF |
| 10941 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 10942 | _ACEOF |
| 10943 | |
| 10944 | |
| 10945 | fi |
| 10946 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10947 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
| 10948 | if test "x$ac_cv_member_struct_stat_st_birthtime" = x""yes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 10949 | |
| 10950 | cat >>confdefs.h <<_ACEOF |
| 10951 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 10952 | _ACEOF |
| 10953 | |
| 10954 | |
| 10955 | fi |
| 10956 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10957 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
| 10958 | if test "x$ac_cv_member_struct_stat_st_blocks" = x""yes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10959 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10960 | cat >>confdefs.h <<_ACEOF |
| 10961 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 10962 | _ACEOF |
| 10963 | |
| 10964 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10965 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10966 | |
| 10967 | else |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10968 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10969 | *" fileblocks.$ac_objext "* ) ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 10970 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 10971 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10972 | esac |
| 10973 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10974 | fi |
| 10975 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10976 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10977 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10978 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 10979 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
| 10980 | if test "${ac_cv_header_time_altzone+set}" = set; then : |
| 10981 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10982 | else |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 10983 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10985 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10986 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10987 | int |
| 10988 | main () |
| 10989 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10990 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10991 | ; |
| 10992 | return 0; |
| 10993 | } |
| 10994 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10995 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10996 | ac_cv_header_time_altzone=yes |
| 10997 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 10998 | ac_cv_header_time_altzone=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10999 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11000 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11001 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11002 | fi |
| 11003 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11004 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 11005 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11006 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11007 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11008 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11009 | |
| 11010 | fi |
| 11011 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11012 | was_it_defined=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11013 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 11014 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 11015 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11016 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11017 | |
| 11018 | #include <sys/types.h> |
| 11019 | #include <sys/select.h> |
| 11020 | #include <sys/time.h> |
| 11021 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11022 | int |
| 11023 | main () |
| 11024 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11025 | ; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11026 | ; |
| 11027 | return 0; |
| 11028 | } |
| 11029 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11030 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11031 | |
| 11032 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11033 | $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] | 11034 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11035 | was_it_defined=yes |
| 11036 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11037 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11038 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11039 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 11040 | $as_echo "$was_it_defined" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11041 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11042 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 11043 | $as_echo_n "checking for addrinfo... " >&6; } |
| 11044 | if test "${ac_cv_struct_addrinfo+set}" = set; then : |
| 11045 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11046 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11047 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11048 | /* end confdefs.h. */ |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11049 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11050 | int |
| 11051 | main () |
| 11052 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11053 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11054 | ; |
| 11055 | return 0; |
| 11056 | } |
| 11057 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11058 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11059 | ac_cv_struct_addrinfo=yes |
| 11060 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11061 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11062 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11063 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11064 | fi |
| 11065 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11066 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 11067 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11068 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11069 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11070 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11071 | |
| 11072 | fi |
| 11073 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11074 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 11075 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
| 11076 | if test "${ac_cv_struct_sockaddr_storage+set}" = set; then : |
| 11077 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11078 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11079 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11080 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11081 | |
| 11082 | # include <sys/types.h> |
| 11083 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11084 | int |
| 11085 | main () |
| 11086 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11087 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11088 | ; |
| 11089 | return 0; |
| 11090 | } |
| 11091 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11092 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11093 | ac_cv_struct_sockaddr_storage=yes |
| 11094 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11095 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11096 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11097 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11098 | fi |
| 11099 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 11101 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11102 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11103 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11104 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11105 | |
| 11106 | fi |
| 11107 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11108 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11109 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 11111 | $as_echo_n "checking whether char is unsigned... " >&6; } |
| 11112 | if test "${ac_cv_c_char_unsigned+set}" = set; then : |
| 11113 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11114 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11116 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11117 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11118 | int |
| 11119 | main () |
| 11120 | { |
| 11121 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
| 11122 | test_array [0] = 0 |
| 11123 | |
| 11124 | ; |
| 11125 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11126 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11127 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11128 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11129 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11130 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11131 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11132 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11133 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11134 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11135 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 11136 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11137 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11138 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11139 | |
| 11140 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11141 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11142 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 11143 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
| 11144 | if test "${ac_cv_c_const+set}" = set; then : |
| 11145 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11146 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11147 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11148 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11149 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11150 | int |
| 11151 | main () |
| 11152 | { |
| 11153 | /* FIXME: Include the comments suggested by Paul. */ |
| 11154 | #ifndef __cplusplus |
| 11155 | /* Ultrix mips cc rejects this. */ |
| 11156 | typedef int charset[2]; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11157 | const charset cs; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11158 | /* SunOS 4.1.1 cc rejects this. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11159 | char const *const *pcpcc; |
| 11160 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11161 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 11162 | struct point {int x, y;}; |
| 11163 | static struct point const zero = {0,0}; |
| 11164 | /* AIX XL C 1.02.0.0 rejects this. |
| 11165 | It does not let you subtract one const X* pointer from another in |
| 11166 | an arm of an if-expression whose if-part is not a constant |
| 11167 | expression */ |
| 11168 | const char *g = "string"; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11169 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11170 | /* HPUX 7.0 cc rejects these. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11171 | ++pcpcc; |
| 11172 | ppc = (char**) pcpcc; |
| 11173 | pcpcc = (char const *const *) ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11174 | { /* SCO 3.2v4 cc rejects this. */ |
| 11175 | char *t; |
| 11176 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11177 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11178 | *t++ = 0; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11179 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11180 | } |
| 11181 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 11182 | int x[] = {25, 17}; |
| 11183 | const int *foo = &x[0]; |
| 11184 | ++foo; |
| 11185 | } |
| 11186 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 11187 | typedef const int *iptr; |
| 11188 | iptr p = 0; |
| 11189 | ++p; |
| 11190 | } |
| 11191 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 11192 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 11193 | struct s { int j; const int *ap[3]; }; |
| 11194 | struct s *b; b->j = 5; |
| 11195 | } |
| 11196 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 11197 | const int foo = 10; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11198 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11199 | } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11200 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11201 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11202 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11203 | ; |
| 11204 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11205 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11206 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11207 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11208 | ac_cv_c_const=yes |
| 11209 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11210 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11211 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11212 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11213 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 11215 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11216 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11217 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11218 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11219 | |
| 11220 | fi |
| 11221 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11222 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11223 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11224 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 11225 | $as_echo_n "checking for working volatile... " >&6; } |
| 11226 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11227 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11228 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11229 | int |
| 11230 | main () |
| 11231 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11232 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11233 | ; |
| 11234 | return 0; |
| 11235 | } |
| 11236 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11237 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11238 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11239 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11240 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11241 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11242 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11243 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11244 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11245 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11246 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11247 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11248 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11249 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 11251 | $as_echo_n "checking for working signed char... " >&6; } |
| 11252 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11253 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11254 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11255 | int |
| 11256 | main () |
| 11257 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11258 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11259 | ; |
| 11260 | return 0; |
| 11261 | } |
| 11262 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11263 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11264 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11265 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11266 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11267 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11268 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11269 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11270 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11271 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11273 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11274 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11275 | have_prototypes=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11276 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 11277 | $as_echo_n "checking for prototypes... " >&6; } |
| 11278 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11279 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11280 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11281 | int |
| 11282 | main () |
| 11283 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11284 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11285 | ; |
| 11286 | return 0; |
| 11287 | } |
| 11288 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11289 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11290 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11291 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11292 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11293 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11294 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11295 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11296 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 11297 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11298 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11299 | works=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11300 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 11301 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 11302 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11303 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11304 | |
| 11305 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11306 | int foo(int x, ...) { |
| 11307 | va_list va; |
| 11308 | va_start(va, x); |
| 11309 | va_arg(va, int); |
| 11310 | va_arg(va, char *); |
| 11311 | va_arg(va, double); |
| 11312 | return 0; |
| 11313 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11314 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11315 | int |
| 11316 | main () |
| 11317 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11318 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11319 | ; |
| 11320 | return 0; |
| 11321 | } |
| 11322 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11323 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11324 | |
| 11325 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11326 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11327 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11328 | works=yes |
| 11329 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11330 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11331 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11333 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11334 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11335 | # check for socketpair |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 11337 | $as_echo_n "checking for socketpair... " >&6; } |
| 11338 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11339 | /* end confdefs.h. */ |
| 11340 | |
| 11341 | #include <sys/types.h> |
| 11342 | #include <sys/socket.h> |
| 11343 | |
| 11344 | int |
| 11345 | main () |
| 11346 | { |
| 11347 | void *x=socketpair |
| 11348 | ; |
| 11349 | return 0; |
| 11350 | } |
| 11351 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11352 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11353 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11354 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11355 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11356 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11357 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11358 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11359 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11360 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11361 | |
| 11362 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11363 | 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] | 11364 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11365 | # check if sockaddr has sa_len member |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11366 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 11367 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 11368 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11369 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11370 | #include <sys/types.h> |
| 11371 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11372 | int |
| 11373 | main () |
| 11374 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11375 | struct sockaddr x; |
| 11376 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11377 | ; |
| 11378 | return 0; |
| 11379 | } |
| 11380 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11381 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11382 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11383 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11384 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11385 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11386 | |
| 11387 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11388 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11389 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11390 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11391 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11392 | 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] | 11393 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11394 | va_list_is_array=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11395 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 11396 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 11397 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11398 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11399 | |
| 11400 | #ifdef HAVE_STDARG_PROTOTYPES |
| 11401 | #include <stdarg.h> |
| 11402 | #else |
| 11403 | #include <varargs.h> |
| 11404 | #endif |
| 11405 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11406 | int |
| 11407 | main () |
| 11408 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11409 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11410 | ; |
| 11411 | return 0; |
| 11412 | } |
| 11413 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11414 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11415 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11416 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11417 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11418 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11419 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11420 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11421 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11422 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11423 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11424 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 11426 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11427 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11428 | # 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] | 11429 | |
| 11430 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11431 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
| 11432 | if test "x$ac_cv_func_gethostbyname_r" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11433 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11434 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 11435 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11436 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 11437 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11438 | OLD_CFLAGS=$CFLAGS |
| 11439 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11440 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11441 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11442 | |
| 11443 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11444 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11445 | int |
| 11446 | main () |
| 11447 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11448 | |
| 11449 | char *name; |
| 11450 | struct hostent *he, *res; |
| 11451 | char buffer[2048]; |
| 11452 | int buflen = 2048; |
| 11453 | int h_errnop; |
| 11454 | |
| 11455 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11456 | |
| 11457 | ; |
| 11458 | return 0; |
| 11459 | } |
| 11460 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11461 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11462 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11463 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11464 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11465 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11466 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11467 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11468 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11469 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11470 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11471 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11472 | |
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; } |
| 11475 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 11476 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 11477 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11478 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11479 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11480 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11481 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11482 | int |
| 11483 | main () |
| 11484 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11485 | |
| 11486 | char *name; |
| 11487 | struct hostent *he; |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11488 | char buffer[2048]; |
| 11489 | int buflen = 2048; |
| 11490 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11491 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11492 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11493 | |
| 11494 | ; |
| 11495 | return 0; |
| 11496 | } |
| 11497 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11498 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11499 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11500 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11501 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11502 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11503 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11504 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11505 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11506 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11507 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11508 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11509 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11510 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11511 | $as_echo "no" >&6; } |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 11512 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 11513 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 11514 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11515 | /* end confdefs.h. */ |
| 11516 | |
| 11517 | # include <netdb.h> |
| 11518 | |
| 11519 | int |
| 11520 | main () |
| 11521 | { |
| 11522 | |
| 11523 | char *name; |
| 11524 | struct hostent *he; |
| 11525 | struct hostent_data data; |
| 11526 | |
| 11527 | (void) gethostbyname_r(name, he, &data); |
| 11528 | |
| 11529 | ; |
| 11530 | return 0; |
| 11531 | } |
| 11532 | _ACEOF |
| 11533 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11534 | |
| 11535 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 11536 | |
| 11537 | |
| 11538 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 11539 | |
| 11540 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11541 | $as_echo "yes" >&6; } |
| 11542 | |
| 11543 | else |
| 11544 | |
| 11545 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11546 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11547 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11548 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11549 | 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] | 11550 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11551 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11552 | 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] | 11553 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11554 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11555 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11556 | CFLAGS=$OLD_CFLAGS |
| 11557 | |
| 11558 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11559 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11560 | for ac_func in gethostbyname |
| 11561 | do : |
| 11562 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
| 11563 | if test "x$ac_cv_func_gethostbyname" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11564 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11565 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11566 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11567 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11568 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11569 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11570 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11571 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11572 | fi |
| 11573 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11574 | |
| 11575 | |
| 11576 | |
| 11577 | |
| 11578 | |
| 11579 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11580 | # checks for system services |
| 11581 | # (none yet) |
| 11582 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11583 | # Linux requires this for correct f.p. operations |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11584 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
| 11585 | if test "x$ac_cv_func___fpu_control" = x""yes; then : |
| 11586 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11587 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11588 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 11589 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
| 11590 | if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then : |
| 11591 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11592 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11593 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11594 | LIBS="-lieee $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11595 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11596 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11597 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11598 | /* Override any GCC internal prototype to avoid an error. |
| 11599 | Use char because int might match the return type of a GCC |
| 11600 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11601 | #ifdef __cplusplus |
| 11602 | extern "C" |
| 11603 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11604 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11605 | int |
| 11606 | main () |
| 11607 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11608 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11609 | ; |
| 11610 | return 0; |
| 11611 | } |
| 11612 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11613 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11614 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11615 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11616 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11617 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11618 | rm -f core conftest.err conftest.$ac_objext \ |
| 11619 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11620 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11621 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11622 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 11623 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
| 11624 | if test "x$ac_cv_lib_ieee___fpu_control" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11625 | cat >>confdefs.h <<_ACEOF |
| 11626 | #define HAVE_LIBIEEE 1 |
| 11627 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11628 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11629 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11630 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11631 | fi |
| 11632 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11633 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11634 | fi |
| 11635 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11636 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11637 | # Check for --with-fpectl |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11638 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 11639 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11640 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11641 | # Check whether --with-fpectl was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11642 | if test "${with_fpectl+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11643 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11644 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11645 | then |
| 11646 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11647 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11648 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11649 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11650 | $as_echo "yes" >&6; } |
| 11651 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11652 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11653 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 11654 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11655 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11656 | $as_echo "no" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11657 | fi |
| 11658 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11659 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11660 | # check for --with-libm=... |
| 11661 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11662 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 11663 | Darwin) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 11664 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11665 | *) LIBM=-lm |
| 11666 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11667 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 11668 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11669 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11670 | # Check whether --with-libm was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11671 | if test "${with_libm+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11672 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11673 | if test "$withval" = no |
| 11674 | then LIBM= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11675 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 11676 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11677 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11678 | then LIBM=$withval |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11679 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 11680 | $as_echo "set LIBM=\"$withval\"" >&6; } |
| 11681 | 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] | 11682 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11683 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11684 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 11685 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11686 | fi |
| 11687 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11688 | |
| 11689 | # check for --with-libc=... |
| 11690 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11691 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 11692 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11693 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11694 | # Check whether --with-libc was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11695 | if test "${with_libc+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11696 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11697 | if test "$withval" = no |
| 11698 | then LIBC= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 11700 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11701 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11702 | then LIBC=$withval |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11703 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 11704 | $as_echo "set LIBC=\"$withval\"" >&6; } |
| 11705 | 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] | 11706 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11707 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11708 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 11709 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 11710 | fi |
| 11711 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11712 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11713 | # ************************************************** |
| 11714 | # * Check for various properties of floating point * |
| 11715 | # ************************************************** |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11716 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 11718 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
| 11719 | if test "${ac_cv_little_endian_double+set}" = set; then : |
| 11720 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11721 | else |
| 11722 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11723 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11724 | ac_cv_little_endian_double=no |
| 11725 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11726 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11727 | /* end confdefs.h. */ |
| 11728 | |
| 11729 | #include <string.h> |
| 11730 | int main() { |
| 11731 | double x = 9006104071832581.0; |
| 11732 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 11733 | return 0; |
| 11734 | else |
| 11735 | return 1; |
| 11736 | } |
| 11737 | |
| 11738 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11739 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11740 | ac_cv_little_endian_double=yes |
| 11741 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11742 | ac_cv_little_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11743 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11744 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11745 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11746 | fi |
| 11747 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11748 | fi |
| 11749 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 11751 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11752 | if test "$ac_cv_little_endian_double" = yes |
| 11753 | then |
| 11754 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11755 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11756 | |
| 11757 | fi |
| 11758 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11759 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 11760 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
| 11761 | if test "${ac_cv_big_endian_double+set}" = set; then : |
| 11762 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11763 | else |
| 11764 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11765 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11766 | ac_cv_big_endian_double=no |
| 11767 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11768 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11769 | /* end confdefs.h. */ |
| 11770 | |
| 11771 | #include <string.h> |
| 11772 | int main() { |
| 11773 | double x = 9006104071832581.0; |
| 11774 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 11775 | return 0; |
| 11776 | else |
| 11777 | return 1; |
| 11778 | } |
| 11779 | |
| 11780 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11781 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11782 | ac_cv_big_endian_double=yes |
| 11783 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11784 | ac_cv_big_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11785 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11786 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11787 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11788 | fi |
| 11789 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11790 | fi |
| 11791 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 11793 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11794 | if test "$ac_cv_big_endian_double" = yes |
| 11795 | then |
| 11796 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11797 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11798 | |
| 11799 | fi |
| 11800 | |
| 11801 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 11802 | # While Python doesn't currently have full support for these platforms |
| 11803 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 11804 | # conversions work. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11805 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 11806 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
| 11807 | if test "${ac_cv_mixed_endian_double+set}" = set; then : |
| 11808 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11809 | else |
| 11810 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11811 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11812 | ac_cv_mixed_endian_double=no |
| 11813 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11814 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11815 | /* end confdefs.h. */ |
| 11816 | |
| 11817 | #include <string.h> |
| 11818 | int main() { |
| 11819 | double x = 9006104071832581.0; |
| 11820 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 11821 | return 0; |
| 11822 | else |
| 11823 | return 1; |
| 11824 | } |
| 11825 | |
| 11826 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11827 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11828 | ac_cv_mixed_endian_double=yes |
| 11829 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11830 | ac_cv_mixed_endian_double=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11831 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11832 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11833 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11834 | fi |
| 11835 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11836 | fi |
| 11837 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 11839 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11840 | if test "$ac_cv_mixed_endian_double" = yes |
| 11841 | then |
| 11842 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11843 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11844 | |
| 11845 | fi |
| 11846 | |
| 11847 | # The short float repr introduced in Python 3.1 requires the |
| 11848 | # correctly-rounded string <-> double conversion functions from |
| 11849 | # Python/dtoa.c, which in turn require that the FPU uses 53-bit |
| 11850 | # 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] | 11851 | # 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] | 11852 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11853 | |
| 11854 | # This inline assembler syntax may also work for suncc and icc, |
| 11855 | # so we try it on all platforms. |
| 11856 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11857 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 11858 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 11859 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11860 | /* end confdefs.h. */ |
| 11861 | |
| 11862 | int |
| 11863 | main () |
| 11864 | { |
| 11865 | |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11866 | unsigned short cw; |
| 11867 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 11868 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11869 | |
| 11870 | ; |
| 11871 | return 0; |
| 11872 | } |
| 11873 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11874 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11875 | have_gcc_asm_for_x87=yes |
| 11876 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11877 | have_gcc_asm_for_x87=no |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11878 | fi |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11879 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11880 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 11881 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | a548dee | 2009-11-15 13:12:43 +0000 | [diff] [blame] | 11882 | if test "$have_gcc_asm_for_x87" = yes |
| 11883 | then |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11884 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11885 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11886 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11887 | fi |
Mark Dickinson | 7a3d864 | 2008-04-22 00:54:27 +0000 | [diff] [blame] | 11888 | |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11889 | # Detect whether system arithmetic is subject to x87-style double |
| 11890 | # rounding issues. The result of this test has little meaning on non |
| 11891 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 11892 | # mode is round-to-nearest and double rounding issues are present, and |
| 11893 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11894 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 11895 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | 99abd14 | 2009-10-24 13:44:16 +0000 | [diff] [blame] | 11896 | # $BASECFLAGS may affect the result |
| 11897 | ac_save_cc="$CC" |
| 11898 | CC="$CC $BASECFLAGS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11899 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11900 | ac_cv_x87_double_rounding=no |
| 11901 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11902 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11903 | /* end confdefs.h. */ |
| 11904 | |
| 11905 | #include <stdlib.h> |
| 11906 | #include <math.h> |
| 11907 | int main() { |
| 11908 | volatile double x, y, z; |
| 11909 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 11910 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 11911 | y = 1./x; |
| 11912 | if (y != 1.) |
| 11913 | exit(0); |
| 11914 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 11915 | x = 1e16; |
| 11916 | y = 2.99999; |
| 11917 | z = x + y; |
| 11918 | if (z != 1e16+4.) |
| 11919 | exit(0); |
| 11920 | /* both tests show evidence of double rounding */ |
| 11921 | exit(1); |
| 11922 | } |
| 11923 | |
| 11924 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11925 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11926 | ac_cv_x87_double_rounding=no |
| 11927 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11928 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11929 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11930 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11931 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11932 | fi |
| 11933 | |
Mark Dickinson | 99abd14 | 2009-10-24 13:44:16 +0000 | [diff] [blame] | 11934 | CC="$ac_save_cc" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11935 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 11936 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11937 | if test "$ac_cv_x87_double_rounding" = yes |
| 11938 | then |
| 11939 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11940 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 04b2723 | 2009-01-04 12:29:36 +0000 | [diff] [blame] | 11941 | |
| 11942 | fi |
| 11943 | |
Mark Dickinson | 1d6e2e1 | 2009-10-24 13:28:38 +0000 | [diff] [blame] | 11944 | # ************************************ |
| 11945 | # * Check for mathematical functions * |
| 11946 | # ************************************ |
| 11947 | |
| 11948 | LIBS_SAVE=$LIBS |
| 11949 | LIBS="$LIBS $LIBM" |
| 11950 | |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11951 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 11952 | # -0. on some architectures. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11953 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 11954 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
| 11955 | if test "${ac_cv_tanh_preserves_zero_sign+set}" = set; then : |
| 11956 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11957 | else |
| 11958 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11959 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11960 | ac_cv_tanh_preserves_zero_sign=no |
| 11961 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11963 | /* end confdefs.h. */ |
| 11964 | |
| 11965 | #include <math.h> |
Mark Dickinson | 7a3d864 | 2008-04-22 00:54:27 +0000 | [diff] [blame] | 11966 | #include <stdlib.h> |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11967 | int main() { |
| 11968 | /* return 0 if either negative zeros don't exist |
| 11969 | on this platform or if negative zeros exist |
| 11970 | and tanh(-0.) == -0. */ |
| 11971 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 11972 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 11973 | else exit(1); |
| 11974 | } |
| 11975 | |
| 11976 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11977 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11978 | ac_cv_tanh_preserves_zero_sign=yes |
| 11979 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11980 | ac_cv_tanh_preserves_zero_sign=no |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11981 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11982 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11983 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11984 | fi |
| 11985 | |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11986 | fi |
| 11987 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 11989 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11990 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 11991 | then |
| 11992 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 11993 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Mark Dickinson | 265d738 | 2008-04-21 22:32:24 +0000 | [diff] [blame] | 11994 | |
| 11995 | fi |
| 11996 | |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 11997 | 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] | 11998 | do : |
| 11999 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 12000 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 12001 | eval as_val=\$$as_ac_var |
| 12002 | if test "x$as_val" = x""yes; then : |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12003 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12004 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12005 | _ACEOF |
| 12006 | |
| 12007 | fi |
| 12008 | done |
| 12009 | |
Mark Dickinson | 65898e0 | 2009-09-05 10:27:00 +0000 | [diff] [blame] | 12010 | for ac_func in hypot lgamma log1p round tgamma |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12011 | do : |
| 12012 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 12013 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 12014 | eval as_val=\$$as_ac_var |
| 12015 | if test "x$as_val" = x""yes; then : |
Christian Heimes | 0a8143f | 2007-12-18 23:22:54 +0000 | [diff] [blame] | 12016 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12017 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Christian Heimes | 0a8143f | 2007-12-18 23:22:54 +0000 | [diff] [blame] | 12018 | _ACEOF |
| 12019 | |
| 12020 | fi |
| 12021 | done |
| 12022 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12023 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 12024 | " |
| 12025 | if test "x$ac_cv_have_decl_isinf" = x""yes; then : |
| 12026 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12027 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12028 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12029 | fi |
| 12030 | |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12031 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12032 | #define HAVE_DECL_ISINF $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12033 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12034 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 12035 | " |
| 12036 | if test "x$ac_cv_have_decl_isnan" = x""yes; then : |
| 12037 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12038 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12039 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12040 | fi |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12041 | |
| 12042 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12043 | #define HAVE_DECL_ISNAN $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12044 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12045 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 12046 | " |
| 12047 | if test "x$ac_cv_have_decl_isfinite" = x""yes; then : |
| 12048 | ac_have_decl=1 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12049 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12050 | ac_have_decl=0 |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12051 | fi |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12052 | |
| 12053 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12054 | #define HAVE_DECL_ISFINITE $ac_have_decl |
Mark Dickinson | d181e3a | 2009-01-04 13:57:26 +0000 | [diff] [blame] | 12055 | _ACEOF |
| 12056 | |
| 12057 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 12058 | LIBS=$LIBS_SAVE |
| 12059 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12060 | # For multiprocessing module, check that sem_open |
| 12061 | # actually works. For FreeBSD versions <= 7.2, |
| 12062 | # the kernel module that provides POSIX semaphores |
| 12063 | # isn't loaded by default, so an attempt to call |
| 12064 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12065 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 12066 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
| 12067 | if test "${ac_cv_posix_semaphores_enabled+set}" = set; then : |
| 12068 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12069 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12070 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12071 | ac_cv_posix_semaphores_enabled=yes |
| 12072 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12073 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12074 | /* end confdefs.h. */ |
| 12075 | |
| 12076 | #include <unistd.h> |
| 12077 | #include <fcntl.h> |
| 12078 | #include <stdio.h> |
| 12079 | #include <semaphore.h> |
| 12080 | #include <sys/stat.h> |
| 12081 | |
| 12082 | int main(void) { |
| 12083 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 12084 | if (a == SEM_FAILED) { |
| 12085 | perror("sem_open"); |
| 12086 | return 1; |
| 12087 | } |
| 12088 | sem_close(a); |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12089 | sem_unlink("/autoconf"); |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12090 | return 0; |
| 12091 | } |
| 12092 | |
| 12093 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12094 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12095 | ac_cv_posix_semaphores_enabled=yes |
| 12096 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12097 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12098 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12099 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12100 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12101 | fi |
| 12102 | |
| 12103 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12104 | fi |
| 12105 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12106 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 12107 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12108 | if test $ac_cv_posix_semaphores_enabled = no |
| 12109 | then |
| 12110 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12111 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12112 | |
| 12113 | fi |
| 12114 | |
| 12115 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12116 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 12117 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
| 12118 | if test "${ac_cv_broken_sem_getvalue+set}" = set; then : |
| 12119 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12120 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12121 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12122 | ac_cv_broken_sem_getvalue=yes |
| 12123 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12124 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12125 | /* end confdefs.h. */ |
| 12126 | |
| 12127 | #include <unistd.h> |
| 12128 | #include <fcntl.h> |
| 12129 | #include <stdio.h> |
| 12130 | #include <semaphore.h> |
| 12131 | #include <sys/stat.h> |
| 12132 | |
| 12133 | int main(void){ |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12134 | 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] | 12135 | int count; |
| 12136 | int res; |
| 12137 | if(a==SEM_FAILED){ |
| 12138 | perror("sem_open"); |
| 12139 | return 1; |
| 12140 | |
| 12141 | } |
| 12142 | res = sem_getvalue(a, &count); |
| 12143 | sem_close(a); |
Mark Dickinson | 59dc89e | 2009-12-13 21:06:06 +0000 | [diff] [blame] | 12144 | sem_unlink("/autocftw"); |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12145 | return res==-1 ? 1 : 0; |
| 12146 | } |
| 12147 | |
| 12148 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12149 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12150 | ac_cv_broken_sem_getvalue=no |
| 12151 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12152 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12153 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12154 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12155 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12156 | fi |
| 12157 | |
| 12158 | |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12159 | fi |
| 12160 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12161 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 12162 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12163 | if test $ac_cv_broken_sem_getvalue = yes |
| 12164 | then |
| 12165 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12166 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Mark Dickinson | c63392c | 2009-11-28 13:13:13 +0000 | [diff] [blame] | 12167 | |
| 12168 | fi |
| 12169 | |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12170 | # determine what size digit to use for Python's longs |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12171 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 12172 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12173 | # Check whether --enable-big-digits was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12174 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12175 | enableval=$enable_big_digits; case $enable_big_digits in |
| 12176 | yes) |
| 12177 | enable_big_digits=30 ;; |
| 12178 | no) |
| 12179 | enable_big_digits=15 ;; |
| 12180 | 15|30) |
| 12181 | ;; |
| 12182 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12183 | 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] | 12184 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 12186 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12187 | |
| 12188 | cat >>confdefs.h <<_ACEOF |
| 12189 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 12190 | _ACEOF |
| 12191 | |
| 12192 | |
| 12193 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 12195 | $as_echo "no value specified" >&6; } |
Mark Dickinson | efc82f7 | 2009-03-20 15:51:55 +0000 | [diff] [blame] | 12196 | fi |
| 12197 | |
| 12198 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12199 | # check for wchar.h |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12200 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
| 12201 | if test "x$ac_cv_header_wchar_h" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12202 | |
| 12203 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12204 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12205 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12206 | wchar_h="yes" |
| 12207 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12208 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12209 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12210 | |
| 12211 | fi |
| 12212 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12213 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12214 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12215 | # determine wchar_t size |
| 12216 | if test "$wchar_h" = yes |
| 12217 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12218 | # 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] | 12219 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 12220 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 12221 | # This bug is HP SR number 8606223364. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12222 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 12223 | $as_echo_n "checking size of wchar_t... " >&6; } |
| 12224 | if test "${ac_cv_sizeof_wchar_t+set}" = set; then : |
| 12225 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12226 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12227 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 12228 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12229 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12230 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12231 | if test "$ac_cv_type_wchar_t" = yes; then |
| 12232 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 12233 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 12234 | { as_fn_set_status 77 |
| 12235 | as_fn_error "cannot compute sizeof (wchar_t) |
| 12236 | See \`config.log' for more details." "$LINENO" 5; }; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12237 | else |
| 12238 | ac_cv_sizeof_wchar_t=0 |
| 12239 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12240 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12241 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12242 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12243 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 12244 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12245 | |
| 12246 | |
| 12247 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12248 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12249 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12250 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12251 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12252 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12253 | fi |
| 12254 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12255 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 12256 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12257 | have_ucs4_tcl=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12258 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12259 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12260 | |
| 12261 | #include <tcl.h> |
| 12262 | #if TCL_UTF_MAX != 6 |
| 12263 | # error "NOT UCS4_TCL" |
| 12264 | #endif |
| 12265 | int |
| 12266 | main () |
| 12267 | { |
| 12268 | |
| 12269 | ; |
| 12270 | return 0; |
| 12271 | } |
| 12272 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12273 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12274 | |
| 12275 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12276 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12277 | |
| 12278 | have_ucs4_tcl=yes |
| 12279 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12280 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12281 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12282 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 12283 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12284 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12285 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12286 | if test "$wchar_h" = yes |
| 12287 | then |
| 12288 | # check whether wchar_t is signed or not |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12289 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 12290 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
| 12291 | if test "${ac_cv_wchar_t_signed+set}" = set; then : |
| 12292 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12293 | else |
| 12294 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12295 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12296 | ac_cv_wchar_t_signed=yes |
| 12297 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12298 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12299 | /* end confdefs.h. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12300 | |
| 12301 | #include <wchar.h> |
| 12302 | int main() |
| 12303 | { |
Martin v. Löwis | 44fe0e4 | 2006-04-11 07:15:30 +0000 | [diff] [blame] | 12304 | /* Success: exit code 0 */ |
| 12305 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12306 | } |
| 12307 | |
| 12308 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12309 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12310 | ac_cv_wchar_t_signed=yes |
| 12311 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12312 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12313 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12314 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12315 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12316 | fi |
| 12317 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12318 | fi |
| 12319 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12320 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 12321 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12322 | fi |
| 12323 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12324 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type to use for unicode" >&5 |
| 12325 | $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] | 12326 | # Check whether --enable-unicode was given. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12327 | if test "${enable_unicode+set}" = set; then : |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12328 | enableval=$enable_unicode; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12329 | else |
| 12330 | enable_unicode=yes |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12331 | fi |
| 12332 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12333 | |
| 12334 | if test $enable_unicode = yes |
| 12335 | then |
Martin v. Löwis | fd91779 | 2001-06-27 20:22:04 +0000 | [diff] [blame] | 12336 | # Without any arguments, Py_UNICODE defaults to two-byte mode |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12337 | case "$have_ucs4_tcl" in |
| 12338 | yes) enable_unicode="ucs4" |
| 12339 | ;; |
| 12340 | *) enable_unicode="ucs2" |
| 12341 | ;; |
| 12342 | esac |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12343 | fi |
| 12344 | |
Martin v. Löwis | 0036cba | 2002-04-12 09:58:45 +0000 | [diff] [blame] | 12345 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12346 | case "$enable_unicode" in |
| 12347 | ucs2) unicode_size="2" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12348 | $as_echo "#define Py_UNICODE_SIZE 2" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12349 | |
| 12350 | ;; |
| 12351 | ucs4) unicode_size="4" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12352 | $as_echo "#define Py_UNICODE_SIZE 4" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12353 | |
| 12354 | ;; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12355 | *) 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] | 12356 | esac |
| 12357 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12358 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12359 | |
| 12360 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12361 | if test "$enable_unicode" = "no" |
| 12362 | then |
Martin v. Löwis | 339d0f7 | 2001-08-17 18:39:25 +0000 | [diff] [blame] | 12363 | UNICODE_OBJS="" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12364 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not used" >&5 |
| 12365 | $as_echo "not used" >&6; } |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12366 | else |
Martin v. Löwis | 339d0f7 | 2001-08-17 18:39:25 +0000 | [diff] [blame] | 12367 | UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12368 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12369 | $as_echo "#define Py_USING_UNICODE 1" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12370 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12371 | |
| 12372 | # wchar_t is only usable if it maps to an unsigned type |
| 12373 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 12374 | -a "$ac_cv_wchar_t_signed" = "no" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12375 | then |
| 12376 | PY_UNICODE_TYPE="wchar_t" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12377 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12378 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12379 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12380 | $as_echo "#define PY_UNICODE_TYPE wchar_t" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12381 | |
| 12382 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 12383 | then |
| 12384 | PY_UNICODE_TYPE="unsigned short" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12385 | $as_echo "#define PY_UNICODE_TYPE unsigned short" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12386 | |
| 12387 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 12388 | then |
| 12389 | PY_UNICODE_TYPE="unsigned long" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12390 | $as_echo "#define PY_UNICODE_TYPE unsigned long" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12391 | |
| 12392 | else |
| 12393 | PY_UNICODE_TYPE="no type found" |
| 12394 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12395 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PY_UNICODE_TYPE" >&5 |
| 12396 | $as_echo "$PY_UNICODE_TYPE" >&6; } |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12397 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12398 | |
| 12399 | # check for endianness |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12400 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 12401 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
| 12402 | if test "${ac_cv_c_bigendian+set}" = set; then : |
| 12403 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12404 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12405 | ac_cv_c_bigendian=unknown |
| 12406 | # See if we're dealing with a universal compiler. |
| 12407 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12408 | /* end confdefs.h. */ |
| 12409 | #ifndef __APPLE_CC__ |
| 12410 | not a universal capable compiler |
| 12411 | #endif |
| 12412 | typedef int dummy; |
| 12413 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12414 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12415 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12416 | |
| 12417 | # Check for potential -arch flags. It is not universal unless |
| 12418 | # there are at least two -arch flags with different values. |
| 12419 | ac_arch= |
| 12420 | ac_prev= |
| 12421 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 12422 | if test -n "$ac_prev"; then |
| 12423 | case $ac_word in |
| 12424 | i?86 | x86_64 | ppc | ppc64) |
| 12425 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 12426 | ac_arch=$ac_word |
| 12427 | else |
| 12428 | ac_cv_c_bigendian=universal |
| 12429 | break |
| 12430 | fi |
| 12431 | ;; |
| 12432 | esac |
| 12433 | ac_prev= |
| 12434 | elif test "x$ac_word" = "x-arch"; then |
| 12435 | ac_prev=arch |
| 12436 | fi |
| 12437 | done |
| 12438 | fi |
| 12439 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12440 | if test $ac_cv_c_bigendian = unknown; then |
| 12441 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 12442 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12443 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12444 | #include <sys/types.h> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12445 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12446 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12447 | int |
| 12448 | main () |
| 12449 | { |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12450 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 12451 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 12452 | && LITTLE_ENDIAN) |
| 12453 | bogus endian macros |
| 12454 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12455 | |
| 12456 | ; |
| 12457 | return 0; |
| 12458 | } |
| 12459 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12460 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12461 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12462 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12463 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12464 | #include <sys/types.h> |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12465 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12466 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12467 | int |
| 12468 | main () |
| 12469 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12470 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12471 | not big endian |
| 12472 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12473 | |
| 12474 | ; |
| 12475 | return 0; |
| 12476 | } |
| 12477 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12478 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12479 | ac_cv_c_bigendian=yes |
| 12480 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12481 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12482 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12483 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12484 | fi |
| 12485 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12486 | fi |
| 12487 | if test $ac_cv_c_bigendian = unknown; then |
| 12488 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 12489 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12490 | /* end confdefs.h. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12491 | #include <limits.h> |
| 12492 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12493 | int |
| 12494 | main () |
| 12495 | { |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12496 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 12497 | bogus endian macros |
| 12498 | #endif |
| 12499 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12500 | ; |
| 12501 | return 0; |
| 12502 | } |
| 12503 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12504 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12505 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 12506 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12507 | /* end confdefs.h. */ |
| 12508 | #include <limits.h> |
| 12509 | |
| 12510 | int |
| 12511 | main () |
| 12512 | { |
| 12513 | #ifndef _BIG_ENDIAN |
| 12514 | not big endian |
| 12515 | #endif |
| 12516 | |
| 12517 | ; |
| 12518 | return 0; |
| 12519 | } |
| 12520 | _ACEOF |
| 12521 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12522 | ac_cv_c_bigendian=yes |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 12523 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12524 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12525 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12526 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12527 | fi |
| 12528 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12529 | fi |
| 12530 | if test $ac_cv_c_bigendian = unknown; then |
| 12531 | # Compile a test program. |
| 12532 | if test "$cross_compiling" = yes; then : |
| 12533 | # Try to guess by grepping values from an object file. |
| 12534 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12535 | /* end confdefs.h. */ |
| 12536 | short int ascii_mm[] = |
| 12537 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 12538 | short int ascii_ii[] = |
| 12539 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 12540 | int use_ascii (int i) { |
| 12541 | return ascii_mm[i] + ascii_ii[i]; |
| 12542 | } |
| 12543 | short int ebcdic_ii[] = |
| 12544 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 12545 | short int ebcdic_mm[] = |
| 12546 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 12547 | int use_ebcdic (int i) { |
| 12548 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 12549 | } |
| 12550 | extern int foo; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12551 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12552 | int |
| 12553 | main () |
| 12554 | { |
| 12555 | return use_ascii (foo) == use_ebcdic (foo); |
| 12556 | ; |
| 12557 | return 0; |
| 12558 | } |
| 12559 | _ACEOF |
| 12560 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12561 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 12562 | ac_cv_c_bigendian=yes |
| 12563 | fi |
| 12564 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 12565 | if test "$ac_cv_c_bigendian" = unknown; then |
| 12566 | ac_cv_c_bigendian=no |
| 12567 | else |
| 12568 | # finding both strings is unlikely to happen, but who knows? |
| 12569 | ac_cv_c_bigendian=unknown |
| 12570 | fi |
| 12571 | fi |
| 12572 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12573 | 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] | 12574 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12575 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12576 | /* end confdefs.h. */ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12577 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12578 | int |
| 12579 | main () |
| 12580 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12581 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12582 | /* Are we little or big endian? From Harbison&Steele. */ |
| 12583 | union |
| 12584 | { |
| 12585 | long int l; |
| 12586 | char c[sizeof (long int)]; |
| 12587 | } u; |
| 12588 | u.l = 1; |
| 12589 | return u.c[sizeof (long int) - 1] == 1; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12590 | |
| 12591 | ; |
| 12592 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12593 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12594 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12595 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12596 | ac_cv_c_bigendian=no |
| 12597 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12598 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12599 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12600 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12601 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12602 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12603 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12604 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12605 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12606 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 12607 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 12608 | case $ac_cv_c_bigendian in #( |
| 12609 | yes) |
| 12610 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 12611 | ;; #( |
| 12612 | no) |
| 12613 | ;; #( |
| 12614 | universal) |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 12615 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12616 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 12617 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12618 | ;; #( |
| 12619 | *) |
| 12620 | as_fn_error "unknown endianness |
| 12621 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
| 12622 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12623 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12624 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12625 | # Check whether right shifting a negative integer extends the sign bit |
| 12626 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12627 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 12628 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
| 12629 | if test "${ac_cv_rshift_extends_sign+set}" = set; then : |
| 12630 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12631 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12632 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12633 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12634 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12635 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12636 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12637 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12638 | |
| 12639 | int main() |
| 12640 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12641 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12642 | } |
| 12643 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12644 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12645 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12646 | ac_cv_rshift_extends_sign=yes |
| 12647 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12648 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12649 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12650 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12651 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12652 | fi |
| 12653 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12654 | fi |
| 12655 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12656 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 12657 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12658 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12659 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12660 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12661 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12662 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12663 | fi |
| 12664 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12665 | # check for getc_unlocked and related locking functions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12666 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 12667 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
| 12668 | if test "${ac_cv_have_getc_unlocked+set}" = set; then : |
| 12669 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12670 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12671 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12672 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12673 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12674 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12675 | int |
| 12676 | main () |
| 12677 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12678 | |
| 12679 | FILE *f = fopen("/dev/null", "r"); |
| 12680 | flockfile(f); |
| 12681 | getc_unlocked(f); |
| 12682 | funlockfile(f); |
| 12683 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12684 | ; |
| 12685 | return 0; |
| 12686 | } |
| 12687 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12688 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12689 | ac_cv_have_getc_unlocked=yes |
| 12690 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12691 | ac_cv_have_getc_unlocked=no |
| 12692 | fi |
| 12693 | rm -f core conftest.err conftest.$ac_objext \ |
| 12694 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12695 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12696 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 12698 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12699 | if test "$ac_cv_have_getc_unlocked" = yes |
| 12700 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12701 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12702 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12703 | |
| 12704 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12705 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12706 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12707 | # save the value of LIBS so we don't actually link Python with readline |
| 12708 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12709 | |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12710 | # On some systems we need to link readline to a termcap compatible |
| 12711 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 12712 | # with setup.py. |
| 12713 | py_cv_lib_readline=no |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 12715 | $as_echo_n "checking how to link readline libs... " >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12716 | for py_libtermcap in "" ncursesw ncurses curses termcap; do |
| 12717 | if test -z "$py_libtermcap"; then |
| 12718 | READLINE_LIBS="-lreadline" |
| 12719 | else |
| 12720 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 12721 | fi |
| 12722 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12723 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12724 | /* end confdefs.h. */ |
| 12725 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12726 | /* Override any GCC internal prototype to avoid an error. |
| 12727 | Use char because int might match the return type of a GCC |
| 12728 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12729 | #ifdef __cplusplus |
| 12730 | extern "C" |
| 12731 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12732 | char readline (); |
| 12733 | int |
| 12734 | main () |
| 12735 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12736 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12737 | ; |
| 12738 | return 0; |
| 12739 | } |
| 12740 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12741 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12742 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12743 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12744 | rm -f core conftest.err conftest.$ac_objext \ |
| 12745 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12746 | if test $py_cv_lib_readline = yes; then |
| 12747 | break |
| 12748 | fi |
| 12749 | done |
| 12750 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 12751 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | e080cdf | 2008-09-07 19:19:04 +0000 | [diff] [blame] | 12752 | if test $py_cv_lib_readline = no; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12753 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 12754 | $as_echo "none" >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12755 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12756 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 12757 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | cc023f1 | 2008-09-07 05:15:58 +0000 | [diff] [blame] | 12758 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12759 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12760 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12761 | fi |
| 12762 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12763 | # check for readline 2.1 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12764 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 12765 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
| 12766 | if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then : |
| 12767 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12768 | else |
| 12769 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12770 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12771 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12772 | /* end confdefs.h. */ |
| 12773 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12774 | /* Override any GCC internal prototype to avoid an error. |
| 12775 | Use char because int might match the return type of a GCC |
| 12776 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12777 | #ifdef __cplusplus |
| 12778 | extern "C" |
| 12779 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12780 | char rl_callback_handler_install (); |
| 12781 | int |
| 12782 | main () |
| 12783 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12784 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12785 | ; |
| 12786 | return 0; |
| 12787 | } |
| 12788 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12789 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12790 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 12791 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12792 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12793 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12794 | rm -f core conftest.err conftest.$ac_objext \ |
| 12795 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12796 | LIBS=$ac_check_lib_save_LIBS |
| 12797 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 12799 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
| 12800 | if test "x$ac_cv_lib_readline_rl_callback_handler_install" = x""yes; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12801 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12802 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12803 | |
| 12804 | fi |
| 12805 | |
| 12806 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12807 | # check for readline 2.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12808 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12809 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12810 | #include <readline/readline.h> |
| 12811 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12812 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12813 | have_readline=yes |
| 12814 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12815 | have_readline=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 12816 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12817 | fi |
| 12818 | rm -f conftest.err conftest.$ac_ext |
| 12819 | if test $have_readline = yes |
| 12820 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12821 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12822 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12823 | #include <readline/readline.h> |
| 12824 | |
| 12825 | _ACEOF |
| 12826 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12827 | $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] | 12828 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12829 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12830 | |
| 12831 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 12832 | rm -f conftest* |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12833 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12834 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12835 | /* end confdefs.h. */ |
| 12836 | #include <readline/readline.h> |
| 12837 | |
| 12838 | _ACEOF |
| 12839 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12840 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12841 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12842 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d9ff74e | 2009-10-26 19:16:46 +0000 | [diff] [blame] | 12843 | |
| 12844 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 12845 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12846 | |
| 12847 | fi |
| 12848 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12849 | # check for readline 4.0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12850 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 12851 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
| 12852 | if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then : |
| 12853 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12854 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12855 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12856 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12857 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12858 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12859 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12860 | /* Override any GCC internal prototype to avoid an error. |
| 12861 | Use char because int might match the return type of a GCC |
| 12862 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12863 | #ifdef __cplusplus |
| 12864 | extern "C" |
| 12865 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12866 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12867 | int |
| 12868 | main () |
| 12869 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12870 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12871 | ; |
| 12872 | return 0; |
| 12873 | } |
| 12874 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12875 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12876 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12877 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12878 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12879 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12880 | rm -f core conftest.err conftest.$ac_objext \ |
| 12881 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12882 | LIBS=$ac_check_lib_save_LIBS |
| 12883 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12884 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 12885 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
| 12886 | if test "x$ac_cv_lib_readline_rl_pre_input_hook" = x""yes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12887 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12888 | $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] | 12889 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12890 | fi |
| 12891 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12892 | |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12893 | # also in 4.0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12894 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 12895 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
| 12896 | if test "${ac_cv_lib_readline_rl_completion_display_matches_hook+set}" = set; then : |
| 12897 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12898 | else |
| 12899 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12900 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12901 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12902 | /* end confdefs.h. */ |
| 12903 | |
| 12904 | /* Override any GCC internal prototype to avoid an error. |
| 12905 | Use char because int might match the return type of a GCC |
| 12906 | builtin and then its argument prototype would still apply. */ |
| 12907 | #ifdef __cplusplus |
| 12908 | extern "C" |
| 12909 | #endif |
| 12910 | char rl_completion_display_matches_hook (); |
| 12911 | int |
| 12912 | main () |
| 12913 | { |
| 12914 | return rl_completion_display_matches_hook (); |
| 12915 | ; |
| 12916 | return 0; |
| 12917 | } |
| 12918 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12919 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12920 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 12921 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12922 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12923 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12924 | rm -f core conftest.err conftest.$ac_objext \ |
| 12925 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12926 | LIBS=$ac_check_lib_save_LIBS |
| 12927 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12928 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 12929 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
| 12930 | if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = x""yes; then : |
Martin v. Löwis | 58bd49f | 2007-09-04 13:13:14 +0000 | [diff] [blame] | 12931 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12932 | $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] | 12933 | |
| 12934 | fi |
| 12935 | |
| 12936 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12937 | # check for readline 4.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12938 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 12939 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
| 12940 | if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then : |
| 12941 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12942 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12943 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | ff7b2d5 | 2008-09-03 05:57:48 +0000 | [diff] [blame] | 12944 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12945 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12946 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12947 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12948 | /* Override any GCC internal prototype to avoid an error. |
| 12949 | Use char because int might match the return type of a GCC |
| 12950 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12951 | #ifdef __cplusplus |
| 12952 | extern "C" |
| 12953 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12954 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12955 | int |
| 12956 | main () |
| 12957 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 12958 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12959 | ; |
| 12960 | return 0; |
| 12961 | } |
| 12962 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12963 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12964 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12965 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12966 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12967 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12968 | rm -f core conftest.err conftest.$ac_objext \ |
| 12969 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12970 | LIBS=$ac_check_lib_save_LIBS |
| 12971 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12972 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 12973 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
| 12974 | if test "x$ac_cv_lib_readline_rl_completion_matches" = x""yes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12975 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12976 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12977 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12978 | fi |
| 12979 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 12980 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12981 | # also in readline 4.2 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12982 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12983 | /* end confdefs.h. */ |
| 12984 | #include <readline/readline.h> |
| 12985 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12986 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12987 | have_readline=yes |
| 12988 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12989 | have_readline=no |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 12990 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12991 | fi |
| 12992 | rm -f conftest.err conftest.$ac_ext |
| 12993 | if test $have_readline = yes |
| 12994 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 12995 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12996 | /* end confdefs.h. */ |
| 12997 | #include <readline/readline.h> |
| 12998 | |
| 12999 | _ACEOF |
| 13000 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13001 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13002 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13003 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13004 | |
| 13005 | fi |
Marc-André Lemburg | 6d5e579 | 2010-04-30 17:20:14 +0000 | [diff] [blame] | 13006 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13007 | |
| 13008 | fi |
| 13009 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 13010 | # End of readline checks: restore LIBS |
| 13011 | LIBS=$LIBS_no_readline |
| 13012 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13013 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 13014 | $as_echo_n "checking for broken nice()... " >&6; } |
| 13015 | if test "${ac_cv_broken_nice+set}" = set; then : |
| 13016 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13017 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13018 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13019 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 13020 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13021 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13022 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13023 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13024 | |
| 13025 | int main() |
| 13026 | { |
| 13027 | int val1 = nice(1); |
| 13028 | if (val1 != -1 && val1 == nice(2)) |
| 13029 | exit(0); |
| 13030 | exit(1); |
| 13031 | } |
| 13032 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13033 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13034 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13035 | ac_cv_broken_nice=yes |
| 13036 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13037 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13038 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13039 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13040 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13041 | fi |
| 13042 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13043 | fi |
| 13044 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13045 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 13046 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13047 | if test "$ac_cv_broken_nice" = yes |
| 13048 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13049 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13050 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13051 | |
| 13052 | fi |
| 13053 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13054 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 13055 | $as_echo_n "checking for broken poll()... " >&6; } |
| 13056 | if test "${ac_cv_broken_poll+set}" = set; then : |
| 13057 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13058 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13059 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13060 | ac_cv_broken_poll=no |
| 13061 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13062 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13063 | /* end confdefs.h. */ |
| 13064 | |
| 13065 | #include <poll.h> |
| 13066 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13067 | int main() |
| 13068 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13069 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13070 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13071 | |
| 13072 | close (42); |
| 13073 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13074 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13075 | if (poll_test < 0) |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13076 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13077 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13078 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13079 | else |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13080 | return 1; |
| 13081 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13082 | |
| 13083 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13084 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13085 | ac_cv_broken_poll=yes |
| 13086 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13087 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13088 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13089 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13090 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13091 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13092 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13093 | fi |
| 13094 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13095 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 13096 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13097 | if test "$ac_cv_broken_poll" = yes |
| 13098 | then |
| 13099 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13100 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13101 | |
| 13102 | fi |
| 13103 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13104 | # 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] | 13105 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 13106 | # tzname[] |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13107 | 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] | 13108 | #include <$ac_cv_struct_tm> |
| 13109 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13110 | " |
| 13111 | if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13112 | |
| 13113 | cat >>confdefs.h <<_ACEOF |
| 13114 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 13115 | _ACEOF |
| 13116 | |
| 13117 | |
| 13118 | fi |
| 13119 | |
| 13120 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 13121 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13122 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13123 | |
| 13124 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13125 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 13126 | " |
| 13127 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
| 13128 | ac_have_decl=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13129 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13130 | ac_have_decl=0 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13131 | fi |
| 13132 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13133 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13134 | #define HAVE_DECL_TZNAME $ac_have_decl |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13135 | _ACEOF |
| 13136 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13137 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 13138 | $as_echo_n "checking for tzname... " >&6; } |
| 13139 | if test "${ac_cv_var_tzname+set}" = set; then : |
| 13140 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13141 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13142 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13143 | /* end confdefs.h. */ |
| 13144 | #include <time.h> |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13145 | #if !HAVE_DECL_TZNAME |
| 13146 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13147 | #endif |
| 13148 | |
| 13149 | int |
| 13150 | main () |
| 13151 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13152 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13153 | ; |
| 13154 | return 0; |
| 13155 | } |
| 13156 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13157 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13158 | ac_cv_var_tzname=yes |
| 13159 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13160 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13161 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13162 | rm -f core conftest.err conftest.$ac_objext \ |
| 13163 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13164 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13165 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 13166 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13167 | if test $ac_cv_var_tzname = yes; then |
| 13168 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13169 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13170 | |
| 13171 | fi |
| 13172 | fi |
| 13173 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13174 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13175 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 13177 | $as_echo_n "checking for working tzset()... " >&6; } |
| 13178 | if test "${ac_cv_working_tzset+set}" = set; then : |
| 13179 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13180 | else |
| 13181 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13182 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13183 | ac_cv_working_tzset=no |
| 13184 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13185 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13186 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13187 | |
| 13188 | #include <stdlib.h> |
| 13189 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13190 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13191 | |
| 13192 | #if HAVE_TZNAME |
| 13193 | extern char *tzname[]; |
| 13194 | #endif |
| 13195 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13196 | int main() |
| 13197 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13198 | /* Note that we need to ensure that not only does tzset(3) |
| 13199 | do 'something' with localtime, but it works as documented |
| 13200 | 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] | 13201 | This includes making sure that tzname is set properly if |
| 13202 | tm->tm_zone does not exist since it is the alternative way |
| 13203 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13204 | |
| 13205 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13206 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13207 | */ |
| 13208 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13209 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13210 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 13211 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13212 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13213 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13214 | if (localtime(&groundhogday)->tm_hour != 0) |
| 13215 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13216 | #if HAVE_TZNAME |
| 13217 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 13218 | if (strcmp(tzname[0], "UTC") || |
| 13219 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 13220 | exit(1); |
| 13221 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13222 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13223 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13224 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13225 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13226 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13227 | #if HAVE_TZNAME |
| 13228 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 13229 | exit(1); |
| 13230 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13231 | |
| 13232 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 13233 | tzset(); |
| 13234 | if (localtime(&groundhogday)->tm_hour != 11) |
| 13235 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13236 | #if HAVE_TZNAME |
| 13237 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 13238 | exit(1); |
| 13239 | #endif |
| 13240 | |
| 13241 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13242 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 13243 | exit(1); |
| 13244 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 13245 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13246 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13247 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13248 | exit(0); |
| 13249 | } |
| 13250 | |
| 13251 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13252 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13253 | ac_cv_working_tzset=yes |
| 13254 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13255 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13256 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13257 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13258 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13259 | fi |
| 13260 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13261 | fi |
| 13262 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13263 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 13264 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13265 | if test "$ac_cv_working_tzset" = yes |
| 13266 | then |
| 13267 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13268 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13269 | |
| 13270 | fi |
| 13271 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13272 | # Look for subsecond timestamps in struct stat |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13273 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 13274 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
| 13275 | if test "${ac_cv_stat_tv_nsec+set}" = set; then : |
| 13276 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13277 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13278 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13279 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13280 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13281 | int |
| 13282 | main () |
| 13283 | { |
| 13284 | |
| 13285 | struct stat st; |
| 13286 | st.st_mtim.tv_nsec = 1; |
| 13287 | |
| 13288 | ; |
| 13289 | return 0; |
| 13290 | } |
| 13291 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13292 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 13293 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13294 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13295 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13296 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13297 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13298 | fi |
| 13299 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13300 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 13301 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13302 | if test "$ac_cv_stat_tv_nsec" = yes |
| 13303 | then |
| 13304 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13305 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13306 | |
| 13307 | fi |
| 13308 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13309 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13310 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 13311 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
| 13312 | if test "${ac_cv_stat_tv_nsec2+set}" = set; then : |
| 13313 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13314 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13315 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13316 | /* end confdefs.h. */ |
| 13317 | #include <sys/stat.h> |
| 13318 | int |
| 13319 | main () |
| 13320 | { |
| 13321 | |
| 13322 | struct stat st; |
| 13323 | st.st_mtimespec.tv_nsec = 1; |
| 13324 | |
| 13325 | ; |
| 13326 | return 0; |
| 13327 | } |
| 13328 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13329 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13330 | ac_cv_stat_tv_nsec2=yes |
| 13331 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13332 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13333 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13334 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13335 | fi |
| 13336 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13337 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 13338 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13339 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 13340 | then |
| 13341 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13342 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13343 | |
| 13344 | fi |
| 13345 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13346 | # 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] | 13347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 13348 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
| 13349 | if test "${ac_cv_mvwdelch_is_expression+set}" = set; then : |
| 13350 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13351 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13352 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13353 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13354 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13355 | int |
| 13356 | main () |
| 13357 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13358 | |
| 13359 | int rtn; |
| 13360 | rtn = mvwdelch(0,0,0); |
| 13361 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13362 | ; |
| 13363 | return 0; |
| 13364 | } |
| 13365 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13366 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13367 | ac_cv_mvwdelch_is_expression=yes |
| 13368 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13369 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13370 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13371 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13372 | fi |
| 13373 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 13375 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13376 | |
| 13377 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 13378 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13379 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13380 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13381 | |
| 13382 | fi |
| 13383 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13384 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 13385 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
| 13386 | if test "${ac_cv_window_has_flags+set}" = set; then : |
| 13387 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13388 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13389 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13390 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13391 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13392 | int |
| 13393 | main () |
| 13394 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13395 | |
| 13396 | WINDOW *w; |
| 13397 | w->_flags = 0; |
| 13398 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13399 | ; |
| 13400 | return 0; |
| 13401 | } |
| 13402 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13403 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13404 | ac_cv_window_has_flags=yes |
| 13405 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13406 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13407 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13408 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13409 | fi |
| 13410 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13411 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 13412 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13413 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13414 | |
| 13415 | if test "$ac_cv_window_has_flags" = yes |
| 13416 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13417 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13418 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13419 | |
| 13420 | fi |
| 13421 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13422 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 13423 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 13424 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13425 | /* end confdefs.h. */ |
| 13426 | #include <curses.h> |
| 13427 | int |
| 13428 | main () |
| 13429 | { |
| 13430 | void *x=is_term_resized |
| 13431 | ; |
| 13432 | return 0; |
| 13433 | } |
| 13434 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13435 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13436 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13437 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13438 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13439 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13440 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13441 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13442 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13443 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13444 | |
| 13445 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13446 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13447 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13448 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 13449 | $as_echo_n "checking for resize_term... " >&6; } |
| 13450 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13451 | /* end confdefs.h. */ |
| 13452 | #include <curses.h> |
| 13453 | int |
| 13454 | main () |
| 13455 | { |
| 13456 | void *x=resize_term |
| 13457 | ; |
| 13458 | return 0; |
| 13459 | } |
| 13460 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13461 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13462 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13463 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13464 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13465 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13466 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13467 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13468 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13469 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13470 | |
| 13471 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13472 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13473 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13474 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 13475 | $as_echo_n "checking for resizeterm... " >&6; } |
| 13476 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13477 | /* end confdefs.h. */ |
| 13478 | #include <curses.h> |
| 13479 | int |
| 13480 | main () |
| 13481 | { |
| 13482 | void *x=resizeterm |
| 13483 | ; |
| 13484 | return 0; |
| 13485 | } |
| 13486 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13487 | if ac_fn_c_try_compile "$LINENO"; then : |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13488 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13489 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13490 | |
Matthias Klose | c511b47 | 2010-05-08 11:01:39 +0000 | [diff] [blame] | 13491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13492 | $as_echo "yes" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13493 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13494 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13495 | $as_echo "no" >&6; } |
Walter Dörwald | 4994d95 | 2006-06-19 08:07:50 +0000 | [diff] [blame] | 13496 | |
| 13497 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13498 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13499 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13500 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 13501 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13502 | |
| 13503 | if test -r /dev/ptmx |
| 13504 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13505 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13506 | $as_echo "yes" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13507 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13508 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13509 | |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13510 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13511 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13512 | $as_echo "no" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13513 | fi |
| 13514 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13515 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 13516 | $as_echo_n "checking for /dev/ptc... " >&6; } |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13517 | |
| 13518 | if test -r /dev/ptc |
| 13519 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13521 | $as_echo "yes" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13522 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13523 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13524 | |
Martin v. Löwis | fefbc20 | 2006-10-17 18:59:23 +0000 | [diff] [blame] | 13525 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13526 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13527 | $as_echo "no" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13528 | fi |
| 13529 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13530 | if test "$have_long_long" = yes |
| 13531 | then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13532 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 13533 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
| 13534 | if test "${ac_cv_have_long_long_format+set}" = set; then : |
| 13535 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13536 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13537 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13538 | ac_cv_have_long_long_format=no |
| 13539 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13540 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13541 | /* end confdefs.h. */ |
| 13542 | |
| 13543 | #include <stdio.h> |
| 13544 | #include <stddef.h> |
| 13545 | #include <string.h> |
| 13546 | |
| 13547 | #ifdef HAVE_SYS_TYPES_H |
| 13548 | #include <sys/types.h> |
| 13549 | #endif |
| 13550 | |
| 13551 | int main() |
| 13552 | { |
| 13553 | char buffer[256]; |
| 13554 | |
| 13555 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 13556 | return 1; |
| 13557 | if (strcmp(buffer, "123")) |
| 13558 | return 1; |
| 13559 | |
| 13560 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 13561 | return 1; |
| 13562 | if (strcmp(buffer, "-123")) |
| 13563 | return 1; |
| 13564 | |
| 13565 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 13566 | return 1; |
| 13567 | if (strcmp(buffer, "123")) |
| 13568 | return 1; |
| 13569 | |
| 13570 | return 0; |
| 13571 | } |
| 13572 | |
| 13573 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13574 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13575 | ac_cv_have_long_long_format=yes |
| 13576 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13577 | ac_cv_have_long_long_format=no |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13578 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13579 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13580 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13581 | fi |
| 13582 | |
| 13583 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13584 | fi |
| 13585 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13586 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 13587 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13588 | fi |
| 13589 | |
Mark Dickinson | 5ce8474 | 2009-12-31 20:48:04 +0000 | [diff] [blame] | 13590 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13591 | then |
| 13592 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13593 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13594 | |
| 13595 | fi |
| 13596 | |
Ronald Oussoren | 315cd0c | 2009-11-19 16:25:21 +0000 | [diff] [blame] | 13597 | if test $ac_sys_system = Darwin |
| 13598 | then |
| 13599 | LIBS="$LIBS -framework CoreFoundation" |
| 13600 | fi |
| 13601 | |
Mark Dickinson | 82864d1 | 2009-11-15 16:18:58 +0000 | [diff] [blame] | 13602 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13603 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 13604 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
| 13605 | if test "${ac_cv_have_size_t_format+set}" = set; then : |
| 13606 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13607 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13608 | if test "$cross_compiling" = yes; then : |
Gregory P. Smith | c9ff3a7 | 2009-11-02 02:03:16 +0000 | [diff] [blame] | 13609 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 13610 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13611 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13612 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13613 | /* end confdefs.h. */ |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13614 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13615 | #include <stdio.h> |
| 13616 | #include <stddef.h> |
| 13617 | #include <string.h> |
| 13618 | |
Christian Heimes | db3d6cb | 2007-12-16 21:39:43 +0000 | [diff] [blame] | 13619 | #ifdef HAVE_SYS_TYPES_H |
| 13620 | #include <sys/types.h> |
| 13621 | #endif |
Neal Norwitz | 4a8fbdb | 2006-09-22 08:16:26 +0000 | [diff] [blame] | 13622 | |
| 13623 | #ifdef HAVE_SSIZE_T |
| 13624 | typedef ssize_t Py_ssize_t; |
| 13625 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 13626 | typedef long Py_ssize_t; |
| 13627 | #else |
| 13628 | typedef int Py_ssize_t; |
| 13629 | #endif |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13630 | |
Christian Heimes | db3d6cb | 2007-12-16 21:39:43 +0000 | [diff] [blame] | 13631 | int main() |
| 13632 | { |
| 13633 | char buffer[256]; |
| 13634 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13635 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 13636 | return 1; |
| 13637 | |
Neal Norwitz | 4a8fbdb | 2006-09-22 08:16:26 +0000 | [diff] [blame] | 13638 | if (strcmp(buffer, "123")) |
| 13639 | return 1; |
| 13640 | |
| 13641 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 13642 | return 1; |
| 13643 | |
| 13644 | if (strcmp(buffer, "-123")) |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13645 | return 1; |
| 13646 | |
| 13647 | return 0; |
| 13648 | } |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13649 | |
Brett Cannon | 09d1236 | 2006-05-11 05:11:33 +0000 | [diff] [blame] | 13650 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13651 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13652 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 13653 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13654 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 13655 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13656 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13657 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | a2db687 | 2009-07-17 07:46:46 +0000 | [diff] [blame] | 13658 | fi |
| 13659 | |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13660 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13661 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 13662 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Gregory P. Smith | c9ff3a7 | 2009-11-02 02:03:16 +0000 | [diff] [blame] | 13663 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13664 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13665 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | 2ccefe1 | 2009-07-17 23:17:48 +0000 | [diff] [blame] | 13666 | |
| 13667 | fi |
| 13668 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13669 | 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] | 13670 | #ifdef HAVE_SYS_TYPES_H |
| 13671 | #include <sys/types.h> |
| 13672 | #endif |
| 13673 | #ifdef HAVE_SYS_SOCKET_H |
| 13674 | #include <sys/socket.h> |
| 13675 | #endif |
| 13676 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13677 | " |
| 13678 | if test "x$ac_cv_type_socklen_t" = x""yes; then : |
Martin v. Löwis | 01c0401 | 2002-11-11 14:58:44 +0000 | [diff] [blame] | 13679 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13680 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13681 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13682 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13683 | |
| 13684 | fi |
| 13685 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13686 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13687 | |
| 13688 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 13689 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 13690 | do |
| 13691 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 13692 | done |
| 13693 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13694 | |
Neal Norwitz | d24499d | 2005-12-18 21:36:39 +0000 | [diff] [blame] | 13695 | SRCDIRS="Parser Grammar Objects Python Modules Mac" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 13697 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13698 | for dir in $SRCDIRS; do |
| 13699 | if test ! -d $dir; then |
| 13700 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 13701 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13702 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13703 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 13704 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 13705 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13706 | # generate output files |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 13707 | 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] | 13708 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13709 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13710 | # This file is a shell script that caches the results of configure |
| 13711 | # 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] | 13712 | # scripts and configure runs, see configure's option --config-cache. |
| 13713 | # It is not useful on other systems. If it contains results you don't |
| 13714 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13715 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13716 | # config.status only pays attention to the cache file if you give it |
| 13717 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13718 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13719 | # `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] | 13720 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 13721 | # following values. |
| 13722 | |
| 13723 | _ACEOF |
| 13724 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 13725 | # The following way of writing the cache mishandles newlines in values, |
| 13726 | # 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] | 13727 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13728 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 13729 | # 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] | 13730 | ( |
| 13731 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 13732 | eval ac_val=\$$ac_var |
| 13733 | case $ac_val in #( |
| 13734 | *${as_nl}*) |
| 13735 | case $ac_var in #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13736 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 13737 | $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] | 13738 | esac |
| 13739 | case $ac_var in #( |
| 13740 | _ | IFS | as_nl) ;; #( |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13741 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 13742 | *) { eval $ac_var=; unset $ac_var;} ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13743 | esac ;; |
| 13744 | esac |
| 13745 | done |
| 13746 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13747 | (set) 2>&1 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13748 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 13749 | *${as_nl}ac_space=\ *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13750 | # `set' does not quote correctly, so add quotes: double-quote |
| 13751 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13752 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 13753 | "s/'/'\\\\''/g; |
| 13754 | 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] | 13755 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13756 | *) |
| 13757 | # `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] | 13758 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13759 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13760 | esac | |
| 13761 | sort |
| 13762 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13763 | sed ' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13764 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13765 | t clear |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13766 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13767 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 13768 | t end |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13769 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 13770 | :end' >>confcache |
| 13771 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 13772 | if test -w "$cache_file"; then |
| 13773 | test "x$cache_file" != "x/dev/null" && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13774 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 13775 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13776 | cat confcache >$cache_file |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13777 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13778 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 13779 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13780 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13781 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13782 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13783 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13784 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 13785 | # Let make expand exec_prefix. |
| 13786 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13787 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13788 | DEFS=-DHAVE_CONFIG_H |
| 13789 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13790 | ac_libobjs= |
| 13791 | ac_ltlibobjs= |
| 13792 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 13793 | # 1. Remove the extension, and $U if already installed. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13794 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13795 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13796 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 13797 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13798 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 13799 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13800 | done |
| 13801 | LIBOBJS=$ac_libobjs |
| 13802 | |
| 13803 | LTLIBOBJS=$ac_ltlibobjs |
| 13804 | |
| 13805 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13806 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13807 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13808 | : ${CONFIG_STATUS=./config.status} |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13809 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13810 | ac_clean_files_save=$ac_clean_files |
| 13811 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13812 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 13813 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 13814 | as_write_fail=0 |
| 13815 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13816 | #! $SHELL |
| 13817 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13818 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13819 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13820 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13821 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13822 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13823 | ac_cs_recheck=false |
| 13824 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13825 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13826 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 13827 | export SHELL |
| 13828 | _ASEOF |
| 13829 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 13830 | ## -------------------- ## |
| 13831 | ## M4sh Initialization. ## |
| 13832 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13833 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13834 | # Be more Bourne compatible |
| 13835 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13836 | 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] | 13837 | emulate sh |
| 13838 | NULLCMD=: |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13839 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13840 | # is contrary to our usage. Disable this feature. |
| 13841 | alias -g '${1+"$@"}'='"$@"' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13842 | setopt NO_GLOB_SUBST |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 13843 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13844 | case `(set -o) 2>/dev/null` in #( |
| 13845 | *posix*) : |
| 13846 | set -o posix ;; #( |
| 13847 | *) : |
| 13848 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13849 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13850 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13851 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13852 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13853 | as_nl=' |
| 13854 | ' |
| 13855 | export as_nl |
| 13856 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 13857 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 13858 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13859 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13860 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 13861 | # but without wasting forks for bash or zsh. |
| 13862 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 13863 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13864 | as_echo='print -r --' |
| 13865 | as_echo_n='print -rn --' |
| 13866 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13867 | as_echo='printf %s\n' |
| 13868 | as_echo_n='printf %s' |
| 13869 | else |
| 13870 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 13871 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 13872 | as_echo_n='/usr/ucb/echo -n' |
| 13873 | else |
| 13874 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 13875 | as_echo_n_body='eval |
| 13876 | arg=$1; |
| 13877 | case $arg in #( |
| 13878 | *"$as_nl"*) |
| 13879 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 13880 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 13881 | esac; |
| 13882 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 13883 | ' |
| 13884 | export as_echo_n_body |
| 13885 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 13886 | fi |
| 13887 | export as_echo_body |
| 13888 | as_echo='sh -c $as_echo_body as_echo' |
| 13889 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13890 | |
| 13891 | # The user is always right. |
| 13892 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13893 | PATH_SEPARATOR=: |
| 13894 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 13895 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 13896 | PATH_SEPARATOR=';' |
| 13897 | } |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13898 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13899 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13900 | |
| 13901 | # IFS |
| 13902 | # We need space, tab and new line, in precisely that order. Quoting is |
| 13903 | # there to prevent editors from complaining about space-tab. |
| 13904 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 13905 | # splitting by setting IFS to empty value.) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13906 | IFS=" "" $as_nl" |
| 13907 | |
| 13908 | # Find who we are. Look in the path if we contain no directory separator. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13909 | case $0 in #(( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13910 | *[\\/]* ) as_myself=$0 ;; |
| 13911 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13912 | for as_dir in $PATH |
| 13913 | do |
| 13914 | IFS=$as_save_IFS |
| 13915 | test -z "$as_dir" && as_dir=. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13916 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 13917 | done |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13918 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13919 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13920 | ;; |
| 13921 | esac |
| 13922 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 13923 | # in which case we are not to be found in the path. |
| 13924 | if test "x$as_myself" = x; then |
| 13925 | as_myself=$0 |
| 13926 | fi |
| 13927 | if test ! -f "$as_myself"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13928 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 13929 | exit 1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13930 | fi |
| 13931 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13932 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 13933 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 13934 | # suppresses any "Segmentation fault" message there. '((' could |
| 13935 | # trigger a bug in pdksh 5.2.14. |
| 13936 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 13937 | do eval test x\${$as_var+set} = xset \ |
| 13938 | && ( (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] | 13939 | done |
| 13940 | PS1='$ ' |
| 13941 | PS2='> ' |
| 13942 | PS4='+ ' |
| 13943 | |
| 13944 | # NLS nuisances. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13945 | LC_ALL=C |
| 13946 | export LC_ALL |
| 13947 | LANGUAGE=C |
| 13948 | export LANGUAGE |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 13949 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 13950 | # CDPATH. |
| 13951 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 13952 | |
| 13953 | |
| 13954 | # as_fn_error ERROR [LINENO LOG_FD] |
| 13955 | # --------------------------------- |
| 13956 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 13957 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
| 13958 | # script with status $?, using 1 if that was 0. |
| 13959 | as_fn_error () |
| 13960 | { |
| 13961 | as_status=$?; test $as_status -eq 0 && as_status=1 |
| 13962 | if test "$3"; then |
| 13963 | as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 13964 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 |
| 13965 | fi |
| 13966 | $as_echo "$as_me: error: $1" >&2 |
| 13967 | as_fn_exit $as_status |
| 13968 | } # as_fn_error |
| 13969 | |
| 13970 | |
| 13971 | # as_fn_set_status STATUS |
| 13972 | # ----------------------- |
| 13973 | # Set $? to STATUS, without forking. |
| 13974 | as_fn_set_status () |
| 13975 | { |
| 13976 | return $1 |
| 13977 | } # as_fn_set_status |
| 13978 | |
| 13979 | # as_fn_exit STATUS |
| 13980 | # ----------------- |
| 13981 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 13982 | as_fn_exit () |
| 13983 | { |
| 13984 | set +e |
| 13985 | as_fn_set_status $1 |
| 13986 | exit $1 |
| 13987 | } # as_fn_exit |
| 13988 | |
| 13989 | # as_fn_unset VAR |
| 13990 | # --------------- |
| 13991 | # Portably unset VAR. |
| 13992 | as_fn_unset () |
| 13993 | { |
| 13994 | { eval $1=; unset $1;} |
| 13995 | } |
| 13996 | as_unset=as_fn_unset |
| 13997 | # as_fn_append VAR VALUE |
| 13998 | # ---------------------- |
| 13999 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 14000 | # advantage of any shell optimizations that allow amortized linear growth over |
| 14001 | # repeated appends, instead of the typical quadratic growth present in naive |
| 14002 | # implementations. |
| 14003 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 14004 | eval 'as_fn_append () |
| 14005 | { |
| 14006 | eval $1+=\$2 |
| 14007 | }' |
| 14008 | else |
| 14009 | as_fn_append () |
| 14010 | { |
| 14011 | eval $1=\$$1\$2 |
| 14012 | } |
| 14013 | fi # as_fn_append |
| 14014 | |
| 14015 | # as_fn_arith ARG... |
| 14016 | # ------------------ |
| 14017 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 14018 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 14019 | # must be portable across $(()) and expr. |
| 14020 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 14021 | eval 'as_fn_arith () |
| 14022 | { |
| 14023 | as_val=$(( $* )) |
| 14024 | }' |
| 14025 | else |
| 14026 | as_fn_arith () |
| 14027 | { |
| 14028 | as_val=`expr "$@" || test $? -eq 1` |
| 14029 | } |
| 14030 | fi # as_fn_arith |
| 14031 | |
| 14032 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14033 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 14034 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 14035 | as_expr=expr |
| 14036 | else |
| 14037 | as_expr=false |
| 14038 | fi |
| 14039 | |
| 14040 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 14041 | as_basename=basename |
| 14042 | else |
| 14043 | as_basename=false |
| 14044 | fi |
| 14045 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14046 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 14047 | as_dirname=dirname |
| 14048 | else |
| 14049 | as_dirname=false |
| 14050 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14051 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14052 | as_me=`$as_basename -- "$0" || |
| 14053 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 14054 | X"$0" : 'X\(//\)$' \| \ |
| 14055 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14056 | $as_echo X/"$0" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14057 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 14058 | s//\1/ |
| 14059 | q |
| 14060 | } |
| 14061 | /^X\/\(\/\/\)$/{ |
| 14062 | s//\1/ |
| 14063 | q |
| 14064 | } |
| 14065 | /^X\/\(\/\).*/{ |
| 14066 | s//\1/ |
| 14067 | q |
| 14068 | } |
| 14069 | s/.*/./; q'` |
| 14070 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14071 | # Avoid depending upon Character Ranges. |
| 14072 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 14073 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14074 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14075 | as_cr_digits='0123456789' |
| 14076 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14077 | |
| 14078 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14079 | case `echo -n x` in #((((( |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14080 | -n*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14081 | case `echo 'xy\c'` in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14082 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14083 | xy) ECHO_C='\c';; |
| 14084 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 14085 | ECHO_T=' ';; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14086 | esac;; |
| 14087 | *) |
| 14088 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14089 | esac |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 14090 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14091 | rm -f conf$$ conf$$.exe conf$$.file |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14092 | if test -d conf$$.dir; then |
| 14093 | rm -f conf$$.dir/conf$$.file |
| 14094 | else |
| 14095 | rm -f conf$$.dir |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14096 | mkdir conf$$.dir 2>/dev/null |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14097 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14098 | if (echo >conf$$.file) 2>/dev/null; then |
| 14099 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 14100 | as_ln_s='ln -s' |
| 14101 | # ... but there are two gotchas: |
| 14102 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 14103 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 14104 | # In both cases, we have to default to `cp -p'. |
| 14105 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 14106 | as_ln_s='cp -p' |
| 14107 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 14108 | as_ln_s=ln |
| 14109 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14110 | as_ln_s='cp -p' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14111 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14112 | else |
| 14113 | as_ln_s='cp -p' |
| 14114 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14115 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 14116 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14117 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14118 | |
| 14119 | # as_fn_mkdir_p |
| 14120 | # ------------- |
| 14121 | # Create "$as_dir" as a directory, including parents if necessary. |
| 14122 | as_fn_mkdir_p () |
| 14123 | { |
| 14124 | |
| 14125 | case $as_dir in #( |
| 14126 | -*) as_dir=./$as_dir;; |
| 14127 | esac |
| 14128 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 14129 | as_dirs= |
| 14130 | while :; do |
| 14131 | case $as_dir in #( |
| 14132 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 14133 | *) as_qdir=$as_dir;; |
| 14134 | esac |
| 14135 | as_dirs="'$as_qdir' $as_dirs" |
| 14136 | as_dir=`$as_dirname -- "$as_dir" || |
| 14137 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 14138 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 14139 | X"$as_dir" : 'X\(//\)$' \| \ |
| 14140 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 14141 | $as_echo X"$as_dir" | |
| 14142 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14143 | s//\1/ |
| 14144 | q |
| 14145 | } |
| 14146 | /^X\(\/\/\)[^/].*/{ |
| 14147 | s//\1/ |
| 14148 | q |
| 14149 | } |
| 14150 | /^X\(\/\/\)$/{ |
| 14151 | s//\1/ |
| 14152 | q |
| 14153 | } |
| 14154 | /^X\(\/\).*/{ |
| 14155 | s//\1/ |
| 14156 | q |
| 14157 | } |
| 14158 | s/.*/./; q'` |
| 14159 | test -d "$as_dir" && break |
| 14160 | done |
| 14161 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
| 14162 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" |
| 14163 | |
| 14164 | |
| 14165 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14166 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14167 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14168 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14169 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14170 | as_mkdir_p=false |
| 14171 | fi |
| 14172 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14173 | if test -x / >/dev/null 2>&1; then |
| 14174 | as_test_x='test -x' |
| 14175 | else |
| 14176 | if ls -dL / >/dev/null 2>&1; then |
| 14177 | as_ls_L_option=L |
| 14178 | else |
| 14179 | as_ls_L_option= |
| 14180 | fi |
| 14181 | as_test_x=' |
| 14182 | eval sh -c '\'' |
| 14183 | if test -d "$1"; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14184 | test -d "$1/."; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14185 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14186 | case $1 in #( |
| 14187 | -*)set "./$1";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14188 | esac; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14189 | 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] | 14190 | ???[sx]*):;;*)false;;esac;fi |
| 14191 | '\'' sh |
| 14192 | ' |
| 14193 | fi |
| 14194 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14195 | |
| 14196 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14197 | 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] | 14198 | |
| 14199 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14200 | 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] | 14201 | |
| 14202 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14203 | exec 6>&1 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14204 | ## ----------------------------------- ## |
| 14205 | ## Main body of $CONFIG_STATUS script. ## |
| 14206 | ## ----------------------------------- ## |
| 14207 | _ASEOF |
| 14208 | 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] | 14209 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14210 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14211 | # 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] | 14212 | # 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] | 14213 | # values after options handling. |
| 14214 | ac_log=" |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 14215 | This file was extended by python $as_me 2.7, which was |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14216 | generated by GNU Autoconf 2.65. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14217 | |
| 14218 | CONFIG_FILES = $CONFIG_FILES |
| 14219 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 14220 | CONFIG_LINKS = $CONFIG_LINKS |
| 14221 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 14222 | $ $0 $@ |
| 14223 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14224 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 14225 | " |
| 14226 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14227 | _ACEOF |
| 14228 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14229 | case $ac_config_files in *" |
| 14230 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 14231 | esac |
| 14232 | |
| 14233 | case $ac_config_headers in *" |
| 14234 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 14235 | esac |
| 14236 | |
| 14237 | |
| 14238 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14239 | # Files that config.status was made for. |
Ronald Oussoren | 450d561 | 2009-06-08 21:12:41 +0000 | [diff] [blame] | 14240 | config_files="$ac_config_files" |
| 14241 | config_headers="$ac_config_headers" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14242 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14243 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14244 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14245 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14246 | ac_cs_usage="\ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14247 | \`$as_me' instantiates files and other configuration actions |
| 14248 | from templates according to the current configuration. Unless the files |
| 14249 | 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] | 14250 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14251 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14252 | |
| 14253 | -h, --help print this help, then exit |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14254 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14255 | --config print configuration, then exit |
| 14256 | -q, --quiet, --silent |
| 14257 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14258 | -d, --debug don't remove temporary files |
| 14259 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14260 | --file=FILE[:TEMPLATE] |
| 14261 | instantiate the configuration file FILE |
| 14262 | --header=FILE[:TEMPLATE] |
| 14263 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14264 | |
| 14265 | Configuration files: |
| 14266 | $config_files |
| 14267 | |
| 14268 | Configuration headers: |
| 14269 | $config_headers |
| 14270 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14271 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 14272 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14273 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14274 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14275 | 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] | 14276 | ac_cs_version="\\ |
Martin v. Löwis | 174440b | 2008-10-03 08:59:41 +0000 | [diff] [blame] | 14277 | python config.status 2.7 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14278 | configured by $0, generated by GNU Autoconf 2.65, |
| 14279 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14280 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14281 | Copyright (C) 2009 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14282 | This config.status script is free software; the Free Software Foundation |
| 14283 | gives unlimited permission to copy, distribute and modify it." |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14284 | |
| 14285 | ac_pwd='$ac_pwd' |
| 14286 | srcdir='$srcdir' |
| 14287 | INSTALL='$INSTALL' |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14288 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14289 | _ACEOF |
| 14290 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14291 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14292 | # 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] | 14293 | ac_need_defaults=: |
| 14294 | while test $# != 0 |
| 14295 | do |
| 14296 | case $1 in |
| 14297 | --*=*) |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14298 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14299 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14300 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14301 | ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14302 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14303 | ac_option=$1 |
| 14304 | ac_optarg=$2 |
| 14305 | ac_shift=shift |
| 14306 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14307 | esac |
| 14308 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14309 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14310 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14311 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 14312 | ac_cs_recheck=: ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14313 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14314 | $as_echo "$ac_cs_version"; exit ;; |
| 14315 | --config | --confi | --conf | --con | --co | --c ) |
| 14316 | $as_echo "$ac_cs_config"; exit ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14317 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14318 | debug=: ;; |
| 14319 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14320 | $ac_shift |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14321 | case $ac_optarg in |
| 14322 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14323 | esac |
| 14324 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14325 | ac_need_defaults=false;; |
| 14326 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14327 | $ac_shift |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14328 | case $ac_optarg in |
| 14329 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14330 | esac |
| 14331 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14332 | ac_need_defaults=false;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14333 | --he | --h) |
| 14334 | # Conflict between --help and --header |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14335 | as_fn_error "ambiguous option: \`$1' |
| 14336 | Try \`$0 --help' for more information.";; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14337 | --help | --hel | -h ) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14338 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14339 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 14340 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 14341 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14342 | |
| 14343 | # This is an error. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14344 | -*) as_fn_error "unrecognized option: \`$1' |
| 14345 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14346 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14347 | *) as_fn_append ac_config_targets " $1" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14348 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14349 | |
| 14350 | esac |
| 14351 | shift |
| 14352 | done |
| 14353 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14354 | ac_configure_extra_args= |
| 14355 | |
| 14356 | if $ac_cs_silent; then |
| 14357 | exec 6>/dev/null |
| 14358 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 14359 | fi |
| 14360 | |
| 14361 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14362 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14363 | if \$ac_cs_recheck; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14364 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 14365 | shift |
| 14366 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 14367 | CONFIG_SHELL='$SHELL' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14368 | export CONFIG_SHELL |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14369 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14370 | fi |
| 14371 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14372 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14373 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14374 | exec 5>>config.log |
| 14375 | { |
| 14376 | echo |
| 14377 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 14378 | ## Running $as_me. ## |
| 14379 | _ASBOX |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14380 | $as_echo "$ac_log" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14381 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14382 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14383 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14384 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14385 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14386 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14387 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14388 | |
| 14389 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14390 | for ac_config_target in $ac_config_targets |
| 14391 | do |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14392 | case $ac_config_target in |
| 14393 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 14394 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 14395 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
| 14396 | "Mac/IDLE/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/IDLE/Makefile" ;; |
Ronald Oussoren | 580c7fe | 2008-05-02 19:45:11 +0000 | [diff] [blame] | 14397 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 14398 | "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] | 14399 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 14400 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | f2caeed | 2009-05-24 20:23:57 +0000 | [diff] [blame] | 14401 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14402 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14403 | *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14404 | esac |
| 14405 | done |
| 14406 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14407 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14408 | # If the user did not use the arguments to specify the items to instantiate, |
| 14409 | # then the envvar interface is used. Set only those that are not. |
| 14410 | # We use the long form for the default assignment because of an extremely |
| 14411 | # bizarre bug on SunOS 4.1.3. |
| 14412 | if $ac_need_defaults; then |
| 14413 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 14414 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 14415 | fi |
| 14416 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14417 | # 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] | 14418 | # 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] | 14419 | # creating and moving files from /tmp can sometimes cause problems. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14420 | # Hook for its removal unless debugging. |
| 14421 | # Note that there is a small window in which the directory will not be cleaned: |
| 14422 | # 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] | 14423 | $debug || |
| 14424 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14425 | tmp= |
| 14426 | trap 'exit_status=$? |
| 14427 | { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status |
| 14428 | ' 0 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14429 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14430 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14431 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14432 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14433 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14434 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14435 | test -n "$tmp" && test -d "$tmp" |
| 14436 | } || |
| 14437 | { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14438 | tmp=./conf$$-$RANDOM |
| 14439 | (umask 077 && mkdir "$tmp") |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14440 | } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14441 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14442 | # Set up the scripts for CONFIG_FILES section. |
| 14443 | # No need to generate them if there are no CONFIG_FILES. |
| 14444 | # This happens for instance with `./config.status config.h'. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14445 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14446 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14447 | |
| 14448 | ac_cr=`echo X | tr X '\015'` |
| 14449 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 14450 | # But we know of no other shell where ac_cr would be empty at this |
| 14451 | # point, so we can use a bashism as a fallback. |
| 14452 | if test "x$ac_cr" = x; then |
| 14453 | eval ac_cr=\$\'\\r\' |
| 14454 | fi |
| 14455 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 14456 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
| 14457 | ac_cs_awk_cr='\r' |
| 14458 | else |
| 14459 | ac_cs_awk_cr=$ac_cr |
| 14460 | fi |
| 14461 | |
| 14462 | echo 'BEGIN {' >"$tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14463 | _ACEOF |
| 14464 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14465 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14466 | { |
| 14467 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 14468 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 14469 | echo "_ACEOF" |
| 14470 | } >conf$$subs.sh || |
| 14471 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 14472 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14473 | ac_delim='%!_!# ' |
| 14474 | for ac_last_try in false false false false false :; do |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14475 | . ./conf$$subs.sh || |
| 14476 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14477 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14478 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 14479 | if test $ac_delim_n = $ac_delim_num; then |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14480 | break |
| 14481 | elif $ac_last_try; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14482 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14483 | else |
| 14484 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14485 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14486 | done |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14487 | rm -f conf$$subs.sh |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14488 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14489 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14490 | cat >>"\$tmp/subs1.awk" <<\\_ACAWK && |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14491 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14492 | sed -n ' |
| 14493 | h |
| 14494 | s/^/S["/; s/!.*/"]=/ |
| 14495 | p |
| 14496 | g |
| 14497 | s/^[^!]*!// |
| 14498 | :repl |
| 14499 | t repl |
| 14500 | s/'"$ac_delim"'$// |
| 14501 | t delim |
| 14502 | :nl |
| 14503 | h |
| 14504 | s/\(.\{148\}\)..*/\1/ |
| 14505 | t more1 |
| 14506 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 14507 | p |
| 14508 | n |
| 14509 | b repl |
| 14510 | :more1 |
| 14511 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14512 | p |
| 14513 | g |
| 14514 | s/.\{148\}// |
| 14515 | t nl |
| 14516 | :delim |
| 14517 | h |
| 14518 | s/\(.\{148\}\)..*/\1/ |
| 14519 | t more2 |
| 14520 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 14521 | p |
| 14522 | b |
| 14523 | :more2 |
| 14524 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14525 | p |
| 14526 | g |
| 14527 | s/.\{148\}// |
| 14528 | t delim |
| 14529 | ' <conf$$subs.awk | sed ' |
| 14530 | /^[^""]/{ |
| 14531 | N |
| 14532 | s/\n// |
| 14533 | } |
| 14534 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14535 | rm -f conf$$subs.awk |
| 14536 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14537 | _ACAWK |
| 14538 | cat >>"\$tmp/subs1.awk" <<_ACAWK && |
| 14539 | for (key in S) S_is_set[key] = 1 |
| 14540 | FS = "" |
| 14541 | |
| 14542 | } |
| 14543 | { |
| 14544 | line = $ 0 |
| 14545 | nfields = split(line, field, "@") |
| 14546 | substed = 0 |
| 14547 | len = length(field[1]) |
| 14548 | for (i = 2; i < nfields; i++) { |
| 14549 | key = field[i] |
| 14550 | keylen = length(key) |
| 14551 | if (S_is_set[key]) { |
| 14552 | value = S[key] |
| 14553 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 14554 | len += length(value) + length(field[++i]) |
| 14555 | substed = 1 |
| 14556 | } else |
| 14557 | len += 1 + keylen |
| 14558 | } |
| 14559 | |
| 14560 | print line |
| 14561 | } |
| 14562 | |
| 14563 | _ACAWK |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14564 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14565 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14566 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 14567 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 14568 | else |
| 14569 | cat |
| 14570 | fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ |
| 14571 | || as_fn_error "could not setup config files machinery" "$LINENO" 5 |
Alexandre Vassalotti | bd7569b | 2009-07-17 23:09:02 +0000 | [diff] [blame] | 14572 | _ACEOF |
| 14573 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14574 | # VPATH may cause trouble with some makes, so we remove $(srcdir), |
| 14575 | # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and |
| 14576 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 14577 | # (actually we leave an empty line to preserve line numbers). |
| 14578 | if test "x$srcdir" = x.; then |
| 14579 | ac_vpsub='/^[ ]*VPATH[ ]*=/{ |
| 14580 | s/:*\$(srcdir):*/:/ |
| 14581 | s/:*\${srcdir}:*/:/ |
| 14582 | s/:*@srcdir@:*/:/ |
| 14583 | s/^\([^=]*=[ ]*\):*/\1/ |
| 14584 | s/:*$// |
| 14585 | s/^[^=]*=[ ]*$// |
| 14586 | }' |
| 14587 | fi |
| 14588 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14589 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14590 | fi # test -n "$CONFIG_FILES" |
| 14591 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14592 | # Set up the scripts for CONFIG_HEADERS section. |
| 14593 | # No need to generate them if there are no CONFIG_HEADERS. |
| 14594 | # This happens for instance with `./config.status Makefile'. |
| 14595 | if test -n "$CONFIG_HEADERS"; then |
| 14596 | cat >"$tmp/defines.awk" <<\_ACAWK || |
| 14597 | BEGIN { |
| 14598 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14599 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14600 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 14601 | # here-document in config.status, that substitutes the proper values into |
| 14602 | # config.h.in to produce config.h. |
| 14603 | |
| 14604 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 14605 | # handling of long lines. |
| 14606 | ac_delim='%!_!# ' |
| 14607 | for ac_last_try in false false :; do |
| 14608 | ac_t=`sed -n "/$ac_delim/p" confdefs.h` |
| 14609 | if test -z "$ac_t"; then |
| 14610 | break |
| 14611 | elif $ac_last_try; then |
| 14612 | as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 |
| 14613 | else |
| 14614 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 14615 | fi |
| 14616 | done |
| 14617 | |
| 14618 | # For the awk script, D is an array of macro values keyed by name, |
| 14619 | # likewise P contains macro parameters if any. Preserve backslash |
| 14620 | # newline sequences. |
| 14621 | |
| 14622 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 14623 | sed -n ' |
| 14624 | s/.\{148\}/&'"$ac_delim"'/g |
| 14625 | t rset |
| 14626 | :rset |
| 14627 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 14628 | t def |
| 14629 | d |
| 14630 | :def |
| 14631 | s/\\$// |
| 14632 | t bsnl |
| 14633 | s/["\\]/\\&/g |
| 14634 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14635 | D["\1"]=" \3"/p |
| 14636 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 14637 | d |
| 14638 | :bsnl |
| 14639 | s/["\\]/\\&/g |
| 14640 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14641 | D["\1"]=" \3\\\\\\n"\\/p |
| 14642 | t cont |
| 14643 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 14644 | t cont |
| 14645 | d |
| 14646 | :cont |
| 14647 | n |
| 14648 | s/.\{148\}/&'"$ac_delim"'/g |
| 14649 | t clear |
| 14650 | :clear |
| 14651 | s/\\$// |
| 14652 | t bsnlc |
| 14653 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 14654 | d |
| 14655 | :bsnlc |
| 14656 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 14657 | b cont |
| 14658 | ' <confdefs.h | sed ' |
| 14659 | s/'"$ac_delim"'/"\\\ |
| 14660 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14661 | |
| 14662 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14663 | for (key in D) D_is_set[key] = 1 |
| 14664 | FS = "" |
| 14665 | } |
| 14666 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 14667 | line = \$ 0 |
| 14668 | split(line, arg, " ") |
| 14669 | if (arg[1] == "#") { |
| 14670 | defundef = arg[2] |
| 14671 | mac1 = arg[3] |
| 14672 | } else { |
| 14673 | defundef = substr(arg[1], 2) |
| 14674 | mac1 = arg[2] |
| 14675 | } |
| 14676 | split(mac1, mac2, "(") #) |
| 14677 | macro = mac2[1] |
| 14678 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 14679 | if (D_is_set[macro]) { |
| 14680 | # Preserve the white space surrounding the "#". |
| 14681 | print prefix "define", macro P[macro] D[macro] |
| 14682 | next |
| 14683 | } else { |
| 14684 | # Replace #undef with comments. This is necessary, for example, |
| 14685 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 14686 | # on some systems where configure will not decide to define it. |
| 14687 | if (defundef == "undef") { |
| 14688 | print "/*", prefix defundef, macro, "*/" |
| 14689 | next |
| 14690 | } |
| 14691 | } |
| 14692 | } |
| 14693 | { print } |
| 14694 | _ACAWK |
| 14695 | _ACEOF |
| 14696 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14697 | as_fn_error "could not setup config headers machinery" "$LINENO" 5 |
| 14698 | fi # test -n "$CONFIG_HEADERS" |
| 14699 | |
| 14700 | |
| 14701 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 14702 | shift |
| 14703 | for ac_tag |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14704 | do |
| 14705 | case $ac_tag in |
| 14706 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 14707 | esac |
| 14708 | case $ac_mode$ac_tag in |
| 14709 | :[FHL]*:*);; |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14710 | :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] | 14711 | :[FH]-) ac_tag=-:-;; |
| 14712 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 14713 | esac |
| 14714 | ac_save_IFS=$IFS |
| 14715 | IFS=: |
| 14716 | set x $ac_tag |
| 14717 | IFS=$ac_save_IFS |
| 14718 | shift |
| 14719 | ac_file=$1 |
| 14720 | shift |
| 14721 | |
| 14722 | case $ac_mode in |
| 14723 | :L) ac_source=$1;; |
| 14724 | :[FH]) |
| 14725 | ac_file_inputs= |
| 14726 | for ac_f |
| 14727 | do |
| 14728 | case $ac_f in |
| 14729 | -) ac_f="$tmp/stdin";; |
| 14730 | *) # Look for the file first in the build tree, then in the source tree |
| 14731 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 14732 | # because $ac_f cannot contain `:'. |
| 14733 | test -f "$ac_f" || |
| 14734 | case $ac_f in |
| 14735 | [\\/$]*) false;; |
| 14736 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 14737 | esac || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14738 | as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14739 | esac |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14740 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 14741 | as_fn_append ac_file_inputs " '$ac_f'" |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14742 | done |
| 14743 | |
| 14744 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 14745 | # use $as_me), people would be surprised to read: |
| 14746 | # /* config.h. Generated by config.status. */ |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14747 | configure_input='Generated from '` |
| 14748 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 14749 | `' by configure.' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14750 | if test x"$ac_file" != x-; then |
| 14751 | configure_input="$ac_file. $configure_input" |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14752 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 14753 | $as_echo "$as_me: creating $ac_file" >&6;} |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14754 | fi |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14755 | # Neutralize special characters interpreted by sed in replacement strings. |
| 14756 | case $configure_input in #( |
| 14757 | *\&* | *\|* | *\\* ) |
| 14758 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 14759 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 14760 | *) ac_sed_conf_input=$configure_input;; |
| 14761 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14762 | |
| 14763 | case $ac_tag in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14764 | *:-:* | *:-) cat >"$tmp/stdin" \ |
| 14765 | || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14766 | esac |
| 14767 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14768 | esac |
| 14769 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14770 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14771 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14772 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 14773 | X"$ac_file" : 'X\(//\)$' \| \ |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14774 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14775 | $as_echo X"$ac_file" | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14776 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14777 | s//\1/ |
| 14778 | q |
| 14779 | } |
| 14780 | /^X\(\/\/\)[^/].*/{ |
| 14781 | s//\1/ |
| 14782 | q |
| 14783 | } |
| 14784 | /^X\(\/\/\)$/{ |
| 14785 | s//\1/ |
| 14786 | q |
| 14787 | } |
| 14788 | /^X\(\/\).*/{ |
| 14789 | s//\1/ |
| 14790 | q |
| 14791 | } |
| 14792 | s/.*/./; q'` |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14793 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14794 | ac_builddir=. |
| 14795 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14796 | case "$ac_dir" in |
| 14797 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14798 | *) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14799 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14800 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14801 | 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] | 14802 | case $ac_top_builddir_sub in |
| 14803 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14804 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 14805 | esac ;; |
| 14806 | esac |
| 14807 | ac_abs_top_builddir=$ac_pwd |
| 14808 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 14809 | # for backward compatibility: |
| 14810 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14811 | |
| 14812 | case $srcdir in |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14813 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14814 | ac_srcdir=. |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14815 | ac_top_srcdir=$ac_top_builddir_sub |
| 14816 | ac_abs_top_srcdir=$ac_pwd ;; |
| 14817 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14818 | ac_srcdir=$srcdir$ac_dir_suffix; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14819 | ac_top_srcdir=$srcdir |
| 14820 | ac_abs_top_srcdir=$srcdir ;; |
| 14821 | *) # Relative name. |
| 14822 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 14823 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 14824 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14825 | esac |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14826 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14827 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14828 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14829 | case $ac_mode in |
| 14830 | :F) |
| 14831 | # |
| 14832 | # CONFIG_FILE |
| 14833 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14834 | |
| 14835 | case $INSTALL in |
| 14836 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14837 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14838 | esac |
Brett Cannon | 19fab76 | 2007-06-02 03:02:29 +0000 | [diff] [blame] | 14839 | _ACEOF |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14840 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14841 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14842 | # If the template does not know about datarootdir, expand it. |
| 14843 | # FIXME: This hack should be removed a few years after 2.60. |
| 14844 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14845 | ac_sed_dataroot=' |
| 14846 | /datarootdir/ { |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14847 | p |
| 14848 | q |
| 14849 | } |
| 14850 | /@datadir@/p |
| 14851 | /@docdir@/p |
| 14852 | /@infodir@/p |
| 14853 | /@localedir@/p |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14854 | /@mandir@/p' |
| 14855 | 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] | 14856 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 14857 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14858 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 14859 | $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] | 14860 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14861 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14862 | ac_datarootdir_hack=' |
| 14863 | s&@datadir@&$datadir&g |
| 14864 | s&@docdir@&$docdir&g |
| 14865 | s&@infodir@&$infodir&g |
| 14866 | s&@localedir@&$localedir&g |
| 14867 | s&@mandir@&$mandir&g |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14868 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14869 | esac |
| 14870 | _ACEOF |
| 14871 | |
| 14872 | # Neutralize VPATH when `$srcdir' = `.'. |
| 14873 | # Shell code in configure.ac might set extrasub. |
| 14874 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14875 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14876 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14877 | $extrasub |
| 14878 | _ACEOF |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14879 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14880 | :t |
| 14881 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14882 | s|@configure_input@|$ac_sed_conf_input|;t t |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14883 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14884 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14885 | s&@srcdir@&$ac_srcdir&;t t |
| 14886 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 14887 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 14888 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 14889 | s&@builddir@&$ac_builddir&;t t |
| 14890 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 14891 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 14892 | s&@INSTALL@&$ac_INSTALL&;t t |
| 14893 | $ac_datarootdir_hack |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14894 | " |
| 14895 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ |
| 14896 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14897 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14898 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
| 14899 | { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && |
| 14900 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14901 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14902 | which seems to be undefined. Please make sure it is defined." >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14903 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14904 | 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] | 14905 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14906 | rm -f "$tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14907 | case $ac_file in |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14908 | -) cat "$tmp/out" && rm -f "$tmp/out";; |
| 14909 | *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; |
| 14910 | esac \ |
| 14911 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14912 | ;; |
| 14913 | :H) |
| 14914 | # |
| 14915 | # CONFIG_HEADER |
| 14916 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14917 | if test x"$ac_file" != x-; then |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14918 | { |
| 14919 | $as_echo "/* $configure_input */" \ |
| 14920 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" |
| 14921 | } >"$tmp/config.h" \ |
| 14922 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
| 14923 | if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then |
| 14924 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 14925 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14926 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14927 | rm -f "$ac_file" |
| 14928 | mv "$tmp/config.h" "$ac_file" \ |
| 14929 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14930 | fi |
| 14931 | else |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14932 | $as_echo "/* $configure_input */" \ |
| 14933 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ |
| 14934 | || as_fn_error "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14935 | fi |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14936 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 14937 | |
Martin v. Löwis | eba4065 | 2007-08-30 20:10:57 +0000 | [diff] [blame] | 14938 | |
| 14939 | esac |
| 14940 | |
| 14941 | done # for ac_tag |
| 14942 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14943 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14944 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14945 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14946 | ac_clean_files=$ac_clean_files_save |
| 14947 | |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14948 | test $ac_write_fail = 0 || |
| 14949 | as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
| 14950 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14951 | |
| 14952 | # configure is writing to config.log, and then calls config.status. |
| 14953 | # config.status does its own redirection, appending to config.log. |
| 14954 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 14955 | # by configure, so config.status won't be able to write to it; its |
| 14956 | # output is simply discarded. So we exec the FD to /dev/null, |
| 14957 | # effectively closing config.log, so it can be properly (re)opened and |
| 14958 | # appended to by config.status. When coming back to configure, we |
| 14959 | # need to make the FD available again. |
| 14960 | if test "$no_create" != yes; then |
| 14961 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14962 | ac_config_status_args= |
| 14963 | test "$silent" = yes && |
| 14964 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14965 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14966 | $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] | 14967 | exec 5>>config.log |
| 14968 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 14969 | # would make configure fail if this is the last instruction. |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14970 | $ac_cs_success || as_fn_exit $? |
| 14971 | fi |
| 14972 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 14973 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 14974 | $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] | 14975 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14976 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 14977 | |
Martin v. Löwis | f7afe95 | 2006-04-14 15:16:15 +0000 | [diff] [blame] | 14978 | echo "creating Modules/Setup" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 14979 | if test ! -f Modules/Setup |
| 14980 | then |
| 14981 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 14982 | fi |
| 14983 | |
Martin v. Löwis | f7afe95 | 2006-04-14 15:16:15 +0000 | [diff] [blame] | 14984 | echo "creating Modules/Setup.local" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 14985 | if test ! -f Modules/Setup.local |
| 14986 | then |
| 14987 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 14988 | fi |
| 14989 | |
| 14990 | echo "creating Makefile" |
| 14991 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 14992 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 14993 | Modules/Setup.local Modules/Setup |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 14994 | |
| 14995 | case $ac_sys_system in |
| 14996 | BeOS) |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 14997 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 14998 | |
| 14999 | Support for BeOS is deprecated as of Python 2.6. |
| 15000 | See PEP 11 for the gory details. |
| 15001 | " >&5 |
Matthias Klose | a0bea5d | 2010-05-08 10:00:28 +0000 | [diff] [blame] | 15002 | $as_echo "$as_me: WARNING: |
Skip Montanaro | 89e975f | 2007-08-22 19:05:21 +0000 | [diff] [blame] | 15003 | |
| 15004 | Support for BeOS is deprecated as of Python 2.6. |
| 15005 | See PEP 11 for the gory details. |
| 15006 | " >&2;} |
| 15007 | ;; |
| 15008 | *) ;; |
| 15009 | esac |
| 15010 | |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 15011 | mv config.c Modules |