Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2 | # Guess values for system-dependent variables and create Makefiles. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3 | # Generated by GNU Autoconf 2.67 for python 3.3. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4 | # |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 5 | # Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 6 | # |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7 | # |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 9 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software |
| 10 | # Foundation, Inc. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11 | # |
| 12 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13 | # This configure script is free software; the Free Software Foundation |
| 14 | # gives unlimited permission to copy, distribute and modify it. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15 | ## -------------------- ## |
| 16 | ## M4sh Initialization. ## |
| 17 | ## -------------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 18 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 19 | # Be more Bourne compatible |
| 20 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 21 | 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] | 22 | emulate sh |
| 23 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 24 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 25 | # is contrary to our usage. Disable this feature. |
| 26 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 27 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 28 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 29 | case `(set -o) 2>/dev/null` in #( |
| 30 | *posix*) : |
| 31 | set -o posix ;; #( |
| 32 | *) : |
| 33 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 34 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 35 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 36 | |
| 37 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 38 | as_nl=' |
| 39 | ' |
| 40 | export as_nl |
| 41 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 42 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 43 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 44 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 45 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 46 | # but without wasting forks for bash or zsh. |
| 47 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 48 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 49 | as_echo='print -r --' |
| 50 | as_echo_n='print -rn --' |
| 51 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 52 | as_echo='printf %s\n' |
| 53 | as_echo_n='printf %s' |
| 54 | else |
| 55 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 56 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 57 | as_echo_n='/usr/ucb/echo -n' |
| 58 | else |
| 59 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 60 | as_echo_n_body='eval |
| 61 | arg=$1; |
| 62 | case $arg in #( |
| 63 | *"$as_nl"*) |
| 64 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 65 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 66 | esac; |
| 67 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 68 | ' |
| 69 | export as_echo_n_body |
| 70 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 71 | fi |
| 72 | export as_echo_body |
| 73 | as_echo='sh -c $as_echo_body as_echo' |
| 74 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 75 | |
| 76 | # The user is always right. |
| 77 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 78 | PATH_SEPARATOR=: |
| 79 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 80 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 81 | PATH_SEPARATOR=';' |
| 82 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 83 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 84 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 85 | |
| 86 | # IFS |
| 87 | # We need space, tab and new line, in precisely that order. Quoting is |
| 88 | # there to prevent editors from complaining about space-tab. |
| 89 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 90 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 91 | IFS=" "" $as_nl" |
| 92 | |
| 93 | # 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] | 94 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 95 | *[\\/]* ) as_myself=$0 ;; |
| 96 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 97 | for as_dir in $PATH |
| 98 | do |
| 99 | IFS=$as_save_IFS |
| 100 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 101 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 102 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 103 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 104 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 105 | ;; |
| 106 | esac |
| 107 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 108 | # in which case we are not to be found in the path. |
| 109 | if test "x$as_myself" = x; then |
| 110 | as_myself=$0 |
| 111 | fi |
| 112 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 113 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 114 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 115 | fi |
| 116 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 117 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 118 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 119 | # suppresses any "Segmentation fault" message there. '((' could |
| 120 | # trigger a bug in pdksh 5.2.14. |
| 121 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 122 | do eval test x\${$as_var+set} = xset \ |
| 123 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 124 | done |
| 125 | PS1='$ ' |
| 126 | PS2='> ' |
| 127 | PS4='+ ' |
| 128 | |
| 129 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 130 | LC_ALL=C |
| 131 | export LC_ALL |
| 132 | LANGUAGE=C |
| 133 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 134 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 135 | # CDPATH. |
| 136 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 137 | |
| 138 | if test "x$CONFIG_SHELL" = x; then |
| 139 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 140 | emulate sh |
| 141 | NULLCMD=: |
| 142 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 143 | # is contrary to our usage. Disable this feature. |
| 144 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 145 | setopt NO_GLOB_SUBST |
| 146 | else |
| 147 | case \`(set -o) 2>/dev/null\` in #( |
| 148 | *posix*) : |
| 149 | set -o posix ;; #( |
| 150 | *) : |
| 151 | ;; |
| 152 | esac |
| 153 | fi |
| 154 | " |
| 155 | as_required="as_fn_return () { (exit \$1); } |
| 156 | as_fn_success () { as_fn_return 0; } |
| 157 | as_fn_failure () { as_fn_return 1; } |
| 158 | as_fn_ret_success () { return 0; } |
| 159 | as_fn_ret_failure () { return 1; } |
| 160 | |
| 161 | exitcode=0 |
| 162 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 163 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 164 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 165 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 166 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 167 | |
| 168 | else |
| 169 | exitcode=1; echo positional parameters were not saved. |
| 170 | fi |
| 171 | test x\$exitcode = x0 || exit 1" |
| 172 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 173 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 174 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 175 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 176 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 177 | if (eval "$as_required") 2>/dev/null; then : |
| 178 | as_have_required=yes |
| 179 | else |
| 180 | as_have_required=no |
| 181 | fi |
| 182 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 183 | |
| 184 | else |
| 185 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 186 | as_found=false |
| 187 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 188 | do |
| 189 | IFS=$as_save_IFS |
| 190 | test -z "$as_dir" && as_dir=. |
| 191 | as_found=: |
| 192 | case $as_dir in #( |
| 193 | /*) |
| 194 | for as_base in sh bash ksh sh5; do |
| 195 | # Try only shells that exist, to save several forks. |
| 196 | as_shell=$as_dir/$as_base |
| 197 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 198 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 199 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 200 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 201 | break 2 |
| 202 | fi |
| 203 | fi |
| 204 | done;; |
| 205 | esac |
| 206 | as_found=false |
| 207 | done |
| 208 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 209 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 210 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 211 | fi; } |
| 212 | IFS=$as_save_IFS |
| 213 | |
| 214 | |
| 215 | if test "x$CONFIG_SHELL" != x; then : |
| 216 | # We cannot yet assume a decent shell, so we have to provide a |
| 217 | # neutralization value for shells without unset; and this also |
| 218 | # works around shells that cannot unset nonexistent variables. |
| 219 | BASH_ENV=/dev/null |
| 220 | ENV=/dev/null |
| 221 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 222 | export CONFIG_SHELL |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 223 | exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 224 | fi |
| 225 | |
| 226 | if test x$as_have_required = xno; then : |
| 227 | $as_echo "$0: This script requires a shell more modern than all" |
| 228 | $as_echo "$0: the shells that I found on your system." |
| 229 | if test x${ZSH_VERSION+set} = xset ; then |
| 230 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 231 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 232 | else |
| 233 | $as_echo "$0: Please tell bug-autoconf@gnu.org and |
| 234 | $0: http://bugs.python.org/ about your system, including |
| 235 | $0: any error possibly output before this message. Then |
| 236 | $0: install a modern shell, or manually run the script |
| 237 | $0: under such a shell if you do have one." |
| 238 | fi |
| 239 | exit 1 |
| 240 | fi |
| 241 | fi |
| 242 | fi |
| 243 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 244 | export SHELL |
| 245 | # Unset more variables known to interfere with behavior of common tools. |
| 246 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 247 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 248 | |
| 249 | ## --------------------- ## |
| 250 | ## M4sh Shell Functions. ## |
| 251 | ## --------------------- ## |
| 252 | # as_fn_unset VAR |
| 253 | # --------------- |
| 254 | # Portably unset VAR. |
| 255 | as_fn_unset () |
| 256 | { |
| 257 | { eval $1=; unset $1;} |
| 258 | } |
| 259 | as_unset=as_fn_unset |
| 260 | |
| 261 | # as_fn_set_status STATUS |
| 262 | # ----------------------- |
| 263 | # Set $? to STATUS, without forking. |
| 264 | as_fn_set_status () |
| 265 | { |
| 266 | return $1 |
| 267 | } # as_fn_set_status |
| 268 | |
| 269 | # as_fn_exit STATUS |
| 270 | # ----------------- |
| 271 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 272 | as_fn_exit () |
| 273 | { |
| 274 | set +e |
| 275 | as_fn_set_status $1 |
| 276 | exit $1 |
| 277 | } # as_fn_exit |
| 278 | |
| 279 | # as_fn_mkdir_p |
| 280 | # ------------- |
| 281 | # Create "$as_dir" as a directory, including parents if necessary. |
| 282 | as_fn_mkdir_p () |
| 283 | { |
| 284 | |
| 285 | case $as_dir in #( |
| 286 | -*) as_dir=./$as_dir;; |
| 287 | esac |
| 288 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 289 | as_dirs= |
| 290 | while :; do |
| 291 | case $as_dir in #( |
| 292 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 293 | *) as_qdir=$as_dir;; |
| 294 | esac |
| 295 | as_dirs="'$as_qdir' $as_dirs" |
| 296 | as_dir=`$as_dirname -- "$as_dir" || |
| 297 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 298 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 299 | X"$as_dir" : 'X\(//\)$' \| \ |
| 300 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 301 | $as_echo X"$as_dir" | |
| 302 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 303 | s//\1/ |
| 304 | q |
| 305 | } |
| 306 | /^X\(\/\/\)[^/].*/{ |
| 307 | s//\1/ |
| 308 | q |
| 309 | } |
| 310 | /^X\(\/\/\)$/{ |
| 311 | s//\1/ |
| 312 | q |
| 313 | } |
| 314 | /^X\(\/\).*/{ |
| 315 | s//\1/ |
| 316 | q |
| 317 | } |
| 318 | s/.*/./; q'` |
| 319 | test -d "$as_dir" && break |
| 320 | done |
| 321 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 322 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 323 | |
| 324 | |
| 325 | } # as_fn_mkdir_p |
| 326 | # as_fn_append VAR VALUE |
| 327 | # ---------------------- |
| 328 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 329 | # advantage of any shell optimizations that allow amortized linear growth over |
| 330 | # repeated appends, instead of the typical quadratic growth present in naive |
| 331 | # implementations. |
| 332 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 333 | eval 'as_fn_append () |
| 334 | { |
| 335 | eval $1+=\$2 |
| 336 | }' |
| 337 | else |
| 338 | as_fn_append () |
| 339 | { |
| 340 | eval $1=\$$1\$2 |
| 341 | } |
| 342 | fi # as_fn_append |
| 343 | |
| 344 | # as_fn_arith ARG... |
| 345 | # ------------------ |
| 346 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 347 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 348 | # must be portable across $(()) and expr. |
| 349 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 350 | eval 'as_fn_arith () |
| 351 | { |
| 352 | as_val=$(( $* )) |
| 353 | }' |
| 354 | else |
| 355 | as_fn_arith () |
| 356 | { |
| 357 | as_val=`expr "$@" || test $? -eq 1` |
| 358 | } |
| 359 | fi # as_fn_arith |
| 360 | |
| 361 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 362 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 363 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 364 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 365 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 366 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 367 | as_fn_error () |
| 368 | { |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 369 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 370 | if test "$4"; then |
| 371 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 372 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 373 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 374 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 375 | as_fn_exit $as_status |
| 376 | } # as_fn_error |
| 377 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 378 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 379 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 380 | as_expr=expr |
| 381 | else |
| 382 | as_expr=false |
| 383 | fi |
| 384 | |
| 385 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 386 | as_basename=basename |
| 387 | else |
| 388 | as_basename=false |
| 389 | fi |
| 390 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 391 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 392 | as_dirname=dirname |
| 393 | else |
| 394 | as_dirname=false |
| 395 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 396 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 397 | as_me=`$as_basename -- "$0" || |
| 398 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 399 | X"$0" : 'X\(//\)$' \| \ |
| 400 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 401 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 402 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 403 | s//\1/ |
| 404 | q |
| 405 | } |
| 406 | /^X\/\(\/\/\)$/{ |
| 407 | s//\1/ |
| 408 | q |
| 409 | } |
| 410 | /^X\/\(\/\).*/{ |
| 411 | s//\1/ |
| 412 | q |
| 413 | } |
| 414 | s/.*/./; q'` |
| 415 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 416 | # Avoid depending upon Character Ranges. |
| 417 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 418 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 419 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 420 | as_cr_digits='0123456789' |
| 421 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 422 | |
| 423 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 424 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 425 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 426 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 427 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 428 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 429 | sed -n ' |
| 430 | p |
| 431 | /[$]LINENO/= |
| 432 | ' <$as_myself | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 433 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 434 | s/[$]LINENO.*/&-/ |
| 435 | t lineno |
| 436 | b |
| 437 | :lineno |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 438 | N |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 439 | :loop |
| 440 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 441 | t loop |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 442 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 443 | ' >$as_me.lineno && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 444 | chmod +x "$as_me.lineno" || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 445 | { $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] | 446 | |
| 447 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 448 | # (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] | 449 | # original and so on. Autoconf is especially sensitive to this). |
| 450 | . "./$as_me.lineno" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 451 | # Exit status is that of the last command. |
| 452 | exit |
| 453 | } |
| 454 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 455 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 456 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 457 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 458 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 459 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 460 | xy) ECHO_C='\c';; |
| 461 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 462 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 463 | esac;; |
| 464 | *) |
| 465 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 466 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 467 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 468 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 469 | if test -d conf$$.dir; then |
| 470 | rm -f conf$$.dir/conf$$.file |
| 471 | else |
| 472 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 473 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 474 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 475 | if (echo >conf$$.file) 2>/dev/null; then |
| 476 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 477 | as_ln_s='ln -s' |
| 478 | # ... but there are two gotchas: |
| 479 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 480 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 481 | # In both cases, we have to default to `cp -p'. |
| 482 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 483 | as_ln_s='cp -p' |
| 484 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 485 | as_ln_s=ln |
| 486 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 487 | as_ln_s='cp -p' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 488 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 489 | else |
| 490 | as_ln_s='cp -p' |
| 491 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 492 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 493 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 494 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 495 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 496 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 497 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 498 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 499 | as_mkdir_p=false |
| 500 | fi |
| 501 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 502 | if test -x / >/dev/null 2>&1; then |
| 503 | as_test_x='test -x' |
| 504 | else |
| 505 | if ls -dL / >/dev/null 2>&1; then |
| 506 | as_ls_L_option=L |
| 507 | else |
| 508 | as_ls_L_option= |
| 509 | fi |
| 510 | as_test_x=' |
| 511 | eval sh -c '\'' |
| 512 | if test -d "$1"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 513 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 514 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 515 | case $1 in #( |
| 516 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 517 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 518 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 519 | ???[sx]*):;;*)false;;esac;fi |
| 520 | '\'' sh |
| 521 | ' |
| 522 | fi |
| 523 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 524 | |
| 525 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 526 | 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] | 527 | |
| 528 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 529 | 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] | 530 | |
| 531 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 532 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 533 | exec 6>&1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 534 | |
| 535 | # Name of the host. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 536 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 537 | # so uname gets run too. |
| 538 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 539 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 540 | # |
| 541 | # Initializations. |
| 542 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 543 | ac_default_prefix=/usr/local |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 544 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 545 | ac_config_libobj_dir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 546 | LIBOBJS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 547 | cross_compiling=no |
| 548 | subdirs= |
| 549 | MFLAGS= |
| 550 | MAKEFLAGS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 551 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 552 | # Identity of this package. |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 553 | PACKAGE_NAME='python' |
| 554 | PACKAGE_TARNAME='python' |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 555 | PACKAGE_VERSION='3.3' |
| 556 | PACKAGE_STRING='python 3.3' |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 557 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 558 | PACKAGE_URL='' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 559 | |
| 560 | ac_unique_file="Include/object.h" |
| 561 | # Factoring default headers for most tests. |
| 562 | ac_includes_default="\ |
| 563 | #include <stdio.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 564 | #ifdef HAVE_SYS_TYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 565 | # include <sys/types.h> |
| 566 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 567 | #ifdef HAVE_SYS_STAT_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 568 | # include <sys/stat.h> |
| 569 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 570 | #ifdef STDC_HEADERS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 571 | # include <stdlib.h> |
| 572 | # include <stddef.h> |
| 573 | #else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 574 | # ifdef HAVE_STDLIB_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 575 | # include <stdlib.h> |
| 576 | # endif |
| 577 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 578 | #ifdef HAVE_STRING_H |
| 579 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 580 | # include <memory.h> |
| 581 | # endif |
| 582 | # include <string.h> |
| 583 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 584 | #ifdef HAVE_STRINGS_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 585 | # include <strings.h> |
| 586 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 587 | #ifdef HAVE_INTTYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 588 | # include <inttypes.h> |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 589 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 590 | #ifdef HAVE_STDINT_H |
| 591 | # include <stdint.h> |
| 592 | #endif |
| 593 | #ifdef HAVE_UNISTD_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 594 | # include <unistd.h> |
| 595 | #endif" |
| 596 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 597 | ac_subst_vars='LTLIBOBJS |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 598 | SRCDIRS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 599 | THREADHEADERS |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 600 | SOABI |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 601 | LIBC |
| 602 | LIBM |
| 603 | HAVE_GETHOSTBYNAME |
| 604 | HAVE_GETHOSTBYNAME_R |
| 605 | HAVE_GETHOSTBYNAME_R_3_ARG |
| 606 | HAVE_GETHOSTBYNAME_R_5_ARG |
| 607 | HAVE_GETHOSTBYNAME_R_6_ARG |
| 608 | LIBOBJS |
| 609 | TRUE |
| 610 | MACHDEP_OBJS |
| 611 | DYNLOADFILE |
| 612 | DLINCLDIR |
| 613 | THREADOBJ |
| 614 | LDLAST |
| 615 | USE_THREAD_MODULE |
| 616 | SIGNAL_OBJS |
| 617 | USE_SIGNAL_MODULE |
| 618 | LIBFFI_INCLUDEDIR |
| 619 | PKG_CONFIG |
| 620 | SHLIBS |
| 621 | CFLAGSFORSHARED |
| 622 | LINKFORSHARED |
| 623 | CCSHARED |
| 624 | BLDSHARED |
| 625 | LDCXXSHARED |
| 626 | LDSHARED |
| 627 | SO |
| 628 | LIBTOOL_CRUFT |
| 629 | OTHER_LIBTOOL_OPT |
| 630 | UNIVERSAL_ARCH_FLAGS |
| 631 | BASECFLAGS |
| 632 | OPT |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 633 | ABIFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 634 | LN |
| 635 | INSTALL_DATA |
| 636 | INSTALL_SCRIPT |
| 637 | INSTALL_PROGRAM |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 638 | HAS_PYTHON |
| 639 | DISABLE_ASDLGEN |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 640 | ARFLAGS |
| 641 | AR |
| 642 | RANLIB |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 643 | USE_INLINE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 644 | GNULD |
| 645 | LINKCC |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 646 | LDVERSION |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 647 | RUNSHARED |
| 648 | INSTSONAME |
| 649 | LDLIBRARYDIR |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 650 | PY3LIBRARY |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 651 | BLDLIBRARY |
| 652 | DLLLIBRARY |
| 653 | LDLIBRARY |
| 654 | LIBRARY |
| 655 | BUILDEXEEXT |
| 656 | EGREP |
| 657 | GREP |
| 658 | CPP |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 659 | NO_AS_NEEDED |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 660 | MAINCC |
| 661 | CXX |
| 662 | OBJEXT |
| 663 | EXEEXT |
| 664 | ac_ct_CC |
| 665 | CPPFLAGS |
| 666 | LDFLAGS |
| 667 | CFLAGS |
| 668 | CC |
| 669 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 670 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 671 | SGI_ABI |
| 672 | MACHDEP |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 673 | FRAMEWORKINSTALLAPPSPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 674 | FRAMEWORKUNIXTOOLSPREFIX |
| 675 | FRAMEWORKALTINSTALLLAST |
| 676 | FRAMEWORKALTINSTALLFIRST |
| 677 | FRAMEWORKINSTALLLAST |
| 678 | FRAMEWORKINSTALLFIRST |
| 679 | PYTHONFRAMEWORKINSTALLDIR |
| 680 | PYTHONFRAMEWORKPREFIX |
| 681 | PYTHONFRAMEWORKDIR |
| 682 | PYTHONFRAMEWORKIDENTIFIER |
| 683 | PYTHONFRAMEWORK |
| 684 | LIPO_32BIT_FLAGS |
| 685 | ARCH_RUN_32BIT |
| 686 | UNIVERSALSDK |
| 687 | CONFIG_ARGS |
| 688 | SOVERSION |
| 689 | VERSION |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 690 | HAS_HG |
| 691 | HGBRANCH |
| 692 | HGTAG |
| 693 | HGVERSION |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 694 | target_alias |
| 695 | host_alias |
| 696 | build_alias |
| 697 | LIBS |
| 698 | ECHO_T |
| 699 | ECHO_N |
| 700 | ECHO_C |
| 701 | DEFS |
| 702 | mandir |
| 703 | localedir |
| 704 | libdir |
| 705 | psdir |
| 706 | pdfdir |
| 707 | dvidir |
| 708 | htmldir |
| 709 | infodir |
| 710 | docdir |
| 711 | oldincludedir |
| 712 | includedir |
| 713 | localstatedir |
| 714 | sharedstatedir |
| 715 | sysconfdir |
| 716 | datadir |
| 717 | datarootdir |
| 718 | libexecdir |
| 719 | sbindir |
| 720 | bindir |
| 721 | program_transform_name |
| 722 | prefix |
| 723 | exec_prefix |
| 724 | PACKAGE_URL |
| 725 | PACKAGE_BUGREPORT |
| 726 | PACKAGE_STRING |
| 727 | PACKAGE_VERSION |
| 728 | PACKAGE_TARNAME |
| 729 | PACKAGE_NAME |
| 730 | PATH_SEPARATOR |
| 731 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 732 | ac_subst_files='' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 733 | ac_user_opts=' |
| 734 | enable_option_checking |
| 735 | enable_universalsdk |
| 736 | with_universal_archs |
| 737 | with_framework_name |
| 738 | enable_framework |
| 739 | with_gcc |
| 740 | with_cxx_main |
| 741 | with_suffix |
| 742 | enable_shared |
| 743 | enable_profiling |
| 744 | with_pydebug |
| 745 | with_libs |
| 746 | with_system_expat |
| 747 | with_system_ffi |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 748 | enable_loadable_sqlite_extensions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 749 | with_dbmliborder |
| 750 | with_signal_module |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 751 | with_threads |
| 752 | with_thread |
| 753 | enable_ipv6 |
| 754 | with_doc_strings |
| 755 | with_tsc |
| 756 | with_pymalloc |
| 757 | with_valgrind |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 758 | with_fpectl |
| 759 | with_libm |
| 760 | with_libc |
| 761 | enable_big_digits |
| 762 | with_wide_unicode |
| 763 | with_computed_gotos |
| 764 | ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 765 | ac_precious_vars='build_alias |
| 766 | host_alias |
| 767 | target_alias |
| 768 | CC |
| 769 | CFLAGS |
| 770 | LDFLAGS |
| 771 | LIBS |
| 772 | CPPFLAGS |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 773 | CPP' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 774 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 775 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 776 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 777 | ac_init_help= |
| 778 | ac_init_version=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 779 | ac_unrecognized_opts= |
| 780 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 781 | # The variables have the same names as the options, with |
| 782 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 783 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 784 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 785 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 786 | no_recursion= |
| 787 | prefix=NONE |
| 788 | program_prefix=NONE |
| 789 | program_suffix=NONE |
| 790 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 791 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 792 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 793 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 794 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 795 | x_includes=NONE |
| 796 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 797 | |
| 798 | # Installation directory options. |
| 799 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 800 | # and all the variables that are supposed to be based on exec_prefix |
| 801 | # by default will actually change. |
| 802 | # Use braces instead of parens because sh, perl, etc. also accept them. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 803 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 804 | bindir='${exec_prefix}/bin' |
| 805 | sbindir='${exec_prefix}/sbin' |
| 806 | libexecdir='${exec_prefix}/libexec' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 807 | datarootdir='${prefix}/share' |
| 808 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 809 | sysconfdir='${prefix}/etc' |
| 810 | sharedstatedir='${prefix}/com' |
| 811 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 812 | includedir='${prefix}/include' |
| 813 | oldincludedir='/usr/include' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 814 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 815 | infodir='${datarootdir}/info' |
| 816 | htmldir='${docdir}' |
| 817 | dvidir='${docdir}' |
| 818 | pdfdir='${docdir}' |
| 819 | psdir='${docdir}' |
| 820 | libdir='${exec_prefix}/lib' |
| 821 | localedir='${datarootdir}/locale' |
| 822 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 823 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 824 | ac_prev= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 825 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 826 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 827 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 828 | # If the previous option needs an argument, assign it. |
| 829 | if test -n "$ac_prev"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 830 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 831 | ac_prev= |
| 832 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 833 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 834 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 835 | case $ac_option in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 836 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 837 | *=) ac_optarg= ;; |
| 838 | *) ac_optarg=yes ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 839 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 840 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 841 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 842 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 843 | case $ac_dashdash$ac_option in |
| 844 | --) |
| 845 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 846 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 847 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 848 | ac_prev=bindir ;; |
| 849 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 850 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 851 | |
| 852 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 853 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 854 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 855 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 856 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 857 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 858 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 859 | ac_prev=cache_file ;; |
| 860 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 861 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 862 | cache_file=$ac_optarg ;; |
| 863 | |
| 864 | --config-cache | -C) |
| 865 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 866 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 867 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 868 | ac_prev=datadir ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 869 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 870 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 871 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 872 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 873 | | --dataroo | --dataro | --datar) |
| 874 | ac_prev=datarootdir ;; |
| 875 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 876 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 877 | datarootdir=$ac_optarg ;; |
| 878 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 879 | -disable-* | --disable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 880 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 881 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 882 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 883 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 884 | ac_useropt_orig=$ac_useropt |
| 885 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 886 | case $ac_user_opts in |
| 887 | *" |
| 888 | "enable_$ac_useropt" |
| 889 | "*) ;; |
| 890 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 891 | ac_unrecognized_sep=', ';; |
| 892 | esac |
| 893 | eval enable_$ac_useropt=no ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 894 | |
| 895 | -docdir | --docdir | --docdi | --doc | --do) |
| 896 | ac_prev=docdir ;; |
| 897 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 898 | docdir=$ac_optarg ;; |
| 899 | |
| 900 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 901 | ac_prev=dvidir ;; |
| 902 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 903 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 904 | |
| 905 | -enable-* | --enable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 906 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 907 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 908 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 909 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 910 | ac_useropt_orig=$ac_useropt |
| 911 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 912 | case $ac_user_opts in |
| 913 | *" |
| 914 | "enable_$ac_useropt" |
| 915 | "*) ;; |
| 916 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 917 | ac_unrecognized_sep=', ';; |
| 918 | esac |
| 919 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 920 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 921 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 922 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 923 | | --exec | --exe | --ex) |
| 924 | ac_prev=exec_prefix ;; |
| 925 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 926 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 927 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 928 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 929 | |
| 930 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 931 | # Obsolete; use --with-gas. |
| 932 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 933 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 934 | -help | --help | --hel | --he | -h) |
| 935 | ac_init_help=long ;; |
| 936 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 937 | ac_init_help=recursive ;; |
| 938 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 939 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 940 | |
| 941 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 942 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 943 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 944 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 945 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 946 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 947 | ac_prev=htmldir ;; |
| 948 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 949 | | --ht=*) |
| 950 | htmldir=$ac_optarg ;; |
| 951 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 952 | -includedir | --includedir | --includedi | --included | --include \ |
| 953 | | --includ | --inclu | --incl | --inc) |
| 954 | ac_prev=includedir ;; |
| 955 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 956 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 957 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 958 | |
| 959 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 960 | ac_prev=infodir ;; |
| 961 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 962 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 963 | |
| 964 | -libdir | --libdir | --libdi | --libd) |
| 965 | ac_prev=libdir ;; |
| 966 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 967 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 968 | |
| 969 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 970 | | --libexe | --libex | --libe) |
| 971 | ac_prev=libexecdir ;; |
| 972 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 973 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 974 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 975 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 976 | -localedir | --localedir | --localedi | --localed | --locale) |
| 977 | ac_prev=localedir ;; |
| 978 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 979 | localedir=$ac_optarg ;; |
| 980 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 981 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 982 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 983 | ac_prev=localstatedir ;; |
| 984 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 985 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 986 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 987 | |
| 988 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 989 | ac_prev=mandir ;; |
| 990 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 991 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 992 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 993 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 994 | # Obsolete; use --without-fp. |
| 995 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 996 | |
| 997 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 998 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 999 | no_create=yes ;; |
| 1000 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1001 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 1002 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 1003 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1004 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1005 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 1006 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 1007 | | --oldin | --oldi | --old | --ol | --o) |
| 1008 | ac_prev=oldincludedir ;; |
| 1009 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1010 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1011 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1012 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1013 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1014 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1015 | ac_prev=prefix ;; |
| 1016 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1017 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1018 | |
| 1019 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1020 | | --program-pre | --program-pr | --program-p) |
| 1021 | ac_prev=program_prefix ;; |
| 1022 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1023 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1024 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1025 | |
| 1026 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1027 | | --program-suf | --program-su | --program-s) |
| 1028 | ac_prev=program_suffix ;; |
| 1029 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1030 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1031 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1032 | |
| 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) |
| 1040 | ac_prev=program_transform_name ;; |
| 1041 | -program-transform-name=* | --program-transform-name=* \ |
| 1042 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1043 | | --program-transform-n=* | --program-transform-=* \ |
| 1044 | | --program-transform=* | --program-transfor=* \ |
| 1045 | | --program-transfo=* | --program-transf=* \ |
| 1046 | | --program-trans=* | --program-tran=* \ |
| 1047 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1048 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1049 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1050 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1051 | ac_prev=pdfdir ;; |
| 1052 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1053 | pdfdir=$ac_optarg ;; |
| 1054 | |
| 1055 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1056 | ac_prev=psdir ;; |
| 1057 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1058 | psdir=$ac_optarg ;; |
| 1059 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1060 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1061 | | -silent | --silent | --silen | --sile | --sil) |
| 1062 | silent=yes ;; |
| 1063 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1064 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1065 | ac_prev=sbindir ;; |
| 1066 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1067 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1068 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1069 | |
| 1070 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1071 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1072 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1073 | | --sha | --sh) |
| 1074 | ac_prev=sharedstatedir ;; |
| 1075 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1076 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1077 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1078 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1079 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1080 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1081 | -site | --site | --sit) |
| 1082 | ac_prev=site ;; |
| 1083 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1084 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1085 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1086 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1087 | ac_prev=srcdir ;; |
| 1088 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1089 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1090 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1091 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1092 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1093 | ac_prev=sysconfdir ;; |
| 1094 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1095 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1096 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1097 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1098 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1099 | ac_prev=target_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1100 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1101 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1102 | |
| 1103 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1104 | verbose=yes ;; |
| 1105 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1106 | -version | --version | --versio | --versi | --vers | -V) |
| 1107 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1108 | |
| 1109 | -with-* | --with-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1110 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1111 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1112 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1113 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1114 | ac_useropt_orig=$ac_useropt |
| 1115 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1116 | case $ac_user_opts in |
| 1117 | *" |
| 1118 | "with_$ac_useropt" |
| 1119 | "*) ;; |
| 1120 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1121 | ac_unrecognized_sep=', ';; |
| 1122 | esac |
| 1123 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1124 | |
| 1125 | -without-* | --without-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1126 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1127 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1128 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1129 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1130 | ac_useropt_orig=$ac_useropt |
| 1131 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1132 | case $ac_user_opts in |
| 1133 | *" |
| 1134 | "with_$ac_useropt" |
| 1135 | "*) ;; |
| 1136 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1137 | ac_unrecognized_sep=', ';; |
| 1138 | esac |
| 1139 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1140 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1141 | --x) |
| 1142 | # Obsolete; use --with-x. |
| 1143 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1144 | |
| 1145 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1146 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1147 | ac_prev=x_includes ;; |
| 1148 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1149 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1150 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1151 | |
| 1152 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1153 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1154 | ac_prev=x_libraries ;; |
| 1155 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1156 | | --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] | 1157 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1158 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1159 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
| 1160 | Try \`$0 --help' for more information" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1161 | ;; |
| 1162 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1163 | *=*) |
| 1164 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1165 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1166 | case $ac_envvar in #( |
| 1167 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1168 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1169 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1170 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1171 | export $ac_envvar ;; |
| 1172 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1173 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1174 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1175 | $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] | 1176 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1177 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1178 | : ${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] | 1179 | ;; |
| 1180 | |
| 1181 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1182 | done |
| 1183 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1184 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1185 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1186 | as_fn_error $? "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1187 | fi |
| 1188 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1189 | if test -n "$ac_unrecognized_opts"; then |
| 1190 | case $enable_option_checking in |
| 1191 | no) ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1192 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1193 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1194 | esac |
| 1195 | fi |
| 1196 | |
| 1197 | # Check all directory arguments for consistency. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1198 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1199 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1200 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1201 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1202 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1203 | eval ac_val=\$$ac_var |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1204 | # Remove trailing slashes. |
| 1205 | case $ac_val in |
| 1206 | */ ) |
| 1207 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1208 | eval $ac_var=\$ac_val;; |
| 1209 | esac |
| 1210 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1211 | case $ac_val in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1212 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1213 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1214 | esac |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1215 | 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] | 1216 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1217 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1218 | # There might be people who depend on the old broken behavior: `$host' |
| 1219 | # used to hold the argument of --host etc. |
| 1220 | # FIXME: To remove some day. |
| 1221 | build=$build_alias |
| 1222 | host=$host_alias |
| 1223 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1224 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1225 | # FIXME: To remove some day. |
| 1226 | if test "x$host_alias" != x; then |
| 1227 | if test "x$build_alias" = x; then |
| 1228 | cross_compiling=maybe |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1229 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. |
| 1230 | 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] | 1231 | elif test "x$build_alias" != "x$host_alias"; then |
| 1232 | cross_compiling=yes |
| 1233 | fi |
| 1234 | fi |
| 1235 | |
| 1236 | ac_tool_prefix= |
| 1237 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1238 | |
| 1239 | test "$silent" = yes && exec 6>/dev/null |
| 1240 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1241 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1242 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1243 | ac_ls_di=`ls -di .` && |
| 1244 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1245 | as_fn_error $? "working directory cannot be determined" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1246 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1247 | as_fn_error $? "pwd does not report name of working directory" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1248 | |
| 1249 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1250 | # Find the source files, if location was not specified. |
| 1251 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1252 | ac_srcdir_defaulted=yes |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1253 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1254 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1255 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1256 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1257 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1258 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1259 | $as_echo X"$as_myself" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1260 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1261 | s//\1/ |
| 1262 | q |
| 1263 | } |
| 1264 | /^X\(\/\/\)[^/].*/{ |
| 1265 | s//\1/ |
| 1266 | q |
| 1267 | } |
| 1268 | /^X\(\/\/\)$/{ |
| 1269 | s//\1/ |
| 1270 | q |
| 1271 | } |
| 1272 | /^X\(\/\).*/{ |
| 1273 | s//\1/ |
| 1274 | q |
| 1275 | } |
| 1276 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1277 | srcdir=$ac_confdir |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1278 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1279 | srcdir=.. |
| 1280 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1281 | else |
| 1282 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1283 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1284 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1285 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1286 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 1287 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1288 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1289 | ac_abs_confdir=`( |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1290 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1291 | pwd)` |
| 1292 | # When building in place, set srcdir=. |
| 1293 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1294 | srcdir=. |
| 1295 | fi |
| 1296 | # Remove unnecessary trailing slashes from srcdir. |
| 1297 | # Double slashes in file names in object file debugging info |
| 1298 | # mess up M-x gdb in Emacs. |
| 1299 | case $srcdir in |
| 1300 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1301 | esac |
| 1302 | for ac_var in $ac_precious_vars; do |
| 1303 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1304 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1305 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1306 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1307 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1308 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1309 | # |
| 1310 | # Report the --help message. |
| 1311 | # |
| 1312 | if test "$ac_init_help" = "long"; then |
| 1313 | # Omit some internal or obsolete options to make the list less imposing. |
| 1314 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1315 | cat <<_ACEOF |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 1316 | \`configure' configures python 3.3 to adapt to many kinds of systems. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1317 | |
| 1318 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1319 | |
| 1320 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1321 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1322 | |
| 1323 | Defaults for the options are specified in brackets. |
| 1324 | |
| 1325 | Configuration: |
| 1326 | -h, --help display this help and exit |
| 1327 | --help=short display options specific to this package |
| 1328 | --help=recursive display the short help of all the included packages |
| 1329 | -V, --version display version information and exit |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1330 | -q, --quiet, --silent do not print \`checking ...' messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1331 | --cache-file=FILE cache test results in FILE [disabled] |
| 1332 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1333 | -n, --no-create do not create output files |
| 1334 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1335 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1336 | Installation directories: |
| 1337 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1338 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1339 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1340 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1341 | |
| 1342 | By default, \`make install' will install all the files in |
| 1343 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1344 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1345 | for instance \`--prefix=\$HOME'. |
| 1346 | |
| 1347 | For better control, use the options below. |
| 1348 | |
| 1349 | Fine tuning of the installation directories: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1350 | --bindir=DIR user executables [EPREFIX/bin] |
| 1351 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1352 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1353 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1354 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1355 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1356 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1357 | --includedir=DIR C header files [PREFIX/include] |
| 1358 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1359 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1360 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1361 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1362 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1363 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1364 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1365 | --htmldir=DIR html documentation [DOCDIR] |
| 1366 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1367 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1368 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1369 | _ACEOF |
| 1370 | |
| 1371 | cat <<\_ACEOF |
| 1372 | _ACEOF |
| 1373 | fi |
| 1374 | |
| 1375 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1376 | case $ac_init_help in |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 1377 | short | recursive ) echo "Configuration of python 3.3:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1378 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1379 | cat <<\_ACEOF |
| 1380 | |
| 1381 | Optional Features: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1382 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1383 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1384 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Christian Heimes | 68f5fbe | 2008-02-14 08:27:37 +0000 | [diff] [blame] | 1385 | --enable-universalsdk[=SDKDIR] |
Christian Heimes | 292d351 | 2008-02-03 16:51:08 +0000 | [diff] [blame] | 1386 | Build against Mac OS X 10.4u SDK (ppc/i386) |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1387 | --enable-framework[=INSTALLDIR] |
| 1388 | Build (MacOSX|Darwin) framework |
| 1389 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1390 | --enable-profiling enable C-level code profiling |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 1391 | --enable-loadable-sqlite-extensions |
| 1392 | support loadable extensions in _sqlite module |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1393 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1394 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 1395 | --enable-big-digits[=BITS] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1396 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1397 | |
| 1398 | Optional Packages: |
| 1399 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1400 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 1401 | --with-universal-archs=ARCH |
| 1402 | select architectures for universal build ("32-bit", |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 1403 | "64-bit", "3-way", "intel" or "all") |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 1404 | --with-framework-name=FRAMEWORK |
| 1405 | specify an alternate name of the framework built |
| 1406 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1407 | --without-gcc never use gcc |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1408 | --with-cxx-main=<compiler> |
| 1409 | compile main() and link python executable with C++ |
| 1410 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1411 | --with-suffix=.exe set executable suffix |
| 1412 | --with-pydebug build with Py_DEBUG defined |
| 1413 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | b2d9046 | 2009-12-31 03:23:10 +0000 | [diff] [blame] | 1414 | --with-system-expat build pyexpat module using an installed expat |
| 1415 | library |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1416 | --with-system-ffi build _ctypes module using an installed ffi library |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 1417 | --with-dbmliborder=db1:db2:... |
| 1418 | order to check db backends for dbm. Valid value is a |
| 1419 | colon separated string with the backend names |
| 1420 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1421 | --with-signal-module disable/enable signal module |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1422 | --with(out)-threads[=DIRECTORY] |
| 1423 | disable/enable thread support |
| 1424 | --with(out)-thread[=DIRECTORY] |
| 1425 | deprecated; use --with(out)-threads |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1426 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1427 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1428 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 1429 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1430 | --with-fpectl enable SIGFPE catching |
| 1431 | --with-libm=STRING math library |
| 1432 | --with-libc=STRING C library |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 1433 | --with-wide-unicode Use 4-byte Unicode characters (default is 2 bytes) |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 1434 | --with(out)-computed-gotos |
| 1435 | Use computed gotos in evaluation loop (enabled by |
| 1436 | default on supported compilers) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1437 | |
| 1438 | Some influential environment variables: |
| 1439 | CC C compiler command |
| 1440 | CFLAGS C compiler flags |
| 1441 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1442 | nonstandard directory <lib dir> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1443 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1444 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1445 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1446 | CPP C preprocessor |
| 1447 | |
| 1448 | Use these variables to override the choices made by `configure' or to help |
| 1449 | it to find libraries and programs with nonstandard names/locations. |
| 1450 | |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 1451 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1452 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1453 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1454 | fi |
| 1455 | |
| 1456 | if test "$ac_init_help" = "recursive"; then |
| 1457 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1458 | 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] | 1459 | test -d "$ac_dir" || |
| 1460 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1461 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1462 | ac_builddir=. |
| 1463 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1464 | case "$ac_dir" in |
| 1465 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1466 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1467 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1468 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1469 | 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] | 1470 | case $ac_top_builddir_sub in |
| 1471 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1472 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1473 | esac ;; |
| 1474 | esac |
| 1475 | ac_abs_top_builddir=$ac_pwd |
| 1476 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1477 | # for backward compatibility: |
| 1478 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1479 | |
| 1480 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1481 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1482 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1483 | ac_top_srcdir=$ac_top_builddir_sub |
| 1484 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1485 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1486 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1487 | ac_top_srcdir=$srcdir |
| 1488 | ac_abs_top_srcdir=$srcdir ;; |
| 1489 | *) # Relative name. |
| 1490 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1491 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1492 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1493 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1494 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1495 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1496 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1497 | # Check for guested configure. |
| 1498 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1499 | echo && |
| 1500 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1501 | elif test -f "$ac_srcdir/configure"; then |
| 1502 | echo && |
| 1503 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1504 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1505 | $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] | 1506 | fi || ac_status=$? |
| 1507 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1508 | done |
| 1509 | fi |
| 1510 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1511 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1512 | if $ac_init_version; then |
| 1513 | cat <<\_ACEOF |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 1514 | python configure 3.3 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1515 | generated by GNU Autoconf 2.67 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1516 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1517 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1518 | This configure script is free software; the Free Software Foundation |
| 1519 | gives unlimited permission to copy, distribute and modify it. |
| 1520 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1521 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1522 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1523 | |
| 1524 | ## ------------------------ ## |
| 1525 | ## Autoconf initialization. ## |
| 1526 | ## ------------------------ ## |
| 1527 | |
| 1528 | # ac_fn_c_try_compile LINENO |
| 1529 | # -------------------------- |
| 1530 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1531 | ac_fn_c_try_compile () |
| 1532 | { |
| 1533 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1534 | rm -f conftest.$ac_objext |
| 1535 | if { { ac_try="$ac_compile" |
| 1536 | case "(($ac_try" in |
| 1537 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1538 | *) ac_try_echo=$ac_try;; |
| 1539 | esac |
| 1540 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1541 | $as_echo "$ac_try_echo"; } >&5 |
| 1542 | (eval "$ac_compile") 2>conftest.err |
| 1543 | ac_status=$? |
| 1544 | if test -s conftest.err; then |
| 1545 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1546 | cat conftest.er1 >&5 |
| 1547 | mv -f conftest.er1 conftest.err |
| 1548 | fi |
| 1549 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1550 | test $ac_status = 0; } && { |
| 1551 | test -z "$ac_c_werror_flag" || |
| 1552 | test ! -s conftest.err |
| 1553 | } && test -s conftest.$ac_objext; then : |
| 1554 | ac_retval=0 |
| 1555 | else |
| 1556 | $as_echo "$as_me: failed program was:" >&5 |
| 1557 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1558 | |
| 1559 | ac_retval=1 |
| 1560 | fi |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1561 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1562 | as_fn_set_status $ac_retval |
| 1563 | |
| 1564 | } # ac_fn_c_try_compile |
| 1565 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1566 | # ac_fn_c_try_link LINENO |
| 1567 | # ----------------------- |
| 1568 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1569 | ac_fn_c_try_link () |
| 1570 | { |
| 1571 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1572 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1573 | if { { ac_try="$ac_link" |
| 1574 | case "(($ac_try" in |
| 1575 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1576 | *) ac_try_echo=$ac_try;; |
| 1577 | esac |
| 1578 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1579 | $as_echo "$ac_try_echo"; } >&5 |
| 1580 | (eval "$ac_link") 2>conftest.err |
| 1581 | ac_status=$? |
| 1582 | if test -s conftest.err; then |
| 1583 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1584 | cat conftest.er1 >&5 |
| 1585 | mv -f conftest.er1 conftest.err |
| 1586 | fi |
| 1587 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1588 | test $ac_status = 0; } && { |
| 1589 | test -z "$ac_c_werror_flag" || |
| 1590 | test ! -s conftest.err |
| 1591 | } && test -s conftest$ac_exeext && { |
| 1592 | test "$cross_compiling" = yes || |
| 1593 | $as_test_x conftest$ac_exeext |
| 1594 | }; then : |
| 1595 | ac_retval=0 |
| 1596 | else |
| 1597 | $as_echo "$as_me: failed program was:" >&5 |
| 1598 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1599 | |
| 1600 | ac_retval=1 |
| 1601 | fi |
| 1602 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1603 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1604 | # interfere with the next link command; also delete a directory that is |
| 1605 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1606 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1607 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1608 | as_fn_set_status $ac_retval |
| 1609 | |
| 1610 | } # ac_fn_c_try_link |
| 1611 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1612 | # ac_fn_c_try_cpp LINENO |
| 1613 | # ---------------------- |
| 1614 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1615 | ac_fn_c_try_cpp () |
| 1616 | { |
| 1617 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1618 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1619 | case "(($ac_try" in |
| 1620 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1621 | *) ac_try_echo=$ac_try;; |
| 1622 | esac |
| 1623 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1624 | $as_echo "$ac_try_echo"; } >&5 |
| 1625 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1626 | ac_status=$? |
| 1627 | if test -s conftest.err; then |
| 1628 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1629 | cat conftest.er1 >&5 |
| 1630 | mv -f conftest.er1 conftest.err |
| 1631 | fi |
| 1632 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1633 | test $ac_status = 0; } > conftest.i && { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1634 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1635 | test ! -s conftest.err |
| 1636 | }; then : |
| 1637 | ac_retval=0 |
| 1638 | else |
| 1639 | $as_echo "$as_me: failed program was:" >&5 |
| 1640 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1641 | |
| 1642 | ac_retval=1 |
| 1643 | fi |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1644 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1645 | as_fn_set_status $ac_retval |
| 1646 | |
| 1647 | } # ac_fn_c_try_cpp |
| 1648 | |
| 1649 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1650 | # ------------------------------------------------------- |
| 1651 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1652 | # the include files in INCLUDES and setting the cache variable VAR |
| 1653 | # accordingly. |
| 1654 | ac_fn_c_check_header_mongrel () |
| 1655 | { |
| 1656 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1657 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1658 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1659 | $as_echo_n "checking for $2... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1660 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1661 | $as_echo_n "(cached) " >&6 |
| 1662 | fi |
| 1663 | eval ac_res=\$$3 |
| 1664 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1665 | $as_echo "$ac_res" >&6; } |
| 1666 | else |
| 1667 | # Is the header compilable? |
| 1668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1669 | $as_echo_n "checking $2 usability... " >&6; } |
| 1670 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1671 | /* end confdefs.h. */ |
| 1672 | $4 |
| 1673 | #include <$2> |
| 1674 | _ACEOF |
| 1675 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1676 | ac_header_compiler=yes |
| 1677 | else |
| 1678 | ac_header_compiler=no |
| 1679 | fi |
| 1680 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1681 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1682 | $as_echo "$ac_header_compiler" >&6; } |
| 1683 | |
| 1684 | # Is the header present? |
| 1685 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1686 | $as_echo_n "checking $2 presence... " >&6; } |
| 1687 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1688 | /* end confdefs.h. */ |
| 1689 | #include <$2> |
| 1690 | _ACEOF |
| 1691 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1692 | ac_header_preproc=yes |
| 1693 | else |
| 1694 | ac_header_preproc=no |
| 1695 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1696 | rm -f conftest.err conftest.i conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1698 | $as_echo "$ac_header_preproc" >&6; } |
| 1699 | |
| 1700 | # So? What about this header? |
| 1701 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1702 | yes:no: ) |
| 1703 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1704 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1705 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1706 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1707 | ;; |
| 1708 | no:yes:* ) |
| 1709 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1710 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1711 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1712 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1713 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1714 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1715 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1716 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1717 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1718 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1719 | ( $as_echo "## -------------------------------------- ## |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1720 | ## Report this to http://bugs.python.org/ ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1721 | ## -------------------------------------- ##" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1722 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1723 | ;; |
| 1724 | esac |
| 1725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1726 | $as_echo_n "checking for $2... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1727 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1728 | $as_echo_n "(cached) " >&6 |
| 1729 | else |
| 1730 | eval "$3=\$ac_header_compiler" |
| 1731 | fi |
| 1732 | eval ac_res=\$$3 |
| 1733 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1734 | $as_echo "$ac_res" >&6; } |
| 1735 | fi |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1736 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1737 | |
| 1738 | } # ac_fn_c_check_header_mongrel |
| 1739 | |
| 1740 | # ac_fn_c_try_run LINENO |
| 1741 | # ---------------------- |
| 1742 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1743 | # that executables *can* be run. |
| 1744 | ac_fn_c_try_run () |
| 1745 | { |
| 1746 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1747 | if { { ac_try="$ac_link" |
| 1748 | case "(($ac_try" in |
| 1749 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1750 | *) ac_try_echo=$ac_try;; |
| 1751 | esac |
| 1752 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1753 | $as_echo "$ac_try_echo"; } >&5 |
| 1754 | (eval "$ac_link") 2>&5 |
| 1755 | ac_status=$? |
| 1756 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1757 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1758 | { { case "(($ac_try" in |
| 1759 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1760 | *) ac_try_echo=$ac_try;; |
| 1761 | esac |
| 1762 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1763 | $as_echo "$ac_try_echo"; } >&5 |
| 1764 | (eval "$ac_try") 2>&5 |
| 1765 | ac_status=$? |
| 1766 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1767 | test $ac_status = 0; }; }; then : |
| 1768 | ac_retval=0 |
| 1769 | else |
| 1770 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1771 | $as_echo "$as_me: failed program was:" >&5 |
| 1772 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1773 | |
| 1774 | ac_retval=$ac_status |
| 1775 | fi |
| 1776 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1777 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1778 | as_fn_set_status $ac_retval |
| 1779 | |
| 1780 | } # ac_fn_c_try_run |
| 1781 | |
| 1782 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1783 | # ------------------------------------------------------- |
| 1784 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1785 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1786 | ac_fn_c_check_header_compile () |
| 1787 | { |
| 1788 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1789 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1790 | $as_echo_n "checking for $2... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1791 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1792 | $as_echo_n "(cached) " >&6 |
| 1793 | else |
| 1794 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1795 | /* end confdefs.h. */ |
| 1796 | $4 |
| 1797 | #include <$2> |
| 1798 | _ACEOF |
| 1799 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1800 | eval "$3=yes" |
| 1801 | else |
| 1802 | eval "$3=no" |
| 1803 | fi |
| 1804 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1805 | fi |
| 1806 | eval ac_res=\$$3 |
| 1807 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1808 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1809 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1810 | |
| 1811 | } # ac_fn_c_check_header_compile |
| 1812 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1813 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1814 | # ------------------------------------------- |
| 1815 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1816 | # variable VAR accordingly. |
| 1817 | ac_fn_c_check_type () |
| 1818 | { |
| 1819 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1820 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1821 | $as_echo_n "checking for $2... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1822 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1823 | $as_echo_n "(cached) " >&6 |
| 1824 | else |
| 1825 | eval "$3=no" |
| 1826 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1827 | /* end confdefs.h. */ |
| 1828 | $4 |
| 1829 | int |
| 1830 | main () |
| 1831 | { |
| 1832 | if (sizeof ($2)) |
| 1833 | return 0; |
| 1834 | ; |
| 1835 | return 0; |
| 1836 | } |
| 1837 | _ACEOF |
| 1838 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1839 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1840 | /* end confdefs.h. */ |
| 1841 | $4 |
| 1842 | int |
| 1843 | main () |
| 1844 | { |
| 1845 | if (sizeof (($2))) |
| 1846 | return 0; |
| 1847 | ; |
| 1848 | return 0; |
| 1849 | } |
| 1850 | _ACEOF |
| 1851 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1852 | |
| 1853 | else |
| 1854 | eval "$3=yes" |
| 1855 | fi |
| 1856 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1857 | fi |
| 1858 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1859 | fi |
| 1860 | eval ac_res=\$$3 |
| 1861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1862 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1863 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1864 | |
| 1865 | } # ac_fn_c_check_type |
| 1866 | |
| 1867 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1868 | # ------------------------------------ |
| 1869 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1870 | # accordingly. |
| 1871 | ac_fn_c_find_uintX_t () |
| 1872 | { |
| 1873 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1874 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1875 | $as_echo_n "checking for uint$2_t... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1876 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1877 | $as_echo_n "(cached) " >&6 |
| 1878 | else |
| 1879 | eval "$3=no" |
| 1880 | # Order is important - never check a type that is potentially smaller |
| 1881 | # than half of the expected target width. |
| 1882 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1883 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1884 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1885 | /* end confdefs.h. */ |
| 1886 | $ac_includes_default |
| 1887 | int |
| 1888 | main () |
| 1889 | { |
| 1890 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
| 1891 | test_array [0] = 0 |
| 1892 | |
| 1893 | ; |
| 1894 | return 0; |
| 1895 | } |
| 1896 | _ACEOF |
| 1897 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1898 | case $ac_type in #( |
| 1899 | uint$2_t) : |
| 1900 | eval "$3=yes" ;; #( |
| 1901 | *) : |
| 1902 | eval "$3=\$ac_type" ;; |
| 1903 | esac |
| 1904 | fi |
| 1905 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1906 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1907 | |
| 1908 | else |
| 1909 | break |
| 1910 | fi |
| 1911 | done |
| 1912 | fi |
| 1913 | eval ac_res=\$$3 |
| 1914 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1915 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1916 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1917 | |
| 1918 | } # ac_fn_c_find_uintX_t |
| 1919 | |
| 1920 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 1921 | # ----------------------------------- |
| 1922 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 1923 | # accordingly. |
| 1924 | ac_fn_c_find_intX_t () |
| 1925 | { |
| 1926 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1927 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 1928 | $as_echo_n "checking for int$2_t... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1929 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1930 | $as_echo_n "(cached) " >&6 |
| 1931 | else |
| 1932 | eval "$3=no" |
| 1933 | # Order is important - never check a type that is potentially smaller |
| 1934 | # than half of the expected target width. |
| 1935 | for ac_type in int$2_t 'int' 'long int' \ |
| 1936 | 'long long int' 'short int' 'signed char'; do |
| 1937 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1938 | /* end confdefs.h. */ |
| 1939 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1940 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1941 | int |
| 1942 | main () |
| 1943 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1944 | static int test_array [1 - 2 * !(0 < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1))]; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1945 | test_array [0] = 0 |
| 1946 | |
| 1947 | ; |
| 1948 | return 0; |
| 1949 | } |
| 1950 | _ACEOF |
| 1951 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1952 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1953 | /* end confdefs.h. */ |
| 1954 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1955 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1956 | int |
| 1957 | main () |
| 1958 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1959 | static int test_array [1 - 2 * !(($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 1) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1960 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
| 1961 | test_array [0] = 0 |
| 1962 | |
| 1963 | ; |
| 1964 | return 0; |
| 1965 | } |
| 1966 | _ACEOF |
| 1967 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1968 | |
| 1969 | else |
| 1970 | case $ac_type in #( |
| 1971 | int$2_t) : |
| 1972 | eval "$3=yes" ;; #( |
| 1973 | *) : |
| 1974 | eval "$3=\$ac_type" ;; |
| 1975 | esac |
| 1976 | fi |
| 1977 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1978 | fi |
| 1979 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 1980 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1981 | |
| 1982 | else |
| 1983 | break |
| 1984 | fi |
| 1985 | done |
| 1986 | fi |
| 1987 | eval ac_res=\$$3 |
| 1988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1989 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 1990 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1991 | |
| 1992 | } # ac_fn_c_find_intX_t |
| 1993 | |
| 1994 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 1995 | # -------------------------------------------- |
| 1996 | # Tries to find the compile-time value of EXPR in a program that includes |
| 1997 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 1998 | # computed |
| 1999 | ac_fn_c_compute_int () |
| 2000 | { |
| 2001 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2002 | if test "$cross_compiling" = yes; then |
| 2003 | # Depending upon the size, compute the lo and hi bounds. |
| 2004 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2005 | /* end confdefs.h. */ |
| 2006 | $4 |
| 2007 | int |
| 2008 | main () |
| 2009 | { |
| 2010 | static int test_array [1 - 2 * !(($2) >= 0)]; |
| 2011 | test_array [0] = 0 |
| 2012 | |
| 2013 | ; |
| 2014 | return 0; |
| 2015 | } |
| 2016 | _ACEOF |
| 2017 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2018 | ac_lo=0 ac_mid=0 |
| 2019 | while :; do |
| 2020 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2021 | /* end confdefs.h. */ |
| 2022 | $4 |
| 2023 | int |
| 2024 | main () |
| 2025 | { |
| 2026 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2027 | test_array [0] = 0 |
| 2028 | |
| 2029 | ; |
| 2030 | return 0; |
| 2031 | } |
| 2032 | _ACEOF |
| 2033 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2034 | ac_hi=$ac_mid; break |
| 2035 | else |
| 2036 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2037 | if test $ac_lo -le $ac_mid; then |
| 2038 | ac_lo= ac_hi= |
| 2039 | break |
| 2040 | fi |
| 2041 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2042 | fi |
| 2043 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2044 | done |
| 2045 | else |
| 2046 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2047 | /* end confdefs.h. */ |
| 2048 | $4 |
| 2049 | int |
| 2050 | main () |
| 2051 | { |
| 2052 | static int test_array [1 - 2 * !(($2) < 0)]; |
| 2053 | test_array [0] = 0 |
| 2054 | |
| 2055 | ; |
| 2056 | return 0; |
| 2057 | } |
| 2058 | _ACEOF |
| 2059 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2060 | ac_hi=-1 ac_mid=-1 |
| 2061 | while :; do |
| 2062 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2063 | /* end confdefs.h. */ |
| 2064 | $4 |
| 2065 | int |
| 2066 | main () |
| 2067 | { |
| 2068 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
| 2069 | test_array [0] = 0 |
| 2070 | |
| 2071 | ; |
| 2072 | return 0; |
| 2073 | } |
| 2074 | _ACEOF |
| 2075 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2076 | ac_lo=$ac_mid; break |
| 2077 | else |
| 2078 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2079 | if test $ac_mid -le $ac_hi; then |
| 2080 | ac_lo= ac_hi= |
| 2081 | break |
| 2082 | fi |
| 2083 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2084 | fi |
| 2085 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2086 | done |
| 2087 | else |
| 2088 | ac_lo= ac_hi= |
| 2089 | fi |
| 2090 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2091 | fi |
| 2092 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2093 | # Binary search between lo and hi bounds. |
| 2094 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2095 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2096 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2097 | /* end confdefs.h. */ |
| 2098 | $4 |
| 2099 | int |
| 2100 | main () |
| 2101 | { |
| 2102 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2103 | test_array [0] = 0 |
| 2104 | |
| 2105 | ; |
| 2106 | return 0; |
| 2107 | } |
| 2108 | _ACEOF |
| 2109 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2110 | ac_hi=$ac_mid |
| 2111 | else |
| 2112 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2113 | fi |
| 2114 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2115 | done |
| 2116 | case $ac_lo in #(( |
| 2117 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2118 | '') ac_retval=1 ;; |
| 2119 | esac |
| 2120 | else |
| 2121 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2122 | /* end confdefs.h. */ |
| 2123 | $4 |
| 2124 | static long int longval () { return $2; } |
| 2125 | static unsigned long int ulongval () { return $2; } |
| 2126 | #include <stdio.h> |
| 2127 | #include <stdlib.h> |
| 2128 | int |
| 2129 | main () |
| 2130 | { |
| 2131 | |
| 2132 | FILE *f = fopen ("conftest.val", "w"); |
| 2133 | if (! f) |
| 2134 | return 1; |
| 2135 | if (($2) < 0) |
| 2136 | { |
| 2137 | long int i = longval (); |
| 2138 | if (i != ($2)) |
| 2139 | return 1; |
| 2140 | fprintf (f, "%ld", i); |
| 2141 | } |
| 2142 | else |
| 2143 | { |
| 2144 | unsigned long int i = ulongval (); |
| 2145 | if (i != ($2)) |
| 2146 | return 1; |
| 2147 | fprintf (f, "%lu", i); |
| 2148 | } |
| 2149 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2150 | on some platforms. */ |
| 2151 | return ferror (f) || fclose (f) != 0; |
| 2152 | |
| 2153 | ; |
| 2154 | return 0; |
| 2155 | } |
| 2156 | _ACEOF |
| 2157 | if ac_fn_c_try_run "$LINENO"; then : |
| 2158 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2159 | else |
| 2160 | ac_retval=1 |
| 2161 | fi |
| 2162 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2163 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2164 | rm -f conftest.val |
| 2165 | |
| 2166 | fi |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 2167 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2168 | as_fn_set_status $ac_retval |
| 2169 | |
| 2170 | } # ac_fn_c_compute_int |
| 2171 | |
| 2172 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2173 | # ---------------------------------- |
| 2174 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2175 | ac_fn_c_check_func () |
| 2176 | { |
| 2177 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2178 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2179 | $as_echo_n "checking for $2... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2180 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2181 | $as_echo_n "(cached) " >&6 |
| 2182 | else |
| 2183 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2184 | /* end confdefs.h. */ |
| 2185 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2186 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2187 | #define $2 innocuous_$2 |
| 2188 | |
| 2189 | /* System header to define __stub macros and hopefully few prototypes, |
| 2190 | which can conflict with char $2 (); below. |
| 2191 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2192 | <limits.h> exists even on freestanding compilers. */ |
| 2193 | |
| 2194 | #ifdef __STDC__ |
| 2195 | # include <limits.h> |
| 2196 | #else |
| 2197 | # include <assert.h> |
| 2198 | #endif |
| 2199 | |
| 2200 | #undef $2 |
| 2201 | |
| 2202 | /* Override any GCC internal prototype to avoid an error. |
| 2203 | Use char because int might match the return type of a GCC |
| 2204 | builtin and then its argument prototype would still apply. */ |
| 2205 | #ifdef __cplusplus |
| 2206 | extern "C" |
| 2207 | #endif |
| 2208 | char $2 (); |
| 2209 | /* The GNU C library defines this for functions which it implements |
| 2210 | to always fail with ENOSYS. Some functions are actually named |
| 2211 | something starting with __ and the normal name is an alias. */ |
| 2212 | #if defined __stub_$2 || defined __stub___$2 |
| 2213 | choke me |
| 2214 | #endif |
| 2215 | |
| 2216 | int |
| 2217 | main () |
| 2218 | { |
| 2219 | return $2 (); |
| 2220 | ; |
| 2221 | return 0; |
| 2222 | } |
| 2223 | _ACEOF |
| 2224 | if ac_fn_c_try_link "$LINENO"; then : |
| 2225 | eval "$3=yes" |
| 2226 | else |
| 2227 | eval "$3=no" |
| 2228 | fi |
| 2229 | rm -f core conftest.err conftest.$ac_objext \ |
| 2230 | conftest$ac_exeext conftest.$ac_ext |
| 2231 | fi |
| 2232 | eval ac_res=\$$3 |
| 2233 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2234 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 2235 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2236 | |
| 2237 | } # ac_fn_c_check_func |
| 2238 | |
| 2239 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2240 | # ---------------------------------------------------- |
| 2241 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2242 | # INCLUDES, setting cache variable VAR accordingly. |
| 2243 | ac_fn_c_check_member () |
| 2244 | { |
| 2245 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2246 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2247 | $as_echo_n "checking for $2.$3... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2248 | if eval "test \"\${$4+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2249 | $as_echo_n "(cached) " >&6 |
| 2250 | else |
| 2251 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2252 | /* end confdefs.h. */ |
| 2253 | $5 |
| 2254 | int |
| 2255 | main () |
| 2256 | { |
| 2257 | static $2 ac_aggr; |
| 2258 | if (ac_aggr.$3) |
| 2259 | return 0; |
| 2260 | ; |
| 2261 | return 0; |
| 2262 | } |
| 2263 | _ACEOF |
| 2264 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2265 | eval "$4=yes" |
| 2266 | else |
| 2267 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2268 | /* end confdefs.h. */ |
| 2269 | $5 |
| 2270 | int |
| 2271 | main () |
| 2272 | { |
| 2273 | static $2 ac_aggr; |
| 2274 | if (sizeof ac_aggr.$3) |
| 2275 | return 0; |
| 2276 | ; |
| 2277 | return 0; |
| 2278 | } |
| 2279 | _ACEOF |
| 2280 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2281 | eval "$4=yes" |
| 2282 | else |
| 2283 | eval "$4=no" |
| 2284 | fi |
| 2285 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2286 | fi |
| 2287 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2288 | fi |
| 2289 | eval ac_res=\$$4 |
| 2290 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2291 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 2292 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2293 | |
| 2294 | } # ac_fn_c_check_member |
| 2295 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2296 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
| 2297 | # --------------------------------------------- |
| 2298 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR |
| 2299 | # accordingly. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2300 | ac_fn_c_check_decl () |
| 2301 | { |
| 2302 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2303 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
| 2304 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` |
| 2305 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 |
| 2306 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } |
| 2307 | if eval "test \"\${$3+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2308 | $as_echo_n "(cached) " >&6 |
| 2309 | else |
| 2310 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2311 | /* end confdefs.h. */ |
| 2312 | $4 |
| 2313 | int |
| 2314 | main () |
| 2315 | { |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2316 | #ifndef $as_decl_name |
| 2317 | #ifdef __cplusplus |
| 2318 | (void) $as_decl_use; |
| 2319 | #else |
| 2320 | (void) $as_decl_name; |
| 2321 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2322 | #endif |
| 2323 | |
| 2324 | ; |
| 2325 | return 0; |
| 2326 | } |
| 2327 | _ACEOF |
| 2328 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2329 | eval "$3=yes" |
| 2330 | else |
| 2331 | eval "$3=no" |
| 2332 | fi |
| 2333 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2334 | fi |
| 2335 | eval ac_res=\$$3 |
| 2336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2337 | $as_echo "$ac_res" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 2338 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2339 | |
| 2340 | } # ac_fn_c_check_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2341 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2342 | This file contains any messages produced by compilers while |
| 2343 | running configure, to aid debugging if configure makes a mistake. |
| 2344 | |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 2345 | It was created by python $as_me 3.3, which was |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2346 | generated by GNU Autoconf 2.67. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2347 | |
| 2348 | $ $0 $@ |
| 2349 | |
| 2350 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2351 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2352 | { |
| 2353 | cat <<_ASUNAME |
| 2354 | ## --------- ## |
| 2355 | ## Platform. ## |
| 2356 | ## --------- ## |
| 2357 | |
| 2358 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2359 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2360 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2361 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2362 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2363 | |
| 2364 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2365 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2366 | |
| 2367 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2368 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2369 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2370 | /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] | 2371 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2372 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2373 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2374 | |
| 2375 | _ASUNAME |
| 2376 | |
| 2377 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2378 | for as_dir in $PATH |
| 2379 | do |
| 2380 | IFS=$as_save_IFS |
| 2381 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2382 | $as_echo "PATH: $as_dir" |
| 2383 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2384 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2385 | |
| 2386 | } >&5 |
| 2387 | |
| 2388 | cat >&5 <<_ACEOF |
| 2389 | |
| 2390 | |
| 2391 | ## ----------- ## |
| 2392 | ## Core tests. ## |
| 2393 | ## ----------- ## |
| 2394 | |
| 2395 | _ACEOF |
| 2396 | |
| 2397 | |
| 2398 | # Keep a trace of the command line. |
| 2399 | # 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] | 2400 | # 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] | 2401 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2402 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2403 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2404 | ac_configure_args0= |
| 2405 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2406 | ac_must_keep_next=false |
| 2407 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2408 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2409 | for ac_arg |
| 2410 | do |
| 2411 | case $ac_arg in |
| 2412 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2413 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2414 | | -silent | --silent | --silen | --sile | --sil) |
| 2415 | continue ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2416 | *\'*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2417 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2418 | esac |
| 2419 | case $ac_pass in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2420 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2421 | 2) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2422 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2423 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2424 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2425 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2426 | case $ac_arg in |
| 2427 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2428 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2429 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2430 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2431 | case "$ac_configure_args0 " in |
| 2432 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2433 | esac |
| 2434 | ;; |
| 2435 | -* ) ac_must_keep_next=true ;; |
| 2436 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2437 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2438 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2439 | ;; |
| 2440 | esac |
| 2441 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2442 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2443 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2444 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2445 | |
| 2446 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2447 | # config.log. We remove comments because anyway the quotes in there |
| 2448 | # would cause problems or look ugly. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2449 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2450 | # 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] | 2451 | trap 'exit_status=$? |
| 2452 | # Save into config.log some information that might help in debugging. |
| 2453 | { |
| 2454 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2455 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2456 | $as_echo "## ---------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2457 | ## Cache variables. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2458 | ## ---------------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2459 | echo |
| 2460 | # The following way of writing the cache mishandles newlines in values, |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2461 | ( |
| 2462 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2463 | eval ac_val=\$$ac_var |
| 2464 | case $ac_val in #( |
| 2465 | *${as_nl}*) |
| 2466 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2467 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2468 | $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] | 2469 | esac |
| 2470 | case $ac_var in #( |
| 2471 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2472 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2473 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2474 | esac ;; |
| 2475 | esac |
| 2476 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2477 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2478 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2479 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2480 | sed -n \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2481 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2482 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2483 | ;; #( |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2484 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2485 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2486 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2487 | esac | |
| 2488 | sort |
| 2489 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2490 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2491 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2492 | $as_echo "## ----------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2493 | ## Output variables. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2494 | ## ----------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2495 | echo |
| 2496 | for ac_var in $ac_subst_vars |
| 2497 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2498 | eval ac_val=\$$ac_var |
| 2499 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2500 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2501 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2502 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2503 | done | sort |
| 2504 | echo |
| 2505 | |
| 2506 | if test -n "$ac_subst_files"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2507 | $as_echo "## ------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2508 | ## File substitutions. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2509 | ## ------------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2510 | echo |
| 2511 | for ac_var in $ac_subst_files |
| 2512 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2513 | eval ac_val=\$$ac_var |
| 2514 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2515 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2516 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2517 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2518 | done | sort |
| 2519 | echo |
| 2520 | fi |
| 2521 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2522 | if test -s confdefs.h; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2523 | $as_echo "## ----------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2524 | ## confdefs.h. ## |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2525 | ## ----------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2526 | echo |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2527 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2528 | echo |
| 2529 | fi |
| 2530 | test "$ac_signal" != 0 && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2531 | $as_echo "$as_me: caught signal $ac_signal" |
| 2532 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2533 | } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2534 | rm -f core *.core core.conftest.* && |
| 2535 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2536 | exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2537 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2538 | for ac_signal in 1 2 13 15; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2539 | 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] | 2540 | done |
| 2541 | ac_signal=0 |
| 2542 | |
| 2543 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2544 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2545 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2546 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2547 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2548 | # Predefined preprocessor variables. |
| 2549 | |
| 2550 | cat >>confdefs.h <<_ACEOF |
| 2551 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2552 | _ACEOF |
| 2553 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2554 | cat >>confdefs.h <<_ACEOF |
| 2555 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2556 | _ACEOF |
| 2557 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2558 | cat >>confdefs.h <<_ACEOF |
| 2559 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2560 | _ACEOF |
| 2561 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2562 | cat >>confdefs.h <<_ACEOF |
| 2563 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2564 | _ACEOF |
| 2565 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2566 | cat >>confdefs.h <<_ACEOF |
| 2567 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2568 | _ACEOF |
| 2569 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2570 | cat >>confdefs.h <<_ACEOF |
| 2571 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2572 | _ACEOF |
| 2573 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2574 | |
| 2575 | # 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] | 2576 | # Prefer an explicitly selected file to automatically selected ones. |
| 2577 | ac_site_file1=NONE |
| 2578 | ac_site_file2=NONE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2579 | if test -n "$CONFIG_SITE"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2580 | # We do not want a PATH search for config.site. |
| 2581 | case $CONFIG_SITE in #(( |
| 2582 | -*) ac_site_file1=./$CONFIG_SITE;; |
| 2583 | */*) ac_site_file1=$CONFIG_SITE;; |
| 2584 | *) ac_site_file1=./$CONFIG_SITE;; |
| 2585 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2586 | elif test "x$prefix" != xNONE; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2587 | ac_site_file1=$prefix/share/config.site |
| 2588 | ac_site_file2=$prefix/etc/config.site |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2589 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2590 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2591 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2592 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2593 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2594 | do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2595 | test "x$ac_site_file" = xNONE && continue |
| 2596 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2597 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2598 | $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] | 2599 | sed 's/^/| /' "$ac_site_file" >&5 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2600 | . "$ac_site_file" \ |
| 2601 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2602 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2603 | as_fn_error $? "failed to load site script $ac_site_file |
| 2604 | See \`config.log' for more details" "$LINENO" 5 ; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2605 | fi |
| 2606 | done |
| 2607 | |
| 2608 | if test -r "$cache_file"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2609 | # Some versions of bash will fail to source /dev/null (special files |
| 2610 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2611 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2612 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2613 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2614 | case $cache_file in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2615 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2616 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2617 | esac |
| 2618 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2619 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2620 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2621 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2622 | >$cache_file |
| 2623 | fi |
| 2624 | |
| 2625 | # Check that the precious variables saved in the cache have kept the same |
| 2626 | # value. |
| 2627 | ac_cache_corrupted=false |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2628 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2629 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2630 | eval ac_new_set=\$ac_env_${ac_var}_set |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2631 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2632 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2633 | case $ac_old_set,$ac_new_set in |
| 2634 | set,) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2635 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2636 | $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] | 2637 | ac_cache_corrupted=: ;; |
| 2638 | ,set) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2639 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2640 | $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] | 2641 | ac_cache_corrupted=: ;; |
| 2642 | ,);; |
| 2643 | *) |
| 2644 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2645 | # differences in whitespace do not lead to failure. |
| 2646 | ac_old_val_w=`echo x $ac_old_val` |
| 2647 | ac_new_val_w=`echo x $ac_new_val` |
| 2648 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2649 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2650 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2651 | ac_cache_corrupted=: |
| 2652 | else |
| 2653 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2654 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2655 | eval $ac_var=\$ac_old_val |
| 2656 | fi |
| 2657 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2658 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2659 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2660 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2661 | fi;; |
| 2662 | esac |
| 2663 | # Pass precious variables to config.status. |
| 2664 | if test "$ac_new_set" = set; then |
| 2665 | case $ac_new_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2666 | *\'*) 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] | 2667 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2668 | esac |
| 2669 | case " $ac_configure_args " in |
| 2670 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2671 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2672 | esac |
| 2673 | fi |
| 2674 | done |
| 2675 | if $ac_cache_corrupted; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2676 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2677 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2678 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2679 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2680 | 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] | 2681 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2682 | ## -------------------- ## |
| 2683 | ## Main body of script. ## |
| 2684 | ## -------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2685 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2686 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2687 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2688 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2689 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2690 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2691 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2692 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2693 | |
Benjamin Peterson | 8c6f88e | 2011-05-31 20:52:17 -0500 | [diff] [blame] | 2694 | |
| 2695 | |
| 2696 | |
| 2697 | |
| 2698 | if test -e $srcdir/.hg/00changelog.i |
| 2699 | then |
| 2700 | # Extract the first word of "hg", so it can be a program name with args. |
| 2701 | set dummy hg; ac_word=$2 |
| 2702 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 2703 | $as_echo_n "checking for $ac_word... " >&6; } |
| 2704 | if test "${ac_cv_prog_HAS_HG+set}" = set; then : |
| 2705 | $as_echo_n "(cached) " >&6 |
| 2706 | else |
| 2707 | if test -n "$HAS_HG"; then |
| 2708 | ac_cv_prog_HAS_HG="$HAS_HG" # Let the user override the test. |
| 2709 | else |
| 2710 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2711 | for as_dir in $PATH |
| 2712 | do |
| 2713 | IFS=$as_save_IFS |
| 2714 | test -z "$as_dir" && as_dir=. |
| 2715 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 2716 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 2717 | ac_cv_prog_HAS_HG="found" |
| 2718 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 2719 | break 2 |
| 2720 | fi |
| 2721 | done |
| 2722 | done |
| 2723 | IFS=$as_save_IFS |
| 2724 | |
| 2725 | test -z "$ac_cv_prog_HAS_HG" && ac_cv_prog_HAS_HG="not-found" |
| 2726 | fi |
| 2727 | fi |
| 2728 | HAS_HG=$ac_cv_prog_HAS_HG |
| 2729 | if test -n "$HAS_HG"; then |
| 2730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAS_HG" >&5 |
| 2731 | $as_echo "$HAS_HG" >&6; } |
| 2732 | else |
| 2733 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2734 | $as_echo "no" >&6; } |
| 2735 | fi |
| 2736 | |
| 2737 | |
| 2738 | else |
| 2739 | HAS_HG=no-repository |
| 2740 | fi |
| 2741 | if test $HAS_HG = found |
| 2742 | then |
| 2743 | HGVERSION="hg id -i \$(srcdir)" |
| 2744 | HGTAG="hg id -t \$(srcdir)" |
| 2745 | HGBRANCH="hg id -b \$(srcdir)" |
| 2746 | else |
| 2747 | HGVERSION="" |
| 2748 | HGTAG="" |
| 2749 | HGBRANCH="" |
| 2750 | fi |
| 2751 | |
| 2752 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2753 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2754 | |
| 2755 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2756 | |
Benjamin Peterson | d23f822 | 2009-04-05 19:13:16 +0000 | [diff] [blame] | 2757 | if test "$prefix" != "/"; then |
| 2758 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2759 | fi |
| 2760 | |
| 2761 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2762 | |
| 2763 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 2764 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 2765 | # with other autoconf-based packages that include Python.h |
| 2766 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 2767 | rm confdefs.h |
| 2768 | mv confdefs.h.new confdefs.h |
| 2769 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 2770 | |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 2771 | VERSION=3.3 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 2772 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2773 | # Version number of Python's own shared library file. |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 2774 | |
| 2775 | SOVERSION=1.0 |
| 2776 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2777 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 2778 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 2779 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2780 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2781 | |
| 2782 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2783 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2784 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 2785 | # them. |
| 2786 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2787 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2788 | |
| 2789 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2790 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2791 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 2792 | # them. |
| 2793 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2794 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2795 | |
| 2796 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2797 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2798 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 2799 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2800 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2801 | |
| 2802 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2803 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2804 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 2805 | # them. |
| 2806 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2807 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2808 | |
| 2809 | |
| 2810 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2811 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2812 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 2813 | # Arguments passed to configure. |
| 2814 | |
| 2815 | CONFIG_ARGS="$ac_configure_args" |
| 2816 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2817 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 2818 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2819 | # Check whether --enable-universalsdk was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2820 | if test "${enable_universalsdk+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2821 | enableval=$enable_universalsdk; |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2822 | case $enableval in |
| 2823 | yes) |
| 2824 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2825 | if test ! -d "${enableval}" |
| 2826 | then |
| 2827 | enableval=/ |
| 2828 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2829 | ;; |
| 2830 | esac |
| 2831 | case $enableval in |
| 2832 | no) |
| 2833 | UNIVERSALSDK= |
| 2834 | enable_universalsdk= |
| 2835 | ;; |
| 2836 | *) |
| 2837 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2838 | if test ! -d "${UNIVERSALSDK}" |
| 2839 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 2840 | as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2841 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2842 | ;; |
| 2843 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2844 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2845 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2846 | else |
| 2847 | |
| 2848 | UNIVERSALSDK= |
| 2849 | enable_universalsdk= |
| 2850 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2851 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2852 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2853 | if test -n "${UNIVERSALSDK}" |
| 2854 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 2856 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2857 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2858 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2859 | $as_echo "no" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2860 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2861 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2862 | |
Benjamin Peterson | 6794aa3 | 2008-07-16 20:33:37 +0000 | [diff] [blame] | 2863 | |
| 2864 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2865 | UNIVERSAL_ARCHS="32-bit" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2866 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2867 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 2868 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2869 | |
| 2870 | # Check whether --with-universal-archs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2871 | if test "${with_universal_archs+set}" = set; then : |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2872 | withval=$with_universal_archs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2873 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 2874 | $as_echo "$withval" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2875 | UNIVERSAL_ARCHS="$withval" |
| 2876 | |
| 2877 | else |
| 2878 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 32-bit" >&5 |
| 2880 | $as_echo "32-bit" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2881 | |
| 2882 | fi |
| 2883 | |
| 2884 | |
| 2885 | |
| 2886 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2887 | |
| 2888 | # Check whether --with-framework-name was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2889 | if test "${with_framework_name+set}" = set; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2890 | withval=$with_framework_name; |
| 2891 | PYTHONFRAMEWORK=${withval} |
| 2892 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 2893 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 2894 | |
| 2895 | else |
| 2896 | |
| 2897 | PYTHONFRAMEWORK=Python |
| 2898 | PYTHONFRAMEWORKDIR=Python.framework |
| 2899 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 2900 | |
| 2901 | fi |
| 2902 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2903 | # Check whether --enable-framework was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2904 | if test "${enable_framework+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2905 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2906 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2907 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2908 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2909 | esac |
| 2910 | case $enableval in |
| 2911 | no) |
| 2912 | PYTHONFRAMEWORK= |
| 2913 | PYTHONFRAMEWORKDIR=no-framework |
| 2914 | PYTHONFRAMEWORKPREFIX= |
| 2915 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2916 | FRAMEWORKINSTALLFIRST= |
| 2917 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2918 | FRAMEWORKALTINSTALLFIRST= |
| 2919 | FRAMEWORKALTINSTALLLAST= |
| 2920 | if test "x${prefix}" = "xNONE"; then |
| 2921 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2922 | else |
| 2923 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2924 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2925 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2926 | ;; |
| 2927 | *) |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2928 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2929 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2930 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | f6ccbf6 | 2009-06-02 10:55:56 +0000 | [diff] [blame] | 2931 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure " |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2932 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 2933 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2934 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2935 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2936 | if test "x${prefix}" = "xNONE" ; then |
| 2937 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2938 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2939 | else |
| 2940 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2941 | fi |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2942 | |
| 2943 | case "${enableval}" in |
| 2944 | /System*) |
| 2945 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2946 | if test "${prefix}" = "NONE" ; then |
| 2947 | # See below |
| 2948 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 2949 | fi |
| 2950 | ;; |
| 2951 | |
| 2952 | /Library*) |
| 2953 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2954 | ;; |
| 2955 | |
| 2956 | */Library/Frameworks) |
| 2957 | MDIR="`dirname "${enableval}"`" |
| 2958 | MDIR="`dirname "${MDIR}"`" |
| 2959 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 2960 | |
| 2961 | if test "${prefix}" = "NONE"; then |
| 2962 | # User hasn't specified the |
| 2963 | # --prefix option, but wants to install |
| 2964 | # the framework in a non-default location, |
| 2965 | # ensure that the compatibility links get |
| 2966 | # installed relative to that prefix as well |
| 2967 | # instead of in /usr/local. |
| 2968 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 2969 | fi |
| 2970 | ;; |
| 2971 | |
| 2972 | *) |
| 2973 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2974 | ;; |
| 2975 | esac |
| 2976 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2977 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2978 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2979 | # Add files for Mac specific code to the list of output |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2980 | # files: |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2981 | ac_config_files="$ac_config_files Mac/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2982 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2983 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2984 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2985 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 2986 | |
| 2987 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 2988 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2989 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2990 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2991 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2992 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2993 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2994 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2995 | PYTHONFRAMEWORKPREFIX= |
| 2996 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2997 | FRAMEWORKINSTALLFIRST= |
| 2998 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2999 | FRAMEWORKALTINSTALLFIRST= |
| 3000 | FRAMEWORKALTINSTALLLAST= |
| 3001 | if test "x${prefix}" = "xNONE" ; then |
| 3002 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 3003 | else |
| 3004 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 3005 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3006 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3007 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 3008 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3009 | fi |
| 3010 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3011 | |
| 3012 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3013 | |
| 3014 | |
| 3015 | |
| 3016 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3017 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 3018 | |
| 3019 | |
| 3020 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 3021 | |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 3022 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3023 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 2b8733f | 2010-04-25 18:34:36 +0000 | [diff] [blame] | 3024 | ## AS_HELP_STRING([--with-dyld], |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 3025 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 3026 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3027 | # Set name for machine-dependent library files |
| 3028 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3029 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 3030 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3031 | if test -z "$MACHDEP" |
| 3032 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3033 | ac_sys_system=`uname -s` |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 3034 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 3035 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3036 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3037 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3038 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3039 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3040 | ac_md_system=`echo $ac_sys_system | |
| 3041 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 3042 | ac_md_release=`echo $ac_sys_release | |
Guido van Rossum | 67b2659 | 2001-10-20 14:21:45 +0000 | [diff] [blame] | 3043 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 3044 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3045 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 3046 | case $MACHDEP in |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 3047 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 3048 | darwin*) MACHDEP="darwin";; |
Martin v. Löwis | f332228 | 2003-07-13 09:46:13 +0000 | [diff] [blame] | 3049 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 3050 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3051 | esac |
| 3052 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3053 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3054 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 3055 | # disable features if it is defined, without any means to access these |
| 3056 | # features as extensions. For these systems, we skip the definition of |
| 3057 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 3058 | # some feature, make sure there is no alternative way to access this |
| 3059 | # feature. Also, when using wildcards, make sure you have verified the |
| 3060 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 3061 | # wildcard, and that the wildcard does not include future systems |
| 3062 | # (which may remove their limitations). |
| 3063 | case $ac_sys_system/$ac_sys_release in |
| 3064 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 3065 | # 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] | 3066 | # 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] | 3067 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 3068 | # OpenBSD 4.6, but is fixed in 4.7. |
| 3069 | OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123456]) |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3070 | define_xopen_source=no |
| 3071 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3072 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3073 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3074 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3075 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3076 | |
| 3077 | ;; |
Martin v. Löwis | 19ed3c8 | 2010-02-15 21:45:06 +0000 | [diff] [blame] | 3078 | OpenBSD/4.[789]) |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3079 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3080 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3081 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3082 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3083 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3084 | |
| 3085 | ;; |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 3086 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3087 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3088 | # Marc Recht |
Benjamin Peterson | f608c61 | 2008-11-16 18:33:53 +0000 | [diff] [blame] | 3089 | 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] | 3090 | define_xopen_source=no;; |
Martin v. Löwis | 1a41576 | 2010-05-28 15:44:20 +0000 | [diff] [blame] | 3091 | # From the perspective of Solaris, _XOPEN_SOURCE is not so much a |
| 3092 | # request to enable features supported by the standard as a request |
| 3093 | # to disable features not supported by the standard. The best way |
| 3094 | # for Python to use Solaris is simply to leave _XOPEN_SOURCE out |
| 3095 | # entirely and define __EXTENSIONS__ instead. |
| 3096 | SunOS/*) |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3097 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3098 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3099 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3100 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3101 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3102 | define_xopen_source=no;; |
| 3103 | # 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] | 3104 | # 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] | 3105 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3106 | define_xopen_source=no;; |
Martin v. Löwis | b37509b | 2008-11-04 20:45:29 +0000 | [diff] [blame] | 3107 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3108 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3109 | FreeBSD/4.*) |
| 3110 | define_xopen_source=no;; |
| 3111 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3112 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3113 | # identifies itself as Darwin/7.* |
| 3114 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3115 | # disables platform specific features beyond repair. |
| 3116 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3117 | # has no effect, don't bother defining them |
| 3118 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3119 | define_xopen_source=no;; |
Ronald Oussoren | 92fb941 | 2010-03-09 06:40:19 +0000 | [diff] [blame] | 3120 | Darwin/1[0-9].*) |
Ronald Oussoren | b8f11a6 | 2010-03-08 07:02:03 +0000 | [diff] [blame] | 3121 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3122 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3123 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3124 | # 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] | 3125 | AIX/4) |
| 3126 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3127 | AIX/5) |
| 3128 | if test `uname -r` -eq 1; then |
| 3129 | define_xopen_source=no |
| 3130 | fi |
| 3131 | ;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 3132 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3133 | # defining NI_NUMERICHOST. |
| 3134 | QNX/6.3.2) |
| 3135 | define_xopen_source=no |
| 3136 | ;; |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3137 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3138 | esac |
| 3139 | |
| 3140 | if test $define_xopen_source = yes |
| 3141 | then |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3142 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3143 | $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3144 | |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3145 | |
| 3146 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3147 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3148 | # several APIs are not declared. Since this is also needed in some |
| 3149 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3150 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3151 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3152 | |
| 3153 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3154 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3155 | $as_echo "#define _POSIX_C_SOURCE 200112L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3156 | |
| 3157 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3158 | fi |
| 3159 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3160 | # |
| 3161 | # SGI compilers allow the specification of the both the ABI and the |
| 3162 | # ISA on the command line. Depending on the values of these switches, |
| 3163 | # different and often incompatable code will be generated. |
| 3164 | # |
| 3165 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3166 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3167 | # variable is also adjusted. |
| 3168 | # |
| 3169 | |
| 3170 | if test ! -z "$SGI_ABI" |
| 3171 | then |
| 3172 | CC="cc $SGI_ABI" |
| 3173 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3174 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3175 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3176 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3177 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3178 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3179 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3180 | # it may influence the way we can build extensions, so distutils |
| 3181 | # needs to check it |
| 3182 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3183 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3184 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3185 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3186 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3187 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking machine type as reported by uname -m" >&5 |
| 3188 | $as_echo_n "checking machine type as reported by uname -m... " >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3189 | ac_sys_machine=`uname -m` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_sys_machine" >&5 |
| 3191 | $as_echo "$ac_sys_machine" >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3192 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3193 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3194 | |
| 3195 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3196 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3197 | # just to get things to compile and link. Users are free to override OPT |
| 3198 | # when running configure or make. The build should not break if they do. |
| 3199 | # BASECFLAGS should generally not be messed with, however. |
| 3200 | |
| 3201 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3202 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3203 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3204 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3205 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3206 | # Check whether --with-gcc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3207 | if test "${with_gcc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3208 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3209 | case $withval in |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 3210 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3211 | without_gcc=yes;; |
| 3212 | yes) CC=gcc |
| 3213 | without_gcc=no;; |
| 3214 | *) CC=$withval |
| 3215 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3216 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3217 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3218 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3219 | case $ac_sys_system in |
Antoine Pitrou | f6350d2 | 2010-09-21 15:19:14 +0000 | [diff] [blame] | 3220 | AIX*) CC=${CC:-xlc_r} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3221 | without_gcc=;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3222 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3223 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3224 | fi |
| 3225 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3226 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3227 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3228 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3229 | # If the user switches compilers, we can't believe the cache |
| 3230 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3231 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3232 | as_fn_error $? "cached CC is different -- throw away $cache_file |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3233 | (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] | 3234 | fi |
| 3235 | |
Jeffrey Yasskin | d4fcdb1 | 2010-07-09 16:30:58 +0000 | [diff] [blame] | 3236 | # Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2 |
| 3237 | # when the compiler supports them, but we don't always want -O2, and |
| 3238 | # we set -g later. |
| 3239 | if test -z "$CFLAGS"; then |
| 3240 | CFLAGS= |
| 3241 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3242 | ac_ext=c |
| 3243 | ac_cpp='$CPP $CPPFLAGS' |
| 3244 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3245 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3246 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3247 | if test -n "$ac_tool_prefix"; then |
| 3248 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3249 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3251 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3252 | if test "${ac_cv_prog_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3253 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3254 | else |
| 3255 | if test -n "$CC"; then |
| 3256 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3257 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3258 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3259 | for as_dir in $PATH |
| 3260 | do |
| 3261 | IFS=$as_save_IFS |
| 3262 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3263 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3264 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3265 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3266 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3267 | break 2 |
| 3268 | fi |
| 3269 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3270 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3271 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3272 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3273 | fi |
| 3274 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3275 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3276 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3278 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3279 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3281 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3282 | fi |
| 3283 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3284 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3285 | fi |
| 3286 | if test -z "$ac_cv_prog_CC"; then |
| 3287 | ac_ct_CC=$CC |
| 3288 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3289 | set dummy gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3290 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3291 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3292 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3293 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3294 | else |
| 3295 | if test -n "$ac_ct_CC"; then |
| 3296 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3297 | else |
| 3298 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3299 | for as_dir in $PATH |
| 3300 | do |
| 3301 | IFS=$as_save_IFS |
| 3302 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3303 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3304 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3305 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3306 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3307 | break 2 |
| 3308 | fi |
| 3309 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3310 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3311 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3312 | |
| 3313 | fi |
| 3314 | fi |
| 3315 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3316 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3317 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3318 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3319 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3320 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3321 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3322 | fi |
| 3323 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3324 | if test "x$ac_ct_CC" = x; then |
| 3325 | CC="" |
| 3326 | else |
| 3327 | case $cross_compiling:$ac_tool_warned in |
| 3328 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3329 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3330 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3331 | ac_tool_warned=yes ;; |
| 3332 | esac |
| 3333 | CC=$ac_ct_CC |
| 3334 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3335 | else |
| 3336 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3337 | fi |
| 3338 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3339 | if test -z "$CC"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3340 | if test -n "$ac_tool_prefix"; then |
| 3341 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3342 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3343 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3344 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3345 | if test "${ac_cv_prog_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3346 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3347 | else |
| 3348 | if test -n "$CC"; then |
| 3349 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3350 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3351 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3352 | for as_dir in $PATH |
| 3353 | do |
| 3354 | IFS=$as_save_IFS |
| 3355 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3356 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3357 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3358 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3359 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3360 | break 2 |
| 3361 | fi |
| 3362 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3363 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3364 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3365 | |
| 3366 | fi |
| 3367 | fi |
| 3368 | CC=$ac_cv_prog_CC |
| 3369 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3371 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3372 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3374 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3375 | fi |
| 3376 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3377 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3378 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3379 | fi |
| 3380 | if test -z "$CC"; then |
| 3381 | # Extract the first word of "cc", so it can be a program name with args. |
| 3382 | set dummy cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3383 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3384 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3385 | if test "${ac_cv_prog_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3386 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3387 | else |
| 3388 | if test -n "$CC"; then |
| 3389 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3390 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3391 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3392 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3393 | for as_dir in $PATH |
| 3394 | do |
| 3395 | IFS=$as_save_IFS |
| 3396 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3397 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3398 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3399 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3400 | ac_prog_rejected=yes |
| 3401 | continue |
| 3402 | fi |
| 3403 | ac_cv_prog_CC="cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3404 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3405 | break 2 |
| 3406 | fi |
| 3407 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3408 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3409 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3410 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3411 | if test $ac_prog_rejected = yes; then |
| 3412 | # We found a bogon in the path, so make sure we never use it. |
| 3413 | set dummy $ac_cv_prog_CC |
| 3414 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3415 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3416 | # We chose a different compiler from the bogus one. |
| 3417 | # However, it has the same basename, so the bogon will be chosen |
| 3418 | # first if we set CC to just the basename; use the full file name. |
| 3419 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3420 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3421 | fi |
| 3422 | fi |
| 3423 | fi |
| 3424 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3425 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3426 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3428 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3429 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3431 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3432 | fi |
| 3433 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3434 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3435 | fi |
| 3436 | if test -z "$CC"; then |
| 3437 | if test -n "$ac_tool_prefix"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3438 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3439 | do |
| 3440 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3441 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3442 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3443 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3444 | if test "${ac_cv_prog_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3445 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3446 | else |
| 3447 | if test -n "$CC"; then |
| 3448 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3449 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3450 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3451 | for as_dir in $PATH |
| 3452 | do |
| 3453 | IFS=$as_save_IFS |
| 3454 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3455 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3456 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3457 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3458 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3459 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3460 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3461 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3462 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3463 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3464 | |
| 3465 | fi |
| 3466 | fi |
| 3467 | CC=$ac_cv_prog_CC |
| 3468 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3470 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3471 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3472 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3473 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3474 | fi |
| 3475 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3476 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3477 | test -n "$CC" && break |
| 3478 | done |
| 3479 | fi |
| 3480 | if test -z "$CC"; then |
| 3481 | ac_ct_CC=$CC |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3482 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3483 | do |
| 3484 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3485 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3486 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3487 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3488 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3489 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3490 | else |
| 3491 | if test -n "$ac_ct_CC"; then |
| 3492 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3493 | else |
| 3494 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3495 | for as_dir in $PATH |
| 3496 | do |
| 3497 | IFS=$as_save_IFS |
| 3498 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3499 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3500 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3501 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3502 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3503 | break 2 |
| 3504 | fi |
| 3505 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3506 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3507 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3508 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3509 | fi |
| 3510 | fi |
| 3511 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3512 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3513 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3514 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3515 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3517 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3518 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3519 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3520 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3521 | test -n "$ac_ct_CC" && break |
| 3522 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3523 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3524 | if test "x$ac_ct_CC" = x; then |
| 3525 | CC="" |
| 3526 | else |
| 3527 | case $cross_compiling:$ac_tool_warned in |
| 3528 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3529 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3530 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3531 | ac_tool_warned=yes ;; |
| 3532 | esac |
| 3533 | CC=$ac_ct_CC |
| 3534 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3535 | fi |
| 3536 | |
| 3537 | fi |
| 3538 | |
| 3539 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3540 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3541 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3542 | as_fn_error $? "no acceptable C compiler found in \$PATH |
| 3543 | See \`config.log' for more details" "$LINENO" 5 ; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3544 | |
| 3545 | # Provide some information about the compiler. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3546 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3547 | set X $ac_compile |
| 3548 | ac_compiler=$2 |
| 3549 | for ac_option in --version -v -V -qversion; do |
| 3550 | { { ac_try="$ac_compiler $ac_option >&5" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3551 | case "(($ac_try" in |
| 3552 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3553 | *) ac_try_echo=$ac_try;; |
| 3554 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3555 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3556 | $as_echo "$ac_try_echo"; } >&5 |
| 3557 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3558 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3559 | if test -s conftest.err; then |
| 3560 | sed '10a\ |
| 3561 | ... rest of stderr output deleted ... |
| 3562 | 10q' conftest.err >conftest.er1 |
| 3563 | cat conftest.er1 >&5 |
| 3564 | fi |
| 3565 | rm -f conftest.er1 conftest.err |
| 3566 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3567 | test $ac_status = 0; } |
| 3568 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3569 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3570 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3571 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3572 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3573 | int |
| 3574 | main () |
| 3575 | { |
| 3576 | |
| 3577 | ; |
| 3578 | return 0; |
| 3579 | } |
| 3580 | _ACEOF |
| 3581 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3582 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3583 | # Try to create an executable without -o first, disregard a.out. |
| 3584 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3585 | # of exeext. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3587 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3588 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3589 | |
| 3590 | # The possible output files: |
| 3591 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3592 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3593 | ac_rmfiles= |
| 3594 | for ac_file in $ac_files |
| 3595 | do |
| 3596 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3597 | *.$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] | 3598 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3599 | esac |
| 3600 | done |
| 3601 | rm -f $ac_rmfiles |
| 3602 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3603 | if { { ac_try="$ac_link_default" |
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_default") 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 | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3614 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3615 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3616 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3617 | # so that the user can short-circuit this test for compilers unknown to |
| 3618 | # Autoconf. |
| 3619 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3620 | do |
| 3621 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3622 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3623 | *.$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] | 3624 | ;; |
| 3625 | [ab].out ) |
| 3626 | # We found the default executable, but exeext='' is most |
| 3627 | # certainly right. |
| 3628 | break;; |
| 3629 | *.* ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3630 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3631 | then :; else |
| 3632 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3633 | fi |
| 3634 | # We set ac_cv_exeext here because the later test for it is not |
| 3635 | # safe: cross compilers may not add the suffix if given an `-o' |
| 3636 | # argument, so we may need to know it at that point already. |
| 3637 | # Even if this section looks crufty: it has the advantage of |
| 3638 | # actually working. |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3639 | break;; |
| 3640 | * ) |
| 3641 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3642 | esac |
| 3643 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3644 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 3645 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3646 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3647 | ac_file='' |
| 3648 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3649 | if test -z "$ac_file"; then : |
| 3650 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3651 | $as_echo "no" >&6; } |
| 3652 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3653 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3654 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3655 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3656 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3657 | as_fn_error 77 "C compiler cannot create executables |
| 3658 | See \`config.log' for more details" "$LINENO" 5 ; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3659 | else |
| 3660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 3661 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3662 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3663 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 3664 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 3665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 3666 | $as_echo "$ac_file" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3667 | ac_exeext=$ac_cv_exeext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3668 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3669 | 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] | 3670 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3671 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 3672 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 3673 | if { { ac_try="$ac_link" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3674 | case "(($ac_try" in |
| 3675 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3676 | *) ac_try_echo=$ac_try;; |
| 3677 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3678 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3679 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3680 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3681 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3682 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3683 | test $ac_status = 0; }; then : |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3684 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 3685 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 3686 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 3687 | # `rm'. |
| 3688 | for ac_file in conftest.exe conftest conftest.*; do |
| 3689 | test -f "$ac_file" || continue |
| 3690 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3691 | *.$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] | 3692 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3693 | break;; |
| 3694 | * ) break;; |
| 3695 | esac |
| 3696 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3697 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3698 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3699 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3700 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
| 3701 | See \`config.log' for more details" "$LINENO" 5 ; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3702 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3703 | rm -f conftest conftest$ac_cv_exeext |
| 3704 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 3705 | $as_echo "$ac_cv_exeext" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3706 | |
| 3707 | rm -f conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3708 | EXEEXT=$ac_cv_exeext |
| 3709 | ac_exeext=$EXEEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3710 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3711 | /* end confdefs.h. */ |
| 3712 | #include <stdio.h> |
| 3713 | int |
| 3714 | main () |
| 3715 | { |
| 3716 | FILE *f = fopen ("conftest.out", "w"); |
| 3717 | return ferror (f) || fclose (f) != 0; |
| 3718 | |
| 3719 | ; |
| 3720 | return 0; |
| 3721 | } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3722 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3723 | ac_clean_files="$ac_clean_files conftest.out" |
| 3724 | # Check that the compiler produces executables we can run. If not, either |
| 3725 | # the compiler is broken, or we cross compile. |
| 3726 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3727 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3728 | if test "$cross_compiling" != yes; then |
| 3729 | { { ac_try="$ac_link" |
| 3730 | case "(($ac_try" in |
| 3731 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3732 | *) ac_try_echo=$ac_try;; |
| 3733 | esac |
| 3734 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3735 | $as_echo "$ac_try_echo"; } >&5 |
| 3736 | (eval "$ac_link") 2>&5 |
| 3737 | ac_status=$? |
| 3738 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3739 | test $ac_status = 0; } |
| 3740 | if { ac_try='./conftest$ac_cv_exeext' |
| 3741 | { { case "(($ac_try" in |
| 3742 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3743 | *) ac_try_echo=$ac_try;; |
| 3744 | esac |
| 3745 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3746 | $as_echo "$ac_try_echo"; } >&5 |
| 3747 | (eval "$ac_try") 2>&5 |
| 3748 | ac_status=$? |
| 3749 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3750 | test $ac_status = 0; }; }; then |
| 3751 | cross_compiling=no |
| 3752 | else |
| 3753 | if test "$cross_compiling" = maybe; then |
| 3754 | cross_compiling=yes |
| 3755 | else |
| 3756 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3757 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3758 | as_fn_error $? "cannot run C compiled programs. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3759 | If you meant to cross compile, use \`--host'. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3760 | See \`config.log' for more details" "$LINENO" 5 ; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3761 | fi |
| 3762 | fi |
| 3763 | fi |
| 3764 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3765 | $as_echo "$cross_compiling" >&6; } |
| 3766 | |
| 3767 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3768 | ac_clean_files=$ac_clean_files_save |
| 3769 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3770 | $as_echo_n "checking for suffix of object files... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3771 | if test "${ac_cv_objext+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3772 | $as_echo_n "(cached) " >&6 |
| 3773 | else |
| 3774 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3775 | /* end confdefs.h. */ |
| 3776 | |
| 3777 | int |
| 3778 | main () |
| 3779 | { |
| 3780 | |
| 3781 | ; |
| 3782 | return 0; |
| 3783 | } |
| 3784 | _ACEOF |
| 3785 | rm -f conftest.o conftest.obj |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3786 | if { { ac_try="$ac_compile" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3787 | case "(($ac_try" in |
| 3788 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3789 | *) ac_try_echo=$ac_try;; |
| 3790 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3791 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3792 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3793 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3794 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3795 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3796 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3797 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3798 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3799 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3800 | *.$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] | 3801 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3802 | break;; |
| 3803 | esac |
| 3804 | done |
| 3805 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3806 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3807 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3808 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3809 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3810 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 3811 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
| 3812 | See \`config.log' for more details" "$LINENO" 5 ; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3813 | fi |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3814 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3815 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3817 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3818 | OBJEXT=$ac_cv_objext |
| 3819 | ac_objext=$OBJEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3820 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3821 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3822 | if test "${ac_cv_c_compiler_gnu+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3823 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3824 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3825 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3826 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3827 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3828 | int |
| 3829 | main () |
| 3830 | { |
| 3831 | #ifndef __GNUC__ |
| 3832 | choke me |
| 3833 | #endif |
| 3834 | |
| 3835 | ; |
| 3836 | return 0; |
| 3837 | } |
| 3838 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3839 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3840 | ac_compiler_gnu=yes |
| 3841 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3842 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3843 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3844 | 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] | 3845 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3846 | |
| 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_c_compiler_gnu" >&5 |
| 3849 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3850 | if test $ac_compiler_gnu = yes; then |
| 3851 | GCC=yes |
| 3852 | else |
| 3853 | GCC= |
| 3854 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3855 | ac_test_CFLAGS=${CFLAGS+set} |
| 3856 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3857 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3858 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3859 | if test "${ac_cv_prog_cc_g+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3860 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3861 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3862 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3863 | ac_c_werror_flag=yes |
| 3864 | ac_cv_prog_cc_g=no |
| 3865 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3866 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3867 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3868 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3869 | int |
| 3870 | main () |
| 3871 | { |
| 3872 | |
| 3873 | ; |
| 3874 | return 0; |
| 3875 | } |
| 3876 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3877 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3878 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3879 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3880 | CFLAGS="" |
| 3881 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3882 | /* end confdefs.h. */ |
| 3883 | |
| 3884 | int |
| 3885 | main () |
| 3886 | { |
| 3887 | |
| 3888 | ; |
| 3889 | return 0; |
| 3890 | } |
| 3891 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3892 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3893 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3894 | else |
| 3895 | ac_c_werror_flag=$ac_save_c_werror_flag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3896 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3897 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3898 | /* end confdefs.h. */ |
| 3899 | |
| 3900 | int |
| 3901 | main () |
| 3902 | { |
| 3903 | |
| 3904 | ; |
| 3905 | return 0; |
| 3906 | } |
| 3907 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3908 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3909 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3910 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3911 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3912 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3913 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3914 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3915 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3916 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3917 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3918 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3919 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3920 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3921 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3922 | elif test $ac_cv_prog_cc_g = yes; then |
| 3923 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3924 | CFLAGS="-g -O2" |
| 3925 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3926 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3927 | fi |
| 3928 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3929 | if test "$GCC" = yes; then |
| 3930 | CFLAGS="-O2" |
| 3931 | else |
| 3932 | CFLAGS= |
| 3933 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3934 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3935 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3936 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 3937 | if test "${ac_cv_prog_cc_c89+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3938 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3939 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3940 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3941 | ac_save_CC=$CC |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3942 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3943 | /* end confdefs.h. */ |
| 3944 | #include <stdarg.h> |
| 3945 | #include <stdio.h> |
| 3946 | #include <sys/types.h> |
| 3947 | #include <sys/stat.h> |
| 3948 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3949 | struct buf { int x; }; |
| 3950 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3951 | static char *e (p, i) |
| 3952 | char **p; |
| 3953 | int i; |
| 3954 | { |
| 3955 | return p[i]; |
| 3956 | } |
| 3957 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3958 | { |
| 3959 | char *s; |
| 3960 | va_list v; |
| 3961 | va_start (v,p); |
| 3962 | s = g (p, va_arg (v,int)); |
| 3963 | va_end (v); |
| 3964 | return s; |
| 3965 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3966 | |
| 3967 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3968 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3969 | These don't provoke an error unfortunately, instead are silently treated |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3970 | 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] | 3971 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3972 | 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] | 3973 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3974 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3975 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3976 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3977 | inside strings and character constants. */ |
| 3978 | #define FOO(x) 'x' |
| 3979 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3980 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3981 | int test (int i, double x); |
| 3982 | struct s1 {int (*f) (int a);}; |
| 3983 | struct s2 {int (*f) (double a);}; |
| 3984 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3985 | int argc; |
| 3986 | char **argv; |
| 3987 | int |
| 3988 | main () |
| 3989 | { |
| 3990 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3991 | ; |
| 3992 | return 0; |
| 3993 | } |
| 3994 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3995 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3996 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3997 | do |
| 3998 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3999 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4000 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4001 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4002 | rm -f core conftest.err conftest.$ac_objext |
| 4003 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4004 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4005 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4006 | CC=$ac_save_CC |
| 4007 | |
| 4008 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4009 | # AC_CACHE_VAL |
| 4010 | case "x$ac_cv_prog_cc_c89" in |
| 4011 | x) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 4013 | $as_echo "none needed" >&6; } ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4014 | xno) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4015 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 4016 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4017 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4018 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4019 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 4020 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4021 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4022 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4023 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4024 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4025 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4026 | ac_ext=c |
| 4027 | ac_cpp='$CPP $CPPFLAGS' |
| 4028 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4029 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4030 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4031 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4032 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4033 | |
| 4034 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4035 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 4036 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4037 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4038 | # Check whether --with-cxx_main was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4039 | if test "${with_cxx_main+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4040 | withval=$with_cxx_main; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4041 | |
| 4042 | case $withval in |
| 4043 | no) with_cxx_main=no |
| 4044 | MAINCC='$(CC)';; |
| 4045 | yes) with_cxx_main=yes |
| 4046 | MAINCC='$(CXX)';; |
| 4047 | *) with_cxx_main=yes |
| 4048 | MAINCC=$withval |
| 4049 | if test -z "$CXX" |
| 4050 | then |
| 4051 | CXX=$withval |
| 4052 | fi;; |
| 4053 | esac |
| 4054 | else |
| 4055 | |
| 4056 | with_cxx_main=no |
| 4057 | MAINCC='$(CC)' |
| 4058 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4059 | fi |
| 4060 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4061 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 4062 | $as_echo "$with_cxx_main" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4063 | |
| 4064 | preset_cxx="$CXX" |
| 4065 | if test -z "$CXX" |
| 4066 | then |
| 4067 | case "$CC" in |
| 4068 | gcc) # Extract the first word of "g++", so it can be a program name with args. |
| 4069 | set dummy g++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4070 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4071 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4072 | if test "${ac_cv_path_CXX+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4073 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4074 | else |
| 4075 | case $CXX in |
| 4076 | [\\/]* | ?:[\\/]*) |
| 4077 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4078 | ;; |
| 4079 | *) |
| 4080 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4081 | for as_dir in notfound |
| 4082 | do |
| 4083 | IFS=$as_save_IFS |
| 4084 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4085 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4086 | 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] | 4087 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4088 | $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] | 4089 | break 2 |
| 4090 | fi |
| 4091 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4092 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4093 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4094 | |
| 4095 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++" |
| 4096 | ;; |
| 4097 | esac |
| 4098 | fi |
| 4099 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4100 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4101 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4102 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4103 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4104 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4105 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4106 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4107 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4108 | ;; |
| 4109 | cc) # Extract the first word of "c++", so it can be a program name with args. |
| 4110 | set dummy c++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4111 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4112 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4113 | if test "${ac_cv_path_CXX+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4114 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4115 | else |
| 4116 | case $CXX in |
| 4117 | [\\/]* | ?:[\\/]*) |
| 4118 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4119 | ;; |
| 4120 | *) |
| 4121 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4122 | for as_dir in notfound |
| 4123 | do |
| 4124 | IFS=$as_save_IFS |
| 4125 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4126 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4127 | 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] | 4128 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4129 | $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] | 4130 | break 2 |
| 4131 | fi |
| 4132 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4133 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4134 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4135 | |
| 4136 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++" |
| 4137 | ;; |
| 4138 | esac |
| 4139 | fi |
| 4140 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4141 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4142 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4143 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4144 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4146 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4147 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4148 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4149 | ;; |
| 4150 | esac |
| 4151 | if test "$CXX" = "notfound" |
| 4152 | then |
| 4153 | CXX="" |
| 4154 | fi |
| 4155 | fi |
| 4156 | if test -z "$CXX" |
| 4157 | then |
| 4158 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4159 | do |
| 4160 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4161 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4162 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4163 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4164 | if test "${ac_cv_prog_CXX+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4165 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4166 | else |
| 4167 | if test -n "$CXX"; then |
| 4168 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4169 | else |
| 4170 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4171 | for as_dir in $PATH |
| 4172 | do |
| 4173 | IFS=$as_save_IFS |
| 4174 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4175 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4176 | 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] | 4177 | ac_cv_prog_CXX="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4178 | $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] | 4179 | break 2 |
| 4180 | fi |
| 4181 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4182 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4183 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4184 | |
| 4185 | fi |
| 4186 | fi |
| 4187 | CXX=$ac_cv_prog_CXX |
| 4188 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4190 | $as_echo "$CXX" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4191 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4192 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4193 | $as_echo "no" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4194 | fi |
| 4195 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4196 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4197 | test -n "$CXX" && break |
| 4198 | done |
| 4199 | test -n "$CXX" || CXX="notfound" |
| 4200 | |
| 4201 | if test "$CXX" = "notfound" |
| 4202 | then |
| 4203 | CXX="" |
| 4204 | fi |
| 4205 | fi |
| 4206 | if test "$preset_cxx" != "$CXX" |
| 4207 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4208 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4209 | |
| 4210 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4211 | If this is not intended, then set CXX on the configure command line. |
| 4212 | " >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4213 | $as_echo "$as_me: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4214 | |
| 4215 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4216 | If this is not intended, then set CXX on the configure command line. |
| 4217 | " >&2;} |
| 4218 | fi |
| 4219 | |
| 4220 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wl,--no-as-needed" >&5 |
| 4222 | $as_echo_n "checking for -Wl,--no-as-needed... " >&6; } |
| 4223 | save_LDFLAGS="$LDFLAGS" |
| 4224 | LDFLAGS="$LDFLAGS -Wl,--no-as-needed" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4225 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4226 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4227 | /* end confdefs.h. */ |
| 4228 | |
| 4229 | int |
| 4230 | main () |
| 4231 | { |
| 4232 | |
| 4233 | ; |
| 4234 | return 0; |
| 4235 | } |
| 4236 | _ACEOF |
| 4237 | if ac_fn_c_try_link "$LINENO"; then : |
| 4238 | NO_AS_NEEDED="-Wl,--no-as-needed" |
| 4239 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4240 | $as_echo "yes" >&6; } |
| 4241 | else |
| 4242 | NO_AS_NEEDED="" |
| 4243 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4244 | $as_echo "no" >&6; } |
| 4245 | fi |
| 4246 | rm -f core conftest.err conftest.$ac_objext \ |
| 4247 | conftest$ac_exeext conftest.$ac_ext |
| 4248 | LDFLAGS="$save_LDFLAGS" |
| 4249 | |
| 4250 | |
| 4251 | |
| 4252 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4253 | ac_ext=c |
| 4254 | ac_cpp='$CPP $CPPFLAGS' |
| 4255 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4256 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4257 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4258 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4259 | $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] | 4260 | # On Suns, sometimes $CPP names a directory. |
| 4261 | if test -n "$CPP" && test -d "$CPP"; then |
| 4262 | CPP= |
| 4263 | fi |
| 4264 | if test -z "$CPP"; then |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4265 | if test "${ac_cv_prog_CPP+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4266 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4267 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4268 | # Double quotes because CPP needs to be expanded |
| 4269 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4270 | do |
| 4271 | ac_preproc_ok=false |
| 4272 | for ac_c_preproc_warn_flag in '' yes |
| 4273 | do |
| 4274 | # Use a header file that comes with gcc, so configuring glibc |
| 4275 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4276 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4277 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4278 | # 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] | 4279 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4280 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4281 | /* end confdefs.h. */ |
| 4282 | #ifdef __STDC__ |
| 4283 | # include <limits.h> |
| 4284 | #else |
| 4285 | # include <assert.h> |
| 4286 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4287 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4288 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4289 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4290 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4291 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4292 | # Broken: fails on valid input. |
| 4293 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4294 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4295 | rm -f conftest.err conftest.i conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4296 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4297 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4298 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4299 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4300 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4301 | #include <ac_nonexistent.h> |
| 4302 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4303 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4304 | # Broken: success on invalid input. |
| 4305 | continue |
| 4306 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4307 | # Passes both tests. |
| 4308 | ac_preproc_ok=: |
| 4309 | break |
| 4310 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4311 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4312 | |
| 4313 | done |
| 4314 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4315 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4316 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4317 | break |
| 4318 | fi |
| 4319 | |
| 4320 | done |
| 4321 | ac_cv_prog_CPP=$CPP |
| 4322 | |
| 4323 | fi |
| 4324 | CPP=$ac_cv_prog_CPP |
| 4325 | else |
| 4326 | ac_cv_prog_CPP=$CPP |
| 4327 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4328 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4329 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4330 | ac_preproc_ok=false |
| 4331 | for ac_c_preproc_warn_flag in '' yes |
| 4332 | do |
| 4333 | # Use a header file that comes with gcc, so configuring glibc |
| 4334 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4335 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4336 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4337 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4338 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4339 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4340 | /* end confdefs.h. */ |
| 4341 | #ifdef __STDC__ |
| 4342 | # include <limits.h> |
| 4343 | #else |
| 4344 | # include <assert.h> |
| 4345 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4346 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4347 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4348 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4349 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4350 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4351 | # Broken: fails on valid input. |
| 4352 | continue |
| 4353 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4354 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4355 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4356 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4357 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4358 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4359 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4360 | #include <ac_nonexistent.h> |
| 4361 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4362 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4363 | # Broken: success on invalid input. |
| 4364 | continue |
| 4365 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4366 | # Passes both tests. |
| 4367 | ac_preproc_ok=: |
| 4368 | break |
| 4369 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4370 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4371 | |
| 4372 | done |
| 4373 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4374 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4375 | if $ac_preproc_ok; then : |
| 4376 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4377 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4378 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4379 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4380 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
| 4381 | See \`config.log' for more details" "$LINENO" 5 ; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4382 | fi |
| 4383 | |
| 4384 | ac_ext=c |
| 4385 | ac_cpp='$CPP $CPPFLAGS' |
| 4386 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4387 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4388 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 4389 | |
| 4390 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4391 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 4392 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4393 | if test "${ac_cv_path_GREP+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4394 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4395 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4396 | if test -z "$GREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4397 | ac_path_GREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4398 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4399 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4400 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4401 | do |
| 4402 | IFS=$as_save_IFS |
| 4403 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4404 | for ac_prog in grep ggrep; do |
| 4405 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4406 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4407 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue |
| 4408 | # 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] | 4409 | # Check for GNU $ac_path_GREP |
| 4410 | case `"$ac_path_GREP" --version 2>&1` in |
| 4411 | *GNU*) |
| 4412 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 4413 | *) |
| 4414 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4415 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4416 | while : |
| 4417 | do |
| 4418 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4419 | mv "conftest.tmp" "conftest.in" |
| 4420 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4421 | $as_echo 'GREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4422 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4423 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4424 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4425 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 4426 | # Best one so far, save it but keep looking for a better one |
| 4427 | ac_cv_path_GREP="$ac_path_GREP" |
| 4428 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4429 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4430 | # 10*(2^10) chars as input seems more than enough |
| 4431 | test $ac_count -gt 10 && break |
| 4432 | done |
| 4433 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4434 | esac |
| 4435 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4436 | $ac_path_GREP_found && break 3 |
| 4437 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4438 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4439 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4440 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4441 | if test -z "$ac_cv_path_GREP"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4442 | 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] | 4443 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4444 | else |
| 4445 | ac_cv_path_GREP=$GREP |
| 4446 | fi |
| 4447 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4448 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4449 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 4450 | $as_echo "$ac_cv_path_GREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4451 | GREP="$ac_cv_path_GREP" |
| 4452 | |
| 4453 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4454 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 4455 | $as_echo_n "checking for egrep... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4456 | if test "${ac_cv_path_EGREP+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4457 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4458 | else |
| 4459 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 4460 | then ac_cv_path_EGREP="$GREP -E" |
| 4461 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4462 | if test -z "$EGREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4463 | ac_path_EGREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4464 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4465 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4466 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4467 | do |
| 4468 | IFS=$as_save_IFS |
| 4469 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4470 | for ac_prog in egrep; do |
| 4471 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4472 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4473 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
| 4474 | # 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] | 4475 | # Check for GNU $ac_path_EGREP |
| 4476 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4477 | *GNU*) |
| 4478 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4479 | *) |
| 4480 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4481 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4482 | while : |
| 4483 | do |
| 4484 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4485 | mv "conftest.tmp" "conftest.in" |
| 4486 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4487 | $as_echo 'EGREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4488 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4489 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4490 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4491 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4492 | # Best one so far, save it but keep looking for a better one |
| 4493 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4494 | ac_path_EGREP_max=$ac_count |
| 4495 | fi |
| 4496 | # 10*(2^10) chars as input seems more than enough |
| 4497 | test $ac_count -gt 10 && break |
| 4498 | done |
| 4499 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4500 | esac |
| 4501 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4502 | $ac_path_EGREP_found && break 3 |
| 4503 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4504 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4505 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4506 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4507 | if test -z "$ac_cv_path_EGREP"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4508 | 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] | 4509 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4510 | else |
| 4511 | ac_cv_path_EGREP=$EGREP |
| 4512 | fi |
| 4513 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4514 | fi |
| 4515 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4517 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4518 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4519 | |
| 4520 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4521 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4522 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4523 | if test "${ac_cv_header_stdc+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4524 | $as_echo_n "(cached) " >&6 |
| 4525 | else |
| 4526 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4527 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4528 | #include <stdlib.h> |
| 4529 | #include <stdarg.h> |
| 4530 | #include <string.h> |
| 4531 | #include <float.h> |
| 4532 | |
| 4533 | int |
| 4534 | main () |
| 4535 | { |
| 4536 | |
| 4537 | ; |
| 4538 | return 0; |
| 4539 | } |
| 4540 | _ACEOF |
| 4541 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4542 | ac_cv_header_stdc=yes |
| 4543 | else |
| 4544 | ac_cv_header_stdc=no |
| 4545 | fi |
| 4546 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4547 | |
| 4548 | if test $ac_cv_header_stdc = yes; then |
| 4549 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4551 | /* end confdefs.h. */ |
| 4552 | #include <string.h> |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4553 | |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4554 | _ACEOF |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4555 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4556 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4557 | |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4558 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4559 | ac_cv_header_stdc=no |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4560 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 4561 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4562 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4563 | fi |
| 4564 | |
| 4565 | if test $ac_cv_header_stdc = yes; then |
| 4566 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4567 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4568 | /* end confdefs.h. */ |
| 4569 | #include <stdlib.h> |
| 4570 | |
| 4571 | _ACEOF |
| 4572 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4573 | $EGREP "free" >/dev/null 2>&1; then : |
| 4574 | |
| 4575 | else |
| 4576 | ac_cv_header_stdc=no |
| 4577 | fi |
| 4578 | rm -f conftest* |
| 4579 | |
| 4580 | fi |
| 4581 | |
| 4582 | if test $ac_cv_header_stdc = yes; then |
| 4583 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4584 | if test "$cross_compiling" = yes; then : |
| 4585 | : |
| 4586 | else |
| 4587 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4588 | /* end confdefs.h. */ |
| 4589 | #include <ctype.h> |
| 4590 | #include <stdlib.h> |
| 4591 | #if ((' ' & 0x0FF) == 0x020) |
| 4592 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4593 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4594 | #else |
| 4595 | # define ISLOWER(c) \ |
| 4596 | (('a' <= (c) && (c) <= 'i') \ |
| 4597 | || ('j' <= (c) && (c) <= 'r') \ |
| 4598 | || ('s' <= (c) && (c) <= 'z')) |
| 4599 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4600 | #endif |
| 4601 | |
| 4602 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4603 | int |
| 4604 | main () |
| 4605 | { |
| 4606 | int i; |
| 4607 | for (i = 0; i < 256; i++) |
| 4608 | if (XOR (islower (i), ISLOWER (i)) |
| 4609 | || toupper (i) != TOUPPER (i)) |
| 4610 | return 2; |
| 4611 | return 0; |
| 4612 | } |
| 4613 | _ACEOF |
| 4614 | if ac_fn_c_try_run "$LINENO"; then : |
| 4615 | |
| 4616 | else |
| 4617 | ac_cv_header_stdc=no |
| 4618 | fi |
| 4619 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4620 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 4621 | fi |
| 4622 | |
| 4623 | fi |
| 4624 | fi |
| 4625 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4626 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 4627 | if test $ac_cv_header_stdc = yes; then |
| 4628 | |
| 4629 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 4630 | |
| 4631 | fi |
| 4632 | |
| 4633 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 4634 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4635 | inttypes.h stdint.h unistd.h |
| 4636 | do : |
| 4637 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4638 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4639 | " |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 4640 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4641 | cat >>confdefs.h <<_ACEOF |
| 4642 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4643 | _ACEOF |
| 4644 | |
| 4645 | fi |
| 4646 | |
| 4647 | done |
| 4648 | |
| 4649 | |
| 4650 | |
| 4651 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4652 | if test "x$ac_cv_header_minix_config_h" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4653 | MINIX=yes |
| 4654 | else |
| 4655 | MINIX= |
| 4656 | fi |
| 4657 | |
| 4658 | |
| 4659 | if test "$MINIX" = yes; then |
| 4660 | |
| 4661 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 4662 | |
| 4663 | |
| 4664 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 4665 | |
| 4666 | |
| 4667 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 4668 | |
| 4669 | fi |
| 4670 | |
| 4671 | |
| 4672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 4673 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4674 | if test "${ac_cv_safe_to_define___extensions__+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4675 | $as_echo_n "(cached) " >&6 |
| 4676 | else |
| 4677 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4678 | /* end confdefs.h. */ |
| 4679 | |
| 4680 | # define __EXTENSIONS__ 1 |
| 4681 | $ac_includes_default |
| 4682 | int |
| 4683 | main () |
| 4684 | { |
| 4685 | |
| 4686 | ; |
| 4687 | return 0; |
| 4688 | } |
| 4689 | _ACEOF |
| 4690 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4691 | ac_cv_safe_to_define___extensions__=yes |
| 4692 | else |
| 4693 | ac_cv_safe_to_define___extensions__=no |
| 4694 | fi |
| 4695 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4696 | fi |
| 4697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 4698 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 4699 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 4700 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 4701 | |
| 4702 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 4703 | |
| 4704 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 4705 | |
| 4706 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 4707 | |
| 4708 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 4709 | |
| 4710 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4711 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4712 | # Check for unsupported systems |
| 4713 | case $ac_sys_system/$ac_sys_release in |
| 4714 | atheos*|Linux*/1*) |
| 4715 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 4716 | echo See README for details. |
| 4717 | exit 1;; |
| 4718 | esac |
| 4719 | |
| 4720 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4721 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 4722 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4723 | |
| 4724 | # Check whether --with-suffix was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4725 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4726 | withval=$with_suffix; |
| 4727 | case $withval in |
| 4728 | no) EXEEXT=;; |
| 4729 | yes) EXEEXT=.exe;; |
| 4730 | *) EXEEXT=$withval;; |
| 4731 | esac |
| 4732 | fi |
| 4733 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 4735 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4736 | |
| 4737 | # Test whether we're running on a non-case-sensitive system, in which |
| 4738 | # case we give a warning if no ext is given |
| 4739 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 4741 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4742 | if test ! -d CaseSensitiveTestDir; then |
| 4743 | mkdir CaseSensitiveTestDir |
| 4744 | fi |
| 4745 | |
| 4746 | if test -d casesensitivetestdir |
| 4747 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4748 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4749 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4750 | BUILDEXEEXT=.exe |
| 4751 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4752 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4753 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4754 | BUILDEXEEXT=$EXEEXT |
| 4755 | fi |
| 4756 | rmdir CaseSensitiveTestDir |
| 4757 | |
| 4758 | case $MACHDEP in |
| 4759 | bsdos*) |
| 4760 | case $CC in |
| 4761 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 4762 | esac;; |
| 4763 | esac |
| 4764 | |
| 4765 | case $ac_sys_system in |
| 4766 | hp*|HP*) |
| 4767 | case $CC in |
| 4768 | cc|*/cc) CC="$CC -Ae";; |
| 4769 | esac;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4770 | esac |
| 4771 | |
| 4772 | |
| 4773 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4774 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 4775 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4776 | if test -z "$LIBRARY" |
| 4777 | then |
Barry Warsaw | f040d7d | 2010-10-18 17:09:07 +0000 | [diff] [blame] | 4778 | LIBRARY='libpython$(VERSION)$(ABIFLAGS).a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4779 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 4781 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4782 | |
| 4783 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 4784 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 4785 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 4786 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 4787 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 4788 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 4789 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 4790 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 4791 | # |
| 4792 | # RUNSHARED is used to run shared python without installed libraries |
| 4793 | # |
| 4794 | # INSTSONAME is the name of the shared library that will be use to install |
| 4795 | # on the system - some systems like version suffix, others don't |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4796 | # |
| 4797 | # LDVERSION is the shared library version number, normally the Python version |
| 4798 | # with the ABI build flags appended. |
| 4799 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4800 | |
| 4801 | |
| 4802 | |
| 4803 | |
| 4804 | |
| 4805 | |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 4806 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4807 | LDLIBRARY="$LIBRARY" |
| 4808 | BLDLIBRARY='$(LDLIBRARY)' |
| 4809 | INSTSONAME='$(LDLIBRARY)' |
| 4810 | DLLLIBRARY='' |
| 4811 | LDLIBRARYDIR='' |
| 4812 | RUNSHARED='' |
Barry Warsaw | 14d98ac | 2010-11-24 19:43:47 +0000 | [diff] [blame] | 4813 | LDVERSION="$VERSION" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4814 | |
| 4815 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 4816 | # If CXX is set, and if it is needed to link a main function that was |
| 4817 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 4818 | # python might then depend on the C++ runtime |
| 4819 | # This is altered for AIX in order to build the export list before |
| 4820 | # linking. |
| 4821 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 4823 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4824 | if test -z "$LINKCC" |
| 4825 | then |
| 4826 | LINKCC='$(PURIFY) $(MAINCC)' |
| 4827 | case $ac_sys_system in |
| 4828 | AIX*) |
| 4829 | exp_extra="\"\"" |
| 4830 | if test $ac_sys_release -ge 5 -o \ |
| 4831 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 4832 | exp_extra="." |
| 4833 | fi |
| 4834 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4835 | QNX*) |
| 4836 | # qcc must be used because the other compilers do not |
| 4837 | # support -N. |
| 4838 | LINKCC=qcc;; |
| 4839 | esac |
| 4840 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 4842 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4843 | |
| 4844 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 4845 | # make sure we default having it set to "no": this is used by |
| 4846 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 4847 | # to linker command lines, and failing to detect GNU ld simply results |
| 4848 | # in the same bahaviour as before. |
| 4849 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4850 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 4851 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4852 | ac_prog=ld |
| 4853 | if test "$GCC" = yes; then |
| 4854 | ac_prog=`$CC -print-prog-name=ld` |
| 4855 | fi |
| 4856 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 4857 | *GNU*) |
| 4858 | GNULD=yes;; |
| 4859 | *) |
| 4860 | GNULD=no;; |
| 4861 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 4863 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4864 | |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4865 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
| 4866 | $as_echo_n "checking for inline... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 4867 | if test "${ac_cv_c_inline+set}" = set; then : |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4868 | $as_echo_n "(cached) " >&6 |
| 4869 | else |
| 4870 | ac_cv_c_inline=no |
| 4871 | for ac_kw in inline __inline__ __inline; do |
| 4872 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4873 | /* end confdefs.h. */ |
| 4874 | #ifndef __cplusplus |
| 4875 | typedef int foo_t; |
| 4876 | static $ac_kw foo_t static_foo () {return 0; } |
| 4877 | $ac_kw foo_t foo () {return 0; } |
| 4878 | #endif |
| 4879 | |
| 4880 | _ACEOF |
| 4881 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4882 | ac_cv_c_inline=$ac_kw |
| 4883 | fi |
| 4884 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4885 | test "$ac_cv_c_inline" != no && break |
| 4886 | done |
| 4887 | |
| 4888 | fi |
| 4889 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
| 4890 | $as_echo "$ac_cv_c_inline" >&6; } |
| 4891 | |
| 4892 | case $ac_cv_c_inline in |
| 4893 | inline | yes) ;; |
| 4894 | *) |
| 4895 | case $ac_cv_c_inline in |
| 4896 | no) ac_val=;; |
| 4897 | *) ac_val=$ac_cv_c_inline;; |
| 4898 | esac |
| 4899 | cat >>confdefs.h <<_ACEOF |
| 4900 | #ifndef __cplusplus |
| 4901 | #define inline $ac_val |
| 4902 | #endif |
| 4903 | _ACEOF |
| 4904 | ;; |
| 4905 | esac |
| 4906 | |
| 4907 | if test "$ac_cv_c_inline" != no ; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4908 | |
| 4909 | $as_echo "#define USE_INLINE 1" >>confdefs.h |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4910 | |
| 4911 | |
| 4912 | fi |
| 4913 | |
| 4914 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4915 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 4916 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4917 | # Check whether --enable-shared was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4918 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4919 | enableval=$enable_shared; |
| 4920 | fi |
| 4921 | |
| 4922 | |
| 4923 | if test -z "$enable_shared" |
| 4924 | then |
| 4925 | case $ac_sys_system in |
Antoine Pitrou | 6103ab1 | 2009-10-24 20:11:21 +0000 | [diff] [blame] | 4926 | CYGWIN*) |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4927 | enable_shared="yes";; |
| 4928 | *) |
| 4929 | enable_shared="no";; |
| 4930 | esac |
| 4931 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4932 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 4933 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4934 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4935 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 4936 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4937 | # Check whether --enable-profiling was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4938 | if test "${enable_profiling+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4939 | enableval=$enable_profiling; ac_save_cc="$CC" |
| 4940 | CC="$CC -pg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4941 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4942 | ac_enable_profiling="no" |
| 4943 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4944 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4945 | /* end confdefs.h. */ |
| 4946 | int main() { return 0; } |
| 4947 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4948 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4949 | ac_enable_profiling="yes" |
| 4950 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4951 | ac_enable_profiling="no" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4952 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4953 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4954 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4955 | fi |
| 4956 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4957 | CC="$ac_save_cc" |
| 4958 | fi |
| 4959 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_profiling" >&5 |
| 4961 | $as_echo "$ac_enable_profiling" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4962 | |
| 4963 | case "$ac_enable_profiling" in |
| 4964 | "yes") |
| 4965 | BASECFLAGS="-pg $BASECFLAGS" |
| 4966 | LDFLAGS="-pg $LDFLAGS" |
| 4967 | ;; |
| 4968 | esac |
| 4969 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4970 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 4971 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4972 | |
| 4973 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 4974 | # library that we build, but we do not want to link against it (we |
| 4975 | # will find it with a -framework option). For this reason there is an |
| 4976 | # extra variable BLDLIBRARY against which Python and the extension |
| 4977 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 4978 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 4979 | if test "$enable_framework" |
| 4980 | then |
| 4981 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 4982 | RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH" |
| 4983 | BLDLIBRARY='' |
| 4984 | else |
| 4985 | BLDLIBRARY='$(LDLIBRARY)' |
| 4986 | fi |
| 4987 | |
| 4988 | # Other platforms follow |
| 4989 | if test $enable_shared = "yes"; then |
| 4990 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4991 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4992 | |
| 4993 | case $ac_sys_system in |
| 4994 | CYGWIN*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4995 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
| 4996 | DLLLIBRARY='libpython$(LDVERSION).dll' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4997 | ;; |
| 4998 | SunOS*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4999 | LDLIBRARY='libpython$(LDVERSION).so' |
| 5000 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5001 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 5002 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5003 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 5004 | then |
| 5005 | PY3LIBRARY=libpython3.so |
| 5006 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5007 | ;; |
| 5008 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5009 | LDLIBRARY='libpython$(LDVERSION).so' |
| 5010 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5011 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 5012 | case $ac_sys_system in |
| 5013 | FreeBSD*) |
| 5014 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 5015 | ;; |
| 5016 | esac |
| 5017 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5018 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 5019 | then |
| 5020 | PY3LIBRARY=libpython3.so |
| 5021 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5022 | ;; |
| 5023 | hp*|HP*) |
| 5024 | case `uname -m` in |
| 5025 | ia64) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5026 | LDLIBRARY='libpython$(LDVERSION).so' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5027 | ;; |
| 5028 | *) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5029 | LDLIBRARY='libpython$(LDVERSION).sl' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5030 | ;; |
| 5031 | esac |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5032 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5033 | RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH} |
| 5034 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5035 | Darwin*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5036 | LDLIBRARY='libpython$(LDVERSION).dylib' |
| 5037 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5038 | RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}' |
| 5039 | ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 5040 | AIX*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5041 | LDLIBRARY='libpython$(LDVERSION).so' |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 5042 | RUNSHARED=LIBPATH=`pwd`:${LIBPATH} |
| 5043 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5044 | |
| 5045 | esac |
| 5046 | else # shared is disabled |
| 5047 | case $ac_sys_system in |
| 5048 | CYGWIN*) |
| 5049 | BLDLIBRARY='$(LIBRARY)' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5050 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5051 | ;; |
| 5052 | esac |
| 5053 | fi |
| 5054 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 5056 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5057 | |
| 5058 | if test -n "$ac_tool_prefix"; then |
| 5059 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 5060 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5061 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5062 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5063 | if test "${ac_cv_prog_RANLIB+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5064 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5065 | else |
| 5066 | if test -n "$RANLIB"; then |
| 5067 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 5068 | else |
| 5069 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5070 | for as_dir in $PATH |
| 5071 | do |
| 5072 | IFS=$as_save_IFS |
| 5073 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5074 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5075 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5076 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5077 | $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] | 5078 | break 2 |
| 5079 | fi |
| 5080 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5081 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5082 | IFS=$as_save_IFS |
| 5083 | |
| 5084 | fi |
| 5085 | fi |
| 5086 | RANLIB=$ac_cv_prog_RANLIB |
| 5087 | if test -n "$RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5088 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 5089 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5090 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5092 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5093 | fi |
| 5094 | |
| 5095 | |
| 5096 | fi |
| 5097 | if test -z "$ac_cv_prog_RANLIB"; then |
| 5098 | ac_ct_RANLIB=$RANLIB |
| 5099 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 5100 | set dummy ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5101 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5102 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5103 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5104 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5105 | else |
| 5106 | if test -n "$ac_ct_RANLIB"; then |
| 5107 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5108 | else |
| 5109 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5110 | for as_dir in $PATH |
| 5111 | do |
| 5112 | IFS=$as_save_IFS |
| 5113 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5114 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5115 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5116 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5117 | $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] | 5118 | break 2 |
| 5119 | fi |
| 5120 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5121 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5122 | IFS=$as_save_IFS |
| 5123 | |
| 5124 | fi |
| 5125 | fi |
| 5126 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5127 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5128 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5129 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5130 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5131 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5132 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5133 | fi |
| 5134 | |
| 5135 | if test "x$ac_ct_RANLIB" = x; then |
| 5136 | RANLIB=":" |
| 5137 | else |
| 5138 | case $cross_compiling:$ac_tool_warned in |
| 5139 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5140 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5141 | $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] | 5142 | ac_tool_warned=yes ;; |
| 5143 | esac |
| 5144 | RANLIB=$ac_ct_RANLIB |
| 5145 | fi |
| 5146 | else |
| 5147 | RANLIB="$ac_cv_prog_RANLIB" |
| 5148 | fi |
| 5149 | |
| 5150 | |
| 5151 | for ac_prog in ar aal |
| 5152 | do |
| 5153 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5154 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5155 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5156 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5157 | if test "${ac_cv_prog_AR+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5158 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5159 | else |
| 5160 | if test -n "$AR"; then |
| 5161 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5162 | else |
| 5163 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5164 | for as_dir in $PATH |
| 5165 | do |
| 5166 | IFS=$as_save_IFS |
| 5167 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5168 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5169 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5170 | ac_cv_prog_AR="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5171 | $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] | 5172 | break 2 |
| 5173 | fi |
| 5174 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5175 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5176 | IFS=$as_save_IFS |
| 5177 | |
| 5178 | fi |
| 5179 | fi |
| 5180 | AR=$ac_cv_prog_AR |
| 5181 | if test -n "$AR"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5182 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5183 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5184 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5186 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5187 | fi |
| 5188 | |
| 5189 | |
| 5190 | test -n "$AR" && break |
| 5191 | done |
| 5192 | test -n "$AR" || AR="ar" |
| 5193 | |
| 5194 | |
| 5195 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5196 | |
| 5197 | if test -z "$ARFLAGS" |
| 5198 | then |
| 5199 | ARFLAGS="rc" |
| 5200 | fi |
| 5201 | |
| 5202 | |
Benjamin Peterson | 87cdb81 | 2011-05-31 18:26:08 -0500 | [diff] [blame] | 5203 | DISABLE_ASDLGEN="" |
| 5204 | # Extract the first word of "python", so it can be a program name with args. |
| 5205 | set dummy python; ac_word=$2 |
| 5206 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5207 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5208 | if test "${ac_cv_prog_HAS_PYTHON+set}" = set; then : |
| 5209 | $as_echo_n "(cached) " >&6 |
| 5210 | else |
| 5211 | if test -n "$HAS_PYTHON"; then |
| 5212 | ac_cv_prog_HAS_PYTHON="$HAS_PYTHON" # Let the user override the test. |
| 5213 | else |
| 5214 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5215 | for as_dir in $PATH |
| 5216 | do |
| 5217 | IFS=$as_save_IFS |
| 5218 | test -z "$as_dir" && as_dir=. |
| 5219 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5220 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5221 | ac_cv_prog_HAS_PYTHON="found" |
| 5222 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 5223 | break 2 |
| 5224 | fi |
| 5225 | done |
| 5226 | done |
| 5227 | IFS=$as_save_IFS |
| 5228 | |
| 5229 | test -z "$ac_cv_prog_HAS_PYTHON" && ac_cv_prog_HAS_PYTHON="not-found" |
| 5230 | fi |
| 5231 | fi |
| 5232 | HAS_PYTHON=$ac_cv_prog_HAS_PYTHON |
| 5233 | if test -n "$HAS_PYTHON"; then |
| 5234 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAS_PYTHON" >&5 |
| 5235 | $as_echo "$HAS_PYTHON" >&6; } |
| 5236 | else |
| 5237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5238 | $as_echo "no" >&6; } |
| 5239 | fi |
| 5240 | |
| 5241 | |
| 5242 | if test $HAS_HG != found -o $HAS_PYTHON != found |
| 5243 | then |
| 5244 | DISABLE_ASDLGEN="@echo hg: $HAS_HG, python: $HAS_PYTHON! cannot run \$(srcdir)/Parser/asdl_c.py #" |
| 5245 | fi |
| 5246 | |
| 5247 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5248 | case $MACHDEP in |
| 5249 | bsdos*|hp*|HP*) |
| 5250 | # install -d does not work on BSDI or HP-UX |
| 5251 | if test -z "$INSTALL" |
| 5252 | then |
| 5253 | INSTALL="${srcdir}/install-sh -c" |
| 5254 | fi |
| 5255 | esac |
| 5256 | ac_aux_dir= |
| 5257 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 5258 | if test -f "$ac_dir/install-sh"; then |
| 5259 | ac_aux_dir=$ac_dir |
| 5260 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 5261 | break |
| 5262 | elif test -f "$ac_dir/install.sh"; then |
| 5263 | ac_aux_dir=$ac_dir |
| 5264 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 5265 | break |
| 5266 | elif test -f "$ac_dir/shtool"; then |
| 5267 | ac_aux_dir=$ac_dir |
| 5268 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 5269 | break |
| 5270 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5271 | done |
| 5272 | if test -z "$ac_aux_dir"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 5273 | 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] | 5274 | fi |
| 5275 | |
| 5276 | # These three variables are undocumented and unsupported, |
| 5277 | # and are intended to be withdrawn in a future Autoconf release. |
| 5278 | # They can cause serious problems if a builder's source tree is in a directory |
| 5279 | # whose full name contains unusual characters. |
| 5280 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 5281 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 5282 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 5283 | |
| 5284 | |
| 5285 | # Find a good install program. We prefer a C program (faster), |
| 5286 | # so one script is as good as another. But avoid the broken or |
| 5287 | # incompatible versions: |
| 5288 | # SysV /etc/install, /usr/sbin/install |
| 5289 | # SunOS /usr/etc/install |
| 5290 | # IRIX /sbin/install |
| 5291 | # AIX /bin/install |
| 5292 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 5293 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 5294 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 5295 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 5296 | # OS/2's system install, which has a completely different semantic |
| 5297 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5298 | # Reject install programs that cannot install multiple files. |
| 5299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 5300 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5301 | if test -z "$INSTALL"; then |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5302 | if test "${ac_cv_path_install+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5303 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5304 | else |
| 5305 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5306 | for as_dir in $PATH |
| 5307 | do |
| 5308 | IFS=$as_save_IFS |
| 5309 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5310 | # Account for people who put trailing slashes in PATH elements. |
| 5311 | case $as_dir/ in #(( |
| 5312 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5313 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5314 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5315 | /usr/ucb/* ) ;; |
| 5316 | *) |
| 5317 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 5318 | # Don't use installbsd from OSF since it installs stuff as root |
| 5319 | # by default. |
| 5320 | for ac_prog in ginstall scoinst install; do |
| 5321 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5322 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
| 5323 | if test $ac_prog = install && |
| 5324 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5325 | # AIX install. It has an incompatible calling convention. |
| 5326 | : |
| 5327 | elif test $ac_prog = install && |
| 5328 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5329 | # program-specific install script used by HP pwplus--don't use. |
| 5330 | : |
| 5331 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5332 | rm -rf conftest.one conftest.two conftest.dir |
| 5333 | echo one > conftest.one |
| 5334 | echo two > conftest.two |
| 5335 | mkdir conftest.dir |
| 5336 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 5337 | test -s conftest.one && test -s conftest.two && |
| 5338 | test -s conftest.dir/conftest.one && |
| 5339 | test -s conftest.dir/conftest.two |
| 5340 | then |
| 5341 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 5342 | break 3 |
| 5343 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5344 | fi |
| 5345 | fi |
| 5346 | done |
| 5347 | done |
| 5348 | ;; |
| 5349 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5350 | |
| 5351 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5352 | IFS=$as_save_IFS |
| 5353 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5354 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5355 | |
| 5356 | fi |
| 5357 | if test "${ac_cv_path_install+set}" = set; then |
| 5358 | INSTALL=$ac_cv_path_install |
| 5359 | else |
| 5360 | # As a last resort, use the slow shell script. Don't cache a |
| 5361 | # value for INSTALL within a source directory, because that will |
| 5362 | # break other packages using the cache if that directory is |
| 5363 | # removed, or if the value is a relative name. |
| 5364 | INSTALL=$ac_install_sh |
| 5365 | fi |
| 5366 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5367 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 5368 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5369 | |
| 5370 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 5371 | # It thinks the first close brace ends the variable substitution. |
| 5372 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 5373 | |
| 5374 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 5375 | |
| 5376 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 5377 | |
| 5378 | |
| 5379 | # Not every filesystem supports hard links |
| 5380 | |
| 5381 | if test -z "$LN" ; then |
| 5382 | case $ac_sys_system in |
| 5383 | CYGWIN*) LN="ln -s";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5384 | *) LN=ln;; |
| 5385 | esac |
| 5386 | fi |
| 5387 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5388 | # For calculating the .so ABI tag. |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5389 | |
| 5390 | ABIFLAGS="" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5391 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5392 | # Check for --with-pydebug |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5393 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 5394 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5395 | |
| 5396 | # Check whether --with-pydebug was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5397 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5398 | withval=$with_pydebug; |
| 5399 | if test "$withval" != no |
| 5400 | then |
| 5401 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5402 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5403 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5404 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5405 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5406 | Py_DEBUG='true' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5407 | ABIFLAGS="${ABIFLAGS}d" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5408 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5409 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5410 | fi |
| 5411 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5413 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5414 | fi |
| 5415 | |
| 5416 | |
| 5417 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 5418 | # merged with this chunk of code? |
| 5419 | |
| 5420 | # Optimizer/debugger flags |
| 5421 | # ------------------------ |
| 5422 | # (The following bit of code is complicated enough - please keep things |
| 5423 | # indented properly. Just pretend you're editing Python code. ;-) |
| 5424 | |
| 5425 | # There are two parallel sets of case statements below, one that checks to |
| 5426 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 5427 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 5428 | # user set OPT. |
| 5429 | |
| 5430 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 5431 | # it on the command line |
| 5432 | |
Benjamin Peterson | 65b4ec5 | 2010-03-23 21:02:34 +0000 | [diff] [blame] | 5433 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5434 | then |
| 5435 | case $GCC in |
| 5436 | yes) |
| 5437 | if test "$CC" != 'g++' ; then |
| 5438 | STRICT_PROTO="-Wstrict-prototypes" |
| 5439 | fi |
| 5440 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 5441 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 5442 | WRAP="-fwrapv" |
| 5443 | fi |
| 5444 | case $ac_cv_prog_cc_g in |
| 5445 | yes) |
| 5446 | if test "$Py_DEBUG" = 'true' ; then |
| 5447 | # Optimization messes up debuggers, so turn it off for |
| 5448 | # debug builds. |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 5449 | OPT="-g -O0 -Wall $STRICT_PROTO" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5450 | else |
| 5451 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 5452 | fi |
| 5453 | ;; |
| 5454 | *) |
| 5455 | OPT="-O3 -Wall $STRICT_PROTO" |
| 5456 | ;; |
| 5457 | esac |
| 5458 | case $ac_sys_system in |
| 5459 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 5460 | ;; |
| 5461 | esac |
| 5462 | ;; |
| 5463 | |
| 5464 | *) |
| 5465 | OPT="-O" |
| 5466 | ;; |
| 5467 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5468 | fi |
| 5469 | |
| 5470 | |
| 5471 | |
| 5472 | # The -arch flags for universal builds on OSX |
| 5473 | UNIVERSAL_ARCH_FLAGS= |
| 5474 | |
| 5475 | |
| 5476 | # tweak BASECFLAGS based on compiler and platform |
| 5477 | case $GCC in |
| 5478 | yes) |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5479 | # Python doesn't violate C99 aliasing rules, but older versions of |
| 5480 | # GCC produce warnings for legal Python code. Enable |
| 5481 | # -fno-strict-aliasing on versions of GCC that support but produce |
| 5482 | # warnings. See Issue3326 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5483 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5 |
| 5484 | $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] | 5485 | ac_save_cc="$CC" |
| 5486 | CC="$CC -fno-strict-aliasing" |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5487 | save_CFLAGS="$CFLAGS" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5488 | if test "${ac_cv_no_strict_aliasing+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5489 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5490 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5491 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5492 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5493 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5494 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5495 | int |
| 5496 | main () |
| 5497 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5498 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5499 | ; |
| 5500 | return 0; |
| 5501 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5502 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5503 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5504 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5505 | |
| 5506 | CC="$ac_save_cc -fstrict-aliasing" |
| 5507 | CFLAGS="$CFLAGS -Werror -Wstrict-aliasing" |
| 5508 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5509 | /* end confdefs.h. */ |
| 5510 | |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5511 | void f(int **x) {} |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5512 | int |
| 5513 | main () |
| 5514 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5515 | double *x; f((int **) &x); |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5516 | ; |
| 5517 | return 0; |
| 5518 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5519 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5520 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5521 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5522 | |
| 5523 | ac_cv_no_strict_aliasing=no |
| 5524 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5525 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5526 | |
| 5527 | ac_cv_no_strict_aliasing=yes |
| 5528 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5529 | fi |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5530 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5531 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5532 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5533 | |
| 5534 | ac_cv_no_strict_aliasing=no |
| 5535 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5536 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5537 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5538 | fi |
| 5539 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5540 | CFLAGS="$save_CFLAGS" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5541 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5542 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5 |
| 5543 | $as_echo "$ac_cv_no_strict_aliasing" >&6; } |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5544 | if test $ac_cv_no_strict_aliasing = yes |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5545 | then |
| 5546 | BASECFLAGS="$BASECFLAGS -fno-strict-aliasing" |
| 5547 | fi |
| 5548 | |
| 5549 | # if using gcc on alpha, use -mieee to get (near) full IEEE 754 |
| 5550 | # support. Without this, treatment of subnormals doesn't follow |
| 5551 | # the standard. |
| 5552 | case $ac_sys_machine in |
| 5553 | alpha*) |
| 5554 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5555 | ;; |
| 5556 | esac |
| 5557 | |
| 5558 | case $ac_sys_system in |
| 5559 | SCO_SV*) |
| 5560 | BASECFLAGS="$BASECFLAGS -m486 -DSCO5" |
| 5561 | ;; |
| 5562 | # is there any other compiler on Darwin besides gcc? |
| 5563 | Darwin*) |
| 5564 | # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd |
| 5565 | # used to be here, but non-Apple gcc doesn't accept them. |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5566 | if test "${CC}" = gcc |
| 5567 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5568 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5 |
| 5569 | $as_echo_n "checking which compiler should be used... " >&6; } |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5570 | case "${UNIVERSALSDK}" in |
| 5571 | */MacOSX10.4u.sdk) |
| 5572 | # Build using 10.4 SDK, force usage of gcc when the |
| 5573 | # compiler is gcc, otherwise the user will get very |
| 5574 | # confusing error messages when building on OSX 10.6 |
| 5575 | CC=gcc-4.0 |
| 5576 | CPP=cpp-4.0 |
| 5577 | ;; |
| 5578 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 5580 | $as_echo "$CC" >&6; } |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5581 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5582 | |
| 5583 | |
| 5584 | if test "${enable_universalsdk}"; then |
| 5585 | UNIVERSAL_ARCH_FLAGS="" |
| 5586 | if test "$UNIVERSAL_ARCHS" = "32-bit" ; then |
| 5587 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 5588 | ARCH_RUN_32BIT="" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 5589 | LIPO_32BIT_FLAGS="" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5590 | elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then |
| 5591 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5592 | LIPO_32BIT_FLAGS="" |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5593 | ARCH_RUN_32BIT="true" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5594 | |
| 5595 | elif test "$UNIVERSAL_ARCHS" = "all" ; then |
| 5596 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5597 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5598 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5599 | |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5600 | elif test "$UNIVERSAL_ARCHS" = "intel" ; then |
| 5601 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5602 | LIPO_32BIT_FLAGS="-extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5603 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5604 | |
| 5605 | elif test "$UNIVERSAL_ARCHS" = "3-way" ; then |
| 5606 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5607 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5608 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5609 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5610 | else |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 5611 | 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] | 5612 | |
| 5613 | fi |
| 5614 | |
| 5615 | |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5616 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5617 | if test "${UNIVERSALSDK}" != "/" |
| 5618 | then |
| 5619 | CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5620 | LDFLAGS="-isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Ronald Oussoren | 712979d | 2010-04-20 19:51:33 +0000 | [diff] [blame] | 5621 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5622 | fi |
| 5623 | fi |
| 5624 | |
| 5625 | # Calculate the right deployment target for this build. |
| 5626 | # |
| 5627 | cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'` |
| 5628 | if test ${cur_target} '>' 10.2; then |
| 5629 | cur_target=10.3 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5630 | if test ${enable_universalsdk}; then |
| 5631 | if test "${UNIVERSAL_ARCHS}" = "all"; then |
| 5632 | # Ensure that the default platform for a |
| 5633 | # 4-way universal build is OSX 10.5, |
| 5634 | # that's the first OS release where |
| 5635 | # 4-way builds make sense. |
| 5636 | cur_target='10.5' |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5637 | |
| 5638 | elif test "${UNIVERSAL_ARCHS}" = "3-way"; then |
| 5639 | cur_target='10.5' |
| 5640 | |
| 5641 | elif test "${UNIVERSAL_ARCHS}" = "intel"; then |
| 5642 | cur_target='10.5' |
| 5643 | |
| 5644 | elif test "${UNIVERSAL_ARCHS}" = "64-bit"; then |
| 5645 | cur_target='10.5' |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5646 | fi |
| 5647 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 5648 | if test `/usr/bin/arch` = "i386"; then |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5649 | # On Intel macs default to a deployment |
| 5650 | # target of 10.4, that's the first OSX |
| 5651 | # release with Intel support. |
| 5652 | cur_target="10.4" |
| 5653 | fi |
| 5654 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5655 | fi |
| 5656 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
| 5657 | |
| 5658 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 5659 | # environment with a value that is the same as what we'll use |
| 5660 | # in the Makefile to ensure that we'll get the same compiler |
| 5661 | # environment during configure and build time. |
| 5662 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 5663 | export MACOSX_DEPLOYMENT_TARGET |
| 5664 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 5665 | |
| 5666 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5667 | esac |
| 5668 | ;; |
| 5669 | |
| 5670 | *) |
| 5671 | case $ac_sys_system in |
| 5672 | OpenUNIX*|UnixWare*) |
| 5673 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 5674 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5675 | SCO_SV*) |
| 5676 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 5677 | ;; |
| 5678 | esac |
| 5679 | ;; |
| 5680 | esac |
| 5681 | |
| 5682 | if test "$Py_DEBUG" = 'true'; then |
| 5683 | : |
| 5684 | else |
| 5685 | OPT="-DNDEBUG $OPT" |
| 5686 | fi |
| 5687 | |
| 5688 | if test "$ac_arch_flags" |
| 5689 | then |
| 5690 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 5691 | fi |
| 5692 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5693 | # Check whether GCC supports PyArg_ParseTuple format |
| 5694 | if test "$GCC" = "yes" |
| 5695 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc supports ParseTuple __format__" >&5 |
| 5697 | $as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5698 | save_CFLAGS=$CFLAGS |
| 5699 | CFLAGS="$CFLAGS -Werror" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5700 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5701 | /* end confdefs.h. */ |
| 5702 | |
| 5703 | void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2))); |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5704 | int |
| 5705 | main () |
| 5706 | { |
| 5707 | |
| 5708 | ; |
| 5709 | return 0; |
| 5710 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5711 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5712 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5713 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5714 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5715 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5716 | $as_echo "#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5717 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5718 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5719 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5720 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5721 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5722 | |
| 5723 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5724 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5725 | |
| 5726 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5727 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5728 | CFLAGS=$save_CFLAGS |
| 5729 | fi |
| 5730 | |
| 5731 | # On some compilers, pthreads are available without further options |
| 5732 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 5733 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 5734 | # So we have to see first whether pthreads are available without |
| 5735 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5736 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 5737 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5738 | if test "${ac_cv_pthread_is_default+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5739 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5740 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5741 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5742 | ac_cv_pthread_is_default=no |
| 5743 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5744 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5745 | /* end confdefs.h. */ |
| 5746 | |
| 5747 | #include <pthread.h> |
| 5748 | |
| 5749 | void* routine(void* p){return NULL;} |
| 5750 | |
| 5751 | int main(){ |
| 5752 | pthread_t p; |
| 5753 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5754 | return 1; |
| 5755 | (void)pthread_detach(p); |
| 5756 | return 0; |
| 5757 | } |
| 5758 | |
| 5759 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5760 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5761 | |
| 5762 | ac_cv_pthread_is_default=yes |
| 5763 | ac_cv_kthread=no |
| 5764 | ac_cv_pthread=no |
| 5765 | |
| 5766 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5767 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5768 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5769 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5770 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5771 | fi |
| 5772 | |
| 5773 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5774 | fi |
| 5775 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5776 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 5777 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5778 | |
| 5779 | |
| 5780 | if test $ac_cv_pthread_is_default = yes |
| 5781 | then |
| 5782 | ac_cv_kpthread=no |
| 5783 | else |
| 5784 | # -Kpthread, if available, provides the right #defines |
| 5785 | # and linker options to make pthread_create available |
| 5786 | # Some compilers won't report that they do not support -Kpthread, |
| 5787 | # so we need to run a program to see whether it really made the |
| 5788 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5789 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 5790 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5791 | if test "${ac_cv_kpthread+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5792 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5793 | else |
| 5794 | ac_save_cc="$CC" |
| 5795 | CC="$CC -Kpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5796 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5797 | ac_cv_kpthread=no |
| 5798 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5799 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5800 | /* end confdefs.h. */ |
| 5801 | |
| 5802 | #include <pthread.h> |
| 5803 | |
| 5804 | void* routine(void* p){return NULL;} |
| 5805 | |
| 5806 | int main(){ |
| 5807 | pthread_t p; |
| 5808 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5809 | return 1; |
| 5810 | (void)pthread_detach(p); |
| 5811 | return 0; |
| 5812 | } |
| 5813 | |
| 5814 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5815 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5816 | ac_cv_kpthread=yes |
| 5817 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5818 | ac_cv_kpthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5819 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5820 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5821 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5822 | fi |
| 5823 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5824 | CC="$ac_save_cc" |
| 5825 | fi |
| 5826 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5827 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 5828 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5829 | fi |
| 5830 | |
| 5831 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 5832 | then |
| 5833 | # -Kthread, if available, provides the right #defines |
| 5834 | # and linker options to make pthread_create available |
| 5835 | # Some compilers won't report that they do not support -Kthread, |
| 5836 | # so we need to run a program to see whether it really made the |
| 5837 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5838 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 5839 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5840 | if test "${ac_cv_kthread+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5841 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5842 | else |
| 5843 | ac_save_cc="$CC" |
| 5844 | CC="$CC -Kthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5845 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5846 | ac_cv_kthread=no |
| 5847 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5848 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5849 | /* end confdefs.h. */ |
| 5850 | |
| 5851 | #include <pthread.h> |
| 5852 | |
| 5853 | void* routine(void* p){return NULL;} |
| 5854 | |
| 5855 | int main(){ |
| 5856 | pthread_t p; |
| 5857 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5858 | return 1; |
| 5859 | (void)pthread_detach(p); |
| 5860 | return 0; |
| 5861 | } |
| 5862 | |
| 5863 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5864 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5865 | ac_cv_kthread=yes |
| 5866 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5867 | ac_cv_kthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5868 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5869 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5870 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5871 | fi |
| 5872 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5873 | CC="$ac_save_cc" |
| 5874 | fi |
| 5875 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5876 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 5877 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5878 | fi |
| 5879 | |
| 5880 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 5881 | then |
| 5882 | # -pthread, if available, provides the right #defines |
| 5883 | # and linker options to make pthread_create available |
| 5884 | # Some compilers won't report that they do not support -pthread, |
| 5885 | # so we need to run a program to see whether it really made the |
| 5886 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5887 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 5888 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5889 | if test "${ac_cv_thread+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5890 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5891 | else |
| 5892 | ac_save_cc="$CC" |
| 5893 | CC="$CC -pthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5894 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5895 | ac_cv_pthread=no |
| 5896 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5897 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5898 | /* end confdefs.h. */ |
| 5899 | |
| 5900 | #include <pthread.h> |
| 5901 | |
| 5902 | void* routine(void* p){return NULL;} |
| 5903 | |
| 5904 | int main(){ |
| 5905 | pthread_t p; |
| 5906 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5907 | return 1; |
| 5908 | (void)pthread_detach(p); |
| 5909 | return 0; |
| 5910 | } |
| 5911 | |
| 5912 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5913 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5914 | ac_cv_pthread=yes |
| 5915 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5916 | ac_cv_pthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5917 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5918 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5919 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5920 | fi |
| 5921 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5922 | CC="$ac_save_cc" |
| 5923 | fi |
| 5924 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5925 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 5926 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5927 | fi |
| 5928 | |
| 5929 | # If we have set a CC compiler flag for thread support then |
| 5930 | # check if it works for CXX, too. |
| 5931 | ac_cv_cxx_thread=no |
| 5932 | if test ! -z "$CXX" |
| 5933 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 5935 | $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] | 5936 | ac_save_cxx="$CXX" |
| 5937 | |
| 5938 | if test "$ac_cv_kpthread" = "yes" |
| 5939 | then |
| 5940 | CXX="$CXX -Kpthread" |
| 5941 | ac_cv_cxx_thread=yes |
| 5942 | elif test "$ac_cv_kthread" = "yes" |
| 5943 | then |
| 5944 | CXX="$CXX -Kthread" |
| 5945 | ac_cv_cxx_thread=yes |
| 5946 | elif test "$ac_cv_pthread" = "yes" |
| 5947 | then |
| 5948 | CXX="$CXX -pthread" |
| 5949 | ac_cv_cxx_thread=yes |
| 5950 | fi |
| 5951 | |
| 5952 | if test $ac_cv_cxx_thread = yes |
| 5953 | then |
| 5954 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 5955 | $CXX -c conftest.$ac_ext 2>&5 |
| 5956 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 5957 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 5958 | then |
| 5959 | ac_cv_cxx_thread=yes |
| 5960 | else |
| 5961 | ac_cv_cxx_thread=no |
| 5962 | fi |
| 5963 | rm -fr conftest* |
| 5964 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5965 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 5966 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5967 | fi |
| 5968 | CXX="$ac_save_cxx" |
| 5969 | |
| 5970 | |
| 5971 | # checks for header files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5972 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5973 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 5974 | if test "${ac_cv_header_stdc+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5975 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5976 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5977 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5978 | /* end confdefs.h. */ |
| 5979 | #include <stdlib.h> |
| 5980 | #include <stdarg.h> |
| 5981 | #include <string.h> |
| 5982 | #include <float.h> |
| 5983 | |
| 5984 | int |
| 5985 | main () |
| 5986 | { |
| 5987 | |
| 5988 | ; |
| 5989 | return 0; |
| 5990 | } |
| 5991 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5992 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5993 | ac_cv_header_stdc=yes |
| 5994 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5995 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5996 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5997 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5998 | |
| 5999 | if test $ac_cv_header_stdc = yes; then |
| 6000 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6001 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6002 | /* end confdefs.h. */ |
| 6003 | #include <string.h> |
| 6004 | |
| 6005 | _ACEOF |
| 6006 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6007 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 6008 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6009 | else |
| 6010 | ac_cv_header_stdc=no |
| 6011 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6012 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6013 | |
| 6014 | fi |
| 6015 | |
| 6016 | if test $ac_cv_header_stdc = yes; then |
| 6017 | # 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] | 6018 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6019 | /* end confdefs.h. */ |
| 6020 | #include <stdlib.h> |
| 6021 | |
| 6022 | _ACEOF |
| 6023 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6024 | $EGREP "free" >/dev/null 2>&1; then : |
| 6025 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6026 | else |
| 6027 | ac_cv_header_stdc=no |
| 6028 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6029 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6030 | |
| 6031 | fi |
| 6032 | |
| 6033 | if test $ac_cv_header_stdc = yes; then |
| 6034 | # /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] | 6035 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6036 | : |
| 6037 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6038 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6039 | /* end confdefs.h. */ |
| 6040 | #include <ctype.h> |
| 6041 | #include <stdlib.h> |
| 6042 | #if ((' ' & 0x0FF) == 0x020) |
| 6043 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 6044 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 6045 | #else |
| 6046 | # define ISLOWER(c) \ |
| 6047 | (('a' <= (c) && (c) <= 'i') \ |
| 6048 | || ('j' <= (c) && (c) <= 'r') \ |
| 6049 | || ('s' <= (c) && (c) <= 'z')) |
| 6050 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 6051 | #endif |
| 6052 | |
| 6053 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 6054 | int |
| 6055 | main () |
| 6056 | { |
| 6057 | int i; |
| 6058 | for (i = 0; i < 256; i++) |
| 6059 | if (XOR (islower (i), ISLOWER (i)) |
| 6060 | || toupper (i) != TOUPPER (i)) |
| 6061 | return 2; |
| 6062 | return 0; |
| 6063 | } |
| 6064 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6065 | if ac_fn_c_try_run "$LINENO"; then : |
| 6066 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6067 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6068 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6069 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6070 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6071 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6072 | fi |
| 6073 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6074 | fi |
| 6075 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 6077 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6078 | if test $ac_cv_header_stdc = yes; then |
| 6079 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6080 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6081 | |
| 6082 | fi |
| 6083 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6084 | for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ |
| 6085 | fcntl.h grp.h \ |
Christian Heimes | bbe741d | 2008-03-28 10:53:29 +0000 | [diff] [blame] | 6086 | 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] | 6087 | 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] | 6088 | unistd.h utime.h \ |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 6089 | sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \ |
| 6090 | sys/lock.h sys/mkdev.h sys/modem.h \ |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 6091 | sys/param.h sys/poll.h sys/select.h sys/sendfile.h sys/socket.h sys/statvfs.h \ |
| 6092 | sys/stat.h sys/termio.h sys/time.h \ |
| 6093 | sys/times.h sys/types.h sys/uio.h sys/un.h sys/utsname.h sys/wait.h pty.h \ |
Gregory P. Smith | 3b1f2c3 | 2011-05-15 12:18:23 -0700 | [diff] [blame] | 6094 | libutil.h sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Ronald Oussoren | 755740f | 2010-02-07 19:56:39 +0000 | [diff] [blame] | 6095 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6096 | do : |
| 6097 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6098 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6099 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6100 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6101 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6102 | _ACEOF |
| 6103 | |
| 6104 | fi |
| 6105 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6106 | done |
| 6107 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6108 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6109 | 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] | 6110 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 6111 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 6112 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6113 | if eval "test \"\${$as_ac_Header+set}\"" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6114 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6115 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6116 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6117 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6118 | #include <sys/types.h> |
| 6119 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6120 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6121 | int |
| 6122 | main () |
| 6123 | { |
| 6124 | if ((DIR *) 0) |
| 6125 | return 0; |
| 6126 | ; |
| 6127 | return 0; |
| 6128 | } |
| 6129 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6130 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6131 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6132 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6133 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6134 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6135 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6136 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6137 | eval ac_res=\$$as_ac_Header |
| 6138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 6139 | $as_echo "$ac_res" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6140 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6141 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6142 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6143 | _ACEOF |
| 6144 | |
| 6145 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6146 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6147 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6148 | done |
| 6149 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 6150 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6151 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6152 | $as_echo_n "checking for library containing opendir... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6153 | if test "${ac_cv_search_opendir+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6154 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6155 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6156 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6157 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6158 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6159 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6160 | /* Override any GCC internal prototype to avoid an error. |
| 6161 | Use char because int might match the return type of a GCC |
| 6162 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6163 | #ifdef __cplusplus |
| 6164 | extern "C" |
| 6165 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6166 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6167 | int |
| 6168 | main () |
| 6169 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6170 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6171 | ; |
| 6172 | return 0; |
| 6173 | } |
| 6174 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6175 | for ac_lib in '' dir; do |
| 6176 | if test -z "$ac_lib"; then |
| 6177 | ac_res="none required" |
| 6178 | else |
| 6179 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6180 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6181 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6182 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6183 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6184 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6185 | rm -f core conftest.err conftest.$ac_objext \ |
| 6186 | conftest$ac_exeext |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6187 | if test "${ac_cv_search_opendir+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6188 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6189 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6190 | done |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6191 | if test "${ac_cv_search_opendir+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6192 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6193 | else |
| 6194 | ac_cv_search_opendir=no |
| 6195 | fi |
| 6196 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6197 | LIBS=$ac_func_search_save_LIBS |
| 6198 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6199 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6200 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6201 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6202 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6203 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6204 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6205 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6206 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6207 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6209 | $as_echo_n "checking for library containing opendir... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6210 | if test "${ac_cv_search_opendir+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6211 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6212 | else |
| 6213 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6214 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6215 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6216 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6217 | /* Override any GCC internal prototype to avoid an error. |
| 6218 | Use char because int might match the return type of a GCC |
| 6219 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6220 | #ifdef __cplusplus |
| 6221 | extern "C" |
| 6222 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6223 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6224 | int |
| 6225 | main () |
| 6226 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6227 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6228 | ; |
| 6229 | return 0; |
| 6230 | } |
| 6231 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6232 | for ac_lib in '' x; do |
| 6233 | if test -z "$ac_lib"; then |
| 6234 | ac_res="none required" |
| 6235 | else |
| 6236 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6237 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6238 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6239 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6240 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6241 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6242 | rm -f core conftest.err conftest.$ac_objext \ |
| 6243 | conftest$ac_exeext |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6244 | if test "${ac_cv_search_opendir+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6245 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6246 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6247 | done |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6248 | if test "${ac_cv_search_opendir+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6249 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6250 | else |
| 6251 | ac_cv_search_opendir=no |
| 6252 | fi |
| 6253 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6254 | LIBS=$ac_func_search_save_LIBS |
| 6255 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6257 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6258 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6259 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6260 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6261 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6262 | fi |
| 6263 | |
| 6264 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6265 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6266 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 6267 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6268 | if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6269 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6270 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6271 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6272 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6273 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6274 | int |
| 6275 | main () |
| 6276 | { |
| 6277 | return makedev(0, 0); |
| 6278 | ; |
| 6279 | return 0; |
| 6280 | } |
| 6281 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6282 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6283 | ac_cv_header_sys_types_h_makedev=yes |
| 6284 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6285 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6286 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6287 | rm -f core conftest.err conftest.$ac_objext \ |
| 6288 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6289 | |
| 6290 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6291 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 6292 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6293 | |
| 6294 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6295 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6296 | if test "x$ac_cv_header_sys_mkdev_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6297 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6298 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6299 | |
| 6300 | fi |
| 6301 | |
| 6302 | |
| 6303 | |
| 6304 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6305 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6306 | if test "x$ac_cv_header_sys_sysmacros_h" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6307 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6308 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6309 | |
| 6310 | fi |
| 6311 | |
| 6312 | |
| 6313 | fi |
| 6314 | fi |
| 6315 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6316 | |
Gregory P. Smith | 3b1f2c3 | 2011-05-15 12:18:23 -0700 | [diff] [blame] | 6317 | # On Darwin (OS X) net/if.h requires sys/socket.h to be imported first. |
| 6318 | for ac_header in net/if.h |
| 6319 | do : |
| 6320 | ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#include <stdio.h> |
| 6321 | #ifdef STDC_HEADERS |
| 6322 | # include <stdlib.h> |
| 6323 | # include <stddef.h> |
| 6324 | #else |
| 6325 | # ifdef HAVE_STDLIB_H |
| 6326 | # include <stdlib.h> |
| 6327 | # endif |
| 6328 | #endif |
| 6329 | #ifdef HAVE_SYS_SOCKET_H |
| 6330 | # include <sys/socket.h> |
| 6331 | #endif |
| 6332 | |
| 6333 | " |
| 6334 | if test "x$ac_cv_header_net_if_h" = x""yes; then : |
| 6335 | cat >>confdefs.h <<_ACEOF |
| 6336 | #define HAVE_NET_IF_H 1 |
| 6337 | _ACEOF |
| 6338 | |
| 6339 | fi |
| 6340 | |
| 6341 | done |
| 6342 | |
| 6343 | |
| 6344 | |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6345 | # On Solaris, term.h requires curses.h |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6346 | for ac_header in term.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6347 | do : |
| 6348 | 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] | 6349 | #ifdef HAVE_CURSES_H |
| 6350 | #include <curses.h> |
| 6351 | #endif |
| 6352 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6353 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6354 | 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] | 6355 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6356 | #define HAVE_TERM_H 1 |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6357 | _ACEOF |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6358 | |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6359 | fi |
| 6360 | |
| 6361 | done |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6362 | |
| 6363 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6364 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6365 | for ac_header in linux/netlink.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6366 | do : |
| 6367 | 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] | 6368 | #ifdef HAVE_ASM_TYPES_H |
| 6369 | #include <asm/types.h> |
| 6370 | #endif |
| 6371 | #ifdef HAVE_SYS_SOCKET_H |
| 6372 | #include <sys/socket.h> |
| 6373 | #endif |
| 6374 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6375 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6376 | 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] | 6377 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6378 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6379 | _ACEOF |
| 6380 | |
| 6381 | fi |
| 6382 | |
| 6383 | done |
| 6384 | |
| 6385 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6386 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6387 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6388 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 6389 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 6390 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6391 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6392 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6393 | |
| 6394 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6395 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6396 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6397 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6398 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6399 | |
| 6400 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6401 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6402 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6403 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6404 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6405 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6406 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6407 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 6408 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6409 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6410 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 6411 | $as_echo_n "checking for makedev... " >&6; } |
| 6412 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6413 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6414 | |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6415 | #if defined(MAJOR_IN_MKDEV) |
| 6416 | #include <sys/mkdev.h> |
| 6417 | #elif defined(MAJOR_IN_SYSMACROS) |
| 6418 | #include <sys/sysmacros.h> |
| 6419 | #else |
| 6420 | #include <sys/types.h> |
| 6421 | #endif |
| 6422 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6423 | int |
| 6424 | main () |
| 6425 | { |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6426 | |
| 6427 | makedev(0, 0) |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6428 | ; |
| 6429 | return 0; |
| 6430 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6431 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6432 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6433 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6434 | ac_cv_has_makedev=yes |
| 6435 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6436 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6437 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6438 | rm -f core conftest.err conftest.$ac_objext \ |
| 6439 | conftest$ac_exeext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6440 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 6441 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6442 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6443 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6444 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6445 | |
| 6446 | fi |
| 6447 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6448 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 6449 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 6450 | # defined, but the compiler does not support pragma redefine_extname, |
| 6451 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 6452 | # structures (such as rlimit64) without declaring them. As a |
| 6453 | # work-around, disable LFS on such configurations |
| 6454 | |
| 6455 | use_lfs=yes |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6456 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 6457 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 6458 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6459 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6460 | |
| 6461 | #define _LARGEFILE_SOURCE 1 |
| 6462 | #define _FILE_OFFSET_BITS 64 |
| 6463 | #include <sys/resource.h> |
| 6464 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6465 | int |
| 6466 | main () |
| 6467 | { |
| 6468 | struct rlimit foo; |
| 6469 | ; |
| 6470 | return 0; |
| 6471 | } |
| 6472 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6473 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6474 | sol_lfs_bug=no |
| 6475 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6476 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6477 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6478 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6479 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 6480 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6481 | if test "$sol_lfs_bug" = "yes"; then |
| 6482 | use_lfs=no |
| 6483 | fi |
| 6484 | |
| 6485 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6486 | # Two defines needed to enable largefile support on various platforms |
| 6487 | # These may affect some typedefs |
Georg Brandl | 216e404 | 2011-02-19 08:58:23 +0000 | [diff] [blame] | 6488 | case $ac_sys_system/$ac_sys_release in |
| 6489 | AIX*) |
| 6490 | |
| 6491 | $as_echo "#define _LARGE_FILES 1" >>confdefs.h |
| 6492 | |
| 6493 | ;; |
| 6494 | esac |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6495 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6496 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6497 | |
| 6498 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6499 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6500 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6501 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6502 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 6503 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 6504 | cat >> confdefs.h <<\EOF |
| 6505 | #if defined(SCO_DS) |
| 6506 | #undef _OFF_T |
| 6507 | #endif |
| 6508 | EOF |
| 6509 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6510 | # Type availability checks |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6511 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6512 | if test "x$ac_cv_type_mode_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6513 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6514 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6515 | |
| 6516 | cat >>confdefs.h <<_ACEOF |
| 6517 | #define mode_t int |
| 6518 | _ACEOF |
| 6519 | |
| 6520 | fi |
| 6521 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6522 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6523 | if test "x$ac_cv_type_off_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6524 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6525 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6526 | |
| 6527 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6528 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6529 | _ACEOF |
| 6530 | |
| 6531 | fi |
| 6532 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6533 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6534 | if test "x$ac_cv_type_pid_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6535 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6536 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6537 | |
| 6538 | cat >>confdefs.h <<_ACEOF |
| 6539 | #define pid_t int |
| 6540 | _ACEOF |
| 6541 | |
| 6542 | fi |
| 6543 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6544 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6545 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | bada4c3 | 2010-04-25 21:18:48 +0000 | [diff] [blame] | 6546 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6547 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6548 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6549 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6550 | if test "x$ac_cv_type_size_t" = x""yes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6551 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6552 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6553 | |
| 6554 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6555 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6556 | _ACEOF |
| 6557 | |
| 6558 | fi |
| 6559 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6560 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 6561 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6562 | if test "${ac_cv_type_uid_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6563 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6564 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6565 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6566 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6567 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6568 | |
| 6569 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6570 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6571 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6572 | ac_cv_type_uid_t=yes |
| 6573 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6574 | ac_cv_type_uid_t=no |
| 6575 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6576 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6577 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6578 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 6580 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6581 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6582 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6583 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6584 | |
| 6585 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6586 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6587 | |
| 6588 | fi |
| 6589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6590 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 6591 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6592 | no|yes) ;; #( |
| 6593 | *) |
| 6594 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6595 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6596 | |
| 6597 | |
| 6598 | cat >>confdefs.h <<_ACEOF |
| 6599 | #define uint32_t $ac_cv_c_uint32_t |
| 6600 | _ACEOF |
| 6601 | ;; |
| 6602 | esac |
| 6603 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6604 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 6605 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6606 | no|yes) ;; #( |
| 6607 | *) |
| 6608 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6609 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6610 | |
| 6611 | |
| 6612 | cat >>confdefs.h <<_ACEOF |
| 6613 | #define uint64_t $ac_cv_c_uint64_t |
| 6614 | _ACEOF |
| 6615 | ;; |
| 6616 | esac |
| 6617 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6618 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 6619 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6620 | no|yes) ;; #( |
| 6621 | *) |
| 6622 | |
| 6623 | cat >>confdefs.h <<_ACEOF |
| 6624 | #define int32_t $ac_cv_c_int32_t |
| 6625 | _ACEOF |
| 6626 | ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6627 | esac |
| 6628 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6629 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 6630 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6631 | no|yes) ;; #( |
| 6632 | *) |
| 6633 | |
| 6634 | cat >>confdefs.h <<_ACEOF |
| 6635 | #define int64_t $ac_cv_c_int64_t |
| 6636 | _ACEOF |
| 6637 | ;; |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 6638 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6639 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6640 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6641 | if test "x$ac_cv_type_ssize_t" = x""yes; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6642 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6643 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6644 | |
| 6645 | fi |
| 6646 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 6647 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6648 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 6649 | # ANSI C requires sizeof(char) == 1, so no need to check it |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6650 | # The cast to long int works around a bug in the HP C Compiler |
| 6651 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6652 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6653 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 6655 | $as_echo_n "checking size of int... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6656 | if test "${ac_cv_sizeof_int+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6657 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6658 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6659 | 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] | 6660 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6661 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6662 | if test "$ac_cv_type_int" = yes; then |
| 6663 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6664 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6665 | as_fn_error 77 "cannot compute sizeof (int) |
| 6666 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6667 | else |
| 6668 | ac_cv_sizeof_int=0 |
| 6669 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6670 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6671 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6672 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6673 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 6674 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6675 | |
| 6676 | |
| 6677 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6678 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6679 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6680 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6681 | |
| 6682 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6683 | # The cast to long int works around a bug in the HP C Compiler |
| 6684 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6685 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6686 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6687 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 6688 | $as_echo_n "checking size of long... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6689 | if test "${ac_cv_sizeof_long+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6690 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6691 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6692 | 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] | 6693 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6694 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6695 | if test "$ac_cv_type_long" = yes; then |
| 6696 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6697 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6698 | as_fn_error 77 "cannot compute sizeof (long) |
| 6699 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6700 | else |
| 6701 | ac_cv_sizeof_long=0 |
| 6702 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6703 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6704 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6705 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6706 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 6707 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6708 | |
| 6709 | |
| 6710 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6711 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6712 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6713 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6714 | |
| 6715 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6716 | # The cast to long int works around a bug in the HP C Compiler |
| 6717 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6718 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6719 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6720 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 6721 | $as_echo_n "checking size of void *... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6722 | if test "${ac_cv_sizeof_void_p+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6723 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6724 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6725 | 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] | 6726 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6727 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6728 | if test "$ac_cv_type_void_p" = yes; then |
| 6729 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6730 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6731 | as_fn_error 77 "cannot compute sizeof (void *) |
| 6732 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6733 | else |
| 6734 | ac_cv_sizeof_void_p=0 |
| 6735 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6736 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6737 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6738 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6739 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 6740 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6741 | |
| 6742 | |
| 6743 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6744 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6745 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6746 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6747 | |
| 6748 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6749 | # The cast to long int works around a bug in the HP C Compiler |
| 6750 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6751 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6752 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 6754 | $as_echo_n "checking size of short... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6755 | if test "${ac_cv_sizeof_short+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6756 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6757 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6758 | 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] | 6759 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6760 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6761 | if test "$ac_cv_type_short" = yes; then |
| 6762 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6763 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6764 | as_fn_error 77 "cannot compute sizeof (short) |
| 6765 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6766 | else |
| 6767 | ac_cv_sizeof_short=0 |
| 6768 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6769 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6770 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6771 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6772 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 6773 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6774 | |
| 6775 | |
| 6776 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6777 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6778 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6779 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6780 | |
| 6781 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6782 | # The cast to long int works around a bug in the HP C Compiler |
| 6783 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6784 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6785 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6786 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 6787 | $as_echo_n "checking size of float... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6788 | if test "${ac_cv_sizeof_float+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6789 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6790 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6791 | 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] | 6792 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6793 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6794 | if test "$ac_cv_type_float" = yes; then |
| 6795 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6796 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6797 | as_fn_error 77 "cannot compute sizeof (float) |
| 6798 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6799 | else |
| 6800 | ac_cv_sizeof_float=0 |
| 6801 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6802 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6803 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6804 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6805 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 6806 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6807 | |
| 6808 | |
| 6809 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6810 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6811 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6812 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6813 | |
| 6814 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6815 | # The cast to long int works around a bug in the HP C Compiler |
| 6816 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6817 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6818 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6819 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 6820 | $as_echo_n "checking size of double... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6821 | if test "${ac_cv_sizeof_double+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6822 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6823 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6824 | 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] | 6825 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6826 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6827 | if test "$ac_cv_type_double" = yes; then |
| 6828 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6829 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6830 | as_fn_error 77 "cannot compute sizeof (double) |
| 6831 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6832 | else |
| 6833 | ac_cv_sizeof_double=0 |
| 6834 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6835 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6836 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6837 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 6839 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6840 | |
| 6841 | |
| 6842 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6843 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6844 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6845 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6846 | |
| 6847 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6848 | # The cast to long int works around a bug in the HP C Compiler |
| 6849 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6850 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6851 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6852 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 6853 | $as_echo_n "checking size of fpos_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6854 | if test "${ac_cv_sizeof_fpos_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6855 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6856 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6857 | 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] | 6858 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6859 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6860 | if test "$ac_cv_type_fpos_t" = yes; then |
| 6861 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6862 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6863 | as_fn_error 77 "cannot compute sizeof (fpos_t) |
| 6864 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6865 | else |
| 6866 | ac_cv_sizeof_fpos_t=0 |
| 6867 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6868 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6869 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6870 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6871 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 6872 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6873 | |
| 6874 | |
| 6875 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6876 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6877 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6878 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6879 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6880 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6881 | # The cast to long int works around a bug in the HP C Compiler |
| 6882 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6883 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6884 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6885 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 6886 | $as_echo_n "checking size of size_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6887 | if test "${ac_cv_sizeof_size_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6888 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6889 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6890 | 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] | 6891 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6892 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6893 | if test "$ac_cv_type_size_t" = yes; then |
| 6894 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6895 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6896 | as_fn_error 77 "cannot compute sizeof (size_t) |
| 6897 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6898 | else |
| 6899 | ac_cv_sizeof_size_t=0 |
| 6900 | fi |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6901 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6902 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6903 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6904 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 |
| 6905 | $as_echo "$ac_cv_sizeof_size_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6906 | |
| 6907 | |
| 6908 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6909 | cat >>confdefs.h <<_ACEOF |
| 6910 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t |
| 6911 | _ACEOF |
| 6912 | |
| 6913 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6914 | # The cast to long int works around a bug in the HP C Compiler |
| 6915 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6916 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6917 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6918 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5 |
| 6919 | $as_echo_n "checking size of pid_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6920 | if test "${ac_cv_sizeof_pid_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6921 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6922 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6923 | 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] | 6924 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6925 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6926 | if test "$ac_cv_type_pid_t" = yes; then |
| 6927 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6928 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6929 | as_fn_error 77 "cannot compute sizeof (pid_t) |
| 6930 | See \`config.log' for more details" "$LINENO" 5 ; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6931 | else |
| 6932 | ac_cv_sizeof_pid_t=0 |
| 6933 | fi |
| 6934 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6935 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6936 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 6938 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6939 | |
| 6940 | |
| 6941 | |
| 6942 | cat >>confdefs.h <<_ACEOF |
| 6943 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 6944 | _ACEOF |
| 6945 | |
| 6946 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6947 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6948 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 6949 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6950 | have_long_long=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6951 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6952 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6953 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6954 | int |
| 6955 | main () |
| 6956 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6957 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6958 | ; |
| 6959 | return 0; |
| 6960 | } |
| 6961 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6962 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6963 | |
| 6964 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6965 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6966 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6967 | have_long_long=yes |
| 6968 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6969 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6970 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6971 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 6972 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 6973 | if test "$have_long_long" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6974 | # The cast to long int works around a bug in the HP C Compiler |
| 6975 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6976 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6977 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6978 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 6979 | $as_echo_n "checking size of long long... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 6980 | if test "${ac_cv_sizeof_long_long+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6981 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6983 | 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] | 6984 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6985 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6986 | if test "$ac_cv_type_long_long" = yes; then |
| 6987 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6988 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 6989 | as_fn_error 77 "cannot compute sizeof (long long) |
| 6990 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6991 | else |
| 6992 | ac_cv_sizeof_long_long=0 |
| 6993 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6994 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6995 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6996 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6997 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 6998 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6999 | |
| 7000 | |
| 7001 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7002 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7003 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7004 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7005 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7006 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7007 | fi |
| 7008 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7009 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 7010 | $as_echo_n "checking for long double support... " >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7011 | have_long_double=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7013 | /* end confdefs.h. */ |
| 7014 | |
| 7015 | int |
| 7016 | main () |
| 7017 | { |
| 7018 | long double x; x = (long double)0; |
| 7019 | ; |
| 7020 | return 0; |
| 7021 | } |
| 7022 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7023 | if ac_fn_c_try_compile "$LINENO"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7024 | |
| 7025 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7026 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7027 | |
| 7028 | have_long_double=yes |
| 7029 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7030 | fi |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7031 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7032 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 7033 | $as_echo "$have_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7034 | if test "$have_long_double" = yes ; then |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7035 | # The cast to long int works around a bug in the HP C Compiler |
| 7036 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7037 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7038 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7039 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 7040 | $as_echo_n "checking size of long double... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7041 | if test "${ac_cv_sizeof_long_double+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7042 | $as_echo_n "(cached) " >&6 |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7043 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7044 | 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] | 7045 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7046 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7047 | if test "$ac_cv_type_long_double" = yes; then |
| 7048 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7049 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7050 | as_fn_error 77 "cannot compute sizeof (long double) |
| 7051 | See \`config.log' for more details" "$LINENO" 5 ; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7052 | else |
| 7053 | ac_cv_sizeof_long_double=0 |
| 7054 | fi |
| 7055 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7056 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7057 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7058 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 7059 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7060 | |
| 7061 | |
| 7062 | |
| 7063 | cat >>confdefs.h <<_ACEOF |
| 7064 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 7065 | _ACEOF |
| 7066 | |
| 7067 | |
| 7068 | fi |
| 7069 | |
| 7070 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7071 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 7072 | $as_echo_n "checking for _Bool support... " >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7073 | have_c99_bool=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7074 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7075 | /* end confdefs.h. */ |
| 7076 | |
| 7077 | int |
| 7078 | main () |
| 7079 | { |
| 7080 | _Bool x; x = (_Bool)0; |
| 7081 | ; |
| 7082 | return 0; |
| 7083 | } |
| 7084 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7085 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7086 | |
| 7087 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7088 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7089 | |
| 7090 | have_c99_bool=yes |
| 7091 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7092 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7093 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7094 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 7095 | $as_echo "$have_c99_bool" >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7096 | if test "$have_c99_bool" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7097 | # The cast to long int works around a bug in the HP C Compiler |
| 7098 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7099 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7100 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7101 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 7102 | $as_echo_n "checking size of _Bool... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7103 | if test "${ac_cv_sizeof__Bool+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7104 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7105 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7106 | 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] | 7107 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7108 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7109 | if test "$ac_cv_type__Bool" = yes; then |
| 7110 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7111 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7112 | as_fn_error 77 "cannot compute sizeof (_Bool) |
| 7113 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7114 | else |
| 7115 | ac_cv_sizeof__Bool=0 |
| 7116 | fi |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7117 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7118 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7119 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7120 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 7121 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7122 | |
| 7123 | |
| 7124 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7125 | cat >>confdefs.h <<_ACEOF |
| 7126 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 7127 | _ACEOF |
| 7128 | |
| 7129 | |
| 7130 | fi |
| 7131 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7132 | 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] | 7133 | #include <stdint.h> |
| 7134 | #endif |
Antoine Pitrou | 1bf29b7 | 2010-10-10 08:10:16 +0000 | [diff] [blame] | 7135 | #ifdef HAVE_INTTYPES_H |
| 7136 | #include <inttypes.h> |
| 7137 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7138 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7139 | if test "x$ac_cv_type_uintptr_t" = x""yes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7140 | |
| 7141 | cat >>confdefs.h <<_ACEOF |
| 7142 | #define HAVE_UINTPTR_T 1 |
| 7143 | _ACEOF |
| 7144 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7145 | # The cast to long int works around a bug in the HP C Compiler |
| 7146 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7147 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7148 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7149 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 7150 | $as_echo_n "checking size of uintptr_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7151 | if test "${ac_cv_sizeof_uintptr_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7152 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7153 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7154 | 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] | 7155 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7156 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7157 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 7158 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7159 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7160 | as_fn_error 77 "cannot compute sizeof (uintptr_t) |
| 7161 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7162 | else |
| 7163 | ac_cv_sizeof_uintptr_t=0 |
| 7164 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7165 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7166 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7167 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7168 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 7169 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7170 | |
| 7171 | |
| 7172 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7173 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7174 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7175 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7176 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7177 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7178 | fi |
| 7179 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7180 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7181 | # The cast to long int works around a bug in the HP C Compiler |
| 7182 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7183 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7184 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 7186 | $as_echo_n "checking size of off_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7187 | if test "${ac_cv_sizeof_off_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7188 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7189 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7190 | 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] | 7191 | #ifdef HAVE_SYS_TYPES_H |
| 7192 | #include <sys/types.h> |
| 7193 | #endif |
| 7194 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7195 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7196 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7197 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7198 | if test "$ac_cv_type_off_t" = yes; then |
| 7199 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7200 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7201 | as_fn_error 77 "cannot compute sizeof (off_t) |
| 7202 | See \`config.log' for more details" "$LINENO" 5 ; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7203 | else |
| 7204 | ac_cv_sizeof_off_t=0 |
| 7205 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7206 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7207 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7208 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 7210 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7211 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7212 | |
| 7213 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7214 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7215 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7216 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7217 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7218 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7219 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7220 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 7221 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7222 | if test "$have_long_long" = yes |
| 7223 | then |
| 7224 | 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] | 7225 | "$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] | 7226 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7227 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7228 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7229 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7230 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7231 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7233 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7234 | fi |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7235 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7236 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7237 | $as_echo "no" >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7238 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7239 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7240 | # The cast to long int works around a bug in the HP C Compiler |
| 7241 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7242 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7243 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7244 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 7245 | $as_echo_n "checking size of time_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7246 | if test "${ac_cv_sizeof_time_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7247 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7248 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7249 | 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] | 7250 | #ifdef HAVE_SYS_TYPES_H |
| 7251 | #include <sys/types.h> |
| 7252 | #endif |
| 7253 | #ifdef HAVE_TIME_H |
| 7254 | #include <time.h> |
| 7255 | #endif |
| 7256 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7257 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7258 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7259 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7260 | if test "$ac_cv_type_time_t" = yes; then |
| 7261 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7262 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7263 | as_fn_error 77 "cannot compute sizeof (time_t) |
| 7264 | See \`config.log' for more details" "$LINENO" 5 ; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7265 | else |
| 7266 | ac_cv_sizeof_time_t=0 |
| 7267 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7268 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7269 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7270 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 7272 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7273 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7274 | |
| 7275 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7276 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7277 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7278 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7279 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7280 | |
| 7281 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7282 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7283 | ac_save_cc="$CC" |
| 7284 | if test "$ac_cv_kpthread" = "yes" |
| 7285 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 7286 | elif test "$ac_cv_kthread" = "yes" |
| 7287 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 7288 | elif test "$ac_cv_pthread" = "yes" |
| 7289 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7290 | fi |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7291 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 7293 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7294 | have_pthread_t=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7295 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7296 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7297 | |
| 7298 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7299 | int |
| 7300 | main () |
| 7301 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 7302 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7303 | ; |
| 7304 | return 0; |
| 7305 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7306 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7307 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7308 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7309 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7310 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7311 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 7313 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7314 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7315 | # 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] | 7316 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7317 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7318 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7319 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 7320 | $as_echo_n "checking size of pthread_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7321 | if test "${ac_cv_sizeof_pthread_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7322 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7323 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7324 | 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] | 7325 | #ifdef HAVE_PTHREAD_H |
| 7326 | #include <pthread.h> |
| 7327 | #endif |
| 7328 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7329 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7330 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7331 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7332 | if test "$ac_cv_type_pthread_t" = yes; then |
| 7333 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7334 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7335 | as_fn_error 77 "cannot compute sizeof (pthread_t) |
| 7336 | See \`config.log' for more details" "$LINENO" 5 ; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7337 | else |
| 7338 | ac_cv_sizeof_pthread_t=0 |
| 7339 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7340 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7341 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7342 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7343 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 7344 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7345 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7346 | |
| 7347 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7348 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7349 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7350 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7351 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7352 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7353 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7354 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7355 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7356 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7357 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7358 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7359 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 7360 | ;; |
| 7361 | Darwin/*) |
| 7362 | OTHER_LIBTOOL_OPT="" |
| 7363 | ;; |
| 7364 | esac |
| 7365 | |
| 7366 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7367 | ARCH_RUN_32BIT="" |
| 7368 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7369 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7370 | Darwin/[01567]\..*) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7371 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 7372 | if test "${enable_universalsdk}"; then |
| 7373 | : |
| 7374 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7375 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7376 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7377 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7378 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 7379 | Darwin/*) |
Ronald Oussoren | 9812a6c | 2010-02-07 11:53:18 +0000 | [diff] [blame] | 7380 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7381 | if test ${gcc_version} '<' 4.0 |
| 7382 | then |
| 7383 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 7384 | else |
| 7385 | LIBTOOL_CRUFT="" |
| 7386 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7387 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7388 | ac_osx_32bit=yes |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7389 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7390 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7391 | /* end confdefs.h. */ |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7392 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7393 | #include <unistd.h> |
| 7394 | int main(int argc, char*argv[]) |
| 7395 | { |
| 7396 | if (sizeof(long) == 4) { |
| 7397 | return 0; |
| 7398 | } else { |
| 7399 | return 1; |
| 7400 | } |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7401 | } |
| 7402 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7403 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7404 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7405 | ac_osx_32bit=yes |
| 7406 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7407 | ac_osx_32bit=no |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7408 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7409 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7410 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7411 | fi |
| 7412 | |
| 7413 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7414 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7415 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7416 | i386) |
| 7417 | MACOSX_DEFAULT_ARCH="i386" |
| 7418 | ;; |
| 7419 | ppc) |
| 7420 | MACOSX_DEFAULT_ARCH="ppc" |
| 7421 | ;; |
| 7422 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7423 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7424 | ;; |
| 7425 | esac |
| 7426 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7427 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7428 | i386) |
| 7429 | MACOSX_DEFAULT_ARCH="x86_64" |
| 7430 | ;; |
| 7431 | ppc) |
| 7432 | MACOSX_DEFAULT_ARCH="ppc64" |
| 7433 | ;; |
| 7434 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7435 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7436 | ;; |
| 7437 | esac |
| 7438 | |
| 7439 | #ARCH_RUN_32BIT="true" |
| 7440 | fi |
| 7441 | |
| 7442 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7443 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7444 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7445 | esac |
| 7446 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7447 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 7448 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7449 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7450 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 7451 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7452 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7453 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7454 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7455 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7457 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7458 | $as_echo "yes" >&6; } |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 7459 | if test $enable_shared = "yes" |
| 7460 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 7461 | 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] | 7462 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7463 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7465 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7466 | fi |
| 7467 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7468 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 7469 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7470 | case $ac_sys_system/$ac_sys_release in |
| 7471 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7472 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7473 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7474 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7475 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 7476 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7477 | ;; |
| 7478 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7479 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7480 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7481 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7482 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7483 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7484 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7485 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7486 | |
| 7487 | |
| 7488 | |
| 7489 | |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7490 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7491 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7492 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7493 | cat >>confdefs.h <<_ACEOF |
| 7494 | #define SHLIB_EXT "$SO" |
| 7495 | _ACEOF |
| 7496 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7497 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 7498 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7499 | # (Shared libraries in this instance are shared modules to be loaded into |
| 7500 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7501 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 7502 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7503 | if test -z "$LDSHARED" |
| 7504 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7505 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7506 | AIX*) |
Georg Brandl | 9a829be | 2011-02-15 15:44:51 +0000 | [diff] [blame] | 7507 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:\$(srcdir)/Modules/python.exp" |
Guido van Rossum | ce608b0 | 2001-09-28 15:59:38 +0000 | [diff] [blame] | 7508 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7509 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7510 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7511 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7512 | SunOS/5*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7513 | if test "$GCC" = "yes" ; then |
| 7514 | LDSHARED='$(CC) -shared' |
| 7515 | LDCXXSHARED='$(CXX) -shared' |
| 7516 | else |
| 7517 | LDSHARED='$(CC) -G' |
| 7518 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 7519 | fi ;; |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7520 | hp*|HP*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7521 | if test "$GCC" = "yes" ; then |
| 7522 | LDSHARED='$(CC) -shared' |
| 7523 | LDCXXSHARED='$(CXX) -shared' |
| 7524 | else |
| 7525 | LDSHARED='ld -b' |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7526 | fi ;; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7527 | Darwin/1.3*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7528 | LDSHARED='$(CC) -bundle' |
| 7529 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7530 | if test "$enable_framework" ; then |
| 7531 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7532 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7533 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7534 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7535 | else |
| 7536 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7537 | LDSHARED="$LDSHARED -undefined suppress" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7538 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7539 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7540 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7541 | LDSHARED='$(CC) -bundle' |
| 7542 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7543 | if test "$enable_framework" ; then |
| 7544 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7545 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7546 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7547 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7548 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 7549 | # No framework, use the Python app as bundle-loader |
| 7550 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 7551 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7552 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7553 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7554 | Darwin/*) |
| 7555 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 7556 | # This allows an extension to be used in any Python |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 7557 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7558 | if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7559 | then |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7560 | if test "${enable_universalsdk}"; then |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7561 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7562 | fi |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7563 | LDSHARED='$(CC) -bundle -undefined dynamic_lookup' |
| 7564 | LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7565 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7566 | else |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7567 | LDSHARED='$(CC) -bundle' |
| 7568 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7569 | if test "$enable_framework" ; then |
| 7570 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7571 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7572 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7573 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7574 | else |
| 7575 | # No framework, use the Python app as bundle-loader |
| 7576 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 7577 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7578 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7579 | fi |
| 7580 | fi |
| 7581 | ;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7582 | Linux*|GNU*|QNX*) |
| 7583 | LDSHARED='$(CC) -shared' |
| 7584 | LDCXXSHARED='$(CXX) -shared';; |
| 7585 | BSD/OS*/4*) |
| 7586 | LDSHARED="gcc -shared" |
| 7587 | LDCXXSHARED="g++ -shared";; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7588 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 7589 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7590 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7591 | LDSHARED='$(CC) -shared' |
| 7592 | LDCXXSHARED='$(CXX) -shared' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7593 | else |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7594 | LDSHARED="ld -Bshareable" |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7595 | fi;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7596 | OpenBSD*) |
| 7597 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7598 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7599 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7600 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7601 | else |
| 7602 | case `uname -r` in |
| 7603 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 7604 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7605 | ;; |
| 7606 | *) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7607 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7608 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7609 | ;; |
| 7610 | esac |
| 7611 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7612 | NetBSD*|DragonFly*) |
Antoine Pitrou | ece919e | 2011-01-02 20:45:21 +0000 | [diff] [blame] | 7613 | LDSHARED='$(CC) -shared' |
| 7614 | LDCXXSHARED='$(CXX) -shared';; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7615 | OpenUNIX*|UnixWare*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7616 | if test "$GCC" = "yes" ; then |
| 7617 | LDSHARED='$(CC) -shared' |
| 7618 | LDCXXSHARED='$(CXX) -shared' |
| 7619 | else |
| 7620 | LDSHARED='$(CC) -G' |
| 7621 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7622 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7623 | SCO_SV*) |
| 7624 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 7625 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 7626 | CYGWIN*) |
| 7627 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 7628 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7629 | *) LDSHARED="ld";; |
| 7630 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7631 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7632 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 7633 | $as_echo "$LDSHARED" >&6; } |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7634 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7635 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7636 | # 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] | 7637 | # library (module) -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7638 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 7639 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7640 | if test -z "$CCSHARED" |
| 7641 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7642 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7643 | SunOS*) if test "$GCC" = yes; |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7644 | then CCSHARED="-fPIC"; |
| 7645 | elif test `uname -p` = sparc; |
| 7646 | then CCSHARED="-xcode=pic32"; |
| 7647 | else CCSHARED="-Kpic"; |
| 7648 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7649 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 7650 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7651 | else CCSHARED="+z"; |
| 7652 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7653 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7654 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7655 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7656 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7657 | if test "$GCC" = "yes" |
| 7658 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 7659 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7660 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7661 | SCO_SV*) |
| 7662 | if test "$GCC" = "yes" |
| 7663 | then CCSHARED="-fPIC" |
| 7664 | else CCSHARED="-Kpic -belf" |
| 7665 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7666 | IRIX*/6*) case $CC in |
| 7667 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 7668 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7669 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7670 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7671 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 7673 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7674 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7675 | # the python executable -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7676 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 7677 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7678 | if test -z "$LINKFORSHARED" |
| 7679 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7680 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7681 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7682 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 7683 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 7684 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7685 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7686 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7687 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7688 | Darwin/*) |
Benjamin Peterson | 9c80cac | 2009-05-23 16:34:23 +0000 | [diff] [blame] | 7689 | LINKFORSHARED="$extra_undefs -framework CoreFoundation" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7690 | if test "$enable_framework" |
| 7691 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7692 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7693 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7694 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7695 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7696 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 7697 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7698 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 7699 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7700 | then |
| 7701 | LINKFORSHARED="-Wl,--export-dynamic" |
| 7702 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7703 | SunOS/5*) case $CC in |
| 7704 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 7705 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 7706 | then |
| 7707 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7708 | fi;; |
| 7709 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 7710 | CYGWIN*) |
| 7711 | if test $enable_shared = "no" |
| 7712 | then |
| 7713 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 7714 | fi;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 7715 | QNX*) |
| 7716 | # -Wl,-E causes the symbols to be added to the dynamic |
| 7717 | # symbol table so that they can be found when a module |
| 7718 | # is loaded. -N 2048K causes the stack size to be set |
| 7719 | # to 2048 kilobytes so that the stack doesn't overflow |
| 7720 | # when running test_compile.py. |
| 7721 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7722 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7723 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7724 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 7725 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7726 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7727 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 7728 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7729 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 7730 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7731 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 7732 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 7733 | case $ac_sys_system in |
| 7734 | CYGWIN*) |
| 7735 | # Cygwin needs CCSHARED when building extension DLLs |
| 7736 | # but not when building the interpreter DLL. |
| 7737 | CFLAGSFORSHARED='';; |
| 7738 | *) |
| 7739 | CFLAGSFORSHARED='$(CCSHARED)' |
| 7740 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7741 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7742 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 7743 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7744 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7745 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 7746 | # library (with --enable-shared). |
| 7747 | # 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] | 7748 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 7749 | # if it is not required, since it creates a dependency of the shared library |
| 7750 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 7751 | # don't need to link LIBS explicitly. The default should be only changed |
| 7752 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7753 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7754 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 7755 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7756 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7757 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 7758 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7759 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7760 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 7761 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7762 | |
| 7763 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7764 | # checks for libraries |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 7765 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sendfile in -lsendfile" >&5 |
| 7766 | $as_echo_n "checking for sendfile in -lsendfile... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7767 | if test "${ac_cv_lib_sendfile_sendfile+set}" = set; then : |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 7768 | $as_echo_n "(cached) " >&6 |
| 7769 | else |
| 7770 | ac_check_lib_save_LIBS=$LIBS |
| 7771 | LIBS="-lsendfile $LIBS" |
| 7772 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 7773 | /* end confdefs.h. */ |
| 7774 | |
| 7775 | /* Override any GCC internal prototype to avoid an error. |
| 7776 | Use char because int might match the return type of a GCC |
| 7777 | builtin and then its argument prototype would still apply. */ |
| 7778 | #ifdef __cplusplus |
| 7779 | extern "C" |
| 7780 | #endif |
| 7781 | char sendfile (); |
| 7782 | int |
| 7783 | main () |
| 7784 | { |
| 7785 | return sendfile (); |
| 7786 | ; |
| 7787 | return 0; |
| 7788 | } |
| 7789 | _ACEOF |
| 7790 | if ac_fn_c_try_link "$LINENO"; then : |
| 7791 | ac_cv_lib_sendfile_sendfile=yes |
| 7792 | else |
| 7793 | ac_cv_lib_sendfile_sendfile=no |
| 7794 | fi |
| 7795 | rm -f core conftest.err conftest.$ac_objext \ |
| 7796 | conftest$ac_exeext conftest.$ac_ext |
| 7797 | LIBS=$ac_check_lib_save_LIBS |
| 7798 | fi |
| 7799 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sendfile_sendfile" >&5 |
| 7800 | $as_echo "$ac_cv_lib_sendfile_sendfile" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7801 | if test "x$ac_cv_lib_sendfile_sendfile" = x""yes; then : |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 7802 | cat >>confdefs.h <<_ACEOF |
| 7803 | #define HAVE_LIBSENDFILE 1 |
| 7804 | _ACEOF |
| 7805 | |
| 7806 | LIBS="-lsendfile $LIBS" |
| 7807 | |
| 7808 | fi |
| 7809 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 7811 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7812 | if test "${ac_cv_lib_dl_dlopen+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7813 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7814 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7815 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7816 | LIBS="-ldl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7817 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7818 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7819 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7820 | /* Override any GCC internal prototype to avoid an error. |
| 7821 | Use char because int might match the return type of a GCC |
| 7822 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7823 | #ifdef __cplusplus |
| 7824 | extern "C" |
| 7825 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7826 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7827 | int |
| 7828 | main () |
| 7829 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7830 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7831 | ; |
| 7832 | return 0; |
| 7833 | } |
| 7834 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7835 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7836 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7837 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7838 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7839 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7840 | rm -f core conftest.err conftest.$ac_objext \ |
| 7841 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7842 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7843 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7844 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 7845 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7846 | 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] | 7847 | cat >>confdefs.h <<_ACEOF |
| 7848 | #define HAVE_LIBDL 1 |
| 7849 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7850 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7851 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7852 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7853 | fi |
| 7854 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7855 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 7856 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7857 | if test "${ac_cv_lib_dld_shl_load+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7858 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7859 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7860 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7861 | LIBS="-ldld $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7862 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7863 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7864 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7865 | /* Override any GCC internal prototype to avoid an error. |
| 7866 | Use char because int might match the return type of a GCC |
| 7867 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7868 | #ifdef __cplusplus |
| 7869 | extern "C" |
| 7870 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7871 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7872 | int |
| 7873 | main () |
| 7874 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7875 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7876 | ; |
| 7877 | return 0; |
| 7878 | } |
| 7879 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7880 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7881 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7882 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7883 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7884 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7885 | rm -f core conftest.err conftest.$ac_objext \ |
| 7886 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7887 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7888 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7889 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 7890 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7891 | 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] | 7892 | cat >>confdefs.h <<_ACEOF |
| 7893 | #define HAVE_LIBDLD 1 |
| 7894 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7895 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7896 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7897 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7898 | fi |
| 7899 | # Dynamic linking for HP-UX |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7900 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7901 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7902 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7903 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 7904 | $as_echo_n "checking for library containing sem_init... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7905 | if test "${ac_cv_search_sem_init+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7906 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7907 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7908 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7909 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7910 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7911 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7912 | /* Override any GCC internal prototype to avoid an error. |
| 7913 | Use char because int might match the return type of a GCC |
| 7914 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7915 | #ifdef __cplusplus |
| 7916 | extern "C" |
| 7917 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7918 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7919 | int |
| 7920 | main () |
| 7921 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7922 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7923 | ; |
| 7924 | return 0; |
| 7925 | } |
| 7926 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7927 | for ac_lib in '' pthread rt posix4; do |
| 7928 | if test -z "$ac_lib"; then |
| 7929 | ac_res="none required" |
| 7930 | else |
| 7931 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7932 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7933 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7934 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7935 | ac_cv_search_sem_init=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7936 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7937 | rm -f core conftest.err conftest.$ac_objext \ |
| 7938 | conftest$ac_exeext |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7939 | if test "${ac_cv_search_sem_init+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7940 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7941 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7942 | done |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7943 | if test "${ac_cv_search_sem_init+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7944 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7945 | else |
| 7946 | ac_cv_search_sem_init=no |
| 7947 | fi |
| 7948 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7949 | LIBS=$ac_func_search_save_LIBS |
| 7950 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7951 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 7952 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7953 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7954 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7955 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7956 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7957 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 7958 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7959 | # posix4 on Solaris 2.6 |
| 7960 | # pthread (first!) on Linux |
| 7961 | fi |
| 7962 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7963 | # check if we need libintl for locale functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7964 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 7965 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 7966 | if test "${ac_cv_lib_intl_textdomain+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7967 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7968 | else |
| 7969 | ac_check_lib_save_LIBS=$LIBS |
| 7970 | LIBS="-lintl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7971 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7972 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7973 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7974 | /* Override any GCC internal prototype to avoid an error. |
| 7975 | Use char because int might match the return type of a GCC |
| 7976 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7977 | #ifdef __cplusplus |
| 7978 | extern "C" |
| 7979 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7980 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7981 | int |
| 7982 | main () |
| 7983 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7984 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7985 | ; |
| 7986 | return 0; |
| 7987 | } |
| 7988 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7989 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7990 | ac_cv_lib_intl_textdomain=yes |
| 7991 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7992 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7993 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7994 | rm -f core conftest.err conftest.$ac_objext \ |
| 7995 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7996 | LIBS=$ac_check_lib_save_LIBS |
| 7997 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7998 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 7999 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8000 | 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] | 8001 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8002 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8003 | |
Brett Cannon | c6d936e | 2009-06-07 20:09:53 +0000 | [diff] [blame] | 8004 | LIBS="-lintl $LIBS" |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 8005 | fi |
| 8006 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8007 | |
| 8008 | # checks for system dependent C++ extensions support |
| 8009 | case "$ac_sys_system" in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8010 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 8011 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 8012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8013 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8014 | |
Georg Brandl | 59e87bd | 2011-02-15 19:48:59 +0000 | [diff] [blame] | 8015 | #include <load.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8016 | int |
| 8017 | main () |
| 8018 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8019 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8020 | ; |
| 8021 | return 0; |
| 8022 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8023 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8024 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8025 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8026 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8027 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8028 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8029 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8030 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8031 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8032 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8033 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8034 | |
| 8035 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8036 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8037 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8038 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8039 | rm -f core conftest.err conftest.$ac_objext \ |
| 8040 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8041 | *) ;; |
| 8042 | esac |
| 8043 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8044 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8045 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 8046 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8047 | if test "${ac_cv_lib_nsl_t_open+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8048 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8049 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8050 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8051 | LIBS="-lnsl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8052 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8053 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8054 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8055 | /* Override any GCC internal prototype to avoid an error. |
| 8056 | Use char because int might match the return type of a GCC |
| 8057 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8058 | #ifdef __cplusplus |
| 8059 | extern "C" |
| 8060 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8061 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8062 | int |
| 8063 | main () |
| 8064 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8065 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8066 | ; |
| 8067 | return 0; |
| 8068 | } |
| 8069 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8070 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8071 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8072 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8073 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8074 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8075 | rm -f core conftest.err conftest.$ac_objext \ |
| 8076 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8077 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8078 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8079 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 8080 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8081 | 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] | 8082 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8083 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 8084 | # SVR4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8085 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 8086 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8087 | if test "${ac_cv_lib_socket_socket+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8088 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8089 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8090 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8091 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8092 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8093 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8094 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8095 | /* Override any GCC internal prototype to avoid an error. |
| 8096 | Use char because int might match the return type of a GCC |
| 8097 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8098 | #ifdef __cplusplus |
| 8099 | extern "C" |
| 8100 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8101 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8102 | int |
| 8103 | main () |
| 8104 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8105 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8106 | ; |
| 8107 | return 0; |
| 8108 | } |
| 8109 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8110 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8111 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8112 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8113 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8114 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8115 | rm -f core conftest.err conftest.$ac_objext \ |
| 8116 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8117 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8118 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 8120 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8121 | if test "x$ac_cv_lib_socket_socket" = x""yes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8122 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8123 | fi |
| 8124 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 8125 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8126 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 8127 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8128 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8129 | # Check whether --with-libs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8130 | if test "${with_libs+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8131 | withval=$with_libs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8132 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8133 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 8134 | LIBS="$withval $LIBS" |
| 8135 | |
| 8136 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8138 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8139 | fi |
| 8140 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 8141 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8142 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8143 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 8144 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8145 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8146 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8147 | if test "${ac_cv_path_PKG_CONFIG+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8148 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8149 | else |
| 8150 | case $PKG_CONFIG in |
| 8151 | [\\/]* | ?:[\\/]*) |
| 8152 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 8153 | ;; |
| 8154 | *) |
| 8155 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8156 | for as_dir in $PATH |
| 8157 | do |
| 8158 | IFS=$as_save_IFS |
| 8159 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8160 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8161 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8162 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8163 | $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] | 8164 | break 2 |
| 8165 | fi |
| 8166 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8167 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8168 | IFS=$as_save_IFS |
| 8169 | |
| 8170 | ;; |
| 8171 | esac |
| 8172 | fi |
| 8173 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 8174 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8175 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 8176 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8177 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8179 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8180 | fi |
| 8181 | |
| 8182 | |
| 8183 | fi |
| 8184 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 8185 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 8186 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8187 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8188 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8189 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8190 | if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8191 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8192 | else |
| 8193 | case $ac_pt_PKG_CONFIG in |
| 8194 | [\\/]* | ?:[\\/]*) |
| 8195 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 8196 | ;; |
| 8197 | *) |
| 8198 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8199 | for as_dir in $PATH |
| 8200 | do |
| 8201 | IFS=$as_save_IFS |
| 8202 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8203 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8204 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8205 | 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] | 8206 | $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] | 8207 | break 2 |
| 8208 | fi |
| 8209 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8210 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8211 | IFS=$as_save_IFS |
| 8212 | |
| 8213 | ;; |
| 8214 | esac |
| 8215 | fi |
| 8216 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 8217 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 8219 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8220 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8222 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8223 | fi |
| 8224 | |
| 8225 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 8226 | PKG_CONFIG="" |
| 8227 | else |
| 8228 | case $cross_compiling:$ac_tool_warned in |
| 8229 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8230 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 8231 | $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] | 8232 | ac_tool_warned=yes ;; |
| 8233 | esac |
| 8234 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 8235 | fi |
| 8236 | else |
| 8237 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 8238 | fi |
| 8239 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8240 | |
| 8241 | # Check for use of the system expat library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 8243 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8244 | |
| 8245 | # Check whether --with-system_expat was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8246 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8247 | withval=$with_system_expat; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 8248 | else |
| 8249 | with_system_expat="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8250 | fi |
| 8251 | |
| 8252 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 8254 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8255 | |
| 8256 | # Check for use of the system libffi library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8257 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 8258 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8259 | |
| 8260 | # Check whether --with-system_ffi was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8261 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8262 | withval=$with_system_ffi; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 8263 | else |
| 8264 | with_system_ffi="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8265 | fi |
| 8266 | |
| 8267 | |
| 8268 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8269 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 8270 | else |
| 8271 | LIBFFI_INCLUDEDIR="" |
| 8272 | fi |
| 8273 | |
| 8274 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8275 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 8276 | $as_echo "$with_system_ffi" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 8277 | |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 8278 | # Check for support for loadable sqlite extensions |
| 8279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-loadable-sqlite-extensions" >&5 |
| 8280 | $as_echo_n "checking for --enable-loadable-sqlite-extensions... " >&6; } |
| 8281 | # Check whether --enable-loadable-sqlite-extensions was given. |
| 8282 | if test "${enable_loadable_sqlite_extensions+set}" = set; then : |
| 8283 | enableval=$enable_loadable_sqlite_extensions; |
| 8284 | else |
| 8285 | enable_loadable_sqlite_extensions="no" |
| 8286 | fi |
| 8287 | |
| 8288 | |
| 8289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_loadable_sqlite_extensions" >&5 |
| 8290 | $as_echo "$enable_loadable_sqlite_extensions" >&6; } |
| 8291 | |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8292 | # Check for --with-dbmliborder |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8293 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 8294 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8295 | |
| 8296 | # Check whether --with-dbmliborder was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8297 | if test "${with_dbmliborder+set}" = set; then : |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8298 | withval=$with_dbmliborder; |
| 8299 | if test x$with_dbmliborder = xyes |
| 8300 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 8301 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8302 | else |
| 8303 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 8304 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 8305 | then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 8306 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8307 | fi |
| 8308 | done |
| 8309 | fi |
| 8310 | fi |
| 8311 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 8313 | $as_echo "$with_dbmliborder" >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8314 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8315 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8316 | |
| 8317 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8318 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 8319 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8320 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8321 | # Check whether --with-signal-module was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8322 | if test "${with_signal_module+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8323 | withval=$with_signal_module; |
| 8324 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8325 | |
| 8326 | |
| 8327 | if test -z "$with_signal_module" |
| 8328 | then with_signal_module="yes" |
| 8329 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8330 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 8331 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8332 | |
| 8333 | if test "${with_signal_module}" = "yes"; then |
| 8334 | USE_SIGNAL_MODULE="" |
| 8335 | SIGNAL_OBJS="" |
| 8336 | else |
| 8337 | USE_SIGNAL_MODULE="#" |
| 8338 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 8339 | fi |
| 8340 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 8341 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8342 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8343 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8344 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8345 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8346 | |
| 8347 | # Templates for things AC_DEFINEd more than once. |
| 8348 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8349 | |
| 8350 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8351 | |
| 8352 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8353 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 8354 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8355 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8356 | # Check whether --with-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8357 | if test "${with_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8358 | withval=$with_threads; |
| 8359 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8360 | |
| 8361 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8362 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8363 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8364 | # Check whether --with-thread was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8365 | if test "${with_thread+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8366 | withval=$with_thread; with_threads=$with_thread |
| 8367 | fi |
| 8368 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8369 | |
| 8370 | if test -z "$with_threads" |
| 8371 | then with_threads="yes" |
| 8372 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8373 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 8374 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8375 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8376 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8377 | if test "$with_threads" = "no" |
| 8378 | then |
| 8379 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8380 | elif test "$ac_cv_pthread_is_default" = yes |
| 8381 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8382 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8383 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8384 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8385 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8386 | |
| 8387 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8388 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8389 | elif test "$ac_cv_kpthread" = "yes" |
| 8390 | then |
| 8391 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8392 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8393 | CXX="$CXX -Kpthread" |
| 8394 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8395 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 8396 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8397 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8398 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8399 | elif test "$ac_cv_kthread" = "yes" |
| 8400 | then |
| 8401 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8402 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8403 | CXX="$CXX -Kthread" |
| 8404 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8405 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8406 | |
| 8407 | posix_threads=yes |
| 8408 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8409 | elif test "$ac_cv_pthread" = "yes" |
| 8410 | then |
| 8411 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8412 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8413 | CXX="$CXX -pthread" |
| 8414 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8415 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8416 | |
| 8417 | posix_threads=yes |
| 8418 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8419 | else |
| 8420 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 8421 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 8422 | fi |
| 8423 | if test ! -z "$withval" -a -d "$withval" |
| 8424 | then LDFLAGS="$LDFLAGS -L$withval" |
| 8425 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8426 | |
| 8427 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 8428 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 8429 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8430 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 8431 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 8432 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8433 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8434 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8435 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8436 | #ifdef _POSIX_THREADS |
| 8437 | yes |
| 8438 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8439 | |
| 8440 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8441 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8442 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8443 | unistd_defines_pthreads=yes |
| 8444 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8445 | unistd_defines_pthreads=no |
| 8446 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 8447 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8448 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8449 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 8450 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8451 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8452 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 8453 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8454 | ac_fn_c_check_header_mongrel "$LINENO" "cthreads.h" "ac_cv_header_cthreads_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8455 | if test "x$ac_cv_header_cthreads_h" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8456 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8457 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8458 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8459 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8460 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8461 | $as_echo "#define HURD_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8462 | |
| 8463 | LIBS="$LIBS -lthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8464 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8465 | else |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8466 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8467 | ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8468 | if test "x$ac_cv_header_mach_cthreads_h" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8469 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8470 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8471 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8472 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8473 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8474 | $as_echo "#define MACH_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8475 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8476 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8477 | else |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8478 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8479 | # Just looking for pthread_create in libpthread is not enough: |
| 8480 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 8481 | # So we really have to include pthread.h, and then link. |
| 8482 | _libs=$LIBS |
| 8483 | LIBS="$LIBS -lpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8484 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 8485 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 8486 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8487 | /* end confdefs.h. */ |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8488 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8489 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8490 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8491 | int |
| 8492 | main () |
| 8493 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8494 | |
| 8495 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8496 | ; |
| 8497 | return 0; |
| 8498 | } |
| 8499 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8500 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8501 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8502 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8503 | $as_echo "yes" >&6; } |
| 8504 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8505 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8506 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8507 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8508 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8509 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8510 | LIBS=$_libs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8511 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8512 | if test "x$ac_cv_func_pthread_detach" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8513 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8514 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8515 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8516 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8517 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8518 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8519 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 8520 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8521 | if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8522 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8523 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8524 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8525 | LIBS="-lpthreads $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8526 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8527 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8528 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8529 | /* Override any GCC internal prototype to avoid an error. |
| 8530 | Use char because int might match the return type of a GCC |
| 8531 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8532 | #ifdef __cplusplus |
| 8533 | extern "C" |
| 8534 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8535 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8536 | int |
| 8537 | main () |
| 8538 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8539 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8540 | ; |
| 8541 | return 0; |
| 8542 | } |
| 8543 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8544 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8545 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8546 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8547 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8548 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8549 | rm -f core conftest.err conftest.$ac_objext \ |
| 8550 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8551 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8552 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8553 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 8554 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8555 | if test "x$ac_cv_lib_pthreads_pthread_create" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8556 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8557 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8558 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8559 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8560 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8561 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8562 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8563 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 8564 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8565 | if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8566 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8567 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8568 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8569 | LIBS="-lc_r $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8570 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8571 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8572 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8573 | /* Override any GCC internal prototype to avoid an error. |
| 8574 | Use char because int might match the return type of a GCC |
| 8575 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8576 | #ifdef __cplusplus |
| 8577 | extern "C" |
| 8578 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8579 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8580 | int |
| 8581 | main () |
| 8582 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8583 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8584 | ; |
| 8585 | return 0; |
| 8586 | } |
| 8587 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8588 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8589 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8590 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8591 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8592 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8593 | rm -f core conftest.err conftest.$ac_objext \ |
| 8594 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8595 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8596 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8597 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 8598 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8599 | if test "x$ac_cv_lib_c_r_pthread_create" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8600 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8601 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8602 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8603 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8604 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8605 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8606 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8607 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 8608 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8609 | if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8610 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8611 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8612 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8613 | LIBS="-lpthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8614 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8615 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8616 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8617 | /* Override any GCC internal prototype to avoid an error. |
| 8618 | Use char because int might match the return type of a GCC |
| 8619 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8620 | #ifdef __cplusplus |
| 8621 | extern "C" |
| 8622 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8623 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8624 | int |
| 8625 | main () |
| 8626 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8627 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8628 | ; |
| 8629 | return 0; |
| 8630 | } |
| 8631 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8632 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8633 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8634 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8635 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8636 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8637 | rm -f core conftest.err conftest.$ac_objext \ |
| 8638 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8639 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8640 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8641 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 8642 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8643 | if test "x$ac_cv_lib_pthread___pthread_create_system" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8644 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8645 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8646 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8647 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8648 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8649 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8650 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8651 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 8652 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8653 | if test "${ac_cv_lib_cma_pthread_create+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8654 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8655 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8656 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8657 | LIBS="-lcma $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8658 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8659 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8660 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8661 | /* Override any GCC internal prototype to avoid an error. |
| 8662 | Use char because int might match the return type of a GCC |
| 8663 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8664 | #ifdef __cplusplus |
| 8665 | extern "C" |
| 8666 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8667 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8668 | int |
| 8669 | main () |
| 8670 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8671 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8672 | ; |
| 8673 | return 0; |
| 8674 | } |
| 8675 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8676 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8677 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8678 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8679 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8680 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8681 | rm -f core conftest.err conftest.$ac_objext \ |
| 8682 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8683 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8684 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 8686 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8687 | if test "x$ac_cv_lib_cma_pthread_create" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8688 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8689 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8690 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8691 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8692 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8693 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 8694 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8695 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 8696 | fi |
| 8697 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8698 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8699 | fi |
| 8700 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 8701 | fi |
| 8702 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8703 | fi |
| 8704 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8705 | fi |
| 8706 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8707 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8708 | rm -f core conftest.err conftest.$ac_objext \ |
| 8709 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8710 | fi |
| 8711 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8712 | |
| 8713 | fi |
| 8714 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8715 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8716 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 8718 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8719 | if test "${ac_cv_lib_mpc_usconfig+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8720 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8721 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8722 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8723 | LIBS="-lmpc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8724 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8725 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8726 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8727 | /* Override any GCC internal prototype to avoid an error. |
| 8728 | Use char because int might match the return type of a GCC |
| 8729 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8730 | #ifdef __cplusplus |
| 8731 | extern "C" |
| 8732 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8733 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8734 | int |
| 8735 | main () |
| 8736 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8737 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8738 | ; |
| 8739 | return 0; |
| 8740 | } |
| 8741 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8742 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8743 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8744 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8745 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8746 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8747 | rm -f core conftest.err conftest.$ac_objext \ |
| 8748 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8749 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8750 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8751 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 8752 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8753 | if test "x$ac_cv_lib_mpc_usconfig" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8754 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8755 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8756 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8757 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8758 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8759 | fi |
| 8760 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8761 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 8762 | if test "$posix_threads" != "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8763 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 8764 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8765 | if test "${ac_cv_lib_thread_thr_create+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8766 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8767 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8768 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8769 | LIBS="-lthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8770 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8771 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8772 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8773 | /* Override any GCC internal prototype to avoid an error. |
| 8774 | Use char because int might match the return type of a GCC |
| 8775 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8776 | #ifdef __cplusplus |
| 8777 | extern "C" |
| 8778 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8779 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8780 | int |
| 8781 | main () |
| 8782 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8783 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8784 | ; |
| 8785 | return 0; |
| 8786 | } |
| 8787 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8788 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8789 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8790 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8791 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8792 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8793 | rm -f core conftest.err conftest.$ac_objext \ |
| 8794 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8795 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8796 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8797 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 8798 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8799 | if test "x$ac_cv_lib_thread_thr_create" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8800 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8801 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8802 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8803 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8804 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8805 | fi |
| 8806 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8807 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8808 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8809 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8810 | if test "$posix_threads" = "yes"; then |
| 8811 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8812 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8813 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8814 | |
| 8815 | fi |
| 8816 | |
| 8817 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 8818 | case $ac_sys_system/$ac_sys_release in |
| 8819 | SunOS/5.6) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8820 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8821 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8822 | ;; |
| 8823 | SunOS/5.8) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8824 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8825 | |
| 8826 | ;; |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8827 | AIX/5) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8828 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8829 | |
| 8830 | ;; |
Antoine Pitrou | 33a2994 | 2010-08-30 14:52:00 +0000 | [diff] [blame] | 8831 | AIX/6) |
| 8832 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
| 8833 | |
| 8834 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8835 | esac |
| 8836 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8837 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 8838 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8839 | if test "${ac_cv_pthread_system_supported+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8840 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8841 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8842 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8843 | ac_cv_pthread_system_supported=no |
| 8844 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8845 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8846 | /* end confdefs.h. */ |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8847 | #include <pthread.h> |
| 8848 | void *foo(void *parm) { |
| 8849 | return NULL; |
| 8850 | } |
| 8851 | main() { |
| 8852 | pthread_attr_t attr; |
| 8853 | pthread_t id; |
| 8854 | if (pthread_attr_init(&attr)) exit(-1); |
| 8855 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 8856 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 8857 | exit(0); |
| 8858 | } |
| 8859 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8860 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8861 | ac_cv_pthread_system_supported=yes |
| 8862 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8863 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8864 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8865 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8866 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8867 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8868 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8869 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8870 | fi |
| 8871 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8872 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 8873 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8874 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 8875 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8876 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8877 | |
| 8878 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8879 | for ac_func in pthread_sigmask |
| 8880 | do : |
| 8881 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 8882 | 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] | 8883 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8884 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8885 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8886 | case $ac_sys_system in |
| 8887 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8888 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8889 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8890 | |
| 8891 | ;; |
| 8892 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8893 | fi |
| 8894 | done |
| 8895 | |
| 8896 | fi |
| 8897 | |
| 8898 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8899 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8900 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8901 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 8902 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8903 | # Check whether --enable-ipv6 was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8904 | if test "${enable_ipv6+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8905 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8906 | no) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8907 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8908 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8909 | ipv6=no |
| 8910 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8911 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8912 | $as_echo "yes" >&6; } |
| 8913 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8914 | |
| 8915 | ipv6=yes |
| 8916 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8917 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8918 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8919 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8920 | if test "$cross_compiling" = yes; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8921 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8922 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8923 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8924 | ipv6=no |
| 8925 | |
| 8926 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8927 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8928 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8929 | /* AF_INET6 available check */ |
| 8930 | #include <sys/types.h> |
| 8931 | #include <sys/socket.h> |
| 8932 | main() |
| 8933 | { |
| 8934 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 8935 | exit(1); |
| 8936 | else |
| 8937 | exit(0); |
| 8938 | } |
| 8939 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8940 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8941 | if ac_fn_c_try_run "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8942 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8943 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8944 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8945 | ipv6=yes |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8946 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8947 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8948 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8950 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8951 | ipv6=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8952 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8953 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8954 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8955 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8956 | fi |
| 8957 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8958 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8959 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8960 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 8961 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 8962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8963 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8964 | |
| 8965 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8966 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8967 | int |
| 8968 | main () |
| 8969 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8970 | struct sockaddr_in6 x; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8971 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8972 | ; |
| 8973 | return 0; |
| 8974 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8975 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8976 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8977 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8978 | |
| 8979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8980 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8981 | ipv6=yes |
| 8982 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8983 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8984 | |
| 8985 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8986 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8987 | ipv6=no |
| 8988 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8989 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8990 | 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] | 8991 | fi |
| 8992 | |
| 8993 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8994 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8995 | |
| 8996 | fi |
| 8997 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8998 | fi |
| 8999 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9000 | |
| 9001 | ipv6type=unknown |
| 9002 | ipv6lib=none |
| 9003 | ipv6trylibc=no |
| 9004 | |
| 9005 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9006 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 9007 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 9008 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 9009 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9010 | case $i in |
| 9011 | inria) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9013 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9014 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9015 | #include <netinet/in.h> |
| 9016 | #ifdef IPV6_INRIA_VERSION |
| 9017 | yes |
| 9018 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9019 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9020 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9021 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9022 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9023 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9024 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9025 | |
| 9026 | ;; |
| 9027 | kame) |
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 <netinet/in.h> |
| 9032 | #ifdef __KAME__ |
| 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 |
| 9040 | ipv6libdir=/usr/local/v6/lib |
| 9041 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9042 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9043 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9044 | |
| 9045 | ;; |
| 9046 | linux-glibc) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9047 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9048 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9049 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9050 | #include <features.h> |
| 9051 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 9052 | yes |
| 9053 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9054 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9055 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9056 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9057 | ipv6type=$i; |
| 9058 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9059 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9060 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9061 | |
| 9062 | ;; |
| 9063 | linux-inet6) |
| 9064 | if test -d /usr/inet6; then |
| 9065 | ipv6type=$i |
| 9066 | ipv6lib=inet6 |
| 9067 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9068 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9069 | fi |
| 9070 | ;; |
| 9071 | solaris) |
| 9072 | if test -f /etc/netconfig; then |
Antoine Pitrou | f3fcd9f | 2011-01-03 18:53:50 +0000 | [diff] [blame] | 9073 | if $GREP -q tcp6 /etc/netconfig; then |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9074 | ipv6type=$i |
| 9075 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9076 | fi |
| 9077 | fi |
| 9078 | ;; |
| 9079 | toshiba) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9080 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9081 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9082 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9083 | #include <sys/param.h> |
| 9084 | #ifdef _TOSHIBA_INET6 |
| 9085 | yes |
| 9086 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9087 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9088 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9089 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9090 | ipv6type=$i; |
| 9091 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9092 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9093 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9094 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9095 | |
| 9096 | ;; |
| 9097 | v6d) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9098 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9099 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9100 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9101 | #include </usr/local/v6/include/sys/v6config.h> |
| 9102 | #ifdef __V6D__ |
| 9103 | yes |
| 9104 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9105 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9106 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9107 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9108 | ipv6type=$i; |
| 9109 | ipv6lib=v6; |
| 9110 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9111 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9112 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9113 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9114 | |
| 9115 | ;; |
| 9116 | zeta) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9117 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9118 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9119 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9120 | #include <sys/param.h> |
| 9121 | #ifdef _ZETA_MINAMI_INET6 |
| 9122 | yes |
| 9123 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9124 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9125 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9126 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9127 | ipv6type=$i; |
| 9128 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9129 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9130 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9131 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9132 | |
| 9133 | ;; |
| 9134 | esac |
| 9135 | if test "$ipv6type" != "unknown"; then |
| 9136 | break |
| 9137 | fi |
| 9138 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9139 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 9140 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9141 | fi |
| 9142 | |
| 9143 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 9144 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 9145 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 9146 | echo "using lib$ipv6lib" |
| 9147 | else |
| 9148 | if test $ipv6trylibc = "yes"; then |
| 9149 | echo "using libc" |
| 9150 | else |
| 9151 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 9152 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 9153 | echo 'ipv6 kit and compile beforehand.' |
| 9154 | exit 1 |
| 9155 | fi |
| 9156 | fi |
| 9157 | fi |
| 9158 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 9160 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 9161 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9162 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9163 | |
| 9164 | #include <Carbon/Carbon.h> |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9165 | int |
| 9166 | main () |
| 9167 | { |
| 9168 | FSIORefNum fRef = 0 |
| 9169 | ; |
| 9170 | return 0; |
| 9171 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9172 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9173 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9174 | if ac_fn_c_try_compile "$LINENO"; then : |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9175 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9176 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9177 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9178 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9179 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9180 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9181 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9182 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9183 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9185 | $as_echo "no" >&6; } |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9186 | |
| 9187 | fi |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9188 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9189 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9190 | # Check for --with-doc-strings |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9191 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 9192 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9193 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9194 | # Check whether --with-doc-strings was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9195 | if test "${with_doc_strings+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9196 | withval=$with_doc_strings; |
| 9197 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9198 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9199 | |
| 9200 | if test -z "$with_doc_strings" |
| 9201 | then with_doc_strings="yes" |
| 9202 | fi |
| 9203 | if test "$with_doc_strings" != "no" |
| 9204 | then |
| 9205 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9206 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9207 | |
| 9208 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 9210 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9211 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 9212 | # Check if eval loop should use timestamp counter profiling |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9213 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 9214 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9215 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9216 | # Check whether --with-tsc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9217 | if test "${with_tsc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9218 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9219 | if test "$withval" != no |
| 9220 | then |
| 9221 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9222 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9223 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9224 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9225 | $as_echo "yes" >&6; } |
| 9226 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9227 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9228 | fi |
| 9229 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9230 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9231 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9232 | fi |
| 9233 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9234 | |
| 9235 | # Check for Python-specific malloc support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9236 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 9237 | $as_echo_n "checking for --with-pymalloc... " >&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-pymalloc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9240 | if test "${with_pymalloc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9241 | withval=$with_pymalloc; |
| 9242 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9243 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9244 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9245 | if test -z "$with_pymalloc" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 9246 | then |
| 9247 | with_pymalloc="yes" |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 9248 | ABIFLAGS="${ABIFLAGS}m" |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9249 | fi |
| 9250 | if test "$with_pymalloc" != "no" |
| 9251 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9252 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9253 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9254 | |
| 9255 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 9257 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9258 | |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9259 | # Check for Valgrind support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9260 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 9261 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9262 | |
| 9263 | # Check whether --with-valgrind was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9264 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9265 | withval=$with_valgrind; |
| 9266 | else |
| 9267 | with_valgrind=no |
| 9268 | fi |
| 9269 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9270 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 9271 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9272 | if test "$with_valgrind" != no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9273 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9274 | if test "x$ac_cv_header_valgrind_valgrind_h" = x""yes; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9275 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9276 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9277 | |
| 9278 | else |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 9279 | as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9280 | |
| 9281 | fi |
| 9282 | |
| 9283 | |
Jeffrey Yasskin | 3937083 | 2010-05-03 19:29:34 +0000 | [diff] [blame] | 9284 | OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT" |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9285 | fi |
| 9286 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 9287 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9288 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 9289 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9290 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9291 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 9292 | # 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] | 9293 | for ac_func in dlopen |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9294 | do : |
| 9295 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9296 | if test "x$ac_cv_func_dlopen" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9297 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9298 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9299 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9300 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9301 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 9302 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9303 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9304 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9305 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 9306 | # loading of modules. |
| 9307 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9308 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 9309 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9310 | if test -z "$DYNLOADFILE" |
| 9311 | then |
| 9312 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 9313 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 9314 | if test "$ac_cv_func_dlopen" = yes |
| 9315 | then DYNLOADFILE="dynload_shlib.o" |
| 9316 | else DYNLOADFILE="dynload_aix.o" |
| 9317 | fi |
| 9318 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9319 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 9320 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 9321 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9322 | *) |
| 9323 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 9324 | # out any dynamic loading |
| 9325 | if test "$ac_cv_func_dlopen" = yes |
| 9326 | then DYNLOADFILE="dynload_shlib.o" |
| 9327 | else DYNLOADFILE="dynload_stub.o" |
| 9328 | fi |
| 9329 | ;; |
| 9330 | esac |
| 9331 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 9333 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9334 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 9335 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9336 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9337 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9338 | |
| 9339 | fi |
| 9340 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9341 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 9342 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9343 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9344 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 9345 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9346 | if test -z "$MACHDEP_OBJS" |
| 9347 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 9348 | MACHDEP_OBJS=$extra_machdep_objs |
| 9349 | else |
| 9350 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9351 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9352 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: MACHDEP_OBJS" >&5 |
| 9353 | $as_echo "MACHDEP_OBJS" >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9354 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9355 | # checks for library functions |
Antoine Pitrou | b1c5496 | 2010-10-14 15:05:38 +0000 | [diff] [blame] | 9356 | for ac_func in alarm accept4 setitimer getitimer bind_textdomain_codeset chown \ |
Antoine Pitrou | 8250e23 | 2011-02-25 23:41:16 +0000 | [diff] [blame] | 9357 | clock confstr ctermid execv faccessat fchmod fchmodat fchown fchownat \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 9358 | fexecve fdopendir fork fpathconf fstatat ftime ftruncate futimesat \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 9359 | futimens futimes gai_strerror \ |
| 9360 | getgrouplist getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 9361 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Gregory P. Smith | 5ed2e77 | 2011-05-15 00:26:45 -0700 | [diff] [blame] | 9362 | if_nameindex \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 9363 | initgroups kill killpg lchmod lchown lockf linkat lstat lutimes mbrtowc mkdirat mkfifo \ |
Charles-François Natali | daafdd5 | 2011-05-29 20:07:40 +0200 | [diff] [blame] | 9364 | mkfifoat mknod mknodat mktime mremap nice openat pathconf pause pipe2 plock poll \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 9365 | posix_fallocate posix_fadvise pread \ |
Victor Stinner | b3e7219 | 2011-05-08 01:46:11 +0200 | [diff] [blame] | 9366 | pthread_init pthread_kill putenv pwrite readlink readlinkat readv realpath renameat \ |
Georg Brandl | 941f956 | 2011-02-25 15:21:47 +0000 | [diff] [blame] | 9367 | select sem_open sem_timedwait sem_getvalue sem_unlink sendfile setegid seteuid \ |
Antoine Pitrou | 061cfb5 | 2011-02-28 22:25:22 +0000 | [diff] [blame] | 9368 | setgid sethostname \ |
Giampaolo Rodolà | 18e8bcb | 2011-02-25 20:57:54 +0000 | [diff] [blame] | 9369 | setlocale setregid setreuid setresuid setresgid setsid setpgid setpgrp setpriority setuid setvbuf \ |
Victor Stinner | b3e7219 | 2011-05-08 01:46:11 +0200 | [diff] [blame] | 9370 | sigaction sigaltstack siginterrupt sigpending \ |
| 9371 | sigrelse sigwait snprintf strftime strlcpy symlinkat sync \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 9372 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Ross Lagerwall | 7807c35 | 2011-03-17 20:20:30 +0200 | [diff] [blame] | 9373 | truncate uname unlinkat unsetenv utimensat utimes waitid waitpid wait3 wait4 \ |
| 9374 | wcscoll wcsftime wcsxfrm writev _getpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9375 | do : |
| 9376 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9377 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 9378 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9379 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9380 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9381 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 9382 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9383 | fi |
| 9384 | done |
| 9385 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9386 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9387 | # For some functions, having a definition is not sufficient, since |
| 9388 | # we want to take their address. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9389 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 9390 | $as_echo_n "checking for chroot... " >&6; } |
| 9391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9392 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9393 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9394 | int |
| 9395 | main () |
| 9396 | { |
| 9397 | void *x=chroot |
| 9398 | ; |
| 9399 | return 0; |
| 9400 | } |
| 9401 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9402 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9403 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9404 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9405 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9406 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9407 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9408 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9409 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9410 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9411 | |
| 9412 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9413 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9414 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 9415 | $as_echo_n "checking for link... " >&6; } |
| 9416 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9417 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9418 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9419 | int |
| 9420 | main () |
| 9421 | { |
| 9422 | void *x=link |
| 9423 | ; |
| 9424 | return 0; |
| 9425 | } |
| 9426 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9427 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9428 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9429 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9430 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9431 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9432 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9433 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9434 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9435 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9436 | |
| 9437 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9438 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9439 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 9440 | $as_echo_n "checking for symlink... " >&6; } |
| 9441 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9442 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9443 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9444 | int |
| 9445 | main () |
| 9446 | { |
| 9447 | void *x=symlink |
| 9448 | ; |
| 9449 | return 0; |
| 9450 | } |
| 9451 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9452 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9453 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9454 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9455 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9456 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9457 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9458 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9459 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9460 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9461 | |
| 9462 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9463 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9464 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 9465 | $as_echo_n "checking for fchdir... " >&6; } |
| 9466 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9467 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9468 | #include <unistd.h> |
| 9469 | int |
| 9470 | main () |
| 9471 | { |
| 9472 | void *x=fchdir |
| 9473 | ; |
| 9474 | return 0; |
| 9475 | } |
| 9476 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9477 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9478 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9479 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9480 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9481 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9482 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9483 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9484 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9485 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9486 | |
| 9487 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9488 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9489 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 9490 | $as_echo_n "checking for fsync... " >&6; } |
| 9491 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9492 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9493 | #include <unistd.h> |
| 9494 | int |
| 9495 | main () |
| 9496 | { |
| 9497 | void *x=fsync |
| 9498 | ; |
| 9499 | return 0; |
| 9500 | } |
| 9501 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9502 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9503 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9504 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9505 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9506 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9507 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9508 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9509 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9510 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9511 | |
| 9512 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9513 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9514 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 9515 | $as_echo_n "checking for fdatasync... " >&6; } |
| 9516 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9517 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9518 | #include <unistd.h> |
| 9519 | int |
| 9520 | main () |
| 9521 | { |
| 9522 | void *x=fdatasync |
| 9523 | ; |
| 9524 | return 0; |
| 9525 | } |
| 9526 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9527 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9528 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9529 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9530 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9532 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9533 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9534 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9535 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9536 | |
| 9537 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9538 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9539 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 9540 | $as_echo_n "checking for epoll... " >&6; } |
| 9541 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9542 | /* end confdefs.h. */ |
| 9543 | #include <sys/epoll.h> |
| 9544 | int |
| 9545 | main () |
| 9546 | { |
| 9547 | void *x=epoll_create |
| 9548 | ; |
| 9549 | return 0; |
| 9550 | } |
| 9551 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9552 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9553 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9554 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9555 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9556 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9557 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9558 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9560 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9561 | |
| 9562 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9563 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9564 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 9565 | $as_echo_n "checking for kqueue... " >&6; } |
| 9566 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9567 | /* end confdefs.h. */ |
| 9568 | |
| 9569 | #include <sys/types.h> |
| 9570 | #include <sys/event.h> |
| 9571 | |
| 9572 | int |
| 9573 | main () |
| 9574 | { |
| 9575 | int x=kqueue() |
| 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 : |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9581 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9582 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +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; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +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; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9589 | |
| 9590 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9591 | 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] | 9592 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 9593 | # functions ctermid_r, setgroups in the library, but no prototype |
| 9594 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 9595 | # address to avoid compiler warnings and potential miscompilations |
| 9596 | # because of the missing prototypes. |
| 9597 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9598 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 9599 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 9600 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9601 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9602 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9603 | #include <stdio.h> |
| 9604 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9605 | int |
| 9606 | main () |
| 9607 | { |
| 9608 | void* p = ctermid_r |
| 9609 | ; |
| 9610 | return 0; |
| 9611 | } |
| 9612 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9613 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9614 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9615 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9616 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9617 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9618 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9619 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9620 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9621 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9622 | |
| 9623 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9624 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9625 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9626 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5 |
| 9627 | $as_echo_n "checking for flock declaration... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9628 | if test "${ac_cv_flock_decl+set}" = set; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9629 | $as_echo_n "(cached) " >&6 |
| 9630 | else |
| 9631 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9632 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9633 | #include <sys/file.h> |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9634 | int |
| 9635 | main () |
| 9636 | { |
| 9637 | void* p = flock |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9638 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9639 | ; |
| 9640 | return 0; |
| 9641 | } |
| 9642 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9643 | if ac_fn_c_try_compile "$LINENO"; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9644 | ac_cv_flock_decl=yes |
| 9645 | else |
| 9646 | ac_cv_flock_decl=no |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9647 | |
| 9648 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9649 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9650 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9651 | fi |
| 9652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5 |
| 9653 | $as_echo "$ac_cv_flock_decl" >&6; } |
| 9654 | if test "x${ac_cv_flock_decl}" = xyes; then |
| 9655 | for ac_func in flock |
| 9656 | do : |
| 9657 | ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9658 | if test "x$ac_cv_func_flock" = x""yes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9659 | cat >>confdefs.h <<_ACEOF |
| 9660 | #define HAVE_FLOCK 1 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9661 | _ACEOF |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9662 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9663 | else |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9664 | { $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] | 9665 | $as_echo_n "checking for flock in -lbsd... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9666 | if test "${ac_cv_lib_bsd_flock+set}" = set; then : |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9667 | $as_echo_n "(cached) " >&6 |
| 9668 | else |
| 9669 | ac_check_lib_save_LIBS=$LIBS |
| 9670 | LIBS="-lbsd $LIBS" |
| 9671 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9672 | /* end confdefs.h. */ |
| 9673 | |
| 9674 | /* Override any GCC internal prototype to avoid an error. |
| 9675 | Use char because int might match the return type of a GCC |
| 9676 | builtin and then its argument prototype would still apply. */ |
| 9677 | #ifdef __cplusplus |
| 9678 | extern "C" |
| 9679 | #endif |
| 9680 | char flock (); |
| 9681 | int |
| 9682 | main () |
| 9683 | { |
| 9684 | return flock (); |
| 9685 | ; |
| 9686 | return 0; |
| 9687 | } |
| 9688 | _ACEOF |
| 9689 | if ac_fn_c_try_link "$LINENO"; then : |
| 9690 | ac_cv_lib_bsd_flock=yes |
| 9691 | else |
| 9692 | ac_cv_lib_bsd_flock=no |
| 9693 | fi |
| 9694 | rm -f core conftest.err conftest.$ac_objext \ |
| 9695 | conftest$ac_exeext conftest.$ac_ext |
| 9696 | LIBS=$ac_check_lib_save_LIBS |
| 9697 | fi |
| 9698 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5 |
| 9699 | $as_echo "$ac_cv_lib_bsd_flock" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9700 | if test "x$ac_cv_lib_bsd_flock" = x""yes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9701 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9702 | |
| 9703 | |
| 9704 | $as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h |
| 9705 | |
| 9706 | |
| 9707 | fi |
| 9708 | |
| 9709 | |
| 9710 | fi |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9711 | done |
| 9712 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9713 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9714 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9715 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 9716 | $as_echo_n "checking for getpagesize... " >&6; } |
| 9717 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9718 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9719 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9720 | #include <unistd.h> |
| 9721 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9722 | int |
| 9723 | main () |
| 9724 | { |
| 9725 | void* p = getpagesize |
| 9726 | ; |
| 9727 | return 0; |
| 9728 | } |
| 9729 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9730 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9731 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9732 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9733 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9735 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9736 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9737 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9738 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9739 | |
| 9740 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9741 | 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] | 9742 | |
Antoine Pitrou | 6f26be0 | 2011-05-03 18:18:59 +0200 | [diff] [blame] | 9743 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mallopt can set malloc mmap threshold" >&5 |
| 9744 | $as_echo_n "checking whether mallopt can set malloc mmap threshold... " >&6; } |
| 9745 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9746 | /* end confdefs.h. */ |
| 9747 | |
| 9748 | #include <malloc.h> |
| 9749 | |
| 9750 | int |
| 9751 | main () |
| 9752 | { |
| 9753 | mallopt(M_MMAP_THRESHOLD, 256 * 1024) |
| 9754 | ; |
| 9755 | return 0; |
| 9756 | } |
| 9757 | _ACEOF |
| 9758 | if ac_fn_c_try_compile "$LINENO"; then : |
| 9759 | |
| 9760 | $as_echo "#define HAVE_MALLOPT_MMAP_THRESHOLD 1" >>confdefs.h |
| 9761 | |
| 9762 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9763 | $as_echo "yes" >&6; } |
| 9764 | else |
| 9765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9766 | $as_echo "no" >&6; } |
| 9767 | |
| 9768 | fi |
| 9769 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9770 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9771 | for ac_prog in true |
| 9772 | do |
| 9773 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 9774 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9775 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9776 | $as_echo_n "checking for $ac_word... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9777 | if test "${ac_cv_prog_TRUE+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9778 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9779 | else |
| 9780 | if test -n "$TRUE"; then |
| 9781 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 9782 | else |
| 9783 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9784 | for as_dir in $PATH |
| 9785 | do |
| 9786 | IFS=$as_save_IFS |
| 9787 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9788 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9789 | 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] | 9790 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9791 | $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] | 9792 | break 2 |
| 9793 | fi |
| 9794 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9795 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9796 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9797 | |
| 9798 | fi |
| 9799 | fi |
| 9800 | TRUE=$ac_cv_prog_TRUE |
| 9801 | if test -n "$TRUE"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9802 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 9803 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9804 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9805 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9806 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9807 | fi |
| 9808 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9809 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9810 | test -n "$TRUE" && break |
| 9811 | done |
| 9812 | test -n "$TRUE" || TRUE="/bin/true" |
| 9813 | |
| 9814 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 9816 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9817 | if test "${ac_cv_lib_c_inet_aton+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9818 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9819 | else |
| 9820 | ac_check_lib_save_LIBS=$LIBS |
| 9821 | LIBS="-lc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9822 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9823 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9824 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9825 | /* Override any GCC internal prototype to avoid an error. |
| 9826 | Use char because int might match the return type of a GCC |
| 9827 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9828 | #ifdef __cplusplus |
| 9829 | extern "C" |
| 9830 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9831 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9832 | int |
| 9833 | main () |
| 9834 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9835 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9836 | ; |
| 9837 | return 0; |
| 9838 | } |
| 9839 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9840 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9841 | ac_cv_lib_c_inet_aton=yes |
| 9842 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9843 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9844 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9845 | rm -f core conftest.err conftest.$ac_objext \ |
| 9846 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9847 | LIBS=$ac_check_lib_save_LIBS |
| 9848 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9849 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 9850 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9851 | 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] | 9852 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9853 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9854 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 9855 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9856 | if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9857 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9858 | else |
| 9859 | ac_check_lib_save_LIBS=$LIBS |
| 9860 | LIBS="-lresolv $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9861 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9862 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9863 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9864 | /* Override any GCC internal prototype to avoid an error. |
| 9865 | Use char because int might match the return type of a GCC |
| 9866 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9867 | #ifdef __cplusplus |
| 9868 | extern "C" |
| 9869 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9870 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9871 | int |
| 9872 | main () |
| 9873 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9874 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9875 | ; |
| 9876 | return 0; |
| 9877 | } |
| 9878 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9879 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9880 | ac_cv_lib_resolv_inet_aton=yes |
| 9881 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9882 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9883 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9884 | rm -f core conftest.err conftest.$ac_objext \ |
| 9885 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9886 | LIBS=$ac_check_lib_save_LIBS |
| 9887 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9888 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 9889 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9890 | 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] | 9891 | cat >>confdefs.h <<_ACEOF |
| 9892 | #define HAVE_LIBRESOLV 1 |
| 9893 | _ACEOF |
| 9894 | |
| 9895 | LIBS="-lresolv $LIBS" |
| 9896 | |
| 9897 | fi |
| 9898 | |
| 9899 | |
| 9900 | fi |
| 9901 | |
| 9902 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9903 | # On Tru64, chflags seems to be present, but calling it will |
| 9904 | # exit Python |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 9906 | $as_echo_n "checking for chflags... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9907 | if test "${ac_cv_have_chflags+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9908 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9909 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9910 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9911 | ac_cv_have_chflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9912 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9913 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9914 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9915 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9916 | #include <sys/stat.h> |
| 9917 | #include <unistd.h> |
| 9918 | int main(int argc, char*argv[]) |
| 9919 | { |
| 9920 | if(chflags(argv[0], 0) != 0) |
| 9921 | return 1; |
| 9922 | return 0; |
| 9923 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9924 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9925 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9926 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9927 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9928 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9929 | ac_cv_have_chflags=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9930 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9931 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9932 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 9933 | fi |
| 9934 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9935 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9936 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 9938 | $as_echo "$ac_cv_have_chflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9939 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9940 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9941 | if test "x$ac_cv_func_chflags" = x""yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9942 | ac_cv_have_chflags="yes" |
| 9943 | else |
| 9944 | ac_cv_have_chflags="no" |
| 9945 | fi |
| 9946 | |
| 9947 | fi |
| 9948 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9949 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9950 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9951 | |
| 9952 | fi |
| 9953 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9954 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 9955 | $as_echo_n "checking for lchflags... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9956 | if test "${ac_cv_have_lchflags+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9957 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9958 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9959 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9960 | ac_cv_have_lchflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9961 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9963 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9964 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9965 | #include <sys/stat.h> |
| 9966 | #include <unistd.h> |
| 9967 | int main(int argc, char*argv[]) |
| 9968 | { |
| 9969 | if(lchflags(argv[0], 0) != 0) |
| 9970 | return 1; |
| 9971 | return 0; |
| 9972 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9973 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9974 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9975 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9976 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9977 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9978 | ac_cv_have_lchflags=no |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9979 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9980 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9981 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9982 | fi |
| 9983 | |
| 9984 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9985 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9986 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 9987 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9988 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9989 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 9990 | if test "x$ac_cv_func_lchflags" = x""yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9991 | ac_cv_have_lchflags="yes" |
| 9992 | else |
| 9993 | ac_cv_have_lchflags="no" |
| 9994 | fi |
| 9995 | |
| 9996 | fi |
| 9997 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9998 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9999 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10000 | |
| 10001 | fi |
| 10002 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10003 | case $ac_sys_system/$ac_sys_release in |
| 10004 | Darwin/*) |
| 10005 | _CUR_CFLAGS="${CFLAGS}" |
| 10006 | _CUR_LDFLAGS="${LDFLAGS}" |
| 10007 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 10008 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 10009 | ;; |
| 10010 | esac |
| 10011 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10012 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 10013 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10014 | if test "${ac_cv_lib_z_inflateCopy+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10015 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10016 | else |
| 10017 | ac_check_lib_save_LIBS=$LIBS |
| 10018 | LIBS="-lz $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10019 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10020 | /* end confdefs.h. */ |
| 10021 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10022 | /* Override any GCC internal prototype to avoid an error. |
| 10023 | Use char because int might match the return type of a GCC |
| 10024 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10025 | #ifdef __cplusplus |
| 10026 | extern "C" |
| 10027 | #endif |
| 10028 | char inflateCopy (); |
| 10029 | int |
| 10030 | main () |
| 10031 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10032 | return inflateCopy (); |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10033 | ; |
| 10034 | return 0; |
| 10035 | } |
| 10036 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10037 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10038 | ac_cv_lib_z_inflateCopy=yes |
| 10039 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10040 | ac_cv_lib_z_inflateCopy=no |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10041 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10042 | rm -f core conftest.err conftest.$ac_objext \ |
| 10043 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10044 | LIBS=$ac_check_lib_save_LIBS |
| 10045 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 10047 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10048 | if test "x$ac_cv_lib_z_inflateCopy" = x""yes; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10049 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10050 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10051 | |
| 10052 | fi |
| 10053 | |
| 10054 | |
| 10055 | case $ac_sys_system/$ac_sys_release in |
| 10056 | Darwin/*) |
| 10057 | CFLAGS="${_CUR_CFLAGS}" |
| 10058 | LDFLAGS="${_CUR_LDFLAGS}" |
| 10059 | ;; |
| 10060 | esac |
| 10061 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 10063 | $as_echo_n "checking for hstrerror... " >&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 | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10067 | #include <netdb.h> |
| 10068 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10069 | int |
| 10070 | main () |
| 10071 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10072 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10073 | ; |
| 10074 | return 0; |
| 10075 | } |
| 10076 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10077 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10078 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10079 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10080 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10081 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10082 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10083 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10084 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10085 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10086 | |
| 10087 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10088 | rm -f core conftest.err conftest.$ac_objext \ |
| 10089 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10090 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10091 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 10092 | $as_echo_n "checking for inet_aton... " >&6; } |
| 10093 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10094 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10095 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 10096 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10097 | #include <sys/socket.h> |
| 10098 | #include <netinet/in.h> |
| 10099 | #include <arpa/inet.h> |
| 10100 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10101 | int |
| 10102 | main () |
| 10103 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10104 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10105 | ; |
| 10106 | return 0; |
| 10107 | } |
| 10108 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10109 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10110 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10111 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10112 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10114 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10115 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10116 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10117 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10118 | |
| 10119 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10120 | rm -f core conftest.err conftest.$ac_objext \ |
| 10121 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10122 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10123 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 10124 | $as_echo_n "checking for inet_pton... " >&6; } |
| 10125 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10126 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10127 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10128 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10129 | #include <sys/socket.h> |
| 10130 | #include <netinet/in.h> |
| 10131 | #include <arpa/inet.h> |
| 10132 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10133 | int |
| 10134 | main () |
| 10135 | { |
| 10136 | void* p = inet_pton |
| 10137 | ; |
| 10138 | return 0; |
| 10139 | } |
| 10140 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10141 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10142 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10143 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10144 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10146 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10147 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10148 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10149 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10150 | |
| 10151 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10152 | 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] | 10153 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10154 | # 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] | 10155 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 10156 | $as_echo_n "checking for setgroups... " >&6; } |
| 10157 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10158 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10159 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10160 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10161 | #ifdef HAVE_GRP_H |
| 10162 | #include <grp.h> |
| 10163 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10164 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10165 | int |
| 10166 | main () |
| 10167 | { |
| 10168 | void* p = setgroups |
| 10169 | ; |
| 10170 | return 0; |
| 10171 | } |
| 10172 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10173 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10174 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10175 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10176 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10178 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10179 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10180 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10181 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10182 | |
| 10183 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10184 | 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] | 10185 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10186 | # check for openpty and forkpty |
| 10187 | |
| 10188 | for ac_func in openpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10189 | do : |
| 10190 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10191 | if test "x$ac_cv_func_openpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10192 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10193 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10194 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10195 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10196 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 10198 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10199 | if test "${ac_cv_lib_util_openpty+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10200 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10201 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10202 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10203 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10204 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10205 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10206 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10207 | /* Override any GCC internal prototype to avoid an error. |
| 10208 | Use char because int might match the return type of a GCC |
| 10209 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10210 | #ifdef __cplusplus |
| 10211 | extern "C" |
| 10212 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10213 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10214 | int |
| 10215 | main () |
| 10216 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10217 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10218 | ; |
| 10219 | return 0; |
| 10220 | } |
| 10221 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10222 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10223 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10224 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10225 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10226 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10227 | rm -f core conftest.err conftest.$ac_objext \ |
| 10228 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10229 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10230 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 10232 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10233 | if test "x$ac_cv_lib_util_openpty" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10234 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10235 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10236 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10237 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 10238 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10239 | if test "${ac_cv_lib_bsd_openpty+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10240 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10241 | else |
| 10242 | ac_check_lib_save_LIBS=$LIBS |
| 10243 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10244 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10245 | /* end confdefs.h. */ |
| 10246 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10247 | /* Override any GCC internal prototype to avoid an error. |
| 10248 | Use char because int might match the return type of a GCC |
| 10249 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10250 | #ifdef __cplusplus |
| 10251 | extern "C" |
| 10252 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10253 | char openpty (); |
| 10254 | int |
| 10255 | main () |
| 10256 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10257 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10258 | ; |
| 10259 | return 0; |
| 10260 | } |
| 10261 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10262 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10263 | ac_cv_lib_bsd_openpty=yes |
| 10264 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10265 | ac_cv_lib_bsd_openpty=no |
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 | rm -f core conftest.err conftest.$ac_objext \ |
| 10268 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10269 | LIBS=$ac_check_lib_save_LIBS |
| 10270 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 10272 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10273 | if test "x$ac_cv_lib_bsd_openpty" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10274 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10275 | LIBS="$LIBS -lbsd" |
| 10276 | fi |
| 10277 | |
| 10278 | |
| 10279 | fi |
| 10280 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10281 | |
| 10282 | fi |
| 10283 | done |
| 10284 | |
| 10285 | for ac_func in forkpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10286 | do : |
| 10287 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10288 | if test "x$ac_cv_func_forkpty" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10289 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10290 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10291 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10292 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10293 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10294 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 10295 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10296 | if test "${ac_cv_lib_util_forkpty+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10297 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10298 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10299 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10300 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10301 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10302 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10303 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10304 | /* Override any GCC internal prototype to avoid an error. |
| 10305 | Use char because int might match the return type of a GCC |
| 10306 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10307 | #ifdef __cplusplus |
| 10308 | extern "C" |
| 10309 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10310 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10311 | int |
| 10312 | main () |
| 10313 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10314 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10315 | ; |
| 10316 | return 0; |
| 10317 | } |
| 10318 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10319 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10320 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10321 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10322 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10323 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10324 | rm -f core conftest.err conftest.$ac_objext \ |
| 10325 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10326 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10327 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10328 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 10329 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10330 | if test "x$ac_cv_lib_util_forkpty" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10331 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10332 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10333 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10334 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 10335 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10336 | if test "${ac_cv_lib_bsd_forkpty+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10337 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10338 | else |
| 10339 | ac_check_lib_save_LIBS=$LIBS |
| 10340 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10341 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10342 | /* end confdefs.h. */ |
| 10343 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10344 | /* Override any GCC internal prototype to avoid an error. |
| 10345 | Use char because int might match the return type of a GCC |
| 10346 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10347 | #ifdef __cplusplus |
| 10348 | extern "C" |
| 10349 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10350 | char forkpty (); |
| 10351 | int |
| 10352 | main () |
| 10353 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10354 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10355 | ; |
| 10356 | return 0; |
| 10357 | } |
| 10358 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10359 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10360 | ac_cv_lib_bsd_forkpty=yes |
| 10361 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10362 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10363 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10364 | rm -f core conftest.err conftest.$ac_objext \ |
| 10365 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10366 | LIBS=$ac_check_lib_save_LIBS |
| 10367 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10368 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 10369 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10370 | if test "x$ac_cv_lib_bsd_forkpty" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10371 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10372 | LIBS="$LIBS -lbsd" |
| 10373 | fi |
| 10374 | |
| 10375 | |
| 10376 | fi |
| 10377 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10378 | |
| 10379 | fi |
| 10380 | done |
| 10381 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10382 | |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10383 | # Stuff for expat. |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10384 | for ac_func in memmove |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10385 | do : |
| 10386 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10387 | if test "x$ac_cv_func_memmove" = x""yes; then : |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10388 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10389 | #define HAVE_MEMMOVE 1 |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10390 | _ACEOF |
| 10391 | |
| 10392 | fi |
| 10393 | done |
| 10394 | |
| 10395 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10396 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10397 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10398 | do : |
| 10399 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10400 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 10401 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10402 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10403 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10404 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10405 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10406 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10407 | done |
| 10408 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10409 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 10410 | ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2" |
| 10411 | if test "x$ac_cv_func_dup2" = x""yes; then : |
| 10412 | $as_echo "#define HAVE_DUP2 1" >>confdefs.h |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10413 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10414 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10415 | case " $LIBOBJS " in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 10416 | *" dup2.$ac_objext "* ) ;; |
| 10417 | *) LIBOBJS="$LIBOBJS dup2.$ac_objext" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10418 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10419 | esac |
| 10420 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10421 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 10422 | |
| 10423 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" |
| 10424 | if test "x$ac_cv_func_getcwd" = x""yes; then : |
| 10425 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h |
| 10426 | |
| 10427 | else |
| 10428 | case " $LIBOBJS " in |
| 10429 | *" getcwd.$ac_objext "* ) ;; |
| 10430 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
| 10431 | ;; |
| 10432 | esac |
| 10433 | |
| 10434 | fi |
| 10435 | |
| 10436 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" |
| 10437 | if test "x$ac_cv_func_strdup" = x""yes; then : |
| 10438 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h |
| 10439 | |
| 10440 | else |
| 10441 | case " $LIBOBJS " in |
| 10442 | *" strdup.$ac_objext "* ) ;; |
| 10443 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" |
| 10444 | ;; |
| 10445 | esac |
| 10446 | |
| 10447 | fi |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10448 | |
| 10449 | |
| 10450 | for ac_func in getpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10451 | do : |
| 10452 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10453 | if test "x$ac_cv_func_getpgrp" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10454 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10455 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10456 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10457 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10458 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10459 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10460 | int |
| 10461 | main () |
| 10462 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10463 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10464 | ; |
| 10465 | return 0; |
| 10466 | } |
| 10467 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10468 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10469 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10470 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10471 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10472 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10473 | 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] | 10474 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10475 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10476 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10477 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10478 | for ac_func in setpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10479 | do : |
| 10480 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10481 | if test "x$ac_cv_func_setpgrp" = x""yes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10482 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10483 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10484 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10485 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10486 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10487 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10488 | int |
| 10489 | main () |
| 10490 | { |
| 10491 | setpgrp(0,0); |
| 10492 | ; |
| 10493 | return 0; |
| 10494 | } |
| 10495 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10496 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10497 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10498 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10499 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10500 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10501 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10502 | |
| 10503 | fi |
| 10504 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10505 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10506 | for ac_func in gettimeofday |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10507 | do : |
| 10508 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10509 | if test "x$ac_cv_func_gettimeofday" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10510 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10511 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10512 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10513 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10514 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10515 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10516 | int |
| 10517 | main () |
| 10518 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10519 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10520 | ; |
| 10521 | return 0; |
| 10522 | } |
| 10523 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10524 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10525 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10526 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10527 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10528 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10529 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10530 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10531 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10532 | 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] | 10533 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10534 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10535 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10536 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10537 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10538 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 10539 | $as_echo_n "checking for major... " >&6; } |
| 10540 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10541 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10542 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 10543 | #if defined(MAJOR_IN_MKDEV) |
| 10544 | #include <sys/mkdev.h> |
| 10545 | #elif defined(MAJOR_IN_SYSMACROS) |
| 10546 | #include <sys/sysmacros.h> |
| 10547 | #else |
| 10548 | #include <sys/types.h> |
| 10549 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10550 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10551 | int |
| 10552 | main () |
| 10553 | { |
| 10554 | |
| 10555 | makedev(major(0),minor(0)); |
| 10556 | |
| 10557 | ; |
| 10558 | return 0; |
| 10559 | } |
| 10560 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10561 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10562 | |
| 10563 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10564 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10565 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10566 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10567 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10568 | |
| 10569 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10570 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10572 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10573 | |
| 10574 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10575 | rm -f core conftest.err conftest.$ac_objext \ |
| 10576 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10577 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10578 | # 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] | 10579 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10580 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 10581 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 10582 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10583 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10584 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10585 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10586 | #include <sys/socket.h> |
| 10587 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10588 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10589 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10590 | int |
| 10591 | main () |
| 10592 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10593 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10594 | ; |
| 10595 | return 0; |
| 10596 | } |
| 10597 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10598 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10599 | have_getaddrinfo=yes |
| 10600 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10601 | have_getaddrinfo=no |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10602 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10603 | rm -f core conftest.err conftest.$ac_objext \ |
| 10604 | conftest$ac_exeext conftest.$ac_ext |
| 10605 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 10606 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10607 | if test $have_getaddrinfo = yes |
| 10608 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 10610 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10611 | if test "${ac_cv_buggy_getaddrinfo+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10612 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10613 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10614 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10615 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10616 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10617 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10618 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10619 | |
| 10620 | #include <sys/types.h> |
| 10621 | #include <netdb.h> |
| 10622 | #include <string.h> |
| 10623 | #include <sys/socket.h> |
| 10624 | #include <netinet/in.h> |
| 10625 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10626 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10627 | { |
| 10628 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 10629 | struct addrinfo hints, *ai, *aitop; |
| 10630 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 10631 | |
| 10632 | for (passive = 0; passive <= 1; passive++) { |
| 10633 | memset(&hints, 0, sizeof(hints)); |
| 10634 | hints.ai_family = AF_UNSPEC; |
| 10635 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 10636 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 10637 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10638 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 10639 | (void)gai_strerror(gaierr); |
| 10640 | goto bad; |
| 10641 | } |
| 10642 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 10643 | if (ai->ai_addr == NULL || |
| 10644 | ai->ai_addrlen == 0 || |
| 10645 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 10646 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 10647 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 10648 | goto bad; |
| 10649 | } |
| 10650 | switch (ai->ai_family) { |
| 10651 | case AF_INET: |
| 10652 | if (strcmp(strport, "54321") != 0) { |
| 10653 | goto bad; |
| 10654 | } |
| 10655 | if (passive) { |
| 10656 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 10657 | goto bad; |
| 10658 | } |
| 10659 | } else { |
| 10660 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 10661 | goto bad; |
| 10662 | } |
| 10663 | } |
| 10664 | inet4++; |
| 10665 | break; |
| 10666 | case AF_INET6: |
| 10667 | if (strcmp(strport, "54321") != 0) { |
| 10668 | goto bad; |
| 10669 | } |
| 10670 | if (passive) { |
| 10671 | if (strcmp(straddr, "::") != 0) { |
| 10672 | goto bad; |
| 10673 | } |
| 10674 | } else { |
| 10675 | if (strcmp(straddr, "::1") != 0) { |
| 10676 | goto bad; |
| 10677 | } |
| 10678 | } |
| 10679 | inet6++; |
| 10680 | break; |
| 10681 | case AF_UNSPEC: |
| 10682 | goto bad; |
| 10683 | break; |
| 10684 | default: |
| 10685 | /* another family support? */ |
| 10686 | break; |
| 10687 | } |
| 10688 | } |
| 10689 | } |
| 10690 | |
| 10691 | if (!(inet4 == 0 || inet4 == 2)) |
| 10692 | goto bad; |
| 10693 | if (!(inet6 == 0 || inet6 == 2)) |
| 10694 | goto bad; |
| 10695 | |
| 10696 | if (aitop) |
| 10697 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10698 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10699 | |
| 10700 | bad: |
| 10701 | if (aitop) |
| 10702 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10703 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10704 | } |
| 10705 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10706 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10707 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10708 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10709 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10710 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10711 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10712 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10713 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10714 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10715 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10716 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10717 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10718 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10719 | |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 10720 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5 |
| 10721 | $as_echo "$ac_cv_buggy_getaddrinfo" >&6; } |
| 10722 | |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 10723 | if test $have_getaddrinfo = no -o "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10724 | then |
| 10725 | if test $ipv6 = yes |
| 10726 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10727 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 10728 | echo ' or you can specify "--disable-ipv6"'. |
| 10729 | exit 1 |
| 10730 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10731 | else |
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 HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10734 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10735 | fi |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 10736 | |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 10737 | for ac_func in getnameinfo |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10738 | do : |
| 10739 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10740 | if test "x$ac_cv_func_getnameinfo" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10741 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10742 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10743 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10744 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10745 | fi |
| 10746 | done |
| 10747 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10748 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10749 | # checks for structures |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 10751 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10752 | if test "${ac_cv_header_time+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10753 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10754 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10756 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10757 | #include <sys/types.h> |
| 10758 | #include <sys/time.h> |
| 10759 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10760 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10761 | int |
| 10762 | main () |
| 10763 | { |
| 10764 | if ((struct tm *) 0) |
| 10765 | return 0; |
| 10766 | ; |
| 10767 | return 0; |
| 10768 | } |
| 10769 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10770 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10771 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10772 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10773 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10774 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10775 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10776 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10777 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 10778 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10779 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10780 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10781 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10782 | |
| 10783 | fi |
| 10784 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 10786 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10787 | if test "${ac_cv_struct_tm+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10788 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10789 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10790 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10791 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10792 | #include <sys/types.h> |
| 10793 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10794 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10795 | int |
| 10796 | main () |
| 10797 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10798 | struct tm tm; |
| 10799 | int *p = &tm.tm_sec; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10800 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10801 | ; |
| 10802 | return 0; |
| 10803 | } |
| 10804 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10805 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10806 | ac_cv_struct_tm=time.h |
| 10807 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10808 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10809 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10810 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10811 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10812 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
| 10813 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10814 | if test $ac_cv_struct_tm = sys/time.h; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10815 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10816 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10817 | |
| 10818 | fi |
| 10819 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10820 | 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] | 10821 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10822 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10823 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10824 | 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] | 10825 | |
| 10826 | cat >>confdefs.h <<_ACEOF |
| 10827 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 10828 | _ACEOF |
| 10829 | |
| 10830 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10831 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10832 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10833 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 10834 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10835 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10836 | |
| 10837 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10838 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 10839 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10840 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10841 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10842 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10843 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10844 | fi |
| 10845 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10846 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10847 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10848 | _ACEOF |
| 10849 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10850 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 10851 | $as_echo_n "checking for tzname... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10852 | if test "${ac_cv_var_tzname+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10853 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10854 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10855 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10856 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10857 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10858 | #if !HAVE_DECL_TZNAME |
| 10859 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10860 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10861 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10862 | int |
| 10863 | main () |
| 10864 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10865 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10866 | ; |
| 10867 | return 0; |
| 10868 | } |
| 10869 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10870 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10871 | ac_cv_var_tzname=yes |
| 10872 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10873 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10874 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10875 | rm -f core conftest.err conftest.$ac_objext \ |
| 10876 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10877 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10878 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 10879 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10880 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10881 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10882 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10883 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10884 | fi |
| 10885 | fi |
| 10886 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10887 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10888 | 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] | 10889 | |
| 10890 | cat >>confdefs.h <<_ACEOF |
| 10891 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 10892 | _ACEOF |
| 10893 | |
| 10894 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10895 | fi |
| 10896 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10897 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10898 | 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] | 10899 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10900 | cat >>confdefs.h <<_ACEOF |
| 10901 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 10902 | _ACEOF |
| 10903 | |
| 10904 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10905 | fi |
| 10906 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10907 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10908 | 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] | 10909 | |
| 10910 | cat >>confdefs.h <<_ACEOF |
| 10911 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 10912 | _ACEOF |
| 10913 | |
| 10914 | |
| 10915 | fi |
| 10916 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10917 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10918 | 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] | 10919 | |
| 10920 | cat >>confdefs.h <<_ACEOF |
| 10921 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 10922 | _ACEOF |
| 10923 | |
| 10924 | |
| 10925 | fi |
| 10926 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10927 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10928 | 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] | 10929 | |
| 10930 | cat >>confdefs.h <<_ACEOF |
| 10931 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 10932 | _ACEOF |
| 10933 | |
| 10934 | |
| 10935 | fi |
| 10936 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10937 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10938 | 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] | 10939 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10940 | cat >>confdefs.h <<_ACEOF |
| 10941 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 10942 | _ACEOF |
| 10943 | |
| 10944 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10945 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10946 | |
| 10947 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10948 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10949 | *" fileblocks.$ac_objext "* ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10950 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 10951 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10952 | esac |
| 10953 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10954 | fi |
| 10955 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10956 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10957 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 10959 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 10960 | if test "${ac_cv_header_time_altzone+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10961 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10962 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10963 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10964 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10965 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10966 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10967 | int |
| 10968 | main () |
| 10969 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10970 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10971 | ; |
| 10972 | return 0; |
| 10973 | } |
| 10974 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10975 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10976 | ac_cv_header_time_altzone=yes |
| 10977 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10978 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10979 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10980 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10981 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10982 | fi |
| 10983 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 10985 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10986 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10987 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10988 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10989 | |
| 10990 | fi |
| 10991 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 10992 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10993 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 10994 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 10995 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10996 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10997 | |
| 10998 | #include <sys/types.h> |
| 10999 | #include <sys/select.h> |
| 11000 | #include <sys/time.h> |
| 11001 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11002 | int |
| 11003 | main () |
| 11004 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11005 | ; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11006 | ; |
| 11007 | return 0; |
| 11008 | } |
| 11009 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11010 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11011 | |
| 11012 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11013 | $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] | 11014 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11015 | was_it_defined=yes |
| 11016 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11017 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11018 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11019 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 11020 | $as_echo "$was_it_defined" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11021 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11022 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 11023 | $as_echo_n "checking for addrinfo... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11024 | if test "${ac_cv_struct_addrinfo+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11025 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11026 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11027 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11028 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11029 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11030 | int |
| 11031 | main () |
| 11032 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11033 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11034 | ; |
| 11035 | return 0; |
| 11036 | } |
| 11037 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11038 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11039 | ac_cv_struct_addrinfo=yes |
| 11040 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11041 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11042 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11043 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11044 | fi |
| 11045 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 11047 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11048 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11049 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11050 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11051 | |
| 11052 | fi |
| 11053 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11054 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 11055 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11056 | if test "${ac_cv_struct_sockaddr_storage+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11057 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11058 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11059 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11060 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11061 | |
| 11062 | # include <sys/types.h> |
| 11063 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11064 | int |
| 11065 | main () |
| 11066 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11067 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11068 | ; |
| 11069 | return 0; |
| 11070 | } |
| 11071 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11072 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11073 | ac_cv_struct_sockaddr_storage=yes |
| 11074 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11075 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11076 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11077 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11078 | fi |
| 11079 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11080 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 11081 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11082 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11083 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11084 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11085 | |
| 11086 | fi |
| 11087 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11088 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11089 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11090 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 11091 | $as_echo_n "checking whether char is unsigned... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11092 | if test "${ac_cv_c_char_unsigned+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11093 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11094 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11095 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11096 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11097 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11098 | int |
| 11099 | main () |
| 11100 | { |
| 11101 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
| 11102 | test_array [0] = 0 |
| 11103 | |
| 11104 | ; |
| 11105 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11106 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11107 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11108 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11109 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11110 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11111 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11112 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11113 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11114 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11115 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 11116 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11117 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11118 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11119 | |
| 11120 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11121 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11122 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 11123 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11124 | if test "${ac_cv_c_const+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11125 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11126 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11127 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11128 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11129 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11130 | int |
| 11131 | main () |
| 11132 | { |
| 11133 | /* FIXME: Include the comments suggested by Paul. */ |
| 11134 | #ifndef __cplusplus |
| 11135 | /* Ultrix mips cc rejects this. */ |
| 11136 | typedef int charset[2]; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11137 | const charset cs; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11138 | /* SunOS 4.1.1 cc rejects this. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11139 | char const *const *pcpcc; |
| 11140 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11141 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 11142 | struct point {int x, y;}; |
| 11143 | static struct point const zero = {0,0}; |
| 11144 | /* AIX XL C 1.02.0.0 rejects this. |
| 11145 | It does not let you subtract one const X* pointer from another in |
| 11146 | an arm of an if-expression whose if-part is not a constant |
| 11147 | expression */ |
| 11148 | const char *g = "string"; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11149 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11150 | /* HPUX 7.0 cc rejects these. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11151 | ++pcpcc; |
| 11152 | ppc = (char**) pcpcc; |
| 11153 | pcpcc = (char const *const *) ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11154 | { /* SCO 3.2v4 cc rejects this. */ |
| 11155 | char *t; |
| 11156 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11157 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11158 | *t++ = 0; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11159 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11160 | } |
| 11161 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 11162 | int x[] = {25, 17}; |
| 11163 | const int *foo = &x[0]; |
| 11164 | ++foo; |
| 11165 | } |
| 11166 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 11167 | typedef const int *iptr; |
| 11168 | iptr p = 0; |
| 11169 | ++p; |
| 11170 | } |
| 11171 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 11172 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 11173 | struct s { int j; const int *ap[3]; }; |
| 11174 | struct s *b; b->j = 5; |
| 11175 | } |
| 11176 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 11177 | const int foo = 10; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11178 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11179 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11180 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11181 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11182 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11183 | ; |
| 11184 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11185 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11186 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11187 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11188 | ac_cv_c_const=yes |
| 11189 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11190 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +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 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11193 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 11195 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11196 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11197 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11198 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11199 | |
| 11200 | fi |
| 11201 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11202 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11203 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11204 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 11205 | $as_echo_n "checking for working volatile... " >&6; } |
| 11206 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11207 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11208 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11209 | int |
| 11210 | main () |
| 11211 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11212 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11213 | ; |
| 11214 | return 0; |
| 11215 | } |
| 11216 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11217 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11218 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11219 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11220 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11221 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11222 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11223 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11224 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11225 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11226 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11227 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11228 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11229 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11230 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 11231 | $as_echo_n "checking for working signed char... " >&6; } |
| 11232 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11233 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11234 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11235 | int |
| 11236 | main () |
| 11237 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11238 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11239 | ; |
| 11240 | return 0; |
| 11241 | } |
| 11242 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11243 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11244 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11245 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11246 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11247 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11248 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11249 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11250 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11251 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11252 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11253 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11254 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11255 | have_prototypes=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11256 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 11257 | $as_echo_n "checking for prototypes... " >&6; } |
| 11258 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11259 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11260 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11261 | int |
| 11262 | main () |
| 11263 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11264 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11265 | ; |
| 11266 | return 0; |
| 11267 | } |
| 11268 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11269 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11270 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11271 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11272 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11273 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11274 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11275 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11276 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 11277 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11278 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11279 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 11281 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 11282 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11283 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11284 | |
| 11285 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11286 | int foo(int x, ...) { |
| 11287 | va_list va; |
| 11288 | va_start(va, x); |
| 11289 | va_arg(va, int); |
| 11290 | va_arg(va, char *); |
| 11291 | va_arg(va, double); |
| 11292 | return 0; |
| 11293 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11294 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11295 | int |
| 11296 | main () |
| 11297 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11298 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11299 | ; |
| 11300 | return 0; |
| 11301 | } |
| 11302 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11303 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11304 | |
| 11305 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11306 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11307 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11308 | works=yes |
| 11309 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11310 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11311 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11313 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11314 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11315 | # check for socketpair |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11316 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 11317 | $as_echo_n "checking for socketpair... " >&6; } |
| 11318 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11319 | /* end confdefs.h. */ |
| 11320 | |
| 11321 | #include <sys/types.h> |
| 11322 | #include <sys/socket.h> |
| 11323 | |
| 11324 | int |
| 11325 | main () |
| 11326 | { |
| 11327 | void *x=socketpair |
| 11328 | ; |
| 11329 | return 0; |
| 11330 | } |
| 11331 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11332 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11333 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11334 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11335 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11337 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11338 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11340 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11341 | |
| 11342 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11343 | 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] | 11344 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11345 | # check if sockaddr has sa_len member |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11346 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 11347 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 11348 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11349 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11350 | #include <sys/types.h> |
| 11351 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11352 | int |
| 11353 | main () |
| 11354 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11355 | struct sockaddr x; |
| 11356 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11357 | ; |
| 11358 | return 0; |
| 11359 | } |
| 11360 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11361 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11362 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11363 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11364 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11365 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11366 | |
| 11367 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11368 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11369 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11370 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11371 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11372 | 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] | 11373 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11374 | va_list_is_array=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11375 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 11376 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 11377 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11378 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11379 | |
| 11380 | #ifdef HAVE_STDARG_PROTOTYPES |
| 11381 | #include <stdarg.h> |
| 11382 | #else |
| 11383 | #include <varargs.h> |
| 11384 | #endif |
| 11385 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11386 | int |
| 11387 | main () |
| 11388 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11389 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11390 | ; |
| 11391 | return 0; |
| 11392 | } |
| 11393 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11394 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11395 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11396 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11397 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11398 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11399 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11400 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11401 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11402 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11403 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11404 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11405 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 11406 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11407 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11408 | # 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] | 11409 | |
| 11410 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11411 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11412 | 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] | 11413 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11414 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 11415 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11416 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 11417 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11418 | OLD_CFLAGS=$CFLAGS |
| 11419 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11420 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11421 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11422 | |
| 11423 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11424 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11425 | int |
| 11426 | main () |
| 11427 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11428 | |
| 11429 | char *name; |
| 11430 | struct hostent *he, *res; |
| 11431 | char buffer[2048]; |
| 11432 | int buflen = 2048; |
| 11433 | int h_errnop; |
| 11434 | |
| 11435 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11436 | |
| 11437 | ; |
| 11438 | return 0; |
| 11439 | } |
| 11440 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11441 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11442 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11443 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11444 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11445 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11446 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11447 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11448 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11449 | $as_echo "yes" >&6; } |
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 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11452 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11453 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11454 | $as_echo "no" >&6; } |
| 11455 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 11456 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 11457 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11458 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11459 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11460 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11461 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11462 | int |
| 11463 | main () |
| 11464 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11465 | |
| 11466 | char *name; |
| 11467 | struct hostent *he; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11468 | char buffer[2048]; |
| 11469 | int buflen = 2048; |
| 11470 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11471 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11472 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11473 | |
| 11474 | ; |
| 11475 | return 0; |
| 11476 | } |
| 11477 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11478 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11479 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11480 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11481 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11482 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11483 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11484 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11486 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11487 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11488 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11489 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11490 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11491 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11492 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 11493 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 11494 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11495 | /* end confdefs.h. */ |
| 11496 | |
| 11497 | # include <netdb.h> |
| 11498 | |
| 11499 | int |
| 11500 | main () |
| 11501 | { |
| 11502 | |
| 11503 | char *name; |
| 11504 | struct hostent *he; |
| 11505 | struct hostent_data data; |
| 11506 | |
| 11507 | (void) gethostbyname_r(name, he, &data); |
| 11508 | |
| 11509 | ; |
| 11510 | return 0; |
| 11511 | } |
| 11512 | _ACEOF |
| 11513 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11514 | |
| 11515 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 11516 | |
| 11517 | |
| 11518 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 11519 | |
| 11520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11521 | $as_echo "yes" >&6; } |
| 11522 | |
| 11523 | else |
| 11524 | |
| 11525 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11526 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11527 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11528 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11529 | 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] | 11530 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11531 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11532 | 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] | 11533 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11534 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11535 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11536 | CFLAGS=$OLD_CFLAGS |
| 11537 | |
| 11538 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11539 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11540 | for ac_func in gethostbyname |
| 11541 | do : |
| 11542 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11543 | if test "x$ac_cv_func_gethostbyname" = x""yes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11544 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11545 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11546 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11547 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11548 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11549 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11550 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11551 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11552 | fi |
| 11553 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11554 | |
| 11555 | |
| 11556 | |
| 11557 | |
| 11558 | |
| 11559 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11560 | # checks for system services |
| 11561 | # (none yet) |
| 11562 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11563 | # Linux requires this for correct f.p. operations |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11564 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11565 | if test "x$ac_cv_func___fpu_control" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11566 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11567 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11568 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 11569 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11570 | if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11571 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11572 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11573 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11574 | LIBS="-lieee $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11575 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11576 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11577 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11578 | /* Override any GCC internal prototype to avoid an error. |
| 11579 | Use char because int might match the return type of a GCC |
| 11580 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11581 | #ifdef __cplusplus |
| 11582 | extern "C" |
| 11583 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11584 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11585 | int |
| 11586 | main () |
| 11587 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11588 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11589 | ; |
| 11590 | return 0; |
| 11591 | } |
| 11592 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11593 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11594 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11595 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11596 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11597 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11598 | rm -f core conftest.err conftest.$ac_objext \ |
| 11599 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11600 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11601 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11602 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 11603 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11604 | 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] | 11605 | cat >>confdefs.h <<_ACEOF |
| 11606 | #define HAVE_LIBIEEE 1 |
| 11607 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11608 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11609 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11610 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11611 | fi |
| 11612 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11613 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11614 | fi |
| 11615 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11616 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11617 | # Check for --with-fpectl |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11618 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 11619 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11620 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11621 | # Check whether --with-fpectl was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11622 | if test "${with_fpectl+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11623 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11624 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11625 | then |
| 11626 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11627 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11628 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11630 | $as_echo "yes" >&6; } |
| 11631 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11632 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11633 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 11634 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11635 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11636 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11637 | fi |
| 11638 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11639 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11640 | # check for --with-libm=... |
| 11641 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11642 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 11643 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11644 | *) LIBM=-lm |
| 11645 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11646 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 11647 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11648 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11649 | # Check whether --with-libm was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11650 | if test "${with_libm+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11651 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11652 | if test "$withval" = no |
| 11653 | then LIBM= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11654 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 11655 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11656 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11657 | then LIBM=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11658 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 11659 | $as_echo "set LIBM=\"$withval\"" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 11660 | 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] | 11661 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11662 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11663 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 11664 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11665 | fi |
| 11666 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11667 | |
| 11668 | # check for --with-libc=... |
| 11669 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 11671 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11672 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11673 | # Check whether --with-libc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11674 | if test "${with_libc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11675 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11676 | if test "$withval" = no |
| 11677 | then LIBC= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11678 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 11679 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11680 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11681 | then LIBC=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11682 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 11683 | $as_echo "set LIBC=\"$withval\"" >&6; } |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 11684 | 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] | 11685 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11686 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11687 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 11688 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11689 | fi |
| 11690 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11691 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11692 | # ************************************************** |
| 11693 | # * Check for various properties of floating point * |
| 11694 | # ************************************************** |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11695 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 11697 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11698 | if test "${ac_cv_little_endian_double+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11699 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11700 | else |
| 11701 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11702 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11703 | ac_cv_little_endian_double=no |
| 11704 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11705 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11706 | /* end confdefs.h. */ |
| 11707 | |
| 11708 | #include <string.h> |
| 11709 | int main() { |
| 11710 | double x = 9006104071832581.0; |
| 11711 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 11712 | return 0; |
| 11713 | else |
| 11714 | return 1; |
| 11715 | } |
| 11716 | |
| 11717 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11718 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11719 | ac_cv_little_endian_double=yes |
| 11720 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11721 | ac_cv_little_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11722 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11723 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11724 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11725 | fi |
| 11726 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11727 | fi |
| 11728 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11729 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 11730 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11731 | if test "$ac_cv_little_endian_double" = yes |
| 11732 | then |
| 11733 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11734 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11735 | |
| 11736 | fi |
| 11737 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11738 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 11739 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11740 | if test "${ac_cv_big_endian_double+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11741 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11742 | else |
| 11743 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11744 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11745 | ac_cv_big_endian_double=no |
| 11746 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11747 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11748 | /* end confdefs.h. */ |
| 11749 | |
| 11750 | #include <string.h> |
| 11751 | int main() { |
| 11752 | double x = 9006104071832581.0; |
| 11753 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 11754 | return 0; |
| 11755 | else |
| 11756 | return 1; |
| 11757 | } |
| 11758 | |
| 11759 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11760 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11761 | ac_cv_big_endian_double=yes |
| 11762 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11763 | ac_cv_big_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11764 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11765 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11766 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11767 | fi |
| 11768 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11769 | fi |
| 11770 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11771 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 11772 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11773 | if test "$ac_cv_big_endian_double" = yes |
| 11774 | then |
| 11775 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11776 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11777 | |
| 11778 | fi |
| 11779 | |
| 11780 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 11781 | # While Python doesn't currently have full support for these platforms |
| 11782 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 11783 | # conversions work. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11784 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 11785 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11786 | if test "${ac_cv_mixed_endian_double+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11787 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11788 | else |
| 11789 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11790 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11791 | ac_cv_mixed_endian_double=no |
| 11792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11793 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11794 | /* end confdefs.h. */ |
| 11795 | |
| 11796 | #include <string.h> |
| 11797 | int main() { |
| 11798 | double x = 9006104071832581.0; |
| 11799 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 11800 | return 0; |
| 11801 | else |
| 11802 | return 1; |
| 11803 | } |
| 11804 | |
| 11805 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11806 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11807 | ac_cv_mixed_endian_double=yes |
| 11808 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11809 | ac_cv_mixed_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11810 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11811 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11812 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11813 | fi |
| 11814 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11815 | fi |
| 11816 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 11818 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11819 | if test "$ac_cv_mixed_endian_double" = yes |
| 11820 | then |
| 11821 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11822 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11823 | |
| 11824 | fi |
| 11825 | |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11826 | # The short float repr introduced in Python 3.1 requires the |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 11827 | # correctly-rounded string <-> double conversion functions from |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11828 | # 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] | 11829 | # 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] | 11830 | # 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] | 11831 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11832 | |
| 11833 | # This inline assembler syntax may also work for suncc and icc, |
| 11834 | # so we try it on all platforms. |
| 11835 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11836 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 11837 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 11838 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11839 | /* end confdefs.h. */ |
| 11840 | |
| 11841 | int |
| 11842 | main () |
| 11843 | { |
| 11844 | |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11845 | unsigned short cw; |
| 11846 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 11847 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11848 | |
| 11849 | ; |
| 11850 | return 0; |
| 11851 | } |
| 11852 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11853 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11854 | have_gcc_asm_for_x87=yes |
| 11855 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11856 | have_gcc_asm_for_x87=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11857 | fi |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11858 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11859 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 11860 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11861 | if test "$have_gcc_asm_for_x87" = yes |
| 11862 | then |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11863 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11864 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11865 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11866 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11867 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11868 | # Detect whether system arithmetic is subject to x87-style double |
| 11869 | # rounding issues. The result of this test has little meaning on non |
| 11870 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 11871 | # mode is round-to-nearest and double rounding issues are present, and |
| 11872 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11873 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 11874 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11875 | # $BASECFLAGS may affect the result |
| 11876 | ac_save_cc="$CC" |
| 11877 | CC="$CC $BASECFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11878 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11879 | ac_cv_x87_double_rounding=no |
| 11880 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11881 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11882 | /* end confdefs.h. */ |
| 11883 | |
| 11884 | #include <stdlib.h> |
| 11885 | #include <math.h> |
| 11886 | int main() { |
| 11887 | volatile double x, y, z; |
| 11888 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 11889 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 11890 | y = 1./x; |
| 11891 | if (y != 1.) |
| 11892 | exit(0); |
| 11893 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 11894 | x = 1e16; |
| 11895 | y = 2.99999; |
| 11896 | z = x + y; |
| 11897 | if (z != 1e16+4.) |
| 11898 | exit(0); |
| 11899 | /* both tests show evidence of double rounding */ |
| 11900 | exit(1); |
| 11901 | } |
| 11902 | |
| 11903 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11904 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11905 | ac_cv_x87_double_rounding=no |
| 11906 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11907 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11908 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11909 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11910 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11911 | fi |
| 11912 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11913 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11914 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 11915 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11916 | if test "$ac_cv_x87_double_rounding" = yes |
| 11917 | then |
| 11918 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11919 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11920 | |
| 11921 | fi |
| 11922 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11923 | # ************************************ |
| 11924 | # * Check for mathematical functions * |
| 11925 | # ************************************ |
| 11926 | |
| 11927 | LIBS_SAVE=$LIBS |
| 11928 | LIBS="$LIBS $LIBM" |
| 11929 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11930 | for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma |
| 11931 | do : |
| 11932 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11933 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 11934 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11935 | cat >>confdefs.h <<_ACEOF |
| 11936 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 11937 | _ACEOF |
| 11938 | |
| 11939 | fi |
| 11940 | done |
| 11941 | |
Victor Stinner | 8f9f8d6 | 2011-05-09 12:45:41 +0200 | [diff] [blame] | 11942 | for ac_func in hypot lgamma log1p log2 round tgamma |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11943 | do : |
| 11944 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11945 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 11946 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11947 | cat >>confdefs.h <<_ACEOF |
| 11948 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 11949 | _ACEOF |
| 11950 | |
| 11951 | fi |
| 11952 | done |
| 11953 | |
| 11954 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 11955 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11956 | if test "x$ac_cv_have_decl_isinf" = x""yes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11957 | ac_have_decl=1 |
| 11958 | else |
| 11959 | ac_have_decl=0 |
| 11960 | fi |
| 11961 | |
| 11962 | cat >>confdefs.h <<_ACEOF |
| 11963 | #define HAVE_DECL_ISINF $ac_have_decl |
| 11964 | _ACEOF |
| 11965 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 11966 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11967 | if test "x$ac_cv_have_decl_isnan" = x""yes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11968 | ac_have_decl=1 |
| 11969 | else |
| 11970 | ac_have_decl=0 |
| 11971 | fi |
| 11972 | |
| 11973 | cat >>confdefs.h <<_ACEOF |
| 11974 | #define HAVE_DECL_ISNAN $ac_have_decl |
| 11975 | _ACEOF |
| 11976 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 11977 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11978 | if test "x$ac_cv_have_decl_isfinite" = x""yes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11979 | ac_have_decl=1 |
| 11980 | else |
| 11981 | ac_have_decl=0 |
| 11982 | fi |
| 11983 | |
| 11984 | cat >>confdefs.h <<_ACEOF |
| 11985 | #define HAVE_DECL_ISFINITE $ac_have_decl |
| 11986 | _ACEOF |
| 11987 | |
| 11988 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11989 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 11990 | # -0. on some architectures. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11991 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 11992 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 11993 | if test "${ac_cv_tanh_preserves_zero_sign+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11994 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11995 | else |
| 11996 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11997 | if test "$cross_compiling" = yes; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11998 | ac_cv_tanh_preserves_zero_sign=no |
| 11999 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12000 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12001 | /* end confdefs.h. */ |
| 12002 | |
| 12003 | #include <math.h> |
| 12004 | #include <stdlib.h> |
| 12005 | int main() { |
| 12006 | /* return 0 if either negative zeros don't exist |
| 12007 | on this platform or if negative zeros exist |
| 12008 | and tanh(-0.) == -0. */ |
| 12009 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 12010 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 12011 | else exit(1); |
| 12012 | } |
| 12013 | |
| 12014 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12015 | if ac_fn_c_try_run "$LINENO"; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12016 | ac_cv_tanh_preserves_zero_sign=yes |
| 12017 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12018 | ac_cv_tanh_preserves_zero_sign=no |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12019 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12020 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12021 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12022 | fi |
| 12023 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12024 | fi |
| 12025 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12026 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 12027 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12028 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 12029 | then |
| 12030 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12031 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 12032 | |
| 12033 | fi |
| 12034 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12035 | if test "$ac_cv_func_log1p" = yes |
| 12036 | then |
| 12037 | # On some versions of AIX, log1p(-0.) returns 0. instead of |
| 12038 | # -0. See issue #9920. |
| 12039 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether log1p drops the sign of negative zero" >&5 |
| 12040 | $as_echo_n "checking whether log1p drops the sign of negative zero... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12041 | if test "${ac_cv_log1p_drops_zero_sign+set}" = set; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12042 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12043 | else |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12044 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12045 | if test "$cross_compiling" = yes; then : |
| 12046 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12047 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12048 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12049 | /* end confdefs.h. */ |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12050 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12051 | #include <math.h> |
| 12052 | #include <stdlib.h> |
| 12053 | int main() { |
| 12054 | /* Fail if the signs of log1p(-0.) and -0. can be |
| 12055 | distinguished. */ |
| 12056 | if (atan2(log1p(-0.), -1.) == atan2(-0., -1.)) |
| 12057 | return 0; |
| 12058 | else |
| 12059 | return 1; |
| 12060 | } |
| 12061 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12062 | _ACEOF |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12063 | if ac_fn_c_try_run "$LINENO"; then : |
| 12064 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12065 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12066 | ac_cv_log1p_drops_zero_sign=yes |
| 12067 | fi |
| 12068 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12069 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12070 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12071 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12072 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12073 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12074 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_log1p_drops_zero_sign" >&5 |
| 12075 | $as_echo "$ac_cv_log1p_drops_zero_sign" >&6; } |
| 12076 | fi |
| 12077 | if test "$ac_cv_log1p_drops_zero_sign" = yes |
| 12078 | then |
| 12079 | |
| 12080 | $as_echo "#define LOG1P_DROPS_ZERO_SIGN 1" >>confdefs.h |
| 12081 | |
| 12082 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12083 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 12084 | LIBS=$LIBS_SAVE |
| 12085 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12086 | # For multiprocessing module, check that sem_open |
| 12087 | # actually works. For FreeBSD versions <= 7.2, |
| 12088 | # the kernel module that provides POSIX semaphores |
| 12089 | # isn't loaded by default, so an attempt to call |
| 12090 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12091 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 12092 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12093 | if test "${ac_cv_posix_semaphores_enabled+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12094 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12095 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12096 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12097 | ac_cv_posix_semaphores_enabled=yes |
| 12098 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12099 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12100 | /* end confdefs.h. */ |
| 12101 | |
| 12102 | #include <unistd.h> |
| 12103 | #include <fcntl.h> |
| 12104 | #include <stdio.h> |
| 12105 | #include <semaphore.h> |
| 12106 | #include <sys/stat.h> |
| 12107 | |
| 12108 | int main(void) { |
| 12109 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 12110 | if (a == SEM_FAILED) { |
| 12111 | perror("sem_open"); |
| 12112 | return 1; |
| 12113 | } |
| 12114 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12115 | sem_unlink("/autoconf"); |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12116 | return 0; |
| 12117 | } |
| 12118 | |
| 12119 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12120 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12121 | ac_cv_posix_semaphores_enabled=yes |
| 12122 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12123 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12124 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12125 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12126 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12127 | fi |
| 12128 | |
| 12129 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12130 | fi |
| 12131 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12132 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 12133 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12134 | if test $ac_cv_posix_semaphores_enabled = no |
| 12135 | then |
| 12136 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12137 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12138 | |
| 12139 | fi |
| 12140 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12141 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12142 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 12143 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12144 | if test "${ac_cv_broken_sem_getvalue+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12145 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12146 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12147 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12148 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12149 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12150 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12151 | /* end confdefs.h. */ |
| 12152 | |
| 12153 | #include <unistd.h> |
| 12154 | #include <fcntl.h> |
| 12155 | #include <stdio.h> |
| 12156 | #include <semaphore.h> |
| 12157 | #include <sys/stat.h> |
| 12158 | |
| 12159 | int main(void){ |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12160 | 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] | 12161 | int count; |
| 12162 | int res; |
| 12163 | if(a==SEM_FAILED){ |
| 12164 | perror("sem_open"); |
| 12165 | return 1; |
| 12166 | |
| 12167 | } |
| 12168 | res = sem_getvalue(a, &count); |
| 12169 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12170 | sem_unlink("/autocftw"); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12171 | return res==-1 ? 1 : 0; |
| 12172 | } |
| 12173 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12174 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12175 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12176 | ac_cv_broken_sem_getvalue=no |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12177 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12178 | ac_cv_broken_sem_getvalue=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12179 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12180 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12181 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 12182 | fi |
| 12183 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12184 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12185 | fi |
| 12186 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12187 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 12188 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12189 | if test $ac_cv_broken_sem_getvalue = yes |
| 12190 | then |
| 12191 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12192 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12193 | |
| 12194 | fi |
| 12195 | |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12196 | # determine what size digit to use for Python's longs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12197 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 12198 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12199 | # Check whether --enable-big-digits was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12200 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12201 | enableval=$enable_big_digits; case $enable_big_digits in |
| 12202 | yes) |
| 12203 | enable_big_digits=30 ;; |
| 12204 | no) |
| 12205 | enable_big_digits=15 ;; |
| 12206 | 15|30) |
| 12207 | ;; |
| 12208 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 12209 | 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] | 12210 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 12212 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12213 | |
| 12214 | cat >>confdefs.h <<_ACEOF |
| 12215 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 12216 | _ACEOF |
| 12217 | |
| 12218 | |
| 12219 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12220 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 12221 | $as_echo "no value specified" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12222 | fi |
| 12223 | |
| 12224 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12225 | # check for wchar.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12226 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12227 | 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] | 12228 | |
| 12229 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12230 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12231 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12232 | wchar_h="yes" |
| 12233 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12234 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12235 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12236 | |
| 12237 | fi |
| 12238 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12239 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12240 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12241 | # determine wchar_t size |
| 12242 | if test "$wchar_h" = yes |
| 12243 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12244 | # 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] | 12245 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 12246 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 12247 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12248 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 12249 | $as_echo_n "checking size of wchar_t... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12250 | if test "${ac_cv_sizeof_wchar_t+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12251 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12252 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12253 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 12254 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12255 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12256 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12257 | if test "$ac_cv_type_wchar_t" = yes; then |
| 12258 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 12259 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 12260 | as_fn_error 77 "cannot compute sizeof (wchar_t) |
| 12261 | See \`config.log' for more details" "$LINENO" 5 ; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12262 | else |
| 12263 | ac_cv_sizeof_wchar_t=0 |
| 12264 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12265 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12266 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12267 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 12269 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12270 | |
| 12271 | |
| 12272 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12273 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12274 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12275 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12276 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12277 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12278 | fi |
| 12279 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 12281 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12282 | have_ucs4_tcl=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12283 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12284 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12285 | |
| 12286 | #include <tcl.h> |
| 12287 | #if TCL_UTF_MAX != 6 |
| 12288 | # error "NOT UCS4_TCL" |
| 12289 | #endif |
| 12290 | int |
| 12291 | main () |
| 12292 | { |
| 12293 | |
| 12294 | ; |
| 12295 | return 0; |
| 12296 | } |
| 12297 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12298 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12299 | |
| 12300 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12301 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12302 | |
| 12303 | have_ucs4_tcl=yes |
| 12304 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12305 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12306 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12307 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 12308 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12309 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12310 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12311 | if test "$wchar_h" = yes |
| 12312 | then |
| 12313 | # check whether wchar_t is signed or not |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12314 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 12315 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12316 | if test "${ac_cv_wchar_t_signed+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12317 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12318 | else |
| 12319 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12320 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12321 | ac_cv_wchar_t_signed=yes |
| 12322 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12323 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12324 | /* end confdefs.h. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12325 | |
| 12326 | #include <wchar.h> |
| 12327 | int main() |
| 12328 | { |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 12329 | /* Success: exit code 0 */ |
| 12330 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12331 | } |
| 12332 | |
| 12333 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12334 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12335 | ac_cv_wchar_t_signed=yes |
| 12336 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12337 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12338 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12339 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12340 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12341 | fi |
| 12342 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12343 | fi |
| 12344 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12345 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 12346 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12347 | fi |
| 12348 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12349 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type to use for str" >&5 |
| 12350 | $as_echo_n "checking what type to use for str... " >&6; } |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12351 | |
| 12352 | # Check whether --with-wide-unicode was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12353 | if test "${with_wide_unicode+set}" = set; then : |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12354 | withval=$with_wide_unicode; |
| 12355 | if test "$withval" != no |
| 12356 | then unicode_size="4" |
| 12357 | else unicode_size="2" |
| 12358 | fi |
| 12359 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12360 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12361 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12362 | case "$have_ucs4_tcl" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12363 | yes) unicode_size="4";; |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12364 | *) unicode_size="2" ;; |
| 12365 | esac |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12366 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12367 | fi |
| 12368 | |
Martin v. Löwis | 0036cba | 2002-04-12 09:58:45 +0000 | [diff] [blame] | 12369 | |
| 12370 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12371 | case "$unicode_size" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12372 | 4) |
| 12373 | $as_echo "#define Py_UNICODE_SIZE 4" >>confdefs.h |
| 12374 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12375 | ABIFLAGS="${ABIFLAGS}u" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12376 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12377 | *) $as_echo "#define Py_UNICODE_SIZE 2" >>confdefs.h |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12378 | ;; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12379 | esac |
| 12380 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12381 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12382 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12383 | # wchar_t is only usable if it maps to an unsigned type |
| 12384 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 12385 | -a "$ac_cv_wchar_t_signed" = "no" |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12386 | then |
| 12387 | PY_UNICODE_TYPE="wchar_t" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12388 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12389 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12390 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12391 | $as_echo "#define PY_UNICODE_TYPE wchar_t" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12392 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12393 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 12394 | then |
| 12395 | PY_UNICODE_TYPE="unsigned short" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12396 | $as_echo "#define PY_UNICODE_TYPE unsigned short" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12397 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12398 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 12399 | then |
| 12400 | PY_UNICODE_TYPE="unsigned long" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12401 | $as_echo "#define PY_UNICODE_TYPE unsigned long" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12402 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12403 | else |
| 12404 | PY_UNICODE_TYPE="no type found" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12405 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12406 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PY_UNICODE_TYPE" >&5 |
| 12407 | $as_echo "$PY_UNICODE_TYPE" >&6; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12408 | |
| 12409 | # check for endianness |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12410 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 12411 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12412 | if test "${ac_cv_c_bigendian+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12413 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12414 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12415 | ac_cv_c_bigendian=unknown |
| 12416 | # See if we're dealing with a universal compiler. |
| 12417 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12418 | /* end confdefs.h. */ |
| 12419 | #ifndef __APPLE_CC__ |
| 12420 | not a universal capable compiler |
| 12421 | #endif |
| 12422 | typedef int dummy; |
| 12423 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12424 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12425 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12426 | |
| 12427 | # Check for potential -arch flags. It is not universal unless |
| 12428 | # there are at least two -arch flags with different values. |
| 12429 | ac_arch= |
| 12430 | ac_prev= |
| 12431 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 12432 | if test -n "$ac_prev"; then |
| 12433 | case $ac_word in |
| 12434 | i?86 | x86_64 | ppc | ppc64) |
| 12435 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 12436 | ac_arch=$ac_word |
| 12437 | else |
| 12438 | ac_cv_c_bigendian=universal |
| 12439 | break |
| 12440 | fi |
| 12441 | ;; |
| 12442 | esac |
| 12443 | ac_prev= |
| 12444 | elif test "x$ac_word" = "x-arch"; then |
| 12445 | ac_prev=arch |
| 12446 | fi |
| 12447 | done |
| 12448 | fi |
| 12449 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12450 | if test $ac_cv_c_bigendian = unknown; then |
| 12451 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 12452 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12453 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12454 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12455 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12456 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12457 | int |
| 12458 | main () |
| 12459 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12460 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 12461 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 12462 | && LITTLE_ENDIAN) |
| 12463 | bogus endian macros |
| 12464 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12465 | |
| 12466 | ; |
| 12467 | return 0; |
| 12468 | } |
| 12469 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12470 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12471 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12472 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12473 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12474 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12475 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12476 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12477 | int |
| 12478 | main () |
| 12479 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12480 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12481 | not big endian |
| 12482 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12483 | |
| 12484 | ; |
| 12485 | return 0; |
| 12486 | } |
| 12487 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12488 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12489 | ac_cv_c_bigendian=yes |
| 12490 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12491 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12492 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12493 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12494 | fi |
| 12495 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12496 | fi |
| 12497 | if test $ac_cv_c_bigendian = unknown; then |
| 12498 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 12499 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12500 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12501 | #include <limits.h> |
| 12502 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12503 | int |
| 12504 | main () |
| 12505 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12506 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 12507 | bogus endian macros |
| 12508 | #endif |
| 12509 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12510 | ; |
| 12511 | return 0; |
| 12512 | } |
| 12513 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12514 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12515 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 12516 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12517 | /* end confdefs.h. */ |
| 12518 | #include <limits.h> |
| 12519 | |
| 12520 | int |
| 12521 | main () |
| 12522 | { |
| 12523 | #ifndef _BIG_ENDIAN |
| 12524 | not big endian |
| 12525 | #endif |
| 12526 | |
| 12527 | ; |
| 12528 | return 0; |
| 12529 | } |
| 12530 | _ACEOF |
| 12531 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12532 | ac_cv_c_bigendian=yes |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12533 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12534 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12535 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12536 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12537 | fi |
| 12538 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12539 | fi |
| 12540 | if test $ac_cv_c_bigendian = unknown; then |
| 12541 | # Compile a test program. |
| 12542 | if test "$cross_compiling" = yes; then : |
| 12543 | # Try to guess by grepping values from an object file. |
| 12544 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12545 | /* end confdefs.h. */ |
| 12546 | short int ascii_mm[] = |
| 12547 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 12548 | short int ascii_ii[] = |
| 12549 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 12550 | int use_ascii (int i) { |
| 12551 | return ascii_mm[i] + ascii_ii[i]; |
| 12552 | } |
| 12553 | short int ebcdic_ii[] = |
| 12554 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 12555 | short int ebcdic_mm[] = |
| 12556 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 12557 | int use_ebcdic (int i) { |
| 12558 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 12559 | } |
| 12560 | extern int foo; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12561 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12562 | int |
| 12563 | main () |
| 12564 | { |
| 12565 | return use_ascii (foo) == use_ebcdic (foo); |
| 12566 | ; |
| 12567 | return 0; |
| 12568 | } |
| 12569 | _ACEOF |
| 12570 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12571 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 12572 | ac_cv_c_bigendian=yes |
| 12573 | fi |
| 12574 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 12575 | if test "$ac_cv_c_bigendian" = unknown; then |
| 12576 | ac_cv_c_bigendian=no |
| 12577 | else |
| 12578 | # finding both strings is unlikely to happen, but who knows? |
| 12579 | ac_cv_c_bigendian=unknown |
| 12580 | fi |
| 12581 | fi |
| 12582 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12583 | 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] | 12584 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12585 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12586 | /* end confdefs.h. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12587 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12588 | int |
| 12589 | main () |
| 12590 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12591 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12592 | /* Are we little or big endian? From Harbison&Steele. */ |
| 12593 | union |
| 12594 | { |
| 12595 | long int l; |
| 12596 | char c[sizeof (long int)]; |
| 12597 | } u; |
| 12598 | u.l = 1; |
| 12599 | return u.c[sizeof (long int) - 1] == 1; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12600 | |
| 12601 | ; |
| 12602 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12603 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12604 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12605 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12606 | ac_cv_c_bigendian=no |
| 12607 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12608 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12609 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12610 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12611 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12612 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12613 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12614 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12615 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12616 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 12617 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 12618 | case $ac_cv_c_bigendian in #( |
| 12619 | yes) |
| 12620 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 12621 | ;; #( |
| 12622 | no) |
| 12623 | ;; #( |
| 12624 | universal) |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 12625 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12626 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12627 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12628 | ;; #( |
| 12629 | *) |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 12630 | as_fn_error $? "unknown endianness |
| 12631 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12632 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12633 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12634 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12635 | # ABI version string for Python extension modules. This appears between the |
| 12636 | # periods in shared library file names, e.g. foo.<SOABI>.so. It is calculated |
| 12637 | # from the following attributes which affect the ABI of this Python build (in |
| 12638 | # this order): |
| 12639 | # |
| 12640 | # * The Python implementation (always 'cpython-' for us) |
| 12641 | # * The major and minor version numbers |
| 12642 | # * --with-pydebug (adds a 'd') |
| 12643 | # * --with-pymalloc (adds a 'm') |
| 12644 | # * --with-wide-unicode (adds a 'u') |
| 12645 | # |
| 12646 | # 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] | 12647 | # would get a shared library ABI version tag of 'cpython-32dmu' and shared |
| 12648 | # libraries would be named 'foo.cpython-32dmu.so'. |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12649 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12650 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ABIFLAGS" >&5 |
| 12651 | $as_echo_n "checking ABIFLAGS... " >&6; } |
| 12652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ABIFLAGS" >&5 |
| 12653 | $as_echo "$ABIFLAGS" >&6; } |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5 |
| 12655 | $as_echo_n "checking SOABI... " >&6; } |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12656 | SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS} |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12657 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5 |
| 12658 | $as_echo "$SOABI" >&6; } |
| 12659 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12660 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5 |
| 12661 | $as_echo_n "checking LDVERSION... " >&6; } |
| 12662 | LDVERSION='$(VERSION)$(ABIFLAGS)' |
| 12663 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5 |
| 12664 | $as_echo "$LDVERSION" >&6; } |
| 12665 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12666 | # SO is the extension of shared libraries `(including the dot!) |
| 12667 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
| 12668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5 |
| 12669 | $as_echo_n "checking SO... " >&6; } |
| 12670 | if test -z "$SO" |
| 12671 | then |
| 12672 | case $ac_sys_system in |
| 12673 | hp*|HP*) |
| 12674 | case `uname -m` in |
| 12675 | ia64) SO=.so;; |
| 12676 | *) SO=.sl;; |
| 12677 | esac |
| 12678 | ;; |
| 12679 | CYGWIN*) SO=.dll;; |
Barry Warsaw | 278266f | 2010-10-14 17:38:46 +0000 | [diff] [blame] | 12680 | Linux*|GNU*) |
| 12681 | SO=.${SOABI}.so;; |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12682 | *) SO=.so;; |
| 12683 | esac |
| 12684 | else |
| 12685 | # this might also be a termcap variable, see #610332 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12686 | echo |
| 12687 | echo '=====================================================================' |
| 12688 | echo '+ +' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12689 | echo '+ WARNING: You have set SO in your environment. +' |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12690 | echo '+ Do you really mean to change the extension for shared libraries? +' |
| 12691 | echo '+ Continuing in 10 seconds to let you to ponder. +' |
| 12692 | echo '+ +' |
| 12693 | echo '=====================================================================' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12694 | sleep 10 |
| 12695 | fi |
| 12696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5 |
| 12697 | $as_echo "$SO" >&6; } |
| 12698 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12699 | # Check whether right shifting a negative integer extends the sign bit |
| 12700 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12701 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 12702 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12703 | if test "${ac_cv_rshift_extends_sign+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12704 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12705 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12706 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12707 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12708 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12709 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12710 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12711 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12712 | |
| 12713 | int main() |
| 12714 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12715 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12716 | } |
| 12717 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12718 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12719 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12720 | ac_cv_rshift_extends_sign=yes |
| 12721 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12722 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12723 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12724 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12725 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12726 | fi |
| 12727 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12728 | fi |
| 12729 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 12731 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12732 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12733 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12734 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12735 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12736 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12737 | fi |
| 12738 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12739 | # check for getc_unlocked and related locking functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 12741 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12742 | if test "${ac_cv_have_getc_unlocked+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12743 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12744 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12745 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12746 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12747 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12748 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12749 | int |
| 12750 | main () |
| 12751 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12752 | |
| 12753 | FILE *f = fopen("/dev/null", "r"); |
| 12754 | flockfile(f); |
| 12755 | getc_unlocked(f); |
| 12756 | funlockfile(f); |
| 12757 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12758 | ; |
| 12759 | return 0; |
| 12760 | } |
| 12761 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12762 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12763 | ac_cv_have_getc_unlocked=yes |
| 12764 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12765 | ac_cv_have_getc_unlocked=no |
| 12766 | fi |
| 12767 | rm -f core conftest.err conftest.$ac_objext \ |
| 12768 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12769 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12770 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12771 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 12772 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12773 | if test "$ac_cv_have_getc_unlocked" = yes |
| 12774 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12775 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12776 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12777 | |
| 12778 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12779 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12780 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12781 | # save the value of LIBS so we don't actually link Python with readline |
| 12782 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12783 | |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12784 | # On some systems we need to link readline to a termcap compatible |
| 12785 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 12786 | # with setup.py. |
| 12787 | py_cv_lib_readline=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12788 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 12789 | $as_echo_n "checking how to link readline libs... " >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12790 | for py_libtermcap in "" ncursesw ncurses curses termcap; do |
| 12791 | if test -z "$py_libtermcap"; then |
| 12792 | READLINE_LIBS="-lreadline" |
| 12793 | else |
| 12794 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 12795 | fi |
| 12796 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12797 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12798 | /* end confdefs.h. */ |
| 12799 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12800 | /* Override any GCC internal prototype to avoid an error. |
| 12801 | Use char because int might match the return type of a GCC |
| 12802 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12803 | #ifdef __cplusplus |
| 12804 | extern "C" |
| 12805 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12806 | char readline (); |
| 12807 | int |
| 12808 | main () |
| 12809 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12810 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12811 | ; |
| 12812 | return 0; |
| 12813 | } |
| 12814 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12815 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12816 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12817 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12818 | rm -f core conftest.err conftest.$ac_objext \ |
| 12819 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12820 | if test $py_cv_lib_readline = yes; then |
| 12821 | break |
| 12822 | fi |
| 12823 | done |
| 12824 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 12825 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | 3856c37 | 2008-09-07 19:24:00 +0000 | [diff] [blame] | 12826 | if test $py_cv_lib_readline = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12827 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 12828 | $as_echo "none" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12829 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12830 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 12831 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12832 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12833 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12834 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12835 | fi |
| 12836 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12837 | # check for readline 2.1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12838 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 12839 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12840 | if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12841 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12842 | else |
| 12843 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12844 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12845 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12846 | /* end confdefs.h. */ |
| 12847 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12848 | /* Override any GCC internal prototype to avoid an error. |
| 12849 | Use char because int might match the return type of a GCC |
| 12850 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12851 | #ifdef __cplusplus |
| 12852 | extern "C" |
| 12853 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12854 | char rl_callback_handler_install (); |
| 12855 | int |
| 12856 | main () |
| 12857 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12858 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12859 | ; |
| 12860 | return 0; |
| 12861 | } |
| 12862 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12863 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12864 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 12865 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12866 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12867 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12868 | rm -f core conftest.err conftest.$ac_objext \ |
| 12869 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12870 | LIBS=$ac_check_lib_save_LIBS |
| 12871 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12872 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 12873 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12874 | 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] | 12875 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12876 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12877 | |
| 12878 | fi |
| 12879 | |
| 12880 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12881 | # check for readline 2.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12882 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12883 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12884 | #include <readline/readline.h> |
| 12885 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12886 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12887 | have_readline=yes |
| 12888 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12889 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12890 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12891 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 12892 | rm -f conftest.err conftest.i conftest.$ac_ext |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12893 | if test $have_readline = yes |
| 12894 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12895 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12896 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12897 | #include <readline/readline.h> |
| 12898 | |
| 12899 | _ACEOF |
| 12900 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12901 | $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] | 12902 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12903 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12904 | |
| 12905 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12906 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12907 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12908 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12909 | /* end confdefs.h. */ |
| 12910 | #include <readline/readline.h> |
| 12911 | |
| 12912 | _ACEOF |
| 12913 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12914 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12915 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12916 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12917 | |
| 12918 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12919 | rm -f conftest* |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12920 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12921 | fi |
| 12922 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12923 | # check for readline 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12924 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 12925 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12926 | if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12927 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12928 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12929 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12930 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12931 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12932 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12933 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12934 | /* Override any GCC internal prototype to avoid an error. |
| 12935 | Use char because int might match the return type of a GCC |
| 12936 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12937 | #ifdef __cplusplus |
| 12938 | extern "C" |
| 12939 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12940 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12941 | int |
| 12942 | main () |
| 12943 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12944 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12945 | ; |
| 12946 | return 0; |
| 12947 | } |
| 12948 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12949 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12950 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12951 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12952 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12953 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12954 | rm -f core conftest.err conftest.$ac_objext \ |
| 12955 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12956 | LIBS=$ac_check_lib_save_LIBS |
| 12957 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12958 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 12959 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12960 | 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] | 12961 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12962 | $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] | 12963 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12964 | fi |
| 12965 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12966 | |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12967 | # also in 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12968 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 12969 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 12970 | if test "${ac_cv_lib_readline_rl_completion_display_matches_hook+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12971 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12972 | else |
| 12973 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12974 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12975 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12976 | /* end confdefs.h. */ |
| 12977 | |
| 12978 | /* Override any GCC internal prototype to avoid an error. |
| 12979 | Use char because int might match the return type of a GCC |
| 12980 | builtin and then its argument prototype would still apply. */ |
| 12981 | #ifdef __cplusplus |
| 12982 | extern "C" |
| 12983 | #endif |
| 12984 | char rl_completion_display_matches_hook (); |
| 12985 | int |
| 12986 | main () |
| 12987 | { |
| 12988 | return rl_completion_display_matches_hook (); |
| 12989 | ; |
| 12990 | return 0; |
| 12991 | } |
| 12992 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12993 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12994 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 12995 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12996 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12997 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12998 | rm -f core conftest.err conftest.$ac_objext \ |
| 12999 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 13000 | LIBS=$ac_check_lib_save_LIBS |
| 13001 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13002 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 13003 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13004 | 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] | 13005 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13006 | $as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 13007 | |
| 13008 | fi |
| 13009 | |
| 13010 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 13011 | # check for readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13012 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 13013 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13014 | if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13015 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 13016 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13017 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 13018 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13019 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13020 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13021 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13022 | /* Override any GCC internal prototype to avoid an error. |
| 13023 | Use char because int might match the return type of a GCC |
| 13024 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13025 | #ifdef __cplusplus |
| 13026 | extern "C" |
| 13027 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13028 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13029 | int |
| 13030 | main () |
| 13031 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13032 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13033 | ; |
| 13034 | return 0; |
| 13035 | } |
| 13036 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13037 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13038 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13039 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13040 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13041 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13042 | rm -f core conftest.err conftest.$ac_objext \ |
| 13043 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13044 | LIBS=$ac_check_lib_save_LIBS |
| 13045 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 13047 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13048 | 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] | 13049 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13050 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13051 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13052 | fi |
| 13053 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13054 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13055 | # also in readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13056 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13057 | /* end confdefs.h. */ |
| 13058 | #include <readline/readline.h> |
| 13059 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13060 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13061 | have_readline=yes |
| 13062 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13063 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13064 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13065 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 13066 | rm -f conftest.err conftest.i conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13067 | if test $have_readline = yes |
| 13068 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13069 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13070 | /* end confdefs.h. */ |
| 13071 | #include <readline/readline.h> |
| 13072 | |
| 13073 | _ACEOF |
| 13074 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13075 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13076 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13077 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13078 | |
| 13079 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 13080 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13081 | |
| 13082 | fi |
| 13083 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 13084 | # End of readline checks: restore LIBS |
| 13085 | LIBS=$LIBS_no_readline |
| 13086 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13087 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 13088 | $as_echo_n "checking for broken nice()... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13089 | if test "${ac_cv_broken_nice+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13090 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13091 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13092 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13093 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 13094 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13095 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13096 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13097 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13098 | |
| 13099 | int main() |
| 13100 | { |
| 13101 | int val1 = nice(1); |
| 13102 | if (val1 != -1 && val1 == nice(2)) |
| 13103 | exit(0); |
| 13104 | exit(1); |
| 13105 | } |
| 13106 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13107 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13108 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13109 | ac_cv_broken_nice=yes |
| 13110 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13111 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13112 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13113 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13114 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13115 | fi |
| 13116 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13117 | fi |
| 13118 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 13120 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13121 | if test "$ac_cv_broken_nice" = yes |
| 13122 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13123 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13124 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13125 | |
| 13126 | fi |
| 13127 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 13129 | $as_echo_n "checking for broken poll()... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13130 | if test "${ac_cv_broken_poll+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13131 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13132 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13133 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13134 | ac_cv_broken_poll=no |
| 13135 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13136 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13137 | /* end confdefs.h. */ |
| 13138 | |
| 13139 | #include <poll.h> |
| 13140 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13141 | int main() |
| 13142 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13143 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13144 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13145 | |
| 13146 | close (42); |
| 13147 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13148 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13149 | if (poll_test < 0) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13150 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13151 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13152 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13153 | else |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13154 | return 1; |
| 13155 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13156 | |
| 13157 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13158 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13159 | ac_cv_broken_poll=yes |
| 13160 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13161 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13162 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13163 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13164 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13165 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13166 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13167 | fi |
| 13168 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13169 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 13170 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13171 | if test "$ac_cv_broken_poll" = yes |
| 13172 | then |
| 13173 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13174 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13175 | |
| 13176 | fi |
| 13177 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13178 | # 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] | 13179 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 13180 | # tzname[] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13181 | 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] | 13182 | #include <$ac_cv_struct_tm> |
| 13183 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13184 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13185 | 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] | 13186 | |
| 13187 | cat >>confdefs.h <<_ACEOF |
| 13188 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 13189 | _ACEOF |
| 13190 | |
| 13191 | |
| 13192 | fi |
| 13193 | |
| 13194 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 13195 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13196 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13197 | |
| 13198 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13199 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 13200 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13201 | if test "x$ac_cv_have_decl_tzname" = x""yes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13202 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13203 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13204 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13205 | fi |
| 13206 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13207 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13208 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13209 | _ACEOF |
| 13210 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13211 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 13212 | $as_echo_n "checking for tzname... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13213 | if test "${ac_cv_var_tzname+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13214 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13215 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13216 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13217 | /* end confdefs.h. */ |
| 13218 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13219 | #if !HAVE_DECL_TZNAME |
| 13220 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13221 | #endif |
| 13222 | |
| 13223 | int |
| 13224 | main () |
| 13225 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13226 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13227 | ; |
| 13228 | return 0; |
| 13229 | } |
| 13230 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13231 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13232 | ac_cv_var_tzname=yes |
| 13233 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13234 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13235 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13236 | rm -f core conftest.err conftest.$ac_objext \ |
| 13237 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13238 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13239 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 13240 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13241 | if test $ac_cv_var_tzname = yes; then |
| 13242 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13243 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13244 | |
| 13245 | fi |
| 13246 | fi |
| 13247 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13248 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13249 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 13251 | $as_echo_n "checking for working tzset()... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13252 | if test "${ac_cv_working_tzset+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13253 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13254 | else |
| 13255 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13256 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13257 | ac_cv_working_tzset=no |
| 13258 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13259 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13260 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13261 | |
| 13262 | #include <stdlib.h> |
| 13263 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13264 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13265 | |
| 13266 | #if HAVE_TZNAME |
| 13267 | extern char *tzname[]; |
| 13268 | #endif |
| 13269 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13270 | int main() |
| 13271 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13272 | /* Note that we need to ensure that not only does tzset(3) |
| 13273 | do 'something' with localtime, but it works as documented |
| 13274 | 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] | 13275 | This includes making sure that tzname is set properly if |
| 13276 | tm->tm_zone does not exist since it is the alternative way |
| 13277 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13278 | |
| 13279 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13280 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13281 | */ |
| 13282 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13283 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13284 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 13285 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13286 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13287 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13288 | if (localtime(&groundhogday)->tm_hour != 0) |
| 13289 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13290 | #if HAVE_TZNAME |
| 13291 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 13292 | if (strcmp(tzname[0], "UTC") || |
| 13293 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 13294 | exit(1); |
| 13295 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13296 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13297 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13298 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13299 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13300 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13301 | #if HAVE_TZNAME |
| 13302 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 13303 | exit(1); |
| 13304 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13305 | |
| 13306 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 13307 | tzset(); |
| 13308 | if (localtime(&groundhogday)->tm_hour != 11) |
| 13309 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13310 | #if HAVE_TZNAME |
| 13311 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 13312 | exit(1); |
| 13313 | #endif |
| 13314 | |
| 13315 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13316 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 13317 | exit(1); |
| 13318 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 13319 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13320 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13321 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13322 | exit(0); |
| 13323 | } |
| 13324 | |
| 13325 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13326 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13327 | ac_cv_working_tzset=yes |
| 13328 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13329 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13330 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13331 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13332 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13333 | fi |
| 13334 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13335 | fi |
| 13336 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13337 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 13338 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13339 | if test "$ac_cv_working_tzset" = yes |
| 13340 | then |
| 13341 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13342 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13343 | |
| 13344 | fi |
| 13345 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13346 | # Look for subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 13348 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13349 | if test "${ac_cv_stat_tv_nsec+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13350 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13351 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13352 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13353 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13354 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13355 | int |
| 13356 | main () |
| 13357 | { |
| 13358 | |
| 13359 | struct stat st; |
| 13360 | st.st_mtim.tv_nsec = 1; |
| 13361 | |
| 13362 | ; |
| 13363 | return 0; |
| 13364 | } |
| 13365 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13366 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 13367 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13368 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13369 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13370 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13371 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13372 | fi |
| 13373 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 13375 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13376 | if test "$ac_cv_stat_tv_nsec" = yes |
| 13377 | then |
| 13378 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13379 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13380 | |
| 13381 | fi |
| 13382 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13383 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13384 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 13385 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13386 | if test "${ac_cv_stat_tv_nsec2+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13387 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13388 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13389 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13390 | /* end confdefs.h. */ |
| 13391 | #include <sys/stat.h> |
| 13392 | int |
| 13393 | main () |
| 13394 | { |
| 13395 | |
| 13396 | struct stat st; |
| 13397 | st.st_mtimespec.tv_nsec = 1; |
| 13398 | |
| 13399 | ; |
| 13400 | return 0; |
| 13401 | } |
| 13402 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13403 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13404 | ac_cv_stat_tv_nsec2=yes |
| 13405 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13406 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13407 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13408 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13409 | fi |
| 13410 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13411 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 13412 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13413 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 13414 | then |
| 13415 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13416 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13417 | |
| 13418 | fi |
| 13419 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13420 | # 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] | 13421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 13422 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13423 | if test "${ac_cv_mvwdelch_is_expression+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13424 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13425 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13426 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13427 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13428 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13429 | int |
| 13430 | main () |
| 13431 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13432 | |
| 13433 | int rtn; |
| 13434 | rtn = mvwdelch(0,0,0); |
| 13435 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13436 | ; |
| 13437 | return 0; |
| 13438 | } |
| 13439 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13440 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13441 | ac_cv_mvwdelch_is_expression=yes |
| 13442 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13443 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13444 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13445 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13446 | fi |
| 13447 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13448 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 13449 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13450 | |
| 13451 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 13452 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13453 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13454 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13455 | |
| 13456 | fi |
| 13457 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13458 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 13459 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13460 | if test "${ac_cv_window_has_flags+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13461 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13462 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13463 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13464 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13465 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13466 | int |
| 13467 | main () |
| 13468 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13469 | |
| 13470 | WINDOW *w; |
| 13471 | w->_flags = 0; |
| 13472 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13473 | ; |
| 13474 | return 0; |
| 13475 | } |
| 13476 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13477 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13478 | ac_cv_window_has_flags=yes |
| 13479 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13480 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13481 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13482 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13483 | fi |
| 13484 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 13486 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13487 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13488 | |
| 13489 | if test "$ac_cv_window_has_flags" = yes |
| 13490 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13491 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13492 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13493 | |
| 13494 | fi |
| 13495 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13496 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 13497 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 13498 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13499 | /* end confdefs.h. */ |
| 13500 | #include <curses.h> |
| 13501 | int |
| 13502 | main () |
| 13503 | { |
| 13504 | void *x=is_term_resized |
| 13505 | ; |
| 13506 | return 0; |
| 13507 | } |
| 13508 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13509 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13510 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13511 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13512 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13513 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13514 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13515 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13517 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13518 | |
| 13519 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13520 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13521 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13522 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 13523 | $as_echo_n "checking for resize_term... " >&6; } |
| 13524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13525 | /* end confdefs.h. */ |
| 13526 | #include <curses.h> |
| 13527 | int |
| 13528 | main () |
| 13529 | { |
| 13530 | void *x=resize_term |
| 13531 | ; |
| 13532 | return 0; |
| 13533 | } |
| 13534 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13535 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13536 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13537 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13538 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13539 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13540 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13541 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13542 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13543 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13544 | |
| 13545 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13546 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13547 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13548 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 13549 | $as_echo_n "checking for resizeterm... " >&6; } |
| 13550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13551 | /* end confdefs.h. */ |
| 13552 | #include <curses.h> |
| 13553 | int |
| 13554 | main () |
| 13555 | { |
| 13556 | void *x=resizeterm |
| 13557 | ; |
| 13558 | return 0; |
| 13559 | } |
| 13560 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13561 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13562 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13563 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13564 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13565 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13566 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13567 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13568 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13569 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13570 | |
| 13571 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13572 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13573 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 13575 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13576 | |
| 13577 | if test -r /dev/ptmx |
| 13578 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13580 | $as_echo "yes" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13581 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13582 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13583 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13584 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13586 | $as_echo "no" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13587 | fi |
| 13588 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 13590 | $as_echo_n "checking for /dev/ptc... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13591 | |
| 13592 | if test -r /dev/ptc |
| 13593 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13595 | $as_echo "yes" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13596 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13597 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13598 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13599 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13600 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13601 | $as_echo "no" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13602 | fi |
| 13603 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13604 | if test "$have_long_long" = yes |
| 13605 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13606 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 13607 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13608 | if test "${ac_cv_have_long_long_format+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13609 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13610 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13611 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13612 | ac_cv_have_long_long_format=no |
| 13613 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13614 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13615 | /* end confdefs.h. */ |
| 13616 | |
| 13617 | #include <stdio.h> |
| 13618 | #include <stddef.h> |
| 13619 | #include <string.h> |
| 13620 | |
| 13621 | #ifdef HAVE_SYS_TYPES_H |
| 13622 | #include <sys/types.h> |
| 13623 | #endif |
| 13624 | |
| 13625 | int main() |
| 13626 | { |
| 13627 | char buffer[256]; |
| 13628 | |
| 13629 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 13630 | return 1; |
| 13631 | if (strcmp(buffer, "123")) |
| 13632 | return 1; |
| 13633 | |
| 13634 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 13635 | return 1; |
| 13636 | if (strcmp(buffer, "-123")) |
| 13637 | return 1; |
| 13638 | |
| 13639 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 13640 | return 1; |
| 13641 | if (strcmp(buffer, "123")) |
| 13642 | return 1; |
| 13643 | |
| 13644 | return 0; |
| 13645 | } |
| 13646 | |
| 13647 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13648 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13649 | ac_cv_have_long_long_format=yes |
| 13650 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13651 | ac_cv_have_long_long_format=no |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13652 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13653 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13654 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13655 | fi |
| 13656 | |
| 13657 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13658 | fi |
| 13659 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 13661 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13662 | fi |
| 13663 | |
Mark Dickinson | 89d7d41 | 2009-12-31 20:50:59 +0000 | [diff] [blame] | 13664 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13665 | then |
| 13666 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13667 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13668 | |
| 13669 | fi |
| 13670 | |
Ronald Oussoren | 3c1928a | 2009-11-19 17:15:31 +0000 | [diff] [blame] | 13671 | if test $ac_sys_system = Darwin |
| 13672 | then |
| 13673 | LIBS="$LIBS -framework CoreFoundation" |
| 13674 | fi |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13675 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13676 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 13677 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13678 | if test "${ac_cv_have_size_t_format+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13679 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13680 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13681 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13682 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 13683 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13684 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13685 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13686 | /* end confdefs.h. */ |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13687 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13688 | #include <stdio.h> |
| 13689 | #include <stddef.h> |
| 13690 | #include <string.h> |
| 13691 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13692 | #ifdef HAVE_SYS_TYPES_H |
| 13693 | #include <sys/types.h> |
| 13694 | #endif |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13695 | |
| 13696 | #ifdef HAVE_SSIZE_T |
| 13697 | typedef ssize_t Py_ssize_t; |
| 13698 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 13699 | typedef long Py_ssize_t; |
| 13700 | #else |
| 13701 | typedef int Py_ssize_t; |
| 13702 | #endif |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13703 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13704 | int main() |
| 13705 | { |
| 13706 | char buffer[256]; |
| 13707 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13708 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 13709 | return 1; |
| 13710 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13711 | if (strcmp(buffer, "123")) |
| 13712 | return 1; |
| 13713 | |
| 13714 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 13715 | return 1; |
| 13716 | |
| 13717 | if (strcmp(buffer, "-123")) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13718 | return 1; |
| 13719 | |
| 13720 | return 0; |
| 13721 | } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13722 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13723 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13724 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13725 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13726 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13727 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13728 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13729 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13730 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 13731 | fi |
| 13732 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13733 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 13735 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13736 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13737 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13738 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13739 | |
| 13740 | fi |
| 13741 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13742 | 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] | 13743 | #ifdef HAVE_SYS_TYPES_H |
| 13744 | #include <sys/types.h> |
| 13745 | #endif |
| 13746 | #ifdef HAVE_SYS_SOCKET_H |
| 13747 | #include <sys/socket.h> |
| 13748 | #endif |
| 13749 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13750 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13751 | 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] | 13752 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13753 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13754 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13755 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13756 | |
| 13757 | fi |
| 13758 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13759 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13760 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5 |
| 13761 | $as_echo_n "checking for broken mbstowcs... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13762 | if test "${ac_cv_broken_mbstowcs+set}" = set; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13763 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13764 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13765 | if test "$cross_compiling" = yes; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13766 | ac_cv_broken_mbstowcs=no |
| 13767 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13768 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13769 | /* end confdefs.h. */ |
| 13770 | |
| 13771 | #include<stdlib.h> |
| 13772 | int main() { |
| 13773 | size_t len = -1; |
| 13774 | const char *str = "text"; |
| 13775 | len = mbstowcs(NULL, str, 0); |
| 13776 | return (len != 4); |
| 13777 | } |
| 13778 | |
| 13779 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13780 | if ac_fn_c_try_run "$LINENO"; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13781 | ac_cv_broken_mbstowcs=no |
| 13782 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13783 | ac_cv_broken_mbstowcs=yes |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13784 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13785 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13786 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13787 | fi |
| 13788 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13789 | fi |
| 13790 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13791 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5 |
| 13792 | $as_echo "$ac_cv_broken_mbstowcs" >&6; } |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13793 | if test "$ac_cv_broken_mbstowcs" = yes |
| 13794 | then |
| 13795 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13796 | $as_echo "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13797 | |
| 13798 | fi |
| 13799 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13800 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5 |
| 13801 | $as_echo_n "checking whether $CC supports computed gotos... " >&6; } |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13802 | if test "${ac_cv_computed_gotos+set}" = set; then : |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13803 | $as_echo_n "(cached) " >&6 |
| 13804 | else |
| 13805 | if test "$cross_compiling" = yes; then : |
| 13806 | ac_cv_computed_gotos=no |
| 13807 | else |
| 13808 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13809 | /* end confdefs.h. */ |
| 13810 | |
| 13811 | int main(int argc, char **argv) |
| 13812 | { |
| 13813 | static void *targets[1] = { &&LABEL1 }; |
| 13814 | goto LABEL2; |
| 13815 | LABEL1: |
| 13816 | return 0; |
| 13817 | LABEL2: |
| 13818 | goto *targets[0]; |
| 13819 | return 1; |
| 13820 | } |
| 13821 | |
| 13822 | _ACEOF |
| 13823 | if ac_fn_c_try_run "$LINENO"; then : |
| 13824 | ac_cv_computed_gotos=yes |
| 13825 | else |
| 13826 | ac_cv_computed_gotos=no |
| 13827 | fi |
| 13828 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13829 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 13830 | fi |
| 13831 | |
| 13832 | fi |
| 13833 | |
| 13834 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5 |
| 13835 | $as_echo "$ac_cv_computed_gotos" >&6; } |
| 13836 | if test "$ac_cv_computed_gotos" = yes |
| 13837 | then |
| 13838 | |
| 13839 | $as_echo "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h |
| 13840 | |
| 13841 | fi |
| 13842 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13843 | # Check for --with-computed-gotos |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13844 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5 |
| 13845 | $as_echo_n "checking for --with-computed-gotos... " >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13846 | |
| 13847 | # Check whether --with-computed-gotos was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13848 | if test "${with_computed_gotos+set}" = set; then : |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13849 | withval=$with_computed_gotos; |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13850 | if test "$withval" = yes |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13851 | then |
| 13852 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13853 | $as_echo "#define USE_COMPUTED_GOTOS 1" >>confdefs.h |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13854 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13856 | $as_echo "yes" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13857 | fi |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13858 | if test "$withval" = no |
| 13859 | then |
| 13860 | |
| 13861 | $as_echo "#define USE_COMPUTED_GOTOS 0" >>confdefs.h |
| 13862 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13863 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13864 | $as_echo "no" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13865 | fi |
| 13866 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13867 | else |
| 13868 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 13869 | $as_echo "no value specified" >&6; } |
| 13870 | fi |
| 13871 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13872 | |
Benjamin Peterson | d8d835b | 2010-10-15 23:14:46 +0000 | [diff] [blame] | 13873 | case $ac_sys_system in |
| 13874 | AIX*) |
| 13875 | |
| 13876 | $as_echo "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h |
| 13877 | ;; |
| 13878 | esac |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13879 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13880 | |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 13881 | |
| 13882 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 13883 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 13884 | do |
| 13885 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 13886 | done |
| 13887 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13888 | |
Neal Norwitz | d24499d | 2005-12-18 21:36:39 +0000 | [diff] [blame] | 13889 | SRCDIRS="Parser Grammar Objects Python Modules Mac" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13890 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 13891 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13892 | for dir in $SRCDIRS; do |
| 13893 | if test ! -d $dir; then |
| 13894 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 13895 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13896 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13897 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 13898 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 13899 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13900 | # generate output files |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 13901 | 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] | 13902 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 13903 | ac_config_files="$ac_config_files Modules/ld_so_aix" |
| 13904 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13905 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13906 | # This file is a shell script that caches the results of configure |
| 13907 | # 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] | 13908 | # scripts and configure runs, see configure's option --config-cache. |
| 13909 | # It is not useful on other systems. If it contains results you don't |
| 13910 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13911 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13912 | # config.status only pays attention to the cache file if you give it |
| 13913 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13914 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13915 | # `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] | 13916 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 13917 | # following values. |
| 13918 | |
| 13919 | _ACEOF |
| 13920 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 13921 | # The following way of writing the cache mishandles newlines in values, |
| 13922 | # but we know of no workaround that is simple, portable, and efficient. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13923 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13924 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 13925 | # 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] | 13926 | ( |
| 13927 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 13928 | eval ac_val=\$$ac_var |
| 13929 | case $ac_val in #( |
| 13930 | *${as_nl}*) |
| 13931 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13932 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 13933 | $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] | 13934 | esac |
| 13935 | case $ac_var in #( |
| 13936 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13937 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 13938 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13939 | esac ;; |
| 13940 | esac |
| 13941 | done |
| 13942 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13943 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13944 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 13945 | *${as_nl}ac_space=\ *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13946 | # `set' does not quote correctly, so add quotes: double-quote |
| 13947 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13948 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 13949 | "s/'/'\\\\''/g; |
| 13950 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13951 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13952 | *) |
| 13953 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13954 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
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 | esac | |
| 13957 | sort |
| 13958 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13959 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13960 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13961 | t clear |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13962 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13963 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 13964 | t end |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13965 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 13966 | :end' >>confcache |
| 13967 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 13968 | if test -w "$cache_file"; then |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13969 | test "x$cache_file" != "x/dev/null" && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13970 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 13971 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 13972 | cat confcache >$cache_file |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13973 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13974 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 13975 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13976 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13977 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13978 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13979 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13980 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 13981 | # Let make expand exec_prefix. |
| 13982 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13983 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13984 | DEFS=-DHAVE_CONFIG_H |
| 13985 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13986 | ac_libobjs= |
| 13987 | ac_ltlibobjs= |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 13988 | U= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13989 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 13990 | # 1. Remove the extension, and $U if already installed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13991 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13992 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13993 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 13994 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13995 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 13996 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13997 | done |
| 13998 | LIBOBJS=$ac_libobjs |
| 13999 | |
| 14000 | LTLIBOBJS=$ac_ltlibobjs |
| 14001 | |
| 14002 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14003 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14004 | |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14005 | : ${CONFIG_STATUS=./config.status} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14006 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14007 | ac_clean_files_save=$ac_clean_files |
| 14008 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14009 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 14010 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 14011 | as_write_fail=0 |
| 14012 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14013 | #! $SHELL |
| 14014 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14015 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14016 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14017 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14018 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14019 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14020 | ac_cs_recheck=false |
| 14021 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 14022 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14023 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 14024 | export SHELL |
| 14025 | _ASEOF |
| 14026 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 14027 | ## -------------------- ## |
| 14028 | ## M4sh Initialization. ## |
| 14029 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 14030 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14031 | # Be more Bourne compatible |
| 14032 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14033 | 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] | 14034 | emulate sh |
| 14035 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14036 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14037 | # is contrary to our usage. Disable this feature. |
| 14038 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14039 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 14040 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14041 | case `(set -o) 2>/dev/null` in #( |
| 14042 | *posix*) : |
| 14043 | set -o posix ;; #( |
| 14044 | *) : |
| 14045 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14046 | esac |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14047 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 14048 | |
| 14049 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14050 | as_nl=' |
| 14051 | ' |
| 14052 | export as_nl |
| 14053 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 14054 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 14055 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 14056 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 14057 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 14058 | # but without wasting forks for bash or zsh. |
| 14059 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 14060 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 14061 | as_echo='print -r --' |
| 14062 | as_echo_n='print -rn --' |
| 14063 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 14064 | as_echo='printf %s\n' |
| 14065 | as_echo_n='printf %s' |
| 14066 | else |
| 14067 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 14068 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 14069 | as_echo_n='/usr/ucb/echo -n' |
| 14070 | else |
| 14071 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 14072 | as_echo_n_body='eval |
| 14073 | arg=$1; |
| 14074 | case $arg in #( |
| 14075 | *"$as_nl"*) |
| 14076 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 14077 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 14078 | esac; |
| 14079 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 14080 | ' |
| 14081 | export as_echo_n_body |
| 14082 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 14083 | fi |
| 14084 | export as_echo_body |
| 14085 | as_echo='sh -c $as_echo_body as_echo' |
| 14086 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14087 | |
| 14088 | # The user is always right. |
| 14089 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14090 | PATH_SEPARATOR=: |
| 14091 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 14092 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 14093 | PATH_SEPARATOR=';' |
| 14094 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14095 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14096 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14097 | |
| 14098 | # IFS |
| 14099 | # We need space, tab and new line, in precisely that order. Quoting is |
| 14100 | # there to prevent editors from complaining about space-tab. |
| 14101 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 14102 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14103 | IFS=" "" $as_nl" |
| 14104 | |
| 14105 | # 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] | 14106 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14107 | *[\\/]* ) as_myself=$0 ;; |
| 14108 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14109 | for as_dir in $PATH |
| 14110 | do |
| 14111 | IFS=$as_save_IFS |
| 14112 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14113 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 14114 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14115 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14116 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14117 | ;; |
| 14118 | esac |
| 14119 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 14120 | # in which case we are not to be found in the path. |
| 14121 | if test "x$as_myself" = x; then |
| 14122 | as_myself=$0 |
| 14123 | fi |
| 14124 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14125 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 14126 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14127 | fi |
| 14128 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14129 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 14130 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 14131 | # suppresses any "Segmentation fault" message there. '((' could |
| 14132 | # trigger a bug in pdksh 5.2.14. |
| 14133 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 14134 | do eval test x\${$as_var+set} = xset \ |
| 14135 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14136 | done |
| 14137 | PS1='$ ' |
| 14138 | PS2='> ' |
| 14139 | PS4='+ ' |
| 14140 | |
| 14141 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14142 | LC_ALL=C |
| 14143 | export LC_ALL |
| 14144 | LANGUAGE=C |
| 14145 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14146 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14147 | # CDPATH. |
| 14148 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 14149 | |
| 14150 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14151 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 14152 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14153 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 14154 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14155 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14156 | as_fn_error () |
| 14157 | { |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14158 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 14159 | if test "$4"; then |
| 14160 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 14161 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14162 | fi |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14163 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14164 | as_fn_exit $as_status |
| 14165 | } # as_fn_error |
| 14166 | |
| 14167 | |
| 14168 | # as_fn_set_status STATUS |
| 14169 | # ----------------------- |
| 14170 | # Set $? to STATUS, without forking. |
| 14171 | as_fn_set_status () |
| 14172 | { |
| 14173 | return $1 |
| 14174 | } # as_fn_set_status |
| 14175 | |
| 14176 | # as_fn_exit STATUS |
| 14177 | # ----------------- |
| 14178 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 14179 | as_fn_exit () |
| 14180 | { |
| 14181 | set +e |
| 14182 | as_fn_set_status $1 |
| 14183 | exit $1 |
| 14184 | } # as_fn_exit |
| 14185 | |
| 14186 | # as_fn_unset VAR |
| 14187 | # --------------- |
| 14188 | # Portably unset VAR. |
| 14189 | as_fn_unset () |
| 14190 | { |
| 14191 | { eval $1=; unset $1;} |
| 14192 | } |
| 14193 | as_unset=as_fn_unset |
| 14194 | # as_fn_append VAR VALUE |
| 14195 | # ---------------------- |
| 14196 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 14197 | # advantage of any shell optimizations that allow amortized linear growth over |
| 14198 | # repeated appends, instead of the typical quadratic growth present in naive |
| 14199 | # implementations. |
| 14200 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 14201 | eval 'as_fn_append () |
| 14202 | { |
| 14203 | eval $1+=\$2 |
| 14204 | }' |
| 14205 | else |
| 14206 | as_fn_append () |
| 14207 | { |
| 14208 | eval $1=\$$1\$2 |
| 14209 | } |
| 14210 | fi # as_fn_append |
| 14211 | |
| 14212 | # as_fn_arith ARG... |
| 14213 | # ------------------ |
| 14214 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 14215 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 14216 | # must be portable across $(()) and expr. |
| 14217 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 14218 | eval 'as_fn_arith () |
| 14219 | { |
| 14220 | as_val=$(( $* )) |
| 14221 | }' |
| 14222 | else |
| 14223 | as_fn_arith () |
| 14224 | { |
| 14225 | as_val=`expr "$@" || test $? -eq 1` |
| 14226 | } |
| 14227 | fi # as_fn_arith |
| 14228 | |
| 14229 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14230 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 14231 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 14232 | as_expr=expr |
| 14233 | else |
| 14234 | as_expr=false |
| 14235 | fi |
| 14236 | |
| 14237 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 14238 | as_basename=basename |
| 14239 | else |
| 14240 | as_basename=false |
| 14241 | fi |
| 14242 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14243 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 14244 | as_dirname=dirname |
| 14245 | else |
| 14246 | as_dirname=false |
| 14247 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14248 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14249 | as_me=`$as_basename -- "$0" || |
| 14250 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 14251 | X"$0" : 'X\(//\)$' \| \ |
| 14252 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14253 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14254 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 14255 | s//\1/ |
| 14256 | q |
| 14257 | } |
| 14258 | /^X\/\(\/\/\)$/{ |
| 14259 | s//\1/ |
| 14260 | q |
| 14261 | } |
| 14262 | /^X\/\(\/\).*/{ |
| 14263 | s//\1/ |
| 14264 | q |
| 14265 | } |
| 14266 | s/.*/./; q'` |
| 14267 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14268 | # Avoid depending upon Character Ranges. |
| 14269 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 14270 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14271 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14272 | as_cr_digits='0123456789' |
| 14273 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14274 | |
| 14275 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14276 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14277 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14278 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14279 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14280 | xy) ECHO_C='\c';; |
| 14281 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 14282 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14283 | esac;; |
| 14284 | *) |
| 14285 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14286 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14287 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14288 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14289 | if test -d conf$$.dir; then |
| 14290 | rm -f conf$$.dir/conf$$.file |
| 14291 | else |
| 14292 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14293 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14294 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14295 | if (echo >conf$$.file) 2>/dev/null; then |
| 14296 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 14297 | as_ln_s='ln -s' |
| 14298 | # ... but there are two gotchas: |
| 14299 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 14300 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 14301 | # In both cases, we have to default to `cp -p'. |
| 14302 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 14303 | as_ln_s='cp -p' |
| 14304 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 14305 | as_ln_s=ln |
| 14306 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14307 | as_ln_s='cp -p' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14308 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14309 | else |
| 14310 | as_ln_s='cp -p' |
| 14311 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14312 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 14313 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14314 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14315 | |
| 14316 | # as_fn_mkdir_p |
| 14317 | # ------------- |
| 14318 | # Create "$as_dir" as a directory, including parents if necessary. |
| 14319 | as_fn_mkdir_p () |
| 14320 | { |
| 14321 | |
| 14322 | case $as_dir in #( |
| 14323 | -*) as_dir=./$as_dir;; |
| 14324 | esac |
| 14325 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 14326 | as_dirs= |
| 14327 | while :; do |
| 14328 | case $as_dir in #( |
| 14329 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 14330 | *) as_qdir=$as_dir;; |
| 14331 | esac |
| 14332 | as_dirs="'$as_qdir' $as_dirs" |
| 14333 | as_dir=`$as_dirname -- "$as_dir" || |
| 14334 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 14335 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 14336 | X"$as_dir" : 'X\(//\)$' \| \ |
| 14337 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 14338 | $as_echo X"$as_dir" | |
| 14339 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14340 | s//\1/ |
| 14341 | q |
| 14342 | } |
| 14343 | /^X\(\/\/\)[^/].*/{ |
| 14344 | s//\1/ |
| 14345 | q |
| 14346 | } |
| 14347 | /^X\(\/\/\)$/{ |
| 14348 | s//\1/ |
| 14349 | q |
| 14350 | } |
| 14351 | /^X\(\/\).*/{ |
| 14352 | s//\1/ |
| 14353 | q |
| 14354 | } |
| 14355 | s/.*/./; q'` |
| 14356 | test -d "$as_dir" && break |
| 14357 | done |
| 14358 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14359 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14360 | |
| 14361 | |
| 14362 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14363 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14364 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14365 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14366 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14367 | as_mkdir_p=false |
| 14368 | fi |
| 14369 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14370 | if test -x / >/dev/null 2>&1; then |
| 14371 | as_test_x='test -x' |
| 14372 | else |
| 14373 | if ls -dL / >/dev/null 2>&1; then |
| 14374 | as_ls_L_option=L |
| 14375 | else |
| 14376 | as_ls_L_option= |
| 14377 | fi |
| 14378 | as_test_x=' |
| 14379 | eval sh -c '\'' |
| 14380 | if test -d "$1"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14381 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14382 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14383 | case $1 in #( |
| 14384 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14385 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14386 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14387 | ???[sx]*):;;*)false;;esac;fi |
| 14388 | '\'' sh |
| 14389 | ' |
| 14390 | fi |
| 14391 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14392 | |
| 14393 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14394 | 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] | 14395 | |
| 14396 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14397 | 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] | 14398 | |
| 14399 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14400 | exec 6>&1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14401 | ## ----------------------------------- ## |
| 14402 | ## Main body of $CONFIG_STATUS script. ## |
| 14403 | ## ----------------------------------- ## |
| 14404 | _ASEOF |
| 14405 | 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] | 14406 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14407 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14408 | # 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] | 14409 | # report actual input values of CONFIG_FILES etc. instead of their |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14410 | # values after options handling. |
| 14411 | ac_log=" |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 14412 | This file was extended by python $as_me 3.3, which was |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14413 | generated by GNU Autoconf 2.67. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14414 | |
| 14415 | CONFIG_FILES = $CONFIG_FILES |
| 14416 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 14417 | CONFIG_LINKS = $CONFIG_LINKS |
| 14418 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 14419 | $ $0 $@ |
| 14420 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14421 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 14422 | " |
| 14423 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14424 | _ACEOF |
| 14425 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14426 | case $ac_config_files in *" |
| 14427 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 14428 | esac |
| 14429 | |
| 14430 | case $ac_config_headers in *" |
| 14431 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 14432 | esac |
| 14433 | |
| 14434 | |
| 14435 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14436 | # Files that config.status was made for. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14437 | config_files="$ac_config_files" |
| 14438 | config_headers="$ac_config_headers" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14439 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14440 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14441 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14442 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14443 | ac_cs_usage="\ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14444 | \`$as_me' instantiates files and other configuration actions |
| 14445 | from templates according to the current configuration. Unless the files |
| 14446 | 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] | 14447 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14448 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14449 | |
| 14450 | -h, --help print this help, then exit |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14451 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14452 | --config print configuration, then exit |
| 14453 | -q, --quiet, --silent |
| 14454 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14455 | -d, --debug don't remove temporary files |
| 14456 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14457 | --file=FILE[:TEMPLATE] |
| 14458 | instantiate the configuration file FILE |
| 14459 | --header=FILE[:TEMPLATE] |
| 14460 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14461 | |
| 14462 | Configuration files: |
| 14463 | $config_files |
| 14464 | |
| 14465 | Configuration headers: |
| 14466 | $config_headers |
| 14467 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14468 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 14469 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14470 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14471 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14472 | 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] | 14473 | ac_cs_version="\\ |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 14474 | python config.status 3.3 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14475 | configured by $0, generated by GNU Autoconf 2.67, |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14476 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14477 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14478 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14479 | This config.status script is free software; the Free Software Foundation |
| 14480 | gives unlimited permission to copy, distribute and modify it." |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14481 | |
| 14482 | ac_pwd='$ac_pwd' |
| 14483 | srcdir='$srcdir' |
| 14484 | INSTALL='$INSTALL' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14485 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14486 | _ACEOF |
| 14487 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14488 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14489 | # 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] | 14490 | ac_need_defaults=: |
| 14491 | while test $# != 0 |
| 14492 | do |
| 14493 | case $1 in |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14494 | --*=?*) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14495 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14496 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14497 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14498 | ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14499 | --*=) |
| 14500 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14501 | ac_optarg= |
| 14502 | ac_shift=: |
| 14503 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14504 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14505 | ac_option=$1 |
| 14506 | ac_optarg=$2 |
| 14507 | ac_shift=shift |
| 14508 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14509 | esac |
| 14510 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14511 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14512 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14513 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 14514 | ac_cs_recheck=: ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14515 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14516 | $as_echo "$ac_cs_version"; exit ;; |
| 14517 | --config | --confi | --conf | --con | --co | --c ) |
| 14518 | $as_echo "$ac_cs_config"; exit ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14519 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14520 | debug=: ;; |
| 14521 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14522 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14523 | case $ac_optarg in |
| 14524 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14525 | '') as_fn_error $? "missing file argument" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14526 | esac |
| 14527 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14528 | ac_need_defaults=false;; |
| 14529 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14530 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14531 | case $ac_optarg in |
| 14532 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14533 | esac |
| 14534 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14535 | ac_need_defaults=false;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14536 | --he | --h) |
| 14537 | # Conflict between --help and --header |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14538 | as_fn_error $? "ambiguous option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14539 | Try \`$0 --help' for more information.";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14540 | --help | --hel | -h ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14541 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14542 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 14543 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 14544 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14545 | |
| 14546 | # This is an error. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14547 | -*) as_fn_error $? "unrecognized option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14548 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14549 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14550 | *) as_fn_append ac_config_targets " $1" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14551 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14552 | |
| 14553 | esac |
| 14554 | shift |
| 14555 | done |
| 14556 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14557 | ac_configure_extra_args= |
| 14558 | |
| 14559 | if $ac_cs_silent; then |
| 14560 | exec 6>/dev/null |
| 14561 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 14562 | fi |
| 14563 | |
| 14564 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14565 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14566 | if \$ac_cs_recheck; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14567 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 14568 | shift |
| 14569 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 14570 | CONFIG_SHELL='$SHELL' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14571 | export CONFIG_SHELL |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14572 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14573 | fi |
| 14574 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14575 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14576 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14577 | exec 5>>config.log |
| 14578 | { |
| 14579 | echo |
| 14580 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 14581 | ## Running $as_me. ## |
| 14582 | _ASBOX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14583 | $as_echo "$ac_log" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14584 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14585 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14586 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14587 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14588 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14589 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14590 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14591 | |
| 14592 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14593 | for ac_config_target in $ac_config_targets |
| 14594 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14595 | case $ac_config_target in |
| 14596 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 14597 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 14598 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 14599 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 14600 | "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] | 14601 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 14602 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 14603 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 14604 | "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14605 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14606 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14607 | esac |
| 14608 | done |
| 14609 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14610 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14611 | # If the user did not use the arguments to specify the items to instantiate, |
| 14612 | # then the envvar interface is used. Set only those that are not. |
| 14613 | # We use the long form for the default assignment because of an extremely |
| 14614 | # bizarre bug on SunOS 4.1.3. |
| 14615 | if $ac_need_defaults; then |
| 14616 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 14617 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 14618 | fi |
| 14619 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14620 | # Have a temporary directory for convenience. Make it in the build tree |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14621 | # 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] | 14622 | # creating and moving files from /tmp can sometimes cause problems. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14623 | # Hook for its removal unless debugging. |
| 14624 | # Note that there is a small window in which the directory will not be cleaned: |
| 14625 | # 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] | 14626 | $debug || |
| 14627 | { |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14628 | tmp= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14629 | trap 'exit_status=$? |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14630 | { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14631 | ' 0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14632 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14633 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14634 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14635 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14636 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14637 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14638 | test -n "$tmp" && test -d "$tmp" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14639 | } || |
| 14640 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14641 | tmp=./conf$$-$RANDOM |
| 14642 | (umask 077 && mkdir "$tmp") |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14643 | } || 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] | 14644 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14645 | # Set up the scripts for CONFIG_FILES section. |
| 14646 | # No need to generate them if there are no CONFIG_FILES. |
| 14647 | # This happens for instance with `./config.status config.h'. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14648 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14649 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14650 | |
| 14651 | ac_cr=`echo X | tr X '\015'` |
| 14652 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 14653 | # But we know of no other shell where ac_cr would be empty at this |
| 14654 | # point, so we can use a bashism as a fallback. |
| 14655 | if test "x$ac_cr" = x; then |
| 14656 | eval ac_cr=\$\'\\r\' |
| 14657 | fi |
| 14658 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 14659 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14660 | ac_cs_awk_cr='\\r' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14661 | else |
| 14662 | ac_cs_awk_cr=$ac_cr |
| 14663 | fi |
| 14664 | |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14665 | echo 'BEGIN {' >"$tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14666 | _ACEOF |
| 14667 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14668 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14669 | { |
| 14670 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 14671 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 14672 | echo "_ACEOF" |
| 14673 | } >conf$$subs.sh || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14674 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 14675 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14676 | ac_delim='%!_!# ' |
| 14677 | for ac_last_try in false false false false false :; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14678 | . ./conf$$subs.sh || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14679 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14680 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14681 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 14682 | if test $ac_delim_n = $ac_delim_num; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14683 | break |
| 14684 | elif $ac_last_try; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14685 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14686 | else |
| 14687 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14688 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14689 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14690 | rm -f conf$$subs.sh |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14691 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14692 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14693 | cat >>"\$tmp/subs1.awk" <<\\_ACAWK && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14694 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14695 | sed -n ' |
| 14696 | h |
| 14697 | s/^/S["/; s/!.*/"]=/ |
| 14698 | p |
| 14699 | g |
| 14700 | s/^[^!]*!// |
| 14701 | :repl |
| 14702 | t repl |
| 14703 | s/'"$ac_delim"'$// |
| 14704 | t delim |
| 14705 | :nl |
| 14706 | h |
| 14707 | s/\(.\{148\}\)..*/\1/ |
| 14708 | t more1 |
| 14709 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 14710 | p |
| 14711 | n |
| 14712 | b repl |
| 14713 | :more1 |
| 14714 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14715 | p |
| 14716 | g |
| 14717 | s/.\{148\}// |
| 14718 | t nl |
| 14719 | :delim |
| 14720 | h |
| 14721 | s/\(.\{148\}\)..*/\1/ |
| 14722 | t more2 |
| 14723 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 14724 | p |
| 14725 | b |
| 14726 | :more2 |
| 14727 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14728 | p |
| 14729 | g |
| 14730 | s/.\{148\}// |
| 14731 | t delim |
| 14732 | ' <conf$$subs.awk | sed ' |
| 14733 | /^[^""]/{ |
| 14734 | N |
| 14735 | s/\n// |
| 14736 | } |
| 14737 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14738 | rm -f conf$$subs.awk |
| 14739 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14740 | _ACAWK |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14741 | cat >>"\$tmp/subs1.awk" <<_ACAWK && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14742 | for (key in S) S_is_set[key] = 1 |
| 14743 | FS = "" |
| 14744 | |
| 14745 | } |
| 14746 | { |
| 14747 | line = $ 0 |
| 14748 | nfields = split(line, field, "@") |
| 14749 | substed = 0 |
| 14750 | len = length(field[1]) |
| 14751 | for (i = 2; i < nfields; i++) { |
| 14752 | key = field[i] |
| 14753 | keylen = length(key) |
| 14754 | if (S_is_set[key]) { |
| 14755 | value = S[key] |
| 14756 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 14757 | len += length(value) + length(field[++i]) |
| 14758 | substed = 1 |
| 14759 | } else |
| 14760 | len += 1 + keylen |
| 14761 | } |
| 14762 | |
| 14763 | print line |
| 14764 | } |
| 14765 | |
| 14766 | _ACAWK |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14767 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14768 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14769 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 14770 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 14771 | else |
| 14772 | cat |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14773 | fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14774 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14775 | _ACEOF |
| 14776 | |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14777 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
| 14778 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14779 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 14780 | # (actually we leave an empty line to preserve line numbers). |
| 14781 | if test "x$srcdir" = x.; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14782 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
| 14783 | h |
| 14784 | s/// |
| 14785 | s/^/:/ |
| 14786 | s/[ ]*$/:/ |
| 14787 | s/:\$(srcdir):/:/g |
| 14788 | s/:\${srcdir}:/:/g |
| 14789 | s/:@srcdir@:/:/g |
| 14790 | s/^:*// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14791 | s/:*$// |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14792 | x |
| 14793 | s/\(=[ ]*\).*/\1/ |
| 14794 | G |
| 14795 | s/\n// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14796 | s/^[^=]*=[ ]*$// |
| 14797 | }' |
| 14798 | fi |
| 14799 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14800 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14801 | fi # test -n "$CONFIG_FILES" |
| 14802 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14803 | # Set up the scripts for CONFIG_HEADERS section. |
| 14804 | # No need to generate them if there are no CONFIG_HEADERS. |
| 14805 | # This happens for instance with `./config.status Makefile'. |
| 14806 | if test -n "$CONFIG_HEADERS"; then |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14807 | cat >"$tmp/defines.awk" <<\_ACAWK || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14808 | BEGIN { |
| 14809 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14810 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14811 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 14812 | # here-document in config.status, that substitutes the proper values into |
| 14813 | # config.h.in to produce config.h. |
| 14814 | |
| 14815 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 14816 | # handling of long lines. |
| 14817 | ac_delim='%!_!# ' |
| 14818 | for ac_last_try in false false :; do |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14819 | ac_t=`sed -n "/$ac_delim/p" confdefs.h` |
| 14820 | if test -z "$ac_t"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14821 | break |
| 14822 | elif $ac_last_try; then |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14823 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14824 | else |
| 14825 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 14826 | fi |
| 14827 | done |
| 14828 | |
| 14829 | # For the awk script, D is an array of macro values keyed by name, |
| 14830 | # likewise P contains macro parameters if any. Preserve backslash |
| 14831 | # newline sequences. |
| 14832 | |
| 14833 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 14834 | sed -n ' |
| 14835 | s/.\{148\}/&'"$ac_delim"'/g |
| 14836 | t rset |
| 14837 | :rset |
| 14838 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 14839 | t def |
| 14840 | d |
| 14841 | :def |
| 14842 | s/\\$// |
| 14843 | t bsnl |
| 14844 | s/["\\]/\\&/g |
| 14845 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14846 | D["\1"]=" \3"/p |
| 14847 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 14848 | d |
| 14849 | :bsnl |
| 14850 | s/["\\]/\\&/g |
| 14851 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14852 | D["\1"]=" \3\\\\\\n"\\/p |
| 14853 | t cont |
| 14854 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 14855 | t cont |
| 14856 | d |
| 14857 | :cont |
| 14858 | n |
| 14859 | s/.\{148\}/&'"$ac_delim"'/g |
| 14860 | t clear |
| 14861 | :clear |
| 14862 | s/\\$// |
| 14863 | t bsnlc |
| 14864 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 14865 | d |
| 14866 | :bsnlc |
| 14867 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 14868 | b cont |
| 14869 | ' <confdefs.h | sed ' |
| 14870 | s/'"$ac_delim"'/"\\\ |
| 14871 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14872 | |
| 14873 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14874 | for (key in D) D_is_set[key] = 1 |
| 14875 | FS = "" |
| 14876 | } |
| 14877 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 14878 | line = \$ 0 |
| 14879 | split(line, arg, " ") |
| 14880 | if (arg[1] == "#") { |
| 14881 | defundef = arg[2] |
| 14882 | mac1 = arg[3] |
| 14883 | } else { |
| 14884 | defundef = substr(arg[1], 2) |
| 14885 | mac1 = arg[2] |
| 14886 | } |
| 14887 | split(mac1, mac2, "(") #) |
| 14888 | macro = mac2[1] |
| 14889 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 14890 | if (D_is_set[macro]) { |
| 14891 | # Preserve the white space surrounding the "#". |
| 14892 | print prefix "define", macro P[macro] D[macro] |
| 14893 | next |
| 14894 | } else { |
| 14895 | # Replace #undef with comments. This is necessary, for example, |
| 14896 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 14897 | # on some systems where configure will not decide to define it. |
| 14898 | if (defundef == "undef") { |
| 14899 | print "/*", prefix defundef, macro, "*/" |
| 14900 | next |
| 14901 | } |
| 14902 | } |
| 14903 | } |
| 14904 | { print } |
| 14905 | _ACAWK |
| 14906 | _ACEOF |
| 14907 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14908 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14909 | fi # test -n "$CONFIG_HEADERS" |
| 14910 | |
| 14911 | |
| 14912 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 14913 | shift |
| 14914 | for ac_tag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14915 | do |
| 14916 | case $ac_tag in |
| 14917 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 14918 | esac |
| 14919 | case $ac_mode$ac_tag in |
| 14920 | :[FHL]*:*);; |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14921 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14922 | :[FH]-) ac_tag=-:-;; |
| 14923 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 14924 | esac |
| 14925 | ac_save_IFS=$IFS |
| 14926 | IFS=: |
| 14927 | set x $ac_tag |
| 14928 | IFS=$ac_save_IFS |
| 14929 | shift |
| 14930 | ac_file=$1 |
| 14931 | shift |
| 14932 | |
| 14933 | case $ac_mode in |
| 14934 | :L) ac_source=$1;; |
| 14935 | :[FH]) |
| 14936 | ac_file_inputs= |
| 14937 | for ac_f |
| 14938 | do |
| 14939 | case $ac_f in |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14940 | -) ac_f="$tmp/stdin";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14941 | *) # Look for the file first in the build tree, then in the source tree |
| 14942 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 14943 | # because $ac_f cannot contain `:'. |
| 14944 | test -f "$ac_f" || |
| 14945 | case $ac_f in |
| 14946 | [\\/$]*) false;; |
| 14947 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 14948 | esac || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14949 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14950 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14951 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 14952 | as_fn_append ac_file_inputs " '$ac_f'" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14953 | done |
| 14954 | |
| 14955 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 14956 | # use $as_me), people would be surprised to read: |
| 14957 | # /* config.h. Generated by config.status. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14958 | configure_input='Generated from '` |
| 14959 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 14960 | `' by configure.' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14961 | if test x"$ac_file" != x-; then |
| 14962 | configure_input="$ac_file. $configure_input" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14963 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 14964 | $as_echo "$as_me: creating $ac_file" >&6;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14965 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14966 | # Neutralize special characters interpreted by sed in replacement strings. |
| 14967 | case $configure_input in #( |
| 14968 | *\&* | *\|* | *\\* ) |
| 14969 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 14970 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 14971 | *) ac_sed_conf_input=$configure_input;; |
| 14972 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14973 | |
| 14974 | case $ac_tag in |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 14975 | *:-:* | *:-) cat >"$tmp/stdin" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 14976 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14977 | esac |
| 14978 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14979 | esac |
| 14980 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14981 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14982 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14983 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 14984 | X"$ac_file" : 'X\(//\)$' \| \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14985 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14986 | $as_echo X"$ac_file" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14987 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14988 | s//\1/ |
| 14989 | q |
| 14990 | } |
| 14991 | /^X\(\/\/\)[^/].*/{ |
| 14992 | s//\1/ |
| 14993 | q |
| 14994 | } |
| 14995 | /^X\(\/\/\)$/{ |
| 14996 | s//\1/ |
| 14997 | q |
| 14998 | } |
| 14999 | /^X\(\/\).*/{ |
| 15000 | s//\1/ |
| 15001 | q |
| 15002 | } |
| 15003 | s/.*/./; q'` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15004 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15005 | ac_builddir=. |
| 15006 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15007 | case "$ac_dir" in |
| 15008 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 15009 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15010 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15011 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15012 | 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] | 15013 | case $ac_top_builddir_sub in |
| 15014 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 15015 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 15016 | esac ;; |
| 15017 | esac |
| 15018 | ac_abs_top_builddir=$ac_pwd |
| 15019 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 15020 | # for backward compatibility: |
| 15021 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15022 | |
| 15023 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15024 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15025 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15026 | ac_top_srcdir=$ac_top_builddir_sub |
| 15027 | ac_abs_top_srcdir=$ac_pwd ;; |
| 15028 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15029 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15030 | ac_top_srcdir=$srcdir |
| 15031 | ac_abs_top_srcdir=$srcdir ;; |
| 15032 | *) # Relative name. |
| 15033 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 15034 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 15035 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15036 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15037 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 15038 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15039 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15040 | case $ac_mode in |
| 15041 | :F) |
| 15042 | # |
| 15043 | # CONFIG_FILE |
| 15044 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15045 | |
| 15046 | case $INSTALL in |
| 15047 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15048 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15049 | esac |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15050 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15051 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15052 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15053 | # If the template does not know about datarootdir, expand it. |
| 15054 | # FIXME: This hack should be removed a few years after 2.60. |
| 15055 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15056 | ac_sed_dataroot=' |
| 15057 | /datarootdir/ { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15058 | p |
| 15059 | q |
| 15060 | } |
| 15061 | /@datadir@/p |
| 15062 | /@docdir@/p |
| 15063 | /@infodir@/p |
| 15064 | /@localedir@/p |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15065 | /@mandir@/p' |
| 15066 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15067 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 15068 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15069 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 15070 | $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] | 15071 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15072 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15073 | ac_datarootdir_hack=' |
| 15074 | s&@datadir@&$datadir&g |
| 15075 | s&@docdir@&$docdir&g |
| 15076 | s&@infodir@&$infodir&g |
| 15077 | s&@localedir@&$localedir&g |
| 15078 | s&@mandir@&$mandir&g |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15079 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15080 | esac |
| 15081 | _ACEOF |
| 15082 | |
| 15083 | # Neutralize VPATH when `$srcdir' = `.'. |
| 15084 | # Shell code in configure.ac might set extrasub. |
| 15085 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15086 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 15087 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15088 | $extrasub |
| 15089 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15090 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15091 | :t |
| 15092 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15093 | s|@configure_input@|$ac_sed_conf_input|;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15094 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15095 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15096 | s&@srcdir@&$ac_srcdir&;t t |
| 15097 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 15098 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 15099 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 15100 | s&@builddir@&$ac_builddir&;t t |
| 15101 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 15102 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 15103 | s&@INSTALL@&$ac_INSTALL&;t t |
| 15104 | $ac_datarootdir_hack |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15105 | " |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15106 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15107 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15108 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15109 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15110 | { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && |
| 15111 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15112 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15113 | which seems to be undefined. Please make sure it is defined" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15114 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15115 | which seems to be undefined. Please make sure it is defined" >&2;} |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 15116 | |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15117 | rm -f "$tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15118 | case $ac_file in |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15119 | -) cat "$tmp/out" && rm -f "$tmp/out";; |
| 15120 | *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15121 | esac \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15122 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15123 | ;; |
| 15124 | :H) |
| 15125 | # |
| 15126 | # CONFIG_HEADER |
| 15127 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15128 | if test x"$ac_file" != x-; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15129 | { |
| 15130 | $as_echo "/* $configure_input */" \ |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15131 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" |
| 15132 | } >"$tmp/config.h" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15133 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15134 | if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15135 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 15136 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15137 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15138 | rm -f "$ac_file" |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15139 | mv "$tmp/config.h" "$ac_file" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15140 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15141 | fi |
| 15142 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15143 | $as_echo "/* $configure_input */" \ |
Benjamin Peterson | 316e02b | 2011-05-10 15:01:56 -0500 | [diff] [blame] | 15144 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15145 | || as_fn_error $? "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15146 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15147 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 15148 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15149 | |
| 15150 | esac |
| 15151 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 15152 | |
| 15153 | case $ac_file$ac_mode in |
| 15154 | "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;; |
| 15155 | |
| 15156 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15157 | done # for ac_tag |
| 15158 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15159 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15160 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15161 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15162 | ac_clean_files=$ac_clean_files_save |
| 15163 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15164 | test $ac_write_fail = 0 || |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15165 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15166 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15167 | |
| 15168 | # configure is writing to config.log, and then calls config.status. |
| 15169 | # config.status does its own redirection, appending to config.log. |
| 15170 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 15171 | # by configure, so config.status won't be able to write to it; its |
| 15172 | # output is simply discarded. So we exec the FD to /dev/null, |
| 15173 | # effectively closing config.log, so it can be properly (re)opened and |
| 15174 | # appended to by config.status. When coming back to configure, we |
| 15175 | # need to make the FD available again. |
| 15176 | if test "$no_create" != yes; then |
| 15177 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15178 | ac_config_status_args= |
| 15179 | test "$silent" = yes && |
| 15180 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15181 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15182 | $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] | 15183 | exec 5>>config.log |
| 15184 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 15185 | # would make configure fail if this is the last instruction. |
Ross Lagerwall | b0ae53d | 2011-06-10 07:30:30 +0200 | [diff] [blame^] | 15186 | $ac_cs_success || as_fn_exit 1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15187 | fi |
| 15188 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 15189 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 15190 | $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] | 15191 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15192 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15193 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15194 | echo "creating Modules/Setup" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15195 | if test ! -f Modules/Setup |
| 15196 | then |
| 15197 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 15198 | fi |
| 15199 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15200 | echo "creating Modules/Setup.local" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15201 | if test ! -f Modules/Setup.local |
| 15202 | then |
| 15203 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 15204 | fi |
| 15205 | |
| 15206 | echo "creating Makefile" |
| 15207 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 15208 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 15209 | Modules/Setup.local Modules/Setup |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 15210 | mv config.c Modules |