Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 2 | # From configure.in Revision: 84674 . |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3 | # Guess values for system-dependent variables and create Makefiles. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4 | # Generated by GNU Autoconf 2.65 for python 3.2. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5 | # |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8 | # |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 10 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, |
| 11 | # Inc. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12 | # |
| 13 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14 | # This configure script is free software; the Free Software Foundation |
| 15 | # gives unlimited permission to copy, distribute and modify it. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16 | ## -------------------- ## |
| 17 | ## M4sh Initialization. ## |
| 18 | ## -------------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 19 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 20 | # Be more Bourne compatible |
| 21 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 | b962171 | 2010-04-24 17:59:49 +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+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 28 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 29 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 30 | case `(set -o) 2>/dev/null` in #( |
| 31 | *posix*) : |
| 32 | set -o posix ;; #( |
| 33 | *) : |
| 34 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 35 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 36 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 37 | |
| 38 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 | b962171 | 2010-04-24 17:59:49 +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 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 84 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 85 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 95 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 102 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 103 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 104 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 105 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 114 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 115 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 116 | fi |
| 117 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 125 | done |
| 126 | PS1='$ ' |
| 127 | PS2='> ' |
| 128 | PS4='+ ' |
| 129 | |
| 130 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 131 | LC_ALL=C |
| 132 | export LC_ALL |
| 133 | LANGUAGE=C |
| 134 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 135 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 323 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 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 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 363 | # as_fn_error ERROR [LINENO LOG_FD] |
| 364 | # --------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 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 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 367 | # script with status $?, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 368 | as_fn_error () |
| 369 | { |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 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 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 374 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 375 | $as_echo "$as_me: error: $1" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 376 | as_fn_exit $as_status |
| 377 | } # as_fn_error |
| 378 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 397 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 402 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 423 | |
| 424 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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. :-) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 443 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 444 | ' >$as_me.lineno && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 445 | chmod +x "$as_me.lineno" || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 456 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 457 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 458 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 459 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 460 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 461 | xy) ECHO_C='\c';; |
| 462 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 463 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 474 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 475 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 | b962171 | 2010-04-24 17:59:49 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +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 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 514 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 515 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 516 | case $1 in #( |
| 517 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 518 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 519 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +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. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 537 | # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 545 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 546 | ac_config_libobj_dir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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' |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 556 | PACKAGE_VERSION='3.2' |
| 557 | PACKAGE_STRING='python 3.2' |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 558 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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> |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 590 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 598 | ac_subst_vars='LTLIBOBJS |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 599 | SRCDIRS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 600 | THREADHEADERS |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 601 | SOABI |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 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 |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 642 | USE_INLINE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 643 | GNULD |
| 644 | LINKCC |
| 645 | RUNSHARED |
| 646 | INSTSONAME |
| 647 | LDLIBRARYDIR |
| 648 | BLDLIBRARY |
| 649 | DLLLIBRARY |
| 650 | LDLIBRARY |
| 651 | LIBRARY |
| 652 | BUILDEXEEXT |
| 653 | EGREP |
| 654 | GREP |
| 655 | CPP |
| 656 | MAINCC |
| 657 | CXX |
| 658 | OBJEXT |
| 659 | EXEEXT |
| 660 | ac_ct_CC |
| 661 | CPPFLAGS |
| 662 | LDFLAGS |
| 663 | CFLAGS |
| 664 | CC |
| 665 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 666 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 667 | SGI_ABI |
| 668 | MACHDEP |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 669 | FRAMEWORKINSTALLAPPSPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 670 | FRAMEWORKUNIXTOOLSPREFIX |
| 671 | FRAMEWORKALTINSTALLLAST |
| 672 | FRAMEWORKALTINSTALLFIRST |
| 673 | FRAMEWORKINSTALLLAST |
| 674 | FRAMEWORKINSTALLFIRST |
| 675 | PYTHONFRAMEWORKINSTALLDIR |
| 676 | PYTHONFRAMEWORKPREFIX |
| 677 | PYTHONFRAMEWORKDIR |
| 678 | PYTHONFRAMEWORKIDENTIFIER |
| 679 | PYTHONFRAMEWORK |
| 680 | LIPO_32BIT_FLAGS |
| 681 | ARCH_RUN_32BIT |
| 682 | UNIVERSALSDK |
| 683 | CONFIG_ARGS |
| 684 | SOVERSION |
| 685 | VERSION |
| 686 | target_alias |
| 687 | host_alias |
| 688 | build_alias |
| 689 | LIBS |
| 690 | ECHO_T |
| 691 | ECHO_N |
| 692 | ECHO_C |
| 693 | DEFS |
| 694 | mandir |
| 695 | localedir |
| 696 | libdir |
| 697 | psdir |
| 698 | pdfdir |
| 699 | dvidir |
| 700 | htmldir |
| 701 | infodir |
| 702 | docdir |
| 703 | oldincludedir |
| 704 | includedir |
| 705 | localstatedir |
| 706 | sharedstatedir |
| 707 | sysconfdir |
| 708 | datadir |
| 709 | datarootdir |
| 710 | libexecdir |
| 711 | sbindir |
| 712 | bindir |
| 713 | program_transform_name |
| 714 | prefix |
| 715 | exec_prefix |
| 716 | PACKAGE_URL |
| 717 | PACKAGE_BUGREPORT |
| 718 | PACKAGE_STRING |
| 719 | PACKAGE_VERSION |
| 720 | PACKAGE_TARNAME |
| 721 | PACKAGE_NAME |
| 722 | PATH_SEPARATOR |
| 723 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 724 | ac_subst_files='' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 725 | ac_user_opts=' |
| 726 | enable_option_checking |
| 727 | enable_universalsdk |
| 728 | with_universal_archs |
| 729 | with_framework_name |
| 730 | enable_framework |
| 731 | with_gcc |
| 732 | with_cxx_main |
| 733 | with_suffix |
| 734 | enable_shared |
| 735 | enable_profiling |
| 736 | with_pydebug |
| 737 | with_libs |
| 738 | with_system_expat |
| 739 | with_system_ffi |
| 740 | with_dbmliborder |
| 741 | with_signal_module |
| 742 | with_dec_threads |
| 743 | with_threads |
| 744 | with_thread |
| 745 | enable_ipv6 |
| 746 | with_doc_strings |
| 747 | with_tsc |
| 748 | with_pymalloc |
| 749 | with_valgrind |
| 750 | with_wctype_functions |
| 751 | with_fpectl |
| 752 | with_libm |
| 753 | with_libc |
| 754 | enable_big_digits |
| 755 | with_wide_unicode |
| 756 | with_computed_gotos |
| 757 | ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 758 | ac_precious_vars='build_alias |
| 759 | host_alias |
| 760 | target_alias |
| 761 | CC |
| 762 | CFLAGS |
| 763 | LDFLAGS |
| 764 | LIBS |
| 765 | CPPFLAGS |
| 766 | CPP' |
| 767 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 768 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 769 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 770 | ac_init_help= |
| 771 | ac_init_version=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 772 | ac_unrecognized_opts= |
| 773 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 774 | # The variables have the same names as the options, with |
| 775 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 776 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 777 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 778 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 779 | no_recursion= |
| 780 | prefix=NONE |
| 781 | program_prefix=NONE |
| 782 | program_suffix=NONE |
| 783 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 784 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 785 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 786 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 787 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 788 | x_includes=NONE |
| 789 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 790 | |
| 791 | # Installation directory options. |
| 792 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 793 | # and all the variables that are supposed to be based on exec_prefix |
| 794 | # by default will actually change. |
| 795 | # Use braces instead of parens because sh, perl, etc. also accept them. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 796 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 797 | bindir='${exec_prefix}/bin' |
| 798 | sbindir='${exec_prefix}/sbin' |
| 799 | libexecdir='${exec_prefix}/libexec' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 800 | datarootdir='${prefix}/share' |
| 801 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 802 | sysconfdir='${prefix}/etc' |
| 803 | sharedstatedir='${prefix}/com' |
| 804 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 805 | includedir='${prefix}/include' |
| 806 | oldincludedir='/usr/include' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 807 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 808 | infodir='${datarootdir}/info' |
| 809 | htmldir='${docdir}' |
| 810 | dvidir='${docdir}' |
| 811 | pdfdir='${docdir}' |
| 812 | psdir='${docdir}' |
| 813 | libdir='${exec_prefix}/lib' |
| 814 | localedir='${datarootdir}/locale' |
| 815 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 816 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 817 | ac_prev= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 818 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 819 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 820 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 821 | # If the previous option needs an argument, assign it. |
| 822 | if test -n "$ac_prev"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 823 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 824 | ac_prev= |
| 825 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 826 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 827 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 828 | case $ac_option in |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 829 | *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 830 | *) ac_optarg=yes ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 831 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 832 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 833 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 834 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 835 | case $ac_dashdash$ac_option in |
| 836 | --) |
| 837 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 838 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 839 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 840 | ac_prev=bindir ;; |
| 841 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 842 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 843 | |
| 844 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 845 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 846 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 847 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 848 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 849 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 850 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 851 | ac_prev=cache_file ;; |
| 852 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 853 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 854 | cache_file=$ac_optarg ;; |
| 855 | |
| 856 | --config-cache | -C) |
| 857 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 858 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 859 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 860 | ac_prev=datadir ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 861 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 862 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 863 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 864 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 865 | | --dataroo | --dataro | --datar) |
| 866 | ac_prev=datarootdir ;; |
| 867 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 868 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 869 | datarootdir=$ac_optarg ;; |
| 870 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 871 | -disable-* | --disable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 872 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 873 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 874 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 875 | as_fn_error "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 876 | ac_useropt_orig=$ac_useropt |
| 877 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 878 | case $ac_user_opts in |
| 879 | *" |
| 880 | "enable_$ac_useropt" |
| 881 | "*) ;; |
| 882 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 883 | ac_unrecognized_sep=', ';; |
| 884 | esac |
| 885 | eval enable_$ac_useropt=no ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 886 | |
| 887 | -docdir | --docdir | --docdi | --doc | --do) |
| 888 | ac_prev=docdir ;; |
| 889 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 890 | docdir=$ac_optarg ;; |
| 891 | |
| 892 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 893 | ac_prev=dvidir ;; |
| 894 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 895 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 896 | |
| 897 | -enable-* | --enable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 898 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 899 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 900 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 901 | as_fn_error "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 902 | ac_useropt_orig=$ac_useropt |
| 903 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 904 | case $ac_user_opts in |
| 905 | *" |
| 906 | "enable_$ac_useropt" |
| 907 | "*) ;; |
| 908 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 909 | ac_unrecognized_sep=', ';; |
| 910 | esac |
| 911 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 912 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 913 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 914 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 915 | | --exec | --exe | --ex) |
| 916 | ac_prev=exec_prefix ;; |
| 917 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 918 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 919 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 920 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 921 | |
| 922 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 923 | # Obsolete; use --with-gas. |
| 924 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 925 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 926 | -help | --help | --hel | --he | -h) |
| 927 | ac_init_help=long ;; |
| 928 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 929 | ac_init_help=recursive ;; |
| 930 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 931 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 932 | |
| 933 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 934 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 935 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 936 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 937 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 938 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 939 | ac_prev=htmldir ;; |
| 940 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 941 | | --ht=*) |
| 942 | htmldir=$ac_optarg ;; |
| 943 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 944 | -includedir | --includedir | --includedi | --included | --include \ |
| 945 | | --includ | --inclu | --incl | --inc) |
| 946 | ac_prev=includedir ;; |
| 947 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 948 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 949 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 950 | |
| 951 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 952 | ac_prev=infodir ;; |
| 953 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 954 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 955 | |
| 956 | -libdir | --libdir | --libdi | --libd) |
| 957 | ac_prev=libdir ;; |
| 958 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 959 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 960 | |
| 961 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 962 | | --libexe | --libex | --libe) |
| 963 | ac_prev=libexecdir ;; |
| 964 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 965 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 966 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 967 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 968 | -localedir | --localedir | --localedi | --localed | --locale) |
| 969 | ac_prev=localedir ;; |
| 970 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 971 | localedir=$ac_optarg ;; |
| 972 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 973 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 974 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 975 | ac_prev=localstatedir ;; |
| 976 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 977 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 978 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 979 | |
| 980 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 981 | ac_prev=mandir ;; |
| 982 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 983 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 984 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 985 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 986 | # Obsolete; use --without-fp. |
| 987 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 988 | |
| 989 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 990 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 991 | no_create=yes ;; |
| 992 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 993 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 994 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 995 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 996 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 997 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 998 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 999 | | --oldin | --oldi | --old | --ol | --o) |
| 1000 | ac_prev=oldincludedir ;; |
| 1001 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1002 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1003 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1004 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1005 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1006 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1007 | ac_prev=prefix ;; |
| 1008 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1009 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1010 | |
| 1011 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1012 | | --program-pre | --program-pr | --program-p) |
| 1013 | ac_prev=program_prefix ;; |
| 1014 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1015 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1016 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1017 | |
| 1018 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1019 | | --program-suf | --program-su | --program-s) |
| 1020 | ac_prev=program_suffix ;; |
| 1021 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1022 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1023 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1024 | |
| 1025 | -program-transform-name | --program-transform-name \ |
| 1026 | | --program-transform-nam | --program-transform-na \ |
| 1027 | | --program-transform-n | --program-transform- \ |
| 1028 | | --program-transform | --program-transfor \ |
| 1029 | | --program-transfo | --program-transf \ |
| 1030 | | --program-trans | --program-tran \ |
| 1031 | | --progr-tra | --program-tr | --program-t) |
| 1032 | ac_prev=program_transform_name ;; |
| 1033 | -program-transform-name=* | --program-transform-name=* \ |
| 1034 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1035 | | --program-transform-n=* | --program-transform-=* \ |
| 1036 | | --program-transform=* | --program-transfor=* \ |
| 1037 | | --program-transfo=* | --program-transf=* \ |
| 1038 | | --program-trans=* | --program-tran=* \ |
| 1039 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1040 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1041 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1042 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1043 | ac_prev=pdfdir ;; |
| 1044 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1045 | pdfdir=$ac_optarg ;; |
| 1046 | |
| 1047 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1048 | ac_prev=psdir ;; |
| 1049 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1050 | psdir=$ac_optarg ;; |
| 1051 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1052 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1053 | | -silent | --silent | --silen | --sile | --sil) |
| 1054 | silent=yes ;; |
| 1055 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1056 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1057 | ac_prev=sbindir ;; |
| 1058 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1059 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1060 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1061 | |
| 1062 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1063 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1064 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1065 | | --sha | --sh) |
| 1066 | ac_prev=sharedstatedir ;; |
| 1067 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1068 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1069 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1070 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1071 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1072 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1073 | -site | --site | --sit) |
| 1074 | ac_prev=site ;; |
| 1075 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1076 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1077 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1078 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1079 | ac_prev=srcdir ;; |
| 1080 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1081 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1082 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1083 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1084 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1085 | ac_prev=sysconfdir ;; |
| 1086 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1087 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1088 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1089 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1090 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1091 | ac_prev=target_alias ;; |
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 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1094 | |
| 1095 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1096 | verbose=yes ;; |
| 1097 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1098 | -version | --version | --versio | --versi | --vers | -V) |
| 1099 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1100 | |
| 1101 | -with-* | --with-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1102 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1103 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1104 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1105 | as_fn_error "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1106 | ac_useropt_orig=$ac_useropt |
| 1107 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1108 | case $ac_user_opts in |
| 1109 | *" |
| 1110 | "with_$ac_useropt" |
| 1111 | "*) ;; |
| 1112 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1113 | ac_unrecognized_sep=', ';; |
| 1114 | esac |
| 1115 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1116 | |
| 1117 | -without-* | --without-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1118 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1119 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1120 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1121 | as_fn_error "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1122 | ac_useropt_orig=$ac_useropt |
| 1123 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1124 | case $ac_user_opts in |
| 1125 | *" |
| 1126 | "with_$ac_useropt" |
| 1127 | "*) ;; |
| 1128 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1129 | ac_unrecognized_sep=', ';; |
| 1130 | esac |
| 1131 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1132 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1133 | --x) |
| 1134 | # Obsolete; use --with-x. |
| 1135 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1136 | |
| 1137 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1138 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1139 | ac_prev=x_includes ;; |
| 1140 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1141 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1142 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1143 | |
| 1144 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1145 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1146 | ac_prev=x_libraries ;; |
| 1147 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1148 | | --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] | 1149 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1150 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1151 | -*) as_fn_error "unrecognized option: \`$ac_option' |
| 1152 | Try \`$0 --help' for more information." |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1153 | ;; |
| 1154 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1155 | *=*) |
| 1156 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1157 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1158 | case $ac_envvar in #( |
| 1159 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1160 | as_fn_error "invalid variable name: \`$ac_envvar'" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1161 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1162 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1163 | export $ac_envvar ;; |
| 1164 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1165 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1166 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1167 | $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] | 1168 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1169 | $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] | 1170 | : ${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] | 1171 | ;; |
| 1172 | |
| 1173 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1174 | done |
| 1175 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1176 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1177 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1178 | as_fn_error "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1179 | fi |
| 1180 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1181 | if test -n "$ac_unrecognized_opts"; then |
| 1182 | case $enable_option_checking in |
| 1183 | no) ;; |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1184 | fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1185 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1186 | esac |
| 1187 | fi |
| 1188 | |
| 1189 | # Check all directory arguments for consistency. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1190 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1191 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1192 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1193 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1194 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1195 | eval ac_val=\$$ac_var |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1196 | # Remove trailing slashes. |
| 1197 | case $ac_val in |
| 1198 | */ ) |
| 1199 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1200 | eval $ac_var=\$ac_val;; |
| 1201 | esac |
| 1202 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1203 | case $ac_val in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1204 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1205 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1206 | esac |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1207 | 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] | 1208 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1209 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1210 | # There might be people who depend on the old broken behavior: `$host' |
| 1211 | # used to hold the argument of --host etc. |
| 1212 | # FIXME: To remove some day. |
| 1213 | build=$build_alias |
| 1214 | host=$host_alias |
| 1215 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1216 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1217 | # FIXME: To remove some day. |
| 1218 | if test "x$host_alias" != x; then |
| 1219 | if test "x$build_alias" = x; then |
| 1220 | cross_compiling=maybe |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1221 | $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. |
| 1222 | If a cross compiler is detected then cross compile mode will be used." >&2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1223 | elif test "x$build_alias" != "x$host_alias"; then |
| 1224 | cross_compiling=yes |
| 1225 | fi |
| 1226 | fi |
| 1227 | |
| 1228 | ac_tool_prefix= |
| 1229 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1230 | |
| 1231 | test "$silent" = yes && exec 6>/dev/null |
| 1232 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1233 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1234 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1235 | ac_ls_di=`ls -di .` && |
| 1236 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1237 | as_fn_error "working directory cannot be determined" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1238 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1239 | as_fn_error "pwd does not report name of working directory" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1240 | |
| 1241 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1242 | # Find the source files, if location was not specified. |
| 1243 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1244 | ac_srcdir_defaulted=yes |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1245 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1246 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1247 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1248 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1249 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1250 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1251 | $as_echo X"$as_myself" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1252 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1253 | s//\1/ |
| 1254 | q |
| 1255 | } |
| 1256 | /^X\(\/\/\)[^/].*/{ |
| 1257 | s//\1/ |
| 1258 | q |
| 1259 | } |
| 1260 | /^X\(\/\/\)$/{ |
| 1261 | s//\1/ |
| 1262 | q |
| 1263 | } |
| 1264 | /^X\(\/\).*/{ |
| 1265 | s//\1/ |
| 1266 | q |
| 1267 | } |
| 1268 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1269 | srcdir=$ac_confdir |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1270 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1271 | srcdir=.. |
| 1272 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1273 | else |
| 1274 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1275 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1276 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1277 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1278 | as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 1279 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1280 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1281 | ac_abs_confdir=`( |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1282 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1283 | pwd)` |
| 1284 | # When building in place, set srcdir=. |
| 1285 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1286 | srcdir=. |
| 1287 | fi |
| 1288 | # Remove unnecessary trailing slashes from srcdir. |
| 1289 | # Double slashes in file names in object file debugging info |
| 1290 | # mess up M-x gdb in Emacs. |
| 1291 | case $srcdir in |
| 1292 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1293 | esac |
| 1294 | for ac_var in $ac_precious_vars; do |
| 1295 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1296 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1297 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1298 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1299 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1300 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1301 | # |
| 1302 | # Report the --help message. |
| 1303 | # |
| 1304 | if test "$ac_init_help" = "long"; then |
| 1305 | # Omit some internal or obsolete options to make the list less imposing. |
| 1306 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1307 | cat <<_ACEOF |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1308 | \`configure' configures python 3.2 to adapt to many kinds of systems. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1309 | |
| 1310 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1311 | |
| 1312 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1313 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1314 | |
| 1315 | Defaults for the options are specified in brackets. |
| 1316 | |
| 1317 | Configuration: |
| 1318 | -h, --help display this help and exit |
| 1319 | --help=short display options specific to this package |
| 1320 | --help=recursive display the short help of all the included packages |
| 1321 | -V, --version display version information and exit |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1322 | -q, --quiet, --silent do not print \`checking...' messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1323 | --cache-file=FILE cache test results in FILE [disabled] |
| 1324 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1325 | -n, --no-create do not create output files |
| 1326 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1327 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1328 | Installation directories: |
| 1329 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1330 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1331 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1332 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1333 | |
| 1334 | By default, \`make install' will install all the files in |
| 1335 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1336 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1337 | for instance \`--prefix=\$HOME'. |
| 1338 | |
| 1339 | For better control, use the options below. |
| 1340 | |
| 1341 | Fine tuning of the installation directories: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1342 | --bindir=DIR user executables [EPREFIX/bin] |
| 1343 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1344 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1345 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1346 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1347 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1348 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1349 | --includedir=DIR C header files [PREFIX/include] |
| 1350 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1351 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1352 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1353 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1354 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1355 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1356 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1357 | --htmldir=DIR html documentation [DOCDIR] |
| 1358 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1359 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1360 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1361 | _ACEOF |
| 1362 | |
| 1363 | cat <<\_ACEOF |
| 1364 | _ACEOF |
| 1365 | fi |
| 1366 | |
| 1367 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1368 | case $ac_init_help in |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1369 | short | recursive ) echo "Configuration of python 3.2:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1370 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1371 | cat <<\_ACEOF |
| 1372 | |
| 1373 | Optional Features: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1374 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1375 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1376 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Christian Heimes | 68f5fbe | 2008-02-14 08:27:37 +0000 | [diff] [blame] | 1377 | --enable-universalsdk[=SDKDIR] |
Christian Heimes | 292d351 | 2008-02-03 16:51:08 +0000 | [diff] [blame] | 1378 | Build against Mac OS X 10.4u SDK (ppc/i386) |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1379 | --enable-framework[=INSTALLDIR] |
| 1380 | Build (MacOSX|Darwin) framework |
| 1381 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1382 | --enable-profiling enable C-level code profiling |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1383 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1384 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 1385 | --enable-big-digits[=BITS] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1386 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1387 | |
| 1388 | Optional Packages: |
| 1389 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1390 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 1391 | --with-universal-archs=ARCH |
| 1392 | select architectures for universal build ("32-bit", |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 1393 | "64-bit", "3-way", "intel" or "all") |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 1394 | --with-framework-name=FRAMEWORK |
| 1395 | specify an alternate name of the framework built |
| 1396 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1397 | --without-gcc never use gcc |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1398 | --with-cxx-main=<compiler> |
| 1399 | compile main() and link python executable with C++ |
| 1400 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1401 | --with-suffix=.exe set executable suffix |
| 1402 | --with-pydebug build with Py_DEBUG defined |
| 1403 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | b2d9046 | 2009-12-31 03:23:10 +0000 | [diff] [blame] | 1404 | --with-system-expat build pyexpat module using an installed expat |
| 1405 | library |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1406 | --with-system-ffi build _ctypes module using an installed ffi library |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 1407 | --with-dbmliborder=db1:db2:... |
| 1408 | order to check db backends for dbm. Valid value is a |
| 1409 | colon separated string with the backend names |
| 1410 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1411 | --with-signal-module disable/enable signal module |
| 1412 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries |
| 1413 | --with(out)-threads[=DIRECTORY] |
| 1414 | disable/enable thread support |
| 1415 | --with(out)-thread[=DIRECTORY] |
| 1416 | deprecated; use --with(out)-threads |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1417 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1418 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1419 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 1420 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1421 | --with-wctype-functions use wctype.h functions |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1422 | --with-fpectl enable SIGFPE catching |
| 1423 | --with-libm=STRING math library |
| 1424 | --with-libc=STRING C library |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 1425 | --with-wide-unicode Use 4-byte Unicode characters (default is 2 bytes) |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 1426 | --with(out)-computed-gotos |
| 1427 | Use computed gotos in evaluation loop (enabled by |
| 1428 | default on supported compilers) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1429 | |
| 1430 | Some influential environment variables: |
| 1431 | CC C compiler command |
| 1432 | CFLAGS C compiler flags |
| 1433 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1434 | nonstandard directory <lib dir> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1435 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1436 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1437 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1438 | CPP C preprocessor |
| 1439 | |
| 1440 | Use these variables to override the choices made by `configure' or to help |
| 1441 | it to find libraries and programs with nonstandard names/locations. |
| 1442 | |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 1443 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1444 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1445 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1446 | fi |
| 1447 | |
| 1448 | if test "$ac_init_help" = "recursive"; then |
| 1449 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1450 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1451 | test -d "$ac_dir" || |
| 1452 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1453 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1454 | ac_builddir=. |
| 1455 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1456 | case "$ac_dir" in |
| 1457 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1458 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1459 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1460 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1461 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1462 | case $ac_top_builddir_sub in |
| 1463 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1464 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1465 | esac ;; |
| 1466 | esac |
| 1467 | ac_abs_top_builddir=$ac_pwd |
| 1468 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1469 | # for backward compatibility: |
| 1470 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1471 | |
| 1472 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1473 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1474 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1475 | ac_top_srcdir=$ac_top_builddir_sub |
| 1476 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1477 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1478 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1479 | ac_top_srcdir=$srcdir |
| 1480 | ac_abs_top_srcdir=$srcdir ;; |
| 1481 | *) # Relative name. |
| 1482 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1483 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1484 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1485 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1486 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1487 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1488 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1489 | # Check for guested configure. |
| 1490 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1491 | echo && |
| 1492 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1493 | elif test -f "$ac_srcdir/configure"; then |
| 1494 | echo && |
| 1495 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1496 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1497 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1498 | fi || ac_status=$? |
| 1499 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1500 | done |
| 1501 | fi |
| 1502 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1503 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1504 | if $ac_init_version; then |
| 1505 | cat <<\_ACEOF |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1506 | python configure 3.2 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1507 | generated by GNU Autoconf 2.65 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1508 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1509 | Copyright (C) 2009 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1510 | This configure script is free software; the Free Software Foundation |
| 1511 | gives unlimited permission to copy, distribute and modify it. |
| 1512 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1513 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1514 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1515 | |
| 1516 | ## ------------------------ ## |
| 1517 | ## Autoconf initialization. ## |
| 1518 | ## ------------------------ ## |
| 1519 | |
| 1520 | # ac_fn_c_try_compile LINENO |
| 1521 | # -------------------------- |
| 1522 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1523 | ac_fn_c_try_compile () |
| 1524 | { |
| 1525 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1526 | rm -f conftest.$ac_objext |
| 1527 | if { { ac_try="$ac_compile" |
| 1528 | case "(($ac_try" in |
| 1529 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1530 | *) ac_try_echo=$ac_try;; |
| 1531 | esac |
| 1532 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1533 | $as_echo "$ac_try_echo"; } >&5 |
| 1534 | (eval "$ac_compile") 2>conftest.err |
| 1535 | ac_status=$? |
| 1536 | if test -s conftest.err; then |
| 1537 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1538 | cat conftest.er1 >&5 |
| 1539 | mv -f conftest.er1 conftest.err |
| 1540 | fi |
| 1541 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1542 | test $ac_status = 0; } && { |
| 1543 | test -z "$ac_c_werror_flag" || |
| 1544 | test ! -s conftest.err |
| 1545 | } && test -s conftest.$ac_objext; then : |
| 1546 | ac_retval=0 |
| 1547 | else |
| 1548 | $as_echo "$as_me: failed program was:" >&5 |
| 1549 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1550 | |
| 1551 | ac_retval=1 |
| 1552 | fi |
| 1553 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1554 | as_fn_set_status $ac_retval |
| 1555 | |
| 1556 | } # ac_fn_c_try_compile |
| 1557 | |
| 1558 | # ac_fn_c_try_cpp LINENO |
| 1559 | # ---------------------- |
| 1560 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1561 | ac_fn_c_try_cpp () |
| 1562 | { |
| 1563 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1564 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1565 | case "(($ac_try" in |
| 1566 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1567 | *) ac_try_echo=$ac_try;; |
| 1568 | esac |
| 1569 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1570 | $as_echo "$ac_try_echo"; } >&5 |
| 1571 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1572 | ac_status=$? |
| 1573 | if test -s conftest.err; then |
| 1574 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1575 | cat conftest.er1 >&5 |
| 1576 | mv -f conftest.er1 conftest.err |
| 1577 | fi |
| 1578 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1579 | test $ac_status = 0; } >/dev/null && { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1580 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1581 | test ! -s conftest.err |
| 1582 | }; then : |
| 1583 | ac_retval=0 |
| 1584 | else |
| 1585 | $as_echo "$as_me: failed program was:" >&5 |
| 1586 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1587 | |
| 1588 | ac_retval=1 |
| 1589 | fi |
| 1590 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1591 | as_fn_set_status $ac_retval |
| 1592 | |
| 1593 | } # ac_fn_c_try_cpp |
| 1594 | |
| 1595 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1596 | # ------------------------------------------------------- |
| 1597 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1598 | # the include files in INCLUDES and setting the cache variable VAR |
| 1599 | # accordingly. |
| 1600 | ac_fn_c_check_header_mongrel () |
| 1601 | { |
| 1602 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1603 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1604 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1605 | $as_echo_n "checking for $2... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1606 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1607 | $as_echo_n "(cached) " >&6 |
| 1608 | fi |
| 1609 | eval ac_res=\$$3 |
| 1610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1611 | $as_echo "$ac_res" >&6; } |
| 1612 | else |
| 1613 | # Is the header compilable? |
| 1614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1615 | $as_echo_n "checking $2 usability... " >&6; } |
| 1616 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1617 | /* end confdefs.h. */ |
| 1618 | $4 |
| 1619 | #include <$2> |
| 1620 | _ACEOF |
| 1621 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1622 | ac_header_compiler=yes |
| 1623 | else |
| 1624 | ac_header_compiler=no |
| 1625 | fi |
| 1626 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1627 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1628 | $as_echo "$ac_header_compiler" >&6; } |
| 1629 | |
| 1630 | # Is the header present? |
| 1631 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1632 | $as_echo_n "checking $2 presence... " >&6; } |
| 1633 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1634 | /* end confdefs.h. */ |
| 1635 | #include <$2> |
| 1636 | _ACEOF |
| 1637 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1638 | ac_header_preproc=yes |
| 1639 | else |
| 1640 | ac_header_preproc=no |
| 1641 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1642 | rm -f conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1643 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1644 | $as_echo "$ac_header_preproc" >&6; } |
| 1645 | |
| 1646 | # So? What about this header? |
| 1647 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1648 | yes:no: ) |
| 1649 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1650 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1651 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1652 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1653 | ;; |
| 1654 | no:yes:* ) |
| 1655 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1656 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1657 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1658 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1659 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1660 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1661 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1662 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1663 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1664 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1665 | ( cat <<\_ASBOX |
| 1666 | ## -------------------------------------- ## |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1667 | ## Report this to http://bugs.python.org/ ## |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1668 | ## -------------------------------------- ## |
| 1669 | _ASBOX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1670 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1671 | ;; |
| 1672 | esac |
| 1673 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1674 | $as_echo_n "checking for $2... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1675 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1676 | $as_echo_n "(cached) " >&6 |
| 1677 | else |
| 1678 | eval "$3=\$ac_header_compiler" |
| 1679 | fi |
| 1680 | eval ac_res=\$$3 |
| 1681 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1682 | $as_echo "$ac_res" >&6; } |
| 1683 | fi |
| 1684 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1685 | |
| 1686 | } # ac_fn_c_check_header_mongrel |
| 1687 | |
| 1688 | # ac_fn_c_try_run LINENO |
| 1689 | # ---------------------- |
| 1690 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1691 | # that executables *can* be run. |
| 1692 | ac_fn_c_try_run () |
| 1693 | { |
| 1694 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1695 | if { { ac_try="$ac_link" |
| 1696 | case "(($ac_try" in |
| 1697 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1698 | *) ac_try_echo=$ac_try;; |
| 1699 | esac |
| 1700 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1701 | $as_echo "$ac_try_echo"; } >&5 |
| 1702 | (eval "$ac_link") 2>&5 |
| 1703 | ac_status=$? |
| 1704 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1705 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1706 | { { case "(($ac_try" in |
| 1707 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1708 | *) ac_try_echo=$ac_try;; |
| 1709 | esac |
| 1710 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1711 | $as_echo "$ac_try_echo"; } >&5 |
| 1712 | (eval "$ac_try") 2>&5 |
| 1713 | ac_status=$? |
| 1714 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1715 | test $ac_status = 0; }; }; then : |
| 1716 | ac_retval=0 |
| 1717 | else |
| 1718 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1719 | $as_echo "$as_me: failed program was:" >&5 |
| 1720 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1721 | |
| 1722 | ac_retval=$ac_status |
| 1723 | fi |
| 1724 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1725 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1726 | as_fn_set_status $ac_retval |
| 1727 | |
| 1728 | } # ac_fn_c_try_run |
| 1729 | |
| 1730 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1731 | # ------------------------------------------------------- |
| 1732 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1733 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1734 | ac_fn_c_check_header_compile () |
| 1735 | { |
| 1736 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1737 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1738 | $as_echo_n "checking for $2... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1739 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1740 | $as_echo_n "(cached) " >&6 |
| 1741 | else |
| 1742 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1743 | /* end confdefs.h. */ |
| 1744 | $4 |
| 1745 | #include <$2> |
| 1746 | _ACEOF |
| 1747 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1748 | eval "$3=yes" |
| 1749 | else |
| 1750 | eval "$3=no" |
| 1751 | fi |
| 1752 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1753 | fi |
| 1754 | eval ac_res=\$$3 |
| 1755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1756 | $as_echo "$ac_res" >&6; } |
| 1757 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1758 | |
| 1759 | } # ac_fn_c_check_header_compile |
| 1760 | |
| 1761 | # ac_fn_c_try_link LINENO |
| 1762 | # ----------------------- |
| 1763 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1764 | ac_fn_c_try_link () |
| 1765 | { |
| 1766 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1767 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1768 | if { { ac_try="$ac_link" |
| 1769 | case "(($ac_try" in |
| 1770 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1771 | *) ac_try_echo=$ac_try;; |
| 1772 | esac |
| 1773 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1774 | $as_echo "$ac_try_echo"; } >&5 |
| 1775 | (eval "$ac_link") 2>conftest.err |
| 1776 | ac_status=$? |
| 1777 | if test -s conftest.err; then |
| 1778 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1779 | cat conftest.er1 >&5 |
| 1780 | mv -f conftest.er1 conftest.err |
| 1781 | fi |
| 1782 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1783 | test $ac_status = 0; } && { |
| 1784 | test -z "$ac_c_werror_flag" || |
| 1785 | test ! -s conftest.err |
| 1786 | } && test -s conftest$ac_exeext && { |
| 1787 | test "$cross_compiling" = yes || |
| 1788 | $as_test_x conftest$ac_exeext |
| 1789 | }; then : |
| 1790 | ac_retval=0 |
| 1791 | else |
| 1792 | $as_echo "$as_me: failed program was:" >&5 |
| 1793 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1794 | |
| 1795 | ac_retval=1 |
| 1796 | fi |
| 1797 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1798 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1799 | # interfere with the next link command; also delete a directory that is |
| 1800 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1801 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1802 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1803 | as_fn_set_status $ac_retval |
| 1804 | |
| 1805 | } # ac_fn_c_try_link |
| 1806 | |
| 1807 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1808 | # ------------------------------------------- |
| 1809 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1810 | # variable VAR accordingly. |
| 1811 | ac_fn_c_check_type () |
| 1812 | { |
| 1813 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1814 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1815 | $as_echo_n "checking for $2... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1816 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1817 | $as_echo_n "(cached) " >&6 |
| 1818 | else |
| 1819 | eval "$3=no" |
| 1820 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1821 | /* end confdefs.h. */ |
| 1822 | $4 |
| 1823 | int |
| 1824 | main () |
| 1825 | { |
| 1826 | if (sizeof ($2)) |
| 1827 | return 0; |
| 1828 | ; |
| 1829 | return 0; |
| 1830 | } |
| 1831 | _ACEOF |
| 1832 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1833 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1834 | /* end confdefs.h. */ |
| 1835 | $4 |
| 1836 | int |
| 1837 | main () |
| 1838 | { |
| 1839 | if (sizeof (($2))) |
| 1840 | return 0; |
| 1841 | ; |
| 1842 | return 0; |
| 1843 | } |
| 1844 | _ACEOF |
| 1845 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1846 | |
| 1847 | else |
| 1848 | eval "$3=yes" |
| 1849 | fi |
| 1850 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1851 | fi |
| 1852 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1853 | fi |
| 1854 | eval ac_res=\$$3 |
| 1855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1856 | $as_echo "$ac_res" >&6; } |
| 1857 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1858 | |
| 1859 | } # ac_fn_c_check_type |
| 1860 | |
| 1861 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1862 | # ------------------------------------ |
| 1863 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1864 | # accordingly. |
| 1865 | ac_fn_c_find_uintX_t () |
| 1866 | { |
| 1867 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1868 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1869 | $as_echo_n "checking for uint$2_t... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1870 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1871 | $as_echo_n "(cached) " >&6 |
| 1872 | else |
| 1873 | eval "$3=no" |
| 1874 | # Order is important - never check a type that is potentially smaller |
| 1875 | # than half of the expected target width. |
| 1876 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1877 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1878 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1879 | /* end confdefs.h. */ |
| 1880 | $ac_includes_default |
| 1881 | int |
| 1882 | main () |
| 1883 | { |
| 1884 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
| 1885 | test_array [0] = 0 |
| 1886 | |
| 1887 | ; |
| 1888 | return 0; |
| 1889 | } |
| 1890 | _ACEOF |
| 1891 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1892 | case $ac_type in #( |
| 1893 | uint$2_t) : |
| 1894 | eval "$3=yes" ;; #( |
| 1895 | *) : |
| 1896 | eval "$3=\$ac_type" ;; |
| 1897 | esac |
| 1898 | fi |
| 1899 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1900 | eval as_val=\$$3 |
| 1901 | if test "x$as_val" = x""no; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1902 | |
| 1903 | else |
| 1904 | break |
| 1905 | fi |
| 1906 | done |
| 1907 | fi |
| 1908 | eval ac_res=\$$3 |
| 1909 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1910 | $as_echo "$ac_res" >&6; } |
| 1911 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1912 | |
| 1913 | } # ac_fn_c_find_uintX_t |
| 1914 | |
| 1915 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 1916 | # ----------------------------------- |
| 1917 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 1918 | # accordingly. |
| 1919 | ac_fn_c_find_intX_t () |
| 1920 | { |
| 1921 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1922 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 1923 | $as_echo_n "checking for int$2_t... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1924 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1925 | $as_echo_n "(cached) " >&6 |
| 1926 | else |
| 1927 | eval "$3=no" |
| 1928 | # Order is important - never check a type that is potentially smaller |
| 1929 | # than half of the expected target width. |
| 1930 | for ac_type in int$2_t 'int' 'long int' \ |
| 1931 | 'long long int' 'short int' 'signed char'; do |
| 1932 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1933 | /* end confdefs.h. */ |
| 1934 | $ac_includes_default |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1935 | int |
| 1936 | main () |
| 1937 | { |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1938 | static int test_array [1 - 2 * !(enum { N = $2 / 2 - 1 }; |
| 1939 | 0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1940 | test_array [0] = 0 |
| 1941 | |
| 1942 | ; |
| 1943 | return 0; |
| 1944 | } |
| 1945 | _ACEOF |
| 1946 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1947 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1948 | /* end confdefs.h. */ |
| 1949 | $ac_includes_default |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1950 | int |
| 1951 | main () |
| 1952 | { |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1953 | static int test_array [1 - 2 * !(enum { N = $2 / 2 - 1 }; |
| 1954 | ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1955 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
| 1956 | test_array [0] = 0 |
| 1957 | |
| 1958 | ; |
| 1959 | return 0; |
| 1960 | } |
| 1961 | _ACEOF |
| 1962 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1963 | |
| 1964 | else |
| 1965 | case $ac_type in #( |
| 1966 | int$2_t) : |
| 1967 | eval "$3=yes" ;; #( |
| 1968 | *) : |
| 1969 | eval "$3=\$ac_type" ;; |
| 1970 | esac |
| 1971 | fi |
| 1972 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1973 | fi |
| 1974 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 1975 | eval as_val=\$$3 |
| 1976 | if test "x$as_val" = x""no; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1977 | |
| 1978 | else |
| 1979 | break |
| 1980 | fi |
| 1981 | done |
| 1982 | fi |
| 1983 | eval ac_res=\$$3 |
| 1984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1985 | $as_echo "$ac_res" >&6; } |
| 1986 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 1987 | |
| 1988 | } # ac_fn_c_find_intX_t |
| 1989 | |
| 1990 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 1991 | # -------------------------------------------- |
| 1992 | # Tries to find the compile-time value of EXPR in a program that includes |
| 1993 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 1994 | # computed |
| 1995 | ac_fn_c_compute_int () |
| 1996 | { |
| 1997 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1998 | if test "$cross_compiling" = yes; then |
| 1999 | # Depending upon the size, compute the lo and hi bounds. |
| 2000 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2001 | /* end confdefs.h. */ |
| 2002 | $4 |
| 2003 | int |
| 2004 | main () |
| 2005 | { |
| 2006 | static int test_array [1 - 2 * !(($2) >= 0)]; |
| 2007 | test_array [0] = 0 |
| 2008 | |
| 2009 | ; |
| 2010 | return 0; |
| 2011 | } |
| 2012 | _ACEOF |
| 2013 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2014 | ac_lo=0 ac_mid=0 |
| 2015 | while :; do |
| 2016 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2017 | /* end confdefs.h. */ |
| 2018 | $4 |
| 2019 | int |
| 2020 | main () |
| 2021 | { |
| 2022 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2023 | test_array [0] = 0 |
| 2024 | |
| 2025 | ; |
| 2026 | return 0; |
| 2027 | } |
| 2028 | _ACEOF |
| 2029 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2030 | ac_hi=$ac_mid; break |
| 2031 | else |
| 2032 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2033 | if test $ac_lo -le $ac_mid; then |
| 2034 | ac_lo= ac_hi= |
| 2035 | break |
| 2036 | fi |
| 2037 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2038 | fi |
| 2039 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2040 | done |
| 2041 | else |
| 2042 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2043 | /* end confdefs.h. */ |
| 2044 | $4 |
| 2045 | int |
| 2046 | main () |
| 2047 | { |
| 2048 | static int test_array [1 - 2 * !(($2) < 0)]; |
| 2049 | test_array [0] = 0 |
| 2050 | |
| 2051 | ; |
| 2052 | return 0; |
| 2053 | } |
| 2054 | _ACEOF |
| 2055 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2056 | ac_hi=-1 ac_mid=-1 |
| 2057 | while :; do |
| 2058 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2059 | /* end confdefs.h. */ |
| 2060 | $4 |
| 2061 | int |
| 2062 | main () |
| 2063 | { |
| 2064 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
| 2065 | test_array [0] = 0 |
| 2066 | |
| 2067 | ; |
| 2068 | return 0; |
| 2069 | } |
| 2070 | _ACEOF |
| 2071 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2072 | ac_lo=$ac_mid; break |
| 2073 | else |
| 2074 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2075 | if test $ac_mid -le $ac_hi; then |
| 2076 | ac_lo= ac_hi= |
| 2077 | break |
| 2078 | fi |
| 2079 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2080 | fi |
| 2081 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2082 | done |
| 2083 | else |
| 2084 | ac_lo= ac_hi= |
| 2085 | fi |
| 2086 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2087 | fi |
| 2088 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2089 | # Binary search between lo and hi bounds. |
| 2090 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2091 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2092 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2093 | /* end confdefs.h. */ |
| 2094 | $4 |
| 2095 | int |
| 2096 | main () |
| 2097 | { |
| 2098 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2099 | test_array [0] = 0 |
| 2100 | |
| 2101 | ; |
| 2102 | return 0; |
| 2103 | } |
| 2104 | _ACEOF |
| 2105 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2106 | ac_hi=$ac_mid |
| 2107 | else |
| 2108 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2109 | fi |
| 2110 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2111 | done |
| 2112 | case $ac_lo in #(( |
| 2113 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2114 | '') ac_retval=1 ;; |
| 2115 | esac |
| 2116 | else |
| 2117 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2118 | /* end confdefs.h. */ |
| 2119 | $4 |
| 2120 | static long int longval () { return $2; } |
| 2121 | static unsigned long int ulongval () { return $2; } |
| 2122 | #include <stdio.h> |
| 2123 | #include <stdlib.h> |
| 2124 | int |
| 2125 | main () |
| 2126 | { |
| 2127 | |
| 2128 | FILE *f = fopen ("conftest.val", "w"); |
| 2129 | if (! f) |
| 2130 | return 1; |
| 2131 | if (($2) < 0) |
| 2132 | { |
| 2133 | long int i = longval (); |
| 2134 | if (i != ($2)) |
| 2135 | return 1; |
| 2136 | fprintf (f, "%ld", i); |
| 2137 | } |
| 2138 | else |
| 2139 | { |
| 2140 | unsigned long int i = ulongval (); |
| 2141 | if (i != ($2)) |
| 2142 | return 1; |
| 2143 | fprintf (f, "%lu", i); |
| 2144 | } |
| 2145 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2146 | on some platforms. */ |
| 2147 | return ferror (f) || fclose (f) != 0; |
| 2148 | |
| 2149 | ; |
| 2150 | return 0; |
| 2151 | } |
| 2152 | _ACEOF |
| 2153 | if ac_fn_c_try_run "$LINENO"; then : |
| 2154 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2155 | else |
| 2156 | ac_retval=1 |
| 2157 | fi |
| 2158 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2159 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2160 | rm -f conftest.val |
| 2161 | |
| 2162 | fi |
| 2163 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2164 | as_fn_set_status $ac_retval |
| 2165 | |
| 2166 | } # ac_fn_c_compute_int |
| 2167 | |
| 2168 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2169 | # ---------------------------------- |
| 2170 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2171 | ac_fn_c_check_func () |
| 2172 | { |
| 2173 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2174 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2175 | $as_echo_n "checking for $2... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2176 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2177 | $as_echo_n "(cached) " >&6 |
| 2178 | else |
| 2179 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2180 | /* end confdefs.h. */ |
| 2181 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2182 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2183 | #define $2 innocuous_$2 |
| 2184 | |
| 2185 | /* System header to define __stub macros and hopefully few prototypes, |
| 2186 | which can conflict with char $2 (); below. |
| 2187 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2188 | <limits.h> exists even on freestanding compilers. */ |
| 2189 | |
| 2190 | #ifdef __STDC__ |
| 2191 | # include <limits.h> |
| 2192 | #else |
| 2193 | # include <assert.h> |
| 2194 | #endif |
| 2195 | |
| 2196 | #undef $2 |
| 2197 | |
| 2198 | /* Override any GCC internal prototype to avoid an error. |
| 2199 | Use char because int might match the return type of a GCC |
| 2200 | builtin and then its argument prototype would still apply. */ |
| 2201 | #ifdef __cplusplus |
| 2202 | extern "C" |
| 2203 | #endif |
| 2204 | char $2 (); |
| 2205 | /* The GNU C library defines this for functions which it implements |
| 2206 | to always fail with ENOSYS. Some functions are actually named |
| 2207 | something starting with __ and the normal name is an alias. */ |
| 2208 | #if defined __stub_$2 || defined __stub___$2 |
| 2209 | choke me |
| 2210 | #endif |
| 2211 | |
| 2212 | int |
| 2213 | main () |
| 2214 | { |
| 2215 | return $2 (); |
| 2216 | ; |
| 2217 | return 0; |
| 2218 | } |
| 2219 | _ACEOF |
| 2220 | if ac_fn_c_try_link "$LINENO"; then : |
| 2221 | eval "$3=yes" |
| 2222 | else |
| 2223 | eval "$3=no" |
| 2224 | fi |
| 2225 | rm -f core conftest.err conftest.$ac_objext \ |
| 2226 | conftest$ac_exeext conftest.$ac_ext |
| 2227 | fi |
| 2228 | eval ac_res=\$$3 |
| 2229 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2230 | $as_echo "$ac_res" >&6; } |
| 2231 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2232 | |
| 2233 | } # ac_fn_c_check_func |
| 2234 | |
| 2235 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2236 | # ---------------------------------------------------- |
| 2237 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2238 | # INCLUDES, setting cache variable VAR accordingly. |
| 2239 | ac_fn_c_check_member () |
| 2240 | { |
| 2241 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2243 | $as_echo_n "checking for $2.$3... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2244 | if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2245 | $as_echo_n "(cached) " >&6 |
| 2246 | else |
| 2247 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2248 | /* end confdefs.h. */ |
| 2249 | $5 |
| 2250 | int |
| 2251 | main () |
| 2252 | { |
| 2253 | static $2 ac_aggr; |
| 2254 | if (ac_aggr.$3) |
| 2255 | return 0; |
| 2256 | ; |
| 2257 | return 0; |
| 2258 | } |
| 2259 | _ACEOF |
| 2260 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2261 | eval "$4=yes" |
| 2262 | else |
| 2263 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2264 | /* end confdefs.h. */ |
| 2265 | $5 |
| 2266 | int |
| 2267 | main () |
| 2268 | { |
| 2269 | static $2 ac_aggr; |
| 2270 | if (sizeof ac_aggr.$3) |
| 2271 | return 0; |
| 2272 | ; |
| 2273 | return 0; |
| 2274 | } |
| 2275 | _ACEOF |
| 2276 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2277 | eval "$4=yes" |
| 2278 | else |
| 2279 | eval "$4=no" |
| 2280 | fi |
| 2281 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2282 | fi |
| 2283 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2284 | fi |
| 2285 | eval ac_res=\$$4 |
| 2286 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2287 | $as_echo "$ac_res" >&6; } |
| 2288 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2289 | |
| 2290 | } # ac_fn_c_check_member |
| 2291 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2292 | # ac_fn_c_check_decl LINENO SYMBOL VAR |
| 2293 | # ------------------------------------ |
| 2294 | # Tests whether SYMBOL is declared, setting cache variable VAR accordingly. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2295 | ac_fn_c_check_decl () |
| 2296 | { |
| 2297 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2298 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5 |
| 2299 | $as_echo_n "checking whether $2 is declared... " >&6; } |
| 2300 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2301 | $as_echo_n "(cached) " >&6 |
| 2302 | else |
| 2303 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2304 | /* end confdefs.h. */ |
| 2305 | $4 |
| 2306 | int |
| 2307 | main () |
| 2308 | { |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2309 | #ifndef $2 |
| 2310 | (void) $2; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2311 | #endif |
| 2312 | |
| 2313 | ; |
| 2314 | return 0; |
| 2315 | } |
| 2316 | _ACEOF |
| 2317 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2318 | eval "$3=yes" |
| 2319 | else |
| 2320 | eval "$3=no" |
| 2321 | fi |
| 2322 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2323 | fi |
| 2324 | eval ac_res=\$$3 |
| 2325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2326 | $as_echo "$ac_res" >&6; } |
| 2327 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
| 2328 | |
| 2329 | } # ac_fn_c_check_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2330 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2331 | This file contains any messages produced by compilers while |
| 2332 | running configure, to aid debugging if configure makes a mistake. |
| 2333 | |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 2334 | It was created by python $as_me 3.2, which was |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2335 | generated by GNU Autoconf 2.65. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2336 | |
| 2337 | $ $0 $@ |
| 2338 | |
| 2339 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2340 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2341 | { |
| 2342 | cat <<_ASUNAME |
| 2343 | ## --------- ## |
| 2344 | ## Platform. ## |
| 2345 | ## --------- ## |
| 2346 | |
| 2347 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2348 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2349 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2350 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2351 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2352 | |
| 2353 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2354 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2355 | |
| 2356 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2357 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2358 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2359 | /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] | 2360 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2361 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2362 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2363 | |
| 2364 | _ASUNAME |
| 2365 | |
| 2366 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2367 | for as_dir in $PATH |
| 2368 | do |
| 2369 | IFS=$as_save_IFS |
| 2370 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2371 | $as_echo "PATH: $as_dir" |
| 2372 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2373 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2374 | |
| 2375 | } >&5 |
| 2376 | |
| 2377 | cat >&5 <<_ACEOF |
| 2378 | |
| 2379 | |
| 2380 | ## ----------- ## |
| 2381 | ## Core tests. ## |
| 2382 | ## ----------- ## |
| 2383 | |
| 2384 | _ACEOF |
| 2385 | |
| 2386 | |
| 2387 | # Keep a trace of the command line. |
| 2388 | # 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] | 2389 | # 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] | 2390 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2391 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2392 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2393 | ac_configure_args0= |
| 2394 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2395 | ac_must_keep_next=false |
| 2396 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2397 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2398 | for ac_arg |
| 2399 | do |
| 2400 | case $ac_arg in |
| 2401 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2402 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2403 | | -silent | --silent | --silen | --sile | --sil) |
| 2404 | continue ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2405 | *\'*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2406 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2407 | esac |
| 2408 | case $ac_pass in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2409 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2410 | 2) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2411 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2412 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2413 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2414 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2415 | case $ac_arg in |
| 2416 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2417 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2418 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2419 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2420 | case "$ac_configure_args0 " in |
| 2421 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2422 | esac |
| 2423 | ;; |
| 2424 | -* ) ac_must_keep_next=true ;; |
| 2425 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2426 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2427 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2428 | ;; |
| 2429 | esac |
| 2430 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2431 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2432 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2433 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2434 | |
| 2435 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2436 | # config.log. We remove comments because anyway the quotes in there |
| 2437 | # would cause problems or look ugly. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2438 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2439 | # 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] | 2440 | trap 'exit_status=$? |
| 2441 | # Save into config.log some information that might help in debugging. |
| 2442 | { |
| 2443 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2444 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2445 | cat <<\_ASBOX |
| 2446 | ## ---------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2447 | ## Cache variables. ## |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2448 | ## ---------------- ## |
| 2449 | _ASBOX |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2450 | echo |
| 2451 | # The following way of writing the cache mishandles newlines in values, |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2452 | ( |
| 2453 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2454 | eval ac_val=\$$ac_var |
| 2455 | case $ac_val in #( |
| 2456 | *${as_nl}*) |
| 2457 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2458 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2459 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2460 | esac |
| 2461 | case $ac_var in #( |
| 2462 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2463 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2464 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2465 | esac ;; |
| 2466 | esac |
| 2467 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2468 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2469 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2470 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2471 | sed -n \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2472 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2473 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2474 | ;; #( |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2475 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2476 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2477 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2478 | esac | |
| 2479 | sort |
| 2480 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2481 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2482 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2483 | cat <<\_ASBOX |
| 2484 | ## ----------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2485 | ## Output variables. ## |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2486 | ## ----------------- ## |
| 2487 | _ASBOX |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2488 | echo |
| 2489 | for ac_var in $ac_subst_vars |
| 2490 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2491 | eval ac_val=\$$ac_var |
| 2492 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2493 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2494 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2495 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2496 | done | sort |
| 2497 | echo |
| 2498 | |
| 2499 | if test -n "$ac_subst_files"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2500 | cat <<\_ASBOX |
| 2501 | ## ------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2502 | ## File substitutions. ## |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2503 | ## ------------------- ## |
| 2504 | _ASBOX |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2505 | echo |
| 2506 | for ac_var in $ac_subst_files |
| 2507 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2508 | eval ac_val=\$$ac_var |
| 2509 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2510 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2511 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2512 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2513 | done | sort |
| 2514 | echo |
| 2515 | fi |
| 2516 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2517 | if test -s confdefs.h; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2518 | cat <<\_ASBOX |
| 2519 | ## ----------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2520 | ## confdefs.h. ## |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2521 | ## ----------- ## |
| 2522 | _ASBOX |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2523 | echo |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2524 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2525 | echo |
| 2526 | fi |
| 2527 | test "$ac_signal" != 0 && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2528 | $as_echo "$as_me: caught signal $ac_signal" |
| 2529 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2530 | } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2531 | rm -f core *.core core.conftest.* && |
| 2532 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2533 | exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2534 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2535 | for ac_signal in 1 2 13 15; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2536 | 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] | 2537 | done |
| 2538 | ac_signal=0 |
| 2539 | |
| 2540 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2541 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2542 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2543 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2544 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2545 | # Predefined preprocessor variables. |
| 2546 | |
| 2547 | cat >>confdefs.h <<_ACEOF |
| 2548 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2549 | _ACEOF |
| 2550 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2551 | cat >>confdefs.h <<_ACEOF |
| 2552 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2553 | _ACEOF |
| 2554 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2555 | cat >>confdefs.h <<_ACEOF |
| 2556 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2557 | _ACEOF |
| 2558 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2559 | cat >>confdefs.h <<_ACEOF |
| 2560 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2561 | _ACEOF |
| 2562 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2563 | cat >>confdefs.h <<_ACEOF |
| 2564 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2565 | _ACEOF |
| 2566 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2567 | cat >>confdefs.h <<_ACEOF |
| 2568 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2569 | _ACEOF |
| 2570 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2571 | |
| 2572 | # Let the site file select an alternate cache file if it wants to. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2573 | # Prefer an explicitly selected file to automatically selected ones. |
| 2574 | ac_site_file1=NONE |
| 2575 | ac_site_file2=NONE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2576 | if test -n "$CONFIG_SITE"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2577 | ac_site_file1=$CONFIG_SITE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2578 | elif test "x$prefix" != xNONE; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2579 | ac_site_file1=$prefix/share/config.site |
| 2580 | ac_site_file2=$prefix/etc/config.site |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2581 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2582 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2583 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2584 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2585 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2586 | do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2587 | test "x$ac_site_file" = xNONE && continue |
| 2588 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2589 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2590 | $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] | 2591 | sed 's/^/| /' "$ac_site_file" >&5 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2592 | . "$ac_site_file" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2593 | fi |
| 2594 | done |
| 2595 | |
| 2596 | if test -r "$cache_file"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2597 | # Some versions of bash will fail to source /dev/null (special files |
| 2598 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2599 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2600 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2601 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2602 | case $cache_file in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2603 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2604 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2605 | esac |
| 2606 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2607 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2608 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2609 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2610 | >$cache_file |
| 2611 | fi |
| 2612 | |
| 2613 | # Check that the precious variables saved in the cache have kept the same |
| 2614 | # value. |
| 2615 | ac_cache_corrupted=false |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2616 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2617 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2618 | eval ac_new_set=\$ac_env_${ac_var}_set |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2619 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2620 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2621 | case $ac_old_set,$ac_new_set in |
| 2622 | set,) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2623 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2624 | $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] | 2625 | ac_cache_corrupted=: ;; |
| 2626 | ,set) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2627 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2628 | $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] | 2629 | ac_cache_corrupted=: ;; |
| 2630 | ,);; |
| 2631 | *) |
| 2632 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2633 | # differences in whitespace do not lead to failure. |
| 2634 | ac_old_val_w=`echo x $ac_old_val` |
| 2635 | ac_new_val_w=`echo x $ac_new_val` |
| 2636 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2637 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2638 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2639 | ac_cache_corrupted=: |
| 2640 | else |
| 2641 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2642 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2643 | eval $ac_var=\$ac_old_val |
| 2644 | fi |
| 2645 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2646 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2647 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2648 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2649 | fi;; |
| 2650 | esac |
| 2651 | # Pass precious variables to config.status. |
| 2652 | if test "$ac_new_set" = set; then |
| 2653 | case $ac_new_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2654 | *\'*) 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] | 2655 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2656 | esac |
| 2657 | case " $ac_configure_args " in |
| 2658 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2659 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2660 | esac |
| 2661 | fi |
| 2662 | done |
| 2663 | if $ac_cache_corrupted; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2664 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2665 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2666 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2667 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2668 | 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] | 2669 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2670 | ## -------------------- ## |
| 2671 | ## Main body of script. ## |
| 2672 | ## -------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2673 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2674 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2675 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2676 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2677 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2678 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2679 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2680 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2681 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2682 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2683 | |
| 2684 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2685 | |
Benjamin Peterson | d23f822 | 2009-04-05 19:13:16 +0000 | [diff] [blame] | 2686 | if test "$prefix" != "/"; then |
| 2687 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2688 | fi |
| 2689 | |
| 2690 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2691 | |
| 2692 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 2693 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 2694 | # with other autoconf-based packages that include Python.h |
| 2695 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 2696 | rm confdefs.h |
| 2697 | mv confdefs.h.new confdefs.h |
| 2698 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 2699 | |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 2700 | VERSION=3.2 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 2701 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2702 | # Version number of Python's own shared library file. |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 2703 | |
| 2704 | SOVERSION=1.0 |
| 2705 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2706 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 2707 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 2708 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2709 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2710 | |
| 2711 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2712 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2713 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 2714 | # them. |
| 2715 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2716 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2717 | |
| 2718 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2719 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2720 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 2721 | # them. |
| 2722 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2723 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2724 | |
| 2725 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2726 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2727 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 2728 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2729 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2730 | |
| 2731 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2732 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2733 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 2734 | # them. |
| 2735 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2736 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2737 | |
| 2738 | |
| 2739 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2740 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2741 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 2742 | # Arguments passed to configure. |
| 2743 | |
| 2744 | CONFIG_ARGS="$ac_configure_args" |
| 2745 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 2747 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2748 | # Check whether --enable-universalsdk was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2749 | if test "${enable_universalsdk+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2750 | enableval=$enable_universalsdk; |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2751 | case $enableval in |
| 2752 | yes) |
| 2753 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2754 | if test ! -d "${enableval}" |
| 2755 | then |
| 2756 | enableval=/ |
| 2757 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2758 | ;; |
| 2759 | esac |
| 2760 | case $enableval in |
| 2761 | no) |
| 2762 | UNIVERSALSDK= |
| 2763 | enable_universalsdk= |
| 2764 | ;; |
| 2765 | *) |
| 2766 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2767 | if test ! -d "${UNIVERSALSDK}" |
| 2768 | then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2769 | as_fn_error "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2770 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2771 | ;; |
| 2772 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2773 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2774 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2775 | else |
| 2776 | |
| 2777 | UNIVERSALSDK= |
| 2778 | enable_universalsdk= |
| 2779 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2780 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2781 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2782 | if test -n "${UNIVERSALSDK}" |
| 2783 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2784 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 2785 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2786 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2787 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2788 | $as_echo "no" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2789 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2790 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2791 | |
Benjamin Peterson | 6794aa3 | 2008-07-16 20:33:37 +0000 | [diff] [blame] | 2792 | |
| 2793 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2794 | UNIVERSAL_ARCHS="32-bit" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2795 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2796 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 2797 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2798 | |
| 2799 | # Check whether --with-universal-archs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2800 | if test "${with_universal_archs+set}" = set; then : |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2801 | withval=$with_universal_archs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2802 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 2803 | $as_echo "$withval" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2804 | UNIVERSAL_ARCHS="$withval" |
| 2805 | |
| 2806 | else |
| 2807 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2808 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 32-bit" >&5 |
| 2809 | $as_echo "32-bit" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2810 | |
| 2811 | fi |
| 2812 | |
| 2813 | |
| 2814 | |
| 2815 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2816 | |
| 2817 | # Check whether --with-framework-name was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2818 | if test "${with_framework_name+set}" = set; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2819 | withval=$with_framework_name; |
| 2820 | PYTHONFRAMEWORK=${withval} |
| 2821 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 2822 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 2823 | |
| 2824 | else |
| 2825 | |
| 2826 | PYTHONFRAMEWORK=Python |
| 2827 | PYTHONFRAMEWORKDIR=Python.framework |
| 2828 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 2829 | |
| 2830 | fi |
| 2831 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2832 | # Check whether --enable-framework was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2833 | if test "${enable_framework+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2834 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2835 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2836 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2837 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2838 | esac |
| 2839 | case $enableval in |
| 2840 | no) |
| 2841 | PYTHONFRAMEWORK= |
| 2842 | PYTHONFRAMEWORKDIR=no-framework |
| 2843 | PYTHONFRAMEWORKPREFIX= |
| 2844 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2845 | FRAMEWORKINSTALLFIRST= |
| 2846 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2847 | FRAMEWORKALTINSTALLFIRST= |
| 2848 | FRAMEWORKALTINSTALLLAST= |
| 2849 | if test "x${prefix}" = "xNONE"; then |
| 2850 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2851 | else |
| 2852 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2853 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2854 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2855 | ;; |
| 2856 | *) |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2857 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2858 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2859 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | f6ccbf6 | 2009-06-02 10:55:56 +0000 | [diff] [blame] | 2860 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure " |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2861 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 2862 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2863 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2864 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2865 | if test "x${prefix}" = "xNONE" ; then |
| 2866 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2867 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2868 | else |
| 2869 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2870 | fi |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2871 | |
| 2872 | case "${enableval}" in |
| 2873 | /System*) |
| 2874 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2875 | if test "${prefix}" = "NONE" ; then |
| 2876 | # See below |
| 2877 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 2878 | fi |
| 2879 | ;; |
| 2880 | |
| 2881 | /Library*) |
| 2882 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2883 | ;; |
| 2884 | |
| 2885 | */Library/Frameworks) |
| 2886 | MDIR="`dirname "${enableval}"`" |
| 2887 | MDIR="`dirname "${MDIR}"`" |
| 2888 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 2889 | |
| 2890 | if test "${prefix}" = "NONE"; then |
| 2891 | # User hasn't specified the |
| 2892 | # --prefix option, but wants to install |
| 2893 | # the framework in a non-default location, |
| 2894 | # ensure that the compatibility links get |
| 2895 | # installed relative to that prefix as well |
| 2896 | # instead of in /usr/local. |
| 2897 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 2898 | fi |
| 2899 | ;; |
| 2900 | |
| 2901 | *) |
| 2902 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2903 | ;; |
| 2904 | esac |
| 2905 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2906 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2907 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2908 | # Add files for Mac specific code to the list of output |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2909 | # files: |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2910 | ac_config_files="$ac_config_files Mac/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2911 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2912 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2913 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2914 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 2915 | |
| 2916 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 2917 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2918 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2919 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2920 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2921 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2922 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2923 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2924 | PYTHONFRAMEWORKPREFIX= |
| 2925 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2926 | FRAMEWORKINSTALLFIRST= |
| 2927 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2928 | FRAMEWORKALTINSTALLFIRST= |
| 2929 | FRAMEWORKALTINSTALLLAST= |
| 2930 | if test "x${prefix}" = "xNONE" ; then |
| 2931 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2932 | else |
| 2933 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2934 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2935 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2936 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2937 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2938 | fi |
| 2939 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2940 | |
| 2941 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2942 | |
| 2943 | |
| 2944 | |
| 2945 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2946 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2947 | |
| 2948 | |
| 2949 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2950 | |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2951 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2952 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 2b8733f | 2010-04-25 18:34:36 +0000 | [diff] [blame] | 2953 | ## AS_HELP_STRING([--with-dyld], |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 2954 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2955 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2956 | # Set name for machine-dependent library files |
| 2957 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 2959 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2960 | if test -z "$MACHDEP" |
| 2961 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2962 | ac_sys_system=`uname -s` |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 2963 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 2964 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2965 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2966 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2967 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2968 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2969 | ac_md_system=`echo $ac_sys_system | |
| 2970 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 2971 | ac_md_release=`echo $ac_sys_release | |
Guido van Rossum | 67b2659 | 2001-10-20 14:21:45 +0000 | [diff] [blame] | 2972 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2973 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2974 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2975 | case $MACHDEP in |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 2976 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 2977 | darwin*) MACHDEP="darwin";; |
Martin v. Löwis | f332228 | 2003-07-13 09:46:13 +0000 | [diff] [blame] | 2978 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2979 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2980 | esac |
| 2981 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 2982 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2983 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 2984 | # disable features if it is defined, without any means to access these |
| 2985 | # features as extensions. For these systems, we skip the definition of |
| 2986 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 2987 | # some feature, make sure there is no alternative way to access this |
| 2988 | # feature. Also, when using wildcards, make sure you have verified the |
| 2989 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 2990 | # wildcard, and that the wildcard does not include future systems |
| 2991 | # (which may remove their limitations). |
| 2992 | case $ac_sys_system/$ac_sys_release in |
| 2993 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 2994 | # 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] | 2995 | # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish. |
Martin v. Löwis | 19ed3c8 | 2010-02-15 21:45:06 +0000 | [diff] [blame] | 2996 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 2997 | # OpenBSD 4.6, but is fixed in 4.7. |
| 2998 | OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123456]) |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 2999 | define_xopen_source=no |
| 3000 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3001 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3002 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3003 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3004 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3005 | |
| 3006 | ;; |
Martin v. Löwis | 19ed3c8 | 2010-02-15 21:45:06 +0000 | [diff] [blame] | 3007 | OpenBSD/4.[789]) |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3008 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3009 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3010 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3011 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3012 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3013 | |
| 3014 | ;; |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 3015 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3016 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3017 | # Marc Recht |
Benjamin Peterson | f608c61 | 2008-11-16 18:33:53 +0000 | [diff] [blame] | 3018 | NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S]) |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3019 | define_xopen_source=no;; |
Martin v. Löwis | 1a41576 | 2010-05-28 15:44:20 +0000 | [diff] [blame] | 3020 | # From the perspective of Solaris, _XOPEN_SOURCE is not so much a |
| 3021 | # request to enable features supported by the standard as a request |
| 3022 | # to disable features not supported by the standard. The best way |
| 3023 | # for Python to use Solaris is simply to leave _XOPEN_SOURCE out |
| 3024 | # entirely and define __EXTENSIONS__ instead. |
| 3025 | SunOS/*) |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3026 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3027 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3028 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3029 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3030 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3031 | define_xopen_source=no;; |
| 3032 | # 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] | 3033 | # 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] | 3034 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3035 | define_xopen_source=no;; |
Martin v. Löwis | b37509b | 2008-11-04 20:45:29 +0000 | [diff] [blame] | 3036 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3037 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3038 | FreeBSD/4.*) |
| 3039 | define_xopen_source=no;; |
| 3040 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3041 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3042 | # identifies itself as Darwin/7.* |
| 3043 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3044 | # disables platform specific features beyond repair. |
| 3045 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3046 | # has no effect, don't bother defining them |
| 3047 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3048 | define_xopen_source=no;; |
Ronald Oussoren | 92fb941 | 2010-03-09 06:40:19 +0000 | [diff] [blame] | 3049 | Darwin/1[0-9].*) |
Ronald Oussoren | b8f11a6 | 2010-03-08 07:02:03 +0000 | [diff] [blame] | 3050 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3051 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3052 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3053 | # 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] | 3054 | AIX/4) |
| 3055 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3056 | AIX/5) |
| 3057 | if test `uname -r` -eq 1; then |
| 3058 | define_xopen_source=no |
| 3059 | fi |
| 3060 | ;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 3061 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3062 | # defining NI_NUMERICHOST. |
| 3063 | QNX/6.3.2) |
| 3064 | define_xopen_source=no |
| 3065 | ;; |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3066 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3067 | esac |
| 3068 | |
| 3069 | if test $define_xopen_source = yes |
| 3070 | then |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3071 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3072 | $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3073 | |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3074 | |
| 3075 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3076 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3077 | # several APIs are not declared. Since this is also needed in some |
| 3078 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3079 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3080 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3081 | |
| 3082 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3083 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3084 | $as_echo "#define _POSIX_C_SOURCE 200112L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3085 | |
| 3086 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3087 | fi |
| 3088 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3089 | # |
| 3090 | # SGI compilers allow the specification of the both the ABI and the |
| 3091 | # ISA on the command line. Depending on the values of these switches, |
| 3092 | # different and often incompatable code will be generated. |
| 3093 | # |
| 3094 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3095 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3096 | # variable is also adjusted. |
| 3097 | # |
| 3098 | |
| 3099 | if test ! -z "$SGI_ABI" |
| 3100 | then |
| 3101 | CC="cc $SGI_ABI" |
| 3102 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3103 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3104 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3105 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3106 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3107 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3108 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3109 | # it may influence the way we can build extensions, so distutils |
| 3110 | # needs to check it |
| 3111 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3112 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3113 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3114 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3115 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3116 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking machine type as reported by uname -m" >&5 |
| 3117 | $as_echo_n "checking machine type as reported by uname -m... " >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3118 | ac_sys_machine=`uname -m` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_sys_machine" >&5 |
| 3120 | $as_echo "$ac_sys_machine" >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3121 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3122 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3123 | |
| 3124 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3125 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3126 | # just to get things to compile and link. Users are free to override OPT |
| 3127 | # when running configure or make. The build should not break if they do. |
| 3128 | # BASECFLAGS should generally not be messed with, however. |
| 3129 | |
| 3130 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3131 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3132 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3133 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3134 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3135 | # Check whether --with-gcc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3136 | if test "${with_gcc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3137 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3138 | case $withval in |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 3139 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3140 | without_gcc=yes;; |
| 3141 | yes) CC=gcc |
| 3142 | without_gcc=no;; |
| 3143 | *) CC=$withval |
| 3144 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3145 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3146 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3147 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3148 | case $ac_sys_system in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3149 | AIX*) CC=cc_r |
| 3150 | without_gcc=;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3151 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3152 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3153 | fi |
| 3154 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3156 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3157 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3158 | # If the user switches compilers, we can't believe the cache |
| 3159 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3160 | then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3161 | as_fn_error "cached CC is different -- throw away $cache_file |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3162 | (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] | 3163 | fi |
| 3164 | |
Jeffrey Yasskin | d4fcdb1 | 2010-07-09 16:30:58 +0000 | [diff] [blame] | 3165 | # Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2 |
| 3166 | # when the compiler supports them, but we don't always want -O2, and |
| 3167 | # we set -g later. |
| 3168 | if test -z "$CFLAGS"; then |
| 3169 | CFLAGS= |
| 3170 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3171 | ac_ext=c |
| 3172 | ac_cpp='$CPP $CPPFLAGS' |
| 3173 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3174 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3175 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3176 | if test -n "$ac_tool_prefix"; then |
| 3177 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3178 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3179 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3180 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3181 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3182 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3183 | else |
| 3184 | if test -n "$CC"; then |
| 3185 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3186 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3187 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3188 | for as_dir in $PATH |
| 3189 | do |
| 3190 | IFS=$as_save_IFS |
| 3191 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3192 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3193 | 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] | 3194 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3195 | $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] | 3196 | break 2 |
| 3197 | fi |
| 3198 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3199 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3200 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3201 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3202 | fi |
| 3203 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3204 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3205 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3206 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3207 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3208 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3210 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3211 | fi |
| 3212 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3213 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3214 | fi |
| 3215 | if test -z "$ac_cv_prog_CC"; then |
| 3216 | ac_ct_CC=$CC |
| 3217 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3218 | set dummy gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3219 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3220 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3221 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
| 3222 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3223 | else |
| 3224 | if test -n "$ac_ct_CC"; then |
| 3225 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3226 | else |
| 3227 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3228 | for as_dir in $PATH |
| 3229 | do |
| 3230 | IFS=$as_save_IFS |
| 3231 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3232 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3233 | 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] | 3234 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3235 | $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] | 3236 | break 2 |
| 3237 | fi |
| 3238 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3239 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3240 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3241 | |
| 3242 | fi |
| 3243 | fi |
| 3244 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3245 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3246 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3247 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3248 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3249 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3250 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3251 | fi |
| 3252 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3253 | if test "x$ac_ct_CC" = x; then |
| 3254 | CC="" |
| 3255 | else |
| 3256 | case $cross_compiling:$ac_tool_warned in |
| 3257 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3258 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3259 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3260 | ac_tool_warned=yes ;; |
| 3261 | esac |
| 3262 | CC=$ac_ct_CC |
| 3263 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3264 | else |
| 3265 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3266 | fi |
| 3267 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3268 | if test -z "$CC"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3269 | if test -n "$ac_tool_prefix"; then |
| 3270 | # 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] | 3271 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3272 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3273 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3274 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3275 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3276 | else |
| 3277 | if test -n "$CC"; then |
| 3278 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3279 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3280 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3281 | for as_dir in $PATH |
| 3282 | do |
| 3283 | IFS=$as_save_IFS |
| 3284 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3285 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3286 | 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] | 3287 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3288 | $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] | 3289 | break 2 |
| 3290 | fi |
| 3291 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3292 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3293 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3294 | |
| 3295 | fi |
| 3296 | fi |
| 3297 | CC=$ac_cv_prog_CC |
| 3298 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3299 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3300 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3301 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3302 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3303 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3304 | fi |
| 3305 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3306 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3307 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3308 | fi |
| 3309 | if test -z "$CC"; then |
| 3310 | # Extract the first word of "cc", so it can be a program name with args. |
| 3311 | set dummy cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3312 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3313 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3314 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3315 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3316 | else |
| 3317 | if test -n "$CC"; then |
| 3318 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3319 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3320 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3321 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3322 | for as_dir in $PATH |
| 3323 | do |
| 3324 | IFS=$as_save_IFS |
| 3325 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3326 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3327 | 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] | 3328 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3329 | ac_prog_rejected=yes |
| 3330 | continue |
| 3331 | fi |
| 3332 | ac_cv_prog_CC="cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3333 | $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] | 3334 | break 2 |
| 3335 | fi |
| 3336 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3337 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3338 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3339 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3340 | if test $ac_prog_rejected = yes; then |
| 3341 | # We found a bogon in the path, so make sure we never use it. |
| 3342 | set dummy $ac_cv_prog_CC |
| 3343 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3344 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3345 | # We chose a different compiler from the bogus one. |
| 3346 | # However, it has the same basename, so the bogon will be chosen |
| 3347 | # first if we set CC to just the basename; use the full file name. |
| 3348 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3349 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3350 | fi |
| 3351 | fi |
| 3352 | fi |
| 3353 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3354 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3355 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3356 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3357 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3358 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3359 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3360 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3361 | fi |
| 3362 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3363 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3364 | fi |
| 3365 | if test -z "$CC"; then |
| 3366 | if test -n "$ac_tool_prefix"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3367 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3368 | do |
| 3369 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3370 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3372 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3373 | if test "${ac_cv_prog_CC+set}" = set; then : |
| 3374 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3375 | else |
| 3376 | if test -n "$CC"; then |
| 3377 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3378 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3379 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3380 | for as_dir in $PATH |
| 3381 | do |
| 3382 | IFS=$as_save_IFS |
| 3383 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3384 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3385 | 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] | 3386 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3387 | $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] | 3388 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3389 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3390 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3391 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3392 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3393 | |
| 3394 | fi |
| 3395 | fi |
| 3396 | CC=$ac_cv_prog_CC |
| 3397 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3398 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3399 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3400 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3401 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3402 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3403 | fi |
| 3404 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3405 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3406 | test -n "$CC" && break |
| 3407 | done |
| 3408 | fi |
| 3409 | if test -z "$CC"; then |
| 3410 | ac_ct_CC=$CC |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3411 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3412 | do |
| 3413 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3414 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3415 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3416 | $as_echo_n "checking for $ac_word... " >&6; } |
| 3417 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
| 3418 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3419 | else |
| 3420 | if test -n "$ac_ct_CC"; then |
| 3421 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3422 | else |
| 3423 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3424 | for as_dir in $PATH |
| 3425 | do |
| 3426 | IFS=$as_save_IFS |
| 3427 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3428 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3429 | 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] | 3430 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3431 | $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] | 3432 | break 2 |
| 3433 | fi |
| 3434 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3435 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3436 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3437 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3438 | fi |
| 3439 | fi |
| 3440 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3441 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3442 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3443 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3444 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3445 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3446 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3447 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3448 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3449 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3450 | test -n "$ac_ct_CC" && break |
| 3451 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3452 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3453 | if test "x$ac_ct_CC" = x; then |
| 3454 | CC="" |
| 3455 | else |
| 3456 | case $cross_compiling:$ac_tool_warned in |
| 3457 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3458 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3459 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3460 | ac_tool_warned=yes ;; |
| 3461 | esac |
| 3462 | CC=$ac_ct_CC |
| 3463 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3464 | fi |
| 3465 | |
| 3466 | fi |
| 3467 | |
| 3468 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3469 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3470 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3471 | as_fn_error "no acceptable C compiler found in \$PATH |
| 3472 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3473 | |
| 3474 | # Provide some information about the compiler. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3475 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3476 | set X $ac_compile |
| 3477 | ac_compiler=$2 |
| 3478 | for ac_option in --version -v -V -qversion; do |
| 3479 | { { ac_try="$ac_compiler $ac_option >&5" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3480 | case "(($ac_try" in |
| 3481 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3482 | *) ac_try_echo=$ac_try;; |
| 3483 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3484 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3485 | $as_echo "$ac_try_echo"; } >&5 |
| 3486 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3487 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3488 | if test -s conftest.err; then |
| 3489 | sed '10a\ |
| 3490 | ... rest of stderr output deleted ... |
| 3491 | 10q' conftest.err >conftest.er1 |
| 3492 | cat conftest.er1 >&5 |
| 3493 | fi |
| 3494 | rm -f conftest.er1 conftest.err |
| 3495 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3496 | test $ac_status = 0; } |
| 3497 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3498 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3499 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3500 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3501 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3502 | int |
| 3503 | main () |
| 3504 | { |
| 3505 | |
| 3506 | ; |
| 3507 | return 0; |
| 3508 | } |
| 3509 | _ACEOF |
| 3510 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3511 | 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] | 3512 | # Try to create an executable without -o first, disregard a.out. |
| 3513 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3514 | # of exeext. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3515 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3516 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3517 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3518 | |
| 3519 | # The possible output files: |
| 3520 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3521 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3522 | ac_rmfiles= |
| 3523 | for ac_file in $ac_files |
| 3524 | do |
| 3525 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3526 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3527 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3528 | esac |
| 3529 | done |
| 3530 | rm -f $ac_rmfiles |
| 3531 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3532 | if { { ac_try="$ac_link_default" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3533 | case "(($ac_try" in |
| 3534 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3535 | *) ac_try_echo=$ac_try;; |
| 3536 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3537 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3538 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3539 | (eval "$ac_link_default") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3540 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3541 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3542 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3543 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3544 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3545 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3546 | # so that the user can short-circuit this test for compilers unknown to |
| 3547 | # Autoconf. |
| 3548 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3549 | do |
| 3550 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3551 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3552 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3553 | ;; |
| 3554 | [ab].out ) |
| 3555 | # We found the default executable, but exeext='' is most |
| 3556 | # certainly right. |
| 3557 | break;; |
| 3558 | *.* ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3559 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3560 | then :; else |
| 3561 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3562 | fi |
| 3563 | # We set ac_cv_exeext here because the later test for it is not |
| 3564 | # safe: cross compilers may not add the suffix if given an `-o' |
| 3565 | # argument, so we may need to know it at that point already. |
| 3566 | # Even if this section looks crufty: it has the advantage of |
| 3567 | # actually working. |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3568 | break;; |
| 3569 | * ) |
| 3570 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3571 | esac |
| 3572 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3573 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 3574 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3575 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3576 | ac_file='' |
| 3577 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3578 | if test -z "$ac_file"; then : |
| 3579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3580 | $as_echo "no" >&6; } |
| 3581 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3582 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3583 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3584 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3585 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3586 | { as_fn_set_status 77 |
| 3587 | as_fn_error "C compiler cannot create executables |
| 3588 | See \`config.log' for more details." "$LINENO" 5; }; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3589 | else |
| 3590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 3591 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3592 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3593 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 3594 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 3595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 3596 | $as_echo "$ac_file" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3597 | ac_exeext=$ac_cv_exeext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3598 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3599 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3600 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3601 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 3602 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 3603 | if { { ac_try="$ac_link" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3604 | case "(($ac_try" in |
| 3605 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3606 | *) ac_try_echo=$ac_try;; |
| 3607 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3608 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3609 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3610 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3611 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3612 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3613 | test $ac_status = 0; }; then : |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3614 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 3615 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 3616 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 3617 | # `rm'. |
| 3618 | for ac_file in conftest.exe conftest conftest.*; do |
| 3619 | test -f "$ac_file" || continue |
| 3620 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3621 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3622 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3623 | break;; |
| 3624 | * ) break;; |
| 3625 | esac |
| 3626 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3627 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3628 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3629 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3630 | as_fn_error "cannot compute suffix of executables: cannot compile and link |
| 3631 | See \`config.log' for more details." "$LINENO" 5; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3632 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3633 | rm -f conftest conftest$ac_cv_exeext |
| 3634 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 3635 | $as_echo "$ac_cv_exeext" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3636 | |
| 3637 | rm -f conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3638 | EXEEXT=$ac_cv_exeext |
| 3639 | ac_exeext=$EXEEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3640 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3641 | /* end confdefs.h. */ |
| 3642 | #include <stdio.h> |
| 3643 | int |
| 3644 | main () |
| 3645 | { |
| 3646 | FILE *f = fopen ("conftest.out", "w"); |
| 3647 | return ferror (f) || fclose (f) != 0; |
| 3648 | |
| 3649 | ; |
| 3650 | return 0; |
| 3651 | } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3652 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3653 | ac_clean_files="$ac_clean_files conftest.out" |
| 3654 | # Check that the compiler produces executables we can run. If not, either |
| 3655 | # the compiler is broken, or we cross compile. |
| 3656 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3657 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3658 | if test "$cross_compiling" != yes; then |
| 3659 | { { ac_try="$ac_link" |
| 3660 | case "(($ac_try" in |
| 3661 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3662 | *) ac_try_echo=$ac_try;; |
| 3663 | esac |
| 3664 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3665 | $as_echo "$ac_try_echo"; } >&5 |
| 3666 | (eval "$ac_link") 2>&5 |
| 3667 | ac_status=$? |
| 3668 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3669 | test $ac_status = 0; } |
| 3670 | if { ac_try='./conftest$ac_cv_exeext' |
| 3671 | { { case "(($ac_try" in |
| 3672 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3673 | *) ac_try_echo=$ac_try;; |
| 3674 | esac |
| 3675 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3676 | $as_echo "$ac_try_echo"; } >&5 |
| 3677 | (eval "$ac_try") 2>&5 |
| 3678 | ac_status=$? |
| 3679 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3680 | test $ac_status = 0; }; }; then |
| 3681 | cross_compiling=no |
| 3682 | else |
| 3683 | if test "$cross_compiling" = maybe; then |
| 3684 | cross_compiling=yes |
| 3685 | else |
| 3686 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3687 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3688 | as_fn_error "cannot run C compiled programs. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3689 | If you meant to cross compile, use \`--host'. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3690 | See \`config.log' for more details." "$LINENO" 5; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3691 | fi |
| 3692 | fi |
| 3693 | fi |
| 3694 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3695 | $as_echo "$cross_compiling" >&6; } |
| 3696 | |
| 3697 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3698 | ac_clean_files=$ac_clean_files_save |
| 3699 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3700 | $as_echo_n "checking for suffix of object files... " >&6; } |
| 3701 | if test "${ac_cv_objext+set}" = set; then : |
| 3702 | $as_echo_n "(cached) " >&6 |
| 3703 | else |
| 3704 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3705 | /* end confdefs.h. */ |
| 3706 | |
| 3707 | int |
| 3708 | main () |
| 3709 | { |
| 3710 | |
| 3711 | ; |
| 3712 | return 0; |
| 3713 | } |
| 3714 | _ACEOF |
| 3715 | rm -f conftest.o conftest.obj |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3716 | if { { ac_try="$ac_compile" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3717 | case "(($ac_try" in |
| 3718 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3719 | *) ac_try_echo=$ac_try;; |
| 3720 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3721 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3722 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3723 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3724 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3725 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3726 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3727 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3728 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3729 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3730 | *.$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] | 3731 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3732 | break;; |
| 3733 | esac |
| 3734 | done |
| 3735 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3736 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3737 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3738 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3739 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3740 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 3741 | as_fn_error "cannot compute suffix of object files: cannot compile |
| 3742 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3743 | fi |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3744 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3745 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3746 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3747 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3748 | OBJEXT=$ac_cv_objext |
| 3749 | ac_objext=$OBJEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3751 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
| 3752 | if test "${ac_cv_c_compiler_gnu+set}" = set; then : |
| 3753 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3754 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3756 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3757 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3758 | int |
| 3759 | main () |
| 3760 | { |
| 3761 | #ifndef __GNUC__ |
| 3762 | choke me |
| 3763 | #endif |
| 3764 | |
| 3765 | ; |
| 3766 | return 0; |
| 3767 | } |
| 3768 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3769 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3770 | ac_compiler_gnu=yes |
| 3771 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3772 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3773 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3774 | 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] | 3775 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3776 | |
| 3777 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3778 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 3779 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3780 | if test $ac_compiler_gnu = yes; then |
| 3781 | GCC=yes |
| 3782 | else |
| 3783 | GCC= |
| 3784 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3785 | ac_test_CFLAGS=${CFLAGS+set} |
| 3786 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3787 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3788 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
| 3789 | if test "${ac_cv_prog_cc_g+set}" = set; then : |
| 3790 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3791 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3792 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3793 | ac_c_werror_flag=yes |
| 3794 | ac_cv_prog_cc_g=no |
| 3795 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3796 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3797 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3798 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3799 | int |
| 3800 | main () |
| 3801 | { |
| 3802 | |
| 3803 | ; |
| 3804 | return 0; |
| 3805 | } |
| 3806 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3807 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3808 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3809 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3810 | CFLAGS="" |
| 3811 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3812 | /* end confdefs.h. */ |
| 3813 | |
| 3814 | int |
| 3815 | main () |
| 3816 | { |
| 3817 | |
| 3818 | ; |
| 3819 | return 0; |
| 3820 | } |
| 3821 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3822 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3823 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3824 | else |
| 3825 | ac_c_werror_flag=$ac_save_c_werror_flag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3826 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3828 | /* end confdefs.h. */ |
| 3829 | |
| 3830 | int |
| 3831 | main () |
| 3832 | { |
| 3833 | |
| 3834 | ; |
| 3835 | return 0; |
| 3836 | } |
| 3837 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3838 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3839 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3840 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3841 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3842 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3843 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3844 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3845 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3846 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3847 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3849 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3850 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3851 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3852 | elif test $ac_cv_prog_cc_g = yes; then |
| 3853 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3854 | CFLAGS="-g -O2" |
| 3855 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3856 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3857 | fi |
| 3858 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3859 | if test "$GCC" = yes; then |
| 3860 | CFLAGS="-O2" |
| 3861 | else |
| 3862 | CFLAGS= |
| 3863 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3864 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3865 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3866 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
| 3867 | if test "${ac_cv_prog_cc_c89+set}" = set; then : |
| 3868 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3869 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3870 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3871 | ac_save_CC=$CC |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3872 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3873 | /* end confdefs.h. */ |
| 3874 | #include <stdarg.h> |
| 3875 | #include <stdio.h> |
| 3876 | #include <sys/types.h> |
| 3877 | #include <sys/stat.h> |
| 3878 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3879 | struct buf { int x; }; |
| 3880 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3881 | static char *e (p, i) |
| 3882 | char **p; |
| 3883 | int i; |
| 3884 | { |
| 3885 | return p[i]; |
| 3886 | } |
| 3887 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3888 | { |
| 3889 | char *s; |
| 3890 | va_list v; |
| 3891 | va_start (v,p); |
| 3892 | s = g (p, va_arg (v,int)); |
| 3893 | va_end (v); |
| 3894 | return s; |
| 3895 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3896 | |
| 3897 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3898 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3899 | These don't provoke an error unfortunately, instead are silently treated |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3900 | 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] | 3901 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3902 | array size at least. It's necessary to write '\x00'==0 to get something |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3903 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3904 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3905 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3906 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3907 | inside strings and character constants. */ |
| 3908 | #define FOO(x) 'x' |
| 3909 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3910 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3911 | int test (int i, double x); |
| 3912 | struct s1 {int (*f) (int a);}; |
| 3913 | struct s2 {int (*f) (double a);}; |
| 3914 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3915 | int argc; |
| 3916 | char **argv; |
| 3917 | int |
| 3918 | main () |
| 3919 | { |
| 3920 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3921 | ; |
| 3922 | return 0; |
| 3923 | } |
| 3924 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3925 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3926 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3927 | do |
| 3928 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3929 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3930 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3931 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3932 | rm -f core conftest.err conftest.$ac_objext |
| 3933 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3934 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3935 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3936 | CC=$ac_save_CC |
| 3937 | |
| 3938 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3939 | # AC_CACHE_VAL |
| 3940 | case "x$ac_cv_prog_cc_c89" in |
| 3941 | x) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3942 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 3943 | $as_echo "none needed" >&6; } ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3944 | xno) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3945 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 3946 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3947 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3948 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 3950 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3951 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3952 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3953 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3954 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3955 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3956 | ac_ext=c |
| 3957 | ac_cpp='$CPP $CPPFLAGS' |
| 3958 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3959 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3960 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3961 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 3962 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3963 | |
| 3964 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3965 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 3966 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3967 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3968 | # Check whether --with-cxx_main was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3969 | if test "${with_cxx_main+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3970 | withval=$with_cxx_main; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3971 | |
| 3972 | case $withval in |
| 3973 | no) with_cxx_main=no |
| 3974 | MAINCC='$(CC)';; |
| 3975 | yes) with_cxx_main=yes |
| 3976 | MAINCC='$(CXX)';; |
| 3977 | *) with_cxx_main=yes |
| 3978 | MAINCC=$withval |
| 3979 | if test -z "$CXX" |
| 3980 | then |
| 3981 | CXX=$withval |
| 3982 | fi;; |
| 3983 | esac |
| 3984 | else |
| 3985 | |
| 3986 | with_cxx_main=no |
| 3987 | MAINCC='$(CC)' |
| 3988 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3989 | fi |
| 3990 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 3992 | $as_echo "$with_cxx_main" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3993 | |
| 3994 | preset_cxx="$CXX" |
| 3995 | if test -z "$CXX" |
| 3996 | then |
| 3997 | case "$CC" in |
| 3998 | gcc) # Extract the first word of "g++", so it can be a program name with args. |
| 3999 | set dummy g++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4000 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4001 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4002 | if test "${ac_cv_path_CXX+set}" = set; then : |
| 4003 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4004 | else |
| 4005 | case $CXX in |
| 4006 | [\\/]* | ?:[\\/]*) |
| 4007 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4008 | ;; |
| 4009 | *) |
| 4010 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4011 | for as_dir in notfound |
| 4012 | do |
| 4013 | IFS=$as_save_IFS |
| 4014 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4015 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4016 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4017 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4018 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4019 | break 2 |
| 4020 | fi |
| 4021 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4022 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4023 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4024 | |
| 4025 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++" |
| 4026 | ;; |
| 4027 | esac |
| 4028 | fi |
| 4029 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4030 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4031 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4032 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4033 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4034 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4035 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4036 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4037 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4038 | ;; |
| 4039 | cc) # Extract the first word of "c++", so it can be a program name with args. |
| 4040 | set dummy c++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4041 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4042 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4043 | if test "${ac_cv_path_CXX+set}" = set; then : |
| 4044 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4045 | else |
| 4046 | case $CXX in |
| 4047 | [\\/]* | ?:[\\/]*) |
| 4048 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4049 | ;; |
| 4050 | *) |
| 4051 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4052 | for as_dir in notfound |
| 4053 | do |
| 4054 | IFS=$as_save_IFS |
| 4055 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4056 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4057 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4058 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4059 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4060 | break 2 |
| 4061 | fi |
| 4062 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4063 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4064 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4065 | |
| 4066 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++" |
| 4067 | ;; |
| 4068 | esac |
| 4069 | fi |
| 4070 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4071 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4072 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4073 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4074 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4075 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4076 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4077 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4078 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4079 | ;; |
| 4080 | esac |
| 4081 | if test "$CXX" = "notfound" |
| 4082 | then |
| 4083 | CXX="" |
| 4084 | fi |
| 4085 | fi |
| 4086 | if test -z "$CXX" |
| 4087 | then |
| 4088 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4089 | do |
| 4090 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4091 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4092 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4093 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4094 | if test "${ac_cv_prog_CXX+set}" = set; then : |
| 4095 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4096 | else |
| 4097 | if test -n "$CXX"; then |
| 4098 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4099 | else |
| 4100 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4101 | for as_dir in $PATH |
| 4102 | do |
| 4103 | IFS=$as_save_IFS |
| 4104 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4105 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4106 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4107 | ac_cv_prog_CXX="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4108 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4109 | break 2 |
| 4110 | fi |
| 4111 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4112 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4113 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4114 | |
| 4115 | fi |
| 4116 | fi |
| 4117 | CXX=$ac_cv_prog_CXX |
| 4118 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4120 | $as_echo "$CXX" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4121 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4122 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4123 | $as_echo "no" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4124 | fi |
| 4125 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4126 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4127 | test -n "$CXX" && break |
| 4128 | done |
| 4129 | test -n "$CXX" || CXX="notfound" |
| 4130 | |
| 4131 | if test "$CXX" = "notfound" |
| 4132 | then |
| 4133 | CXX="" |
| 4134 | fi |
| 4135 | fi |
| 4136 | if test "$preset_cxx" != "$CXX" |
| 4137 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4138 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4139 | |
| 4140 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4141 | If this is not intended, then set CXX on the configure command line. |
| 4142 | " >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4143 | $as_echo "$as_me: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4144 | |
| 4145 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4146 | If this is not intended, then set CXX on the configure command line. |
| 4147 | " >&2;} |
| 4148 | fi |
| 4149 | |
| 4150 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4151 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4152 | |
| 4153 | ac_ext=c |
| 4154 | ac_cpp='$CPP $CPPFLAGS' |
| 4155 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4156 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4157 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4159 | $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] | 4160 | # On Suns, sometimes $CPP names a directory. |
| 4161 | if test -n "$CPP" && test -d "$CPP"; then |
| 4162 | CPP= |
| 4163 | fi |
| 4164 | if test -z "$CPP"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4165 | if test "${ac_cv_prog_CPP+set}" = set; then : |
| 4166 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4167 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4168 | # Double quotes because CPP needs to be expanded |
| 4169 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4170 | do |
| 4171 | ac_preproc_ok=false |
| 4172 | for ac_c_preproc_warn_flag in '' yes |
| 4173 | do |
| 4174 | # Use a header file that comes with gcc, so configuring glibc |
| 4175 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4176 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4177 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4178 | # 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] | 4179 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4180 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4181 | /* end confdefs.h. */ |
| 4182 | #ifdef __STDC__ |
| 4183 | # include <limits.h> |
| 4184 | #else |
| 4185 | # include <assert.h> |
| 4186 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4187 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4188 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4189 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4190 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4191 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4192 | # Broken: fails on valid input. |
| 4193 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4194 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4195 | rm -f conftest.err conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4196 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4197 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4198 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4199 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4200 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4201 | #include <ac_nonexistent.h> |
| 4202 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4203 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4204 | # Broken: success on invalid input. |
| 4205 | continue |
| 4206 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4207 | # Passes both tests. |
| 4208 | ac_preproc_ok=: |
| 4209 | break |
| 4210 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4211 | rm -f conftest.err conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4212 | |
| 4213 | done |
| 4214 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4215 | rm -f conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4216 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4217 | break |
| 4218 | fi |
| 4219 | |
| 4220 | done |
| 4221 | ac_cv_prog_CPP=$CPP |
| 4222 | |
| 4223 | fi |
| 4224 | CPP=$ac_cv_prog_CPP |
| 4225 | else |
| 4226 | ac_cv_prog_CPP=$CPP |
| 4227 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4228 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4229 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4230 | ac_preproc_ok=false |
| 4231 | for ac_c_preproc_warn_flag in '' yes |
| 4232 | do |
| 4233 | # Use a header file that comes with gcc, so configuring glibc |
| 4234 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4235 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4236 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4237 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4238 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4239 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4240 | /* end confdefs.h. */ |
| 4241 | #ifdef __STDC__ |
| 4242 | # include <limits.h> |
| 4243 | #else |
| 4244 | # include <assert.h> |
| 4245 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4246 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4247 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4248 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4249 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4250 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4251 | # Broken: fails on valid input. |
| 4252 | continue |
| 4253 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4254 | rm -f conftest.err conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4255 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4256 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4257 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4258 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4259 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4260 | #include <ac_nonexistent.h> |
| 4261 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4262 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4263 | # Broken: success on invalid input. |
| 4264 | continue |
| 4265 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4266 | # Passes both tests. |
| 4267 | ac_preproc_ok=: |
| 4268 | break |
| 4269 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4270 | rm -f conftest.err conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4271 | |
| 4272 | done |
| 4273 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4274 | rm -f conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4275 | if $ac_preproc_ok; then : |
| 4276 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4277 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4278 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4279 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4280 | as_fn_error "C preprocessor \"$CPP\" fails sanity check |
| 4281 | See \`config.log' for more details." "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4282 | fi |
| 4283 | |
| 4284 | ac_ext=c |
| 4285 | ac_cpp='$CPP $CPPFLAGS' |
| 4286 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4287 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4288 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 4289 | |
| 4290 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4291 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 4292 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
| 4293 | if test "${ac_cv_path_GREP+set}" = set; then : |
| 4294 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4295 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4296 | if test -z "$GREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4297 | ac_path_GREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4298 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4299 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4300 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4301 | do |
| 4302 | IFS=$as_save_IFS |
| 4303 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4304 | for ac_prog in grep ggrep; do |
| 4305 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4306 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4307 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue |
| 4308 | # Check for GNU ac_path_GREP and select it if it is found. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4309 | # Check for GNU $ac_path_GREP |
| 4310 | case `"$ac_path_GREP" --version 2>&1` in |
| 4311 | *GNU*) |
| 4312 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 4313 | *) |
| 4314 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4315 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4316 | while : |
| 4317 | do |
| 4318 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4319 | mv "conftest.tmp" "conftest.in" |
| 4320 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4321 | $as_echo 'GREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4322 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4323 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4324 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4325 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 4326 | # Best one so far, save it but keep looking for a better one |
| 4327 | ac_cv_path_GREP="$ac_path_GREP" |
| 4328 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4329 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4330 | # 10*(2^10) chars as input seems more than enough |
| 4331 | test $ac_count -gt 10 && break |
| 4332 | done |
| 4333 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4334 | esac |
| 4335 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4336 | $ac_path_GREP_found && break 3 |
| 4337 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4338 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4339 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4340 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4341 | if test -z "$ac_cv_path_GREP"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4342 | as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4343 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4344 | else |
| 4345 | ac_cv_path_GREP=$GREP |
| 4346 | fi |
| 4347 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4348 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 4350 | $as_echo "$ac_cv_path_GREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4351 | GREP="$ac_cv_path_GREP" |
| 4352 | |
| 4353 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4354 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 4355 | $as_echo_n "checking for egrep... " >&6; } |
| 4356 | if test "${ac_cv_path_EGREP+set}" = set; then : |
| 4357 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4358 | else |
| 4359 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 4360 | then ac_cv_path_EGREP="$GREP -E" |
| 4361 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4362 | if test -z "$EGREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4363 | ac_path_EGREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4364 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4365 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4366 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4367 | do |
| 4368 | IFS=$as_save_IFS |
| 4369 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4370 | for ac_prog in egrep; do |
| 4371 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4372 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4373 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
| 4374 | # Check for GNU ac_path_EGREP and select it if it is found. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4375 | # Check for GNU $ac_path_EGREP |
| 4376 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4377 | *GNU*) |
| 4378 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4379 | *) |
| 4380 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4381 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4382 | while : |
| 4383 | do |
| 4384 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4385 | mv "conftest.tmp" "conftest.in" |
| 4386 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4387 | $as_echo 'EGREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4388 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4389 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4390 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4391 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4392 | # Best one so far, save it but keep looking for a better one |
| 4393 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4394 | ac_path_EGREP_max=$ac_count |
| 4395 | fi |
| 4396 | # 10*(2^10) chars as input seems more than enough |
| 4397 | test $ac_count -gt 10 && break |
| 4398 | done |
| 4399 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4400 | esac |
| 4401 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4402 | $ac_path_EGREP_found && break 3 |
| 4403 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4404 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4405 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4406 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4407 | if test -z "$ac_cv_path_EGREP"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4408 | as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4409 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4410 | else |
| 4411 | ac_cv_path_EGREP=$EGREP |
| 4412 | fi |
| 4413 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4414 | fi |
| 4415 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4416 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4417 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4418 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4419 | |
| 4420 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4422 | $as_echo_n "checking for ANSI C header files... " >&6; } |
| 4423 | if test "${ac_cv_header_stdc+set}" = set; then : |
| 4424 | $as_echo_n "(cached) " >&6 |
| 4425 | else |
| 4426 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4427 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4428 | #include <stdlib.h> |
| 4429 | #include <stdarg.h> |
| 4430 | #include <string.h> |
| 4431 | #include <float.h> |
| 4432 | |
| 4433 | int |
| 4434 | main () |
| 4435 | { |
| 4436 | |
| 4437 | ; |
| 4438 | return 0; |
| 4439 | } |
| 4440 | _ACEOF |
| 4441 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4442 | ac_cv_header_stdc=yes |
| 4443 | else |
| 4444 | ac_cv_header_stdc=no |
| 4445 | fi |
| 4446 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4447 | |
| 4448 | if test $ac_cv_header_stdc = yes; then |
| 4449 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4450 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4451 | /* end confdefs.h. */ |
| 4452 | #include <string.h> |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4453 | |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4454 | _ACEOF |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4455 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4456 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4457 | |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4458 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4459 | ac_cv_header_stdc=no |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4460 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 4461 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4462 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4463 | fi |
| 4464 | |
| 4465 | if test $ac_cv_header_stdc = yes; then |
| 4466 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4467 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4468 | /* end confdefs.h. */ |
| 4469 | #include <stdlib.h> |
| 4470 | |
| 4471 | _ACEOF |
| 4472 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4473 | $EGREP "free" >/dev/null 2>&1; then : |
| 4474 | |
| 4475 | else |
| 4476 | ac_cv_header_stdc=no |
| 4477 | fi |
| 4478 | rm -f conftest* |
| 4479 | |
| 4480 | fi |
| 4481 | |
| 4482 | if test $ac_cv_header_stdc = yes; then |
| 4483 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4484 | if test "$cross_compiling" = yes; then : |
| 4485 | : |
| 4486 | else |
| 4487 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4488 | /* end confdefs.h. */ |
| 4489 | #include <ctype.h> |
| 4490 | #include <stdlib.h> |
| 4491 | #if ((' ' & 0x0FF) == 0x020) |
| 4492 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4493 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4494 | #else |
| 4495 | # define ISLOWER(c) \ |
| 4496 | (('a' <= (c) && (c) <= 'i') \ |
| 4497 | || ('j' <= (c) && (c) <= 'r') \ |
| 4498 | || ('s' <= (c) && (c) <= 'z')) |
| 4499 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4500 | #endif |
| 4501 | |
| 4502 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4503 | int |
| 4504 | main () |
| 4505 | { |
| 4506 | int i; |
| 4507 | for (i = 0; i < 256; i++) |
| 4508 | if (XOR (islower (i), ISLOWER (i)) |
| 4509 | || toupper (i) != TOUPPER (i)) |
| 4510 | return 2; |
| 4511 | return 0; |
| 4512 | } |
| 4513 | _ACEOF |
| 4514 | if ac_fn_c_try_run "$LINENO"; then : |
| 4515 | |
| 4516 | else |
| 4517 | ac_cv_header_stdc=no |
| 4518 | fi |
| 4519 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4520 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 4521 | fi |
| 4522 | |
| 4523 | fi |
| 4524 | fi |
| 4525 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4526 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 4527 | if test $ac_cv_header_stdc = yes; then |
| 4528 | |
| 4529 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 4530 | |
| 4531 | fi |
| 4532 | |
| 4533 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 4534 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4535 | inttypes.h stdint.h unistd.h |
| 4536 | do : |
| 4537 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4538 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4539 | " |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4540 | eval as_val=\$$as_ac_Header |
| 4541 | if test "x$as_val" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4542 | cat >>confdefs.h <<_ACEOF |
| 4543 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4544 | _ACEOF |
| 4545 | |
| 4546 | fi |
| 4547 | |
| 4548 | done |
| 4549 | |
| 4550 | |
| 4551 | |
| 4552 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
| 4553 | if test "x$ac_cv_header_minix_config_h" = x""yes; then : |
| 4554 | MINIX=yes |
| 4555 | else |
| 4556 | MINIX= |
| 4557 | fi |
| 4558 | |
| 4559 | |
| 4560 | if test "$MINIX" = yes; then |
| 4561 | |
| 4562 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 4563 | |
| 4564 | |
| 4565 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 4566 | |
| 4567 | |
| 4568 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 4569 | |
| 4570 | fi |
| 4571 | |
| 4572 | |
| 4573 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 4574 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
| 4575 | if test "${ac_cv_safe_to_define___extensions__+set}" = set; then : |
| 4576 | $as_echo_n "(cached) " >&6 |
| 4577 | else |
| 4578 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4579 | /* end confdefs.h. */ |
| 4580 | |
| 4581 | # define __EXTENSIONS__ 1 |
| 4582 | $ac_includes_default |
| 4583 | int |
| 4584 | main () |
| 4585 | { |
| 4586 | |
| 4587 | ; |
| 4588 | return 0; |
| 4589 | } |
| 4590 | _ACEOF |
| 4591 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4592 | ac_cv_safe_to_define___extensions__=yes |
| 4593 | else |
| 4594 | ac_cv_safe_to_define___extensions__=no |
| 4595 | fi |
| 4596 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4597 | fi |
| 4598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 4599 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 4600 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 4601 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 4602 | |
| 4603 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 4604 | |
| 4605 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 4606 | |
| 4607 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 4608 | |
| 4609 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 4610 | |
| 4611 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4612 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4613 | # Check for unsupported systems |
| 4614 | case $ac_sys_system/$ac_sys_release in |
| 4615 | atheos*|Linux*/1*) |
| 4616 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 4617 | echo See README for details. |
| 4618 | exit 1;; |
| 4619 | esac |
| 4620 | |
| 4621 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4622 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 4623 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4624 | |
| 4625 | # Check whether --with-suffix was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4626 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4627 | withval=$with_suffix; |
| 4628 | case $withval in |
| 4629 | no) EXEEXT=;; |
| 4630 | yes) EXEEXT=.exe;; |
| 4631 | *) EXEEXT=$withval;; |
| 4632 | esac |
| 4633 | fi |
| 4634 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4635 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 4636 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4637 | |
| 4638 | # Test whether we're running on a non-case-sensitive system, in which |
| 4639 | # case we give a warning if no ext is given |
| 4640 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4641 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 4642 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4643 | if test ! -d CaseSensitiveTestDir; then |
| 4644 | mkdir CaseSensitiveTestDir |
| 4645 | fi |
| 4646 | |
| 4647 | if test -d casesensitivetestdir |
| 4648 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4649 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4650 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4651 | BUILDEXEEXT=.exe |
| 4652 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4653 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4654 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4655 | BUILDEXEEXT=$EXEEXT |
| 4656 | fi |
| 4657 | rmdir CaseSensitiveTestDir |
| 4658 | |
| 4659 | case $MACHDEP in |
| 4660 | bsdos*) |
| 4661 | case $CC in |
| 4662 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 4663 | esac;; |
| 4664 | esac |
| 4665 | |
| 4666 | case $ac_sys_system in |
| 4667 | hp*|HP*) |
| 4668 | case $CC in |
| 4669 | cc|*/cc) CC="$CC -Ae";; |
| 4670 | esac;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4671 | esac |
| 4672 | |
| 4673 | |
| 4674 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4675 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 4676 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4677 | if test -z "$LIBRARY" |
| 4678 | then |
| 4679 | LIBRARY='libpython$(VERSION).a' |
| 4680 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4681 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 4682 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4683 | |
| 4684 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 4685 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 4686 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 4687 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 4688 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 4689 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 4690 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 4691 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 4692 | # |
| 4693 | # RUNSHARED is used to run shared python without installed libraries |
| 4694 | # |
| 4695 | # INSTSONAME is the name of the shared library that will be use to install |
| 4696 | # on the system - some systems like version suffix, others don't |
| 4697 | |
| 4698 | |
| 4699 | |
| 4700 | |
| 4701 | |
| 4702 | |
| 4703 | LDLIBRARY="$LIBRARY" |
| 4704 | BLDLIBRARY='$(LDLIBRARY)' |
| 4705 | INSTSONAME='$(LDLIBRARY)' |
| 4706 | DLLLIBRARY='' |
| 4707 | LDLIBRARYDIR='' |
| 4708 | RUNSHARED='' |
| 4709 | |
| 4710 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 4711 | # If CXX is set, and if it is needed to link a main function that was |
| 4712 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 4713 | # python might then depend on the C++ runtime |
| 4714 | # This is altered for AIX in order to build the export list before |
| 4715 | # linking. |
| 4716 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 4718 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4719 | if test -z "$LINKCC" |
| 4720 | then |
| 4721 | LINKCC='$(PURIFY) $(MAINCC)' |
| 4722 | case $ac_sys_system in |
| 4723 | AIX*) |
| 4724 | exp_extra="\"\"" |
| 4725 | if test $ac_sys_release -ge 5 -o \ |
| 4726 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 4727 | exp_extra="." |
| 4728 | fi |
| 4729 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4730 | QNX*) |
| 4731 | # qcc must be used because the other compilers do not |
| 4732 | # support -N. |
| 4733 | LINKCC=qcc;; |
| 4734 | esac |
| 4735 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4736 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 4737 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4738 | |
| 4739 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 4740 | # make sure we default having it set to "no": this is used by |
| 4741 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 4742 | # to linker command lines, and failing to detect GNU ld simply results |
| 4743 | # in the same bahaviour as before. |
| 4744 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4745 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 4746 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4747 | ac_prog=ld |
| 4748 | if test "$GCC" = yes; then |
| 4749 | ac_prog=`$CC -print-prog-name=ld` |
| 4750 | fi |
| 4751 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 4752 | *GNU*) |
| 4753 | GNULD=yes;; |
| 4754 | *) |
| 4755 | GNULD=no;; |
| 4756 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4757 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 4758 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4759 | |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4760 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
| 4761 | $as_echo_n "checking for inline... " >&6; } |
| 4762 | if test "${ac_cv_c_inline+set}" = set; then : |
| 4763 | $as_echo_n "(cached) " >&6 |
| 4764 | else |
| 4765 | ac_cv_c_inline=no |
| 4766 | for ac_kw in inline __inline__ __inline; do |
| 4767 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4768 | /* end confdefs.h. */ |
| 4769 | #ifndef __cplusplus |
| 4770 | typedef int foo_t; |
| 4771 | static $ac_kw foo_t static_foo () {return 0; } |
| 4772 | $ac_kw foo_t foo () {return 0; } |
| 4773 | #endif |
| 4774 | |
| 4775 | _ACEOF |
| 4776 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4777 | ac_cv_c_inline=$ac_kw |
| 4778 | fi |
| 4779 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4780 | test "$ac_cv_c_inline" != no && break |
| 4781 | done |
| 4782 | |
| 4783 | fi |
| 4784 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
| 4785 | $as_echo "$ac_cv_c_inline" >&6; } |
| 4786 | |
| 4787 | case $ac_cv_c_inline in |
| 4788 | inline | yes) ;; |
| 4789 | *) |
| 4790 | case $ac_cv_c_inline in |
| 4791 | no) ac_val=;; |
| 4792 | *) ac_val=$ac_cv_c_inline;; |
| 4793 | esac |
| 4794 | cat >>confdefs.h <<_ACEOF |
| 4795 | #ifndef __cplusplus |
| 4796 | #define inline $ac_val |
| 4797 | #endif |
| 4798 | _ACEOF |
| 4799 | ;; |
| 4800 | esac |
| 4801 | |
| 4802 | if test "$ac_cv_c_inline" != no ; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4803 | |
| 4804 | $as_echo "#define USE_INLINE 1" >>confdefs.h |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4805 | |
| 4806 | |
| 4807 | fi |
| 4808 | |
| 4809 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 4811 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4812 | # Check whether --enable-shared was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4813 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4814 | enableval=$enable_shared; |
| 4815 | fi |
| 4816 | |
| 4817 | |
| 4818 | if test -z "$enable_shared" |
| 4819 | then |
| 4820 | case $ac_sys_system in |
Antoine Pitrou | 6103ab1 | 2009-10-24 20:11:21 +0000 | [diff] [blame] | 4821 | CYGWIN*) |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4822 | enable_shared="yes";; |
| 4823 | *) |
| 4824 | enable_shared="no";; |
| 4825 | esac |
| 4826 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4827 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 4828 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4829 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4830 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 4831 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4832 | # Check whether --enable-profiling was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4833 | if test "${enable_profiling+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4834 | enableval=$enable_profiling; ac_save_cc="$CC" |
| 4835 | CC="$CC -pg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4836 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4837 | ac_enable_profiling="no" |
| 4838 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4839 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4840 | /* end confdefs.h. */ |
| 4841 | int main() { return 0; } |
| 4842 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4843 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4844 | ac_enable_profiling="yes" |
| 4845 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4846 | ac_enable_profiling="no" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4847 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4848 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4849 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4850 | fi |
| 4851 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4852 | CC="$ac_save_cc" |
| 4853 | fi |
| 4854 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_profiling" >&5 |
| 4856 | $as_echo "$ac_enable_profiling" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4857 | |
| 4858 | case "$ac_enable_profiling" in |
| 4859 | "yes") |
| 4860 | BASECFLAGS="-pg $BASECFLAGS" |
| 4861 | LDFLAGS="-pg $LDFLAGS" |
| 4862 | ;; |
| 4863 | esac |
| 4864 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4865 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 4866 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4867 | |
| 4868 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 4869 | # library that we build, but we do not want to link against it (we |
| 4870 | # will find it with a -framework option). For this reason there is an |
| 4871 | # extra variable BLDLIBRARY against which Python and the extension |
| 4872 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 4873 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 4874 | if test "$enable_framework" |
| 4875 | then |
| 4876 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 4877 | RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH" |
| 4878 | BLDLIBRARY='' |
| 4879 | else |
| 4880 | BLDLIBRARY='$(LDLIBRARY)' |
| 4881 | fi |
| 4882 | |
| 4883 | # Other platforms follow |
| 4884 | if test $enable_shared = "yes"; then |
| 4885 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4886 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4887 | |
| 4888 | case $ac_sys_system in |
| 4889 | CYGWIN*) |
| 4890 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4891 | DLLLIBRARY='libpython$(VERSION).dll' |
| 4892 | ;; |
| 4893 | SunOS*) |
| 4894 | LDLIBRARY='libpython$(VERSION).so' |
| 4895 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4896 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4897 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4898 | ;; |
| 4899 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*) |
| 4900 | LDLIBRARY='libpython$(VERSION).so' |
| 4901 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4902 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4903 | case $ac_sys_system in |
| 4904 | FreeBSD*) |
| 4905 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 4906 | ;; |
| 4907 | esac |
| 4908 | INSTSONAME="$LDLIBRARY".$SOVERSION |
| 4909 | ;; |
| 4910 | hp*|HP*) |
| 4911 | case `uname -m` in |
| 4912 | ia64) |
| 4913 | LDLIBRARY='libpython$(VERSION).so' |
| 4914 | ;; |
| 4915 | *) |
| 4916 | LDLIBRARY='libpython$(VERSION).sl' |
| 4917 | ;; |
| 4918 | esac |
| 4919 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)' |
| 4920 | RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH} |
| 4921 | ;; |
| 4922 | OSF*) |
| 4923 | LDLIBRARY='libpython$(VERSION).so' |
| 4924 | BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)' |
| 4925 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4926 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4927 | Darwin*) |
| 4928 | LDLIBRARY='libpython$(VERSION).dylib' |
| 4929 | BLDLIBRARY='-L. -lpython$(VERSION)' |
| 4930 | RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}' |
| 4931 | ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 4932 | AIX*) |
| 4933 | LDLIBRARY='libpython$(VERSION).so' |
| 4934 | RUNSHARED=LIBPATH=`pwd`:${LIBPATH} |
| 4935 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4936 | |
| 4937 | esac |
| 4938 | else # shared is disabled |
| 4939 | case $ac_sys_system in |
| 4940 | CYGWIN*) |
| 4941 | BLDLIBRARY='$(LIBRARY)' |
| 4942 | LDLIBRARY='libpython$(VERSION).dll.a' |
| 4943 | ;; |
| 4944 | esac |
| 4945 | fi |
| 4946 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 4948 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4949 | |
| 4950 | if test -n "$ac_tool_prefix"; then |
| 4951 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 4952 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4953 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4954 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4955 | if test "${ac_cv_prog_RANLIB+set}" = set; then : |
| 4956 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4957 | else |
| 4958 | if test -n "$RANLIB"; then |
| 4959 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 4960 | else |
| 4961 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4962 | for as_dir in $PATH |
| 4963 | do |
| 4964 | IFS=$as_save_IFS |
| 4965 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4966 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4967 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 4968 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4969 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4970 | break 2 |
| 4971 | fi |
| 4972 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4973 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4974 | IFS=$as_save_IFS |
| 4975 | |
| 4976 | fi |
| 4977 | fi |
| 4978 | RANLIB=$ac_cv_prog_RANLIB |
| 4979 | if test -n "$RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4980 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 4981 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4984 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4985 | fi |
| 4986 | |
| 4987 | |
| 4988 | fi |
| 4989 | if test -z "$ac_cv_prog_RANLIB"; then |
| 4990 | ac_ct_RANLIB=$RANLIB |
| 4991 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 4992 | set dummy ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4993 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4994 | $as_echo_n "checking for $ac_word... " >&6; } |
| 4995 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : |
| 4996 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4997 | else |
| 4998 | if test -n "$ac_ct_RANLIB"; then |
| 4999 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5000 | else |
| 5001 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5002 | for as_dir in $PATH |
| 5003 | do |
| 5004 | IFS=$as_save_IFS |
| 5005 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5006 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5007 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5008 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5009 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5010 | break 2 |
| 5011 | fi |
| 5012 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5013 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5014 | IFS=$as_save_IFS |
| 5015 | |
| 5016 | fi |
| 5017 | fi |
| 5018 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5019 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5020 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5021 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5022 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5023 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5024 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5025 | fi |
| 5026 | |
| 5027 | if test "x$ac_ct_RANLIB" = x; then |
| 5028 | RANLIB=":" |
| 5029 | else |
| 5030 | case $cross_compiling:$ac_tool_warned in |
| 5031 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5032 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5033 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5034 | ac_tool_warned=yes ;; |
| 5035 | esac |
| 5036 | RANLIB=$ac_ct_RANLIB |
| 5037 | fi |
| 5038 | else |
| 5039 | RANLIB="$ac_cv_prog_RANLIB" |
| 5040 | fi |
| 5041 | |
| 5042 | |
| 5043 | for ac_prog in ar aal |
| 5044 | do |
| 5045 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5046 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5047 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5048 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5049 | if test "${ac_cv_prog_AR+set}" = set; then : |
| 5050 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5051 | else |
| 5052 | if test -n "$AR"; then |
| 5053 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5054 | else |
| 5055 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5056 | for as_dir in $PATH |
| 5057 | do |
| 5058 | IFS=$as_save_IFS |
| 5059 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5060 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5061 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5062 | ac_cv_prog_AR="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5063 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5064 | break 2 |
| 5065 | fi |
| 5066 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5067 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5068 | IFS=$as_save_IFS |
| 5069 | |
| 5070 | fi |
| 5071 | fi |
| 5072 | AR=$ac_cv_prog_AR |
| 5073 | if test -n "$AR"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5074 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5075 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5076 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5078 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5079 | fi |
| 5080 | |
| 5081 | |
| 5082 | test -n "$AR" && break |
| 5083 | done |
| 5084 | test -n "$AR" || AR="ar" |
| 5085 | |
| 5086 | |
| 5087 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5088 | |
| 5089 | if test -z "$ARFLAGS" |
| 5090 | then |
| 5091 | ARFLAGS="rc" |
| 5092 | fi |
| 5093 | |
| 5094 | |
| 5095 | # Extract the first word of "svnversion", so it can be a program name with args. |
| 5096 | set dummy svnversion; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5097 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5098 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5099 | if test "${ac_cv_prog_SVNVERSION+set}" = set; then : |
| 5100 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5101 | else |
| 5102 | if test -n "$SVNVERSION"; then |
| 5103 | ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test. |
| 5104 | else |
| 5105 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5106 | for as_dir in $PATH |
| 5107 | do |
| 5108 | IFS=$as_save_IFS |
| 5109 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5110 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5111 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5112 | ac_cv_prog_SVNVERSION="found" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5113 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5114 | break 2 |
| 5115 | fi |
| 5116 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5117 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5118 | IFS=$as_save_IFS |
| 5119 | |
| 5120 | test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found" |
| 5121 | fi |
| 5122 | fi |
| 5123 | SVNVERSION=$ac_cv_prog_SVNVERSION |
| 5124 | if test -n "$SVNVERSION"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5125 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SVNVERSION" >&5 |
| 5126 | $as_echo "$SVNVERSION" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5127 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5128 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5129 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5130 | fi |
| 5131 | |
| 5132 | |
| 5133 | if test $SVNVERSION = found |
| 5134 | then |
| 5135 | SVNVERSION="svnversion \$(srcdir)" |
| 5136 | else |
| 5137 | SVNVERSION="echo Unversioned directory" |
| 5138 | fi |
| 5139 | |
| 5140 | case $MACHDEP in |
| 5141 | bsdos*|hp*|HP*) |
| 5142 | # install -d does not work on BSDI or HP-UX |
| 5143 | if test -z "$INSTALL" |
| 5144 | then |
| 5145 | INSTALL="${srcdir}/install-sh -c" |
| 5146 | fi |
| 5147 | esac |
| 5148 | ac_aux_dir= |
| 5149 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 5150 | for ac_t in install-sh install.sh shtool; do |
| 5151 | if test -f "$ac_dir/$ac_t"; then |
| 5152 | ac_aux_dir=$ac_dir |
| 5153 | ac_install_sh="$ac_aux_dir/$ac_t -c" |
| 5154 | break 2 |
| 5155 | fi |
| 5156 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5157 | done |
| 5158 | if test -z "$ac_aux_dir"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 5159 | as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5160 | fi |
| 5161 | |
| 5162 | # These three variables are undocumented and unsupported, |
| 5163 | # and are intended to be withdrawn in a future Autoconf release. |
| 5164 | # They can cause serious problems if a builder's source tree is in a directory |
| 5165 | # whose full name contains unusual characters. |
| 5166 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 5167 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 5168 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 5169 | |
| 5170 | |
| 5171 | # Find a good install program. We prefer a C program (faster), |
| 5172 | # so one script is as good as another. But avoid the broken or |
| 5173 | # incompatible versions: |
| 5174 | # SysV /etc/install, /usr/sbin/install |
| 5175 | # SunOS /usr/etc/install |
| 5176 | # IRIX /sbin/install |
| 5177 | # AIX /bin/install |
| 5178 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 5179 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 5180 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 5181 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 5182 | # OS/2's system install, which has a completely different semantic |
| 5183 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5184 | # Reject install programs that cannot install multiple files. |
| 5185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 5186 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5187 | if test -z "$INSTALL"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5188 | if test "${ac_cv_path_install+set}" = set; then : |
| 5189 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5190 | else |
| 5191 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5192 | for as_dir in $PATH |
| 5193 | do |
| 5194 | IFS=$as_save_IFS |
| 5195 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5196 | # Account for people who put trailing slashes in PATH elements. |
| 5197 | case $as_dir/ in #(( |
| 5198 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5199 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5200 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5201 | /usr/ucb/* ) ;; |
| 5202 | *) |
| 5203 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 5204 | # Don't use installbsd from OSF since it installs stuff as root |
| 5205 | # by default. |
| 5206 | for ac_prog in ginstall scoinst install; do |
| 5207 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5208 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
| 5209 | if test $ac_prog = install && |
| 5210 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5211 | # AIX install. It has an incompatible calling convention. |
| 5212 | : |
| 5213 | elif test $ac_prog = install && |
| 5214 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5215 | # program-specific install script used by HP pwplus--don't use. |
| 5216 | : |
| 5217 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5218 | rm -rf conftest.one conftest.two conftest.dir |
| 5219 | echo one > conftest.one |
| 5220 | echo two > conftest.two |
| 5221 | mkdir conftest.dir |
| 5222 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 5223 | test -s conftest.one && test -s conftest.two && |
| 5224 | test -s conftest.dir/conftest.one && |
| 5225 | test -s conftest.dir/conftest.two |
| 5226 | then |
| 5227 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 5228 | break 3 |
| 5229 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5230 | fi |
| 5231 | fi |
| 5232 | done |
| 5233 | done |
| 5234 | ;; |
| 5235 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5236 | |
| 5237 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5238 | IFS=$as_save_IFS |
| 5239 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5240 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5241 | |
| 5242 | fi |
| 5243 | if test "${ac_cv_path_install+set}" = set; then |
| 5244 | INSTALL=$ac_cv_path_install |
| 5245 | else |
| 5246 | # As a last resort, use the slow shell script. Don't cache a |
| 5247 | # value for INSTALL within a source directory, because that will |
| 5248 | # break other packages using the cache if that directory is |
| 5249 | # removed, or if the value is a relative name. |
| 5250 | INSTALL=$ac_install_sh |
| 5251 | fi |
| 5252 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 5254 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5255 | |
| 5256 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 5257 | # It thinks the first close brace ends the variable substitution. |
| 5258 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 5259 | |
| 5260 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 5261 | |
| 5262 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 5263 | |
| 5264 | |
| 5265 | # Not every filesystem supports hard links |
| 5266 | |
| 5267 | if test -z "$LN" ; then |
| 5268 | case $ac_sys_system in |
| 5269 | CYGWIN*) LN="ln -s";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5270 | *) LN=ln;; |
| 5271 | esac |
| 5272 | fi |
| 5273 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5274 | # For calculating the .so ABI tag. |
| 5275 | SOABI_QUALIFIERS="" |
| 5276 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5277 | # Check for --with-pydebug |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5278 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 5279 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5280 | |
| 5281 | # Check whether --with-pydebug was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5282 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5283 | withval=$with_pydebug; |
| 5284 | if test "$withval" != no |
| 5285 | then |
| 5286 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5287 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5288 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5290 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5291 | Py_DEBUG='true' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5292 | SOABI_QUALIFIERS="${SOABI_QUALIFIERS}d" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5293 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5294 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5295 | fi |
| 5296 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5298 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5299 | fi |
| 5300 | |
| 5301 | |
| 5302 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 5303 | # merged with this chunk of code? |
| 5304 | |
| 5305 | # Optimizer/debugger flags |
| 5306 | # ------------------------ |
| 5307 | # (The following bit of code is complicated enough - please keep things |
| 5308 | # indented properly. Just pretend you're editing Python code. ;-) |
| 5309 | |
| 5310 | # There are two parallel sets of case statements below, one that checks to |
| 5311 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 5312 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 5313 | # user set OPT. |
| 5314 | |
| 5315 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 5316 | # it on the command line |
| 5317 | |
Benjamin Peterson | 65b4ec5 | 2010-03-23 21:02:34 +0000 | [diff] [blame] | 5318 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5319 | then |
| 5320 | case $GCC in |
| 5321 | yes) |
| 5322 | if test "$CC" != 'g++' ; then |
| 5323 | STRICT_PROTO="-Wstrict-prototypes" |
| 5324 | fi |
| 5325 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 5326 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 5327 | WRAP="-fwrapv" |
| 5328 | fi |
| 5329 | case $ac_cv_prog_cc_g in |
| 5330 | yes) |
| 5331 | if test "$Py_DEBUG" = 'true' ; then |
| 5332 | # Optimization messes up debuggers, so turn it off for |
| 5333 | # debug builds. |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 5334 | OPT="-g -O0 -Wall $STRICT_PROTO" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5335 | else |
| 5336 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 5337 | fi |
| 5338 | ;; |
| 5339 | *) |
| 5340 | OPT="-O3 -Wall $STRICT_PROTO" |
| 5341 | ;; |
| 5342 | esac |
| 5343 | case $ac_sys_system in |
| 5344 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 5345 | ;; |
| 5346 | esac |
| 5347 | ;; |
| 5348 | |
| 5349 | *) |
| 5350 | OPT="-O" |
| 5351 | ;; |
| 5352 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5353 | fi |
| 5354 | |
| 5355 | |
| 5356 | |
| 5357 | # The -arch flags for universal builds on OSX |
| 5358 | UNIVERSAL_ARCH_FLAGS= |
| 5359 | |
| 5360 | |
| 5361 | # tweak BASECFLAGS based on compiler and platform |
| 5362 | case $GCC in |
| 5363 | yes) |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5364 | # Python doesn't violate C99 aliasing rules, but older versions of |
| 5365 | # GCC produce warnings for legal Python code. Enable |
| 5366 | # -fno-strict-aliasing on versions of GCC that support but produce |
| 5367 | # warnings. See Issue3326 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5368 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5 |
| 5369 | $as_echo_n "checking whether $CC accepts and needs -fno-strict-aliasing... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5370 | ac_save_cc="$CC" |
| 5371 | CC="$CC -fno-strict-aliasing" |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5372 | save_CFLAGS="$CFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5373 | if test "${ac_cv_no_strict_aliasing+set}" = set; then : |
| 5374 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5375 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5376 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5377 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5378 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5379 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5380 | int |
| 5381 | main () |
| 5382 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5383 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5384 | ; |
| 5385 | return 0; |
| 5386 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5387 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5388 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5389 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5390 | |
| 5391 | CC="$ac_save_cc -fstrict-aliasing" |
| 5392 | CFLAGS="$CFLAGS -Werror -Wstrict-aliasing" |
| 5393 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5394 | /* end confdefs.h. */ |
| 5395 | |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5396 | void f(int **x) {} |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5397 | int |
| 5398 | main () |
| 5399 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5400 | double *x; f((int **) &x); |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5401 | ; |
| 5402 | return 0; |
| 5403 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5404 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5405 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5406 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5407 | |
| 5408 | ac_cv_no_strict_aliasing=no |
| 5409 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5410 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5411 | |
| 5412 | ac_cv_no_strict_aliasing=yes |
| 5413 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5414 | fi |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5415 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5416 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5417 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5418 | |
| 5419 | ac_cv_no_strict_aliasing=no |
| 5420 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5421 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5422 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5423 | fi |
| 5424 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5425 | CFLAGS="$save_CFLAGS" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5426 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5 |
| 5428 | $as_echo "$ac_cv_no_strict_aliasing" >&6; } |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5429 | if test $ac_cv_no_strict_aliasing = yes |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 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 | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5451 | if test "${CC}" = gcc |
| 5452 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +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 | 666028b | 2010-04-18 19:07:43 +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 | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 5465 | $as_echo "$CC" >&6; } |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5466 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5467 | |
| 5468 | |
| 5469 | if test "${enable_universalsdk}"; then |
| 5470 | UNIVERSAL_ARCH_FLAGS="" |
| 5471 | if test "$UNIVERSAL_ARCHS" = "32-bit" ; then |
| 5472 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 5473 | ARCH_RUN_32BIT="" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 5474 | LIPO_32BIT_FLAGS="" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5475 | elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then |
| 5476 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5477 | LIPO_32BIT_FLAGS="" |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5478 | ARCH_RUN_32BIT="true" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5479 | |
| 5480 | elif test "$UNIVERSAL_ARCHS" = "all" ; then |
| 5481 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5482 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5483 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5484 | |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5485 | elif test "$UNIVERSAL_ARCHS" = "intel" ; then |
| 5486 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5487 | LIPO_32BIT_FLAGS="-extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5488 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5489 | |
| 5490 | elif test "$UNIVERSAL_ARCHS" = "3-way" ; then |
| 5491 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5492 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5493 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5494 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5495 | else |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 5496 | as_fn_error "proper usage is --with-universal-arch=32-bit|64-bit|all|intel|3-way" "$LINENO" 5 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5497 | |
| 5498 | fi |
| 5499 | |
| 5500 | |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5501 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5502 | if test "${UNIVERSALSDK}" != "/" |
| 5503 | then |
| 5504 | CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5505 | LDFLAGS="-isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Ronald Oussoren | 712979d | 2010-04-20 19:51:33 +0000 | [diff] [blame] | 5506 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5507 | fi |
| 5508 | fi |
| 5509 | |
| 5510 | # Calculate the right deployment target for this build. |
| 5511 | # |
| 5512 | cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'` |
| 5513 | if test ${cur_target} '>' 10.2; then |
| 5514 | cur_target=10.3 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5515 | if test ${enable_universalsdk}; then |
| 5516 | if test "${UNIVERSAL_ARCHS}" = "all"; then |
| 5517 | # Ensure that the default platform for a |
| 5518 | # 4-way universal build is OSX 10.5, |
| 5519 | # that's the first OS release where |
| 5520 | # 4-way builds make sense. |
| 5521 | cur_target='10.5' |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5522 | |
| 5523 | elif test "${UNIVERSAL_ARCHS}" = "3-way"; then |
| 5524 | cur_target='10.5' |
| 5525 | |
| 5526 | elif test "${UNIVERSAL_ARCHS}" = "intel"; then |
| 5527 | cur_target='10.5' |
| 5528 | |
| 5529 | elif test "${UNIVERSAL_ARCHS}" = "64-bit"; then |
| 5530 | cur_target='10.5' |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5531 | fi |
| 5532 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 5533 | if test `/usr/bin/arch` = "i386"; then |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5534 | # On Intel macs default to a deployment |
| 5535 | # target of 10.4, that's the first OSX |
| 5536 | # release with Intel support. |
| 5537 | cur_target="10.4" |
| 5538 | fi |
| 5539 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5540 | fi |
| 5541 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
| 5542 | |
| 5543 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 5544 | # environment with a value that is the same as what we'll use |
| 5545 | # in the Makefile to ensure that we'll get the same compiler |
| 5546 | # environment during configure and build time. |
| 5547 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 5548 | export MACOSX_DEPLOYMENT_TARGET |
| 5549 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 5550 | |
| 5551 | ;; |
| 5552 | OSF*) |
| 5553 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5554 | ;; |
| 5555 | esac |
| 5556 | ;; |
| 5557 | |
| 5558 | *) |
| 5559 | case $ac_sys_system in |
| 5560 | OpenUNIX*|UnixWare*) |
| 5561 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 5562 | ;; |
| 5563 | OSF*) |
| 5564 | BASECFLAGS="$BASECFLAGS -ieee -std" |
| 5565 | ;; |
| 5566 | SCO_SV*) |
| 5567 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 5568 | ;; |
| 5569 | esac |
| 5570 | ;; |
| 5571 | esac |
| 5572 | |
| 5573 | if test "$Py_DEBUG" = 'true'; then |
| 5574 | : |
| 5575 | else |
| 5576 | OPT="-DNDEBUG $OPT" |
| 5577 | fi |
| 5578 | |
| 5579 | if test "$ac_arch_flags" |
| 5580 | then |
| 5581 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 5582 | fi |
| 5583 | |
| 5584 | # disable check for icc since it seems to pass, but generates a warning |
| 5585 | if test "$CC" = icc |
| 5586 | then |
| 5587 | ac_cv_opt_olimit_ok=no |
| 5588 | fi |
| 5589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5590 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -OPT:Olimit=0" >&5 |
| 5591 | $as_echo_n "checking whether $CC accepts -OPT:Olimit=0... " >&6; } |
| 5592 | if test "${ac_cv_opt_olimit_ok+set}" = set; then : |
| 5593 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5594 | else |
| 5595 | ac_save_cc="$CC" |
| 5596 | CC="$CC -OPT:Olimit=0" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5597 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5598 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5599 | |
| 5600 | int |
| 5601 | main () |
| 5602 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5603 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5604 | ; |
| 5605 | return 0; |
| 5606 | } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5607 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5608 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5609 | ac_cv_opt_olimit_ok=yes |
| 5610 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5611 | ac_cv_opt_olimit_ok=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5612 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5613 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5614 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5615 | CC="$ac_save_cc" |
| 5616 | fi |
| 5617 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5618 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_opt_olimit_ok" >&5 |
| 5619 | $as_echo "$ac_cv_opt_olimit_ok" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5620 | if test $ac_cv_opt_olimit_ok = yes; then |
| 5621 | case $ac_sys_system in |
| 5622 | # XXX is this branch needed? On MacOSX 10.2.2 the result of the |
| 5623 | # olimit_ok test is "no". Is it "yes" in some other Darwin-esque |
| 5624 | # environment? |
| 5625 | Darwin*) |
| 5626 | ;; |
| 5627 | *) |
| 5628 | BASECFLAGS="$BASECFLAGS -OPT:Olimit=0" |
| 5629 | ;; |
| 5630 | esac |
| 5631 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5632 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Olimit 1500" >&5 |
| 5633 | $as_echo_n "checking whether $CC accepts -Olimit 1500... " >&6; } |
| 5634 | if test "${ac_cv_olimit_ok+set}" = set; then : |
| 5635 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5636 | else |
| 5637 | ac_save_cc="$CC" |
| 5638 | CC="$CC -Olimit 1500" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5639 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5640 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5641 | |
| 5642 | int |
| 5643 | main () |
| 5644 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5645 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5646 | ; |
| 5647 | return 0; |
| 5648 | } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5649 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5650 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5651 | ac_cv_olimit_ok=yes |
| 5652 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5653 | ac_cv_olimit_ok=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5654 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5655 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5656 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5657 | CC="$ac_save_cc" |
| 5658 | fi |
| 5659 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_olimit_ok" >&5 |
| 5661 | $as_echo "$ac_cv_olimit_ok" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5662 | if test $ac_cv_olimit_ok = yes; then |
| 5663 | BASECFLAGS="$BASECFLAGS -Olimit 1500" |
| 5664 | fi |
| 5665 | fi |
| 5666 | |
| 5667 | # Check whether GCC supports PyArg_ParseTuple format |
| 5668 | if test "$GCC" = "yes" |
| 5669 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc supports ParseTuple __format__" >&5 |
| 5671 | $as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5672 | save_CFLAGS=$CFLAGS |
| 5673 | CFLAGS="$CFLAGS -Werror" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5674 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5675 | /* end confdefs.h. */ |
| 5676 | |
| 5677 | void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2))); |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5678 | int |
| 5679 | main () |
| 5680 | { |
| 5681 | |
| 5682 | ; |
| 5683 | return 0; |
| 5684 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5685 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5686 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5687 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5688 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5689 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5690 | $as_echo "#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5691 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5692 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5693 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5694 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5695 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5696 | |
| 5697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5698 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5699 | |
| 5700 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5701 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5702 | CFLAGS=$save_CFLAGS |
| 5703 | fi |
| 5704 | |
| 5705 | # On some compilers, pthreads are available without further options |
| 5706 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 5707 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 5708 | # So we have to see first whether pthreads are available without |
| 5709 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5710 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 5711 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
| 5712 | if test "${ac_cv_pthread_is_default+set}" = set; then : |
| 5713 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5714 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5715 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5716 | ac_cv_pthread_is_default=no |
| 5717 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5718 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5719 | /* end confdefs.h. */ |
| 5720 | |
| 5721 | #include <pthread.h> |
| 5722 | |
| 5723 | void* routine(void* p){return NULL;} |
| 5724 | |
| 5725 | int main(){ |
| 5726 | pthread_t p; |
| 5727 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5728 | return 1; |
| 5729 | (void)pthread_detach(p); |
| 5730 | return 0; |
| 5731 | } |
| 5732 | |
| 5733 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5734 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5735 | |
| 5736 | ac_cv_pthread_is_default=yes |
| 5737 | ac_cv_kthread=no |
| 5738 | ac_cv_pthread=no |
| 5739 | |
| 5740 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5741 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5742 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5743 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5744 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5745 | fi |
| 5746 | |
| 5747 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5748 | fi |
| 5749 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 5751 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5752 | |
| 5753 | |
| 5754 | if test $ac_cv_pthread_is_default = yes |
| 5755 | then |
| 5756 | ac_cv_kpthread=no |
| 5757 | else |
| 5758 | # -Kpthread, if available, provides the right #defines |
| 5759 | # and linker options to make pthread_create available |
| 5760 | # Some compilers won't report that they do not support -Kpthread, |
| 5761 | # so we need to run a program to see whether it really made the |
| 5762 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5763 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 5764 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
| 5765 | if test "${ac_cv_kpthread+set}" = set; then : |
| 5766 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5767 | else |
| 5768 | ac_save_cc="$CC" |
| 5769 | CC="$CC -Kpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5770 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5771 | ac_cv_kpthread=no |
| 5772 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5773 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5774 | /* end confdefs.h. */ |
| 5775 | |
| 5776 | #include <pthread.h> |
| 5777 | |
| 5778 | void* routine(void* p){return NULL;} |
| 5779 | |
| 5780 | int main(){ |
| 5781 | pthread_t p; |
| 5782 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5783 | return 1; |
| 5784 | (void)pthread_detach(p); |
| 5785 | return 0; |
| 5786 | } |
| 5787 | |
| 5788 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5789 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5790 | ac_cv_kpthread=yes |
| 5791 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5792 | ac_cv_kpthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5793 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5794 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5795 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5796 | fi |
| 5797 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5798 | CC="$ac_save_cc" |
| 5799 | fi |
| 5800 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5801 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 5802 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5803 | fi |
| 5804 | |
| 5805 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 5806 | then |
| 5807 | # -Kthread, if available, provides the right #defines |
| 5808 | # and linker options to make pthread_create available |
| 5809 | # Some compilers won't report that they do not support -Kthread, |
| 5810 | # so we need to run a program to see whether it really made the |
| 5811 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5812 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 5813 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
| 5814 | if test "${ac_cv_kthread+set}" = set; then : |
| 5815 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5816 | else |
| 5817 | ac_save_cc="$CC" |
| 5818 | CC="$CC -Kthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5819 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5820 | ac_cv_kthread=no |
| 5821 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5822 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5823 | /* end confdefs.h. */ |
| 5824 | |
| 5825 | #include <pthread.h> |
| 5826 | |
| 5827 | void* routine(void* p){return NULL;} |
| 5828 | |
| 5829 | int main(){ |
| 5830 | pthread_t p; |
| 5831 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5832 | return 1; |
| 5833 | (void)pthread_detach(p); |
| 5834 | return 0; |
| 5835 | } |
| 5836 | |
| 5837 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5838 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5839 | ac_cv_kthread=yes |
| 5840 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5841 | ac_cv_kthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5842 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5843 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5844 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5845 | fi |
| 5846 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5847 | CC="$ac_save_cc" |
| 5848 | fi |
| 5849 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 5851 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5852 | fi |
| 5853 | |
| 5854 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 5855 | then |
| 5856 | # -pthread, if available, provides the right #defines |
| 5857 | # and linker options to make pthread_create available |
| 5858 | # Some compilers won't report that they do not support -pthread, |
| 5859 | # so we need to run a program to see whether it really made the |
| 5860 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5861 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 5862 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
| 5863 | if test "${ac_cv_thread+set}" = set; then : |
| 5864 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5865 | else |
| 5866 | ac_save_cc="$CC" |
| 5867 | CC="$CC -pthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5868 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5869 | ac_cv_pthread=no |
| 5870 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5871 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5872 | /* end confdefs.h. */ |
| 5873 | |
| 5874 | #include <pthread.h> |
| 5875 | |
| 5876 | void* routine(void* p){return NULL;} |
| 5877 | |
| 5878 | int main(){ |
| 5879 | pthread_t p; |
| 5880 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5881 | return 1; |
| 5882 | (void)pthread_detach(p); |
| 5883 | return 0; |
| 5884 | } |
| 5885 | |
| 5886 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5887 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5888 | ac_cv_pthread=yes |
| 5889 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5890 | ac_cv_pthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5891 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5892 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5893 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5894 | fi |
| 5895 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5896 | CC="$ac_save_cc" |
| 5897 | fi |
| 5898 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5899 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 5900 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5901 | fi |
| 5902 | |
| 5903 | # If we have set a CC compiler flag for thread support then |
| 5904 | # check if it works for CXX, too. |
| 5905 | ac_cv_cxx_thread=no |
| 5906 | if test ! -z "$CXX" |
| 5907 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5908 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 5909 | $as_echo_n "checking whether $CXX also accepts flags for thread support... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5910 | ac_save_cxx="$CXX" |
| 5911 | |
| 5912 | if test "$ac_cv_kpthread" = "yes" |
| 5913 | then |
| 5914 | CXX="$CXX -Kpthread" |
| 5915 | ac_cv_cxx_thread=yes |
| 5916 | elif test "$ac_cv_kthread" = "yes" |
| 5917 | then |
| 5918 | CXX="$CXX -Kthread" |
| 5919 | ac_cv_cxx_thread=yes |
| 5920 | elif test "$ac_cv_pthread" = "yes" |
| 5921 | then |
| 5922 | CXX="$CXX -pthread" |
| 5923 | ac_cv_cxx_thread=yes |
| 5924 | fi |
| 5925 | |
| 5926 | if test $ac_cv_cxx_thread = yes |
| 5927 | then |
| 5928 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 5929 | $CXX -c conftest.$ac_ext 2>&5 |
| 5930 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 5931 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 5932 | then |
| 5933 | ac_cv_cxx_thread=yes |
| 5934 | else |
| 5935 | ac_cv_cxx_thread=no |
| 5936 | fi |
| 5937 | rm -fr conftest* |
| 5938 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5939 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 5940 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5941 | fi |
| 5942 | CXX="$ac_save_cxx" |
| 5943 | |
| 5944 | |
| 5945 | # checks for header files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5946 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5947 | $as_echo_n "checking for ANSI C header files... " >&6; } |
| 5948 | if test "${ac_cv_header_stdc+set}" = set; then : |
| 5949 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5950 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5951 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5952 | /* end confdefs.h. */ |
| 5953 | #include <stdlib.h> |
| 5954 | #include <stdarg.h> |
| 5955 | #include <string.h> |
| 5956 | #include <float.h> |
| 5957 | |
| 5958 | int |
| 5959 | main () |
| 5960 | { |
| 5961 | |
| 5962 | ; |
| 5963 | return 0; |
| 5964 | } |
| 5965 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5966 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5967 | ac_cv_header_stdc=yes |
| 5968 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5969 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5970 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5971 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5972 | |
| 5973 | if test $ac_cv_header_stdc = yes; then |
| 5974 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5975 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5976 | /* end confdefs.h. */ |
| 5977 | #include <string.h> |
| 5978 | |
| 5979 | _ACEOF |
| 5980 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5981 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 5982 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5983 | else |
| 5984 | ac_cv_header_stdc=no |
| 5985 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 5986 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5987 | |
| 5988 | fi |
| 5989 | |
| 5990 | if test $ac_cv_header_stdc = yes; then |
| 5991 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5992 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5993 | /* end confdefs.h. */ |
| 5994 | #include <stdlib.h> |
| 5995 | |
| 5996 | _ACEOF |
| 5997 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5998 | $EGREP "free" >/dev/null 2>&1; then : |
| 5999 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6000 | else |
| 6001 | ac_cv_header_stdc=no |
| 6002 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6003 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6004 | |
| 6005 | fi |
| 6006 | |
| 6007 | if test $ac_cv_header_stdc = yes; then |
| 6008 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6009 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6010 | : |
| 6011 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6013 | /* end confdefs.h. */ |
| 6014 | #include <ctype.h> |
| 6015 | #include <stdlib.h> |
| 6016 | #if ((' ' & 0x0FF) == 0x020) |
| 6017 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 6018 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 6019 | #else |
| 6020 | # define ISLOWER(c) \ |
| 6021 | (('a' <= (c) && (c) <= 'i') \ |
| 6022 | || ('j' <= (c) && (c) <= 'r') \ |
| 6023 | || ('s' <= (c) && (c) <= 'z')) |
| 6024 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 6025 | #endif |
| 6026 | |
| 6027 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 6028 | int |
| 6029 | main () |
| 6030 | { |
| 6031 | int i; |
| 6032 | for (i = 0; i < 256; i++) |
| 6033 | if (XOR (islower (i), ISLOWER (i)) |
| 6034 | || toupper (i) != TOUPPER (i)) |
| 6035 | return 2; |
| 6036 | return 0; |
| 6037 | } |
| 6038 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6039 | if ac_fn_c_try_run "$LINENO"; then : |
| 6040 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6041 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6042 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6043 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6044 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6045 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6046 | fi |
| 6047 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6048 | fi |
| 6049 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6050 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 6051 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6052 | if test $ac_cv_header_stdc = yes; then |
| 6053 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6054 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6055 | |
| 6056 | fi |
| 6057 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6058 | for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ |
| 6059 | fcntl.h grp.h \ |
Christian Heimes | bbe741d | 2008-03-28 10:53:29 +0000 | [diff] [blame] | 6060 | ieeefp.h io.h langinfo.h libintl.h ncurses.h poll.h process.h pthread.h \ |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 6061 | 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] | 6062 | unistd.h utime.h \ |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 6063 | sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \ |
| 6064 | sys/lock.h sys/mkdev.h sys/modem.h \ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6065 | sys/param.h sys/poll.h sys/select.h sys/socket.h sys/statvfs.h sys/stat.h \ |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 6066 | sys/termio.h sys/time.h \ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6067 | sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
Hye-Shik Chang | 8126860 | 2004-02-02 06:05:24 +0000 | [diff] [blame] | 6068 | sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Ronald Oussoren | 755740f | 2010-02-07 19:56:39 +0000 | [diff] [blame] | 6069 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6070 | do : |
| 6071 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6072 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6073 | eval as_val=\$$as_ac_Header |
| 6074 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6075 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6076 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6077 | _ACEOF |
| 6078 | |
| 6079 | fi |
| 6080 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6081 | done |
| 6082 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6083 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6084 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6085 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 6086 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 6087 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6088 | if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6089 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6090 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6091 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6092 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6093 | #include <sys/types.h> |
| 6094 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6095 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6096 | int |
| 6097 | main () |
| 6098 | { |
| 6099 | if ((DIR *) 0) |
| 6100 | return 0; |
| 6101 | ; |
| 6102 | return 0; |
| 6103 | } |
| 6104 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6105 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6106 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6107 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6108 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6109 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6110 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6111 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6112 | eval ac_res=\$$as_ac_Header |
| 6113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 6114 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6115 | eval as_val=\$$as_ac_Header |
| 6116 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6117 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6118 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6119 | _ACEOF |
| 6120 | |
| 6121 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6122 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6123 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6124 | done |
| 6125 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 6126 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6127 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6128 | $as_echo_n "checking for library containing opendir... " >&6; } |
| 6129 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6130 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6131 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6132 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6133 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6134 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6135 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6136 | /* Override any GCC internal prototype to avoid an error. |
| 6137 | Use char because int might match the return type of a GCC |
| 6138 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6139 | #ifdef __cplusplus |
| 6140 | extern "C" |
| 6141 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6142 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6143 | int |
| 6144 | main () |
| 6145 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6146 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6147 | ; |
| 6148 | return 0; |
| 6149 | } |
| 6150 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6151 | for ac_lib in '' dir; do |
| 6152 | if test -z "$ac_lib"; then |
| 6153 | ac_res="none required" |
| 6154 | else |
| 6155 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6156 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6157 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6158 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6159 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6160 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6161 | rm -f core conftest.err conftest.$ac_objext \ |
| 6162 | conftest$ac_exeext |
| 6163 | if test "${ac_cv_search_opendir+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6164 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6165 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6166 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6167 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6168 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6169 | else |
| 6170 | ac_cv_search_opendir=no |
| 6171 | fi |
| 6172 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6173 | LIBS=$ac_func_search_save_LIBS |
| 6174 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6175 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6176 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6177 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6178 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6179 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6180 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6181 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6182 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6183 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6184 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6185 | $as_echo_n "checking for library containing opendir... " >&6; } |
| 6186 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6187 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6188 | else |
| 6189 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6190 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6191 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6192 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6193 | /* Override any GCC internal prototype to avoid an error. |
| 6194 | Use char because int might match the return type of a GCC |
| 6195 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6196 | #ifdef __cplusplus |
| 6197 | extern "C" |
| 6198 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6199 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6200 | int |
| 6201 | main () |
| 6202 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6203 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6204 | ; |
| 6205 | return 0; |
| 6206 | } |
| 6207 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6208 | for ac_lib in '' x; do |
| 6209 | if test -z "$ac_lib"; then |
| 6210 | ac_res="none required" |
| 6211 | else |
| 6212 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6213 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6214 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6215 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6216 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6217 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6218 | rm -f core conftest.err conftest.$ac_objext \ |
| 6219 | conftest$ac_exeext |
| 6220 | if test "${ac_cv_search_opendir+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6221 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6222 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6223 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6224 | if test "${ac_cv_search_opendir+set}" = set; then : |
| 6225 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6226 | else |
| 6227 | ac_cv_search_opendir=no |
| 6228 | fi |
| 6229 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6230 | LIBS=$ac_func_search_save_LIBS |
| 6231 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6233 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6234 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6235 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6236 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6237 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6238 | fi |
| 6239 | |
| 6240 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6241 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 6243 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
| 6244 | if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then : |
| 6245 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6246 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6247 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6248 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6249 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6250 | int |
| 6251 | main () |
| 6252 | { |
| 6253 | return makedev(0, 0); |
| 6254 | ; |
| 6255 | return 0; |
| 6256 | } |
| 6257 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6258 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6259 | ac_cv_header_sys_types_h_makedev=yes |
| 6260 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6261 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6262 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6263 | rm -f core conftest.err conftest.$ac_objext \ |
| 6264 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6265 | |
| 6266 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6267 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 6268 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6269 | |
| 6270 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6271 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
| 6272 | if test "x$ac_cv_header_sys_mkdev_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6273 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6274 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6275 | |
| 6276 | fi |
| 6277 | |
| 6278 | |
| 6279 | |
| 6280 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6281 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
| 6282 | if test "x$ac_cv_header_sys_sysmacros_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6283 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6284 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6285 | |
| 6286 | fi |
| 6287 | |
| 6288 | |
| 6289 | fi |
| 6290 | fi |
| 6291 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6292 | |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6293 | # On Solaris, term.h requires curses.h |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6294 | for ac_header in term.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6295 | do : |
| 6296 | 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] | 6297 | #ifdef HAVE_CURSES_H |
| 6298 | #include <curses.h> |
| 6299 | #endif |
| 6300 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6301 | " |
| 6302 | if test "x$ac_cv_header_term_h" = x""yes; then : |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6303 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6304 | #define HAVE_TERM_H 1 |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6305 | _ACEOF |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6306 | |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6307 | fi |
| 6308 | |
| 6309 | done |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6310 | |
| 6311 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6312 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6313 | for ac_header in linux/netlink.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6314 | do : |
| 6315 | 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] | 6316 | #ifdef HAVE_ASM_TYPES_H |
| 6317 | #include <asm/types.h> |
| 6318 | #endif |
| 6319 | #ifdef HAVE_SYS_SOCKET_H |
| 6320 | #include <sys/socket.h> |
| 6321 | #endif |
| 6322 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6323 | " |
| 6324 | 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] | 6325 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6326 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6327 | _ACEOF |
| 6328 | |
| 6329 | fi |
| 6330 | |
| 6331 | done |
| 6332 | |
| 6333 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6334 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6335 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 6337 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 6338 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6339 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6340 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6341 | |
| 6342 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6343 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6344 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6345 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6346 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6347 | |
| 6348 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6349 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6350 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6351 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6352 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6353 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6354 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 6356 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6357 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6358 | # Check whether using makedev requires defining _OSF_SOURCE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6359 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 6360 | $as_echo_n "checking for makedev... " >&6; } |
| 6361 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6362 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6363 | |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6364 | #if defined(MAJOR_IN_MKDEV) |
| 6365 | #include <sys/mkdev.h> |
| 6366 | #elif defined(MAJOR_IN_SYSMACROS) |
| 6367 | #include <sys/sysmacros.h> |
| 6368 | #else |
| 6369 | #include <sys/types.h> |
| 6370 | #endif |
| 6371 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6372 | int |
| 6373 | main () |
| 6374 | { |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6375 | |
| 6376 | makedev(0, 0) |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6377 | ; |
| 6378 | return 0; |
| 6379 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6380 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6381 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6382 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6383 | ac_cv_has_makedev=yes |
| 6384 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6385 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6386 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6387 | rm -f core conftest.err conftest.$ac_objext \ |
| 6388 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6389 | if test "$ac_cv_has_makedev" = "no"; then |
| 6390 | # we didn't link, try if _OSF_SOURCE will allow us to link |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6392 | /* end confdefs.h. */ |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6393 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6394 | #define _OSF_SOURCE 1 |
| 6395 | #include <sys/types.h> |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6396 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6397 | int |
| 6398 | main () |
| 6399 | { |
| 6400 | makedev(0, 0) |
| 6401 | ; |
| 6402 | return 0; |
| 6403 | } |
| 6404 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6405 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6406 | ac_cv_has_makedev=yes |
| 6407 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6408 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6409 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6410 | rm -f core conftest.err conftest.$ac_objext \ |
| 6411 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6412 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6413 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6414 | $as_echo "#define _OSF_SOURCE 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6415 | |
| 6416 | fi |
| 6417 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6418 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 6419 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6420 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6421 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6422 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6423 | |
| 6424 | fi |
| 6425 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6426 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 6427 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 6428 | # defined, but the compiler does not support pragma redefine_extname, |
| 6429 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 6430 | # structures (such as rlimit64) without declaring them. As a |
| 6431 | # work-around, disable LFS on such configurations |
| 6432 | |
| 6433 | use_lfs=yes |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 6435 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 6436 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6437 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6438 | |
| 6439 | #define _LARGEFILE_SOURCE 1 |
| 6440 | #define _FILE_OFFSET_BITS 64 |
| 6441 | #include <sys/resource.h> |
| 6442 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6443 | int |
| 6444 | main () |
| 6445 | { |
| 6446 | struct rlimit foo; |
| 6447 | ; |
| 6448 | return 0; |
| 6449 | } |
| 6450 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6451 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6452 | sol_lfs_bug=no |
| 6453 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6454 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6455 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6456 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6457 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 6458 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6459 | if test "$sol_lfs_bug" = "yes"; then |
| 6460 | use_lfs=no |
| 6461 | fi |
| 6462 | |
| 6463 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6464 | # Two defines needed to enable largefile support on various platforms |
| 6465 | # These may affect some typedefs |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6466 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6467 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6468 | |
| 6469 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6470 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6471 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6472 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6473 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 6474 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 6475 | cat >> confdefs.h <<\EOF |
| 6476 | #if defined(SCO_DS) |
| 6477 | #undef _OFF_T |
| 6478 | #endif |
| 6479 | EOF |
| 6480 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6481 | # Type availability checks |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6482 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
| 6483 | if test "x$ac_cv_type_mode_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6484 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6485 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6486 | |
| 6487 | cat >>confdefs.h <<_ACEOF |
| 6488 | #define mode_t int |
| 6489 | _ACEOF |
| 6490 | |
| 6491 | fi |
| 6492 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6493 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
| 6494 | if test "x$ac_cv_type_off_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6495 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6496 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6497 | |
| 6498 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6499 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6500 | _ACEOF |
| 6501 | |
| 6502 | fi |
| 6503 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6504 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
| 6505 | if test "x$ac_cv_type_pid_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6506 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6507 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6508 | |
| 6509 | cat >>confdefs.h <<_ACEOF |
| 6510 | #define pid_t int |
| 6511 | _ACEOF |
| 6512 | |
| 6513 | fi |
| 6514 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6515 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6516 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | bada4c3 | 2010-04-25 21:18:48 +0000 | [diff] [blame] | 6517 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6518 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6519 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6520 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
| 6521 | if test "x$ac_cv_type_size_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6522 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6523 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6524 | |
| 6525 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6526 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6527 | _ACEOF |
| 6528 | |
| 6529 | fi |
| 6530 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6531 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 6532 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
| 6533 | if test "${ac_cv_type_uid_t+set}" = set; then : |
| 6534 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6535 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6536 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6537 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6538 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6539 | |
| 6540 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6541 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6542 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6543 | ac_cv_type_uid_t=yes |
| 6544 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6545 | ac_cv_type_uid_t=no |
| 6546 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6547 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6548 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6549 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 6551 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6552 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6553 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6554 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6555 | |
| 6556 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6557 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6558 | |
| 6559 | fi |
| 6560 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6561 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 6562 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6563 | no|yes) ;; #( |
| 6564 | *) |
| 6565 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6566 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6567 | |
| 6568 | |
| 6569 | cat >>confdefs.h <<_ACEOF |
| 6570 | #define uint32_t $ac_cv_c_uint32_t |
| 6571 | _ACEOF |
| 6572 | ;; |
| 6573 | esac |
| 6574 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6575 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 6576 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6577 | no|yes) ;; #( |
| 6578 | *) |
| 6579 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6580 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6581 | |
| 6582 | |
| 6583 | cat >>confdefs.h <<_ACEOF |
| 6584 | #define uint64_t $ac_cv_c_uint64_t |
| 6585 | _ACEOF |
| 6586 | ;; |
| 6587 | esac |
| 6588 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6589 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 6590 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6591 | no|yes) ;; #( |
| 6592 | *) |
| 6593 | |
| 6594 | cat >>confdefs.h <<_ACEOF |
| 6595 | #define int32_t $ac_cv_c_int32_t |
| 6596 | _ACEOF |
| 6597 | ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6598 | esac |
| 6599 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6600 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 6601 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6602 | no|yes) ;; #( |
| 6603 | *) |
| 6604 | |
| 6605 | cat >>confdefs.h <<_ACEOF |
| 6606 | #define int64_t $ac_cv_c_int64_t |
| 6607 | _ACEOF |
| 6608 | ;; |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 6609 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6610 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6611 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
| 6612 | if test "x$ac_cv_type_ssize_t" = x""yes; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6613 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6614 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6615 | |
| 6616 | fi |
| 6617 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 6618 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6619 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 6620 | # ANSI C requires sizeof(char) == 1, so no need to check it |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6621 | # The cast to long int works around a bug in the HP C Compiler |
| 6622 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6623 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6624 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6625 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 6626 | $as_echo_n "checking size of int... " >&6; } |
| 6627 | if test "${ac_cv_sizeof_int+set}" = set; then : |
| 6628 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6629 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6630 | 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] | 6631 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6632 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6633 | if test "$ac_cv_type_int" = yes; then |
| 6634 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6635 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6636 | { as_fn_set_status 77 |
| 6637 | as_fn_error "cannot compute sizeof (int) |
| 6638 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6639 | else |
| 6640 | ac_cv_sizeof_int=0 |
| 6641 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6642 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6643 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6644 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 6646 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6647 | |
| 6648 | |
| 6649 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6650 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6651 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6652 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6653 | |
| 6654 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6655 | # The cast to long int works around a bug in the HP C Compiler |
| 6656 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6657 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6658 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6659 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 6660 | $as_echo_n "checking size of long... " >&6; } |
| 6661 | if test "${ac_cv_sizeof_long+set}" = set; then : |
| 6662 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6663 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6664 | 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] | 6665 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6666 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6667 | if test "$ac_cv_type_long" = yes; then |
| 6668 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6669 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6670 | { as_fn_set_status 77 |
| 6671 | as_fn_error "cannot compute sizeof (long) |
| 6672 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6673 | else |
| 6674 | ac_cv_sizeof_long=0 |
| 6675 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6676 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6677 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6678 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6679 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 6680 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6681 | |
| 6682 | |
| 6683 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6684 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6685 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6686 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6687 | |
| 6688 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6689 | # The cast to long int works around a bug in the HP C Compiler |
| 6690 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6691 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6692 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6693 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 6694 | $as_echo_n "checking size of void *... " >&6; } |
| 6695 | if test "${ac_cv_sizeof_void_p+set}" = set; then : |
| 6696 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6697 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6698 | 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] | 6699 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6700 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6701 | if test "$ac_cv_type_void_p" = yes; then |
| 6702 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6703 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6704 | { as_fn_set_status 77 |
| 6705 | as_fn_error "cannot compute sizeof (void *) |
| 6706 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6707 | else |
| 6708 | ac_cv_sizeof_void_p=0 |
| 6709 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6710 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6711 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6712 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6713 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 6714 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6715 | |
| 6716 | |
| 6717 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6718 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6719 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6720 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6721 | |
| 6722 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6723 | # The cast to long int works around a bug in the HP C Compiler |
| 6724 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6725 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6726 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6727 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 6728 | $as_echo_n "checking size of short... " >&6; } |
| 6729 | if test "${ac_cv_sizeof_short+set}" = set; then : |
| 6730 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6731 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6732 | 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] | 6733 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6734 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6735 | if test "$ac_cv_type_short" = yes; then |
| 6736 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6737 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6738 | { as_fn_set_status 77 |
| 6739 | as_fn_error "cannot compute sizeof (short) |
| 6740 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6741 | else |
| 6742 | ac_cv_sizeof_short=0 |
| 6743 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6744 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6745 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6746 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6747 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 6748 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6749 | |
| 6750 | |
| 6751 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6752 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6753 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6754 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6755 | |
| 6756 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6757 | # The cast to long int works around a bug in the HP C Compiler |
| 6758 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6759 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6760 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6761 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 6762 | $as_echo_n "checking size of float... " >&6; } |
| 6763 | if test "${ac_cv_sizeof_float+set}" = set; then : |
| 6764 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6765 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6766 | 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] | 6767 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6768 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6769 | if test "$ac_cv_type_float" = yes; then |
| 6770 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6771 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6772 | { as_fn_set_status 77 |
| 6773 | as_fn_error "cannot compute sizeof (float) |
| 6774 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6775 | else |
| 6776 | ac_cv_sizeof_float=0 |
| 6777 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6778 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6779 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6780 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 6782 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6783 | |
| 6784 | |
| 6785 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6786 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6787 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6788 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6789 | |
| 6790 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6791 | # The cast to long int works around a bug in the HP C Compiler |
| 6792 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6793 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6794 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6795 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 6796 | $as_echo_n "checking size of double... " >&6; } |
| 6797 | if test "${ac_cv_sizeof_double+set}" = set; then : |
| 6798 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6799 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6800 | 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] | 6801 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6802 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6803 | if test "$ac_cv_type_double" = yes; then |
| 6804 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6805 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6806 | { as_fn_set_status 77 |
| 6807 | as_fn_error "cannot compute sizeof (double) |
| 6808 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6809 | else |
| 6810 | ac_cv_sizeof_double=0 |
| 6811 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6812 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6813 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6814 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6815 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 6816 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6817 | |
| 6818 | |
| 6819 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6820 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6821 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6822 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6823 | |
| 6824 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6825 | # The cast to long int works around a bug in the HP C Compiler |
| 6826 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6827 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6828 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6829 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 6830 | $as_echo_n "checking size of fpos_t... " >&6; } |
| 6831 | if test "${ac_cv_sizeof_fpos_t+set}" = set; then : |
| 6832 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6833 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6834 | 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] | 6835 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6836 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6837 | if test "$ac_cv_type_fpos_t" = yes; then |
| 6838 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6839 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6840 | { as_fn_set_status 77 |
| 6841 | as_fn_error "cannot compute sizeof (fpos_t) |
| 6842 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6843 | else |
| 6844 | ac_cv_sizeof_fpos_t=0 |
| 6845 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6846 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6847 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6848 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6849 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 6850 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6851 | |
| 6852 | |
| 6853 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6854 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6855 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6856 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6857 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6858 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6859 | # The cast to long int works around a bug in the HP C Compiler |
| 6860 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6861 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6862 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6863 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 6864 | $as_echo_n "checking size of size_t... " >&6; } |
| 6865 | if test "${ac_cv_sizeof_size_t+set}" = set; then : |
| 6866 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6867 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6868 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6869 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6870 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6871 | if test "$ac_cv_type_size_t" = yes; then |
| 6872 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6873 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6874 | { as_fn_set_status 77 |
| 6875 | as_fn_error "cannot compute sizeof (size_t) |
| 6876 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6877 | else |
| 6878 | ac_cv_sizeof_size_t=0 |
| 6879 | fi |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6880 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6881 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6882 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6883 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 |
| 6884 | $as_echo "$ac_cv_sizeof_size_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6885 | |
| 6886 | |
| 6887 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6888 | cat >>confdefs.h <<_ACEOF |
| 6889 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t |
| 6890 | _ACEOF |
| 6891 | |
| 6892 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6893 | # The cast to long int works around a bug in the HP C Compiler |
| 6894 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6895 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6896 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6897 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5 |
| 6898 | $as_echo_n "checking size of pid_t... " >&6; } |
| 6899 | if test "${ac_cv_sizeof_pid_t+set}" = set; then : |
| 6900 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6901 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6902 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pid_t))" "ac_cv_sizeof_pid_t" "$ac_includes_default"; then : |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6903 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6904 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6905 | if test "$ac_cv_type_pid_t" = yes; then |
| 6906 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6907 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6908 | { as_fn_set_status 77 |
| 6909 | as_fn_error "cannot compute sizeof (pid_t) |
| 6910 | See \`config.log' for more details." "$LINENO" 5; }; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6911 | else |
| 6912 | ac_cv_sizeof_pid_t=0 |
| 6913 | fi |
| 6914 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6915 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6916 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 6918 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6919 | |
| 6920 | |
| 6921 | |
| 6922 | cat >>confdefs.h <<_ACEOF |
| 6923 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 6924 | _ACEOF |
| 6925 | |
| 6926 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6927 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6928 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 6929 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6930 | have_long_long=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6931 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6932 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6933 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6934 | int |
| 6935 | main () |
| 6936 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6937 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6938 | ; |
| 6939 | return 0; |
| 6940 | } |
| 6941 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6942 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6943 | |
| 6944 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6945 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6946 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6947 | have_long_long=yes |
| 6948 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6949 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6950 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6951 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 6952 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 6953 | if test "$have_long_long" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6954 | # The cast to long int works around a bug in the HP C Compiler |
| 6955 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6956 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6957 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 6959 | $as_echo_n "checking size of long long... " >&6; } |
| 6960 | if test "${ac_cv_sizeof_long_long+set}" = set; then : |
| 6961 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6962 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6963 | 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] | 6964 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6965 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6966 | if test "$ac_cv_type_long_long" = yes; then |
| 6967 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6968 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 6969 | { as_fn_set_status 77 |
| 6970 | as_fn_error "cannot compute sizeof (long long) |
| 6971 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6972 | else |
| 6973 | ac_cv_sizeof_long_long=0 |
| 6974 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6975 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6976 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6977 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6978 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 6979 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6980 | |
| 6981 | |
| 6982 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6983 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6984 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6985 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6986 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6987 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6988 | fi |
| 6989 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6990 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 6991 | $as_echo_n "checking for long double support... " >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 6992 | have_long_double=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6993 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 6994 | /* end confdefs.h. */ |
| 6995 | |
| 6996 | int |
| 6997 | main () |
| 6998 | { |
| 6999 | long double x; x = (long double)0; |
| 7000 | ; |
| 7001 | return 0; |
| 7002 | } |
| 7003 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7004 | if ac_fn_c_try_compile "$LINENO"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7005 | |
| 7006 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7007 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7008 | |
| 7009 | have_long_double=yes |
| 7010 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7011 | fi |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7012 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 7014 | $as_echo "$have_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7015 | if test "$have_long_double" = yes ; then |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7016 | # The cast to long int works around a bug in the HP C Compiler |
| 7017 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7018 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7019 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7020 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 7021 | $as_echo_n "checking size of long double... " >&6; } |
| 7022 | if test "${ac_cv_sizeof_long_double+set}" = set; then : |
| 7023 | $as_echo_n "(cached) " >&6 |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7024 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7025 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long double))" "ac_cv_sizeof_long_double" "$ac_includes_default"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7026 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7027 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7028 | if test "$ac_cv_type_long_double" = yes; then |
| 7029 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7030 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7031 | { as_fn_set_status 77 |
| 7032 | as_fn_error "cannot compute sizeof (long double) |
| 7033 | See \`config.log' for more details." "$LINENO" 5; }; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7034 | else |
| 7035 | ac_cv_sizeof_long_double=0 |
| 7036 | fi |
| 7037 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7038 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7039 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7040 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 7041 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7042 | |
| 7043 | |
| 7044 | |
| 7045 | cat >>confdefs.h <<_ACEOF |
| 7046 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 7047 | _ACEOF |
| 7048 | |
| 7049 | |
| 7050 | fi |
| 7051 | |
| 7052 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7053 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 7054 | $as_echo_n "checking for _Bool support... " >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7055 | have_c99_bool=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7056 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7057 | /* end confdefs.h. */ |
| 7058 | |
| 7059 | int |
| 7060 | main () |
| 7061 | { |
| 7062 | _Bool x; x = (_Bool)0; |
| 7063 | ; |
| 7064 | return 0; |
| 7065 | } |
| 7066 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7067 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7068 | |
| 7069 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7070 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7071 | |
| 7072 | have_c99_bool=yes |
| 7073 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7074 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7075 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 7077 | $as_echo "$have_c99_bool" >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7078 | if test "$have_c99_bool" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7079 | # The cast to long int works around a bug in the HP C Compiler |
| 7080 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7081 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7082 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7083 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 7084 | $as_echo_n "checking size of _Bool... " >&6; } |
| 7085 | if test "${ac_cv_sizeof__Bool+set}" = set; then : |
| 7086 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7087 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7088 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (_Bool))" "ac_cv_sizeof__Bool" "$ac_includes_default"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7089 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7090 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7091 | if test "$ac_cv_type__Bool" = yes; then |
| 7092 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7093 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7094 | { as_fn_set_status 77 |
| 7095 | as_fn_error "cannot compute sizeof (_Bool) |
| 7096 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7097 | else |
| 7098 | ac_cv_sizeof__Bool=0 |
| 7099 | fi |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7100 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7101 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7102 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7103 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 7104 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7105 | |
| 7106 | |
| 7107 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7108 | cat >>confdefs.h <<_ACEOF |
| 7109 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 7110 | _ACEOF |
| 7111 | |
| 7112 | |
| 7113 | fi |
| 7114 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7115 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "#ifdef HAVE_STDINT_H |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7116 | #include <stdint.h> |
| 7117 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7118 | " |
| 7119 | if test "x$ac_cv_type_uintptr_t" = x""yes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7120 | |
| 7121 | cat >>confdefs.h <<_ACEOF |
| 7122 | #define HAVE_UINTPTR_T 1 |
| 7123 | _ACEOF |
| 7124 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7125 | # The cast to long int works around a bug in the HP C Compiler |
| 7126 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7127 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7128 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7129 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 7130 | $as_echo_n "checking size of uintptr_t... " >&6; } |
| 7131 | if test "${ac_cv_sizeof_uintptr_t+set}" = set; then : |
| 7132 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7133 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7134 | 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] | 7135 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7136 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7137 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 7138 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7139 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7140 | { as_fn_set_status 77 |
| 7141 | as_fn_error "cannot compute sizeof (uintptr_t) |
| 7142 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7143 | else |
| 7144 | ac_cv_sizeof_uintptr_t=0 |
| 7145 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7146 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7147 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7148 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7149 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 7150 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7151 | |
| 7152 | |
| 7153 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7154 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7155 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7156 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7157 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7158 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7159 | fi |
| 7160 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7161 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7162 | # The cast to long int works around a bug in the HP C Compiler |
| 7163 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7164 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7165 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7166 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 7167 | $as_echo_n "checking size of off_t... " >&6; } |
| 7168 | if test "${ac_cv_sizeof_off_t+set}" = set; then : |
| 7169 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7170 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7171 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7172 | #ifdef HAVE_SYS_TYPES_H |
| 7173 | #include <sys/types.h> |
| 7174 | #endif |
| 7175 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7176 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7177 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7178 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7179 | if test "$ac_cv_type_off_t" = yes; then |
| 7180 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7181 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7182 | { as_fn_set_status 77 |
| 7183 | as_fn_error "cannot compute sizeof (off_t) |
| 7184 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7185 | else |
| 7186 | ac_cv_sizeof_off_t=0 |
| 7187 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7188 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7189 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7190 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7191 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 7192 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7193 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7194 | |
| 7195 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7196 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7197 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7198 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7199 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7200 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7201 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 7203 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7204 | if test "$have_long_long" = yes |
| 7205 | then |
| 7206 | 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] | 7207 | "$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] | 7208 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7209 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7210 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7212 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7213 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7215 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7216 | fi |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7217 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7219 | $as_echo "no" >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7220 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7221 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7222 | # The cast to long int works around a bug in the HP C Compiler |
| 7223 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7224 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7225 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7226 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 7227 | $as_echo_n "checking size of time_t... " >&6; } |
| 7228 | if test "${ac_cv_sizeof_time_t+set}" = set; then : |
| 7229 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7230 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7231 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7232 | #ifdef HAVE_SYS_TYPES_H |
| 7233 | #include <sys/types.h> |
| 7234 | #endif |
| 7235 | #ifdef HAVE_TIME_H |
| 7236 | #include <time.h> |
| 7237 | #endif |
| 7238 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7239 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7240 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7241 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7242 | if test "$ac_cv_type_time_t" = yes; then |
| 7243 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7244 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7245 | { as_fn_set_status 77 |
| 7246 | as_fn_error "cannot compute sizeof (time_t) |
| 7247 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7248 | else |
| 7249 | ac_cv_sizeof_time_t=0 |
| 7250 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7251 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7252 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7253 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7254 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 7255 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7256 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7257 | |
| 7258 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7259 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7260 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7261 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7262 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7263 | |
| 7264 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7265 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7266 | ac_save_cc="$CC" |
| 7267 | if test "$ac_cv_kpthread" = "yes" |
| 7268 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 7269 | elif test "$ac_cv_kthread" = "yes" |
| 7270 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 7271 | elif test "$ac_cv_pthread" = "yes" |
| 7272 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7273 | fi |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7274 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7275 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 7276 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7277 | have_pthread_t=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7278 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7279 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7280 | |
| 7281 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7282 | int |
| 7283 | main () |
| 7284 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 7285 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7286 | ; |
| 7287 | return 0; |
| 7288 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7289 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7290 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7291 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7292 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7293 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7294 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7295 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 7296 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7297 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7298 | # The cast to long int works around a bug in the HP C Compiler |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7299 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7300 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7301 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7302 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 7303 | $as_echo_n "checking size of pthread_t... " >&6; } |
| 7304 | if test "${ac_cv_sizeof_pthread_t+set}" = set; then : |
| 7305 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7306 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7307 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t" " |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7308 | #ifdef HAVE_PTHREAD_H |
| 7309 | #include <pthread.h> |
| 7310 | #endif |
| 7311 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7312 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7313 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7314 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7315 | if test "$ac_cv_type_pthread_t" = yes; then |
| 7316 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7317 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7318 | { as_fn_set_status 77 |
| 7319 | as_fn_error "cannot compute sizeof (pthread_t) |
| 7320 | See \`config.log' for more details." "$LINENO" 5; }; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7321 | else |
| 7322 | ac_cv_sizeof_pthread_t=0 |
| 7323 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7324 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7325 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7326 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 7328 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7329 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7330 | |
| 7331 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7332 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7333 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7334 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7335 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7336 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7337 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7338 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7339 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7340 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7341 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7342 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7343 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 7344 | ;; |
| 7345 | Darwin/*) |
| 7346 | OTHER_LIBTOOL_OPT="" |
| 7347 | ;; |
| 7348 | esac |
| 7349 | |
| 7350 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7351 | ARCH_RUN_32BIT="" |
| 7352 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7353 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7354 | Darwin/[01567]\..*) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7355 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 7356 | if test "${enable_universalsdk}"; then |
| 7357 | : |
| 7358 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7359 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7360 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7361 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7362 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 7363 | Darwin/*) |
Ronald Oussoren | 9812a6c | 2010-02-07 11:53:18 +0000 | [diff] [blame] | 7364 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7365 | if test ${gcc_version} '<' 4.0 |
| 7366 | then |
| 7367 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 7368 | else |
| 7369 | LIBTOOL_CRUFT="" |
| 7370 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7371 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7372 | ac_osx_32bit=yes |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7373 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7374 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7375 | /* end confdefs.h. */ |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7376 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7377 | #include <unistd.h> |
| 7378 | int main(int argc, char*argv[]) |
| 7379 | { |
| 7380 | if (sizeof(long) == 4) { |
| 7381 | return 0; |
| 7382 | } else { |
| 7383 | return 1; |
| 7384 | } |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7385 | } |
| 7386 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7387 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7388 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7389 | ac_osx_32bit=yes |
| 7390 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7391 | ac_osx_32bit=no |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7392 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7393 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7394 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7395 | fi |
| 7396 | |
| 7397 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7398 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7399 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7400 | i386) |
| 7401 | MACOSX_DEFAULT_ARCH="i386" |
| 7402 | ;; |
| 7403 | ppc) |
| 7404 | MACOSX_DEFAULT_ARCH="ppc" |
| 7405 | ;; |
| 7406 | *) |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7407 | as_fn_error "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7408 | ;; |
| 7409 | esac |
| 7410 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7411 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7412 | i386) |
| 7413 | MACOSX_DEFAULT_ARCH="x86_64" |
| 7414 | ;; |
| 7415 | ppc) |
| 7416 | MACOSX_DEFAULT_ARCH="ppc64" |
| 7417 | ;; |
| 7418 | *) |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7419 | as_fn_error "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7420 | ;; |
| 7421 | esac |
| 7422 | |
| 7423 | #ARCH_RUN_32BIT="true" |
| 7424 | fi |
| 7425 | |
| 7426 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7427 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7428 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7429 | esac |
| 7430 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7431 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 7432 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7433 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7434 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 7435 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7436 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7437 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7438 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7439 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7440 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7442 | $as_echo "yes" >&6; } |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 7443 | if test $enable_shared = "yes" |
| 7444 | then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 7445 | as_fn_error "Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" "$LINENO" 5 |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 7446 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7447 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7448 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7449 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7450 | fi |
| 7451 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7452 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 7453 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7454 | case $ac_sys_system/$ac_sys_release in |
| 7455 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7457 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7458 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7459 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 7460 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7461 | ;; |
| 7462 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7463 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7464 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7465 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7466 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7467 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7468 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7469 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7470 | |
| 7471 | |
| 7472 | |
| 7473 | |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7474 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7475 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7476 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7477 | cat >>confdefs.h <<_ACEOF |
| 7478 | #define SHLIB_EXT "$SO" |
| 7479 | _ACEOF |
| 7480 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7481 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 7482 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7483 | # (Shared libraries in this instance are shared modules to be loaded into |
| 7484 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7485 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 7486 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7487 | if test -z "$LDSHARED" |
| 7488 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7489 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7490 | AIX*) |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 7491 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp -L\$(srcdir)" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 7492 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7493 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7494 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7495 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7496 | SunOS/5*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7497 | if test "$GCC" = "yes" ; then |
| 7498 | LDSHARED='$(CC) -shared' |
| 7499 | LDCXXSHARED='$(CXX) -shared' |
| 7500 | else |
| 7501 | LDSHARED='$(CC) -G' |
| 7502 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 7503 | fi ;; |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7504 | hp*|HP*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7505 | if test "$GCC" = "yes" ; then |
| 7506 | LDSHARED='$(CC) -shared' |
| 7507 | LDCXXSHARED='$(CXX) -shared' |
| 7508 | else |
| 7509 | LDSHARED='ld -b' |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7510 | fi ;; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7511 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7512 | Darwin/1.3*) |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7513 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7514 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7515 | if test "$enable_framework" ; then |
| 7516 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7517 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7518 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7519 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7520 | else |
| 7521 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7522 | LDSHARED="$LDSHARED -undefined suppress" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7523 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7524 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7525 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7526 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7527 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7528 | if test "$enable_framework" ; then |
| 7529 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7530 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7531 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7532 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7533 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 7534 | # No framework, use the Python app as bundle-loader |
| 7535 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 7536 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7537 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7538 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7539 | Darwin/*) |
| 7540 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 7541 | # This allows an extension to be used in any Python |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 7542 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7543 | if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7544 | then |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7545 | if test "${enable_universalsdk}"; then |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7546 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7547 | fi |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7548 | LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined dynamic_lookup' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7549 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle -undefined dynamic_lookup' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7550 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7551 | else |
| 7552 | LDSHARED='$(CC) $(LDFLAGS) -bundle' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7553 | LDCXXSHARED='$(CXX) $(LDFLAGS) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7554 | if test "$enable_framework" ; then |
| 7555 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7556 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7557 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7558 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7559 | else |
| 7560 | # No framework, use the Python app as bundle-loader |
| 7561 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 7562 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7563 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7564 | fi |
| 7565 | fi |
| 7566 | ;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7567 | Linux*|GNU*|QNX*) |
| 7568 | LDSHARED='$(CC) -shared' |
| 7569 | LDCXXSHARED='$(CXX) -shared';; |
| 7570 | BSD/OS*/4*) |
| 7571 | LDSHARED="gcc -shared" |
| 7572 | LDCXXSHARED="g++ -shared";; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7573 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 7574 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7575 | then |
Benjamin Peterson | ab0a752 | 2010-03-14 15:18:25 +0000 | [diff] [blame] | 7576 | LDSHARED='$(CC) -shared ${LDFLAGS}' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7577 | LDCXXSHARED='$(CXX) -shared ${LDFLAGS}' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7578 | else |
| 7579 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7580 | fi;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7581 | OpenBSD*) |
| 7582 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7583 | then |
| 7584 | LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7585 | LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7586 | else |
| 7587 | case `uname -r` in |
| 7588 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 7589 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7590 | ;; |
| 7591 | *) |
| 7592 | LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7593 | LDCXXSHARED='$(CXX) -shared $(CCSHARED) ${LDFLAGS}' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7594 | ;; |
| 7595 | esac |
| 7596 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7597 | NetBSD*|DragonFly*) |
| 7598 | LDSHARED="cc -shared ${LDFLAGS}" |
| 7599 | LDCXXSHARED="c++ -shared ${LDFLAGS}";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7600 | OpenUNIX*|UnixWare*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7601 | if test "$GCC" = "yes" ; then |
| 7602 | LDSHARED='$(CC) -shared' |
| 7603 | LDCXXSHARED='$(CXX) -shared' |
| 7604 | else |
| 7605 | LDSHARED='$(CC) -G' |
| 7606 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7607 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7608 | SCO_SV*) |
| 7609 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 7610 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 7611 | CYGWIN*) |
| 7612 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 7613 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7614 | *) LDSHARED="ld";; |
| 7615 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7616 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7617 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 7618 | $as_echo "$LDSHARED" >&6; } |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7619 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7620 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7621 | # 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] | 7622 | # library (module) -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7623 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 7624 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7625 | if test -z "$CCSHARED" |
| 7626 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7627 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7628 | SunOS*) if test "$GCC" = yes; |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7629 | then CCSHARED="-fPIC"; |
| 7630 | elif test `uname -p` = sparc; |
| 7631 | then CCSHARED="-xcode=pic32"; |
| 7632 | else CCSHARED="-Kpic"; |
| 7633 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7634 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 7635 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7636 | else CCSHARED="+z"; |
| 7637 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7638 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7639 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7640 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7641 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7642 | if test "$GCC" = "yes" |
| 7643 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 7644 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7645 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7646 | SCO_SV*) |
| 7647 | if test "$GCC" = "yes" |
| 7648 | then CCSHARED="-fPIC" |
| 7649 | else CCSHARED="-Kpic -belf" |
| 7650 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7651 | IRIX*/6*) case $CC in |
| 7652 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 7653 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7654 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7655 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7656 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7657 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 7658 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7659 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7660 | # the python executable -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7661 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 7662 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7663 | if test -z "$LINKFORSHARED" |
| 7664 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7665 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7666 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7667 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 7668 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 7669 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7670 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7671 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7672 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7673 | Darwin/*) |
Benjamin Peterson | 9c80cac | 2009-05-23 16:34:23 +0000 | [diff] [blame] | 7674 | LINKFORSHARED="$extra_undefs -framework CoreFoundation" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7675 | if test "$enable_framework" |
| 7676 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7677 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7678 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7679 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7680 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7681 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 7682 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7683 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 7684 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7685 | then |
| 7686 | LINKFORSHARED="-Wl,--export-dynamic" |
| 7687 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7688 | SunOS/5*) case $CC in |
| 7689 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 7690 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 7691 | then |
| 7692 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7693 | fi;; |
| 7694 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 7695 | CYGWIN*) |
| 7696 | if test $enable_shared = "no" |
| 7697 | then |
| 7698 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 7699 | fi;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 7700 | QNX*) |
| 7701 | # -Wl,-E causes the symbols to be added to the dynamic |
| 7702 | # symbol table so that they can be found when a module |
| 7703 | # is loaded. -N 2048K causes the stack size to be set |
| 7704 | # to 2048 kilobytes so that the stack doesn't overflow |
| 7705 | # when running test_compile.py. |
| 7706 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7707 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7708 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7709 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 7710 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7711 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7712 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 7713 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 7715 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7716 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 7717 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 7718 | case $ac_sys_system in |
| 7719 | CYGWIN*) |
| 7720 | # Cygwin needs CCSHARED when building extension DLLs |
| 7721 | # but not when building the interpreter DLL. |
| 7722 | CFLAGSFORSHARED='';; |
| 7723 | *) |
| 7724 | CFLAGSFORSHARED='$(CCSHARED)' |
| 7725 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7726 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7727 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 7728 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7729 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7730 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 7731 | # library (with --enable-shared). |
| 7732 | # 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] | 7733 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 7734 | # if it is not required, since it creates a dependency of the shared library |
| 7735 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 7736 | # don't need to link LIBS explicitly. The default should be only changed |
| 7737 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7738 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7739 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 7740 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7741 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7742 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 7743 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7744 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7745 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 7746 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7747 | |
| 7748 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7749 | # checks for libraries |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 7751 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
| 7752 | if test "${ac_cv_lib_dl_dlopen+set}" = set; then : |
| 7753 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7754 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7755 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7756 | LIBS="-ldl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7757 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7758 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7759 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7760 | /* Override any GCC internal prototype to avoid an error. |
| 7761 | Use char because int might match the return type of a GCC |
| 7762 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7763 | #ifdef __cplusplus |
| 7764 | extern "C" |
| 7765 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7766 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7767 | int |
| 7768 | main () |
| 7769 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7770 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7771 | ; |
| 7772 | return 0; |
| 7773 | } |
| 7774 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7775 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7776 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7777 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7778 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7779 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7780 | rm -f core conftest.err conftest.$ac_objext \ |
| 7781 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7782 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7783 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7784 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 7785 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
| 7786 | 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] | 7787 | cat >>confdefs.h <<_ACEOF |
| 7788 | #define HAVE_LIBDL 1 |
| 7789 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7790 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7791 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7792 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7793 | fi |
| 7794 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7795 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 7796 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
| 7797 | if test "${ac_cv_lib_dld_shl_load+set}" = set; then : |
| 7798 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7799 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7800 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7801 | LIBS="-ldld $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7802 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7803 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7804 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7805 | /* Override any GCC internal prototype to avoid an error. |
| 7806 | Use char because int might match the return type of a GCC |
| 7807 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7808 | #ifdef __cplusplus |
| 7809 | extern "C" |
| 7810 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7811 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7812 | int |
| 7813 | main () |
| 7814 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7815 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7816 | ; |
| 7817 | return 0; |
| 7818 | } |
| 7819 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7820 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7821 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7822 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7823 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7824 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7825 | rm -f core conftest.err conftest.$ac_objext \ |
| 7826 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7827 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7828 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7829 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 7830 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
| 7831 | 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] | 7832 | cat >>confdefs.h <<_ACEOF |
| 7833 | #define HAVE_LIBDLD 1 |
| 7834 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7835 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7836 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7837 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7838 | fi |
| 7839 | # Dynamic linking for HP-UX |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7840 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7841 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7842 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7843 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 7844 | $as_echo_n "checking for library containing sem_init... " >&6; } |
| 7845 | if test "${ac_cv_search_sem_init+set}" = set; then : |
| 7846 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7847 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7848 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7849 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7850 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7851 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7852 | /* Override any GCC internal prototype to avoid an error. |
| 7853 | Use char because int might match the return type of a GCC |
| 7854 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7855 | #ifdef __cplusplus |
| 7856 | extern "C" |
| 7857 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7858 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7859 | int |
| 7860 | main () |
| 7861 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7862 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7863 | ; |
| 7864 | return 0; |
| 7865 | } |
| 7866 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7867 | for ac_lib in '' pthread rt posix4; do |
| 7868 | if test -z "$ac_lib"; then |
| 7869 | ac_res="none required" |
| 7870 | else |
| 7871 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7872 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7873 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7874 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7875 | ac_cv_search_sem_init=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7876 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7877 | rm -f core conftest.err conftest.$ac_objext \ |
| 7878 | conftest$ac_exeext |
| 7879 | if test "${ac_cv_search_sem_init+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7880 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7881 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7882 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7883 | if test "${ac_cv_search_sem_init+set}" = set; then : |
| 7884 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7885 | else |
| 7886 | ac_cv_search_sem_init=no |
| 7887 | fi |
| 7888 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7889 | LIBS=$ac_func_search_save_LIBS |
| 7890 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7891 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 7892 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7893 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7894 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7895 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7896 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7897 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 7898 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7899 | # posix4 on Solaris 2.6 |
| 7900 | # pthread (first!) on Linux |
| 7901 | fi |
| 7902 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7903 | # check if we need libintl for locale functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7904 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 7905 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
| 7906 | if test "${ac_cv_lib_intl_textdomain+set}" = set; then : |
| 7907 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7908 | else |
| 7909 | ac_check_lib_save_LIBS=$LIBS |
| 7910 | LIBS="-lintl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7911 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7912 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7913 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7914 | /* Override any GCC internal prototype to avoid an error. |
| 7915 | Use char because int might match the return type of a GCC |
| 7916 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7917 | #ifdef __cplusplus |
| 7918 | extern "C" |
| 7919 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7920 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7921 | int |
| 7922 | main () |
| 7923 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7924 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7925 | ; |
| 7926 | return 0; |
| 7927 | } |
| 7928 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7929 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7930 | ac_cv_lib_intl_textdomain=yes |
| 7931 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7932 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7933 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7934 | rm -f core conftest.err conftest.$ac_objext \ |
| 7935 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7936 | LIBS=$ac_check_lib_save_LIBS |
| 7937 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7938 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 7939 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
| 7940 | 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] | 7941 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7942 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7943 | |
Brett Cannon | c6d936e | 2009-06-07 20:09:53 +0000 | [diff] [blame] | 7944 | LIBS="-lintl $LIBS" |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7945 | fi |
| 7946 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7947 | |
| 7948 | # checks for system dependent C++ extensions support |
| 7949 | case "$ac_sys_system" in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7950 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 7951 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 7952 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7953 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7954 | |
| 7955 | #include "/usr/lpp/xlC/include/load.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7956 | int |
| 7957 | main () |
| 7958 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7959 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7960 | ; |
| 7961 | return 0; |
| 7962 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7963 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7964 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7965 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7966 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7967 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7968 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7969 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7970 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7971 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7972 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7973 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7974 | |
| 7975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7976 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7977 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7978 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7979 | rm -f core conftest.err conftest.$ac_objext \ |
| 7980 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7981 | *) ;; |
| 7982 | esac |
| 7983 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 7984 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7985 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 7986 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
| 7987 | if test "${ac_cv_lib_nsl_t_open+set}" = set; then : |
| 7988 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 7989 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7990 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7991 | LIBS="-lnsl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7992 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7993 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7994 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7995 | /* Override any GCC internal prototype to avoid an error. |
| 7996 | Use char because int might match the return type of a GCC |
| 7997 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7998 | #ifdef __cplusplus |
| 7999 | extern "C" |
| 8000 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8001 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8002 | int |
| 8003 | main () |
| 8004 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8005 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8006 | ; |
| 8007 | return 0; |
| 8008 | } |
| 8009 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8010 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8011 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8012 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8013 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8014 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8015 | rm -f core conftest.err conftest.$ac_objext \ |
| 8016 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8017 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8018 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8019 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 8020 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
| 8021 | 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] | 8022 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8023 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 8024 | # SVR4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8025 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 8026 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
| 8027 | if test "${ac_cv_lib_socket_socket+set}" = set; then : |
| 8028 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8029 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8030 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8031 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8032 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8033 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8034 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8035 | /* Override any GCC internal prototype to avoid an error. |
| 8036 | Use char because int might match the return type of a GCC |
| 8037 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8038 | #ifdef __cplusplus |
| 8039 | extern "C" |
| 8040 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8041 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8042 | int |
| 8043 | main () |
| 8044 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8045 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8046 | ; |
| 8047 | return 0; |
| 8048 | } |
| 8049 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8050 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8051 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8052 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8053 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8054 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8055 | rm -f core conftest.err conftest.$ac_objext \ |
| 8056 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8057 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8058 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8059 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 8060 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
| 8061 | if test "x$ac_cv_lib_socket_socket" = x""yes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8062 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8063 | fi |
| 8064 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 8065 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8066 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 8067 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8068 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8069 | # Check whether --with-libs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8070 | if test "${with_libs+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8071 | withval=$with_libs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8072 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8073 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 8074 | LIBS="$withval $LIBS" |
| 8075 | |
| 8076 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8078 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8079 | fi |
| 8080 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 8081 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8082 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8083 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 8084 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8085 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8086 | $as_echo_n "checking for $ac_word... " >&6; } |
| 8087 | if test "${ac_cv_path_PKG_CONFIG+set}" = set; then : |
| 8088 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8089 | else |
| 8090 | case $PKG_CONFIG in |
| 8091 | [\\/]* | ?:[\\/]*) |
| 8092 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 8093 | ;; |
| 8094 | *) |
| 8095 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8096 | for as_dir in $PATH |
| 8097 | do |
| 8098 | IFS=$as_save_IFS |
| 8099 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8100 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8101 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8102 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8103 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8104 | break 2 |
| 8105 | fi |
| 8106 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8107 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8108 | IFS=$as_save_IFS |
| 8109 | |
| 8110 | ;; |
| 8111 | esac |
| 8112 | fi |
| 8113 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 8114 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8115 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 8116 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8117 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8118 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8119 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8120 | fi |
| 8121 | |
| 8122 | |
| 8123 | fi |
| 8124 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 8125 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 8126 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8127 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8129 | $as_echo_n "checking for $ac_word... " >&6; } |
| 8130 | if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then : |
| 8131 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8132 | else |
| 8133 | case $ac_pt_PKG_CONFIG in |
| 8134 | [\\/]* | ?:[\\/]*) |
| 8135 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 8136 | ;; |
| 8137 | *) |
| 8138 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8139 | for as_dir in $PATH |
| 8140 | do |
| 8141 | IFS=$as_save_IFS |
| 8142 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8143 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8144 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8145 | ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8146 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8147 | break 2 |
| 8148 | fi |
| 8149 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8150 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8151 | IFS=$as_save_IFS |
| 8152 | |
| 8153 | ;; |
| 8154 | esac |
| 8155 | fi |
| 8156 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 8157 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8158 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 8159 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8160 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8161 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8162 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8163 | fi |
| 8164 | |
| 8165 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 8166 | PKG_CONFIG="" |
| 8167 | else |
| 8168 | case $cross_compiling:$ac_tool_warned in |
| 8169 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8170 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 8171 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8172 | ac_tool_warned=yes ;; |
| 8173 | esac |
| 8174 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 8175 | fi |
| 8176 | else |
| 8177 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 8178 | fi |
| 8179 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8180 | |
| 8181 | # Check for use of the system expat library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8182 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 8183 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8184 | |
| 8185 | # Check whether --with-system_expat was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8186 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8187 | withval=$with_system_expat; |
| 8188 | fi |
| 8189 | |
| 8190 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8191 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 8192 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8193 | |
| 8194 | # Check for use of the system libffi library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 8196 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8197 | |
| 8198 | # Check whether --with-system_ffi was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8199 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8200 | withval=$with_system_ffi; |
| 8201 | fi |
| 8202 | |
| 8203 | |
| 8204 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8205 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 8206 | else |
| 8207 | LIBFFI_INCLUDEDIR="" |
| 8208 | fi |
| 8209 | |
| 8210 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 8212 | $as_echo "$with_system_ffi" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 8213 | |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8214 | # Check for --with-dbmliborder |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8215 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 8216 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8217 | |
| 8218 | # Check whether --with-dbmliborder was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8219 | if test "${with_dbmliborder+set}" = set; then : |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8220 | withval=$with_dbmliborder; |
| 8221 | if test x$with_dbmliborder = xyes |
| 8222 | then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 8223 | as_fn_error "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8224 | else |
| 8225 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 8226 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 8227 | then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 8228 | as_fn_error "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8229 | fi |
| 8230 | done |
| 8231 | fi |
| 8232 | fi |
| 8233 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8234 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 8235 | $as_echo "$with_dbmliborder" >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8236 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8237 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8238 | |
| 8239 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8240 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 8241 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8242 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8243 | # Check whether --with-signal-module was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8244 | if test "${with_signal_module+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8245 | withval=$with_signal_module; |
| 8246 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8247 | |
| 8248 | |
| 8249 | if test -z "$with_signal_module" |
| 8250 | then with_signal_module="yes" |
| 8251 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8252 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 8253 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8254 | |
| 8255 | if test "${with_signal_module}" = "yes"; then |
| 8256 | USE_SIGNAL_MODULE="" |
| 8257 | SIGNAL_OBJS="" |
| 8258 | else |
| 8259 | USE_SIGNAL_MODULE="#" |
| 8260 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 8261 | fi |
| 8262 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 8263 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8264 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8265 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8266 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8267 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dec-threads" >&5 |
| 8268 | $as_echo_n "checking for --with-dec-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8269 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8270 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8271 | # Check whether --with-dec-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8272 | if test "${with_dec_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8273 | withval=$with_dec_threads; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8274 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8275 | $as_echo "$withval" >&6; } |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8276 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8277 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8278 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8279 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8280 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8281 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8282 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8283 | fi |
| 8284 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8285 | |
| 8286 | # Templates for things AC_DEFINEd more than once. |
| 8287 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8288 | |
| 8289 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8290 | |
| 8291 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 8293 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8294 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8295 | # Check whether --with-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8296 | if test "${with_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8297 | withval=$with_threads; |
| 8298 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8299 | |
| 8300 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8301 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8302 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8303 | # Check whether --with-thread was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8304 | if test "${with_thread+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8305 | withval=$with_thread; with_threads=$with_thread |
| 8306 | fi |
| 8307 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8308 | |
| 8309 | if test -z "$with_threads" |
| 8310 | then with_threads="yes" |
| 8311 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 8313 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8314 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8315 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8316 | if test "$with_threads" = "no" |
| 8317 | then |
| 8318 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8319 | elif test "$ac_cv_pthread_is_default" = yes |
| 8320 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8321 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8322 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8323 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8324 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8325 | |
| 8326 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8327 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8328 | elif test "$ac_cv_kpthread" = "yes" |
| 8329 | then |
| 8330 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8331 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8332 | CXX="$CXX -Kpthread" |
| 8333 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8334 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 8335 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8336 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8337 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8338 | elif test "$ac_cv_kthread" = "yes" |
| 8339 | then |
| 8340 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8341 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8342 | CXX="$CXX -Kthread" |
| 8343 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8344 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8345 | |
| 8346 | posix_threads=yes |
| 8347 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8348 | elif test "$ac_cv_pthread" = "yes" |
| 8349 | then |
| 8350 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8351 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8352 | CXX="$CXX -pthread" |
| 8353 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8354 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8355 | |
| 8356 | posix_threads=yes |
| 8357 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8358 | else |
| 8359 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 8360 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 8361 | fi |
| 8362 | if test ! -z "$withval" -a -d "$withval" |
| 8363 | then LDFLAGS="$LDFLAGS -L$withval" |
| 8364 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8365 | |
| 8366 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 8367 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 8368 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8369 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 8370 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 8371 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8372 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8373 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8374 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8375 | #ifdef _POSIX_THREADS |
| 8376 | yes |
| 8377 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8378 | |
| 8379 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8380 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8381 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8382 | unistd_defines_pthreads=yes |
| 8383 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8384 | unistd_defines_pthreads=no |
| 8385 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 8386 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8387 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8388 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 8389 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8390 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8391 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 8392 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8393 | ac_fn_c_check_header_mongrel "$LINENO" "cthreads.h" "ac_cv_header_cthreads_h" "$ac_includes_default" |
| 8394 | if test "x$ac_cv_header_cthreads_h" = x""yes; then : |
| 8395 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8396 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8397 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8398 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8399 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8400 | $as_echo "#define HURD_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8401 | |
| 8402 | LIBS="$LIBS -lthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8403 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8404 | else |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8405 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8406 | ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" |
| 8407 | if test "x$ac_cv_header_mach_cthreads_h" = x""yes; then : |
| 8408 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8409 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8410 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8411 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8412 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8413 | $as_echo "#define MACH_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8414 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8415 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8416 | else |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8417 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8418 | # Just looking for pthread_create in libpthread is not enough: |
| 8419 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 8420 | # So we really have to include pthread.h, and then link. |
| 8421 | _libs=$LIBS |
| 8422 | LIBS="$LIBS -lpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 8424 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 8425 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8426 | /* end confdefs.h. */ |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8427 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8428 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8429 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8430 | int |
| 8431 | main () |
| 8432 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8433 | |
| 8434 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8435 | ; |
| 8436 | return 0; |
| 8437 | } |
| 8438 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8439 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8440 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8442 | $as_echo "yes" >&6; } |
| 8443 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8444 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8445 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8446 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8447 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8448 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8449 | LIBS=$_libs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8450 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
| 8451 | if test "x$ac_cv_func_pthread_detach" = x""yes; then : |
| 8452 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8453 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8454 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8455 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8456 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8457 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8458 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 8459 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
| 8460 | if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then : |
| 8461 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8462 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8463 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8464 | LIBS="-lpthreads $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8465 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8466 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8467 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8468 | /* Override any GCC internal prototype to avoid an error. |
| 8469 | Use char because int might match the return type of a GCC |
| 8470 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8471 | #ifdef __cplusplus |
| 8472 | extern "C" |
| 8473 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8474 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8475 | int |
| 8476 | main () |
| 8477 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8478 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8479 | ; |
| 8480 | return 0; |
| 8481 | } |
| 8482 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8483 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8484 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8485 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8486 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8487 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8488 | rm -f core conftest.err conftest.$ac_objext \ |
| 8489 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8490 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8491 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8492 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 8493 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
| 8494 | if test "x$ac_cv_lib_pthreads_pthread_create" = x""yes; then : |
| 8495 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8496 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8497 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8498 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8499 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8500 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8501 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8502 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 8503 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
| 8504 | if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then : |
| 8505 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8506 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8507 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8508 | LIBS="-lc_r $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8510 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8511 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8512 | /* Override any GCC internal prototype to avoid an error. |
| 8513 | Use char because int might match the return type of a GCC |
| 8514 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8515 | #ifdef __cplusplus |
| 8516 | extern "C" |
| 8517 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8518 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8519 | int |
| 8520 | main () |
| 8521 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8522 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8523 | ; |
| 8524 | return 0; |
| 8525 | } |
| 8526 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8527 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8528 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8529 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8530 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8531 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8532 | rm -f core conftest.err conftest.$ac_objext \ |
| 8533 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8534 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8535 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8536 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 8537 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
| 8538 | if test "x$ac_cv_lib_c_r_pthread_create" = x""yes; then : |
| 8539 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8540 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8541 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8542 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8543 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8544 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8545 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 8547 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
| 8548 | if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then : |
| 8549 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8550 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8551 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8552 | LIBS="-lpthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8554 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8555 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8556 | /* Override any GCC internal prototype to avoid an error. |
| 8557 | Use char because int might match the return type of a GCC |
| 8558 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8559 | #ifdef __cplusplus |
| 8560 | extern "C" |
| 8561 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8562 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8563 | int |
| 8564 | main () |
| 8565 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8566 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8567 | ; |
| 8568 | return 0; |
| 8569 | } |
| 8570 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8571 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8572 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8573 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8574 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8575 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8576 | rm -f core conftest.err conftest.$ac_objext \ |
| 8577 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8578 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8579 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8580 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 8581 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
| 8582 | if test "x$ac_cv_lib_pthread___pthread_create_system" = x""yes; then : |
| 8583 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8584 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8585 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8586 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8587 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8588 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8590 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 8591 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
| 8592 | if test "${ac_cv_lib_cma_pthread_create+set}" = set; then : |
| 8593 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8594 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8595 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8596 | LIBS="-lcma $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8597 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8598 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8599 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8600 | /* Override any GCC internal prototype to avoid an error. |
| 8601 | Use char because int might match the return type of a GCC |
| 8602 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8603 | #ifdef __cplusplus |
| 8604 | extern "C" |
| 8605 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8606 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8607 | int |
| 8608 | main () |
| 8609 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8610 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8611 | ; |
| 8612 | return 0; |
| 8613 | } |
| 8614 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8615 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8616 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8617 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8618 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8619 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8620 | rm -f core conftest.err conftest.$ac_objext \ |
| 8621 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8622 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8623 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8624 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 8625 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
| 8626 | if test "x$ac_cv_lib_cma_pthread_create" = x""yes; then : |
| 8627 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8628 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8629 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8630 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8631 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8632 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 8633 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8634 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 8635 | fi |
| 8636 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8637 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8638 | fi |
| 8639 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 8640 | fi |
| 8641 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8642 | fi |
| 8643 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8644 | fi |
| 8645 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8646 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8647 | rm -f core conftest.err conftest.$ac_objext \ |
| 8648 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8649 | fi |
| 8650 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8651 | |
| 8652 | fi |
| 8653 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8654 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8655 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8656 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 8657 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
| 8658 | if test "${ac_cv_lib_mpc_usconfig+set}" = set; then : |
| 8659 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8660 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8661 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8662 | LIBS="-lmpc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8663 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8664 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8665 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8666 | /* Override any GCC internal prototype to avoid an error. |
| 8667 | Use char because int might match the return type of a GCC |
| 8668 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8669 | #ifdef __cplusplus |
| 8670 | extern "C" |
| 8671 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8672 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8673 | int |
| 8674 | main () |
| 8675 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8676 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8677 | ; |
| 8678 | return 0; |
| 8679 | } |
| 8680 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8681 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8682 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8683 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8684 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8685 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8686 | rm -f core conftest.err conftest.$ac_objext \ |
| 8687 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8688 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8689 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8690 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 8691 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
| 8692 | if test "x$ac_cv_lib_mpc_usconfig" = x""yes; then : |
| 8693 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8694 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8695 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8696 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8697 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8698 | fi |
| 8699 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8700 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 8701 | if test "$posix_threads" != "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8702 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 8703 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
| 8704 | if test "${ac_cv_lib_thread_thr_create+set}" = set; then : |
| 8705 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8706 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8707 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8708 | LIBS="-lthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8709 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8710 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8711 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8712 | /* Override any GCC internal prototype to avoid an error. |
| 8713 | Use char because int might match the return type of a GCC |
| 8714 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8715 | #ifdef __cplusplus |
| 8716 | extern "C" |
| 8717 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8718 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8719 | int |
| 8720 | main () |
| 8721 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8722 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8723 | ; |
| 8724 | return 0; |
| 8725 | } |
| 8726 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8727 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8728 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8729 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8730 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8731 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8732 | rm -f core conftest.err conftest.$ac_objext \ |
| 8733 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8734 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8735 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8736 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 8737 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
| 8738 | if test "x$ac_cv_lib_thread_thr_create" = x""yes; then : |
| 8739 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8740 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8741 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8742 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8743 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8744 | fi |
| 8745 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8746 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8747 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8748 | if test "$USE_THREAD_MODULE" != "#" |
| 8749 | then |
| 8750 | # If the above checks didn't disable threads, (at least) OSF1 |
| 8751 | # needs this '-threads' argument during linking. |
| 8752 | case $ac_sys_system in |
| 8753 | OSF1) LDLAST=-threads;; |
| 8754 | esac |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 8755 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8756 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8757 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8758 | if test "$posix_threads" = "yes"; then |
| 8759 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8760 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8761 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8762 | |
| 8763 | fi |
| 8764 | |
| 8765 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 8766 | case $ac_sys_system/$ac_sys_release in |
| 8767 | SunOS/5.6) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8768 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8769 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8770 | ;; |
| 8771 | SunOS/5.8) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8772 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8773 | |
| 8774 | ;; |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8775 | AIX/5) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8776 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8777 | |
| 8778 | ;; |
Antoine Pitrou | 33a2994 | 2010-08-30 14:52:00 +0000 | [diff] [blame] | 8779 | AIX/6) |
| 8780 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
| 8781 | |
| 8782 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8783 | esac |
| 8784 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 8786 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
| 8787 | if test "${ac_cv_pthread_system_supported+set}" = set; then : |
| 8788 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8789 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8790 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8791 | ac_cv_pthread_system_supported=no |
| 8792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8793 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8794 | /* end confdefs.h. */ |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8795 | #include <pthread.h> |
| 8796 | void *foo(void *parm) { |
| 8797 | return NULL; |
| 8798 | } |
| 8799 | main() { |
| 8800 | pthread_attr_t attr; |
| 8801 | pthread_t id; |
| 8802 | if (pthread_attr_init(&attr)) exit(-1); |
| 8803 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 8804 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 8805 | exit(0); |
| 8806 | } |
| 8807 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8808 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8809 | ac_cv_pthread_system_supported=yes |
| 8810 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8811 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8812 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8813 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8814 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8815 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8816 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8817 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8818 | fi |
| 8819 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8820 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 8821 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8822 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 8823 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8824 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8825 | |
| 8826 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8827 | for ac_func in pthread_sigmask |
| 8828 | do : |
| 8829 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
| 8830 | 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] | 8831 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8832 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8833 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8834 | case $ac_sys_system in |
| 8835 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8836 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8837 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8838 | |
| 8839 | ;; |
| 8840 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8841 | fi |
| 8842 | done |
| 8843 | |
| 8844 | fi |
| 8845 | |
| 8846 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8847 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8848 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8849 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 8850 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8851 | # Check whether --enable-ipv6 was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8852 | if test "${enable_ipv6+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8853 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8854 | no) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8856 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8857 | ipv6=no |
| 8858 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8859 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8860 | $as_echo "yes" >&6; } |
| 8861 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8862 | |
| 8863 | ipv6=yes |
| 8864 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8865 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8866 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8867 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8868 | if test "$cross_compiling" = yes; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8869 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8870 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8871 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8872 | ipv6=no |
| 8873 | |
| 8874 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8875 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8876 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8877 | /* AF_INET6 available check */ |
| 8878 | #include <sys/types.h> |
| 8879 | #include <sys/socket.h> |
| 8880 | main() |
| 8881 | { |
| 8882 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 8883 | exit(1); |
| 8884 | else |
| 8885 | exit(0); |
| 8886 | } |
| 8887 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8888 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8889 | if ac_fn_c_try_run "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8890 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8891 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8892 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8893 | ipv6=yes |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8894 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8895 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8896 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8897 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8898 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8899 | ipv6=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8900 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8901 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8902 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8903 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8904 | fi |
| 8905 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8906 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8907 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8908 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 8909 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 8910 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8911 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8912 | |
| 8913 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8914 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8915 | int |
| 8916 | main () |
| 8917 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8918 | struct sockaddr_in6 x; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8919 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8920 | ; |
| 8921 | return 0; |
| 8922 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8923 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8924 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8925 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8926 | |
| 8927 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8928 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8929 | ipv6=yes |
| 8930 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8931 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8932 | |
| 8933 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8934 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8935 | ipv6=no |
| 8936 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8937 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8938 | 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] | 8939 | fi |
| 8940 | |
| 8941 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8942 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8943 | |
| 8944 | fi |
| 8945 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8946 | fi |
| 8947 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8948 | |
| 8949 | ipv6type=unknown |
| 8950 | ipv6lib=none |
| 8951 | ipv6trylibc=no |
| 8952 | |
| 8953 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8954 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 8955 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 8956 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 8957 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8958 | case $i in |
| 8959 | inria) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8960 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8961 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8962 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8963 | #include <netinet/in.h> |
| 8964 | #ifdef IPV6_INRIA_VERSION |
| 8965 | yes |
| 8966 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8967 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8968 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8969 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 8970 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8971 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 8972 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8973 | |
| 8974 | ;; |
| 8975 | kame) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8976 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8977 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8978 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8979 | #include <netinet/in.h> |
| 8980 | #ifdef __KAME__ |
| 8981 | yes |
| 8982 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8983 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8984 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8985 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8986 | ipv6type=$i; |
| 8987 | ipv6lib=inet6 |
| 8988 | ipv6libdir=/usr/local/v6/lib |
| 8989 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8990 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 8991 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8992 | |
| 8993 | ;; |
| 8994 | linux-glibc) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8995 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8996 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8997 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8998 | #include <features.h> |
| 8999 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 9000 | yes |
| 9001 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9002 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9003 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9004 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9005 | ipv6type=$i; |
| 9006 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9007 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9008 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9009 | |
| 9010 | ;; |
| 9011 | linux-inet6) |
| 9012 | if test -d /usr/inet6; then |
| 9013 | ipv6type=$i |
| 9014 | ipv6lib=inet6 |
| 9015 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9016 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9017 | fi |
| 9018 | ;; |
| 9019 | solaris) |
| 9020 | if test -f /etc/netconfig; then |
| 9021 | if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then |
| 9022 | ipv6type=$i |
| 9023 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9024 | fi |
| 9025 | fi |
| 9026 | ;; |
| 9027 | toshiba) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9028 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9029 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9030 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9031 | #include <sys/param.h> |
| 9032 | #ifdef _TOSHIBA_INET6 |
| 9033 | yes |
| 9034 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9035 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9036 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9037 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9038 | ipv6type=$i; |
| 9039 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9040 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9041 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9042 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9043 | |
| 9044 | ;; |
| 9045 | v6d) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9046 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9047 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9048 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9049 | #include </usr/local/v6/include/sys/v6config.h> |
| 9050 | #ifdef __V6D__ |
| 9051 | yes |
| 9052 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9053 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9054 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9055 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9056 | ipv6type=$i; |
| 9057 | ipv6lib=v6; |
| 9058 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9059 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9060 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9061 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9062 | |
| 9063 | ;; |
| 9064 | zeta) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9066 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9067 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9068 | #include <sys/param.h> |
| 9069 | #ifdef _ZETA_MINAMI_INET6 |
| 9070 | yes |
| 9071 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9072 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9073 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9074 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9075 | ipv6type=$i; |
| 9076 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9077 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9078 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9079 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9080 | |
| 9081 | ;; |
| 9082 | esac |
| 9083 | if test "$ipv6type" != "unknown"; then |
| 9084 | break |
| 9085 | fi |
| 9086 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9087 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 9088 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9089 | fi |
| 9090 | |
| 9091 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 9092 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 9093 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 9094 | echo "using lib$ipv6lib" |
| 9095 | else |
| 9096 | if test $ipv6trylibc = "yes"; then |
| 9097 | echo "using libc" |
| 9098 | else |
| 9099 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 9100 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 9101 | echo 'ipv6 kit and compile beforehand.' |
| 9102 | exit 1 |
| 9103 | fi |
| 9104 | fi |
| 9105 | fi |
| 9106 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9107 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 9108 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 9109 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9110 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9111 | |
| 9112 | #include <Carbon/Carbon.h> |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9113 | int |
| 9114 | main () |
| 9115 | { |
| 9116 | FSIORefNum fRef = 0 |
| 9117 | ; |
| 9118 | return 0; |
| 9119 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9120 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9121 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9122 | if ac_fn_c_try_compile "$LINENO"; then : |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9123 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9124 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9125 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9126 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9127 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9128 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9129 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9130 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9131 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9132 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9133 | $as_echo "no" >&6; } |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9134 | |
| 9135 | fi |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9136 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9137 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9138 | # Check for --with-doc-strings |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9139 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 9140 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9141 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9142 | # Check whether --with-doc-strings was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9143 | if test "${with_doc_strings+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9144 | withval=$with_doc_strings; |
| 9145 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9146 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9147 | |
| 9148 | if test -z "$with_doc_strings" |
| 9149 | then with_doc_strings="yes" |
| 9150 | fi |
| 9151 | if test "$with_doc_strings" != "no" |
| 9152 | then |
| 9153 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9154 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9155 | |
| 9156 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9157 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 9158 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9159 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 9160 | # Check if eval loop should use timestamp counter profiling |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9161 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 9162 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9163 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9164 | # Check whether --with-tsc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9165 | if test "${with_tsc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9166 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9167 | if test "$withval" != no |
| 9168 | then |
| 9169 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9170 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9171 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9172 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9173 | $as_echo "yes" >&6; } |
| 9174 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9175 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9176 | fi |
| 9177 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9179 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9180 | fi |
| 9181 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9182 | |
| 9183 | # Check for Python-specific malloc support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9184 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 9185 | $as_echo_n "checking for --with-pymalloc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9186 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9187 | # Check whether --with-pymalloc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9188 | if test "${with_pymalloc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9189 | withval=$with_pymalloc; |
| 9190 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9191 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9192 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9193 | if test -z "$with_pymalloc" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 9194 | then |
| 9195 | with_pymalloc="yes" |
| 9196 | SOABI_QUALIFIERS="${SOABI_QUALIFIERS}m" |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9197 | fi |
| 9198 | if test "$with_pymalloc" != "no" |
| 9199 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9200 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9201 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9202 | |
| 9203 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9204 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 9205 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9206 | |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9207 | # Check for Valgrind support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 9209 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9210 | |
| 9211 | # Check whether --with-valgrind was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9212 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9213 | withval=$with_valgrind; |
| 9214 | else |
| 9215 | with_valgrind=no |
| 9216 | fi |
| 9217 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 9219 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9220 | if test "$with_valgrind" != no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9221 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
| 9222 | if test "x$ac_cv_header_valgrind_valgrind_h" = x""yes; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9223 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9224 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9225 | |
| 9226 | else |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 9227 | as_fn_error "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9228 | |
| 9229 | fi |
| 9230 | |
| 9231 | |
Jeffrey Yasskin | 3937083 | 2010-05-03 19:29:34 +0000 | [diff] [blame] | 9232 | OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT" |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9233 | fi |
| 9234 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9235 | # Check for --with-wctype-functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9236 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-wctype-functions" >&5 |
| 9237 | $as_echo_n "checking for --with-wctype-functions... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9238 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9239 | # Check whether --with-wctype-functions was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9240 | if test "${with_wctype_functions+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9241 | withval=$with_wctype_functions; |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9242 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9243 | then |
| 9244 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9245 | $as_echo "#define WANT_WCTYPE_FUNCTIONS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9246 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9247 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9248 | $as_echo "yes" >&6; } |
| 9249 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9250 | $as_echo "no" >&6; } |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9251 | fi |
| 9252 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9254 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9255 | fi |
| 9256 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 9257 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 9258 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9259 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 9260 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9261 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9262 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 9263 | # 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] | 9264 | for ac_func in dlopen |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9265 | do : |
| 9266 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
| 9267 | if test "x$ac_cv_func_dlopen" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9268 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9269 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9270 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9271 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9272 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 9273 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9274 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9275 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9276 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 9277 | # loading of modules. |
| 9278 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 9280 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9281 | if test -z "$DYNLOADFILE" |
| 9282 | then |
| 9283 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 9284 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 9285 | if test "$ac_cv_func_dlopen" = yes |
| 9286 | then DYNLOADFILE="dynload_shlib.o" |
| 9287 | else DYNLOADFILE="dynload_aix.o" |
| 9288 | fi |
| 9289 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9290 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 9291 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 9292 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9293 | *) |
| 9294 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 9295 | # out any dynamic loading |
| 9296 | if test "$ac_cv_func_dlopen" = yes |
| 9297 | then DYNLOADFILE="dynload_shlib.o" |
| 9298 | else DYNLOADFILE="dynload_stub.o" |
| 9299 | fi |
| 9300 | ;; |
| 9301 | esac |
| 9302 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9303 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 9304 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9305 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 9306 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9307 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9308 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9309 | |
| 9310 | fi |
| 9311 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9312 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 9313 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9314 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 9316 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9317 | if test -z "$MACHDEP_OBJS" |
| 9318 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 9319 | MACHDEP_OBJS=$extra_machdep_objs |
| 9320 | else |
| 9321 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9322 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9323 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: MACHDEP_OBJS" >&5 |
| 9324 | $as_echo "MACHDEP_OBJS" >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9325 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9326 | # checks for library functions |
Martin v. Löwis | 823725e | 2008-03-24 13:39:54 +0000 | [diff] [blame] | 9327 | for ac_func in alarm setitimer getitimer bind_textdomain_codeset chown \ |
| 9328 | clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \ |
Martin v. Löwis | 438b534 | 2002-12-27 10:16:42 +0000 | [diff] [blame] | 9329 | gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 9330 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Antoine Pitrou | b7572f0 | 2009-12-02 20:46:48 +0000 | [diff] [blame] | 9331 | initgroups kill killpg lchmod lchown lstat mbrtowc mkfifo mknod mktime \ |
Martin v. Löwis | a5f0907 | 2002-10-11 05:37:59 +0000 | [diff] [blame] | 9332 | mremap nice pathconf pause plock poll pthread_init \ |
Guido van Rossum | 162e38c | 2003-02-19 15:25:10 +0000 | [diff] [blame] | 9333 | putenv readlink realpath \ |
Benjamin Peterson | 965ce87 | 2009-04-05 21:24:58 +0000 | [diff] [blame] | 9334 | select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \ |
| 9335 | setgid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 9336 | setlocale setregid setreuid setresuid setresgid setsid setpgid setpgrp setuid setvbuf \ |
Jean-Paul Calderone | 6ed7ac4 | 2010-06-19 19:58:37 +0000 | [diff] [blame] | 9337 | sigaction siginterrupt sigrelse snprintf strftime strlcpy \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 9338 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Martin v. Löwis | 113a085 | 2009-05-29 17:25:39 +0000 | [diff] [blame] | 9339 | truncate uname unsetenv utimes waitpid wait3 wait4 \ |
| 9340 | wcscoll wcsftime wcsxfrm _getpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9341 | do : |
| 9342 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9343 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 9344 | eval as_val=\$$as_ac_var |
| 9345 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9346 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9347 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9348 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 9349 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9350 | fi |
| 9351 | done |
| 9352 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9353 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9354 | # For some functions, having a definition is not sufficient, since |
| 9355 | # we want to take their address. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9356 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 9357 | $as_echo_n "checking for chroot... " >&6; } |
| 9358 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9359 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9360 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9361 | int |
| 9362 | main () |
| 9363 | { |
| 9364 | void *x=chroot |
| 9365 | ; |
| 9366 | return 0; |
| 9367 | } |
| 9368 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9369 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9370 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9371 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9372 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9374 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9375 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9377 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9378 | |
| 9379 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9380 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9381 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 9382 | $as_echo_n "checking for link... " >&6; } |
| 9383 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9384 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9385 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9386 | int |
| 9387 | main () |
| 9388 | { |
| 9389 | void *x=link |
| 9390 | ; |
| 9391 | return 0; |
| 9392 | } |
| 9393 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9394 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9395 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9396 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9397 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9398 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9399 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9400 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9401 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9402 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9403 | |
| 9404 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9405 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9406 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 9407 | $as_echo_n "checking for symlink... " >&6; } |
| 9408 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9409 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9410 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9411 | int |
| 9412 | main () |
| 9413 | { |
| 9414 | void *x=symlink |
| 9415 | ; |
| 9416 | return 0; |
| 9417 | } |
| 9418 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9419 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9420 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9421 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9422 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9423 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9424 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9425 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9426 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9427 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9428 | |
| 9429 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9430 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9431 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 9432 | $as_echo_n "checking for fchdir... " >&6; } |
| 9433 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9434 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9435 | #include <unistd.h> |
| 9436 | int |
| 9437 | main () |
| 9438 | { |
| 9439 | void *x=fchdir |
| 9440 | ; |
| 9441 | return 0; |
| 9442 | } |
| 9443 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9444 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9445 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9446 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9447 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9448 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9449 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9450 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9451 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9452 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9453 | |
| 9454 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9455 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9456 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 9457 | $as_echo_n "checking for fsync... " >&6; } |
| 9458 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9459 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9460 | #include <unistd.h> |
| 9461 | int |
| 9462 | main () |
| 9463 | { |
| 9464 | void *x=fsync |
| 9465 | ; |
| 9466 | return 0; |
| 9467 | } |
| 9468 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9469 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9470 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9471 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9472 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9474 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9475 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9476 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9477 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9478 | |
| 9479 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9480 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9481 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 9482 | $as_echo_n "checking for fdatasync... " >&6; } |
| 9483 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9484 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9485 | #include <unistd.h> |
| 9486 | int |
| 9487 | main () |
| 9488 | { |
| 9489 | void *x=fdatasync |
| 9490 | ; |
| 9491 | return 0; |
| 9492 | } |
| 9493 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9494 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9495 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9496 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9497 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9498 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9499 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9500 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9501 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9502 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9503 | |
| 9504 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9505 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9506 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 9507 | $as_echo_n "checking for epoll... " >&6; } |
| 9508 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9509 | /* end confdefs.h. */ |
| 9510 | #include <sys/epoll.h> |
| 9511 | int |
| 9512 | main () |
| 9513 | { |
| 9514 | void *x=epoll_create |
| 9515 | ; |
| 9516 | return 0; |
| 9517 | } |
| 9518 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9519 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9520 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9521 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9522 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9523 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9524 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9525 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9526 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9527 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9528 | |
| 9529 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9530 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9531 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 9532 | $as_echo_n "checking for kqueue... " >&6; } |
| 9533 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9534 | /* end confdefs.h. */ |
| 9535 | |
| 9536 | #include <sys/types.h> |
| 9537 | #include <sys/event.h> |
| 9538 | |
| 9539 | int |
| 9540 | main () |
| 9541 | { |
| 9542 | int x=kqueue() |
| 9543 | ; |
| 9544 | return 0; |
| 9545 | } |
| 9546 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9547 | if ac_fn_c_try_compile "$LINENO"; then : |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9548 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9549 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9550 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9551 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9552 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9553 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9554 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9555 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9556 | |
| 9557 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9558 | 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] | 9559 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 9560 | # functions ctermid_r, setgroups in the library, but no prototype |
| 9561 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 9562 | # address to avoid compiler warnings and potential miscompilations |
| 9563 | # because of the missing prototypes. |
| 9564 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9565 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 9566 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 9567 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9568 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9569 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9570 | #include <stdio.h> |
| 9571 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9572 | int |
| 9573 | main () |
| 9574 | { |
| 9575 | void* p = ctermid_r |
| 9576 | ; |
| 9577 | return 0; |
| 9578 | } |
| 9579 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9580 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9581 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9582 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9583 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9584 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9585 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9586 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9587 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9588 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9589 | |
| 9590 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9591 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9592 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9593 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5 |
| 9594 | $as_echo_n "checking for flock declaration... " >&6; } |
| 9595 | if test "${ac_cv_flock_decl+set}" = set; then : |
| 9596 | $as_echo_n "(cached) " >&6 |
| 9597 | else |
| 9598 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9599 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9600 | #include <sys/file.h> |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9601 | int |
| 9602 | main () |
| 9603 | { |
| 9604 | void* p = flock |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9605 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9606 | ; |
| 9607 | return 0; |
| 9608 | } |
| 9609 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9610 | if ac_fn_c_try_compile "$LINENO"; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9611 | ac_cv_flock_decl=yes |
| 9612 | else |
| 9613 | ac_cv_flock_decl=no |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9614 | |
| 9615 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9616 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9617 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9618 | fi |
| 9619 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5 |
| 9620 | $as_echo "$ac_cv_flock_decl" >&6; } |
| 9621 | if test "x${ac_cv_flock_decl}" = xyes; then |
| 9622 | for ac_func in flock |
| 9623 | do : |
| 9624 | ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" |
| 9625 | if test "x$ac_cv_func_flock" = x""yes; then : |
| 9626 | cat >>confdefs.h <<_ACEOF |
| 9627 | #define HAVE_FLOCK 1 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9628 | _ACEOF |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9629 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9630 | else |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9631 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock in -lbsd" >&5 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9632 | $as_echo_n "checking for flock in -lbsd... " >&6; } |
| 9633 | if test "${ac_cv_lib_bsd_flock+set}" = set; then : |
| 9634 | $as_echo_n "(cached) " >&6 |
| 9635 | else |
| 9636 | ac_check_lib_save_LIBS=$LIBS |
| 9637 | LIBS="-lbsd $LIBS" |
| 9638 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9639 | /* end confdefs.h. */ |
| 9640 | |
| 9641 | /* Override any GCC internal prototype to avoid an error. |
| 9642 | Use char because int might match the return type of a GCC |
| 9643 | builtin and then its argument prototype would still apply. */ |
| 9644 | #ifdef __cplusplus |
| 9645 | extern "C" |
| 9646 | #endif |
| 9647 | char flock (); |
| 9648 | int |
| 9649 | main () |
| 9650 | { |
| 9651 | return flock (); |
| 9652 | ; |
| 9653 | return 0; |
| 9654 | } |
| 9655 | _ACEOF |
| 9656 | if ac_fn_c_try_link "$LINENO"; then : |
| 9657 | ac_cv_lib_bsd_flock=yes |
| 9658 | else |
| 9659 | ac_cv_lib_bsd_flock=no |
| 9660 | fi |
| 9661 | rm -f core conftest.err conftest.$ac_objext \ |
| 9662 | conftest$ac_exeext conftest.$ac_ext |
| 9663 | LIBS=$ac_check_lib_save_LIBS |
| 9664 | fi |
| 9665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5 |
| 9666 | $as_echo "$ac_cv_lib_bsd_flock" >&6; } |
| 9667 | if test "x$ac_cv_lib_bsd_flock" = x""yes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9668 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9669 | |
| 9670 | |
| 9671 | $as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h |
| 9672 | |
| 9673 | |
| 9674 | fi |
| 9675 | |
| 9676 | |
| 9677 | fi |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9678 | done |
| 9679 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9680 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9681 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9682 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 9683 | $as_echo_n "checking for getpagesize... " >&6; } |
| 9684 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9685 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9686 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9687 | #include <unistd.h> |
| 9688 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9689 | int |
| 9690 | main () |
| 9691 | { |
| 9692 | void* p = getpagesize |
| 9693 | ; |
| 9694 | return 0; |
| 9695 | } |
| 9696 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9697 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9698 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9699 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9700 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9701 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9702 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9703 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9704 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9705 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9706 | |
| 9707 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9708 | 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] | 9709 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9710 | for ac_prog in true |
| 9711 | do |
| 9712 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 9713 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9715 | $as_echo_n "checking for $ac_word... " >&6; } |
| 9716 | if test "${ac_cv_prog_TRUE+set}" = set; then : |
| 9717 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9718 | else |
| 9719 | if test -n "$TRUE"; then |
| 9720 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 9721 | else |
| 9722 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9723 | for as_dir in $PATH |
| 9724 | do |
| 9725 | IFS=$as_save_IFS |
| 9726 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9727 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9728 | 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] | 9729 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9730 | $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] | 9731 | break 2 |
| 9732 | fi |
| 9733 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9734 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9735 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9736 | |
| 9737 | fi |
| 9738 | fi |
| 9739 | TRUE=$ac_cv_prog_TRUE |
| 9740 | if test -n "$TRUE"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9741 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 9742 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9743 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9744 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9745 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9746 | fi |
| 9747 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9748 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9749 | test -n "$TRUE" && break |
| 9750 | done |
| 9751 | test -n "$TRUE" || TRUE="/bin/true" |
| 9752 | |
| 9753 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9754 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 9755 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
| 9756 | if test "${ac_cv_lib_c_inet_aton+set}" = set; then : |
| 9757 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9758 | else |
| 9759 | ac_check_lib_save_LIBS=$LIBS |
| 9760 | LIBS="-lc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9761 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9762 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9763 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9764 | /* Override any GCC internal prototype to avoid an error. |
| 9765 | Use char because int might match the return type of a GCC |
| 9766 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9767 | #ifdef __cplusplus |
| 9768 | extern "C" |
| 9769 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9770 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9771 | int |
| 9772 | main () |
| 9773 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9774 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9775 | ; |
| 9776 | return 0; |
| 9777 | } |
| 9778 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9779 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9780 | ac_cv_lib_c_inet_aton=yes |
| 9781 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9782 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9783 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9784 | rm -f core conftest.err conftest.$ac_objext \ |
| 9785 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9786 | LIBS=$ac_check_lib_save_LIBS |
| 9787 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 9789 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
| 9790 | 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] | 9791 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9793 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 9794 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
| 9795 | if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then : |
| 9796 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9797 | else |
| 9798 | ac_check_lib_save_LIBS=$LIBS |
| 9799 | LIBS="-lresolv $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9800 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9801 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9802 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9803 | /* Override any GCC internal prototype to avoid an error. |
| 9804 | Use char because int might match the return type of a GCC |
| 9805 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9806 | #ifdef __cplusplus |
| 9807 | extern "C" |
| 9808 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9809 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9810 | int |
| 9811 | main () |
| 9812 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9813 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9814 | ; |
| 9815 | return 0; |
| 9816 | } |
| 9817 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9818 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9819 | ac_cv_lib_resolv_inet_aton=yes |
| 9820 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9821 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9822 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9823 | rm -f core conftest.err conftest.$ac_objext \ |
| 9824 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9825 | LIBS=$ac_check_lib_save_LIBS |
| 9826 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9827 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 9828 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
| 9829 | 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] | 9830 | cat >>confdefs.h <<_ACEOF |
| 9831 | #define HAVE_LIBRESOLV 1 |
| 9832 | _ACEOF |
| 9833 | |
| 9834 | LIBS="-lresolv $LIBS" |
| 9835 | |
| 9836 | fi |
| 9837 | |
| 9838 | |
| 9839 | fi |
| 9840 | |
| 9841 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9842 | # On Tru64, chflags seems to be present, but calling it will |
| 9843 | # exit Python |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9844 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 9845 | $as_echo_n "checking for chflags... " >&6; } |
| 9846 | if test "${ac_cv_have_chflags+set}" = set; then : |
| 9847 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9848 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9849 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9850 | ac_cv_have_chflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9851 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9852 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9853 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9854 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9855 | #include <sys/stat.h> |
| 9856 | #include <unistd.h> |
| 9857 | int main(int argc, char*argv[]) |
| 9858 | { |
| 9859 | if(chflags(argv[0], 0) != 0) |
| 9860 | return 1; |
| 9861 | return 0; |
| 9862 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9863 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9864 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9865 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9866 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9867 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9868 | ac_cv_have_chflags=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9869 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9870 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9871 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 9872 | fi |
| 9873 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9874 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9875 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9876 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 9877 | $as_echo "$ac_cv_have_chflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9878 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9879 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
| 9880 | if test "x$ac_cv_func_chflags" = x""yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9881 | ac_cv_have_chflags="yes" |
| 9882 | else |
| 9883 | ac_cv_have_chflags="no" |
| 9884 | fi |
| 9885 | |
| 9886 | fi |
| 9887 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9888 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9889 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9890 | |
| 9891 | fi |
| 9892 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9893 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 9894 | $as_echo_n "checking for lchflags... " >&6; } |
| 9895 | if test "${ac_cv_have_lchflags+set}" = set; then : |
| 9896 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9897 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9898 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9899 | ac_cv_have_lchflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9900 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9901 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9902 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9903 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9904 | #include <sys/stat.h> |
| 9905 | #include <unistd.h> |
| 9906 | int main(int argc, char*argv[]) |
| 9907 | { |
| 9908 | if(lchflags(argv[0], 0) != 0) |
| 9909 | return 1; |
| 9910 | return 0; |
| 9911 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9912 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9913 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9914 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9915 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9916 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9917 | ac_cv_have_lchflags=no |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9918 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9919 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9920 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9921 | fi |
| 9922 | |
| 9923 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9924 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9925 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 9926 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9927 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9928 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
| 9929 | if test "x$ac_cv_func_lchflags" = x""yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9930 | ac_cv_have_lchflags="yes" |
| 9931 | else |
| 9932 | ac_cv_have_lchflags="no" |
| 9933 | fi |
| 9934 | |
| 9935 | fi |
| 9936 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9937 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9938 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9939 | |
| 9940 | fi |
| 9941 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9942 | case $ac_sys_system/$ac_sys_release in |
| 9943 | Darwin/*) |
| 9944 | _CUR_CFLAGS="${CFLAGS}" |
| 9945 | _CUR_LDFLAGS="${LDFLAGS}" |
| 9946 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 9947 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 9948 | ;; |
| 9949 | esac |
| 9950 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9951 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 9952 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
| 9953 | if test "${ac_cv_lib_z_inflateCopy+set}" = set; then : |
| 9954 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9955 | else |
| 9956 | ac_check_lib_save_LIBS=$LIBS |
| 9957 | LIBS="-lz $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9958 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9959 | /* end confdefs.h. */ |
| 9960 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9961 | /* Override any GCC internal prototype to avoid an error. |
| 9962 | Use char because int might match the return type of a GCC |
| 9963 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9964 | #ifdef __cplusplus |
| 9965 | extern "C" |
| 9966 | #endif |
| 9967 | char inflateCopy (); |
| 9968 | int |
| 9969 | main () |
| 9970 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9971 | return inflateCopy (); |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9972 | ; |
| 9973 | return 0; |
| 9974 | } |
| 9975 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9976 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9977 | ac_cv_lib_z_inflateCopy=yes |
| 9978 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9979 | ac_cv_lib_z_inflateCopy=no |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9980 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9981 | rm -f core conftest.err conftest.$ac_objext \ |
| 9982 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9983 | LIBS=$ac_check_lib_save_LIBS |
| 9984 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9985 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 9986 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
| 9987 | if test "x$ac_cv_lib_z_inflateCopy" = x""yes; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9988 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9989 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9990 | |
| 9991 | fi |
| 9992 | |
| 9993 | |
| 9994 | case $ac_sys_system/$ac_sys_release in |
| 9995 | Darwin/*) |
| 9996 | CFLAGS="${_CUR_CFLAGS}" |
| 9997 | LDFLAGS="${_CUR_LDFLAGS}" |
| 9998 | ;; |
| 9999 | esac |
| 10000 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10001 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 10002 | $as_echo_n "checking for hstrerror... " >&6; } |
| 10003 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10004 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10005 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10006 | #include <netdb.h> |
| 10007 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10008 | int |
| 10009 | main () |
| 10010 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10011 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10012 | ; |
| 10013 | return 0; |
| 10014 | } |
| 10015 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10016 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10017 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10018 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10019 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10020 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10021 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10022 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10023 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10024 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10025 | |
| 10026 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10027 | rm -f core conftest.err conftest.$ac_objext \ |
| 10028 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10029 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10030 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 10031 | $as_echo_n "checking for inet_aton... " >&6; } |
| 10032 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10033 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10034 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 10035 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10036 | #include <sys/socket.h> |
| 10037 | #include <netinet/in.h> |
| 10038 | #include <arpa/inet.h> |
| 10039 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10040 | int |
| 10041 | main () |
| 10042 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10043 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10044 | ; |
| 10045 | return 0; |
| 10046 | } |
| 10047 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10048 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10049 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10050 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10051 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10053 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10054 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10056 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10057 | |
| 10058 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10059 | rm -f core conftest.err conftest.$ac_objext \ |
| 10060 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10061 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 10063 | $as_echo_n "checking for inet_pton... " >&6; } |
| 10064 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10065 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10066 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10067 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10068 | #include <sys/socket.h> |
| 10069 | #include <netinet/in.h> |
| 10070 | #include <arpa/inet.h> |
| 10071 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10072 | int |
| 10073 | main () |
| 10074 | { |
| 10075 | void* p = inet_pton |
| 10076 | ; |
| 10077 | return 0; |
| 10078 | } |
| 10079 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10080 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10081 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10082 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10083 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10084 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10085 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10086 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10087 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10088 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10089 | |
| 10090 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10091 | 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] | 10092 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10093 | # On some systems, setgroups is in unistd.h, on others, in grp.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10094 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 10095 | $as_echo_n "checking for setgroups... " >&6; } |
| 10096 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10097 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10098 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10099 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10100 | #ifdef HAVE_GRP_H |
| 10101 | #include <grp.h> |
| 10102 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10103 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10104 | int |
| 10105 | main () |
| 10106 | { |
| 10107 | void* p = setgroups |
| 10108 | ; |
| 10109 | return 0; |
| 10110 | } |
| 10111 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10112 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10113 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10114 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10115 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10116 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10117 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10118 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10120 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10121 | |
| 10122 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10123 | 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] | 10124 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10125 | # check for openpty and forkpty |
| 10126 | |
| 10127 | for ac_func in openpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10128 | do : |
| 10129 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
| 10130 | if test "x$ac_cv_func_openpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10131 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10132 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10133 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10134 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10135 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10136 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 10137 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
| 10138 | if test "${ac_cv_lib_util_openpty+set}" = set; then : |
| 10139 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10140 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10141 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10142 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10143 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10144 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10145 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10146 | /* Override any GCC internal prototype to avoid an error. |
| 10147 | Use char because int might match the return type of a GCC |
| 10148 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10149 | #ifdef __cplusplus |
| 10150 | extern "C" |
| 10151 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10152 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10153 | int |
| 10154 | main () |
| 10155 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10156 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10157 | ; |
| 10158 | return 0; |
| 10159 | } |
| 10160 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10161 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10162 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10163 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10164 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10165 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10166 | rm -f core conftest.err conftest.$ac_objext \ |
| 10167 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10168 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10169 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10170 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 10171 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
| 10172 | if test "x$ac_cv_lib_util_openpty" = x""yes; then : |
| 10173 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10174 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10175 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 10177 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
| 10178 | if test "${ac_cv_lib_bsd_openpty+set}" = set; then : |
| 10179 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10180 | else |
| 10181 | ac_check_lib_save_LIBS=$LIBS |
| 10182 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10183 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10184 | /* end confdefs.h. */ |
| 10185 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10186 | /* Override any GCC internal prototype to avoid an error. |
| 10187 | Use char because int might match the return type of a GCC |
| 10188 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10189 | #ifdef __cplusplus |
| 10190 | extern "C" |
| 10191 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10192 | char openpty (); |
| 10193 | int |
| 10194 | main () |
| 10195 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10196 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10197 | ; |
| 10198 | return 0; |
| 10199 | } |
| 10200 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10201 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10202 | ac_cv_lib_bsd_openpty=yes |
| 10203 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10204 | ac_cv_lib_bsd_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10205 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10206 | rm -f core conftest.err conftest.$ac_objext \ |
| 10207 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10208 | LIBS=$ac_check_lib_save_LIBS |
| 10209 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10210 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 10211 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
| 10212 | if test "x$ac_cv_lib_bsd_openpty" = x""yes; then : |
| 10213 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10214 | LIBS="$LIBS -lbsd" |
| 10215 | fi |
| 10216 | |
| 10217 | |
| 10218 | fi |
| 10219 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10220 | |
| 10221 | fi |
| 10222 | done |
| 10223 | |
| 10224 | for ac_func in forkpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10225 | do : |
| 10226 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
| 10227 | if test "x$ac_cv_func_forkpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10228 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10229 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10230 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10231 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10232 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10233 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 10234 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
| 10235 | if test "${ac_cv_lib_util_forkpty+set}" = set; then : |
| 10236 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10237 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10238 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10239 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10240 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10241 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10242 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10243 | /* Override any GCC internal prototype to avoid an error. |
| 10244 | Use char because int might match the return type of a GCC |
| 10245 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10246 | #ifdef __cplusplus |
| 10247 | extern "C" |
| 10248 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10249 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10250 | int |
| 10251 | main () |
| 10252 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10253 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10254 | ; |
| 10255 | return 0; |
| 10256 | } |
| 10257 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10258 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10259 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10260 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10261 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10262 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10263 | rm -f core conftest.err conftest.$ac_objext \ |
| 10264 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10265 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10266 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10267 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 10268 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
| 10269 | if test "x$ac_cv_lib_util_forkpty" = x""yes; then : |
| 10270 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10271 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10272 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10273 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 10274 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
| 10275 | if test "${ac_cv_lib_bsd_forkpty+set}" = set; then : |
| 10276 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10277 | else |
| 10278 | ac_check_lib_save_LIBS=$LIBS |
| 10279 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10280 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10281 | /* end confdefs.h. */ |
| 10282 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10283 | /* Override any GCC internal prototype to avoid an error. |
| 10284 | Use char because int might match the return type of a GCC |
| 10285 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10286 | #ifdef __cplusplus |
| 10287 | extern "C" |
| 10288 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10289 | char forkpty (); |
| 10290 | int |
| 10291 | main () |
| 10292 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10293 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10294 | ; |
| 10295 | return 0; |
| 10296 | } |
| 10297 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10298 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10299 | ac_cv_lib_bsd_forkpty=yes |
| 10300 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10301 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10302 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10303 | rm -f core conftest.err conftest.$ac_objext \ |
| 10304 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10305 | LIBS=$ac_check_lib_save_LIBS |
| 10306 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10307 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 10308 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
| 10309 | if test "x$ac_cv_lib_bsd_forkpty" = x""yes; then : |
| 10310 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10311 | LIBS="$LIBS -lbsd" |
| 10312 | fi |
| 10313 | |
| 10314 | |
| 10315 | fi |
| 10316 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10317 | |
| 10318 | fi |
| 10319 | done |
| 10320 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10321 | |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10322 | # Stuff for expat. |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10323 | for ac_func in memmove |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10324 | do : |
| 10325 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
| 10326 | if test "x$ac_cv_func_memmove" = x""yes; then : |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10327 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10328 | #define HAVE_MEMMOVE 1 |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10329 | _ACEOF |
| 10330 | |
| 10331 | fi |
| 10332 | done |
| 10333 | |
| 10334 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10335 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10336 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10337 | do : |
| 10338 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10339 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 10340 | eval as_val=\$$as_ac_var |
| 10341 | if test "x$as_val" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10342 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10343 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10344 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10345 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10346 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10347 | done |
| 10348 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10349 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 10350 | for ac_func in dup2 getcwd strdup |
| 10351 | do : |
| 10352 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10353 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
| 10354 | eval as_val=\$$as_ac_var |
| 10355 | if test "x$as_val" = x""yes; then : |
| 10356 | cat >>confdefs.h <<_ACEOF |
| 10357 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 10358 | _ACEOF |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10359 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10360 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10361 | case " $LIBOBJS " in |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 10362 | *" $ac_func.$ac_objext "* ) ;; |
| 10363 | *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10364 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10365 | esac |
| 10366 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10367 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 10368 | done |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10369 | |
| 10370 | |
| 10371 | for ac_func in getpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10372 | do : |
| 10373 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
| 10374 | if test "x$ac_cv_func_getpgrp" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10375 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10376 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10377 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10378 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10379 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10380 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10381 | int |
| 10382 | main () |
| 10383 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10384 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10385 | ; |
| 10386 | return 0; |
| 10387 | } |
| 10388 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10389 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10390 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10391 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10392 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10393 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10394 | 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] | 10395 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10396 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10397 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10398 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10399 | for ac_func in setpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10400 | do : |
| 10401 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
| 10402 | if test "x$ac_cv_func_setpgrp" = x""yes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10403 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10404 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10405 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10406 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10407 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10408 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10409 | int |
| 10410 | main () |
| 10411 | { |
| 10412 | setpgrp(0,0); |
| 10413 | ; |
| 10414 | return 0; |
| 10415 | } |
| 10416 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10417 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10418 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10419 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10420 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10421 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10422 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10423 | |
| 10424 | fi |
| 10425 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10426 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10427 | for ac_func in gettimeofday |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10428 | do : |
| 10429 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
| 10430 | if test "x$ac_cv_func_gettimeofday" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10431 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10432 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10433 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10435 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10436 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10437 | int |
| 10438 | main () |
| 10439 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10440 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10441 | ; |
| 10442 | return 0; |
| 10443 | } |
| 10444 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10445 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10446 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10447 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10448 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10449 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10450 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10451 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10452 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10453 | 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] | 10454 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10455 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10456 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10457 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10458 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10459 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 10460 | $as_echo_n "checking for major... " >&6; } |
| 10461 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10462 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10463 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 10464 | #if defined(MAJOR_IN_MKDEV) |
| 10465 | #include <sys/mkdev.h> |
| 10466 | #elif defined(MAJOR_IN_SYSMACROS) |
| 10467 | #include <sys/sysmacros.h> |
| 10468 | #else |
| 10469 | #include <sys/types.h> |
| 10470 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10471 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10472 | int |
| 10473 | main () |
| 10474 | { |
| 10475 | |
| 10476 | makedev(major(0),minor(0)); |
| 10477 | |
| 10478 | ; |
| 10479 | return 0; |
| 10480 | } |
| 10481 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10482 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10483 | |
| 10484 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10485 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10486 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10488 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10489 | |
| 10490 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10491 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10492 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10493 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10494 | |
| 10495 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10496 | rm -f core conftest.err conftest.$ac_objext \ |
| 10497 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10498 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10499 | # 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] | 10500 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10501 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 10502 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 10503 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10504 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10505 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10506 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10507 | #include <sys/socket.h> |
| 10508 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10509 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10510 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10511 | int |
| 10512 | main () |
| 10513 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10514 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10515 | ; |
| 10516 | return 0; |
| 10517 | } |
| 10518 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10519 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10520 | have_getaddrinfo=yes |
| 10521 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10522 | have_getaddrinfo=no |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10523 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10524 | rm -f core conftest.err conftest.$ac_objext \ |
| 10525 | conftest$ac_exeext conftest.$ac_ext |
| 10526 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 10527 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10528 | if test $have_getaddrinfo = yes |
| 10529 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10530 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 10531 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
| 10532 | if test "${ac_cv_buggy_getaddrinfo+set}" = set; then : |
| 10533 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10534 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10535 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10536 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10537 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10538 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10539 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10540 | |
| 10541 | #include <sys/types.h> |
| 10542 | #include <netdb.h> |
| 10543 | #include <string.h> |
| 10544 | #include <sys/socket.h> |
| 10545 | #include <netinet/in.h> |
| 10546 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10547 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10548 | { |
| 10549 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 10550 | struct addrinfo hints, *ai, *aitop; |
| 10551 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 10552 | |
| 10553 | for (passive = 0; passive <= 1; passive++) { |
| 10554 | memset(&hints, 0, sizeof(hints)); |
| 10555 | hints.ai_family = AF_UNSPEC; |
| 10556 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 10557 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 10558 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10559 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 10560 | (void)gai_strerror(gaierr); |
| 10561 | goto bad; |
| 10562 | } |
| 10563 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 10564 | if (ai->ai_addr == NULL || |
| 10565 | ai->ai_addrlen == 0 || |
| 10566 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 10567 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 10568 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 10569 | goto bad; |
| 10570 | } |
| 10571 | switch (ai->ai_family) { |
| 10572 | case AF_INET: |
| 10573 | if (strcmp(strport, "54321") != 0) { |
| 10574 | goto bad; |
| 10575 | } |
| 10576 | if (passive) { |
| 10577 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 10578 | goto bad; |
| 10579 | } |
| 10580 | } else { |
| 10581 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 10582 | goto bad; |
| 10583 | } |
| 10584 | } |
| 10585 | inet4++; |
| 10586 | break; |
| 10587 | case AF_INET6: |
| 10588 | if (strcmp(strport, "54321") != 0) { |
| 10589 | goto bad; |
| 10590 | } |
| 10591 | if (passive) { |
| 10592 | if (strcmp(straddr, "::") != 0) { |
| 10593 | goto bad; |
| 10594 | } |
| 10595 | } else { |
| 10596 | if (strcmp(straddr, "::1") != 0) { |
| 10597 | goto bad; |
| 10598 | } |
| 10599 | } |
| 10600 | inet6++; |
| 10601 | break; |
| 10602 | case AF_UNSPEC: |
| 10603 | goto bad; |
| 10604 | break; |
| 10605 | default: |
| 10606 | /* another family support? */ |
| 10607 | break; |
| 10608 | } |
| 10609 | } |
| 10610 | } |
| 10611 | |
| 10612 | if (!(inet4 == 0 || inet4 == 2)) |
| 10613 | goto bad; |
| 10614 | if (!(inet6 == 0 || inet6 == 2)) |
| 10615 | goto bad; |
| 10616 | |
| 10617 | if (aitop) |
| 10618 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10619 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10620 | |
| 10621 | bad: |
| 10622 | if (aitop) |
| 10623 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10624 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10625 | } |
| 10626 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10627 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10628 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10629 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10630 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10631 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10632 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10633 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10634 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10635 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10636 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10637 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10638 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10639 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10640 | |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 10641 | if test $have_getaddrinfo = no -o "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10642 | then |
| 10643 | if test $ipv6 = yes |
| 10644 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10645 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 10646 | echo ' or you can specify "--disable-ipv6"'. |
| 10647 | exit 1 |
| 10648 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10649 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10650 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10651 | $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10652 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10653 | fi |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 10654 | for ac_func in getnameinfo |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10655 | do : |
| 10656 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
| 10657 | if test "x$ac_cv_func_getnameinfo" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10658 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10659 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10660 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10661 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10662 | fi |
| 10663 | done |
| 10664 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10665 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10666 | # checks for structures |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10667 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 10668 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
| 10669 | if test "${ac_cv_header_time+set}" = set; then : |
| 10670 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10671 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10672 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10673 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10674 | #include <sys/types.h> |
| 10675 | #include <sys/time.h> |
| 10676 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10677 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10678 | int |
| 10679 | main () |
| 10680 | { |
| 10681 | if ((struct tm *) 0) |
| 10682 | return 0; |
| 10683 | ; |
| 10684 | return 0; |
| 10685 | } |
| 10686 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10687 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10688 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10689 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10690 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10691 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10692 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10693 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10694 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 10695 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10696 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10697 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10698 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10699 | |
| 10700 | fi |
| 10701 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10702 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 10703 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
| 10704 | if test "${ac_cv_struct_tm+set}" = set; then : |
| 10705 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10706 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10707 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10708 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10709 | #include <sys/types.h> |
| 10710 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10711 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10712 | int |
| 10713 | main () |
| 10714 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10715 | struct tm tm; |
| 10716 | int *p = &tm.tm_sec; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10717 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10718 | ; |
| 10719 | return 0; |
| 10720 | } |
| 10721 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10722 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10723 | ac_cv_struct_tm=time.h |
| 10724 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10725 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10726 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10727 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10728 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10729 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
| 10730 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10731 | if test $ac_cv_struct_tm = sys/time.h; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10732 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10733 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10734 | |
| 10735 | fi |
| 10736 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10737 | 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] | 10738 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10739 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10740 | " |
| 10741 | 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] | 10742 | |
| 10743 | cat >>confdefs.h <<_ACEOF |
| 10744 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 10745 | _ACEOF |
| 10746 | |
| 10747 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10748 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10749 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10750 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 10751 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10752 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10753 | |
| 10754 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10755 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 10756 | " |
| 10757 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
| 10758 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10759 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10760 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10761 | fi |
| 10762 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10763 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10764 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10765 | _ACEOF |
| 10766 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10767 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 10768 | $as_echo_n "checking for tzname... " >&6; } |
| 10769 | if test "${ac_cv_var_tzname+set}" = set; then : |
| 10770 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10771 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10772 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10773 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10774 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10775 | #if !HAVE_DECL_TZNAME |
| 10776 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10777 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10778 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10779 | int |
| 10780 | main () |
| 10781 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10782 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10783 | ; |
| 10784 | return 0; |
| 10785 | } |
| 10786 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10787 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10788 | ac_cv_var_tzname=yes |
| 10789 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10790 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10791 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10792 | rm -f core conftest.err conftest.$ac_objext \ |
| 10793 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10794 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 10796 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10797 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10798 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10799 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10800 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10801 | fi |
| 10802 | fi |
| 10803 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10804 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
| 10805 | 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] | 10806 | |
| 10807 | cat >>confdefs.h <<_ACEOF |
| 10808 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 10809 | _ACEOF |
| 10810 | |
| 10811 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10812 | fi |
| 10813 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10814 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
| 10815 | 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] | 10816 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10817 | cat >>confdefs.h <<_ACEOF |
| 10818 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 10819 | _ACEOF |
| 10820 | |
| 10821 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10822 | fi |
| 10823 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10824 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
| 10825 | 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] | 10826 | |
| 10827 | cat >>confdefs.h <<_ACEOF |
| 10828 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 10829 | _ACEOF |
| 10830 | |
| 10831 | |
| 10832 | fi |
| 10833 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10834 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
| 10835 | 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] | 10836 | |
| 10837 | cat >>confdefs.h <<_ACEOF |
| 10838 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 10839 | _ACEOF |
| 10840 | |
| 10841 | |
| 10842 | fi |
| 10843 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10844 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
| 10845 | 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] | 10846 | |
| 10847 | cat >>confdefs.h <<_ACEOF |
| 10848 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 10849 | _ACEOF |
| 10850 | |
| 10851 | |
| 10852 | fi |
| 10853 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10854 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
| 10855 | 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] | 10856 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10857 | cat >>confdefs.h <<_ACEOF |
| 10858 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 10859 | _ACEOF |
| 10860 | |
| 10861 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10862 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10863 | |
| 10864 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10865 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10866 | *" fileblocks.$ac_objext "* ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10867 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 10868 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10869 | esac |
| 10870 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10871 | fi |
| 10872 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10873 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10874 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 10876 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
| 10877 | if test "${ac_cv_header_time_altzone+set}" = set; then : |
| 10878 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10879 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10880 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10881 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10882 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10883 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10884 | int |
| 10885 | main () |
| 10886 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10887 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10888 | ; |
| 10889 | return 0; |
| 10890 | } |
| 10891 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10892 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10893 | ac_cv_header_time_altzone=yes |
| 10894 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10895 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10896 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10897 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10898 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10899 | fi |
| 10900 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 10902 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10903 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10904 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10905 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10906 | |
| 10907 | fi |
| 10908 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 10909 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10910 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 10911 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 10912 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10913 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10914 | |
| 10915 | #include <sys/types.h> |
| 10916 | #include <sys/select.h> |
| 10917 | #include <sys/time.h> |
| 10918 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10919 | int |
| 10920 | main () |
| 10921 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10922 | ; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10923 | ; |
| 10924 | return 0; |
| 10925 | } |
| 10926 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10927 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10928 | |
| 10929 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10930 | $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] | 10931 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 10932 | was_it_defined=yes |
| 10933 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10934 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10935 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10936 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 10937 | $as_echo "$was_it_defined" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10938 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10939 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 10940 | $as_echo_n "checking for addrinfo... " >&6; } |
| 10941 | if test "${ac_cv_struct_addrinfo+set}" = set; then : |
| 10942 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10943 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10944 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10945 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10946 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10947 | int |
| 10948 | main () |
| 10949 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10950 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10951 | ; |
| 10952 | return 0; |
| 10953 | } |
| 10954 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10955 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10956 | ac_cv_struct_addrinfo=yes |
| 10957 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10958 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10959 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10960 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 10961 | fi |
| 10962 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10963 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 10964 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10965 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10966 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10967 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10968 | |
| 10969 | fi |
| 10970 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10971 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 10972 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
| 10973 | if test "${ac_cv_struct_sockaddr_storage+set}" = set; then : |
| 10974 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10975 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10976 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10977 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10978 | |
| 10979 | # include <sys/types.h> |
| 10980 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10981 | int |
| 10982 | main () |
| 10983 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10984 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10985 | ; |
| 10986 | return 0; |
| 10987 | } |
| 10988 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10989 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10990 | ac_cv_struct_sockaddr_storage=yes |
| 10991 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10992 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10993 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10994 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 10995 | fi |
| 10996 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10997 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 10998 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10999 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11000 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11001 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11002 | |
| 11003 | fi |
| 11004 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11005 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11006 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11007 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 11008 | $as_echo_n "checking whether char is unsigned... " >&6; } |
| 11009 | if test "${ac_cv_c_char_unsigned+set}" = set; then : |
| 11010 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11011 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11013 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11014 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11015 | int |
| 11016 | main () |
| 11017 | { |
| 11018 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
| 11019 | test_array [0] = 0 |
| 11020 | |
| 11021 | ; |
| 11022 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11023 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11024 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11025 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11026 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11027 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11028 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11029 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11030 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11031 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11032 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 11033 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11034 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11035 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11036 | |
| 11037 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11038 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11039 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 11040 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
| 11041 | if test "${ac_cv_c_const+set}" = set; then : |
| 11042 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11043 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11044 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11045 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11046 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11047 | int |
| 11048 | main () |
| 11049 | { |
| 11050 | /* FIXME: Include the comments suggested by Paul. */ |
| 11051 | #ifndef __cplusplus |
| 11052 | /* Ultrix mips cc rejects this. */ |
| 11053 | typedef int charset[2]; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11054 | const charset cs; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11055 | /* SunOS 4.1.1 cc rejects this. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11056 | char const *const *pcpcc; |
| 11057 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11058 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 11059 | struct point {int x, y;}; |
| 11060 | static struct point const zero = {0,0}; |
| 11061 | /* AIX XL C 1.02.0.0 rejects this. |
| 11062 | It does not let you subtract one const X* pointer from another in |
| 11063 | an arm of an if-expression whose if-part is not a constant |
| 11064 | expression */ |
| 11065 | const char *g = "string"; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11066 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11067 | /* HPUX 7.0 cc rejects these. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11068 | ++pcpcc; |
| 11069 | ppc = (char**) pcpcc; |
| 11070 | pcpcc = (char const *const *) ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11071 | { /* SCO 3.2v4 cc rejects this. */ |
| 11072 | char *t; |
| 11073 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11074 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11075 | *t++ = 0; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11076 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11077 | } |
| 11078 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 11079 | int x[] = {25, 17}; |
| 11080 | const int *foo = &x[0]; |
| 11081 | ++foo; |
| 11082 | } |
| 11083 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 11084 | typedef const int *iptr; |
| 11085 | iptr p = 0; |
| 11086 | ++p; |
| 11087 | } |
| 11088 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 11089 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 11090 | struct s { int j; const int *ap[3]; }; |
| 11091 | struct s *b; b->j = 5; |
| 11092 | } |
| 11093 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 11094 | const int foo = 10; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11095 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11096 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11097 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11098 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11099 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11100 | ; |
| 11101 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11102 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11103 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11104 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11105 | ac_cv_c_const=yes |
| 11106 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11107 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11108 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11109 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11110 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11111 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 11112 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11113 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11114 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11115 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11116 | |
| 11117 | fi |
| 11118 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11119 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11120 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11121 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 11122 | $as_echo_n "checking for working volatile... " >&6; } |
| 11123 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11124 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11125 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11126 | int |
| 11127 | main () |
| 11128 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11129 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11130 | ; |
| 11131 | return 0; |
| 11132 | } |
| 11133 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11134 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11135 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11136 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11137 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11138 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11139 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11140 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11141 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11142 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11143 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11144 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11145 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11146 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 11148 | $as_echo_n "checking for working signed char... " >&6; } |
| 11149 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11150 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11151 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11152 | int |
| 11153 | main () |
| 11154 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11155 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11156 | ; |
| 11157 | return 0; |
| 11158 | } |
| 11159 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11160 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11161 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11162 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11163 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11164 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11165 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11166 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11167 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11168 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11169 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11170 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11171 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11172 | have_prototypes=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11173 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 11174 | $as_echo_n "checking for prototypes... " >&6; } |
| 11175 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11176 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11177 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11178 | int |
| 11179 | main () |
| 11180 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11181 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11182 | ; |
| 11183 | return 0; |
| 11184 | } |
| 11185 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11186 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11187 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11188 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11189 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11190 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11191 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11192 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11193 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 11194 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11195 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11196 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 11198 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 11199 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11200 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11201 | |
| 11202 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11203 | int foo(int x, ...) { |
| 11204 | va_list va; |
| 11205 | va_start(va, x); |
| 11206 | va_arg(va, int); |
| 11207 | va_arg(va, char *); |
| 11208 | va_arg(va, double); |
| 11209 | return 0; |
| 11210 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11211 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11212 | int |
| 11213 | main () |
| 11214 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11215 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11216 | ; |
| 11217 | return 0; |
| 11218 | } |
| 11219 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11220 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11221 | |
| 11222 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11223 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11224 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11225 | works=yes |
| 11226 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11227 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11228 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11229 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11230 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11231 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11232 | # check for socketpair |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11233 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 11234 | $as_echo_n "checking for socketpair... " >&6; } |
| 11235 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11236 | /* end confdefs.h. */ |
| 11237 | |
| 11238 | #include <sys/types.h> |
| 11239 | #include <sys/socket.h> |
| 11240 | |
| 11241 | int |
| 11242 | main () |
| 11243 | { |
| 11244 | void *x=socketpair |
| 11245 | ; |
| 11246 | return 0; |
| 11247 | } |
| 11248 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11249 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11250 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11251 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11252 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11254 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11255 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11257 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11258 | |
| 11259 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11260 | 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] | 11261 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11262 | # check if sockaddr has sa_len member |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11263 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 11264 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 11265 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11266 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11267 | #include <sys/types.h> |
| 11268 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11269 | int |
| 11270 | main () |
| 11271 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11272 | struct sockaddr x; |
| 11273 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11274 | ; |
| 11275 | return 0; |
| 11276 | } |
| 11277 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11278 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11279 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11280 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11281 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11282 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11283 | |
| 11284 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11285 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11286 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11287 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11288 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11289 | 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] | 11290 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11291 | va_list_is_array=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 11293 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 11294 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11295 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11296 | |
| 11297 | #ifdef HAVE_STDARG_PROTOTYPES |
| 11298 | #include <stdarg.h> |
| 11299 | #else |
| 11300 | #include <varargs.h> |
| 11301 | #endif |
| 11302 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11303 | int |
| 11304 | main () |
| 11305 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11306 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11307 | ; |
| 11308 | return 0; |
| 11309 | } |
| 11310 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11311 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11312 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11313 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11314 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11315 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11316 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11317 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11318 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11319 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11320 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11321 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11322 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 11323 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11324 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11325 | # 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] | 11326 | |
| 11327 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11328 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
| 11329 | 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] | 11330 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11331 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 11332 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11333 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 11334 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11335 | OLD_CFLAGS=$CFLAGS |
| 11336 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11337 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11338 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11339 | |
| 11340 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11341 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11342 | int |
| 11343 | main () |
| 11344 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11345 | |
| 11346 | char *name; |
| 11347 | struct hostent *he, *res; |
| 11348 | char buffer[2048]; |
| 11349 | int buflen = 2048; |
| 11350 | int h_errnop; |
| 11351 | |
| 11352 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11353 | |
| 11354 | ; |
| 11355 | return 0; |
| 11356 | } |
| 11357 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11358 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11359 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11360 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11361 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11362 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11363 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11364 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11365 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11366 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11367 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11368 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11369 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11371 | $as_echo "no" >&6; } |
| 11372 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 11373 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 11374 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11375 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11376 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11377 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11378 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11379 | int |
| 11380 | main () |
| 11381 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11382 | |
| 11383 | char *name; |
| 11384 | struct hostent *he; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11385 | char buffer[2048]; |
| 11386 | int buflen = 2048; |
| 11387 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11388 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11389 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11390 | |
| 11391 | ; |
| 11392 | return 0; |
| 11393 | } |
| 11394 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11395 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11396 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11397 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11398 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11399 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11400 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11401 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11403 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11404 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11405 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11406 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11407 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11408 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11409 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 11410 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 11411 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11412 | /* end confdefs.h. */ |
| 11413 | |
| 11414 | # include <netdb.h> |
| 11415 | |
| 11416 | int |
| 11417 | main () |
| 11418 | { |
| 11419 | |
| 11420 | char *name; |
| 11421 | struct hostent *he; |
| 11422 | struct hostent_data data; |
| 11423 | |
| 11424 | (void) gethostbyname_r(name, he, &data); |
| 11425 | |
| 11426 | ; |
| 11427 | return 0; |
| 11428 | } |
| 11429 | _ACEOF |
| 11430 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11431 | |
| 11432 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 11433 | |
| 11434 | |
| 11435 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 11436 | |
| 11437 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11438 | $as_echo "yes" >&6; } |
| 11439 | |
| 11440 | else |
| 11441 | |
| 11442 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11443 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11444 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11445 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11446 | 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] | 11447 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11448 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11449 | 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] | 11450 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11451 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11452 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11453 | CFLAGS=$OLD_CFLAGS |
| 11454 | |
| 11455 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11457 | for ac_func in gethostbyname |
| 11458 | do : |
| 11459 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
| 11460 | if test "x$ac_cv_func_gethostbyname" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11461 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11462 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11463 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11464 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11465 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11466 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11467 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11468 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11469 | fi |
| 11470 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11471 | |
| 11472 | |
| 11473 | |
| 11474 | |
| 11475 | |
| 11476 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11477 | # checks for system services |
| 11478 | # (none yet) |
| 11479 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11480 | # Linux requires this for correct f.p. operations |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11481 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
| 11482 | if test "x$ac_cv_func___fpu_control" = x""yes; then : |
| 11483 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11484 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11485 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 11486 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
| 11487 | if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then : |
| 11488 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11489 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11490 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11491 | LIBS="-lieee $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11492 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11493 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11494 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11495 | /* Override any GCC internal prototype to avoid an error. |
| 11496 | Use char because int might match the return type of a GCC |
| 11497 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11498 | #ifdef __cplusplus |
| 11499 | extern "C" |
| 11500 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11501 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11502 | int |
| 11503 | main () |
| 11504 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11505 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11506 | ; |
| 11507 | return 0; |
| 11508 | } |
| 11509 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11510 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11511 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11512 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11513 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11514 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11515 | rm -f core conftest.err conftest.$ac_objext \ |
| 11516 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11517 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11518 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11519 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 11520 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
| 11521 | 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] | 11522 | cat >>confdefs.h <<_ACEOF |
| 11523 | #define HAVE_LIBIEEE 1 |
| 11524 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11525 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11526 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11527 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11528 | fi |
| 11529 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11530 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11531 | fi |
| 11532 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11533 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11534 | # Check for --with-fpectl |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11535 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 11536 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11537 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11538 | # Check whether --with-fpectl was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11539 | if test "${with_fpectl+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11540 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11541 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11542 | then |
| 11543 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11544 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11545 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11546 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11547 | $as_echo "yes" >&6; } |
| 11548 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11549 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11550 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 11551 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11552 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11553 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11554 | fi |
| 11555 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11556 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11557 | # check for --with-libm=... |
| 11558 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11559 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 11560 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11561 | *) LIBM=-lm |
| 11562 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11563 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 11564 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11565 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11566 | # Check whether --with-libm was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11567 | if test "${with_libm+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11568 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11569 | if test "$withval" = no |
| 11570 | then LIBM= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 11572 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11573 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11574 | then LIBM=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11575 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 11576 | $as_echo "set LIBM=\"$withval\"" >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 11577 | 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] | 11578 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11579 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11580 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 11581 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11582 | fi |
| 11583 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11584 | |
| 11585 | # check for --with-libc=... |
| 11586 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11587 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 11588 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11589 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11590 | # Check whether --with-libc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11591 | if test "${with_libc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11592 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11593 | if test "$withval" = no |
| 11594 | then LIBC= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 11596 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11597 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11598 | then LIBC=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11599 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 11600 | $as_echo "set LIBC=\"$withval\"" >&6; } |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 11601 | 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] | 11602 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11603 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11604 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 11605 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11606 | fi |
| 11607 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11608 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11609 | # ************************************************** |
| 11610 | # * Check for various properties of floating point * |
| 11611 | # ************************************************** |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11612 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11613 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 11614 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
| 11615 | if test "${ac_cv_little_endian_double+set}" = set; then : |
| 11616 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11617 | else |
| 11618 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11619 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11620 | ac_cv_little_endian_double=no |
| 11621 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11622 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11623 | /* end confdefs.h. */ |
| 11624 | |
| 11625 | #include <string.h> |
| 11626 | int main() { |
| 11627 | double x = 9006104071832581.0; |
| 11628 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 11629 | return 0; |
| 11630 | else |
| 11631 | return 1; |
| 11632 | } |
| 11633 | |
| 11634 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11635 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11636 | ac_cv_little_endian_double=yes |
| 11637 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11638 | ac_cv_little_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11639 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11640 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11641 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11642 | fi |
| 11643 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11644 | fi |
| 11645 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11646 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 11647 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11648 | if test "$ac_cv_little_endian_double" = yes |
| 11649 | then |
| 11650 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11651 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11652 | |
| 11653 | fi |
| 11654 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11655 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 11656 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
| 11657 | if test "${ac_cv_big_endian_double+set}" = set; then : |
| 11658 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11659 | else |
| 11660 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11661 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11662 | ac_cv_big_endian_double=no |
| 11663 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11664 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11665 | /* end confdefs.h. */ |
| 11666 | |
| 11667 | #include <string.h> |
| 11668 | int main() { |
| 11669 | double x = 9006104071832581.0; |
| 11670 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 11671 | return 0; |
| 11672 | else |
| 11673 | return 1; |
| 11674 | } |
| 11675 | |
| 11676 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11677 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11678 | ac_cv_big_endian_double=yes |
| 11679 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11680 | ac_cv_big_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11681 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11682 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11683 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11684 | fi |
| 11685 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11686 | fi |
| 11687 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11688 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 11689 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11690 | if test "$ac_cv_big_endian_double" = yes |
| 11691 | then |
| 11692 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11693 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11694 | |
| 11695 | fi |
| 11696 | |
| 11697 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 11698 | # While Python doesn't currently have full support for these platforms |
| 11699 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 11700 | # conversions work. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11701 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 11702 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
| 11703 | if test "${ac_cv_mixed_endian_double+set}" = set; then : |
| 11704 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11705 | else |
| 11706 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11707 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11708 | ac_cv_mixed_endian_double=no |
| 11709 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11710 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11711 | /* end confdefs.h. */ |
| 11712 | |
| 11713 | #include <string.h> |
| 11714 | int main() { |
| 11715 | double x = 9006104071832581.0; |
| 11716 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 11717 | return 0; |
| 11718 | else |
| 11719 | return 1; |
| 11720 | } |
| 11721 | |
| 11722 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11723 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11724 | ac_cv_mixed_endian_double=yes |
| 11725 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11726 | ac_cv_mixed_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11727 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11728 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11729 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11730 | fi |
| 11731 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11732 | fi |
| 11733 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 11735 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11736 | if test "$ac_cv_mixed_endian_double" = yes |
| 11737 | then |
| 11738 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11739 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11740 | |
| 11741 | fi |
| 11742 | |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11743 | # The short float repr introduced in Python 3.1 requires the |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 11744 | # correctly-rounded string <-> double conversion functions from |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11745 | # Python/dtoa.c, which in turn require that the FPU uses 53-bit |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 11746 | # rounding; this is a problem on x86, where the x87 FPU has a default |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11747 | # rounding precision of 64 bits. For gcc/x86, we can fix this by |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 11748 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11749 | |
| 11750 | # This inline assembler syntax may also work for suncc and icc, |
| 11751 | # so we try it on all platforms. |
| 11752 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 11754 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 11755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11756 | /* end confdefs.h. */ |
| 11757 | |
| 11758 | int |
| 11759 | main () |
| 11760 | { |
| 11761 | |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11762 | unsigned short cw; |
| 11763 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 11764 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11765 | |
| 11766 | ; |
| 11767 | return 0; |
| 11768 | } |
| 11769 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11770 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11771 | have_gcc_asm_for_x87=yes |
| 11772 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11773 | have_gcc_asm_for_x87=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11774 | fi |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11775 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11776 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 11777 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11778 | if test "$have_gcc_asm_for_x87" = yes |
| 11779 | then |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11780 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11781 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11782 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11783 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11784 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11785 | # Detect whether system arithmetic is subject to x87-style double |
| 11786 | # rounding issues. The result of this test has little meaning on non |
| 11787 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 11788 | # mode is round-to-nearest and double rounding issues are present, and |
| 11789 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11790 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 11791 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11792 | # $BASECFLAGS may affect the result |
| 11793 | ac_save_cc="$CC" |
| 11794 | CC="$CC $BASECFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11795 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11796 | ac_cv_x87_double_rounding=no |
| 11797 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11798 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11799 | /* end confdefs.h. */ |
| 11800 | |
| 11801 | #include <stdlib.h> |
| 11802 | #include <math.h> |
| 11803 | int main() { |
| 11804 | volatile double x, y, z; |
| 11805 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 11806 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 11807 | y = 1./x; |
| 11808 | if (y != 1.) |
| 11809 | exit(0); |
| 11810 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 11811 | x = 1e16; |
| 11812 | y = 2.99999; |
| 11813 | z = x + y; |
| 11814 | if (z != 1e16+4.) |
| 11815 | exit(0); |
| 11816 | /* both tests show evidence of double rounding */ |
| 11817 | exit(1); |
| 11818 | } |
| 11819 | |
| 11820 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11821 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11822 | ac_cv_x87_double_rounding=no |
| 11823 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11824 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11825 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11826 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11827 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11828 | fi |
| 11829 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11830 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11831 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 11832 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11833 | if test "$ac_cv_x87_double_rounding" = yes |
| 11834 | then |
| 11835 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11836 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11837 | |
| 11838 | fi |
| 11839 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11840 | # ************************************ |
| 11841 | # * Check for mathematical functions * |
| 11842 | # ************************************ |
| 11843 | |
| 11844 | LIBS_SAVE=$LIBS |
| 11845 | LIBS="$LIBS $LIBM" |
| 11846 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11847 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 11848 | # -0. on some architectures. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11849 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 11850 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
| 11851 | if test "${ac_cv_tanh_preserves_zero_sign+set}" = set; then : |
| 11852 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11853 | else |
| 11854 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11855 | if test "$cross_compiling" = yes; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11856 | ac_cv_tanh_preserves_zero_sign=no |
| 11857 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11858 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11859 | /* end confdefs.h. */ |
| 11860 | |
| 11861 | #include <math.h> |
| 11862 | #include <stdlib.h> |
| 11863 | int main() { |
| 11864 | /* return 0 if either negative zeros don't exist |
| 11865 | on this platform or if negative zeros exist |
| 11866 | and tanh(-0.) == -0. */ |
| 11867 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 11868 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 11869 | else exit(1); |
| 11870 | } |
| 11871 | |
| 11872 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11873 | if ac_fn_c_try_run "$LINENO"; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11874 | ac_cv_tanh_preserves_zero_sign=yes |
| 11875 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11876 | ac_cv_tanh_preserves_zero_sign=no |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11877 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11878 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11879 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11880 | fi |
| 11881 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11882 | fi |
| 11883 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11884 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 11885 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11886 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 11887 | then |
| 11888 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11889 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11890 | |
| 11891 | fi |
| 11892 | |
Mark Dickinson | 9c11336 | 2009-09-05 10:36:23 +0000 | [diff] [blame] | 11893 | for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11894 | do : |
| 11895 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11896 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 11897 | eval as_val=\$$as_ac_var |
| 11898 | if test "x$as_val" = x""yes; then : |
Mark Dickinson | 9c11336 | 2009-09-05 10:36:23 +0000 | [diff] [blame] | 11899 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11900 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Mark Dickinson | 9c11336 | 2009-09-05 10:36:23 +0000 | [diff] [blame] | 11901 | _ACEOF |
| 11902 | |
| 11903 | fi |
| 11904 | done |
| 11905 | |
Mark Dickinson | 9c11336 | 2009-09-05 10:36:23 +0000 | [diff] [blame] | 11906 | for ac_func in hypot lgamma log1p round tgamma |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11907 | do : |
| 11908 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11909 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 11910 | eval as_val=\$$as_ac_var |
| 11911 | if test "x$as_val" = x""yes; then : |
Christian Heimes | 99170a5 | 2007-12-19 02:07:34 +0000 | [diff] [blame] | 11912 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11913 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Christian Heimes | 99170a5 | 2007-12-19 02:07:34 +0000 | [diff] [blame] | 11914 | _ACEOF |
| 11915 | |
| 11916 | fi |
| 11917 | done |
| 11918 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11919 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 11920 | " |
| 11921 | if test "x$ac_cv_have_decl_isinf" = x""yes; then : |
| 11922 | ac_have_decl=1 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11923 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11924 | ac_have_decl=0 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11925 | fi |
| 11926 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11927 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11928 | #define HAVE_DECL_ISINF $ac_have_decl |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11929 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11930 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 11931 | " |
| 11932 | if test "x$ac_cv_have_decl_isnan" = x""yes; then : |
| 11933 | ac_have_decl=1 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11934 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11935 | ac_have_decl=0 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11936 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11937 | |
| 11938 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11939 | #define HAVE_DECL_ISNAN $ac_have_decl |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11940 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11941 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 11942 | " |
| 11943 | if test "x$ac_cv_have_decl_isfinite" = x""yes; then : |
| 11944 | ac_have_decl=1 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11945 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11946 | ac_have_decl=0 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11947 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11948 | |
| 11949 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11950 | #define HAVE_DECL_ISFINITE $ac_have_decl |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11951 | _ACEOF |
| 11952 | |
| 11953 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 11954 | LIBS=$LIBS_SAVE |
| 11955 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11956 | # For multiprocessing module, check that sem_open |
| 11957 | # actually works. For FreeBSD versions <= 7.2, |
| 11958 | # the kernel module that provides POSIX semaphores |
| 11959 | # isn't loaded by default, so an attempt to call |
| 11960 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11961 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 11962 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
| 11963 | if test "${ac_cv_posix_semaphores_enabled+set}" = set; then : |
| 11964 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11965 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11966 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11967 | ac_cv_posix_semaphores_enabled=yes |
| 11968 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11969 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11970 | /* end confdefs.h. */ |
| 11971 | |
| 11972 | #include <unistd.h> |
| 11973 | #include <fcntl.h> |
| 11974 | #include <stdio.h> |
| 11975 | #include <semaphore.h> |
| 11976 | #include <sys/stat.h> |
| 11977 | |
| 11978 | int main(void) { |
| 11979 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 11980 | if (a == SEM_FAILED) { |
| 11981 | perror("sem_open"); |
| 11982 | return 1; |
| 11983 | } |
| 11984 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 11985 | sem_unlink("/autoconf"); |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11986 | return 0; |
| 11987 | } |
| 11988 | |
| 11989 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11990 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11991 | ac_cv_posix_semaphores_enabled=yes |
| 11992 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11993 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11994 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11995 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11996 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 11997 | fi |
| 11998 | |
| 11999 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12000 | fi |
| 12001 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12002 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 12003 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12004 | if test $ac_cv_posix_semaphores_enabled = no |
| 12005 | then |
| 12006 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12007 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12008 | |
| 12009 | fi |
| 12010 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12011 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12012 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 12013 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
| 12014 | if test "${ac_cv_broken_sem_getvalue+set}" = set; then : |
| 12015 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12016 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12017 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12018 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12019 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12020 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12021 | /* end confdefs.h. */ |
| 12022 | |
| 12023 | #include <unistd.h> |
| 12024 | #include <fcntl.h> |
| 12025 | #include <stdio.h> |
| 12026 | #include <semaphore.h> |
| 12027 | #include <sys/stat.h> |
| 12028 | |
| 12029 | int main(void){ |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12030 | sem_t *a = sem_open("/autocftw", O_CREAT, S_IRUSR|S_IWUSR, 0); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12031 | int count; |
| 12032 | int res; |
| 12033 | if(a==SEM_FAILED){ |
| 12034 | perror("sem_open"); |
| 12035 | return 1; |
| 12036 | |
| 12037 | } |
| 12038 | res = sem_getvalue(a, &count); |
| 12039 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12040 | sem_unlink("/autocftw"); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12041 | return res==-1 ? 1 : 0; |
| 12042 | } |
| 12043 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12044 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12045 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12046 | ac_cv_broken_sem_getvalue=no |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12047 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12048 | ac_cv_broken_sem_getvalue=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12049 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12050 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12051 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 12052 | fi |
| 12053 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12054 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12055 | fi |
| 12056 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12057 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 12058 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12059 | if test $ac_cv_broken_sem_getvalue = yes |
| 12060 | then |
| 12061 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12062 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12063 | |
| 12064 | fi |
| 12065 | |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12066 | # determine what size digit to use for Python's longs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12067 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 12068 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12069 | # Check whether --enable-big-digits was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12070 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12071 | enableval=$enable_big_digits; case $enable_big_digits in |
| 12072 | yes) |
| 12073 | enable_big_digits=30 ;; |
| 12074 | no) |
| 12075 | enable_big_digits=15 ;; |
| 12076 | 15|30) |
| 12077 | ;; |
| 12078 | *) |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12079 | as_fn_error "bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" "$LINENO" 5 ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12080 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12081 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 12082 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12083 | |
| 12084 | cat >>confdefs.h <<_ACEOF |
| 12085 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 12086 | _ACEOF |
| 12087 | |
| 12088 | |
| 12089 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12090 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 12091 | $as_echo "no value specified" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12092 | fi |
| 12093 | |
| 12094 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12095 | # check for wchar.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12096 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
| 12097 | 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] | 12098 | |
| 12099 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12100 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12101 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12102 | wchar_h="yes" |
| 12103 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12104 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12105 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12106 | |
| 12107 | fi |
| 12108 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12109 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12110 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12111 | # determine wchar_t size |
| 12112 | if test "$wchar_h" = yes |
| 12113 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12114 | # The cast to long int works around a bug in the HP C Compiler |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12115 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 12116 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 12117 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12118 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 12119 | $as_echo_n "checking size of wchar_t... " >&6; } |
| 12120 | if test "${ac_cv_sizeof_wchar_t+set}" = set; then : |
| 12121 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12122 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12123 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 12124 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12125 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12126 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12127 | if test "$ac_cv_type_wchar_t" = yes; then |
| 12128 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 12129 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12130 | { as_fn_set_status 77 |
| 12131 | as_fn_error "cannot compute sizeof (wchar_t) |
| 12132 | See \`config.log' for more details." "$LINENO" 5; }; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12133 | else |
| 12134 | ac_cv_sizeof_wchar_t=0 |
| 12135 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12136 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12137 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12138 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12139 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 12140 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12141 | |
| 12142 | |
| 12143 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12144 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12145 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12146 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12147 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12148 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12149 | fi |
| 12150 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12151 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 12152 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12153 | have_ucs4_tcl=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12154 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12155 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12156 | |
| 12157 | #include <tcl.h> |
| 12158 | #if TCL_UTF_MAX != 6 |
| 12159 | # error "NOT UCS4_TCL" |
| 12160 | #endif |
| 12161 | int |
| 12162 | main () |
| 12163 | { |
| 12164 | |
| 12165 | ; |
| 12166 | return 0; |
| 12167 | } |
| 12168 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12169 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12170 | |
| 12171 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12172 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12173 | |
| 12174 | have_ucs4_tcl=yes |
| 12175 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12176 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12177 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 12179 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12180 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12181 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12182 | if test "$wchar_h" = yes |
| 12183 | then |
| 12184 | # check whether wchar_t is signed or not |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 12186 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
| 12187 | if test "${ac_cv_wchar_t_signed+set}" = set; then : |
| 12188 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12189 | else |
| 12190 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12191 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12192 | ac_cv_wchar_t_signed=yes |
| 12193 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12194 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12195 | /* end confdefs.h. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12196 | |
| 12197 | #include <wchar.h> |
| 12198 | int main() |
| 12199 | { |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 12200 | /* Success: exit code 0 */ |
| 12201 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12202 | } |
| 12203 | |
| 12204 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12205 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12206 | ac_cv_wchar_t_signed=yes |
| 12207 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12208 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12209 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12210 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12211 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12212 | fi |
| 12213 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12214 | fi |
| 12215 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12216 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 12217 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12218 | fi |
| 12219 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12220 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type to use for str" >&5 |
| 12221 | $as_echo_n "checking what type to use for str... " >&6; } |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12222 | |
| 12223 | # Check whether --with-wide-unicode was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12224 | if test "${with_wide_unicode+set}" = set; then : |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12225 | withval=$with_wide_unicode; |
| 12226 | if test "$withval" != no |
| 12227 | then unicode_size="4" |
| 12228 | else unicode_size="2" |
| 12229 | fi |
| 12230 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12231 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12232 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12233 | case "$have_ucs4_tcl" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12234 | yes) unicode_size="4";; |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12235 | *) unicode_size="2" ;; |
| 12236 | esac |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12237 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12238 | fi |
| 12239 | |
Martin v. Löwis | 0036cba | 2002-04-12 09:58:45 +0000 | [diff] [blame] | 12240 | |
| 12241 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12242 | case "$unicode_size" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12243 | 4) |
| 12244 | $as_echo "#define Py_UNICODE_SIZE 4" >>confdefs.h |
| 12245 | |
| 12246 | SOABI_QUALIFIERS="${SOABI_QUALIFIERS}u" |
| 12247 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12248 | *) $as_echo "#define Py_UNICODE_SIZE 2" >>confdefs.h |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12249 | ;; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12250 | esac |
| 12251 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12252 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12253 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12254 | # wchar_t is only usable if it maps to an unsigned type |
| 12255 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 12256 | -a "$ac_cv_wchar_t_signed" = "no" |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12257 | then |
| 12258 | PY_UNICODE_TYPE="wchar_t" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12259 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12260 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12261 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12262 | $as_echo "#define PY_UNICODE_TYPE wchar_t" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12263 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12264 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 12265 | then |
| 12266 | PY_UNICODE_TYPE="unsigned short" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12267 | $as_echo "#define PY_UNICODE_TYPE unsigned short" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12268 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12269 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 12270 | then |
| 12271 | PY_UNICODE_TYPE="unsigned long" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12272 | $as_echo "#define PY_UNICODE_TYPE unsigned long" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12273 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12274 | else |
| 12275 | PY_UNICODE_TYPE="no type found" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12276 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PY_UNICODE_TYPE" >&5 |
| 12278 | $as_echo "$PY_UNICODE_TYPE" >&6; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12279 | |
| 12280 | # check for endianness |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 12282 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
| 12283 | if test "${ac_cv_c_bigendian+set}" = set; then : |
| 12284 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12285 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12286 | ac_cv_c_bigendian=unknown |
| 12287 | # See if we're dealing with a universal compiler. |
| 12288 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12289 | /* end confdefs.h. */ |
| 12290 | #ifndef __APPLE_CC__ |
| 12291 | not a universal capable compiler |
| 12292 | #endif |
| 12293 | typedef int dummy; |
| 12294 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12295 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12296 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12297 | |
| 12298 | # Check for potential -arch flags. It is not universal unless |
| 12299 | # there are at least two -arch flags with different values. |
| 12300 | ac_arch= |
| 12301 | ac_prev= |
| 12302 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 12303 | if test -n "$ac_prev"; then |
| 12304 | case $ac_word in |
| 12305 | i?86 | x86_64 | ppc | ppc64) |
| 12306 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 12307 | ac_arch=$ac_word |
| 12308 | else |
| 12309 | ac_cv_c_bigendian=universal |
| 12310 | break |
| 12311 | fi |
| 12312 | ;; |
| 12313 | esac |
| 12314 | ac_prev= |
| 12315 | elif test "x$ac_word" = "x-arch"; then |
| 12316 | ac_prev=arch |
| 12317 | fi |
| 12318 | done |
| 12319 | fi |
| 12320 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12321 | if test $ac_cv_c_bigendian = unknown; then |
| 12322 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 12323 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12324 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12325 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12326 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12327 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12328 | int |
| 12329 | main () |
| 12330 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12331 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 12332 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 12333 | && LITTLE_ENDIAN) |
| 12334 | bogus endian macros |
| 12335 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12336 | |
| 12337 | ; |
| 12338 | return 0; |
| 12339 | } |
| 12340 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12341 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12342 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12343 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12344 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12345 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12346 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12347 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12348 | int |
| 12349 | main () |
| 12350 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12351 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12352 | not big endian |
| 12353 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12354 | |
| 12355 | ; |
| 12356 | return 0; |
| 12357 | } |
| 12358 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12359 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12360 | ac_cv_c_bigendian=yes |
| 12361 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12362 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12363 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12364 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12365 | fi |
| 12366 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12367 | fi |
| 12368 | if test $ac_cv_c_bigendian = unknown; then |
| 12369 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 12370 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12371 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12372 | #include <limits.h> |
| 12373 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12374 | int |
| 12375 | main () |
| 12376 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12377 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 12378 | bogus endian macros |
| 12379 | #endif |
| 12380 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12381 | ; |
| 12382 | return 0; |
| 12383 | } |
| 12384 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12385 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12386 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 12387 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12388 | /* end confdefs.h. */ |
| 12389 | #include <limits.h> |
| 12390 | |
| 12391 | int |
| 12392 | main () |
| 12393 | { |
| 12394 | #ifndef _BIG_ENDIAN |
| 12395 | not big endian |
| 12396 | #endif |
| 12397 | |
| 12398 | ; |
| 12399 | return 0; |
| 12400 | } |
| 12401 | _ACEOF |
| 12402 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12403 | ac_cv_c_bigendian=yes |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12404 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12405 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12406 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12407 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12408 | fi |
| 12409 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12410 | fi |
| 12411 | if test $ac_cv_c_bigendian = unknown; then |
| 12412 | # Compile a test program. |
| 12413 | if test "$cross_compiling" = yes; then : |
| 12414 | # Try to guess by grepping values from an object file. |
| 12415 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12416 | /* end confdefs.h. */ |
| 12417 | short int ascii_mm[] = |
| 12418 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 12419 | short int ascii_ii[] = |
| 12420 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 12421 | int use_ascii (int i) { |
| 12422 | return ascii_mm[i] + ascii_ii[i]; |
| 12423 | } |
| 12424 | short int ebcdic_ii[] = |
| 12425 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 12426 | short int ebcdic_mm[] = |
| 12427 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 12428 | int use_ebcdic (int i) { |
| 12429 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 12430 | } |
| 12431 | extern int foo; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12432 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12433 | int |
| 12434 | main () |
| 12435 | { |
| 12436 | return use_ascii (foo) == use_ebcdic (foo); |
| 12437 | ; |
| 12438 | return 0; |
| 12439 | } |
| 12440 | _ACEOF |
| 12441 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12442 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 12443 | ac_cv_c_bigendian=yes |
| 12444 | fi |
| 12445 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 12446 | if test "$ac_cv_c_bigendian" = unknown; then |
| 12447 | ac_cv_c_bigendian=no |
| 12448 | else |
| 12449 | # finding both strings is unlikely to happen, but who knows? |
| 12450 | ac_cv_c_bigendian=unknown |
| 12451 | fi |
| 12452 | fi |
| 12453 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12454 | 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] | 12455 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12456 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12457 | /* end confdefs.h. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12458 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12459 | int |
| 12460 | main () |
| 12461 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12462 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12463 | /* Are we little or big endian? From Harbison&Steele. */ |
| 12464 | union |
| 12465 | { |
| 12466 | long int l; |
| 12467 | char c[sizeof (long int)]; |
| 12468 | } u; |
| 12469 | u.l = 1; |
| 12470 | return u.c[sizeof (long int) - 1] == 1; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12471 | |
| 12472 | ; |
| 12473 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12474 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12475 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12476 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12477 | ac_cv_c_bigendian=no |
| 12478 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12479 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12480 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12481 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12482 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12483 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12484 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12485 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12486 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 12488 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 12489 | case $ac_cv_c_bigendian in #( |
| 12490 | yes) |
| 12491 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 12492 | ;; #( |
| 12493 | no) |
| 12494 | ;; #( |
| 12495 | universal) |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 12496 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12497 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12498 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12499 | ;; #( |
| 12500 | *) |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12501 | as_fn_error "unknown endianness |
| 12502 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12503 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12504 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12505 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12506 | # ABI version string for Python extension modules. This appears between the |
| 12507 | # periods in shared library file names, e.g. foo.<SOABI>.so. It is calculated |
| 12508 | # from the following attributes which affect the ABI of this Python build (in |
| 12509 | # this order): |
| 12510 | # |
| 12511 | # * The Python implementation (always 'cpython-' for us) |
| 12512 | # * The major and minor version numbers |
| 12513 | # * --with-pydebug (adds a 'd') |
| 12514 | # * --with-pymalloc (adds a 'm') |
| 12515 | # * --with-wide-unicode (adds a 'u') |
| 12516 | # |
| 12517 | # Thus for example, Python 3.2 built with wide unicode, pydebug, and pymalloc, |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12518 | # would get a shared library ABI version tag of 'cpython-32dmu' and shared |
| 12519 | # libraries would be named 'foo.cpython-32dmu.so'. |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12520 | |
| 12521 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5 |
| 12522 | $as_echo_n "checking SOABI... " >&6; } |
| 12523 | SOABI='cpython-'`echo $VERSION | tr -d .`${SOABI_QUALIFIERS} |
| 12524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5 |
| 12525 | $as_echo "$SOABI" >&6; } |
| 12526 | |
| 12527 | # SO is the extension of shared libraries `(including the dot!) |
| 12528 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
| 12529 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5 |
| 12530 | $as_echo_n "checking SO... " >&6; } |
| 12531 | if test -z "$SO" |
| 12532 | then |
| 12533 | case $ac_sys_system in |
| 12534 | hp*|HP*) |
| 12535 | case `uname -m` in |
| 12536 | ia64) SO=.so;; |
| 12537 | *) SO=.sl;; |
| 12538 | esac |
| 12539 | ;; |
| 12540 | CYGWIN*) SO=.dll;; |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12541 | Linux*) SO=.${SOABI}.so;; |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12542 | *) SO=.so;; |
| 12543 | esac |
| 12544 | else |
| 12545 | # this might also be a termcap variable, see #610332 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12546 | echo |
| 12547 | echo '=====================================================================' |
| 12548 | echo '+ +' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12549 | echo '+ WARNING: You have set SO in your environment. +' |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12550 | echo '+ Do you really mean to change the extension for shared libraries? +' |
| 12551 | echo '+ Continuing in 10 seconds to let you to ponder. +' |
| 12552 | echo '+ +' |
| 12553 | echo '=====================================================================' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12554 | sleep 10 |
| 12555 | fi |
| 12556 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5 |
| 12557 | $as_echo "$SO" >&6; } |
| 12558 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12559 | # Check whether right shifting a negative integer extends the sign bit |
| 12560 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12561 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 12562 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
| 12563 | if test "${ac_cv_rshift_extends_sign+set}" = set; then : |
| 12564 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12565 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12566 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12567 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12568 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12569 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12570 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12571 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12572 | |
| 12573 | int main() |
| 12574 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12575 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12576 | } |
| 12577 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12578 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12579 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12580 | ac_cv_rshift_extends_sign=yes |
| 12581 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12582 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12583 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12584 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12585 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12586 | fi |
| 12587 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12588 | fi |
| 12589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 12591 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12592 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12593 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12594 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12595 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12596 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12597 | fi |
| 12598 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12599 | # check for getc_unlocked and related locking functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12600 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 12601 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
| 12602 | if test "${ac_cv_have_getc_unlocked+set}" = set; then : |
| 12603 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12604 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12605 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12606 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12607 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12608 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12609 | int |
| 12610 | main () |
| 12611 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12612 | |
| 12613 | FILE *f = fopen("/dev/null", "r"); |
| 12614 | flockfile(f); |
| 12615 | getc_unlocked(f); |
| 12616 | funlockfile(f); |
| 12617 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12618 | ; |
| 12619 | return 0; |
| 12620 | } |
| 12621 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12622 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12623 | ac_cv_have_getc_unlocked=yes |
| 12624 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12625 | ac_cv_have_getc_unlocked=no |
| 12626 | fi |
| 12627 | rm -f core conftest.err conftest.$ac_objext \ |
| 12628 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12629 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12630 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12631 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 12632 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12633 | if test "$ac_cv_have_getc_unlocked" = yes |
| 12634 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12635 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12636 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12637 | |
| 12638 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12639 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12640 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12641 | # save the value of LIBS so we don't actually link Python with readline |
| 12642 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12643 | |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12644 | # On some systems we need to link readline to a termcap compatible |
| 12645 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 12646 | # with setup.py. |
| 12647 | py_cv_lib_readline=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12648 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 12649 | $as_echo_n "checking how to link readline libs... " >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12650 | for py_libtermcap in "" ncursesw ncurses curses termcap; do |
| 12651 | if test -z "$py_libtermcap"; then |
| 12652 | READLINE_LIBS="-lreadline" |
| 12653 | else |
| 12654 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 12655 | fi |
| 12656 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12657 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12658 | /* end confdefs.h. */ |
| 12659 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12660 | /* Override any GCC internal prototype to avoid an error. |
| 12661 | Use char because int might match the return type of a GCC |
| 12662 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12663 | #ifdef __cplusplus |
| 12664 | extern "C" |
| 12665 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12666 | char readline (); |
| 12667 | int |
| 12668 | main () |
| 12669 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12670 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12671 | ; |
| 12672 | return 0; |
| 12673 | } |
| 12674 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12675 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12676 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12677 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12678 | rm -f core conftest.err conftest.$ac_objext \ |
| 12679 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12680 | if test $py_cv_lib_readline = yes; then |
| 12681 | break |
| 12682 | fi |
| 12683 | done |
| 12684 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 12685 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | 3856c37 | 2008-09-07 19:24:00 +0000 | [diff] [blame] | 12686 | if test $py_cv_lib_readline = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12687 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 12688 | $as_echo "none" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12689 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12690 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 12691 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12692 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12693 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12694 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12695 | fi |
| 12696 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12697 | # check for readline 2.1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12698 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 12699 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
| 12700 | if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then : |
| 12701 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12702 | else |
| 12703 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12704 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12705 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12706 | /* end confdefs.h. */ |
| 12707 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12708 | /* Override any GCC internal prototype to avoid an error. |
| 12709 | Use char because int might match the return type of a GCC |
| 12710 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12711 | #ifdef __cplusplus |
| 12712 | extern "C" |
| 12713 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12714 | char rl_callback_handler_install (); |
| 12715 | int |
| 12716 | main () |
| 12717 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12718 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12719 | ; |
| 12720 | return 0; |
| 12721 | } |
| 12722 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12723 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12724 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 12725 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12726 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12727 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12728 | rm -f core conftest.err conftest.$ac_objext \ |
| 12729 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12730 | LIBS=$ac_check_lib_save_LIBS |
| 12731 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12732 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 12733 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
| 12734 | 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] | 12735 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12736 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12737 | |
| 12738 | fi |
| 12739 | |
| 12740 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12741 | # check for readline 2.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12742 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12743 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12744 | #include <readline/readline.h> |
| 12745 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12746 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12747 | have_readline=yes |
| 12748 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12749 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12750 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12751 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12752 | rm -f conftest.err conftest.$ac_ext |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12753 | if test $have_readline = yes |
| 12754 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12756 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12757 | #include <readline/readline.h> |
| 12758 | |
| 12759 | _ACEOF |
| 12760 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12761 | $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] | 12762 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12763 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12764 | |
| 12765 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12766 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12767 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12768 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12769 | /* end confdefs.h. */ |
| 12770 | #include <readline/readline.h> |
| 12771 | |
| 12772 | _ACEOF |
| 12773 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12774 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12775 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12776 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12777 | |
| 12778 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12779 | rm -f conftest* |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12780 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12781 | fi |
| 12782 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12783 | # check for readline 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12784 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 12785 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
| 12786 | if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then : |
| 12787 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12788 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12789 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12790 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12791 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12792 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12793 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12794 | /* Override any GCC internal prototype to avoid an error. |
| 12795 | Use char because int might match the return type of a GCC |
| 12796 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12797 | #ifdef __cplusplus |
| 12798 | extern "C" |
| 12799 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12800 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12801 | int |
| 12802 | main () |
| 12803 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12804 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12805 | ; |
| 12806 | return 0; |
| 12807 | } |
| 12808 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12809 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12810 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12811 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12812 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12813 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12814 | rm -f core conftest.err conftest.$ac_objext \ |
| 12815 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12816 | LIBS=$ac_check_lib_save_LIBS |
| 12817 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12818 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 12819 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
| 12820 | 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] | 12821 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12822 | $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] | 12823 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12824 | fi |
| 12825 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12826 | |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12827 | # also in 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12828 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 12829 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
| 12830 | if test "${ac_cv_lib_readline_rl_completion_display_matches_hook+set}" = set; then : |
| 12831 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12832 | else |
| 12833 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12834 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12835 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12836 | /* end confdefs.h. */ |
| 12837 | |
| 12838 | /* Override any GCC internal prototype to avoid an error. |
| 12839 | Use char because int might match the return type of a GCC |
| 12840 | builtin and then its argument prototype would still apply. */ |
| 12841 | #ifdef __cplusplus |
| 12842 | extern "C" |
| 12843 | #endif |
| 12844 | char rl_completion_display_matches_hook (); |
| 12845 | int |
| 12846 | main () |
| 12847 | { |
| 12848 | return rl_completion_display_matches_hook (); |
| 12849 | ; |
| 12850 | return 0; |
| 12851 | } |
| 12852 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12853 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12854 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 12855 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12856 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12857 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12858 | rm -f core conftest.err conftest.$ac_objext \ |
| 12859 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12860 | LIBS=$ac_check_lib_save_LIBS |
| 12861 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 12863 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
| 12864 | if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = x""yes; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12865 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12866 | $as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12867 | |
| 12868 | fi |
| 12869 | |
| 12870 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12871 | # check for readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12872 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 12873 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
| 12874 | if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then : |
| 12875 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12876 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12877 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12878 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12879 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12880 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12881 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12882 | /* Override any GCC internal prototype to avoid an error. |
| 12883 | Use char because int might match the return type of a GCC |
| 12884 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12885 | #ifdef __cplusplus |
| 12886 | extern "C" |
| 12887 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12888 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12889 | int |
| 12890 | main () |
| 12891 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12892 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12893 | ; |
| 12894 | return 0; |
| 12895 | } |
| 12896 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12897 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12898 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12899 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12900 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12901 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12902 | rm -f core conftest.err conftest.$ac_objext \ |
| 12903 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12904 | LIBS=$ac_check_lib_save_LIBS |
| 12905 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12906 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 12907 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
| 12908 | 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] | 12909 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12910 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12911 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12912 | fi |
| 12913 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 12914 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12915 | # also in readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12916 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12917 | /* end confdefs.h. */ |
| 12918 | #include <readline/readline.h> |
| 12919 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12920 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12921 | have_readline=yes |
| 12922 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12923 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12924 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12925 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12926 | rm -f conftest.err conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12927 | if test $have_readline = yes |
| 12928 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12929 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12930 | /* end confdefs.h. */ |
| 12931 | #include <readline/readline.h> |
| 12932 | |
| 12933 | _ACEOF |
| 12934 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12935 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12936 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12937 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12938 | |
| 12939 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12940 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12941 | |
| 12942 | fi |
| 12943 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12944 | # End of readline checks: restore LIBS |
| 12945 | LIBS=$LIBS_no_readline |
| 12946 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12947 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 12948 | $as_echo_n "checking for broken nice()... " >&6; } |
| 12949 | if test "${ac_cv_broken_nice+set}" = set; then : |
| 12950 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12951 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12952 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12953 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12954 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12955 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12956 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12957 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12958 | |
| 12959 | int main() |
| 12960 | { |
| 12961 | int val1 = nice(1); |
| 12962 | if (val1 != -1 && val1 == nice(2)) |
| 12963 | exit(0); |
| 12964 | exit(1); |
| 12965 | } |
| 12966 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12967 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12968 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12969 | ac_cv_broken_nice=yes |
| 12970 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12971 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12972 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12973 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12974 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12975 | fi |
| 12976 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12977 | fi |
| 12978 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 12980 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12981 | if test "$ac_cv_broken_nice" = yes |
| 12982 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12983 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12984 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 12985 | |
| 12986 | fi |
| 12987 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12988 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 12989 | $as_echo_n "checking for broken poll()... " >&6; } |
| 12990 | if test "${ac_cv_broken_poll+set}" = set; then : |
| 12991 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12992 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12993 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 12994 | ac_cv_broken_poll=no |
| 12995 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12996 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 12997 | /* end confdefs.h. */ |
| 12998 | |
| 12999 | #include <poll.h> |
| 13000 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13001 | int main() |
| 13002 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13003 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13004 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13005 | |
| 13006 | close (42); |
| 13007 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13008 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13009 | if (poll_test < 0) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13010 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13011 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13012 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13013 | else |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13014 | return 1; |
| 13015 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13016 | |
| 13017 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13018 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13019 | ac_cv_broken_poll=yes |
| 13020 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13021 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13022 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13023 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13024 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13025 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13026 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13027 | fi |
| 13028 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13029 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 13030 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13031 | if test "$ac_cv_broken_poll" = yes |
| 13032 | then |
| 13033 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13034 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13035 | |
| 13036 | fi |
| 13037 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13038 | # 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] | 13039 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 13040 | # tzname[] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13041 | 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] | 13042 | #include <$ac_cv_struct_tm> |
| 13043 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13044 | " |
| 13045 | 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] | 13046 | |
| 13047 | cat >>confdefs.h <<_ACEOF |
| 13048 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 13049 | _ACEOF |
| 13050 | |
| 13051 | |
| 13052 | fi |
| 13053 | |
| 13054 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 13055 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13056 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13057 | |
| 13058 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13059 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 13060 | " |
| 13061 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
| 13062 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13063 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13064 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13065 | fi |
| 13066 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13067 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13068 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13069 | _ACEOF |
| 13070 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13071 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 13072 | $as_echo_n "checking for tzname... " >&6; } |
| 13073 | if test "${ac_cv_var_tzname+set}" = set; then : |
| 13074 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13075 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13076 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13077 | /* end confdefs.h. */ |
| 13078 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13079 | #if !HAVE_DECL_TZNAME |
| 13080 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13081 | #endif |
| 13082 | |
| 13083 | int |
| 13084 | main () |
| 13085 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13086 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13087 | ; |
| 13088 | return 0; |
| 13089 | } |
| 13090 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13091 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13092 | ac_cv_var_tzname=yes |
| 13093 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13094 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13095 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13096 | rm -f core conftest.err conftest.$ac_objext \ |
| 13097 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13098 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13099 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 13100 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13101 | if test $ac_cv_var_tzname = yes; then |
| 13102 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13103 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13104 | |
| 13105 | fi |
| 13106 | fi |
| 13107 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13108 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13109 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 13111 | $as_echo_n "checking for working tzset()... " >&6; } |
| 13112 | if test "${ac_cv_working_tzset+set}" = set; then : |
| 13113 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13114 | else |
| 13115 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13116 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13117 | ac_cv_working_tzset=no |
| 13118 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13119 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13120 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13121 | |
| 13122 | #include <stdlib.h> |
| 13123 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13124 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13125 | |
| 13126 | #if HAVE_TZNAME |
| 13127 | extern char *tzname[]; |
| 13128 | #endif |
| 13129 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13130 | int main() |
| 13131 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13132 | /* Note that we need to ensure that not only does tzset(3) |
| 13133 | do 'something' with localtime, but it works as documented |
| 13134 | 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] | 13135 | This includes making sure that tzname is set properly if |
| 13136 | tm->tm_zone does not exist since it is the alternative way |
| 13137 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13138 | |
| 13139 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13140 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13141 | */ |
| 13142 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13143 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13144 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 13145 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13146 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13147 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13148 | if (localtime(&groundhogday)->tm_hour != 0) |
| 13149 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13150 | #if HAVE_TZNAME |
| 13151 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 13152 | if (strcmp(tzname[0], "UTC") || |
| 13153 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 13154 | exit(1); |
| 13155 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13156 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13157 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13158 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13159 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13160 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13161 | #if HAVE_TZNAME |
| 13162 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 13163 | exit(1); |
| 13164 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13165 | |
| 13166 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 13167 | tzset(); |
| 13168 | if (localtime(&groundhogday)->tm_hour != 11) |
| 13169 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13170 | #if HAVE_TZNAME |
| 13171 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 13172 | exit(1); |
| 13173 | #endif |
| 13174 | |
| 13175 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13176 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 13177 | exit(1); |
| 13178 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 13179 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13180 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13181 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13182 | exit(0); |
| 13183 | } |
| 13184 | |
| 13185 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13186 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13187 | ac_cv_working_tzset=yes |
| 13188 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13189 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13190 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13191 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13192 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13193 | fi |
| 13194 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13195 | fi |
| 13196 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13197 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 13198 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13199 | if test "$ac_cv_working_tzset" = yes |
| 13200 | then |
| 13201 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13202 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13203 | |
| 13204 | fi |
| 13205 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13206 | # Look for subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13207 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 13208 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
| 13209 | if test "${ac_cv_stat_tv_nsec+set}" = set; then : |
| 13210 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13211 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13212 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13213 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13214 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13215 | int |
| 13216 | main () |
| 13217 | { |
| 13218 | |
| 13219 | struct stat st; |
| 13220 | st.st_mtim.tv_nsec = 1; |
| 13221 | |
| 13222 | ; |
| 13223 | return 0; |
| 13224 | } |
| 13225 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13226 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 13227 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13228 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13229 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13230 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13231 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13232 | fi |
| 13233 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13234 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 13235 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13236 | if test "$ac_cv_stat_tv_nsec" = yes |
| 13237 | then |
| 13238 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13239 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13240 | |
| 13241 | fi |
| 13242 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13243 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13244 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 13245 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
| 13246 | if test "${ac_cv_stat_tv_nsec2+set}" = set; then : |
| 13247 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13248 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13249 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13250 | /* end confdefs.h. */ |
| 13251 | #include <sys/stat.h> |
| 13252 | int |
| 13253 | main () |
| 13254 | { |
| 13255 | |
| 13256 | struct stat st; |
| 13257 | st.st_mtimespec.tv_nsec = 1; |
| 13258 | |
| 13259 | ; |
| 13260 | return 0; |
| 13261 | } |
| 13262 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13263 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13264 | ac_cv_stat_tv_nsec2=yes |
| 13265 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13266 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13267 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13268 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13269 | fi |
| 13270 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 13272 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13273 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 13274 | then |
| 13275 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13276 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13277 | |
| 13278 | fi |
| 13279 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13280 | # On HP/UX 11.0, mvwdelch is a block with a return statement |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 13282 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
| 13283 | if test "${ac_cv_mvwdelch_is_expression+set}" = set; then : |
| 13284 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13285 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13286 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13287 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13288 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13289 | int |
| 13290 | main () |
| 13291 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13292 | |
| 13293 | int rtn; |
| 13294 | rtn = mvwdelch(0,0,0); |
| 13295 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13296 | ; |
| 13297 | return 0; |
| 13298 | } |
| 13299 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13300 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13301 | ac_cv_mvwdelch_is_expression=yes |
| 13302 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13303 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13304 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13305 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13306 | fi |
| 13307 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13308 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 13309 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13310 | |
| 13311 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 13312 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13313 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13314 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13315 | |
| 13316 | fi |
| 13317 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13318 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 13319 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
| 13320 | if test "${ac_cv_window_has_flags+set}" = set; then : |
| 13321 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13322 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13323 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13324 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13325 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13326 | int |
| 13327 | main () |
| 13328 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13329 | |
| 13330 | WINDOW *w; |
| 13331 | w->_flags = 0; |
| 13332 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13333 | ; |
| 13334 | return 0; |
| 13335 | } |
| 13336 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13337 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13338 | ac_cv_window_has_flags=yes |
| 13339 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13340 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13341 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13342 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13343 | fi |
| 13344 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13345 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 13346 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13347 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13348 | |
| 13349 | if test "$ac_cv_window_has_flags" = yes |
| 13350 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13351 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13352 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13353 | |
| 13354 | fi |
| 13355 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13356 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 13357 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 13358 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13359 | /* end confdefs.h. */ |
| 13360 | #include <curses.h> |
| 13361 | int |
| 13362 | main () |
| 13363 | { |
| 13364 | void *x=is_term_resized |
| 13365 | ; |
| 13366 | return 0; |
| 13367 | } |
| 13368 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13369 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13370 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13371 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13372 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13374 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13375 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13377 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13378 | |
| 13379 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13380 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13381 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13382 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 13383 | $as_echo_n "checking for resize_term... " >&6; } |
| 13384 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13385 | /* end confdefs.h. */ |
| 13386 | #include <curses.h> |
| 13387 | int |
| 13388 | main () |
| 13389 | { |
| 13390 | void *x=resize_term |
| 13391 | ; |
| 13392 | return 0; |
| 13393 | } |
| 13394 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13395 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13396 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13397 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13398 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13399 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13400 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13401 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13403 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13404 | |
| 13405 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13406 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13407 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13408 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 13409 | $as_echo_n "checking for resizeterm... " >&6; } |
| 13410 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13411 | /* end confdefs.h. */ |
| 13412 | #include <curses.h> |
| 13413 | int |
| 13414 | main () |
| 13415 | { |
| 13416 | void *x=resizeterm |
| 13417 | ; |
| 13418 | return 0; |
| 13419 | } |
| 13420 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13421 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13422 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13423 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13424 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13426 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13427 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13428 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13429 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13430 | |
| 13431 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13432 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13433 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 13435 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13436 | |
| 13437 | if test -r /dev/ptmx |
| 13438 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13439 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13440 | $as_echo "yes" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13441 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13442 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13443 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13444 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13445 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13446 | $as_echo "no" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13447 | fi |
| 13448 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13449 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 13450 | $as_echo_n "checking for /dev/ptc... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13451 | |
| 13452 | if test -r /dev/ptc |
| 13453 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13455 | $as_echo "yes" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13457 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13458 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13459 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13460 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13461 | $as_echo "no" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13462 | fi |
| 13463 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13464 | if test "$have_long_long" = yes |
| 13465 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13466 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 13467 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
| 13468 | if test "${ac_cv_have_long_long_format+set}" = set; then : |
| 13469 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13470 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13471 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13472 | ac_cv_have_long_long_format=no |
| 13473 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13474 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13475 | /* end confdefs.h. */ |
| 13476 | |
| 13477 | #include <stdio.h> |
| 13478 | #include <stddef.h> |
| 13479 | #include <string.h> |
| 13480 | |
| 13481 | #ifdef HAVE_SYS_TYPES_H |
| 13482 | #include <sys/types.h> |
| 13483 | #endif |
| 13484 | |
| 13485 | int main() |
| 13486 | { |
| 13487 | char buffer[256]; |
| 13488 | |
| 13489 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 13490 | return 1; |
| 13491 | if (strcmp(buffer, "123")) |
| 13492 | return 1; |
| 13493 | |
| 13494 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 13495 | return 1; |
| 13496 | if (strcmp(buffer, "-123")) |
| 13497 | return 1; |
| 13498 | |
| 13499 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 13500 | return 1; |
| 13501 | if (strcmp(buffer, "123")) |
| 13502 | return 1; |
| 13503 | |
| 13504 | return 0; |
| 13505 | } |
| 13506 | |
| 13507 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13508 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13509 | ac_cv_have_long_long_format=yes |
| 13510 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13511 | ac_cv_have_long_long_format=no |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13512 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13513 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13514 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13515 | fi |
| 13516 | |
| 13517 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13518 | fi |
| 13519 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 13521 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13522 | fi |
| 13523 | |
Mark Dickinson | 89d7d41 | 2009-12-31 20:50:59 +0000 | [diff] [blame] | 13524 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13525 | then |
| 13526 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13527 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13528 | |
| 13529 | fi |
| 13530 | |
Ronald Oussoren | 3c1928a | 2009-11-19 17:15:31 +0000 | [diff] [blame] | 13531 | if test $ac_sys_system = Darwin |
| 13532 | then |
| 13533 | LIBS="$LIBS -framework CoreFoundation" |
| 13534 | fi |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13535 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13536 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 13537 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
| 13538 | if test "${ac_cv_have_size_t_format+set}" = set; then : |
| 13539 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13540 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13541 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13542 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 13543 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13544 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13545 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13546 | /* end confdefs.h. */ |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13547 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13548 | #include <stdio.h> |
| 13549 | #include <stddef.h> |
| 13550 | #include <string.h> |
| 13551 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13552 | #ifdef HAVE_SYS_TYPES_H |
| 13553 | #include <sys/types.h> |
| 13554 | #endif |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13555 | |
| 13556 | #ifdef HAVE_SSIZE_T |
| 13557 | typedef ssize_t Py_ssize_t; |
| 13558 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 13559 | typedef long Py_ssize_t; |
| 13560 | #else |
| 13561 | typedef int Py_ssize_t; |
| 13562 | #endif |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13563 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13564 | int main() |
| 13565 | { |
| 13566 | char buffer[256]; |
| 13567 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13568 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 13569 | return 1; |
| 13570 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13571 | if (strcmp(buffer, "123")) |
| 13572 | return 1; |
| 13573 | |
| 13574 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 13575 | return 1; |
| 13576 | |
| 13577 | if (strcmp(buffer, "-123")) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13578 | return 1; |
| 13579 | |
| 13580 | return 0; |
| 13581 | } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13582 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13583 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13584 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13585 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13586 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13587 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13588 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13589 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13590 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 13591 | fi |
| 13592 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13593 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 13595 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13596 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13597 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13598 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13599 | |
| 13600 | fi |
| 13601 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13602 | 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] | 13603 | #ifdef HAVE_SYS_TYPES_H |
| 13604 | #include <sys/types.h> |
| 13605 | #endif |
| 13606 | #ifdef HAVE_SYS_SOCKET_H |
| 13607 | #include <sys/socket.h> |
| 13608 | #endif |
| 13609 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13610 | " |
| 13611 | 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] | 13612 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13613 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13614 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13615 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13616 | |
| 13617 | fi |
| 13618 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13619 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13620 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5 |
| 13621 | $as_echo_n "checking for broken mbstowcs... " >&6; } |
| 13622 | if test "${ac_cv_broken_mbstowcs+set}" = set; then : |
| 13623 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13624 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13625 | if test "$cross_compiling" = yes; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13626 | ac_cv_broken_mbstowcs=no |
| 13627 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13628 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13629 | /* end confdefs.h. */ |
| 13630 | |
| 13631 | #include<stdlib.h> |
| 13632 | int main() { |
| 13633 | size_t len = -1; |
| 13634 | const char *str = "text"; |
| 13635 | len = mbstowcs(NULL, str, 0); |
| 13636 | return (len != 4); |
| 13637 | } |
| 13638 | |
| 13639 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13640 | if ac_fn_c_try_run "$LINENO"; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13641 | ac_cv_broken_mbstowcs=no |
| 13642 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13643 | ac_cv_broken_mbstowcs=yes |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13644 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13645 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13646 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13647 | fi |
| 13648 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13649 | fi |
| 13650 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13651 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5 |
| 13652 | $as_echo "$ac_cv_broken_mbstowcs" >&6; } |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13653 | if test "$ac_cv_broken_mbstowcs" = yes |
| 13654 | then |
| 13655 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13656 | $as_echo "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13657 | |
| 13658 | fi |
| 13659 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13660 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5 |
| 13661 | $as_echo_n "checking whether $CC supports computed gotos... " >&6; } |
| 13662 | if test "${ac_cv_computed_gotos+set}" = set; then : |
| 13663 | $as_echo_n "(cached) " >&6 |
| 13664 | else |
| 13665 | if test "$cross_compiling" = yes; then : |
| 13666 | ac_cv_computed_gotos=no |
| 13667 | else |
| 13668 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13669 | /* end confdefs.h. */ |
| 13670 | |
| 13671 | int main(int argc, char **argv) |
| 13672 | { |
| 13673 | static void *targets[1] = { &&LABEL1 }; |
| 13674 | goto LABEL2; |
| 13675 | LABEL1: |
| 13676 | return 0; |
| 13677 | LABEL2: |
| 13678 | goto *targets[0]; |
| 13679 | return 1; |
| 13680 | } |
| 13681 | |
| 13682 | _ACEOF |
| 13683 | if ac_fn_c_try_run "$LINENO"; then : |
| 13684 | ac_cv_computed_gotos=yes |
| 13685 | else |
| 13686 | ac_cv_computed_gotos=no |
| 13687 | fi |
| 13688 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13689 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 13690 | fi |
| 13691 | |
| 13692 | fi |
| 13693 | |
| 13694 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5 |
| 13695 | $as_echo "$ac_cv_computed_gotos" >&6; } |
| 13696 | if test "$ac_cv_computed_gotos" = yes |
| 13697 | then |
| 13698 | |
| 13699 | $as_echo "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h |
| 13700 | |
| 13701 | fi |
| 13702 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13703 | # Check for --with-computed-gotos |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13704 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5 |
| 13705 | $as_echo_n "checking for --with-computed-gotos... " >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13706 | |
| 13707 | # Check whether --with-computed-gotos was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13708 | if test "${with_computed_gotos+set}" = set; then : |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13709 | withval=$with_computed_gotos; |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13710 | if test "$withval" = yes |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13711 | then |
| 13712 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13713 | $as_echo "#define USE_COMPUTED_GOTOS 1" >>confdefs.h |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13714 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13716 | $as_echo "yes" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13717 | fi |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13718 | if test "$withval" = no |
| 13719 | then |
| 13720 | |
| 13721 | $as_echo "#define USE_COMPUTED_GOTOS 0" >>confdefs.h |
| 13722 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13723 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13724 | $as_echo "no" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13725 | fi |
| 13726 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13727 | else |
| 13728 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 13729 | $as_echo "no value specified" >&6; } |
| 13730 | fi |
| 13731 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13732 | |
| 13733 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13734 | |
Jesus Cea | 6a79229 | 2010-05-03 21:18:48 +0000 | [diff] [blame] | 13735 | case $ac_sys_system in |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 13736 | OSF*) as_fn_error "OSF* systems are deprecated unless somebody volunteers. Check http://bugs.python.org/issue8606" "$LINENO" 5 ;; |
Jesus Cea | 6a79229 | 2010-05-03 21:18:48 +0000 | [diff] [blame] | 13737 | esac |
| 13738 | |
| 13739 | |
| 13740 | |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 13741 | |
| 13742 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 13743 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 13744 | do |
| 13745 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 13746 | done |
| 13747 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13748 | |
Neal Norwitz | d24499d | 2005-12-18 21:36:39 +0000 | [diff] [blame] | 13749 | SRCDIRS="Parser Grammar Objects Python Modules Mac" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 13751 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13752 | for dir in $SRCDIRS; do |
| 13753 | if test ! -d $dir; then |
| 13754 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 13755 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13756 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13757 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 13758 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 13759 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13760 | # generate output files |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 13761 | 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] | 13762 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 13763 | ac_config_files="$ac_config_files Modules/ld_so_aix" |
| 13764 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13765 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13766 | # This file is a shell script that caches the results of configure |
| 13767 | # 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] | 13768 | # scripts and configure runs, see configure's option --config-cache. |
| 13769 | # It is not useful on other systems. If it contains results you don't |
| 13770 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13771 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13772 | # config.status only pays attention to the cache file if you give it |
| 13773 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13774 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13775 | # `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] | 13776 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 13777 | # following values. |
| 13778 | |
| 13779 | _ACEOF |
| 13780 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 13781 | # The following way of writing the cache mishandles newlines in values, |
| 13782 | # but we know of no workaround that is simple, portable, and efficient. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13783 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13784 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 13785 | # and sets the high bit in the cache file unless we assign to the vars. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13786 | ( |
| 13787 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 13788 | eval ac_val=\$$ac_var |
| 13789 | case $ac_val in #( |
| 13790 | *${as_nl}*) |
| 13791 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13792 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 13793 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13794 | esac |
| 13795 | case $ac_var in #( |
| 13796 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13797 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 13798 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13799 | esac ;; |
| 13800 | esac |
| 13801 | done |
| 13802 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13803 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13804 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 13805 | *${as_nl}ac_space=\ *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13806 | # `set' does not quote correctly, so add quotes: double-quote |
| 13807 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13808 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 13809 | "s/'/'\\\\''/g; |
| 13810 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13811 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13812 | *) |
| 13813 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13814 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13815 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13816 | esac | |
| 13817 | sort |
| 13818 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13819 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13820 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13821 | t clear |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13822 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13823 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 13824 | t end |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13825 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 13826 | :end' >>confcache |
| 13827 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 13828 | if test -w "$cache_file"; then |
| 13829 | test "x$cache_file" != "x/dev/null" && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13830 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 13831 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13832 | cat confcache >$cache_file |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13833 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13834 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 13835 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13836 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13837 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13838 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13839 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13840 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 13841 | # Let make expand exec_prefix. |
| 13842 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13843 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13844 | DEFS=-DHAVE_CONFIG_H |
| 13845 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13846 | ac_libobjs= |
| 13847 | ac_ltlibobjs= |
| 13848 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 13849 | # 1. Remove the extension, and $U if already installed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13850 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13851 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13852 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 13853 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13854 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 13855 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13856 | done |
| 13857 | LIBOBJS=$ac_libobjs |
| 13858 | |
| 13859 | LTLIBOBJS=$ac_ltlibobjs |
| 13860 | |
| 13861 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13862 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13863 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13864 | : ${CONFIG_STATUS=./config.status} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13865 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13866 | ac_clean_files_save=$ac_clean_files |
| 13867 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13868 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 13869 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 13870 | as_write_fail=0 |
| 13871 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13872 | #! $SHELL |
| 13873 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13874 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13875 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13876 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13877 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13878 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13879 | ac_cs_recheck=false |
| 13880 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13881 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13882 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 13883 | export SHELL |
| 13884 | _ASEOF |
| 13885 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 13886 | ## -------------------- ## |
| 13887 | ## M4sh Initialization. ## |
| 13888 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13889 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13890 | # Be more Bourne compatible |
| 13891 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13892 | 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] | 13893 | emulate sh |
| 13894 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13895 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13896 | # is contrary to our usage. Disable this feature. |
| 13897 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13898 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 13899 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13900 | case `(set -o) 2>/dev/null` in #( |
| 13901 | *posix*) : |
| 13902 | set -o posix ;; #( |
| 13903 | *) : |
| 13904 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13905 | esac |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13906 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13907 | |
| 13908 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13909 | as_nl=' |
| 13910 | ' |
| 13911 | export as_nl |
| 13912 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 13913 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 13914 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13915 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 13916 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 13917 | # but without wasting forks for bash or zsh. |
| 13918 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 13919 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13920 | as_echo='print -r --' |
| 13921 | as_echo_n='print -rn --' |
| 13922 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 13923 | as_echo='printf %s\n' |
| 13924 | as_echo_n='printf %s' |
| 13925 | else |
| 13926 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 13927 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 13928 | as_echo_n='/usr/ucb/echo -n' |
| 13929 | else |
| 13930 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 13931 | as_echo_n_body='eval |
| 13932 | arg=$1; |
| 13933 | case $arg in #( |
| 13934 | *"$as_nl"*) |
| 13935 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 13936 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 13937 | esac; |
| 13938 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 13939 | ' |
| 13940 | export as_echo_n_body |
| 13941 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 13942 | fi |
| 13943 | export as_echo_body |
| 13944 | as_echo='sh -c $as_echo_body as_echo' |
| 13945 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13946 | |
| 13947 | # The user is always right. |
| 13948 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13949 | PATH_SEPARATOR=: |
| 13950 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 13951 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 13952 | PATH_SEPARATOR=';' |
| 13953 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13954 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13955 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13956 | |
| 13957 | # IFS |
| 13958 | # We need space, tab and new line, in precisely that order. Quoting is |
| 13959 | # there to prevent editors from complaining about space-tab. |
| 13960 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 13961 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13962 | IFS=" "" $as_nl" |
| 13963 | |
| 13964 | # Find who we are. Look in the path if we contain no directory separator. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13965 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13966 | *[\\/]* ) as_myself=$0 ;; |
| 13967 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13968 | for as_dir in $PATH |
| 13969 | do |
| 13970 | IFS=$as_save_IFS |
| 13971 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13972 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 13973 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13974 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13975 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13976 | ;; |
| 13977 | esac |
| 13978 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 13979 | # in which case we are not to be found in the path. |
| 13980 | if test "x$as_myself" = x; then |
| 13981 | as_myself=$0 |
| 13982 | fi |
| 13983 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13984 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 13985 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13986 | fi |
| 13987 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13988 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 13989 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 13990 | # suppresses any "Segmentation fault" message there. '((' could |
| 13991 | # trigger a bug in pdksh 5.2.14. |
| 13992 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 13993 | do eval test x\${$as_var+set} = xset \ |
| 13994 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13995 | done |
| 13996 | PS1='$ ' |
| 13997 | PS2='> ' |
| 13998 | PS4='+ ' |
| 13999 | |
| 14000 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14001 | LC_ALL=C |
| 14002 | export LC_ALL |
| 14003 | LANGUAGE=C |
| 14004 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14005 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14006 | # CDPATH. |
| 14007 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 14008 | |
| 14009 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14010 | # as_fn_error ERROR [LINENO LOG_FD] |
| 14011 | # --------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14012 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 14013 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14014 | # script with status $?, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14015 | as_fn_error () |
| 14016 | { |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14017 | as_status=$?; test $as_status -eq 0 && as_status=1 |
| 14018 | if test "$3"; then |
| 14019 | as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 14020 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14021 | fi |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14022 | $as_echo "$as_me: error: $1" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14023 | as_fn_exit $as_status |
| 14024 | } # as_fn_error |
| 14025 | |
| 14026 | |
| 14027 | # as_fn_set_status STATUS |
| 14028 | # ----------------------- |
| 14029 | # Set $? to STATUS, without forking. |
| 14030 | as_fn_set_status () |
| 14031 | { |
| 14032 | return $1 |
| 14033 | } # as_fn_set_status |
| 14034 | |
| 14035 | # as_fn_exit STATUS |
| 14036 | # ----------------- |
| 14037 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 14038 | as_fn_exit () |
| 14039 | { |
| 14040 | set +e |
| 14041 | as_fn_set_status $1 |
| 14042 | exit $1 |
| 14043 | } # as_fn_exit |
| 14044 | |
| 14045 | # as_fn_unset VAR |
| 14046 | # --------------- |
| 14047 | # Portably unset VAR. |
| 14048 | as_fn_unset () |
| 14049 | { |
| 14050 | { eval $1=; unset $1;} |
| 14051 | } |
| 14052 | as_unset=as_fn_unset |
| 14053 | # as_fn_append VAR VALUE |
| 14054 | # ---------------------- |
| 14055 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 14056 | # advantage of any shell optimizations that allow amortized linear growth over |
| 14057 | # repeated appends, instead of the typical quadratic growth present in naive |
| 14058 | # implementations. |
| 14059 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 14060 | eval 'as_fn_append () |
| 14061 | { |
| 14062 | eval $1+=\$2 |
| 14063 | }' |
| 14064 | else |
| 14065 | as_fn_append () |
| 14066 | { |
| 14067 | eval $1=\$$1\$2 |
| 14068 | } |
| 14069 | fi # as_fn_append |
| 14070 | |
| 14071 | # as_fn_arith ARG... |
| 14072 | # ------------------ |
| 14073 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 14074 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 14075 | # must be portable across $(()) and expr. |
| 14076 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 14077 | eval 'as_fn_arith () |
| 14078 | { |
| 14079 | as_val=$(( $* )) |
| 14080 | }' |
| 14081 | else |
| 14082 | as_fn_arith () |
| 14083 | { |
| 14084 | as_val=`expr "$@" || test $? -eq 1` |
| 14085 | } |
| 14086 | fi # as_fn_arith |
| 14087 | |
| 14088 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14089 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 14090 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 14091 | as_expr=expr |
| 14092 | else |
| 14093 | as_expr=false |
| 14094 | fi |
| 14095 | |
| 14096 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 14097 | as_basename=basename |
| 14098 | else |
| 14099 | as_basename=false |
| 14100 | fi |
| 14101 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14102 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 14103 | as_dirname=dirname |
| 14104 | else |
| 14105 | as_dirname=false |
| 14106 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14107 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14108 | as_me=`$as_basename -- "$0" || |
| 14109 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 14110 | X"$0" : 'X\(//\)$' \| \ |
| 14111 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14112 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14113 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 14114 | s//\1/ |
| 14115 | q |
| 14116 | } |
| 14117 | /^X\/\(\/\/\)$/{ |
| 14118 | s//\1/ |
| 14119 | q |
| 14120 | } |
| 14121 | /^X\/\(\/\).*/{ |
| 14122 | s//\1/ |
| 14123 | q |
| 14124 | } |
| 14125 | s/.*/./; q'` |
| 14126 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14127 | # Avoid depending upon Character Ranges. |
| 14128 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 14129 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14130 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14131 | as_cr_digits='0123456789' |
| 14132 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14133 | |
| 14134 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14135 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14136 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14137 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14138 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14139 | xy) ECHO_C='\c';; |
| 14140 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 14141 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14142 | esac;; |
| 14143 | *) |
| 14144 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14145 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14146 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14147 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14148 | if test -d conf$$.dir; then |
| 14149 | rm -f conf$$.dir/conf$$.file |
| 14150 | else |
| 14151 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14152 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14153 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14154 | if (echo >conf$$.file) 2>/dev/null; then |
| 14155 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 14156 | as_ln_s='ln -s' |
| 14157 | # ... but there are two gotchas: |
| 14158 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 14159 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 14160 | # In both cases, we have to default to `cp -p'. |
| 14161 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 14162 | as_ln_s='cp -p' |
| 14163 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 14164 | as_ln_s=ln |
| 14165 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14166 | as_ln_s='cp -p' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14167 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14168 | else |
| 14169 | as_ln_s='cp -p' |
| 14170 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14171 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 14172 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14173 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14174 | |
| 14175 | # as_fn_mkdir_p |
| 14176 | # ------------- |
| 14177 | # Create "$as_dir" as a directory, including parents if necessary. |
| 14178 | as_fn_mkdir_p () |
| 14179 | { |
| 14180 | |
| 14181 | case $as_dir in #( |
| 14182 | -*) as_dir=./$as_dir;; |
| 14183 | esac |
| 14184 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 14185 | as_dirs= |
| 14186 | while :; do |
| 14187 | case $as_dir in #( |
| 14188 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 14189 | *) as_qdir=$as_dir;; |
| 14190 | esac |
| 14191 | as_dirs="'$as_qdir' $as_dirs" |
| 14192 | as_dir=`$as_dirname -- "$as_dir" || |
| 14193 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 14194 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 14195 | X"$as_dir" : 'X\(//\)$' \| \ |
| 14196 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 14197 | $as_echo X"$as_dir" | |
| 14198 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14199 | s//\1/ |
| 14200 | q |
| 14201 | } |
| 14202 | /^X\(\/\/\)[^/].*/{ |
| 14203 | s//\1/ |
| 14204 | q |
| 14205 | } |
| 14206 | /^X\(\/\/\)$/{ |
| 14207 | s//\1/ |
| 14208 | q |
| 14209 | } |
| 14210 | /^X\(\/\).*/{ |
| 14211 | s//\1/ |
| 14212 | q |
| 14213 | } |
| 14214 | s/.*/./; q'` |
| 14215 | test -d "$as_dir" && break |
| 14216 | done |
| 14217 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14218 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14219 | |
| 14220 | |
| 14221 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14222 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14223 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14224 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14225 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14226 | as_mkdir_p=false |
| 14227 | fi |
| 14228 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14229 | if test -x / >/dev/null 2>&1; then |
| 14230 | as_test_x='test -x' |
| 14231 | else |
| 14232 | if ls -dL / >/dev/null 2>&1; then |
| 14233 | as_ls_L_option=L |
| 14234 | else |
| 14235 | as_ls_L_option= |
| 14236 | fi |
| 14237 | as_test_x=' |
| 14238 | eval sh -c '\'' |
| 14239 | if test -d "$1"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14240 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14241 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14242 | case $1 in #( |
| 14243 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14244 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14245 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14246 | ???[sx]*):;;*)false;;esac;fi |
| 14247 | '\'' sh |
| 14248 | ' |
| 14249 | fi |
| 14250 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14251 | |
| 14252 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14253 | 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] | 14254 | |
| 14255 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14256 | 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] | 14257 | |
| 14258 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14259 | exec 6>&1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14260 | ## ----------------------------------- ## |
| 14261 | ## Main body of $CONFIG_STATUS script. ## |
| 14262 | ## ----------------------------------- ## |
| 14263 | _ASEOF |
| 14264 | 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] | 14265 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14266 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14267 | # 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] | 14268 | # report actual input values of CONFIG_FILES etc. instead of their |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14269 | # values after options handling. |
| 14270 | ac_log=" |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 14271 | This file was extended by python $as_me 3.2, which was |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14272 | generated by GNU Autoconf 2.65. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14273 | |
| 14274 | CONFIG_FILES = $CONFIG_FILES |
| 14275 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 14276 | CONFIG_LINKS = $CONFIG_LINKS |
| 14277 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 14278 | $ $0 $@ |
| 14279 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14280 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 14281 | " |
| 14282 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14283 | _ACEOF |
| 14284 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14285 | case $ac_config_files in *" |
| 14286 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 14287 | esac |
| 14288 | |
| 14289 | case $ac_config_headers in *" |
| 14290 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 14291 | esac |
| 14292 | |
| 14293 | |
| 14294 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14295 | # Files that config.status was made for. |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 14296 | config_files="`echo $ac_config_files`" |
| 14297 | config_headers="`echo $ac_config_headers`" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14298 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14299 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14300 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14301 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14302 | ac_cs_usage="\ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14303 | \`$as_me' instantiates files and other configuration actions |
| 14304 | from templates according to the current configuration. Unless the files |
| 14305 | 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] | 14306 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14307 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14308 | |
| 14309 | -h, --help print this help, then exit |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14310 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14311 | --config print configuration, then exit |
| 14312 | -q, --quiet, --silent |
| 14313 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14314 | -d, --debug don't remove temporary files |
| 14315 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14316 | --file=FILE[:TEMPLATE] |
| 14317 | instantiate the configuration file FILE |
| 14318 | --header=FILE[:TEMPLATE] |
| 14319 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14320 | |
| 14321 | Configuration files: |
| 14322 | $config_files |
| 14323 | |
| 14324 | Configuration headers: |
| 14325 | $config_headers |
| 14326 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14327 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 14328 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14329 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14330 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14331 | 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] | 14332 | ac_cs_version="\\ |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 14333 | python config.status 3.2 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14334 | configured by $0, generated by GNU Autoconf 2.65, |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14335 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14336 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14337 | Copyright (C) 2009 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14338 | This config.status script is free software; the Free Software Foundation |
| 14339 | gives unlimited permission to copy, distribute and modify it." |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14340 | |
| 14341 | ac_pwd='$ac_pwd' |
| 14342 | srcdir='$srcdir' |
| 14343 | INSTALL='$INSTALL' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14344 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14345 | _ACEOF |
| 14346 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14347 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14348 | # 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] | 14349 | ac_need_defaults=: |
| 14350 | while test $# != 0 |
| 14351 | do |
| 14352 | case $1 in |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14353 | --*=*) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14354 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14355 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14356 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14357 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14358 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14359 | ac_option=$1 |
| 14360 | ac_optarg=$2 |
| 14361 | ac_shift=shift |
| 14362 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14363 | esac |
| 14364 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14365 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14366 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14367 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 14368 | ac_cs_recheck=: ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14369 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14370 | $as_echo "$ac_cs_version"; exit ;; |
| 14371 | --config | --confi | --conf | --con | --co | --c ) |
| 14372 | $as_echo "$ac_cs_config"; exit ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14373 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14374 | debug=: ;; |
| 14375 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14376 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14377 | case $ac_optarg in |
| 14378 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14379 | esac |
| 14380 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14381 | ac_need_defaults=false;; |
| 14382 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14383 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14384 | case $ac_optarg in |
| 14385 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14386 | esac |
| 14387 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14388 | ac_need_defaults=false;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14389 | --he | --h) |
| 14390 | # Conflict between --help and --header |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14391 | as_fn_error "ambiguous option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14392 | Try \`$0 --help' for more information.";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14393 | --help | --hel | -h ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14394 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14395 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 14396 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 14397 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14398 | |
| 14399 | # This is an error. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14400 | -*) as_fn_error "unrecognized option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14401 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14402 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14403 | *) as_fn_append ac_config_targets " $1" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14404 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14405 | |
| 14406 | esac |
| 14407 | shift |
| 14408 | done |
| 14409 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14410 | ac_configure_extra_args= |
| 14411 | |
| 14412 | if $ac_cs_silent; then |
| 14413 | exec 6>/dev/null |
| 14414 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 14415 | fi |
| 14416 | |
| 14417 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14418 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14419 | if \$ac_cs_recheck; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14420 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 14421 | shift |
| 14422 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 14423 | CONFIG_SHELL='$SHELL' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14424 | export CONFIG_SHELL |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14425 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14426 | fi |
| 14427 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14428 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14429 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14430 | exec 5>>config.log |
| 14431 | { |
| 14432 | echo |
| 14433 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 14434 | ## Running $as_me. ## |
| 14435 | _ASBOX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14436 | $as_echo "$ac_log" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14437 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14438 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14439 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14440 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14441 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14442 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14443 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14444 | |
| 14445 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14446 | for ac_config_target in $ac_config_targets |
| 14447 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14448 | case $ac_config_target in |
| 14449 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 14450 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 14451 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 14452 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 14453 | "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14454 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 14455 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 14456 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 14457 | "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14458 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14459 | *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14460 | esac |
| 14461 | done |
| 14462 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14463 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14464 | # If the user did not use the arguments to specify the items to instantiate, |
| 14465 | # then the envvar interface is used. Set only those that are not. |
| 14466 | # We use the long form for the default assignment because of an extremely |
| 14467 | # bizarre bug on SunOS 4.1.3. |
| 14468 | if $ac_need_defaults; then |
| 14469 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 14470 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 14471 | fi |
| 14472 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14473 | # Have a temporary directory for convenience. Make it in the build tree |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14474 | # 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] | 14475 | # creating and moving files from /tmp can sometimes cause problems. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14476 | # Hook for its removal unless debugging. |
| 14477 | # Note that there is a small window in which the directory will not be cleaned: |
| 14478 | # 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] | 14479 | $debug || |
| 14480 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14481 | tmp= |
| 14482 | trap 'exit_status=$? |
| 14483 | { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status |
| 14484 | ' 0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14485 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14486 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14487 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14488 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14489 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14490 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14491 | test -n "$tmp" && test -d "$tmp" |
| 14492 | } || |
| 14493 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14494 | tmp=./conf$$-$RANDOM |
| 14495 | (umask 077 && mkdir "$tmp") |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14496 | } || 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] | 14497 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14498 | # Set up the scripts for CONFIG_FILES section. |
| 14499 | # No need to generate them if there are no CONFIG_FILES. |
| 14500 | # This happens for instance with `./config.status config.h'. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14501 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14502 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14503 | |
| 14504 | ac_cr=`echo X | tr X '\015'` |
| 14505 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 14506 | # But we know of no other shell where ac_cr would be empty at this |
| 14507 | # point, so we can use a bashism as a fallback. |
| 14508 | if test "x$ac_cr" = x; then |
| 14509 | eval ac_cr=\$\'\\r\' |
| 14510 | fi |
| 14511 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 14512 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14513 | ac_cs_awk_cr='\r' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14514 | else |
| 14515 | ac_cs_awk_cr=$ac_cr |
| 14516 | fi |
| 14517 | |
| 14518 | echo 'BEGIN {' >"$tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14519 | _ACEOF |
| 14520 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14521 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14522 | { |
| 14523 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 14524 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 14525 | echo "_ACEOF" |
| 14526 | } >conf$$subs.sh || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14527 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 14528 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14529 | ac_delim='%!_!# ' |
| 14530 | for ac_last_try in false false false false false :; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14531 | . ./conf$$subs.sh || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14532 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14533 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14534 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 14535 | if test $ac_delim_n = $ac_delim_num; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14536 | break |
| 14537 | elif $ac_last_try; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14538 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14539 | else |
| 14540 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14541 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14542 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14543 | rm -f conf$$subs.sh |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14544 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14545 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14546 | cat >>"\$tmp/subs1.awk" <<\\_ACAWK && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14547 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14548 | sed -n ' |
| 14549 | h |
| 14550 | s/^/S["/; s/!.*/"]=/ |
| 14551 | p |
| 14552 | g |
| 14553 | s/^[^!]*!// |
| 14554 | :repl |
| 14555 | t repl |
| 14556 | s/'"$ac_delim"'$// |
| 14557 | t delim |
| 14558 | :nl |
| 14559 | h |
| 14560 | s/\(.\{148\}\)..*/\1/ |
| 14561 | t more1 |
| 14562 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 14563 | p |
| 14564 | n |
| 14565 | b repl |
| 14566 | :more1 |
| 14567 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14568 | p |
| 14569 | g |
| 14570 | s/.\{148\}// |
| 14571 | t nl |
| 14572 | :delim |
| 14573 | h |
| 14574 | s/\(.\{148\}\)..*/\1/ |
| 14575 | t more2 |
| 14576 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 14577 | p |
| 14578 | b |
| 14579 | :more2 |
| 14580 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14581 | p |
| 14582 | g |
| 14583 | s/.\{148\}// |
| 14584 | t delim |
| 14585 | ' <conf$$subs.awk | sed ' |
| 14586 | /^[^""]/{ |
| 14587 | N |
| 14588 | s/\n// |
| 14589 | } |
| 14590 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14591 | rm -f conf$$subs.awk |
| 14592 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14593 | _ACAWK |
| 14594 | cat >>"\$tmp/subs1.awk" <<_ACAWK && |
| 14595 | for (key in S) S_is_set[key] = 1 |
| 14596 | FS = "" |
| 14597 | |
| 14598 | } |
| 14599 | { |
| 14600 | line = $ 0 |
| 14601 | nfields = split(line, field, "@") |
| 14602 | substed = 0 |
| 14603 | len = length(field[1]) |
| 14604 | for (i = 2; i < nfields; i++) { |
| 14605 | key = field[i] |
| 14606 | keylen = length(key) |
| 14607 | if (S_is_set[key]) { |
| 14608 | value = S[key] |
| 14609 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 14610 | len += length(value) + length(field[++i]) |
| 14611 | substed = 1 |
| 14612 | } else |
| 14613 | len += 1 + keylen |
| 14614 | } |
| 14615 | |
| 14616 | print line |
| 14617 | } |
| 14618 | |
| 14619 | _ACAWK |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14620 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14621 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14622 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 14623 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 14624 | else |
| 14625 | cat |
| 14626 | fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14627 | || as_fn_error "could not setup config files machinery" "$LINENO" 5 |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14628 | _ACEOF |
| 14629 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14630 | # VPATH may cause trouble with some makes, so we remove $(srcdir), |
| 14631 | # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14632 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 14633 | # (actually we leave an empty line to preserve line numbers). |
| 14634 | if test "x$srcdir" = x.; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14635 | ac_vpsub='/^[ ]*VPATH[ ]*=/{ |
| 14636 | s/:*\$(srcdir):*/:/ |
| 14637 | s/:*\${srcdir}:*/:/ |
| 14638 | s/:*@srcdir@:*/:/ |
| 14639 | s/^\([^=]*=[ ]*\):*/\1/ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14640 | s/:*$// |
| 14641 | s/^[^=]*=[ ]*$// |
| 14642 | }' |
| 14643 | fi |
| 14644 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14645 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14646 | fi # test -n "$CONFIG_FILES" |
| 14647 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14648 | # Set up the scripts for CONFIG_HEADERS section. |
| 14649 | # No need to generate them if there are no CONFIG_HEADERS. |
| 14650 | # This happens for instance with `./config.status Makefile'. |
| 14651 | if test -n "$CONFIG_HEADERS"; then |
| 14652 | cat >"$tmp/defines.awk" <<\_ACAWK || |
| 14653 | BEGIN { |
| 14654 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14655 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14656 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 14657 | # here-document in config.status, that substitutes the proper values into |
| 14658 | # config.h.in to produce config.h. |
| 14659 | |
| 14660 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 14661 | # handling of long lines. |
| 14662 | ac_delim='%!_!# ' |
| 14663 | for ac_last_try in false false :; do |
| 14664 | ac_t=`sed -n "/$ac_delim/p" confdefs.h` |
| 14665 | if test -z "$ac_t"; then |
| 14666 | break |
| 14667 | elif $ac_last_try; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14668 | as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14669 | else |
| 14670 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 14671 | fi |
| 14672 | done |
| 14673 | |
| 14674 | # For the awk script, D is an array of macro values keyed by name, |
| 14675 | # likewise P contains macro parameters if any. Preserve backslash |
| 14676 | # newline sequences. |
| 14677 | |
| 14678 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 14679 | sed -n ' |
| 14680 | s/.\{148\}/&'"$ac_delim"'/g |
| 14681 | t rset |
| 14682 | :rset |
| 14683 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 14684 | t def |
| 14685 | d |
| 14686 | :def |
| 14687 | s/\\$// |
| 14688 | t bsnl |
| 14689 | s/["\\]/\\&/g |
| 14690 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14691 | D["\1"]=" \3"/p |
| 14692 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 14693 | d |
| 14694 | :bsnl |
| 14695 | s/["\\]/\\&/g |
| 14696 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14697 | D["\1"]=" \3\\\\\\n"\\/p |
| 14698 | t cont |
| 14699 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 14700 | t cont |
| 14701 | d |
| 14702 | :cont |
| 14703 | n |
| 14704 | s/.\{148\}/&'"$ac_delim"'/g |
| 14705 | t clear |
| 14706 | :clear |
| 14707 | s/\\$// |
| 14708 | t bsnlc |
| 14709 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 14710 | d |
| 14711 | :bsnlc |
| 14712 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 14713 | b cont |
| 14714 | ' <confdefs.h | sed ' |
| 14715 | s/'"$ac_delim"'/"\\\ |
| 14716 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14717 | |
| 14718 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14719 | for (key in D) D_is_set[key] = 1 |
| 14720 | FS = "" |
| 14721 | } |
| 14722 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 14723 | line = \$ 0 |
| 14724 | split(line, arg, " ") |
| 14725 | if (arg[1] == "#") { |
| 14726 | defundef = arg[2] |
| 14727 | mac1 = arg[3] |
| 14728 | } else { |
| 14729 | defundef = substr(arg[1], 2) |
| 14730 | mac1 = arg[2] |
| 14731 | } |
| 14732 | split(mac1, mac2, "(") #) |
| 14733 | macro = mac2[1] |
| 14734 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 14735 | if (D_is_set[macro]) { |
| 14736 | # Preserve the white space surrounding the "#". |
| 14737 | print prefix "define", macro P[macro] D[macro] |
| 14738 | next |
| 14739 | } else { |
| 14740 | # Replace #undef with comments. This is necessary, for example, |
| 14741 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 14742 | # on some systems where configure will not decide to define it. |
| 14743 | if (defundef == "undef") { |
| 14744 | print "/*", prefix defundef, macro, "*/" |
| 14745 | next |
| 14746 | } |
| 14747 | } |
| 14748 | } |
| 14749 | { print } |
| 14750 | _ACAWK |
| 14751 | _ACEOF |
| 14752 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14753 | as_fn_error "could not setup config headers machinery" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14754 | fi # test -n "$CONFIG_HEADERS" |
| 14755 | |
| 14756 | |
| 14757 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 14758 | shift |
| 14759 | for ac_tag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14760 | do |
| 14761 | case $ac_tag in |
| 14762 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 14763 | esac |
| 14764 | case $ac_mode$ac_tag in |
| 14765 | :[FHL]*:*);; |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14766 | :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14767 | :[FH]-) ac_tag=-:-;; |
| 14768 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 14769 | esac |
| 14770 | ac_save_IFS=$IFS |
| 14771 | IFS=: |
| 14772 | set x $ac_tag |
| 14773 | IFS=$ac_save_IFS |
| 14774 | shift |
| 14775 | ac_file=$1 |
| 14776 | shift |
| 14777 | |
| 14778 | case $ac_mode in |
| 14779 | :L) ac_source=$1;; |
| 14780 | :[FH]) |
| 14781 | ac_file_inputs= |
| 14782 | for ac_f |
| 14783 | do |
| 14784 | case $ac_f in |
| 14785 | -) ac_f="$tmp/stdin";; |
| 14786 | *) # Look for the file first in the build tree, then in the source tree |
| 14787 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 14788 | # because $ac_f cannot contain `:'. |
| 14789 | test -f "$ac_f" || |
| 14790 | case $ac_f in |
| 14791 | [\\/$]*) false;; |
| 14792 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 14793 | esac || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14794 | as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14795 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14796 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 14797 | as_fn_append ac_file_inputs " '$ac_f'" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14798 | done |
| 14799 | |
| 14800 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 14801 | # use $as_me), people would be surprised to read: |
| 14802 | # /* config.h. Generated by config.status. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14803 | configure_input='Generated from '` |
| 14804 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 14805 | `' by configure.' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14806 | if test x"$ac_file" != x-; then |
| 14807 | configure_input="$ac_file. $configure_input" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14808 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 14809 | $as_echo "$as_me: creating $ac_file" >&6;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14810 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14811 | # Neutralize special characters interpreted by sed in replacement strings. |
| 14812 | case $configure_input in #( |
| 14813 | *\&* | *\|* | *\\* ) |
| 14814 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 14815 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 14816 | *) ac_sed_conf_input=$configure_input;; |
| 14817 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14818 | |
| 14819 | case $ac_tag in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14820 | *:-:* | *:-) cat >"$tmp/stdin" \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14821 | || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14822 | esac |
| 14823 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14824 | esac |
| 14825 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14826 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14827 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14828 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 14829 | X"$ac_file" : 'X\(//\)$' \| \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14830 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14831 | $as_echo X"$ac_file" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14832 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14833 | s//\1/ |
| 14834 | q |
| 14835 | } |
| 14836 | /^X\(\/\/\)[^/].*/{ |
| 14837 | s//\1/ |
| 14838 | q |
| 14839 | } |
| 14840 | /^X\(\/\/\)$/{ |
| 14841 | s//\1/ |
| 14842 | q |
| 14843 | } |
| 14844 | /^X\(\/\).*/{ |
| 14845 | s//\1/ |
| 14846 | q |
| 14847 | } |
| 14848 | s/.*/./; q'` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14849 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14850 | ac_builddir=. |
| 14851 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14852 | case "$ac_dir" in |
| 14853 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14854 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14855 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14856 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14857 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14858 | case $ac_top_builddir_sub in |
| 14859 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 14860 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 14861 | esac ;; |
| 14862 | esac |
| 14863 | ac_abs_top_builddir=$ac_pwd |
| 14864 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 14865 | # for backward compatibility: |
| 14866 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14867 | |
| 14868 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14869 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14870 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14871 | ac_top_srcdir=$ac_top_builddir_sub |
| 14872 | ac_abs_top_srcdir=$ac_pwd ;; |
| 14873 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14874 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14875 | ac_top_srcdir=$srcdir |
| 14876 | ac_abs_top_srcdir=$srcdir ;; |
| 14877 | *) # Relative name. |
| 14878 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 14879 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 14880 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14881 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14882 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14883 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14884 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14885 | case $ac_mode in |
| 14886 | :F) |
| 14887 | # |
| 14888 | # CONFIG_FILE |
| 14889 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14890 | |
| 14891 | case $INSTALL in |
| 14892 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14893 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14894 | esac |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 14895 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14896 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14897 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14898 | # If the template does not know about datarootdir, expand it. |
| 14899 | # FIXME: This hack should be removed a few years after 2.60. |
| 14900 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14901 | ac_sed_dataroot=' |
| 14902 | /datarootdir/ { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14903 | p |
| 14904 | q |
| 14905 | } |
| 14906 | /@datadir@/p |
| 14907 | /@docdir@/p |
| 14908 | /@infodir@/p |
| 14909 | /@localedir@/p |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14910 | /@mandir@/p' |
| 14911 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14912 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 14913 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14914 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 14915 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14916 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14917 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14918 | ac_datarootdir_hack=' |
| 14919 | s&@datadir@&$datadir&g |
| 14920 | s&@docdir@&$docdir&g |
| 14921 | s&@infodir@&$infodir&g |
| 14922 | s&@localedir@&$localedir&g |
| 14923 | s&@mandir@&$mandir&g |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14924 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14925 | esac |
| 14926 | _ACEOF |
| 14927 | |
| 14928 | # Neutralize VPATH when `$srcdir' = `.'. |
| 14929 | # Shell code in configure.ac might set extrasub. |
| 14930 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14931 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14932 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14933 | $extrasub |
| 14934 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14935 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14936 | :t |
| 14937 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14938 | s|@configure_input@|$ac_sed_conf_input|;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14939 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14940 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14941 | s&@srcdir@&$ac_srcdir&;t t |
| 14942 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 14943 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 14944 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 14945 | s&@builddir@&$ac_builddir&;t t |
| 14946 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 14947 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 14948 | s&@INSTALL@&$ac_INSTALL&;t t |
| 14949 | $ac_datarootdir_hack |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14950 | " |
| 14951 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14952 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14953 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14954 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
| 14955 | { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && |
| 14956 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14957 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14958 | which seems to be undefined. Please make sure it is defined." >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14959 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14960 | which seems to be undefined. Please make sure it is defined." >&2;} |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 14961 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14962 | rm -f "$tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14963 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14964 | -) cat "$tmp/out" && rm -f "$tmp/out";; |
| 14965 | *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; |
| 14966 | esac \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14967 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14968 | ;; |
| 14969 | :H) |
| 14970 | # |
| 14971 | # CONFIG_HEADER |
| 14972 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14973 | if test x"$ac_file" != x-; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14974 | { |
| 14975 | $as_echo "/* $configure_input */" \ |
| 14976 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" |
| 14977 | } >"$tmp/config.h" \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14978 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14979 | if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then |
| 14980 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 14981 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14983 | rm -f "$ac_file" |
| 14984 | mv "$tmp/config.h" "$ac_file" \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14985 | || as_fn_error "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14986 | fi |
| 14987 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14988 | $as_echo "/* $configure_input */" \ |
| 14989 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 14990 | || as_fn_error "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14991 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14992 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 14993 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14994 | |
| 14995 | esac |
| 14996 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 14997 | |
| 14998 | case $ac_file$ac_mode in |
| 14999 | "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;; |
| 15000 | |
| 15001 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15002 | done # for ac_tag |
| 15003 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15004 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15005 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15006 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15007 | ac_clean_files=$ac_clean_files_save |
| 15008 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15009 | test $ac_write_fail = 0 || |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 15010 | as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15011 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15012 | |
| 15013 | # configure is writing to config.log, and then calls config.status. |
| 15014 | # config.status does its own redirection, appending to config.log. |
| 15015 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 15016 | # by configure, so config.status won't be able to write to it; its |
| 15017 | # output is simply discarded. So we exec the FD to /dev/null, |
| 15018 | # effectively closing config.log, so it can be properly (re)opened and |
| 15019 | # appended to by config.status. When coming back to configure, we |
| 15020 | # need to make the FD available again. |
| 15021 | if test "$no_create" != yes; then |
| 15022 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15023 | ac_config_status_args= |
| 15024 | test "$silent" = yes && |
| 15025 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15026 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15027 | $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] | 15028 | exec 5>>config.log |
| 15029 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 15030 | # would make configure fail if this is the last instruction. |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 15031 | $ac_cs_success || as_fn_exit $? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15032 | fi |
| 15033 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 15034 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 15035 | $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] | 15036 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15037 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15038 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15039 | echo "creating Modules/Setup" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15040 | if test ! -f Modules/Setup |
| 15041 | then |
| 15042 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 15043 | fi |
| 15044 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15045 | echo "creating Modules/Setup.local" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15046 | if test ! -f Modules/Setup.local |
| 15047 | then |
| 15048 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 15049 | fi |
| 15050 | |
| 15051 | echo "creating Makefile" |
| 15052 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 15053 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 15054 | Modules/Setup.local Modules/Setup |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 15055 | mv config.c Modules |