Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Georg Brandl | 1ca2e79 | 2011-03-05 20:51:24 +0100 | [diff] [blame] | 2 | # From configure.in Revision. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3 | # Guess values for system-dependent variables and create Makefiles. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4 | # Generated by GNU Autoconf 2.68 for python 3.2. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5 | # |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 6 | # Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 7 | # |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8 | # |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software |
| 11 | # Foundation, Inc. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12 | # |
| 13 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14 | # This configure script is free software; the Free Software Foundation |
| 15 | # gives unlimited permission to copy, distribute and modify it. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 16 | ## -------------------- ## |
| 17 | ## M4sh Initialization. ## |
| 18 | ## -------------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 19 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 20 | # Be more Bourne compatible |
| 21 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 22 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 23 | emulate sh |
| 24 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 25 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 26 | # is contrary to our usage. Disable this feature. |
| 27 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 28 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 29 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 30 | case `(set -o) 2>/dev/null` in #( |
| 31 | *posix*) : |
| 32 | set -o posix ;; #( |
| 33 | *) : |
| 34 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 35 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 36 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 37 | |
| 38 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 39 | as_nl=' |
| 40 | ' |
| 41 | export as_nl |
| 42 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 43 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 44 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 45 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 46 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 47 | # but without wasting forks for bash or zsh. |
| 48 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 49 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 50 | as_echo='print -r --' |
| 51 | as_echo_n='print -rn --' |
| 52 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 53 | as_echo='printf %s\n' |
| 54 | as_echo_n='printf %s' |
| 55 | else |
| 56 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 57 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 58 | as_echo_n='/usr/ucb/echo -n' |
| 59 | else |
| 60 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 61 | as_echo_n_body='eval |
| 62 | arg=$1; |
| 63 | case $arg in #( |
| 64 | *"$as_nl"*) |
| 65 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 66 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 67 | esac; |
| 68 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 69 | ' |
| 70 | export as_echo_n_body |
| 71 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 72 | fi |
| 73 | export as_echo_body |
| 74 | as_echo='sh -c $as_echo_body as_echo' |
| 75 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 76 | |
| 77 | # The user is always right. |
| 78 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 79 | PATH_SEPARATOR=: |
| 80 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 81 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 82 | PATH_SEPARATOR=';' |
| 83 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 84 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 85 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 86 | |
| 87 | # IFS |
| 88 | # We need space, tab and new line, in precisely that order. Quoting is |
| 89 | # there to prevent editors from complaining about space-tab. |
| 90 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 91 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 92 | IFS=" "" $as_nl" |
| 93 | |
| 94 | # Find who we are. Look in the path if we contain no directory separator. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 95 | as_myself= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 96 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 97 | *[\\/]* ) as_myself=$0 ;; |
| 98 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 99 | for as_dir in $PATH |
| 100 | do |
| 101 | IFS=$as_save_IFS |
| 102 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 103 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 104 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 105 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 106 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 107 | ;; |
| 108 | esac |
| 109 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 110 | # in which case we are not to be found in the path. |
| 111 | if test "x$as_myself" = x; then |
| 112 | as_myself=$0 |
| 113 | fi |
| 114 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 115 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 116 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 117 | fi |
| 118 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 119 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 120 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 121 | # suppresses any "Segmentation fault" message there. '((' could |
| 122 | # trigger a bug in pdksh 5.2.14. |
| 123 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 124 | do eval test x\${$as_var+set} = xset \ |
| 125 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 126 | done |
| 127 | PS1='$ ' |
| 128 | PS2='> ' |
| 129 | PS4='+ ' |
| 130 | |
| 131 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 132 | LC_ALL=C |
| 133 | export LC_ALL |
| 134 | LANGUAGE=C |
| 135 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 136 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 137 | # CDPATH. |
| 138 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 139 | |
| 140 | if test "x$CONFIG_SHELL" = x; then |
| 141 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : |
| 142 | emulate sh |
| 143 | NULLCMD=: |
| 144 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which |
| 145 | # is contrary to our usage. Disable this feature. |
| 146 | alias -g '\${1+\"\$@\"}'='\"\$@\"' |
| 147 | setopt NO_GLOB_SUBST |
| 148 | else |
| 149 | case \`(set -o) 2>/dev/null\` in #( |
| 150 | *posix*) : |
| 151 | set -o posix ;; #( |
| 152 | *) : |
| 153 | ;; |
| 154 | esac |
| 155 | fi |
| 156 | " |
| 157 | as_required="as_fn_return () { (exit \$1); } |
| 158 | as_fn_success () { as_fn_return 0; } |
| 159 | as_fn_failure () { as_fn_return 1; } |
| 160 | as_fn_ret_success () { return 0; } |
| 161 | as_fn_ret_failure () { return 1; } |
| 162 | |
| 163 | exitcode=0 |
| 164 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } |
| 165 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } |
| 166 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } |
| 167 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } |
| 168 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : |
| 169 | |
| 170 | else |
| 171 | exitcode=1; echo positional parameters were not saved. |
| 172 | fi |
| 173 | test x\$exitcode = x0 || exit 1" |
| 174 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
| 175 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO |
| 176 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && |
| 177 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 |
| 178 | test \$(( 1 + 1 )) = 2 || exit 1" |
| 179 | if (eval "$as_required") 2>/dev/null; then : |
| 180 | as_have_required=yes |
| 181 | else |
| 182 | as_have_required=no |
| 183 | fi |
| 184 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : |
| 185 | |
| 186 | else |
| 187 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 188 | as_found=false |
| 189 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH |
| 190 | do |
| 191 | IFS=$as_save_IFS |
| 192 | test -z "$as_dir" && as_dir=. |
| 193 | as_found=: |
| 194 | case $as_dir in #( |
| 195 | /*) |
| 196 | for as_base in sh bash ksh sh5; do |
| 197 | # Try only shells that exist, to save several forks. |
| 198 | as_shell=$as_dir/$as_base |
| 199 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && |
| 200 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 201 | CONFIG_SHELL=$as_shell as_have_required=yes |
| 202 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : |
| 203 | break 2 |
| 204 | fi |
| 205 | fi |
| 206 | done;; |
| 207 | esac |
| 208 | as_found=false |
| 209 | done |
| 210 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && |
| 211 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : |
| 212 | CONFIG_SHELL=$SHELL as_have_required=yes |
| 213 | fi; } |
| 214 | IFS=$as_save_IFS |
| 215 | |
| 216 | |
| 217 | if test "x$CONFIG_SHELL" != x; then : |
| 218 | # We cannot yet assume a decent shell, so we have to provide a |
| 219 | # neutralization value for shells without unset; and this also |
| 220 | # works around shells that cannot unset nonexistent variables. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 221 | # Preserve -v and -x to the replacement shell. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 222 | BASH_ENV=/dev/null |
| 223 | ENV=/dev/null |
| 224 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV |
| 225 | export CONFIG_SHELL |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 226 | case $- in # (((( |
| 227 | *v*x* | *x*v* ) as_opts=-vx ;; |
| 228 | *v* ) as_opts=-v ;; |
| 229 | *x* ) as_opts=-x ;; |
| 230 | * ) as_opts= ;; |
| 231 | esac |
| 232 | exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 233 | fi |
| 234 | |
| 235 | if test x$as_have_required = xno; then : |
| 236 | $as_echo "$0: This script requires a shell more modern than all" |
| 237 | $as_echo "$0: the shells that I found on your system." |
| 238 | if test x${ZSH_VERSION+set} = xset ; then |
| 239 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" |
| 240 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." |
| 241 | else |
| 242 | $as_echo "$0: Please tell bug-autoconf@gnu.org and |
| 243 | $0: http://bugs.python.org/ about your system, including |
| 244 | $0: any error possibly output before this message. Then |
| 245 | $0: install a modern shell, or manually run the script |
| 246 | $0: under such a shell if you do have one." |
| 247 | fi |
| 248 | exit 1 |
| 249 | fi |
| 250 | fi |
| 251 | fi |
| 252 | SHELL=${CONFIG_SHELL-/bin/sh} |
| 253 | export SHELL |
| 254 | # Unset more variables known to interfere with behavior of common tools. |
| 255 | CLICOLOR_FORCE= GREP_OPTIONS= |
| 256 | unset CLICOLOR_FORCE GREP_OPTIONS |
| 257 | |
| 258 | ## --------------------- ## |
| 259 | ## M4sh Shell Functions. ## |
| 260 | ## --------------------- ## |
| 261 | # as_fn_unset VAR |
| 262 | # --------------- |
| 263 | # Portably unset VAR. |
| 264 | as_fn_unset () |
| 265 | { |
| 266 | { eval $1=; unset $1;} |
| 267 | } |
| 268 | as_unset=as_fn_unset |
| 269 | |
| 270 | # as_fn_set_status STATUS |
| 271 | # ----------------------- |
| 272 | # Set $? to STATUS, without forking. |
| 273 | as_fn_set_status () |
| 274 | { |
| 275 | return $1 |
| 276 | } # as_fn_set_status |
| 277 | |
| 278 | # as_fn_exit STATUS |
| 279 | # ----------------- |
| 280 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 281 | as_fn_exit () |
| 282 | { |
| 283 | set +e |
| 284 | as_fn_set_status $1 |
| 285 | exit $1 |
| 286 | } # as_fn_exit |
| 287 | |
| 288 | # as_fn_mkdir_p |
| 289 | # ------------- |
| 290 | # Create "$as_dir" as a directory, including parents if necessary. |
| 291 | as_fn_mkdir_p () |
| 292 | { |
| 293 | |
| 294 | case $as_dir in #( |
| 295 | -*) as_dir=./$as_dir;; |
| 296 | esac |
| 297 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 298 | as_dirs= |
| 299 | while :; do |
| 300 | case $as_dir in #( |
| 301 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 302 | *) as_qdir=$as_dir;; |
| 303 | esac |
| 304 | as_dirs="'$as_qdir' $as_dirs" |
| 305 | as_dir=`$as_dirname -- "$as_dir" || |
| 306 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 307 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 308 | X"$as_dir" : 'X\(//\)$' \| \ |
| 309 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 310 | $as_echo X"$as_dir" | |
| 311 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 312 | s//\1/ |
| 313 | q |
| 314 | } |
| 315 | /^X\(\/\/\)[^/].*/{ |
| 316 | s//\1/ |
| 317 | q |
| 318 | } |
| 319 | /^X\(\/\/\)$/{ |
| 320 | s//\1/ |
| 321 | q |
| 322 | } |
| 323 | /^X\(\/\).*/{ |
| 324 | s//\1/ |
| 325 | q |
| 326 | } |
| 327 | s/.*/./; q'` |
| 328 | test -d "$as_dir" && break |
| 329 | done |
| 330 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 331 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 332 | |
| 333 | |
| 334 | } # as_fn_mkdir_p |
| 335 | # as_fn_append VAR VALUE |
| 336 | # ---------------------- |
| 337 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 338 | # advantage of any shell optimizations that allow amortized linear growth over |
| 339 | # repeated appends, instead of the typical quadratic growth present in naive |
| 340 | # implementations. |
| 341 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 342 | eval 'as_fn_append () |
| 343 | { |
| 344 | eval $1+=\$2 |
| 345 | }' |
| 346 | else |
| 347 | as_fn_append () |
| 348 | { |
| 349 | eval $1=\$$1\$2 |
| 350 | } |
| 351 | fi # as_fn_append |
| 352 | |
| 353 | # as_fn_arith ARG... |
| 354 | # ------------------ |
| 355 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 356 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 357 | # must be portable across $(()) and expr. |
| 358 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 359 | eval 'as_fn_arith () |
| 360 | { |
| 361 | as_val=$(( $* )) |
| 362 | }' |
| 363 | else |
| 364 | as_fn_arith () |
| 365 | { |
| 366 | as_val=`expr "$@" || test $? -eq 1` |
| 367 | } |
| 368 | fi # as_fn_arith |
| 369 | |
| 370 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 371 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 372 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 373 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 374 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 375 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 376 | as_fn_error () |
| 377 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 378 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 379 | if test "$4"; then |
| 380 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 381 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 382 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 383 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 384 | as_fn_exit $as_status |
| 385 | } # as_fn_error |
| 386 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 387 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 388 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 389 | as_expr=expr |
| 390 | else |
| 391 | as_expr=false |
| 392 | fi |
| 393 | |
| 394 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 395 | as_basename=basename |
| 396 | else |
| 397 | as_basename=false |
| 398 | fi |
| 399 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 400 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 401 | as_dirname=dirname |
| 402 | else |
| 403 | as_dirname=false |
| 404 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 405 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 406 | as_me=`$as_basename -- "$0" || |
| 407 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 408 | X"$0" : 'X\(//\)$' \| \ |
| 409 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 410 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 411 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 412 | s//\1/ |
| 413 | q |
| 414 | } |
| 415 | /^X\/\(\/\/\)$/{ |
| 416 | s//\1/ |
| 417 | q |
| 418 | } |
| 419 | /^X\/\(\/\).*/{ |
| 420 | s//\1/ |
| 421 | q |
| 422 | } |
| 423 | s/.*/./; q'` |
| 424 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 425 | # Avoid depending upon Character Ranges. |
| 426 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 427 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 428 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 429 | as_cr_digits='0123456789' |
| 430 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 431 | |
| 432 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 433 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
| 434 | as_lineno_2=$LINENO as_lineno_2a=$LINENO |
| 435 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && |
| 436 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { |
| 437 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 438 | sed -n ' |
| 439 | p |
| 440 | /[$]LINENO/= |
| 441 | ' <$as_myself | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 442 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 443 | s/[$]LINENO.*/&-/ |
| 444 | t lineno |
| 445 | b |
| 446 | :lineno |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 447 | N |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 448 | :loop |
| 449 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 450 | t loop |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 451 | s/-\n.*// |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 452 | ' >$as_me.lineno && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 453 | chmod +x "$as_me.lineno" || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 454 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 455 | |
| 456 | # Don't try to exec as it changes $[0], causing all sort of problems |
| 457 | # (the dirname of $[0] is not the place where we might find the |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 458 | # original and so on. Autoconf is especially sensitive to this). |
| 459 | . "./$as_me.lineno" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 460 | # Exit status is that of the last command. |
| 461 | exit |
| 462 | } |
| 463 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 464 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 465 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 466 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 467 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 468 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 469 | xy) ECHO_C='\c';; |
| 470 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 471 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 472 | esac;; |
| 473 | *) |
| 474 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 475 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 476 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 477 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 478 | if test -d conf$$.dir; then |
| 479 | rm -f conf$$.dir/conf$$.file |
| 480 | else |
| 481 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 482 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 483 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 484 | if (echo >conf$$.file) 2>/dev/null; then |
| 485 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 486 | as_ln_s='ln -s' |
| 487 | # ... but there are two gotchas: |
| 488 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 489 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 490 | # In both cases, we have to default to `cp -p'. |
| 491 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 492 | as_ln_s='cp -p' |
| 493 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 494 | as_ln_s=ln |
| 495 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 496 | as_ln_s='cp -p' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 497 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 498 | else |
| 499 | as_ln_s='cp -p' |
| 500 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 501 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 502 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 503 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 504 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 505 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 506 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 507 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 508 | as_mkdir_p=false |
| 509 | fi |
| 510 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 511 | if test -x / >/dev/null 2>&1; then |
| 512 | as_test_x='test -x' |
| 513 | else |
| 514 | if ls -dL / >/dev/null 2>&1; then |
| 515 | as_ls_L_option=L |
| 516 | else |
| 517 | as_ls_L_option= |
| 518 | fi |
| 519 | as_test_x=' |
| 520 | eval sh -c '\'' |
| 521 | if test -d "$1"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 522 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 523 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 524 | case $1 in #( |
| 525 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 526 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 527 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 528 | ???[sx]*):;;*)false;;esac;fi |
| 529 | '\'' sh |
| 530 | ' |
| 531 | fi |
| 532 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 533 | |
| 534 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 535 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 536 | |
| 537 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 538 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 539 | |
| 540 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 541 | test -n "$DJDIR" || exec 7<&0 </dev/null |
| 542 | exec 6>&1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 543 | |
| 544 | # Name of the host. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 545 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 546 | # so uname gets run too. |
| 547 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` |
| 548 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 549 | # |
| 550 | # Initializations. |
| 551 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 552 | ac_default_prefix=/usr/local |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 553 | ac_clean_files= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 554 | ac_config_libobj_dir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 555 | LIBOBJS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 556 | cross_compiling=no |
| 557 | subdirs= |
| 558 | MFLAGS= |
| 559 | MAKEFLAGS= |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 560 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 561 | # Identity of this package. |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 562 | PACKAGE_NAME='python' |
| 563 | PACKAGE_TARNAME='python' |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 564 | PACKAGE_VERSION='3.2' |
| 565 | PACKAGE_STRING='python 3.2' |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 566 | PACKAGE_BUGREPORT='http://bugs.python.org/' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 567 | PACKAGE_URL='' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 568 | |
| 569 | ac_unique_file="Include/object.h" |
| 570 | # Factoring default headers for most tests. |
| 571 | ac_includes_default="\ |
| 572 | #include <stdio.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 573 | #ifdef HAVE_SYS_TYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 574 | # include <sys/types.h> |
| 575 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 576 | #ifdef HAVE_SYS_STAT_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 577 | # include <sys/stat.h> |
| 578 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 579 | #ifdef STDC_HEADERS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 580 | # include <stdlib.h> |
| 581 | # include <stddef.h> |
| 582 | #else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 583 | # ifdef HAVE_STDLIB_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 584 | # include <stdlib.h> |
| 585 | # endif |
| 586 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 587 | #ifdef HAVE_STRING_H |
| 588 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 589 | # include <memory.h> |
| 590 | # endif |
| 591 | # include <string.h> |
| 592 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 593 | #ifdef HAVE_STRINGS_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 594 | # include <strings.h> |
| 595 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 596 | #ifdef HAVE_INTTYPES_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 597 | # include <inttypes.h> |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 598 | #endif |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 599 | #ifdef HAVE_STDINT_H |
| 600 | # include <stdint.h> |
| 601 | #endif |
| 602 | #ifdef HAVE_UNISTD_H |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 603 | # include <unistd.h> |
| 604 | #endif" |
| 605 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 606 | ac_subst_vars='LTLIBOBJS |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 607 | SRCDIRS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 608 | THREADHEADERS |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 609 | SOABI |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 610 | LIBC |
| 611 | LIBM |
| 612 | HAVE_GETHOSTBYNAME |
| 613 | HAVE_GETHOSTBYNAME_R |
| 614 | HAVE_GETHOSTBYNAME_R_3_ARG |
| 615 | HAVE_GETHOSTBYNAME_R_5_ARG |
| 616 | HAVE_GETHOSTBYNAME_R_6_ARG |
| 617 | LIBOBJS |
| 618 | TRUE |
| 619 | MACHDEP_OBJS |
| 620 | DYNLOADFILE |
| 621 | DLINCLDIR |
| 622 | THREADOBJ |
| 623 | LDLAST |
| 624 | USE_THREAD_MODULE |
| 625 | SIGNAL_OBJS |
| 626 | USE_SIGNAL_MODULE |
| 627 | LIBFFI_INCLUDEDIR |
| 628 | PKG_CONFIG |
| 629 | SHLIBS |
| 630 | CFLAGSFORSHARED |
| 631 | LINKFORSHARED |
| 632 | CCSHARED |
| 633 | BLDSHARED |
| 634 | LDCXXSHARED |
| 635 | LDSHARED |
| 636 | SO |
| 637 | LIBTOOL_CRUFT |
| 638 | OTHER_LIBTOOL_OPT |
| 639 | UNIVERSAL_ARCH_FLAGS |
| 640 | BASECFLAGS |
| 641 | OPT |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 642 | ABIFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 643 | LN |
| 644 | INSTALL_DATA |
| 645 | INSTALL_SCRIPT |
| 646 | INSTALL_PROGRAM |
Georg Brandl | 1ca2e79 | 2011-03-05 20:51:24 +0100 | [diff] [blame] | 647 | HAS_HG |
| 648 | HGBRANCH |
| 649 | HGTAG |
| 650 | HGVERSION |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 651 | SVNVERSION |
| 652 | ARFLAGS |
| 653 | AR |
| 654 | RANLIB |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 655 | USE_INLINE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 656 | GNULD |
| 657 | LINKCC |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 658 | LDVERSION |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 659 | RUNSHARED |
| 660 | INSTSONAME |
| 661 | LDLIBRARYDIR |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 662 | PY3LIBRARY |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 663 | BLDLIBRARY |
| 664 | DLLLIBRARY |
| 665 | LDLIBRARY |
| 666 | LIBRARY |
| 667 | BUILDEXEEXT |
| 668 | EGREP |
| 669 | GREP |
| 670 | CPP |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 671 | NO_AS_NEEDED |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 672 | MAINCC |
| 673 | CXX |
| 674 | OBJEXT |
| 675 | EXEEXT |
| 676 | ac_ct_CC |
| 677 | CPPFLAGS |
| 678 | LDFLAGS |
| 679 | CFLAGS |
| 680 | CC |
| 681 | EXPORT_MACOSX_DEPLOYMENT_TARGET |
| 682 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET |
| 683 | SGI_ABI |
| 684 | MACHDEP |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 685 | FRAMEWORKINSTALLAPPSPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 686 | FRAMEWORKUNIXTOOLSPREFIX |
| 687 | FRAMEWORKALTINSTALLLAST |
| 688 | FRAMEWORKALTINSTALLFIRST |
| 689 | FRAMEWORKINSTALLLAST |
| 690 | FRAMEWORKINSTALLFIRST |
| 691 | PYTHONFRAMEWORKINSTALLDIR |
| 692 | PYTHONFRAMEWORKPREFIX |
| 693 | PYTHONFRAMEWORKDIR |
| 694 | PYTHONFRAMEWORKIDENTIFIER |
| 695 | PYTHONFRAMEWORK |
| 696 | LIPO_32BIT_FLAGS |
| 697 | ARCH_RUN_32BIT |
| 698 | UNIVERSALSDK |
| 699 | CONFIG_ARGS |
| 700 | SOVERSION |
| 701 | VERSION |
| 702 | target_alias |
| 703 | host_alias |
| 704 | build_alias |
| 705 | LIBS |
| 706 | ECHO_T |
| 707 | ECHO_N |
| 708 | ECHO_C |
| 709 | DEFS |
| 710 | mandir |
| 711 | localedir |
| 712 | libdir |
| 713 | psdir |
| 714 | pdfdir |
| 715 | dvidir |
| 716 | htmldir |
| 717 | infodir |
| 718 | docdir |
| 719 | oldincludedir |
| 720 | includedir |
| 721 | localstatedir |
| 722 | sharedstatedir |
| 723 | sysconfdir |
| 724 | datadir |
| 725 | datarootdir |
| 726 | libexecdir |
| 727 | sbindir |
| 728 | bindir |
| 729 | program_transform_name |
| 730 | prefix |
| 731 | exec_prefix |
| 732 | PACKAGE_URL |
| 733 | PACKAGE_BUGREPORT |
| 734 | PACKAGE_STRING |
| 735 | PACKAGE_VERSION |
| 736 | PACKAGE_TARNAME |
| 737 | PACKAGE_NAME |
| 738 | PATH_SEPARATOR |
| 739 | SHELL' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 740 | ac_subst_files='' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 741 | ac_user_opts=' |
| 742 | enable_option_checking |
| 743 | enable_universalsdk |
| 744 | with_universal_archs |
| 745 | with_framework_name |
| 746 | enable_framework |
| 747 | with_gcc |
| 748 | with_cxx_main |
| 749 | with_suffix |
| 750 | enable_shared |
| 751 | enable_profiling |
| 752 | with_pydebug |
| 753 | with_libs |
| 754 | with_system_expat |
| 755 | with_system_ffi |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 756 | enable_loadable_sqlite_extensions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 757 | with_dbmliborder |
| 758 | with_signal_module |
| 759 | with_dec_threads |
| 760 | with_threads |
| 761 | with_thread |
| 762 | enable_ipv6 |
| 763 | with_doc_strings |
| 764 | with_tsc |
| 765 | with_pymalloc |
| 766 | with_valgrind |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 767 | with_fpectl |
| 768 | with_libm |
| 769 | with_libc |
| 770 | enable_big_digits |
| 771 | with_wide_unicode |
| 772 | with_computed_gotos |
| 773 | ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 774 | ac_precious_vars='build_alias |
| 775 | host_alias |
| 776 | target_alias |
| 777 | CC |
| 778 | CFLAGS |
| 779 | LDFLAGS |
| 780 | LIBS |
| 781 | CPPFLAGS |
Barry Warsaw | 14d98ac | 2010-11-24 19:43:47 +0000 | [diff] [blame] | 782 | CPP' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 783 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 784 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 785 | # Initialize some variables set by options. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 786 | ac_init_help= |
| 787 | ac_init_version=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 788 | ac_unrecognized_opts= |
| 789 | ac_unrecognized_sep= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 790 | # The variables have the same names as the options, with |
| 791 | # dashes changed to underlines. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 792 | cache_file=/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 793 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 794 | no_create= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 795 | no_recursion= |
| 796 | prefix=NONE |
| 797 | program_prefix=NONE |
| 798 | program_suffix=NONE |
| 799 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 800 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 801 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 802 | srcdir= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 803 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 804 | x_includes=NONE |
| 805 | x_libraries=NONE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 806 | |
| 807 | # Installation directory options. |
| 808 | # These are left unexpanded so users can "make install exec_prefix=/foo" |
| 809 | # and all the variables that are supposed to be based on exec_prefix |
| 810 | # by default will actually change. |
| 811 | # Use braces instead of parens because sh, perl, etc. also accept them. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 812 | # (The list follows the same order as the GNU Coding Standards.) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 813 | bindir='${exec_prefix}/bin' |
| 814 | sbindir='${exec_prefix}/sbin' |
| 815 | libexecdir='${exec_prefix}/libexec' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 816 | datarootdir='${prefix}/share' |
| 817 | datadir='${datarootdir}' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 818 | sysconfdir='${prefix}/etc' |
| 819 | sharedstatedir='${prefix}/com' |
| 820 | localstatedir='${prefix}/var' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 821 | includedir='${prefix}/include' |
| 822 | oldincludedir='/usr/include' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 823 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
| 824 | infodir='${datarootdir}/info' |
| 825 | htmldir='${docdir}' |
| 826 | dvidir='${docdir}' |
| 827 | pdfdir='${docdir}' |
| 828 | psdir='${docdir}' |
| 829 | libdir='${exec_prefix}/lib' |
| 830 | localedir='${datarootdir}/locale' |
| 831 | mandir='${datarootdir}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 832 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 833 | ac_prev= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 834 | ac_dashdash= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 835 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 836 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 837 | # If the previous option needs an argument, assign it. |
| 838 | if test -n "$ac_prev"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 839 | eval $ac_prev=\$ac_option |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 840 | ac_prev= |
| 841 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 842 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 843 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 844 | case $ac_option in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 845 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
| 846 | *=) ac_optarg= ;; |
| 847 | *) ac_optarg=yes ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 848 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 849 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 850 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 851 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 852 | case $ac_dashdash$ac_option in |
| 853 | --) |
| 854 | ac_dashdash=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 855 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 856 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 857 | ac_prev=bindir ;; |
| 858 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 859 | bindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 860 | |
| 861 | -build | --build | --buil | --bui | --bu) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 862 | ac_prev=build_alias ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 863 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 864 | build_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 865 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 866 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 867 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 868 | ac_prev=cache_file ;; |
| 869 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 870 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 871 | cache_file=$ac_optarg ;; |
| 872 | |
| 873 | --config-cache | -C) |
| 874 | cache_file=config.cache ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 875 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 876 | -datadir | --datadir | --datadi | --datad) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 877 | ac_prev=datadir ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 878 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 879 | datadir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 880 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 881 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
| 882 | | --dataroo | --dataro | --datar) |
| 883 | ac_prev=datarootdir ;; |
| 884 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ |
| 885 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) |
| 886 | datarootdir=$ac_optarg ;; |
| 887 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 888 | -disable-* | --disable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 889 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 890 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 891 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 892 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 893 | ac_useropt_orig=$ac_useropt |
| 894 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 895 | case $ac_user_opts in |
| 896 | *" |
| 897 | "enable_$ac_useropt" |
| 898 | "*) ;; |
| 899 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" |
| 900 | ac_unrecognized_sep=', ';; |
| 901 | esac |
| 902 | eval enable_$ac_useropt=no ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 903 | |
| 904 | -docdir | --docdir | --docdi | --doc | --do) |
| 905 | ac_prev=docdir ;; |
| 906 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) |
| 907 | docdir=$ac_optarg ;; |
| 908 | |
| 909 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) |
| 910 | ac_prev=dvidir ;; |
| 911 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) |
| 912 | dvidir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 913 | |
| 914 | -enable-* | --enable-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 915 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 916 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 917 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 918 | as_fn_error $? "invalid feature name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 919 | ac_useropt_orig=$ac_useropt |
| 920 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 921 | case $ac_user_opts in |
| 922 | *" |
| 923 | "enable_$ac_useropt" |
| 924 | "*) ;; |
| 925 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" |
| 926 | ac_unrecognized_sep=', ';; |
| 927 | esac |
| 928 | eval enable_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 929 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 930 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 931 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 932 | | --exec | --exe | --ex) |
| 933 | ac_prev=exec_prefix ;; |
| 934 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 935 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 936 | | --exec=* | --exe=* | --ex=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 937 | exec_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 938 | |
| 939 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 940 | # Obsolete; use --with-gas. |
| 941 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 942 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 943 | -help | --help | --hel | --he | -h) |
| 944 | ac_init_help=long ;; |
| 945 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) |
| 946 | ac_init_help=recursive ;; |
| 947 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) |
| 948 | ac_init_help=short ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 949 | |
| 950 | -host | --host | --hos | --ho) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 951 | ac_prev=host_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 952 | -host=* | --host=* | --hos=* | --ho=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 953 | host_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 954 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 955 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
| 956 | ac_prev=htmldir ;; |
| 957 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ |
| 958 | | --ht=*) |
| 959 | htmldir=$ac_optarg ;; |
| 960 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 961 | -includedir | --includedir | --includedi | --included | --include \ |
| 962 | | --includ | --inclu | --incl | --inc) |
| 963 | ac_prev=includedir ;; |
| 964 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 965 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 966 | includedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 967 | |
| 968 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 969 | ac_prev=infodir ;; |
| 970 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 971 | infodir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 972 | |
| 973 | -libdir | --libdir | --libdi | --libd) |
| 974 | ac_prev=libdir ;; |
| 975 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 976 | libdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 977 | |
| 978 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 979 | | --libexe | --libex | --libe) |
| 980 | ac_prev=libexecdir ;; |
| 981 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 982 | | --libexe=* | --libex=* | --libe=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 983 | libexecdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 984 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 985 | -localedir | --localedir | --localedi | --localed | --locale) |
| 986 | ac_prev=localedir ;; |
| 987 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) |
| 988 | localedir=$ac_optarg ;; |
| 989 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 990 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 991 | | --localstate | --localstat | --localsta | --localst | --locals) |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 992 | ac_prev=localstatedir ;; |
| 993 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 994 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 995 | localstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 996 | |
| 997 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 998 | ac_prev=mandir ;; |
| 999 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1000 | mandir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1001 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1002 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1003 | # Obsolete; use --without-fp. |
| 1004 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1005 | |
| 1006 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1007 | | --no-cr | --no-c | -n) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1008 | no_create=yes ;; |
| 1009 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1010 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 1011 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 1012 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1013 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1014 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 1015 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 1016 | | --oldin | --oldi | --old | --ol | --o) |
| 1017 | ac_prev=oldincludedir ;; |
| 1018 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 1019 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 1020 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1021 | oldincludedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1022 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1023 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 1024 | ac_prev=prefix ;; |
| 1025 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1026 | prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1027 | |
| 1028 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 1029 | | --program-pre | --program-pr | --program-p) |
| 1030 | ac_prev=program_prefix ;; |
| 1031 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 1032 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1033 | program_prefix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1034 | |
| 1035 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 1036 | | --program-suf | --program-su | --program-s) |
| 1037 | ac_prev=program_suffix ;; |
| 1038 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 1039 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1040 | program_suffix=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1041 | |
| 1042 | -program-transform-name | --program-transform-name \ |
| 1043 | | --program-transform-nam | --program-transform-na \ |
| 1044 | | --program-transform-n | --program-transform- \ |
| 1045 | | --program-transform | --program-transfor \ |
| 1046 | | --program-transfo | --program-transf \ |
| 1047 | | --program-trans | --program-tran \ |
| 1048 | | --progr-tra | --program-tr | --program-t) |
| 1049 | ac_prev=program_transform_name ;; |
| 1050 | -program-transform-name=* | --program-transform-name=* \ |
| 1051 | | --program-transform-nam=* | --program-transform-na=* \ |
| 1052 | | --program-transform-n=* | --program-transform-=* \ |
| 1053 | | --program-transform=* | --program-transfor=* \ |
| 1054 | | --program-transfo=* | --program-transf=* \ |
| 1055 | | --program-trans=* | --program-tran=* \ |
| 1056 | | --progr-tra=* | --program-tr=* | --program-t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1057 | program_transform_name=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1058 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1059 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
| 1060 | ac_prev=pdfdir ;; |
| 1061 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) |
| 1062 | pdfdir=$ac_optarg ;; |
| 1063 | |
| 1064 | -psdir | --psdir | --psdi | --psd | --ps) |
| 1065 | ac_prev=psdir ;; |
| 1066 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) |
| 1067 | psdir=$ac_optarg ;; |
| 1068 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1069 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 1070 | | -silent | --silent | --silen | --sile | --sil) |
| 1071 | silent=yes ;; |
| 1072 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1073 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 1074 | ac_prev=sbindir ;; |
| 1075 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 1076 | | --sbi=* | --sb=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1077 | sbindir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1078 | |
| 1079 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 1080 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 1081 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 1082 | | --sha | --sh) |
| 1083 | ac_prev=sharedstatedir ;; |
| 1084 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 1085 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 1086 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 1087 | | --sha=* | --sh=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1088 | sharedstatedir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1089 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1090 | -site | --site | --sit) |
| 1091 | ac_prev=site ;; |
| 1092 | -site=* | --site=* | --sit=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1093 | site=$ac_optarg ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1094 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1095 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 1096 | ac_prev=srcdir ;; |
| 1097 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1098 | srcdir=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1099 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1100 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 1101 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 1102 | ac_prev=sysconfdir ;; |
| 1103 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 1104 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1105 | sysconfdir=$ac_optarg ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1106 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1107 | -target | --target | --targe | --targ | --tar | --ta | --t) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1108 | ac_prev=target_alias ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1109 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1110 | target_alias=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1111 | |
| 1112 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 1113 | verbose=yes ;; |
| 1114 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1115 | -version | --version | --versio | --versi | --vers | -V) |
| 1116 | ac_init_version=: ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1117 | |
| 1118 | -with-* | --with-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1119 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1120 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1121 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1122 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1123 | ac_useropt_orig=$ac_useropt |
| 1124 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1125 | case $ac_user_opts in |
| 1126 | *" |
| 1127 | "with_$ac_useropt" |
| 1128 | "*) ;; |
| 1129 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" |
| 1130 | ac_unrecognized_sep=', ';; |
| 1131 | esac |
| 1132 | eval with_$ac_useropt=\$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1133 | |
| 1134 | -without-* | --without-*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1135 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1136 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1137 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1138 | as_fn_error $? "invalid package name: $ac_useropt" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1139 | ac_useropt_orig=$ac_useropt |
| 1140 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` |
| 1141 | case $ac_user_opts in |
| 1142 | *" |
| 1143 | "with_$ac_useropt" |
| 1144 | "*) ;; |
| 1145 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" |
| 1146 | ac_unrecognized_sep=', ';; |
| 1147 | esac |
| 1148 | eval with_$ac_useropt=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1149 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1150 | --x) |
| 1151 | # Obsolete; use --with-x. |
| 1152 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1153 | |
| 1154 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 1155 | | --x-incl | --x-inc | --x-in | --x-i) |
| 1156 | ac_prev=x_includes ;; |
| 1157 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 1158 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1159 | x_includes=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1160 | |
| 1161 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 1162 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 1163 | ac_prev=x_libraries ;; |
| 1164 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 1165 | | --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] | 1166 | x_libraries=$ac_optarg ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1167 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1168 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
| 1169 | Try \`$0 --help' for more information" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1170 | ;; |
| 1171 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1172 | *=*) |
| 1173 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` |
| 1174 | # Reject names that are not valid shell variable names. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1175 | case $ac_envvar in #( |
| 1176 | '' | [0-9]* | *[!_$as_cr_alnum]* ) |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1177 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1178 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1179 | eval $ac_envvar=\$ac_optarg |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1180 | export $ac_envvar ;; |
| 1181 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1182 | *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1183 | # FIXME: should be removed in autoconf 3.0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1184 | $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] | 1185 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1186 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1187 | : "${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] | 1188 | ;; |
| 1189 | |
| 1190 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1191 | done |
| 1192 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1193 | if test -n "$ac_prev"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1194 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1195 | as_fn_error $? "missing argument to $ac_option" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1196 | fi |
| 1197 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1198 | if test -n "$ac_unrecognized_opts"; then |
| 1199 | case $enable_option_checking in |
| 1200 | no) ;; |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1201 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1202 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
| 1203 | esac |
| 1204 | fi |
| 1205 | |
| 1206 | # Check all directory arguments for consistency. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1207 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
| 1208 | datadir sysconfdir sharedstatedir localstatedir includedir \ |
| 1209 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ |
| 1210 | libdir localedir mandir |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1211 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1212 | eval ac_val=\$$ac_var |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1213 | # Remove trailing slashes. |
| 1214 | case $ac_val in |
| 1215 | */ ) |
| 1216 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` |
| 1217 | eval $ac_var=\$ac_val;; |
| 1218 | esac |
| 1219 | # Be sure to have absolute directory names. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1220 | case $ac_val in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1221 | [\\/$]* | ?:[\\/]* ) continue;; |
| 1222 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1223 | esac |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1224 | 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] | 1225 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1226 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1227 | # There might be people who depend on the old broken behavior: `$host' |
| 1228 | # used to hold the argument of --host etc. |
| 1229 | # FIXME: To remove some day. |
| 1230 | build=$build_alias |
| 1231 | host=$host_alias |
| 1232 | target=$target_alias |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1233 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1234 | # FIXME: To remove some day. |
| 1235 | if test "x$host_alias" != x; then |
| 1236 | if test "x$build_alias" = x; then |
| 1237 | cross_compiling=maybe |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1238 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. |
| 1239 | 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] | 1240 | elif test "x$build_alias" != "x$host_alias"; then |
| 1241 | cross_compiling=yes |
| 1242 | fi |
| 1243 | fi |
| 1244 | |
| 1245 | ac_tool_prefix= |
| 1246 | test -n "$host_alias" && ac_tool_prefix=$host_alias- |
| 1247 | |
| 1248 | test "$silent" = yes && exec 6>/dev/null |
| 1249 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1250 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1251 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
| 1252 | ac_ls_di=`ls -di .` && |
| 1253 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1254 | as_fn_error $? "working directory cannot be determined" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1255 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1256 | as_fn_error $? "pwd does not report name of working directory" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1257 | |
| 1258 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1259 | # Find the source files, if location was not specified. |
| 1260 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1261 | ac_srcdir_defaulted=yes |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1262 | # Try the directory containing this script, then the parent directory. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1263 | ac_confdir=`$as_dirname -- "$as_myself" || |
| 1264 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 1265 | X"$as_myself" : 'X\(//\)[^/]' \| \ |
| 1266 | X"$as_myself" : 'X\(//\)$' \| \ |
| 1267 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || |
| 1268 | $as_echo X"$as_myself" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1269 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 1270 | s//\1/ |
| 1271 | q |
| 1272 | } |
| 1273 | /^X\(\/\/\)[^/].*/{ |
| 1274 | s//\1/ |
| 1275 | q |
| 1276 | } |
| 1277 | /^X\(\/\/\)$/{ |
| 1278 | s//\1/ |
| 1279 | q |
| 1280 | } |
| 1281 | /^X\(\/\).*/{ |
| 1282 | s//\1/ |
| 1283 | q |
| 1284 | } |
| 1285 | s/.*/./; q'` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1286 | srcdir=$ac_confdir |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1287 | if test ! -r "$srcdir/$ac_unique_file"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1288 | srcdir=.. |
| 1289 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1290 | else |
| 1291 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1292 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1293 | if test ! -r "$srcdir/$ac_unique_file"; then |
| 1294 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1295 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 1296 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1297 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
| 1298 | ac_abs_confdir=`( |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1299 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1300 | pwd)` |
| 1301 | # When building in place, set srcdir=. |
| 1302 | if test "$ac_abs_confdir" = "$ac_pwd"; then |
| 1303 | srcdir=. |
| 1304 | fi |
| 1305 | # Remove unnecessary trailing slashes from srcdir. |
| 1306 | # Double slashes in file names in object file debugging info |
| 1307 | # mess up M-x gdb in Emacs. |
| 1308 | case $srcdir in |
| 1309 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; |
| 1310 | esac |
| 1311 | for ac_var in $ac_precious_vars; do |
| 1312 | eval ac_env_${ac_var}_set=\${${ac_var}+set} |
| 1313 | eval ac_env_${ac_var}_value=\$${ac_var} |
| 1314 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} |
| 1315 | eval ac_cv_env_${ac_var}_value=\$${ac_var} |
| 1316 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1317 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1318 | # |
| 1319 | # Report the --help message. |
| 1320 | # |
| 1321 | if test "$ac_init_help" = "long"; then |
| 1322 | # Omit some internal or obsolete options to make the list less imposing. |
| 1323 | # This message is too long to be a string in the A/UX 3.1 sh. |
| 1324 | cat <<_ACEOF |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1325 | \`configure' configures python 3.2 to adapt to many kinds of systems. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1326 | |
| 1327 | Usage: $0 [OPTION]... [VAR=VALUE]... |
| 1328 | |
| 1329 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
| 1330 | VAR=VALUE. See below for descriptions of some of the useful variables. |
| 1331 | |
| 1332 | Defaults for the options are specified in brackets. |
| 1333 | |
| 1334 | Configuration: |
| 1335 | -h, --help display this help and exit |
| 1336 | --help=short display options specific to this package |
| 1337 | --help=recursive display the short help of all the included packages |
| 1338 | -V, --version display version information and exit |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1339 | -q, --quiet, --silent do not print \`checking ...' messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1340 | --cache-file=FILE cache test results in FILE [disabled] |
| 1341 | -C, --config-cache alias for \`--cache-file=config.cache' |
| 1342 | -n, --no-create do not create output files |
| 1343 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] |
| 1344 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1345 | Installation directories: |
| 1346 | --prefix=PREFIX install architecture-independent files in PREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1347 | [$ac_default_prefix] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1348 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1349 | [PREFIX] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1350 | |
| 1351 | By default, \`make install' will install all the files in |
| 1352 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify |
| 1353 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', |
| 1354 | for instance \`--prefix=\$HOME'. |
| 1355 | |
| 1356 | For better control, use the options below. |
| 1357 | |
| 1358 | Fine tuning of the installation directories: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1359 | --bindir=DIR user executables [EPREFIX/bin] |
| 1360 | --sbindir=DIR system admin executables [EPREFIX/sbin] |
| 1361 | --libexecdir=DIR program executables [EPREFIX/libexec] |
| 1362 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] |
| 1363 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] |
| 1364 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] |
| 1365 | --libdir=DIR object code libraries [EPREFIX/lib] |
| 1366 | --includedir=DIR C header files [PREFIX/include] |
| 1367 | --oldincludedir=DIR C header files for non-gcc [/usr/include] |
| 1368 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] |
| 1369 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] |
| 1370 | --infodir=DIR info documentation [DATAROOTDIR/info] |
| 1371 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] |
| 1372 | --mandir=DIR man documentation [DATAROOTDIR/man] |
| 1373 | --docdir=DIR documentation root [DATAROOTDIR/doc/python] |
| 1374 | --htmldir=DIR html documentation [DOCDIR] |
| 1375 | --dvidir=DIR dvi documentation [DOCDIR] |
| 1376 | --pdfdir=DIR pdf documentation [DOCDIR] |
| 1377 | --psdir=DIR ps documentation [DOCDIR] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1378 | _ACEOF |
| 1379 | |
| 1380 | cat <<\_ACEOF |
| 1381 | _ACEOF |
| 1382 | fi |
| 1383 | |
| 1384 | if test -n "$ac_init_help"; then |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1385 | case $ac_init_help in |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1386 | short | recursive ) echo "Configuration of python 3.2:";; |
Martin v. Löwis | 88afe66 | 2002-10-26 13:47:44 +0000 | [diff] [blame] | 1387 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1388 | cat <<\_ACEOF |
| 1389 | |
| 1390 | Optional Features: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1391 | --disable-option-checking ignore unrecognized --enable/--with options |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1392 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 1393 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
Christian Heimes | 68f5fbe | 2008-02-14 08:27:37 +0000 | [diff] [blame] | 1394 | --enable-universalsdk[=SDKDIR] |
Christian Heimes | 292d351 | 2008-02-03 16:51:08 +0000 | [diff] [blame] | 1395 | Build against Mac OS X 10.4u SDK (ppc/i386) |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1396 | --enable-framework[=INSTALLDIR] |
| 1397 | Build (MacOSX|Darwin) framework |
| 1398 | --enable-shared disable/enable building shared python library |
Skip Montanaro | 56f6a4f | 2004-06-18 02:47:22 +0000 | [diff] [blame] | 1399 | --enable-profiling enable C-level code profiling |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 1400 | --enable-loadable-sqlite-extensions |
| 1401 | support loadable extensions in _sqlite module |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1402 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 1403 | --disable-ipv6 Disable ipv6 support |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 1404 | --enable-big-digits[=BITS] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1405 | use big digits for Python longs [[BITS=30]] |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1406 | |
| 1407 | Optional Packages: |
| 1408 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 1409 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 1410 | --with-universal-archs=ARCH |
| 1411 | select architectures for universal build ("32-bit", |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 1412 | "64-bit", "3-way", "intel" or "all") |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 1413 | --with-framework-name=FRAMEWORK |
| 1414 | specify an alternate name of the framework built |
| 1415 | with --enable-framework |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1416 | --without-gcc never use gcc |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1417 | --with-cxx-main=<compiler> |
| 1418 | compile main() and link python executable with C++ |
| 1419 | compiler |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1420 | --with-suffix=.exe set executable suffix |
| 1421 | --with-pydebug build with Py_DEBUG defined |
| 1422 | --with-libs='lib1 ...' link against additional libs |
Benjamin Peterson | b2d9046 | 2009-12-31 03:23:10 +0000 | [diff] [blame] | 1423 | --with-system-expat build pyexpat module using an installed expat |
| 1424 | library |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 1425 | --with-system-ffi build _ctypes module using an installed ffi library |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 1426 | --with-dbmliborder=db1:db2:... |
| 1427 | order to check db backends for dbm. Valid value is a |
| 1428 | colon separated string with the backend names |
| 1429 | `ndbm', `gdbm' and `bdb'. |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1430 | --with-signal-module disable/enable signal module |
| 1431 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries |
| 1432 | --with(out)-threads[=DIRECTORY] |
| 1433 | disable/enable thread support |
| 1434 | --with(out)-thread[=DIRECTORY] |
| 1435 | deprecated; use --with(out)-threads |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1436 | --with(out)-doc-strings disable/enable documentation strings |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 1437 | --with(out)-tsc enable/disable timestamp counter profile |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1438 | --with(out)-pymalloc disable/enable specialized mallocs |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 1439 | --with-valgrind Enable Valgrind support |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 1440 | --with-fpectl enable SIGFPE catching |
| 1441 | --with-libm=STRING math library |
| 1442 | --with-libc=STRING C library |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 1443 | --with-wide-unicode Use 4-byte Unicode characters (default is 2 bytes) |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 1444 | --with(out)-computed-gotos |
| 1445 | Use computed gotos in evaluation loop (enabled by |
| 1446 | default on supported compilers) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1447 | |
| 1448 | Some influential environment variables: |
| 1449 | CC C compiler command |
| 1450 | CFLAGS C compiler flags |
| 1451 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a |
| 1452 | nonstandard directory <lib dir> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1453 | LIBS libraries to pass to the linker, e.g. -l<library> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1454 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1455 | you have headers in a nonstandard directory <include dir> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1456 | CPP C preprocessor |
| 1457 | |
| 1458 | Use these variables to override the choices made by `configure' or to help |
| 1459 | it to find libraries and programs with nonstandard names/locations. |
| 1460 | |
Georg Brandl | e2e1561 | 2009-05-20 18:25:10 +0000 | [diff] [blame] | 1461 | Report bugs to <http://bugs.python.org/>. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1462 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1463 | ac_status=$? |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1464 | fi |
| 1465 | |
| 1466 | if test "$ac_init_help" = "recursive"; then |
| 1467 | # If there are subdirs, report their specific --help. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1468 | 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] | 1469 | test -d "$ac_dir" || |
| 1470 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || |
| 1471 | continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1472 | ac_builddir=. |
| 1473 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1474 | case "$ac_dir" in |
| 1475 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1476 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1477 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1478 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1479 | 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] | 1480 | case $ac_top_builddir_sub in |
| 1481 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 1482 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 1483 | esac ;; |
| 1484 | esac |
| 1485 | ac_abs_top_builddir=$ac_pwd |
| 1486 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 1487 | # for backward compatibility: |
| 1488 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1489 | |
| 1490 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1491 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1492 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1493 | ac_top_srcdir=$ac_top_builddir_sub |
| 1494 | ac_abs_top_srcdir=$ac_pwd ;; |
| 1495 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1496 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1497 | ac_top_srcdir=$srcdir |
| 1498 | ac_abs_top_srcdir=$srcdir ;; |
| 1499 | *) # Relative name. |
| 1500 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 1501 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 1502 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1503 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1504 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 1505 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1506 | cd "$ac_dir" || { ac_status=$?; continue; } |
| 1507 | # Check for guested configure. |
| 1508 | if test -f "$ac_srcdir/configure.gnu"; then |
| 1509 | echo && |
| 1510 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive |
| 1511 | elif test -f "$ac_srcdir/configure"; then |
| 1512 | echo && |
| 1513 | $SHELL "$ac_srcdir/configure" --help=recursive |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1514 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1515 | $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] | 1516 | fi || ac_status=$? |
| 1517 | cd "$ac_pwd" || { ac_status=$?; break; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1518 | done |
| 1519 | fi |
| 1520 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1521 | test -n "$ac_init_help" && exit $ac_status |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1522 | if $ac_init_version; then |
| 1523 | cat <<\_ACEOF |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 1524 | python configure 3.2 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1525 | generated by GNU Autoconf 2.68 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1526 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1527 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1528 | This configure script is free software; the Free Software Foundation |
| 1529 | gives unlimited permission to copy, distribute and modify it. |
| 1530 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 1531 | exit |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 1532 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1533 | |
| 1534 | ## ------------------------ ## |
| 1535 | ## Autoconf initialization. ## |
| 1536 | ## ------------------------ ## |
| 1537 | |
| 1538 | # ac_fn_c_try_compile LINENO |
| 1539 | # -------------------------- |
| 1540 | # Try to compile conftest.$ac_ext, and return whether this succeeded. |
| 1541 | ac_fn_c_try_compile () |
| 1542 | { |
| 1543 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1544 | rm -f conftest.$ac_objext |
| 1545 | if { { ac_try="$ac_compile" |
| 1546 | case "(($ac_try" in |
| 1547 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1548 | *) ac_try_echo=$ac_try;; |
| 1549 | esac |
| 1550 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1551 | $as_echo "$ac_try_echo"; } >&5 |
| 1552 | (eval "$ac_compile") 2>conftest.err |
| 1553 | ac_status=$? |
| 1554 | if test -s conftest.err; then |
| 1555 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1556 | cat conftest.er1 >&5 |
| 1557 | mv -f conftest.er1 conftest.err |
| 1558 | fi |
| 1559 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1560 | test $ac_status = 0; } && { |
| 1561 | test -z "$ac_c_werror_flag" || |
| 1562 | test ! -s conftest.err |
| 1563 | } && test -s conftest.$ac_objext; then : |
| 1564 | ac_retval=0 |
| 1565 | else |
| 1566 | $as_echo "$as_me: failed program was:" >&5 |
| 1567 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1568 | |
| 1569 | ac_retval=1 |
| 1570 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1571 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1572 | as_fn_set_status $ac_retval |
| 1573 | |
| 1574 | } # ac_fn_c_try_compile |
| 1575 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 1576 | # ac_fn_c_try_link LINENO |
| 1577 | # ----------------------- |
| 1578 | # Try to link conftest.$ac_ext, and return whether this succeeded. |
| 1579 | ac_fn_c_try_link () |
| 1580 | { |
| 1581 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1582 | rm -f conftest.$ac_objext conftest$ac_exeext |
| 1583 | if { { ac_try="$ac_link" |
| 1584 | case "(($ac_try" in |
| 1585 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1586 | *) ac_try_echo=$ac_try;; |
| 1587 | esac |
| 1588 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1589 | $as_echo "$ac_try_echo"; } >&5 |
| 1590 | (eval "$ac_link") 2>conftest.err |
| 1591 | ac_status=$? |
| 1592 | if test -s conftest.err; then |
| 1593 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1594 | cat conftest.er1 >&5 |
| 1595 | mv -f conftest.er1 conftest.err |
| 1596 | fi |
| 1597 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1598 | test $ac_status = 0; } && { |
| 1599 | test -z "$ac_c_werror_flag" || |
| 1600 | test ! -s conftest.err |
| 1601 | } && test -s conftest$ac_exeext && { |
| 1602 | test "$cross_compiling" = yes || |
| 1603 | $as_test_x conftest$ac_exeext |
| 1604 | }; then : |
| 1605 | ac_retval=0 |
| 1606 | else |
| 1607 | $as_echo "$as_me: failed program was:" >&5 |
| 1608 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1609 | |
| 1610 | ac_retval=1 |
| 1611 | fi |
| 1612 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
| 1613 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would |
| 1614 | # interfere with the next link command; also delete a directory that is |
| 1615 | # left behind by Apple's compiler. We do this before executing the actions. |
| 1616 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
| 1617 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
| 1618 | as_fn_set_status $ac_retval |
| 1619 | |
| 1620 | } # ac_fn_c_try_link |
| 1621 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1622 | # ac_fn_c_try_cpp LINENO |
| 1623 | # ---------------------- |
| 1624 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. |
| 1625 | ac_fn_c_try_cpp () |
| 1626 | { |
| 1627 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1628 | if { { ac_try="$ac_cpp conftest.$ac_ext" |
| 1629 | case "(($ac_try" in |
| 1630 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1631 | *) ac_try_echo=$ac_try;; |
| 1632 | esac |
| 1633 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1634 | $as_echo "$ac_try_echo"; } >&5 |
| 1635 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err |
| 1636 | ac_status=$? |
| 1637 | if test -s conftest.err; then |
| 1638 | grep -v '^ *+' conftest.err >conftest.er1 |
| 1639 | cat conftest.er1 >&5 |
| 1640 | mv -f conftest.er1 conftest.err |
| 1641 | fi |
| 1642 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1643 | test $ac_status = 0; } > conftest.i && { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1644 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
| 1645 | test ! -s conftest.err |
| 1646 | }; then : |
| 1647 | ac_retval=0 |
| 1648 | else |
| 1649 | $as_echo "$as_me: failed program was:" >&5 |
| 1650 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1651 | |
| 1652 | ac_retval=1 |
| 1653 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1654 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1655 | as_fn_set_status $ac_retval |
| 1656 | |
| 1657 | } # ac_fn_c_try_cpp |
| 1658 | |
| 1659 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
| 1660 | # ------------------------------------------------------- |
| 1661 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using |
| 1662 | # the include files in INCLUDES and setting the cache variable VAR |
| 1663 | # accordingly. |
| 1664 | ac_fn_c_check_header_mongrel () |
| 1665 | { |
| 1666 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1667 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1669 | $as_echo_n "checking for $2... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1670 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1671 | $as_echo_n "(cached) " >&6 |
| 1672 | fi |
| 1673 | eval ac_res=\$$3 |
| 1674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1675 | $as_echo "$ac_res" >&6; } |
| 1676 | else |
| 1677 | # Is the header compilable? |
| 1678 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 |
| 1679 | $as_echo_n "checking $2 usability... " >&6; } |
| 1680 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1681 | /* end confdefs.h. */ |
| 1682 | $4 |
| 1683 | #include <$2> |
| 1684 | _ACEOF |
| 1685 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1686 | ac_header_compiler=yes |
| 1687 | else |
| 1688 | ac_header_compiler=no |
| 1689 | fi |
| 1690 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1691 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 |
| 1692 | $as_echo "$ac_header_compiler" >&6; } |
| 1693 | |
| 1694 | # Is the header present? |
| 1695 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 |
| 1696 | $as_echo_n "checking $2 presence... " >&6; } |
| 1697 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1698 | /* end confdefs.h. */ |
| 1699 | #include <$2> |
| 1700 | _ACEOF |
| 1701 | if ac_fn_c_try_cpp "$LINENO"; then : |
| 1702 | ac_header_preproc=yes |
| 1703 | else |
| 1704 | ac_header_preproc=no |
| 1705 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1706 | rm -f conftest.err conftest.i conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1707 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
| 1708 | $as_echo "$ac_header_preproc" >&6; } |
| 1709 | |
| 1710 | # So? What about this header? |
| 1711 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( |
| 1712 | yes:no: ) |
| 1713 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 |
| 1714 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} |
| 1715 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1716 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
| 1717 | ;; |
| 1718 | no:yes:* ) |
| 1719 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 |
| 1720 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} |
| 1721 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 |
| 1722 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} |
| 1723 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 |
| 1724 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} |
| 1725 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 |
| 1726 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} |
| 1727 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 |
| 1728 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1729 | ( $as_echo "## -------------------------------------- ## |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1730 | ## Report this to http://bugs.python.org/ ## |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1731 | ## -------------------------------------- ##" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1732 | ) | sed "s/^/$as_me: WARNING: /" >&2 |
| 1733 | ;; |
| 1734 | esac |
| 1735 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1736 | $as_echo_n "checking for $2... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1737 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1738 | $as_echo_n "(cached) " >&6 |
| 1739 | else |
| 1740 | eval "$3=\$ac_header_compiler" |
| 1741 | fi |
| 1742 | eval ac_res=\$$3 |
| 1743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1744 | $as_echo "$ac_res" >&6; } |
| 1745 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1746 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1747 | |
| 1748 | } # ac_fn_c_check_header_mongrel |
| 1749 | |
| 1750 | # ac_fn_c_try_run LINENO |
| 1751 | # ---------------------- |
| 1752 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes |
| 1753 | # that executables *can* be run. |
| 1754 | ac_fn_c_try_run () |
| 1755 | { |
| 1756 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1757 | if { { ac_try="$ac_link" |
| 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_link") 2>&5 |
| 1765 | ac_status=$? |
| 1766 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1767 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' |
| 1768 | { { case "(($ac_try" in |
| 1769 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 1770 | *) ac_try_echo=$ac_try;; |
| 1771 | esac |
| 1772 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 1773 | $as_echo "$ac_try_echo"; } >&5 |
| 1774 | (eval "$ac_try") 2>&5 |
| 1775 | ac_status=$? |
| 1776 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 1777 | test $ac_status = 0; }; }; then : |
| 1778 | ac_retval=0 |
| 1779 | else |
| 1780 | $as_echo "$as_me: program exited with status $ac_status" >&5 |
| 1781 | $as_echo "$as_me: failed program was:" >&5 |
| 1782 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 1783 | |
| 1784 | ac_retval=$ac_status |
| 1785 | fi |
| 1786 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1787 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1788 | as_fn_set_status $ac_retval |
| 1789 | |
| 1790 | } # ac_fn_c_try_run |
| 1791 | |
| 1792 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
| 1793 | # ------------------------------------------------------- |
| 1794 | # Tests whether HEADER exists and can be compiled using the include files in |
| 1795 | # INCLUDES, setting the cache variable VAR accordingly. |
| 1796 | ac_fn_c_check_header_compile () |
| 1797 | { |
| 1798 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1799 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1800 | $as_echo_n "checking for $2... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1801 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1802 | $as_echo_n "(cached) " >&6 |
| 1803 | else |
| 1804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1805 | /* end confdefs.h. */ |
| 1806 | $4 |
| 1807 | #include <$2> |
| 1808 | _ACEOF |
| 1809 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1810 | eval "$3=yes" |
| 1811 | else |
| 1812 | eval "$3=no" |
| 1813 | fi |
| 1814 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1815 | fi |
| 1816 | eval ac_res=\$$3 |
| 1817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1818 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1819 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1820 | |
| 1821 | } # ac_fn_c_check_header_compile |
| 1822 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1823 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
| 1824 | # ------------------------------------------- |
| 1825 | # Tests whether TYPE exists after having included INCLUDES, setting cache |
| 1826 | # variable VAR accordingly. |
| 1827 | ac_fn_c_check_type () |
| 1828 | { |
| 1829 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1830 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 1831 | $as_echo_n "checking for $2... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1832 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1833 | $as_echo_n "(cached) " >&6 |
| 1834 | else |
| 1835 | eval "$3=no" |
| 1836 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1837 | /* end confdefs.h. */ |
| 1838 | $4 |
| 1839 | int |
| 1840 | main () |
| 1841 | { |
| 1842 | if (sizeof ($2)) |
| 1843 | return 0; |
| 1844 | ; |
| 1845 | return 0; |
| 1846 | } |
| 1847 | _ACEOF |
| 1848 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1849 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1850 | /* end confdefs.h. */ |
| 1851 | $4 |
| 1852 | int |
| 1853 | main () |
| 1854 | { |
| 1855 | if (sizeof (($2))) |
| 1856 | return 0; |
| 1857 | ; |
| 1858 | return 0; |
| 1859 | } |
| 1860 | _ACEOF |
| 1861 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1862 | |
| 1863 | else |
| 1864 | eval "$3=yes" |
| 1865 | fi |
| 1866 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1867 | fi |
| 1868 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1869 | fi |
| 1870 | eval ac_res=\$$3 |
| 1871 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1872 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1873 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1874 | |
| 1875 | } # ac_fn_c_check_type |
| 1876 | |
| 1877 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
| 1878 | # ------------------------------------ |
| 1879 | # Finds an unsigned integer type with width BITS, setting cache variable VAR |
| 1880 | # accordingly. |
| 1881 | ac_fn_c_find_uintX_t () |
| 1882 | { |
| 1883 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1884 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 |
| 1885 | $as_echo_n "checking for uint$2_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1886 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1887 | $as_echo_n "(cached) " >&6 |
| 1888 | else |
| 1889 | eval "$3=no" |
| 1890 | # Order is important - never check a type that is potentially smaller |
| 1891 | # than half of the expected target width. |
| 1892 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ |
| 1893 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do |
| 1894 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1895 | /* end confdefs.h. */ |
| 1896 | $ac_includes_default |
| 1897 | int |
| 1898 | main () |
| 1899 | { |
| 1900 | static int test_array [1 - 2 * !((($ac_type) -1 >> ($2 / 2 - 1)) >> ($2 / 2 - 1) == 3)]; |
| 1901 | test_array [0] = 0 |
| 1902 | |
| 1903 | ; |
| 1904 | return 0; |
| 1905 | } |
| 1906 | _ACEOF |
| 1907 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1908 | case $ac_type in #( |
| 1909 | uint$2_t) : |
| 1910 | eval "$3=yes" ;; #( |
| 1911 | *) : |
| 1912 | eval "$3=\$ac_type" ;; |
| 1913 | esac |
| 1914 | fi |
| 1915 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1916 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1917 | |
| 1918 | else |
| 1919 | break |
| 1920 | fi |
| 1921 | done |
| 1922 | fi |
| 1923 | eval ac_res=\$$3 |
| 1924 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1925 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1926 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1927 | |
| 1928 | } # ac_fn_c_find_uintX_t |
| 1929 | |
| 1930 | # ac_fn_c_find_intX_t LINENO BITS VAR |
| 1931 | # ----------------------------------- |
| 1932 | # Finds a signed integer type with width BITS, setting cache variable VAR |
| 1933 | # accordingly. |
| 1934 | ac_fn_c_find_intX_t () |
| 1935 | { |
| 1936 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 1937 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
| 1938 | $as_echo_n "checking for int$2_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1939 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1940 | $as_echo_n "(cached) " >&6 |
| 1941 | else |
| 1942 | eval "$3=no" |
| 1943 | # Order is important - never check a type that is potentially smaller |
| 1944 | # than half of the expected target width. |
| 1945 | for ac_type in int$2_t 'int' 'long int' \ |
| 1946 | 'long long int' 'short int' 'signed char'; do |
| 1947 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1948 | /* end confdefs.h. */ |
| 1949 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1950 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1951 | int |
| 1952 | main () |
| 1953 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1954 | 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] | 1955 | test_array [0] = 0 |
| 1956 | |
| 1957 | ; |
| 1958 | return 0; |
| 1959 | } |
| 1960 | _ACEOF |
| 1961 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 1963 | /* end confdefs.h. */ |
| 1964 | $ac_includes_default |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1965 | enum { N = $2 / 2 - 1 }; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1966 | int |
| 1967 | main () |
| 1968 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1969 | 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] | 1970 | < ($ac_type) ((((($ac_type) 1 << N) << N) - 1) * 2 + 2))]; |
| 1971 | test_array [0] = 0 |
| 1972 | |
| 1973 | ; |
| 1974 | return 0; |
| 1975 | } |
| 1976 | _ACEOF |
| 1977 | if ac_fn_c_try_compile "$LINENO"; then : |
| 1978 | |
| 1979 | else |
| 1980 | case $ac_type in #( |
| 1981 | int$2_t) : |
| 1982 | eval "$3=yes" ;; #( |
| 1983 | *) : |
| 1984 | eval "$3=\$ac_type" ;; |
| 1985 | esac |
| 1986 | fi |
| 1987 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 1988 | fi |
| 1989 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 1990 | if eval test \"x\$"$3"\" = x"no"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 1991 | |
| 1992 | else |
| 1993 | break |
| 1994 | fi |
| 1995 | done |
| 1996 | fi |
| 1997 | eval ac_res=\$$3 |
| 1998 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 1999 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2000 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2001 | |
| 2002 | } # ac_fn_c_find_intX_t |
| 2003 | |
| 2004 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
| 2005 | # -------------------------------------------- |
| 2006 | # Tries to find the compile-time value of EXPR in a program that includes |
| 2007 | # INCLUDES, setting VAR accordingly. Returns whether the value could be |
| 2008 | # computed |
| 2009 | ac_fn_c_compute_int () |
| 2010 | { |
| 2011 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2012 | if test "$cross_compiling" = yes; then |
| 2013 | # Depending upon the size, compute the lo and hi bounds. |
| 2014 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2015 | /* end confdefs.h. */ |
| 2016 | $4 |
| 2017 | int |
| 2018 | main () |
| 2019 | { |
| 2020 | static int test_array [1 - 2 * !(($2) >= 0)]; |
| 2021 | test_array [0] = 0 |
| 2022 | |
| 2023 | ; |
| 2024 | return 0; |
| 2025 | } |
| 2026 | _ACEOF |
| 2027 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2028 | ac_lo=0 ac_mid=0 |
| 2029 | while :; do |
| 2030 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2031 | /* end confdefs.h. */ |
| 2032 | $4 |
| 2033 | int |
| 2034 | main () |
| 2035 | { |
| 2036 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2037 | test_array [0] = 0 |
| 2038 | |
| 2039 | ; |
| 2040 | return 0; |
| 2041 | } |
| 2042 | _ACEOF |
| 2043 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2044 | ac_hi=$ac_mid; break |
| 2045 | else |
| 2046 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val |
| 2047 | if test $ac_lo -le $ac_mid; then |
| 2048 | ac_lo= ac_hi= |
| 2049 | break |
| 2050 | fi |
| 2051 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val |
| 2052 | fi |
| 2053 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2054 | done |
| 2055 | else |
| 2056 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2057 | /* end confdefs.h. */ |
| 2058 | $4 |
| 2059 | int |
| 2060 | main () |
| 2061 | { |
| 2062 | static int test_array [1 - 2 * !(($2) < 0)]; |
| 2063 | test_array [0] = 0 |
| 2064 | |
| 2065 | ; |
| 2066 | return 0; |
| 2067 | } |
| 2068 | _ACEOF |
| 2069 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2070 | ac_hi=-1 ac_mid=-1 |
| 2071 | while :; do |
| 2072 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2073 | /* end confdefs.h. */ |
| 2074 | $4 |
| 2075 | int |
| 2076 | main () |
| 2077 | { |
| 2078 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; |
| 2079 | test_array [0] = 0 |
| 2080 | |
| 2081 | ; |
| 2082 | return 0; |
| 2083 | } |
| 2084 | _ACEOF |
| 2085 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2086 | ac_lo=$ac_mid; break |
| 2087 | else |
| 2088 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val |
| 2089 | if test $ac_mid -le $ac_hi; then |
| 2090 | ac_lo= ac_hi= |
| 2091 | break |
| 2092 | fi |
| 2093 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val |
| 2094 | fi |
| 2095 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2096 | done |
| 2097 | else |
| 2098 | ac_lo= ac_hi= |
| 2099 | fi |
| 2100 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2101 | fi |
| 2102 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2103 | # Binary search between lo and hi bounds. |
| 2104 | while test "x$ac_lo" != "x$ac_hi"; do |
| 2105 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val |
| 2106 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2107 | /* end confdefs.h. */ |
| 2108 | $4 |
| 2109 | int |
| 2110 | main () |
| 2111 | { |
| 2112 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
| 2113 | test_array [0] = 0 |
| 2114 | |
| 2115 | ; |
| 2116 | return 0; |
| 2117 | } |
| 2118 | _ACEOF |
| 2119 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2120 | ac_hi=$ac_mid |
| 2121 | else |
| 2122 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val |
| 2123 | fi |
| 2124 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2125 | done |
| 2126 | case $ac_lo in #(( |
| 2127 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; |
| 2128 | '') ac_retval=1 ;; |
| 2129 | esac |
| 2130 | else |
| 2131 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2132 | /* end confdefs.h. */ |
| 2133 | $4 |
| 2134 | static long int longval () { return $2; } |
| 2135 | static unsigned long int ulongval () { return $2; } |
| 2136 | #include <stdio.h> |
| 2137 | #include <stdlib.h> |
| 2138 | int |
| 2139 | main () |
| 2140 | { |
| 2141 | |
| 2142 | FILE *f = fopen ("conftest.val", "w"); |
| 2143 | if (! f) |
| 2144 | return 1; |
| 2145 | if (($2) < 0) |
| 2146 | { |
| 2147 | long int i = longval (); |
| 2148 | if (i != ($2)) |
| 2149 | return 1; |
| 2150 | fprintf (f, "%ld", i); |
| 2151 | } |
| 2152 | else |
| 2153 | { |
| 2154 | unsigned long int i = ulongval (); |
| 2155 | if (i != ($2)) |
| 2156 | return 1; |
| 2157 | fprintf (f, "%lu", i); |
| 2158 | } |
| 2159 | /* Do not output a trailing newline, as this causes \r\n confusion |
| 2160 | on some platforms. */ |
| 2161 | return ferror (f) || fclose (f) != 0; |
| 2162 | |
| 2163 | ; |
| 2164 | return 0; |
| 2165 | } |
| 2166 | _ACEOF |
| 2167 | if ac_fn_c_try_run "$LINENO"; then : |
| 2168 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 |
| 2169 | else |
| 2170 | ac_retval=1 |
| 2171 | fi |
| 2172 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 2173 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 2174 | rm -f conftest.val |
| 2175 | |
| 2176 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2177 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2178 | as_fn_set_status $ac_retval |
| 2179 | |
| 2180 | } # ac_fn_c_compute_int |
| 2181 | |
| 2182 | # ac_fn_c_check_func LINENO FUNC VAR |
| 2183 | # ---------------------------------- |
| 2184 | # Tests whether FUNC exists, setting the cache variable VAR accordingly |
| 2185 | ac_fn_c_check_func () |
| 2186 | { |
| 2187 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2188 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
| 2189 | $as_echo_n "checking for $2... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2190 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2191 | $as_echo_n "(cached) " >&6 |
| 2192 | else |
| 2193 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2194 | /* end confdefs.h. */ |
| 2195 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
| 2196 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ |
| 2197 | #define $2 innocuous_$2 |
| 2198 | |
| 2199 | /* System header to define __stub macros and hopefully few prototypes, |
| 2200 | which can conflict with char $2 (); below. |
| 2201 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 2202 | <limits.h> exists even on freestanding compilers. */ |
| 2203 | |
| 2204 | #ifdef __STDC__ |
| 2205 | # include <limits.h> |
| 2206 | #else |
| 2207 | # include <assert.h> |
| 2208 | #endif |
| 2209 | |
| 2210 | #undef $2 |
| 2211 | |
| 2212 | /* Override any GCC internal prototype to avoid an error. |
| 2213 | Use char because int might match the return type of a GCC |
| 2214 | builtin and then its argument prototype would still apply. */ |
| 2215 | #ifdef __cplusplus |
| 2216 | extern "C" |
| 2217 | #endif |
| 2218 | char $2 (); |
| 2219 | /* The GNU C library defines this for functions which it implements |
| 2220 | to always fail with ENOSYS. Some functions are actually named |
| 2221 | something starting with __ and the normal name is an alias. */ |
| 2222 | #if defined __stub_$2 || defined __stub___$2 |
| 2223 | choke me |
| 2224 | #endif |
| 2225 | |
| 2226 | int |
| 2227 | main () |
| 2228 | { |
| 2229 | return $2 (); |
| 2230 | ; |
| 2231 | return 0; |
| 2232 | } |
| 2233 | _ACEOF |
| 2234 | if ac_fn_c_try_link "$LINENO"; then : |
| 2235 | eval "$3=yes" |
| 2236 | else |
| 2237 | eval "$3=no" |
| 2238 | fi |
| 2239 | rm -f core conftest.err conftest.$ac_objext \ |
| 2240 | conftest$ac_exeext conftest.$ac_ext |
| 2241 | fi |
| 2242 | eval ac_res=\$$3 |
| 2243 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2244 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2245 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2246 | |
| 2247 | } # ac_fn_c_check_func |
| 2248 | |
| 2249 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
| 2250 | # ---------------------------------------------------- |
| 2251 | # Tries to find if the field MEMBER exists in type AGGR, after including |
| 2252 | # INCLUDES, setting cache variable VAR accordingly. |
| 2253 | ac_fn_c_check_member () |
| 2254 | { |
| 2255 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 2256 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 |
| 2257 | $as_echo_n "checking for $2.$3... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2258 | if eval \${$4+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2259 | $as_echo_n "(cached) " >&6 |
| 2260 | else |
| 2261 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2262 | /* end confdefs.h. */ |
| 2263 | $5 |
| 2264 | int |
| 2265 | main () |
| 2266 | { |
| 2267 | static $2 ac_aggr; |
| 2268 | if (ac_aggr.$3) |
| 2269 | return 0; |
| 2270 | ; |
| 2271 | return 0; |
| 2272 | } |
| 2273 | _ACEOF |
| 2274 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2275 | eval "$4=yes" |
| 2276 | else |
| 2277 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2278 | /* end confdefs.h. */ |
| 2279 | $5 |
| 2280 | int |
| 2281 | main () |
| 2282 | { |
| 2283 | static $2 ac_aggr; |
| 2284 | if (sizeof ac_aggr.$3) |
| 2285 | return 0; |
| 2286 | ; |
| 2287 | return 0; |
| 2288 | } |
| 2289 | _ACEOF |
| 2290 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2291 | eval "$4=yes" |
| 2292 | else |
| 2293 | eval "$4=no" |
| 2294 | fi |
| 2295 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2296 | fi |
| 2297 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2298 | fi |
| 2299 | eval ac_res=\$$4 |
| 2300 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2301 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2302 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2303 | |
| 2304 | } # ac_fn_c_check_member |
| 2305 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2306 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
| 2307 | # --------------------------------------------- |
| 2308 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR |
| 2309 | # accordingly. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2310 | ac_fn_c_check_decl () |
| 2311 | { |
| 2312 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2313 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
| 2314 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` |
| 2315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 |
| 2316 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } |
| 2317 | if eval \${$3+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2318 | $as_echo_n "(cached) " >&6 |
| 2319 | else |
| 2320 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 2321 | /* end confdefs.h. */ |
| 2322 | $4 |
| 2323 | int |
| 2324 | main () |
| 2325 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2326 | #ifndef $as_decl_name |
| 2327 | #ifdef __cplusplus |
| 2328 | (void) $as_decl_use; |
| 2329 | #else |
| 2330 | (void) $as_decl_name; |
| 2331 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2332 | #endif |
| 2333 | |
| 2334 | ; |
| 2335 | return 0; |
| 2336 | } |
| 2337 | _ACEOF |
| 2338 | if ac_fn_c_try_compile "$LINENO"; then : |
| 2339 | eval "$3=yes" |
| 2340 | else |
| 2341 | eval "$3=no" |
| 2342 | fi |
| 2343 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 2344 | fi |
| 2345 | eval ac_res=\$$3 |
| 2346 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 2347 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2348 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2349 | |
| 2350 | } # ac_fn_c_check_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2351 | cat >config.log <<_ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2352 | This file contains any messages produced by compilers while |
| 2353 | running configure, to aid debugging if configure makes a mistake. |
| 2354 | |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 2355 | It was created by python $as_me 3.2, which was |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2356 | generated by GNU Autoconf 2.68. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2357 | |
| 2358 | $ $0 $@ |
| 2359 | |
| 2360 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2361 | exec 5>>config.log |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2362 | { |
| 2363 | cat <<_ASUNAME |
| 2364 | ## --------- ## |
| 2365 | ## Platform. ## |
| 2366 | ## --------- ## |
| 2367 | |
| 2368 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 2369 | uname -m = `(uname -m) 2>/dev/null || echo unknown` |
| 2370 | uname -r = `(uname -r) 2>/dev/null || echo unknown` |
| 2371 | uname -s = `(uname -s) 2>/dev/null || echo unknown` |
| 2372 | uname -v = `(uname -v) 2>/dev/null || echo unknown` |
| 2373 | |
| 2374 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
| 2375 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` |
| 2376 | |
| 2377 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
| 2378 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` |
| 2379 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2380 | /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] | 2381 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` |
| 2382 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` |
| 2383 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` |
| 2384 | |
| 2385 | _ASUNAME |
| 2386 | |
| 2387 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 2388 | for as_dir in $PATH |
| 2389 | do |
| 2390 | IFS=$as_save_IFS |
| 2391 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2392 | $as_echo "PATH: $as_dir" |
| 2393 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2394 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2395 | |
| 2396 | } >&5 |
| 2397 | |
| 2398 | cat >&5 <<_ACEOF |
| 2399 | |
| 2400 | |
| 2401 | ## ----------- ## |
| 2402 | ## Core tests. ## |
| 2403 | ## ----------- ## |
| 2404 | |
| 2405 | _ACEOF |
| 2406 | |
| 2407 | |
| 2408 | # Keep a trace of the command line. |
| 2409 | # 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] | 2410 | # 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] | 2411 | # Also quote any args containing shell meta-characters. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2412 | # Make two passes to allow for proper duplicate-argument suppression. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2413 | ac_configure_args= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2414 | ac_configure_args0= |
| 2415 | ac_configure_args1= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2416 | ac_must_keep_next=false |
| 2417 | for ac_pass in 1 2 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2418 | do |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2419 | for ac_arg |
| 2420 | do |
| 2421 | case $ac_arg in |
| 2422 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; |
| 2423 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 2424 | | -silent | --silent | --silen | --sile | --sil) |
| 2425 | continue ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2426 | *\'*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2427 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2428 | esac |
| 2429 | case $ac_pass in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2430 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2431 | 2) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2432 | as_fn_append ac_configure_args1 " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2433 | if test $ac_must_keep_next = true; then |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2434 | ac_must_keep_next=false # Got value, back to normal. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2435 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 2436 | case $ac_arg in |
| 2437 | *=* | --config-cache | -C | -disable-* | --disable-* \ |
| 2438 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ |
| 2439 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ |
| 2440 | | -with-* | --with-* | -without-* | --without-* | --x) |
| 2441 | case "$ac_configure_args0 " in |
| 2442 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; |
| 2443 | esac |
| 2444 | ;; |
| 2445 | -* ) ac_must_keep_next=true ;; |
| 2446 | esac |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2447 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2448 | as_fn_append ac_configure_args " '$ac_arg'" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2449 | ;; |
| 2450 | esac |
| 2451 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2452 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2453 | { ac_configure_args0=; unset ac_configure_args0;} |
| 2454 | { ac_configure_args1=; unset ac_configure_args1;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2455 | |
| 2456 | # When interrupted or exit'd, cleanup temporary files, and complete |
| 2457 | # config.log. We remove comments because anyway the quotes in there |
| 2458 | # would cause problems or look ugly. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2459 | # WARNING: Use '\'' to represent an apostrophe within the trap. |
| 2460 | # 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] | 2461 | trap 'exit_status=$? |
| 2462 | # Save into config.log some information that might help in debugging. |
| 2463 | { |
| 2464 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2465 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2466 | $as_echo "## ---------------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2467 | ## Cache variables. ## |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2468 | ## ---------------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2469 | echo |
| 2470 | # The following way of writing the cache mishandles newlines in values, |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2471 | ( |
| 2472 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do |
| 2473 | eval ac_val=\$$ac_var |
| 2474 | case $ac_val in #( |
| 2475 | *${as_nl}*) |
| 2476 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2477 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 2478 | $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] | 2479 | esac |
| 2480 | case $ac_var in #( |
| 2481 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2482 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 2483 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2484 | esac ;; |
| 2485 | esac |
| 2486 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2487 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2488 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( |
| 2489 | *${as_nl}ac_space=\ *) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2490 | sed -n \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2491 | "s/'\''/'\''\\\\'\'''\''/g; |
| 2492 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" |
| 2493 | ;; #( |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2494 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2495 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 2496 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2497 | esac | |
| 2498 | sort |
| 2499 | ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2500 | echo |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2501 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2502 | $as_echo "## ----------------- ## |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2503 | ## Output variables. ## |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2504 | ## ----------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2505 | echo |
| 2506 | for ac_var in $ac_subst_vars |
| 2507 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2508 | eval ac_val=\$$ac_var |
| 2509 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2510 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2511 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2512 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2513 | done | sort |
| 2514 | echo |
| 2515 | |
| 2516 | if test -n "$ac_subst_files"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2517 | $as_echo "## ------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2518 | ## File substitutions. ## |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2519 | ## ------------------- ##" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2520 | echo |
| 2521 | for ac_var in $ac_subst_files |
| 2522 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2523 | eval ac_val=\$$ac_var |
| 2524 | case $ac_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2525 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2526 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2527 | $as_echo "$ac_var='\''$ac_val'\''" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 2528 | done | sort |
| 2529 | echo |
| 2530 | fi |
| 2531 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2532 | if test -s confdefs.h; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2533 | $as_echo "## ----------- ## |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2534 | ## confdefs.h. ## |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2535 | ## ----------- ##" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2536 | echo |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2537 | cat confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2538 | echo |
| 2539 | fi |
| 2540 | test "$ac_signal" != 0 && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2541 | $as_echo "$as_me: caught signal $ac_signal" |
| 2542 | $as_echo "$as_me: exit $exit_status" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2543 | } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2544 | rm -f core *.core core.conftest.* && |
| 2545 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2546 | exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2547 | ' 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2548 | for ac_signal in 1 2 13 15; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2549 | 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] | 2550 | done |
| 2551 | ac_signal=0 |
| 2552 | |
| 2553 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2554 | rm -f -r conftest* confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2555 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2556 | $as_echo "/* confdefs.h */" > confdefs.h |
| 2557 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2558 | # Predefined preprocessor variables. |
| 2559 | |
| 2560 | cat >>confdefs.h <<_ACEOF |
| 2561 | #define PACKAGE_NAME "$PACKAGE_NAME" |
| 2562 | _ACEOF |
| 2563 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2564 | cat >>confdefs.h <<_ACEOF |
| 2565 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" |
| 2566 | _ACEOF |
| 2567 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2568 | cat >>confdefs.h <<_ACEOF |
| 2569 | #define PACKAGE_VERSION "$PACKAGE_VERSION" |
| 2570 | _ACEOF |
| 2571 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2572 | cat >>confdefs.h <<_ACEOF |
| 2573 | #define PACKAGE_STRING "$PACKAGE_STRING" |
| 2574 | _ACEOF |
| 2575 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2576 | cat >>confdefs.h <<_ACEOF |
| 2577 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" |
| 2578 | _ACEOF |
| 2579 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2580 | cat >>confdefs.h <<_ACEOF |
| 2581 | #define PACKAGE_URL "$PACKAGE_URL" |
| 2582 | _ACEOF |
| 2583 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2584 | |
| 2585 | # 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] | 2586 | # Prefer an explicitly selected file to automatically selected ones. |
| 2587 | ac_site_file1=NONE |
| 2588 | ac_site_file2=NONE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2589 | if test -n "$CONFIG_SITE"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2590 | # We do not want a PATH search for config.site. |
| 2591 | case $CONFIG_SITE in #(( |
| 2592 | -*) ac_site_file1=./$CONFIG_SITE;; |
| 2593 | */*) ac_site_file1=$CONFIG_SITE;; |
| 2594 | *) ac_site_file1=./$CONFIG_SITE;; |
| 2595 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2596 | elif test "x$prefix" != xNONE; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2597 | ac_site_file1=$prefix/share/config.site |
| 2598 | ac_site_file2=$prefix/etc/config.site |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2599 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2600 | ac_site_file1=$ac_default_prefix/share/config.site |
| 2601 | ac_site_file2=$ac_default_prefix/etc/config.site |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2602 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2603 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2604 | do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2605 | test "x$ac_site_file" = xNONE && continue |
| 2606 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
| 2607 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
| 2608 | $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] | 2609 | sed 's/^/| /' "$ac_site_file" >&5 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2610 | . "$ac_site_file" \ |
| 2611 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2612 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2613 | as_fn_error $? "failed to load site script $ac_site_file |
| 2614 | See \`config.log' for more details" "$LINENO" 5; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2615 | fi |
| 2616 | done |
| 2617 | |
| 2618 | if test -r "$cache_file"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2619 | # Some versions of bash will fail to source /dev/null (special files |
| 2620 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. |
| 2621 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then |
| 2622 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
| 2623 | $as_echo "$as_me: loading cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2624 | case $cache_file in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2625 | [\\/]* | ?:[\\/]* ) . "$cache_file";; |
| 2626 | *) . "./$cache_file";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2627 | esac |
| 2628 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2629 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2630 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
| 2631 | $as_echo "$as_me: creating cache $cache_file" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2632 | >$cache_file |
| 2633 | fi |
| 2634 | |
| 2635 | # Check that the precious variables saved in the cache have kept the same |
| 2636 | # value. |
| 2637 | ac_cache_corrupted=false |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2638 | for ac_var in $ac_precious_vars; do |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2639 | eval ac_old_set=\$ac_cv_env_${ac_var}_set |
| 2640 | eval ac_new_set=\$ac_env_${ac_var}_set |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2641 | eval ac_old_val=\$ac_cv_env_${ac_var}_value |
| 2642 | eval ac_new_val=\$ac_env_${ac_var}_value |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2643 | case $ac_old_set,$ac_new_set in |
| 2644 | set,) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2645 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 |
| 2646 | $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] | 2647 | ac_cache_corrupted=: ;; |
| 2648 | ,set) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2649 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 |
| 2650 | $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] | 2651 | ac_cache_corrupted=: ;; |
| 2652 | ,);; |
| 2653 | *) |
| 2654 | if test "x$ac_old_val" != "x$ac_new_val"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2655 | # differences in whitespace do not lead to failure. |
| 2656 | ac_old_val_w=`echo x $ac_old_val` |
| 2657 | ac_new_val_w=`echo x $ac_new_val` |
| 2658 | if test "$ac_old_val_w" != "$ac_new_val_w"; then |
| 2659 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 |
| 2660 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} |
| 2661 | ac_cache_corrupted=: |
| 2662 | else |
| 2663 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 |
| 2664 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} |
| 2665 | eval $ac_var=\$ac_old_val |
| 2666 | fi |
| 2667 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 |
| 2668 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} |
| 2669 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 |
| 2670 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2671 | fi;; |
| 2672 | esac |
| 2673 | # Pass precious variables to config.status. |
| 2674 | if test "$ac_new_set" = set; then |
| 2675 | case $ac_new_val in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2676 | *\'*) 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] | 2677 | *) ac_arg=$ac_var=$ac_new_val ;; |
| 2678 | esac |
| 2679 | case " $ac_configure_args " in |
| 2680 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2681 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2682 | esac |
| 2683 | fi |
| 2684 | done |
| 2685 | if $ac_cache_corrupted; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2686 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 2687 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
| 2688 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 |
| 2689 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2690 | 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] | 2691 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2692 | ## -------------------- ## |
| 2693 | ## Main body of script. ## |
| 2694 | ## -------------------- ## |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2695 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2696 | ac_ext=c |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2697 | ac_cpp='$CPP $CPPFLAGS' |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2698 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 2699 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 2700 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2701 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2702 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2703 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2704 | ac_config_headers="$ac_config_headers pyconfig.h" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2705 | |
| 2706 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2707 | |
Benjamin Peterson | d23f822 | 2009-04-05 19:13:16 +0000 | [diff] [blame] | 2708 | if test "$prefix" != "/"; then |
| 2709 | prefix=`echo "$prefix" | sed -e 's/\/$//g'` |
| 2710 | fi |
| 2711 | |
| 2712 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2713 | |
| 2714 | |
Martin v. Löwis | 8316feb | 2003-06-14 07:48:07 +0000 | [diff] [blame] | 2715 | # We don't use PACKAGE_ variables, and they cause conflicts |
| 2716 | # with other autoconf-based packages that include Python.h |
| 2717 | grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new |
| 2718 | rm confdefs.h |
| 2719 | mv confdefs.h.new confdefs.h |
| 2720 | |
Martin v. Löwis | bddf5a5 | 2002-11-11 13:37:28 +0000 | [diff] [blame] | 2721 | |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 2722 | VERSION=3.2 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 2723 | |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 2724 | # Version number of Python's own shared library file. |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 2725 | |
| 2726 | SOVERSION=1.0 |
| 2727 | |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2728 | # The later defininition of _XOPEN_SOURCE disables certain features |
| 2729 | # on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone). |
| 2730 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2731 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2732 | |
| 2733 | |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2734 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2735 | # certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable |
| 2736 | # them. |
| 2737 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2738 | $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | bcd9396 | 2003-05-03 10:32:18 +0000 | [diff] [blame] | 2739 | |
| 2740 | |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2741 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2742 | # certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable |
| 2743 | # them. |
| 2744 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2745 | $as_echo "#define __BSD_VISIBLE 1" >>confdefs.h |
Andrew MacIntyre | abccf41 | 2003-07-02 13:53:25 +0000 | [diff] [blame] | 2746 | |
| 2747 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2748 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2749 | # u_int on Irix 5.3. Defining _BSD_TYPES brings it back. |
| 2750 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2751 | $as_echo "#define _BSD_TYPES 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 2752 | |
| 2753 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2754 | # The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables |
| 2755 | # certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable |
| 2756 | # them. |
| 2757 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2758 | $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2759 | |
| 2760 | |
| 2761 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 2762 | define_xopen_source=yes |
Martin v. Löwis | 6f18a3c | 2002-07-20 08:51:52 +0000 | [diff] [blame] | 2763 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 2764 | # Arguments passed to configure. |
| 2765 | |
| 2766 | CONFIG_ARGS="$ac_configure_args" |
| 2767 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-universalsdk" >&5 |
| 2769 | $as_echo_n "checking for --enable-universalsdk... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2770 | # Check whether --enable-universalsdk was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2771 | if test "${enable_universalsdk+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2772 | enableval=$enable_universalsdk; |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2773 | case $enableval in |
| 2774 | yes) |
| 2775 | enableval=/Developer/SDKs/MacOSX10.4u.sdk |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2776 | if test ! -d "${enableval}" |
| 2777 | then |
| 2778 | enableval=/ |
| 2779 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2780 | ;; |
| 2781 | esac |
| 2782 | case $enableval in |
| 2783 | no) |
| 2784 | UNIVERSALSDK= |
| 2785 | enable_universalsdk= |
| 2786 | ;; |
| 2787 | *) |
| 2788 | UNIVERSALSDK=$enableval |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2789 | if test ! -d "${UNIVERSALSDK}" |
| 2790 | then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 2791 | as_fn_error $? "--enable-universalsdk specifies non-existing SDK: ${UNIVERSALSDK}" "$LINENO" 5 |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2792 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2793 | ;; |
| 2794 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2795 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2796 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2797 | else |
| 2798 | |
| 2799 | UNIVERSALSDK= |
| 2800 | enable_universalsdk= |
| 2801 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2802 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2803 | |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2804 | if test -n "${UNIVERSALSDK}" |
| 2805 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2806 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${UNIVERSALSDK}" >&5 |
| 2807 | $as_echo "${UNIVERSALSDK}" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2808 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2809 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 2810 | $as_echo "no" >&6; } |
Ronald Oussoren | 8af24c1 | 2010-02-07 12:03:42 +0000 | [diff] [blame] | 2811 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2812 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2813 | |
Benjamin Peterson | 6794aa3 | 2008-07-16 20:33:37 +0000 | [diff] [blame] | 2814 | |
| 2815 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2816 | UNIVERSAL_ARCHS="32-bit" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2817 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2818 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-universal-archs" >&5 |
| 2819 | $as_echo_n "checking for --with-universal-archs... " >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2820 | |
| 2821 | # Check whether --with-universal-archs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2822 | if test "${with_universal_archs+set}" = set; then : |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2823 | withval=$with_universal_archs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 2825 | $as_echo "$withval" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2826 | UNIVERSAL_ARCHS="$withval" |
| 2827 | |
| 2828 | else |
| 2829 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2830 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 32-bit" >&5 |
| 2831 | $as_echo "32-bit" >&6; } |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2832 | |
| 2833 | fi |
| 2834 | |
| 2835 | |
| 2836 | |
| 2837 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2838 | |
| 2839 | # Check whether --with-framework-name was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2840 | if test "${with_framework_name+set}" = set; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2841 | withval=$with_framework_name; |
| 2842 | PYTHONFRAMEWORK=${withval} |
| 2843 | PYTHONFRAMEWORKDIR=${withval}.framework |
| 2844 | PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'` |
| 2845 | |
| 2846 | else |
| 2847 | |
| 2848 | PYTHONFRAMEWORK=Python |
| 2849 | PYTHONFRAMEWORKDIR=Python.framework |
| 2850 | PYTHONFRAMEWORKIDENTIFIER=org.python.python |
| 2851 | |
| 2852 | fi |
| 2853 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2854 | # Check whether --enable-framework was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2855 | if test "${enable_framework+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2856 | enableval=$enable_framework; |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2857 | case $enableval in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2858 | yes) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2859 | enableval=/Library/Frameworks |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2860 | esac |
| 2861 | case $enableval in |
| 2862 | no) |
| 2863 | PYTHONFRAMEWORK= |
| 2864 | PYTHONFRAMEWORKDIR=no-framework |
| 2865 | PYTHONFRAMEWORKPREFIX= |
| 2866 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2867 | FRAMEWORKINSTALLFIRST= |
| 2868 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2869 | FRAMEWORKALTINSTALLFIRST= |
| 2870 | FRAMEWORKALTINSTALLLAST= |
| 2871 | if test "x${prefix}" = "xNONE"; then |
| 2872 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2873 | else |
| 2874 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2875 | fi |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2876 | enable_framework= |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2877 | ;; |
| 2878 | *) |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2879 | PYTHONFRAMEWORKPREFIX="${enableval}" |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2880 | PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2881 | FRAMEWORKINSTALLFIRST="frameworkinstallstructure" |
Ronald Oussoren | f6ccbf6 | 2009-06-02 10:55:56 +0000 | [diff] [blame] | 2882 | FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure " |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 2883 | FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools" |
| 2884 | FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2885 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2886 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2887 | if test "x${prefix}" = "xNONE" ; then |
| 2888 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2889 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2890 | else |
| 2891 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2892 | fi |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2893 | |
| 2894 | case "${enableval}" in |
| 2895 | /System*) |
| 2896 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2897 | if test "${prefix}" = "NONE" ; then |
| 2898 | # See below |
| 2899 | FRAMEWORKUNIXTOOLSPREFIX="/usr" |
| 2900 | fi |
| 2901 | ;; |
| 2902 | |
| 2903 | /Library*) |
| 2904 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2905 | ;; |
| 2906 | |
| 2907 | */Library/Frameworks) |
| 2908 | MDIR="`dirname "${enableval}"`" |
| 2909 | MDIR="`dirname "${MDIR}"`" |
| 2910 | FRAMEWORKINSTALLAPPSPREFIX="${MDIR}/Applications" |
| 2911 | |
| 2912 | if test "${prefix}" = "NONE"; then |
| 2913 | # User hasn't specified the |
| 2914 | # --prefix option, but wants to install |
| 2915 | # the framework in a non-default location, |
| 2916 | # ensure that the compatibility links get |
| 2917 | # installed relative to that prefix as well |
| 2918 | # instead of in /usr/local. |
| 2919 | FRAMEWORKUNIXTOOLSPREFIX="${MDIR}" |
| 2920 | fi |
| 2921 | ;; |
| 2922 | |
| 2923 | *) |
| 2924 | FRAMEWORKINSTALLAPPSPREFIX="/Applications" |
| 2925 | ;; |
| 2926 | esac |
| 2927 | |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2928 | prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2929 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2930 | # Add files for Mac specific code to the list of output |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2931 | # files: |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2932 | ac_config_files="$ac_config_files Mac/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2933 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2934 | ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2935 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2936 | ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist" |
| 2937 | |
| 2938 | ac_config_files="$ac_config_files Mac/Resources/app/Info.plist" |
| 2939 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2940 | esac |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2941 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2942 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 2943 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2944 | PYTHONFRAMEWORK= |
Jack Jansen | 127e56e | 2001-09-11 14:41:54 +0000 | [diff] [blame] | 2945 | PYTHONFRAMEWORKDIR=no-framework |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2946 | PYTHONFRAMEWORKPREFIX= |
| 2947 | PYTHONFRAMEWORKINSTALLDIR= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2948 | FRAMEWORKINSTALLFIRST= |
| 2949 | FRAMEWORKINSTALLLAST= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2950 | FRAMEWORKALTINSTALLFIRST= |
| 2951 | FRAMEWORKALTINSTALLLAST= |
| 2952 | if test "x${prefix}" = "xNONE" ; then |
| 2953 | FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}" |
| 2954 | else |
| 2955 | FRAMEWORKUNIXTOOLSPREFIX="${prefix}" |
| 2956 | fi |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2957 | enable_framework= |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2958 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 2959 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 2960 | fi |
| 2961 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 2962 | |
| 2963 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 2964 | |
| 2965 | |
| 2966 | |
| 2967 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2968 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 2969 | |
| 2970 | |
| 2971 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 2972 | |
Ronald Oussoren | 86b33c8 | 2010-04-30 11:41:56 +0000 | [diff] [blame] | 2973 | |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2974 | ##AC_ARG_WITH(dyld, |
Matthias Klose | 2b8733f | 2010-04-25 18:34:36 +0000 | [diff] [blame] | 2975 | ## AS_HELP_STRING([--with-dyld], |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 2976 | ## [Use (OpenStep|Rhapsody) dynamic linker])) |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 2977 | ## |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2978 | # Set name for machine-dependent library files |
| 2979 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 2980 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP" >&5 |
| 2981 | $as_echo_n "checking MACHDEP... " >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2982 | if test -z "$MACHDEP" |
| 2983 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2984 | ac_sys_system=`uname -s` |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 2985 | if test "$ac_sys_system" = "AIX" \ |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 2986 | -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2987 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2988 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2989 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 2990 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2991 | ac_md_system=`echo $ac_sys_system | |
| 2992 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 2993 | ac_md_release=`echo $ac_sys_release | |
Guido van Rossum | 67b2659 | 2001-10-20 14:21:45 +0000 | [diff] [blame] | 2994 | tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 2995 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 2996 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 2997 | case $MACHDEP in |
Andrew M. Kuchling | 5a3e4cb | 2001-07-20 19:29:04 +0000 | [diff] [blame] | 2998 | cygwin*) MACHDEP="cygwin";; |
Jack Jansen | 8a97f4a | 2001-12-05 23:27:32 +0000 | [diff] [blame] | 2999 | darwin*) MACHDEP="darwin";; |
Martin v. Löwis | f332228 | 2003-07-13 09:46:13 +0000 | [diff] [blame] | 3000 | irix646) MACHDEP="irix6";; |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 3001 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3002 | esac |
| 3003 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3004 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3005 | # Some systems cannot stand _XOPEN_SOURCE being defined at all; they |
| 3006 | # disable features if it is defined, without any means to access these |
| 3007 | # features as extensions. For these systems, we skip the definition of |
| 3008 | # _XOPEN_SOURCE. Before adding a system to the list to gain access to |
| 3009 | # some feature, make sure there is no alternative way to access this |
| 3010 | # feature. Also, when using wildcards, make sure you have verified the |
| 3011 | # need for not defining _XOPEN_SOURCE on all systems matching the |
| 3012 | # wildcard, and that the wildcard does not include future systems |
| 3013 | # (which may remove their limitations). |
| 3014 | case $ac_sys_system/$ac_sys_release in |
| 3015 | # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined, |
| 3016 | # 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] | 3017 | # 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] | 3018 | # In addition, Stefan Krah confirms that issue #1244610 exists through |
| 3019 | # OpenBSD 4.6, but is fixed in 4.7. |
| 3020 | OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123456]) |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3021 | define_xopen_source=no |
| 3022 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3023 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3024 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3025 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3026 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Christian Heimes | 5b5e81c | 2007-12-31 16:14:33 +0000 | [diff] [blame] | 3027 | |
| 3028 | ;; |
Martin v. Löwis | 19ed3c8 | 2010-02-15 21:45:06 +0000 | [diff] [blame] | 3029 | OpenBSD/4.[789]) |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3030 | # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is |
| 3031 | # also defined. This can be overridden by defining _BSD_SOURCE |
| 3032 | # As this has a different meaning on Linux, only define it on OpenBSD |
| 3033 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3034 | $as_echo "#define _BSD_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 7671efc | 2010-02-15 08:35:16 +0000 | [diff] [blame] | 3035 | |
| 3036 | ;; |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 3037 | # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of |
| 3038 | # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by |
| 3039 | # Marc Recht |
Benjamin Peterson | f608c61 | 2008-11-16 18:33:53 +0000 | [diff] [blame] | 3040 | 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] | 3041 | define_xopen_source=no;; |
Martin v. Löwis | 1a41576 | 2010-05-28 15:44:20 +0000 | [diff] [blame] | 3042 | # From the perspective of Solaris, _XOPEN_SOURCE is not so much a |
| 3043 | # request to enable features supported by the standard as a request |
| 3044 | # to disable features not supported by the standard. The best way |
| 3045 | # for Python to use Solaris is simply to leave _XOPEN_SOURCE out |
| 3046 | # entirely and define __EXTENSIONS__ instead. |
| 3047 | SunOS/*) |
Martin v. Löwis | a9d7142 | 2003-03-28 18:43:31 +0000 | [diff] [blame] | 3048 | define_xopen_source=no;; |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3049 | # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE, |
| 3050 | # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice. |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3051 | # Reconfirmed for 7.1.4 by Martin v. Loewis. |
Martin v. Löwis | 253d1f4 | 2004-05-07 19:14:14 +0000 | [diff] [blame] | 3052 | OpenUNIX/8.0.0| UnixWare/7.1.[0-4]) |
Martin v. Löwis | c2409b4 | 2003-05-11 05:53:41 +0000 | [diff] [blame] | 3053 | define_xopen_source=no;; |
| 3054 | # 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] | 3055 | # 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] | 3056 | SCO_SV/3.2) |
Martin v. Löwis | 53e73c3 | 2003-05-05 05:13:18 +0000 | [diff] [blame] | 3057 | define_xopen_source=no;; |
Martin v. Löwis | b37509b | 2008-11-04 20:45:29 +0000 | [diff] [blame] | 3058 | # On FreeBSD 4, the math functions C89 does not cover are never defined |
| 3059 | # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them. |
| 3060 | FreeBSD/4.*) |
| 3061 | define_xopen_source=no;; |
| 3062 | # On MacOS X 10.2, a bug in ncurses.h means that it craps out if |
| 3063 | # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which |
| 3064 | # identifies itself as Darwin/7.* |
| 3065 | # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3066 | # disables platform specific features beyond repair. |
| 3067 | # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE |
| 3068 | # has no effect, don't bother defining them |
| 3069 | Darwin/[6789].*) |
Anthony Baxter | 6169c6b | 2003-10-04 07:46:23 +0000 | [diff] [blame] | 3070 | define_xopen_source=no;; |
Ronald Oussoren | 92fb941 | 2010-03-09 06:40:19 +0000 | [diff] [blame] | 3071 | Darwin/1[0-9].*) |
Ronald Oussoren | b8f11a6 | 2010-03-08 07:02:03 +0000 | [diff] [blame] | 3072 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3073 | # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but |
| 3074 | # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined |
| 3075 | # 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] | 3076 | AIX/4) |
| 3077 | define_xopen_source=no;; |
Trent Mick | c5625ba | 2004-08-25 23:59:39 +0000 | [diff] [blame] | 3078 | AIX/5) |
| 3079 | if test `uname -r` -eq 1; then |
| 3080 | define_xopen_source=no |
| 3081 | fi |
| 3082 | ;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 3083 | # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from |
| 3084 | # defining NI_NUMERICHOST. |
| 3085 | QNX/6.3.2) |
| 3086 | define_xopen_source=no |
| 3087 | ;; |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3088 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3089 | esac |
| 3090 | |
| 3091 | if test $define_xopen_source = yes |
| 3092 | then |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3093 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3094 | $as_echo "#define _XOPEN_SOURCE 600" >>confdefs.h |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3095 | |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3096 | |
| 3097 | # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires |
| 3098 | # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else |
| 3099 | # several APIs are not declared. Since this is also needed in some |
| 3100 | # cases for HP-UX, we define it globally. |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3101 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3102 | $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3103 | |
| 3104 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 3105 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3106 | $as_echo "#define _POSIX_C_SOURCE 200112L" >>confdefs.h |
Martin v. Löwis | 678fc1e | 2002-11-12 06:04:39 +0000 | [diff] [blame] | 3107 | |
| 3108 | |
Martin v. Löwis | 35195ad | 2002-11-11 13:26:51 +0000 | [diff] [blame] | 3109 | fi |
| 3110 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3111 | # |
| 3112 | # SGI compilers allow the specification of the both the ABI and the |
| 3113 | # ISA on the command line. Depending on the values of these switches, |
| 3114 | # different and often incompatable code will be generated. |
| 3115 | # |
| 3116 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 3117 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 3118 | # variable is also adjusted. |
| 3119 | # |
| 3120 | |
| 3121 | if test ! -z "$SGI_ABI" |
| 3122 | then |
| 3123 | CC="cc $SGI_ABI" |
| 3124 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 3125 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 3126 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3127 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MACHDEP" >&5 |
| 3128 | $as_echo "$MACHDEP" >&6; } |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3129 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3130 | # Record the configure-time value of MACOSX_DEPLOYMENT_TARGET, |
| 3131 | # it may influence the way we can build extensions, so distutils |
| 3132 | # needs to check it |
| 3133 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3134 | |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3135 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET= |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 3136 | EXPORT_MACOSX_DEPLOYMENT_TARGET='#' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 3137 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3138 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking machine type as reported by uname -m" >&5 |
| 3139 | $as_echo_n "checking machine type as reported by uname -m... " >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3140 | ac_sys_machine=`uname -m` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_sys_machine" >&5 |
| 3142 | $as_echo "$ac_sys_machine" >&6; } |
Mark Dickinson | b0e2b4c | 2008-04-26 20:48:56 +0000 | [diff] [blame] | 3143 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3144 | # checks for alternative programs |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 3145 | |
| 3146 | # compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just |
| 3147 | # for debug/optimization stuff. BASECFLAGS is for flags that are required |
| 3148 | # just to get things to compile and link. Users are free to override OPT |
| 3149 | # when running configure or make. The build should not break if they do. |
| 3150 | # BASECFLAGS should generally not be messed with, however. |
| 3151 | |
| 3152 | # XXX shouldn't some/most/all of this code be merged with the stuff later |
| 3153 | # on that fiddles with OPT and BASECFLAGS? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3154 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --without-gcc" >&5 |
| 3155 | $as_echo_n "checking for --without-gcc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3156 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3157 | # Check whether --with-gcc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3158 | if test "${with_gcc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3159 | withval=$with_gcc; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3160 | case $withval in |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 3161 | no) CC=${CC:-cc} |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3162 | without_gcc=yes;; |
| 3163 | yes) CC=gcc |
| 3164 | without_gcc=no;; |
| 3165 | *) CC=$withval |
| 3166 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3167 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3168 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3169 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3170 | case $ac_sys_system in |
Antoine Pitrou | f6350d2 | 2010-09-21 15:19:14 +0000 | [diff] [blame] | 3171 | AIX*) CC=${CC:-xlc_r} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3172 | without_gcc=;; |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 3173 | *) without_gcc=no;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 3174 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3175 | fi |
| 3176 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $without_gcc" >&5 |
| 3178 | $as_echo "$without_gcc" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3179 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 3180 | # If the user switches compilers, we can't believe the cache |
| 3181 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 3182 | then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3183 | as_fn_error $? "cached CC is different -- throw away $cache_file |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3184 | (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] | 3185 | fi |
| 3186 | |
Jeffrey Yasskin | d4fcdb1 | 2010-07-09 16:30:58 +0000 | [diff] [blame] | 3187 | # Don't let AC_PROG_CC set the default CFLAGS. It normally sets -g -O2 |
| 3188 | # when the compiler supports them, but we don't always want -O2, and |
| 3189 | # we set -g later. |
| 3190 | if test -z "$CFLAGS"; then |
| 3191 | CFLAGS= |
| 3192 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3193 | ac_ext=c |
| 3194 | ac_cpp='$CPP $CPPFLAGS' |
| 3195 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3196 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3197 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 3198 | if test -n "$ac_tool_prefix"; then |
| 3199 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. |
| 3200 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3201 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3202 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3203 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3204 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3205 | else |
| 3206 | if test -n "$CC"; then |
| 3207 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3208 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3209 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3210 | for as_dir in $PATH |
| 3211 | do |
| 3212 | IFS=$as_save_IFS |
| 3213 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3214 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3215 | 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] | 3216 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3217 | $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] | 3218 | break 2 |
| 3219 | fi |
| 3220 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3221 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3222 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3223 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3224 | fi |
| 3225 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3226 | CC=$ac_cv_prog_CC |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3227 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3228 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3229 | $as_echo "$CC" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3230 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3232 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3233 | fi |
| 3234 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3235 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3236 | fi |
| 3237 | if test -z "$ac_cv_prog_CC"; then |
| 3238 | ac_ct_CC=$CC |
| 3239 | # Extract the first word of "gcc", so it can be a program name with args. |
| 3240 | set dummy gcc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3241 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3242 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3243 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3244 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3245 | else |
| 3246 | if test -n "$ac_ct_CC"; then |
| 3247 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3248 | else |
| 3249 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3250 | for as_dir in $PATH |
| 3251 | do |
| 3252 | IFS=$as_save_IFS |
| 3253 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3254 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3255 | 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] | 3256 | ac_cv_prog_ac_ct_CC="gcc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3257 | $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] | 3258 | break 2 |
| 3259 | fi |
| 3260 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3261 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3262 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3263 | |
| 3264 | fi |
| 3265 | fi |
| 3266 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3267 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3269 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3270 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3272 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3273 | fi |
| 3274 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3275 | if test "x$ac_ct_CC" = x; then |
| 3276 | CC="" |
| 3277 | else |
| 3278 | case $cross_compiling:$ac_tool_warned in |
| 3279 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3280 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3281 | $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] | 3282 | ac_tool_warned=yes ;; |
| 3283 | esac |
| 3284 | CC=$ac_ct_CC |
| 3285 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3286 | else |
| 3287 | CC="$ac_cv_prog_CC" |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3288 | fi |
| 3289 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3290 | if test -z "$CC"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3291 | if test -n "$ac_tool_prefix"; then |
| 3292 | # 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] | 3293 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3294 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3295 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3296 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3297 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3298 | else |
| 3299 | if test -n "$CC"; then |
| 3300 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3301 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3302 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3303 | for as_dir in $PATH |
| 3304 | do |
| 3305 | IFS=$as_save_IFS |
| 3306 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3307 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3308 | 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] | 3309 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3310 | $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] | 3311 | break 2 |
| 3312 | fi |
| 3313 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3314 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3315 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3316 | |
| 3317 | fi |
| 3318 | fi |
| 3319 | CC=$ac_cv_prog_CC |
| 3320 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3321 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3322 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3323 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3324 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3325 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3326 | fi |
| 3327 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3328 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3329 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3330 | fi |
| 3331 | if test -z "$CC"; then |
| 3332 | # Extract the first word of "cc", so it can be a program name with args. |
| 3333 | set dummy cc; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3334 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3335 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3336 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3337 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3338 | else |
| 3339 | if test -n "$CC"; then |
| 3340 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3341 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3342 | ac_prog_rejected=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3343 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3344 | for as_dir in $PATH |
| 3345 | do |
| 3346 | IFS=$as_save_IFS |
| 3347 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3348 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3349 | 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] | 3350 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
| 3351 | ac_prog_rejected=yes |
| 3352 | continue |
| 3353 | fi |
| 3354 | ac_cv_prog_CC="cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3355 | $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] | 3356 | break 2 |
| 3357 | fi |
| 3358 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3359 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3360 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3361 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3362 | if test $ac_prog_rejected = yes; then |
| 3363 | # We found a bogon in the path, so make sure we never use it. |
| 3364 | set dummy $ac_cv_prog_CC |
| 3365 | shift |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3366 | if test $# != 0; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3367 | # We chose a different compiler from the bogus one. |
| 3368 | # However, it has the same basename, so the bogon will be chosen |
| 3369 | # first if we set CC to just the basename; use the full file name. |
| 3370 | shift |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3371 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3372 | fi |
| 3373 | fi |
| 3374 | fi |
| 3375 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3376 | CC=$ac_cv_prog_CC |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3377 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3378 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3379 | $as_echo "$CC" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3380 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3381 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3382 | $as_echo "no" >&6; } |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3383 | fi |
| 3384 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3385 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3386 | fi |
| 3387 | if test -z "$CC"; then |
| 3388 | if test -n "$ac_tool_prefix"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3389 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3390 | do |
| 3391 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. |
| 3392 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3393 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3394 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3395 | if ${ac_cv_prog_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3396 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3397 | else |
| 3398 | if test -n "$CC"; then |
| 3399 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 3400 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3401 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3402 | for as_dir in $PATH |
| 3403 | do |
| 3404 | IFS=$as_save_IFS |
| 3405 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3406 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3407 | 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] | 3408 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3409 | $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] | 3410 | break 2 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3411 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3412 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3413 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3414 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3415 | |
| 3416 | fi |
| 3417 | fi |
| 3418 | CC=$ac_cv_prog_CC |
| 3419 | if test -n "$CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3420 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 3421 | $as_echo "$CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3422 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3423 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3424 | $as_echo "no" >&6; } |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3425 | fi |
| 3426 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3427 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3428 | test -n "$CC" && break |
| 3429 | done |
| 3430 | fi |
| 3431 | if test -z "$CC"; then |
| 3432 | ac_ct_CC=$CC |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3433 | for ac_prog in cl.exe |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3434 | do |
| 3435 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 3436 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3437 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 3438 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3439 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3440 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3441 | else |
| 3442 | if test -n "$ac_ct_CC"; then |
| 3443 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. |
| 3444 | else |
| 3445 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 3446 | for as_dir in $PATH |
| 3447 | do |
| 3448 | IFS=$as_save_IFS |
| 3449 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3450 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3451 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3452 | ac_cv_prog_ac_ct_CC="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3453 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3454 | break 2 |
| 3455 | fi |
| 3456 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3457 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3458 | IFS=$as_save_IFS |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3459 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3460 | fi |
| 3461 | fi |
| 3462 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
| 3463 | if test -n "$ac_ct_CC"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
| 3465 | $as_echo "$ac_ct_CC" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3466 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3468 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3469 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3470 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3471 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3472 | test -n "$ac_ct_CC" && break |
| 3473 | done |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3474 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3475 | if test "x$ac_ct_CC" = x; then |
| 3476 | CC="" |
| 3477 | else |
| 3478 | case $cross_compiling:$ac_tool_warned in |
| 3479 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3480 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 3481 | $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] | 3482 | ac_tool_warned=yes ;; |
| 3483 | esac |
| 3484 | CC=$ac_ct_CC |
| 3485 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3486 | fi |
| 3487 | |
| 3488 | fi |
| 3489 | |
| 3490 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3491 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3492 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3493 | as_fn_error $? "no acceptable C compiler found in \$PATH |
| 3494 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3495 | |
| 3496 | # Provide some information about the compiler. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3497 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
| 3498 | set X $ac_compile |
| 3499 | ac_compiler=$2 |
| 3500 | for ac_option in --version -v -V -qversion; do |
| 3501 | { { ac_try="$ac_compiler $ac_option >&5" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3502 | case "(($ac_try" in |
| 3503 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3504 | *) ac_try_echo=$ac_try;; |
| 3505 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3506 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3507 | $as_echo "$ac_try_echo"; } >&5 |
| 3508 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3509 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3510 | if test -s conftest.err; then |
| 3511 | sed '10a\ |
| 3512 | ... rest of stderr output deleted ... |
| 3513 | 10q' conftest.err >conftest.er1 |
| 3514 | cat conftest.er1 >&5 |
| 3515 | fi |
| 3516 | rm -f conftest.er1 conftest.err |
| 3517 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3518 | test $ac_status = 0; } |
| 3519 | done |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3520 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3521 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3522 | /* end confdefs.h. */ |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 3523 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3524 | int |
| 3525 | main () |
| 3526 | { |
| 3527 | |
| 3528 | ; |
| 3529 | return 0; |
| 3530 | } |
| 3531 | _ACEOF |
| 3532 | ac_clean_files_save=$ac_clean_files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3533 | 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] | 3534 | # Try to create an executable without -o first, disregard a.out. |
| 3535 | # It will help us diagnose broken compilers, and finding out an intuition |
| 3536 | # of exeext. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3537 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
| 3538 | $as_echo_n "checking whether the C compiler works... " >&6; } |
| 3539 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
| 3540 | |
| 3541 | # The possible output files: |
| 3542 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" |
| 3543 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3544 | ac_rmfiles= |
| 3545 | for ac_file in $ac_files |
| 3546 | do |
| 3547 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3548 | *.$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] | 3549 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
| 3550 | esac |
| 3551 | done |
| 3552 | rm -f $ac_rmfiles |
| 3553 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3554 | if { { ac_try="$ac_link_default" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3555 | case "(($ac_try" in |
| 3556 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3557 | *) ac_try_echo=$ac_try;; |
| 3558 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3559 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3560 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3561 | (eval "$ac_link_default") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3562 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3563 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3564 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3565 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
| 3566 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' |
| 3567 | # in a Makefile. We should not override ac_cv_exeext if it was cached, |
| 3568 | # so that the user can short-circuit this test for compilers unknown to |
| 3569 | # Autoconf. |
| 3570 | for ac_file in $ac_files '' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3571 | do |
| 3572 | test -f "$ac_file" || continue |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3573 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3574 | *.$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] | 3575 | ;; |
| 3576 | [ab].out ) |
| 3577 | # We found the default executable, but exeext='' is most |
| 3578 | # certainly right. |
| 3579 | break;; |
| 3580 | *.* ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3581 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3582 | then :; else |
| 3583 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3584 | fi |
| 3585 | # We set ac_cv_exeext here because the later test for it is not |
| 3586 | # safe: cross compilers may not add the suffix if given an `-o' |
| 3587 | # argument, so we may need to know it at that point already. |
| 3588 | # Even if this section looks crufty: it has the advantage of |
| 3589 | # actually working. |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3590 | break;; |
| 3591 | * ) |
| 3592 | break;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3593 | esac |
| 3594 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3595 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
| 3596 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3597 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3598 | ac_file='' |
| 3599 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3600 | if test -z "$ac_file"; then : |
| 3601 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 3602 | $as_echo "no" >&6; } |
| 3603 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3604 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3605 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3606 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3607 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3608 | as_fn_error 77 "C compiler cannot create executables |
| 3609 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3610 | else |
| 3611 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 3612 | $as_echo "yes" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3613 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
| 3615 | $as_echo_n "checking for C compiler default output file name... " >&6; } |
| 3616 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 |
| 3617 | $as_echo "$ac_file" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3618 | ac_exeext=$ac_cv_exeext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3619 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3620 | 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] | 3621 | ac_clean_files=$ac_clean_files_save |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3622 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
| 3623 | $as_echo_n "checking for suffix of executables... " >&6; } |
| 3624 | if { { ac_try="$ac_link" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3625 | case "(($ac_try" in |
| 3626 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3627 | *) ac_try_echo=$ac_try;; |
| 3628 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3629 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3630 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3631 | (eval "$ac_link") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3632 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3633 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3634 | test $ac_status = 0; }; then : |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3635 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
| 3636 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will |
| 3637 | # work properly (i.e., refer to `conftest.exe'), while it won't with |
| 3638 | # `rm'. |
| 3639 | for ac_file in conftest.exe conftest conftest.*; do |
| 3640 | test -f "$ac_file" || continue |
| 3641 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3642 | *.$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] | 3643 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
| 3644 | break;; |
| 3645 | * ) break;; |
| 3646 | esac |
| 3647 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3648 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3649 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3650 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3651 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
| 3652 | See \`config.log' for more details" "$LINENO" 5; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 3653 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3654 | rm -f conftest conftest$ac_cv_exeext |
| 3655 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
| 3656 | $as_echo "$ac_cv_exeext" >&6; } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3657 | |
| 3658 | rm -f conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3659 | EXEEXT=$ac_cv_exeext |
| 3660 | ac_exeext=$EXEEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3661 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 3662 | /* end confdefs.h. */ |
| 3663 | #include <stdio.h> |
| 3664 | int |
| 3665 | main () |
| 3666 | { |
| 3667 | FILE *f = fopen ("conftest.out", "w"); |
| 3668 | return ferror (f) || fclose (f) != 0; |
| 3669 | |
| 3670 | ; |
| 3671 | return 0; |
| 3672 | } |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3673 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3674 | ac_clean_files="$ac_clean_files conftest.out" |
| 3675 | # Check that the compiler produces executables we can run. If not, either |
| 3676 | # the compiler is broken, or we cross compile. |
| 3677 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 |
| 3678 | $as_echo_n "checking whether we are cross compiling... " >&6; } |
| 3679 | if test "$cross_compiling" != yes; then |
| 3680 | { { ac_try="$ac_link" |
| 3681 | case "(($ac_try" in |
| 3682 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3683 | *) ac_try_echo=$ac_try;; |
| 3684 | esac |
| 3685 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3686 | $as_echo "$ac_try_echo"; } >&5 |
| 3687 | (eval "$ac_link") 2>&5 |
| 3688 | ac_status=$? |
| 3689 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3690 | test $ac_status = 0; } |
| 3691 | if { ac_try='./conftest$ac_cv_exeext' |
| 3692 | { { case "(($ac_try" in |
| 3693 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3694 | *) ac_try_echo=$ac_try;; |
| 3695 | esac |
| 3696 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3697 | $as_echo "$ac_try_echo"; } >&5 |
| 3698 | (eval "$ac_try") 2>&5 |
| 3699 | ac_status=$? |
| 3700 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3701 | test $ac_status = 0; }; }; then |
| 3702 | cross_compiling=no |
| 3703 | else |
| 3704 | if test "$cross_compiling" = maybe; then |
| 3705 | cross_compiling=yes |
| 3706 | else |
| 3707 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3708 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3709 | as_fn_error $? "cannot run C compiled programs. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3710 | If you meant to cross compile, use \`--host'. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3711 | See \`config.log' for more details" "$LINENO" 5; } |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3712 | fi |
| 3713 | fi |
| 3714 | fi |
| 3715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 |
| 3716 | $as_echo "$cross_compiling" >&6; } |
| 3717 | |
| 3718 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out |
| 3719 | ac_clean_files=$ac_clean_files_save |
| 3720 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
| 3721 | $as_echo_n "checking for suffix of object files... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3722 | if ${ac_cv_objext+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3723 | $as_echo_n "(cached) " >&6 |
| 3724 | else |
| 3725 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3726 | /* end confdefs.h. */ |
| 3727 | |
| 3728 | int |
| 3729 | main () |
| 3730 | { |
| 3731 | |
| 3732 | ; |
| 3733 | return 0; |
| 3734 | } |
| 3735 | _ACEOF |
| 3736 | rm -f conftest.o conftest.obj |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3737 | if { { ac_try="$ac_compile" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3738 | case "(($ac_try" in |
| 3739 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
| 3740 | *) ac_try_echo=$ac_try;; |
| 3741 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3742 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
| 3743 | $as_echo "$ac_try_echo"; } >&5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3744 | (eval "$ac_compile") 2>&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3745 | ac_status=$? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3746 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
| 3747 | test $ac_status = 0; }; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3748 | for ac_file in conftest.o conftest.obj conftest.*; do |
| 3749 | test -f "$ac_file" || continue; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3750 | case $ac_file in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3751 | *.$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] | 3752 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
| 3753 | break;; |
| 3754 | esac |
| 3755 | done |
| 3756 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3757 | $as_echo "$as_me: failed program was:" >&5 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3758 | sed 's/^/| /' conftest.$ac_ext >&5 |
| 3759 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3760 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 3761 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3762 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
| 3763 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3764 | fi |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 3765 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3766 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3767 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
| 3768 | $as_echo "$ac_cv_objext" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3769 | OBJEXT=$ac_cv_objext |
| 3770 | ac_objext=$OBJEXT |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3771 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
| 3772 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3773 | if ${ac_cv_c_compiler_gnu+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3774 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3775 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3776 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3777 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3778 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3779 | int |
| 3780 | main () |
| 3781 | { |
| 3782 | #ifndef __GNUC__ |
| 3783 | choke me |
| 3784 | #endif |
| 3785 | |
| 3786 | ; |
| 3787 | return 0; |
| 3788 | } |
| 3789 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3790 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3791 | ac_compiler_gnu=yes |
| 3792 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3793 | ac_compiler_gnu=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3794 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3795 | 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] | 3796 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
| 3797 | |
| 3798 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3799 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
| 3800 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
| 3801 | if test $ac_compiler_gnu = yes; then |
| 3802 | GCC=yes |
| 3803 | else |
| 3804 | GCC= |
| 3805 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3806 | ac_test_CFLAGS=${CFLAGS+set} |
| 3807 | ac_save_CFLAGS=$CFLAGS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3808 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
| 3809 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3810 | if ${ac_cv_prog_cc_g+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3811 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3812 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3813 | ac_save_c_werror_flag=$ac_c_werror_flag |
| 3814 | ac_c_werror_flag=yes |
| 3815 | ac_cv_prog_cc_g=no |
| 3816 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3817 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3818 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3819 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3820 | int |
| 3821 | main () |
| 3822 | { |
| 3823 | |
| 3824 | ; |
| 3825 | return 0; |
| 3826 | } |
| 3827 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3828 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3829 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3830 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3831 | CFLAGS="" |
| 3832 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3833 | /* end confdefs.h. */ |
| 3834 | |
| 3835 | int |
| 3836 | main () |
| 3837 | { |
| 3838 | |
| 3839 | ; |
| 3840 | return 0; |
| 3841 | } |
| 3842 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3843 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3844 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3845 | else |
| 3846 | ac_c_werror_flag=$ac_save_c_werror_flag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3847 | CFLAGS="-g" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3848 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3849 | /* end confdefs.h. */ |
| 3850 | |
| 3851 | int |
| 3852 | main () |
| 3853 | { |
| 3854 | |
| 3855 | ; |
| 3856 | return 0; |
| 3857 | } |
| 3858 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3859 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3860 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3861 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3862 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3863 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3864 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3865 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3866 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 3867 | ac_c_werror_flag=$ac_save_c_werror_flag |
| 3868 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3869 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
| 3870 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3871 | if test "$ac_test_CFLAGS" = set; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3872 | CFLAGS=$ac_save_CFLAGS |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3873 | elif test $ac_cv_prog_cc_g = yes; then |
| 3874 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3875 | CFLAGS="-g -O2" |
| 3876 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3877 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3878 | fi |
| 3879 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3880 | if test "$GCC" = yes; then |
| 3881 | CFLAGS="-O2" |
| 3882 | else |
| 3883 | CFLAGS= |
| 3884 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3885 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3886 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
| 3887 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 3888 | if ${ac_cv_prog_cc_c89+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3889 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3890 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3891 | ac_cv_prog_cc_c89=no |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3892 | ac_save_CC=$CC |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3893 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3894 | /* end confdefs.h. */ |
| 3895 | #include <stdarg.h> |
| 3896 | #include <stdio.h> |
| 3897 | #include <sys/types.h> |
| 3898 | #include <sys/stat.h> |
| 3899 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
| 3900 | struct buf { int x; }; |
| 3901 | FILE * (*rcsopen) (struct buf *, struct stat *, int); |
| 3902 | static char *e (p, i) |
| 3903 | char **p; |
| 3904 | int i; |
| 3905 | { |
| 3906 | return p[i]; |
| 3907 | } |
| 3908 | static char *f (char * (*g) (char **, int), char **p, ...) |
| 3909 | { |
| 3910 | char *s; |
| 3911 | va_list v; |
| 3912 | va_start (v,p); |
| 3913 | s = g (p, va_arg (v,int)); |
| 3914 | va_end (v); |
| 3915 | return s; |
| 3916 | } |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3917 | |
| 3918 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has |
| 3919 | function prototypes and stuff, but not '\xHH' hex character constants. |
| 3920 | These don't provoke an error unfortunately, instead are silently treated |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3921 | 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] | 3922 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
| 3923 | 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] | 3924 | that's true only with -std. */ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 3925 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
| 3926 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3927 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
| 3928 | inside strings and character constants. */ |
| 3929 | #define FOO(x) 'x' |
| 3930 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; |
| 3931 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3932 | int test (int i, double x); |
| 3933 | struct s1 {int (*f) (int a);}; |
| 3934 | struct s2 {int (*f) (double a);}; |
| 3935 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); |
| 3936 | int argc; |
| 3937 | char **argv; |
| 3938 | int |
| 3939 | main () |
| 3940 | { |
| 3941 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
| 3942 | ; |
| 3943 | return 0; |
| 3944 | } |
| 3945 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3946 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
| 3947 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3948 | do |
| 3949 | CC="$ac_save_CC $ac_arg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3950 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3951 | ac_cv_prog_cc_c89=$ac_arg |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3952 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3953 | rm -f core conftest.err conftest.$ac_objext |
| 3954 | test "x$ac_cv_prog_cc_c89" != "xno" && break |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3955 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3956 | rm -f conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3957 | CC=$ac_save_CC |
| 3958 | |
| 3959 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3960 | # AC_CACHE_VAL |
| 3961 | case "x$ac_cv_prog_cc_c89" in |
| 3962 | x) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3963 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
| 3964 | $as_echo "none needed" >&6; } ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3965 | xno) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3966 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
| 3967 | $as_echo "unsupported" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3968 | *) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3969 | CC="$CC $ac_cv_prog_cc_c89" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3970 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
| 3971 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3972 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3973 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3974 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3975 | fi |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 3976 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 3977 | ac_ext=c |
| 3978 | ac_cpp='$CPP $CPPFLAGS' |
| 3979 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 3980 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 3981 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3982 | |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 3983 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3984 | |
| 3985 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3986 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-cxx-main=<compiler>" >&5 |
| 3987 | $as_echo_n "checking for --with-cxx-main=<compiler>... " >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3988 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3989 | # Check whether --with-cxx_main was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 3990 | if test "${with_cxx_main+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 3991 | withval=$with_cxx_main; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 3992 | |
| 3993 | case $withval in |
| 3994 | no) with_cxx_main=no |
| 3995 | MAINCC='$(CC)';; |
| 3996 | yes) with_cxx_main=yes |
| 3997 | MAINCC='$(CXX)';; |
| 3998 | *) with_cxx_main=yes |
| 3999 | MAINCC=$withval |
| 4000 | if test -z "$CXX" |
| 4001 | then |
| 4002 | CXX=$withval |
| 4003 | fi;; |
| 4004 | esac |
| 4005 | else |
| 4006 | |
| 4007 | with_cxx_main=no |
| 4008 | MAINCC='$(CC)' |
| 4009 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4010 | fi |
| 4011 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_cxx_main" >&5 |
| 4013 | $as_echo "$with_cxx_main" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4014 | |
| 4015 | preset_cxx="$CXX" |
| 4016 | if test -z "$CXX" |
| 4017 | then |
| 4018 | case "$CC" in |
| 4019 | gcc) # Extract the first word of "g++", so it can be a program name with args. |
| 4020 | set dummy g++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4021 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4022 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4023 | if ${ac_cv_path_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4024 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4025 | else |
| 4026 | case $CXX in |
| 4027 | [\\/]* | ?:[\\/]*) |
| 4028 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4029 | ;; |
| 4030 | *) |
| 4031 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4032 | for as_dir in notfound |
| 4033 | do |
| 4034 | IFS=$as_save_IFS |
| 4035 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4036 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4037 | 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] | 4038 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4039 | $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] | 4040 | break 2 |
| 4041 | fi |
| 4042 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4043 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4044 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4045 | |
| 4046 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++" |
| 4047 | ;; |
| 4048 | esac |
| 4049 | fi |
| 4050 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4051 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4053 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4054 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4056 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4057 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4058 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4059 | ;; |
| 4060 | cc) # Extract the first word of "c++", so it can be a program name with args. |
| 4061 | set dummy c++; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4063 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4064 | if ${ac_cv_path_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4065 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4066 | else |
| 4067 | case $CXX in |
| 4068 | [\\/]* | ?:[\\/]*) |
| 4069 | ac_cv_path_CXX="$CXX" # Let the user override the test with a path. |
| 4070 | ;; |
| 4071 | *) |
| 4072 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4073 | for as_dir in notfound |
| 4074 | do |
| 4075 | IFS=$as_save_IFS |
| 4076 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4077 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4078 | 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] | 4079 | ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4080 | $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] | 4081 | break 2 |
| 4082 | fi |
| 4083 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4084 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4085 | IFS=$as_save_IFS |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4086 | |
| 4087 | test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++" |
| 4088 | ;; |
| 4089 | esac |
| 4090 | fi |
| 4091 | CXX=$ac_cv_path_CXX |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4092 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4093 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4094 | $as_echo "$CXX" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4095 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4096 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4097 | $as_echo "no" >&6; } |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 4098 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4099 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4100 | ;; |
| 4101 | esac |
| 4102 | if test "$CXX" = "notfound" |
| 4103 | then |
| 4104 | CXX="" |
| 4105 | fi |
| 4106 | fi |
| 4107 | if test -z "$CXX" |
| 4108 | then |
| 4109 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 4110 | do |
| 4111 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 4112 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4113 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 4114 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4115 | if ${ac_cv_prog_CXX+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4116 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4117 | else |
| 4118 | if test -n "$CXX"; then |
| 4119 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 4120 | else |
| 4121 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 4122 | for as_dir in $PATH |
| 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_prog_CXX="$ac_prog" |
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 | fi |
| 4137 | fi |
| 4138 | CXX=$ac_cv_prog_CXX |
| 4139 | if test -n "$CXX"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4140 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 |
| 4141 | $as_echo "$CXX" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4142 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4143 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4144 | $as_echo "no" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4145 | fi |
| 4146 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4147 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4148 | test -n "$CXX" && break |
| 4149 | done |
| 4150 | test -n "$CXX" || CXX="notfound" |
| 4151 | |
| 4152 | if test "$CXX" = "notfound" |
| 4153 | then |
| 4154 | CXX="" |
| 4155 | fi |
| 4156 | fi |
| 4157 | if test "$preset_cxx" != "$CXX" |
| 4158 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4159 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4160 | |
| 4161 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4162 | If this is not intended, then set CXX on the configure command line. |
| 4163 | " >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4164 | $as_echo "$as_me: WARNING: |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 4165 | |
| 4166 | By default, distutils will build C++ extension modules with \"$CXX\". |
| 4167 | If this is not intended, then set CXX on the configure command line. |
| 4168 | " >&2;} |
| 4169 | fi |
| 4170 | |
| 4171 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4172 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wl,--no-as-needed" >&5 |
| 4173 | $as_echo_n "checking for -Wl,--no-as-needed... " >&6; } |
| 4174 | save_LDFLAGS="$LDFLAGS" |
| 4175 | LDFLAGS="$LDFLAGS -Wl,--no-as-needed" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4176 | |
Martin v. Löwis | 48e14d3 | 2011-05-09 07:37:45 +0200 | [diff] [blame] | 4177 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4178 | /* end confdefs.h. */ |
| 4179 | |
| 4180 | int |
| 4181 | main () |
| 4182 | { |
| 4183 | |
| 4184 | ; |
| 4185 | return 0; |
| 4186 | } |
| 4187 | _ACEOF |
| 4188 | if ac_fn_c_try_link "$LINENO"; then : |
| 4189 | NO_AS_NEEDED="-Wl,--no-as-needed" |
| 4190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4191 | $as_echo "yes" >&6; } |
| 4192 | else |
| 4193 | NO_AS_NEEDED="" |
| 4194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4195 | $as_echo "no" >&6; } |
| 4196 | fi |
| 4197 | rm -f core conftest.err conftest.$ac_objext \ |
| 4198 | conftest$ac_exeext conftest.$ac_ext |
| 4199 | LDFLAGS="$save_LDFLAGS" |
| 4200 | |
| 4201 | |
| 4202 | |
| 4203 | # checks for UNIX variants that set C preprocessor variables |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4204 | ac_ext=c |
| 4205 | ac_cpp='$CPP $CPPFLAGS' |
| 4206 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4207 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4208 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4209 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
| 4210 | $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] | 4211 | # On Suns, sometimes $CPP names a directory. |
| 4212 | if test -n "$CPP" && test -d "$CPP"; then |
| 4213 | CPP= |
| 4214 | fi |
| 4215 | if test -z "$CPP"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4216 | if ${ac_cv_prog_CPP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4217 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4218 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4219 | # Double quotes because CPP needs to be expanded |
| 4220 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" |
| 4221 | do |
| 4222 | ac_preproc_ok=false |
| 4223 | for ac_c_preproc_warn_flag in '' yes |
| 4224 | do |
| 4225 | # Use a header file that comes with gcc, so configuring glibc |
| 4226 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4227 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4228 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1d5ecb7 | 2001-08-09 10:29:44 +0000 | [diff] [blame] | 4229 | # 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] | 4230 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4231 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4232 | /* end confdefs.h. */ |
| 4233 | #ifdef __STDC__ |
| 4234 | # include <limits.h> |
| 4235 | #else |
| 4236 | # include <assert.h> |
| 4237 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4238 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4239 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4240 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4241 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4242 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4243 | # Broken: fails on valid input. |
| 4244 | continue |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4245 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4246 | rm -f conftest.err conftest.i conftest.$ac_ext |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 4247 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4248 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4249 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4250 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4251 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4252 | #include <ac_nonexistent.h> |
| 4253 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4254 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4255 | # Broken: success on invalid input. |
| 4256 | continue |
| 4257 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4258 | # Passes both tests. |
| 4259 | ac_preproc_ok=: |
| 4260 | break |
| 4261 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4262 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4263 | |
| 4264 | done |
| 4265 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4266 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4267 | if $ac_preproc_ok; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4268 | break |
| 4269 | fi |
| 4270 | |
| 4271 | done |
| 4272 | ac_cv_prog_CPP=$CPP |
| 4273 | |
| 4274 | fi |
| 4275 | CPP=$ac_cv_prog_CPP |
| 4276 | else |
| 4277 | ac_cv_prog_CPP=$CPP |
| 4278 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4279 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
| 4280 | $as_echo "$CPP" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4281 | ac_preproc_ok=false |
| 4282 | for ac_c_preproc_warn_flag in '' yes |
| 4283 | do |
| 4284 | # Use a header file that comes with gcc, so configuring glibc |
| 4285 | # with a fresh cross-compiler works. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4286 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
| 4287 | # <limits.h> exists even on freestanding compilers. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4288 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 4289 | # not just through cpp. "Syntax error" is here to catch this case. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4290 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4291 | /* end confdefs.h. */ |
| 4292 | #ifdef __STDC__ |
| 4293 | # include <limits.h> |
| 4294 | #else |
| 4295 | # include <assert.h> |
| 4296 | #endif |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 4297 | Syntax error |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4298 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4299 | if ac_fn_c_try_cpp "$LINENO"; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4300 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4301 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4302 | # Broken: fails on valid input. |
| 4303 | continue |
| 4304 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4305 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4306 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4307 | # OK, works on sane cases. Now check whether nonexistent headers |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4308 | # can be detected and how. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4309 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4310 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4311 | #include <ac_nonexistent.h> |
| 4312 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4313 | if ac_fn_c_try_cpp "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4314 | # Broken: success on invalid input. |
| 4315 | continue |
| 4316 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4317 | # Passes both tests. |
| 4318 | ac_preproc_ok=: |
| 4319 | break |
| 4320 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4321 | rm -f conftest.err conftest.i conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4322 | |
| 4323 | done |
| 4324 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4325 | rm -f conftest.i conftest.err conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4326 | if $ac_preproc_ok; then : |
| 4327 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4328 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4329 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 4330 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4331 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
| 4332 | See \`config.log' for more details" "$LINENO" 5; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 4333 | fi |
| 4334 | |
| 4335 | ac_ext=c |
| 4336 | ac_cpp='$CPP $CPPFLAGS' |
| 4337 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' |
| 4338 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
| 4339 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
| 4340 | |
| 4341 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
| 4343 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4344 | if ${ac_cv_path_GREP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4345 | $as_echo_n "(cached) " >&6 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4346 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4347 | if test -z "$GREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4348 | ac_path_GREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4349 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4350 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4351 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4352 | do |
| 4353 | IFS=$as_save_IFS |
| 4354 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4355 | for ac_prog in grep ggrep; do |
| 4356 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4357 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4358 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue |
| 4359 | # 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] | 4360 | # Check for GNU $ac_path_GREP |
| 4361 | case `"$ac_path_GREP" --version 2>&1` in |
| 4362 | *GNU*) |
| 4363 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; |
| 4364 | *) |
| 4365 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4366 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4367 | while : |
| 4368 | do |
| 4369 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4370 | mv "conftest.tmp" "conftest.in" |
| 4371 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4372 | $as_echo 'GREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4373 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4374 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4375 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4376 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
| 4377 | # Best one so far, save it but keep looking for a better one |
| 4378 | ac_cv_path_GREP="$ac_path_GREP" |
| 4379 | ac_path_GREP_max=$ac_count |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4380 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4381 | # 10*(2^10) chars as input seems more than enough |
| 4382 | test $ac_count -gt 10 && break |
| 4383 | done |
| 4384 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4385 | esac |
| 4386 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4387 | $ac_path_GREP_found && break 3 |
| 4388 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4389 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4390 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4391 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4392 | if test -z "$ac_cv_path_GREP"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4393 | 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] | 4394 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4395 | else |
| 4396 | ac_cv_path_GREP=$GREP |
| 4397 | fi |
| 4398 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4399 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4400 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
| 4401 | $as_echo "$ac_cv_path_GREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4402 | GREP="$ac_cv_path_GREP" |
| 4403 | |
| 4404 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4405 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
| 4406 | $as_echo_n "checking for egrep... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4407 | if ${ac_cv_path_EGREP+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4408 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4409 | else |
| 4410 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
| 4411 | then ac_cv_path_EGREP="$GREP -E" |
| 4412 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4413 | if test -z "$EGREP"; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4414 | ac_path_EGREP_found=false |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4415 | # Loop through the user's path and test for each of PROGNAME-LIST |
| 4416 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4417 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
| 4418 | do |
| 4419 | IFS=$as_save_IFS |
| 4420 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4421 | for ac_prog in egrep; do |
| 4422 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 4423 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" |
| 4424 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue |
| 4425 | # 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] | 4426 | # Check for GNU $ac_path_EGREP |
| 4427 | case `"$ac_path_EGREP" --version 2>&1` in |
| 4428 | *GNU*) |
| 4429 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; |
| 4430 | *) |
| 4431 | ac_count=0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4432 | $as_echo_n 0123456789 >"conftest.in" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4433 | while : |
| 4434 | do |
| 4435 | cat "conftest.in" "conftest.in" >"conftest.tmp" |
| 4436 | mv "conftest.tmp" "conftest.in" |
| 4437 | cp "conftest.in" "conftest.nl" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4438 | $as_echo 'EGREP' >> "conftest.nl" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4439 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
| 4440 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4441 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4442 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
| 4443 | # Best one so far, save it but keep looking for a better one |
| 4444 | ac_cv_path_EGREP="$ac_path_EGREP" |
| 4445 | ac_path_EGREP_max=$ac_count |
| 4446 | fi |
| 4447 | # 10*(2^10) chars as input seems more than enough |
| 4448 | test $ac_count -gt 10 && break |
| 4449 | done |
| 4450 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; |
| 4451 | esac |
| 4452 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4453 | $ac_path_EGREP_found && break 3 |
| 4454 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4455 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4456 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4457 | IFS=$as_save_IFS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4458 | if test -z "$ac_cv_path_EGREP"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4459 | 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] | 4460 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4461 | else |
| 4462 | ac_cv_path_EGREP=$EGREP |
| 4463 | fi |
| 4464 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4465 | fi |
| 4466 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4467 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
| 4468 | $as_echo "$ac_cv_path_EGREP" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 4469 | EGREP="$ac_cv_path_EGREP" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 4470 | |
| 4471 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4472 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 4473 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4474 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4475 | $as_echo_n "(cached) " >&6 |
| 4476 | else |
| 4477 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4478 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4479 | #include <stdlib.h> |
| 4480 | #include <stdarg.h> |
| 4481 | #include <string.h> |
| 4482 | #include <float.h> |
| 4483 | |
| 4484 | int |
| 4485 | main () |
| 4486 | { |
| 4487 | |
| 4488 | ; |
| 4489 | return 0; |
| 4490 | } |
| 4491 | _ACEOF |
| 4492 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4493 | ac_cv_header_stdc=yes |
| 4494 | else |
| 4495 | ac_cv_header_stdc=no |
| 4496 | fi |
| 4497 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4498 | |
| 4499 | if test $ac_cv_header_stdc = yes; then |
| 4500 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 4501 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4502 | /* end confdefs.h. */ |
| 4503 | #include <string.h> |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4504 | |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 4505 | _ACEOF |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4506 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4507 | $EGREP "memchr" >/dev/null 2>&1; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4508 | |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4509 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4510 | ac_cv_header_stdc=no |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 4511 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 4512 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4513 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4514 | fi |
| 4515 | |
| 4516 | if test $ac_cv_header_stdc = yes; then |
| 4517 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 4518 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4519 | /* end confdefs.h. */ |
| 4520 | #include <stdlib.h> |
| 4521 | |
| 4522 | _ACEOF |
| 4523 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 4524 | $EGREP "free" >/dev/null 2>&1; then : |
| 4525 | |
| 4526 | else |
| 4527 | ac_cv_header_stdc=no |
| 4528 | fi |
| 4529 | rm -f conftest* |
| 4530 | |
| 4531 | fi |
| 4532 | |
| 4533 | if test $ac_cv_header_stdc = yes; then |
| 4534 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 4535 | if test "$cross_compiling" = yes; then : |
| 4536 | : |
| 4537 | else |
| 4538 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4539 | /* end confdefs.h. */ |
| 4540 | #include <ctype.h> |
| 4541 | #include <stdlib.h> |
| 4542 | #if ((' ' & 0x0FF) == 0x020) |
| 4543 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 4544 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 4545 | #else |
| 4546 | # define ISLOWER(c) \ |
| 4547 | (('a' <= (c) && (c) <= 'i') \ |
| 4548 | || ('j' <= (c) && (c) <= 'r') \ |
| 4549 | || ('s' <= (c) && (c) <= 'z')) |
| 4550 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 4551 | #endif |
| 4552 | |
| 4553 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 4554 | int |
| 4555 | main () |
| 4556 | { |
| 4557 | int i; |
| 4558 | for (i = 0; i < 256; i++) |
| 4559 | if (XOR (islower (i), ISLOWER (i)) |
| 4560 | || toupper (i) != TOUPPER (i)) |
| 4561 | return 2; |
| 4562 | return 0; |
| 4563 | } |
| 4564 | _ACEOF |
| 4565 | if ac_fn_c_try_run "$LINENO"; then : |
| 4566 | |
| 4567 | else |
| 4568 | ac_cv_header_stdc=no |
| 4569 | fi |
| 4570 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4571 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 4572 | fi |
| 4573 | |
| 4574 | fi |
| 4575 | fi |
| 4576 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 4577 | $as_echo "$ac_cv_header_stdc" >&6; } |
| 4578 | if test $ac_cv_header_stdc = yes; then |
| 4579 | |
| 4580 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
| 4581 | |
| 4582 | fi |
| 4583 | |
| 4584 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
| 4585 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
| 4586 | inttypes.h stdint.h unistd.h |
| 4587 | do : |
| 4588 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 4589 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default |
| 4590 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4591 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4592 | cat >>confdefs.h <<_ACEOF |
| 4593 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
| 4594 | _ACEOF |
| 4595 | |
| 4596 | fi |
| 4597 | |
| 4598 | done |
| 4599 | |
| 4600 | |
| 4601 | |
| 4602 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4603 | if test "x$ac_cv_header_minix_config_h" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4604 | MINIX=yes |
| 4605 | else |
| 4606 | MINIX= |
| 4607 | fi |
| 4608 | |
| 4609 | |
| 4610 | if test "$MINIX" = yes; then |
| 4611 | |
| 4612 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
| 4613 | |
| 4614 | |
| 4615 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
| 4616 | |
| 4617 | |
| 4618 | $as_echo "#define _MINIX 1" >>confdefs.h |
| 4619 | |
| 4620 | fi |
| 4621 | |
| 4622 | |
| 4623 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
| 4624 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4625 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4626 | $as_echo_n "(cached) " >&6 |
| 4627 | else |
| 4628 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4629 | /* end confdefs.h. */ |
| 4630 | |
| 4631 | # define __EXTENSIONS__ 1 |
| 4632 | $ac_includes_default |
| 4633 | int |
| 4634 | main () |
| 4635 | { |
| 4636 | |
| 4637 | ; |
| 4638 | return 0; |
| 4639 | } |
| 4640 | _ACEOF |
| 4641 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4642 | ac_cv_safe_to_define___extensions__=yes |
| 4643 | else |
| 4644 | ac_cv_safe_to_define___extensions__=no |
| 4645 | fi |
| 4646 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4647 | fi |
| 4648 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
| 4649 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
| 4650 | test $ac_cv_safe_to_define___extensions__ = yes && |
| 4651 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
| 4652 | |
| 4653 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
| 4654 | |
| 4655 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
| 4656 | |
| 4657 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
| 4658 | |
| 4659 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h |
| 4660 | |
| 4661 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4662 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4663 | # Check for unsupported systems |
| 4664 | case $ac_sys_system/$ac_sys_release in |
| 4665 | atheos*|Linux*/1*) |
| 4666 | echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported. |
| 4667 | echo See README for details. |
| 4668 | exit 1;; |
| 4669 | esac |
| 4670 | |
| 4671 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-suffix" >&5 |
| 4673 | $as_echo_n "checking for --with-suffix... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4674 | |
| 4675 | # Check whether --with-suffix was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4676 | if test "${with_suffix+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4677 | withval=$with_suffix; |
| 4678 | case $withval in |
| 4679 | no) EXEEXT=;; |
| 4680 | yes) EXEEXT=.exe;; |
| 4681 | *) EXEEXT=$withval;; |
| 4682 | esac |
| 4683 | fi |
| 4684 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5 |
| 4686 | $as_echo "$EXEEXT" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4687 | |
| 4688 | # Test whether we're running on a non-case-sensitive system, in which |
| 4689 | # case we give a warning if no ext is given |
| 4690 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4691 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for case-insensitive build directory" >&5 |
| 4692 | $as_echo_n "checking for case-insensitive build directory... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4693 | if test ! -d CaseSensitiveTestDir; then |
| 4694 | mkdir CaseSensitiveTestDir |
| 4695 | fi |
| 4696 | |
| 4697 | if test -d casesensitivetestdir |
| 4698 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 4700 | $as_echo "yes" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4701 | BUILDEXEEXT=.exe |
| 4702 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4703 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 4704 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4705 | BUILDEXEEXT=$EXEEXT |
| 4706 | fi |
| 4707 | rmdir CaseSensitiveTestDir |
| 4708 | |
| 4709 | case $MACHDEP in |
| 4710 | bsdos*) |
| 4711 | case $CC in |
| 4712 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 4713 | esac;; |
| 4714 | esac |
| 4715 | |
| 4716 | case $ac_sys_system in |
| 4717 | hp*|HP*) |
| 4718 | case $CC in |
| 4719 | cc|*/cc) CC="$CC -Ae";; |
| 4720 | esac;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4721 | esac |
| 4722 | |
| 4723 | |
| 4724 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY" >&5 |
| 4726 | $as_echo_n "checking LIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4727 | if test -z "$LIBRARY" |
| 4728 | then |
Barry Warsaw | f040d7d | 2010-10-18 17:09:07 +0000 | [diff] [blame] | 4729 | LIBRARY='libpython$(VERSION)$(ABIFLAGS).a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4730 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4731 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBRARY" >&5 |
| 4732 | $as_echo "$LIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4733 | |
| 4734 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 4735 | # name of the library into which to insert object files). BLDLIBRARY is also |
| 4736 | # the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY |
| 4737 | # is blank as the main program is not linked directly against LDLIBRARY. |
| 4738 | # LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On |
| 4739 | # systems without shared libraries, LDLIBRARY is the same as LIBRARY |
| 4740 | # (defined in the Makefiles). On Cygwin LDLIBRARY is the import library, |
| 4741 | # DLLLIBRARY is the shared (i.e., DLL) library. |
| 4742 | # |
| 4743 | # RUNSHARED is used to run shared python without installed libraries |
| 4744 | # |
| 4745 | # INSTSONAME is the name of the shared library that will be use to install |
| 4746 | # on the system - some systems like version suffix, others don't |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4747 | # |
| 4748 | # LDVERSION is the shared library version number, normally the Python version |
| 4749 | # with the ABI build flags appended. |
| 4750 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4751 | |
| 4752 | |
| 4753 | |
| 4754 | |
| 4755 | |
| 4756 | |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 4757 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4758 | LDLIBRARY="$LIBRARY" |
| 4759 | BLDLIBRARY='$(LDLIBRARY)' |
| 4760 | INSTSONAME='$(LDLIBRARY)' |
| 4761 | DLLLIBRARY='' |
| 4762 | LDLIBRARYDIR='' |
| 4763 | RUNSHARED='' |
Barry Warsaw | 14d98ac | 2010-11-24 19:43:47 +0000 | [diff] [blame] | 4764 | LDVERSION="$VERSION" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4765 | |
| 4766 | # LINKCC is the command that links the python executable -- default is $(CC). |
| 4767 | # If CXX is set, and if it is needed to link a main function that was |
| 4768 | # compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable: |
| 4769 | # python might then depend on the C++ runtime |
| 4770 | # This is altered for AIX in order to build the export list before |
| 4771 | # linking. |
| 4772 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4773 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKCC" >&5 |
| 4774 | $as_echo_n "checking LINKCC... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4775 | if test -z "$LINKCC" |
| 4776 | then |
| 4777 | LINKCC='$(PURIFY) $(MAINCC)' |
| 4778 | case $ac_sys_system in |
| 4779 | AIX*) |
| 4780 | exp_extra="\"\"" |
| 4781 | if test $ac_sys_release -ge 5 -o \ |
| 4782 | $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then |
| 4783 | exp_extra="." |
| 4784 | fi |
| 4785 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4786 | QNX*) |
| 4787 | # qcc must be used because the other compilers do not |
| 4788 | # support -N. |
| 4789 | LINKCC=qcc;; |
| 4790 | esac |
| 4791 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKCC" >&5 |
| 4793 | $as_echo "$LINKCC" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4794 | |
| 4795 | # GNULD is set to "yes" if the GNU linker is used. If this goes wrong |
| 4796 | # make sure we default having it set to "no": this is used by |
| 4797 | # distutils.unixccompiler to know if it should add --enable-new-dtags |
| 4798 | # to linker command lines, and failing to detect GNU ld simply results |
| 4799 | # in the same bahaviour as before. |
| 4800 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4801 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
| 4802 | $as_echo_n "checking for GNU ld... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4803 | ac_prog=ld |
| 4804 | if test "$GCC" = yes; then |
| 4805 | ac_prog=`$CC -print-prog-name=ld` |
| 4806 | fi |
| 4807 | case `"$ac_prog" -V 2>&1 < /dev/null` in |
| 4808 | *GNU*) |
| 4809 | GNULD=yes;; |
| 4810 | *) |
| 4811 | GNULD=no;; |
| 4812 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4813 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNULD" >&5 |
| 4814 | $as_echo "$GNULD" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4815 | |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4816 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
| 4817 | $as_echo_n "checking for inline... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4818 | if ${ac_cv_c_inline+:} false; then : |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4819 | $as_echo_n "(cached) " >&6 |
| 4820 | else |
| 4821 | ac_cv_c_inline=no |
| 4822 | for ac_kw in inline __inline__ __inline; do |
| 4823 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 4824 | /* end confdefs.h. */ |
| 4825 | #ifndef __cplusplus |
| 4826 | typedef int foo_t; |
| 4827 | static $ac_kw foo_t static_foo () {return 0; } |
| 4828 | $ac_kw foo_t foo () {return 0; } |
| 4829 | #endif |
| 4830 | |
| 4831 | _ACEOF |
| 4832 | if ac_fn_c_try_compile "$LINENO"; then : |
| 4833 | ac_cv_c_inline=$ac_kw |
| 4834 | fi |
| 4835 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 4836 | test "$ac_cv_c_inline" != no && break |
| 4837 | done |
| 4838 | |
| 4839 | fi |
| 4840 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
| 4841 | $as_echo "$ac_cv_c_inline" >&6; } |
| 4842 | |
| 4843 | case $ac_cv_c_inline in |
| 4844 | inline | yes) ;; |
| 4845 | *) |
| 4846 | case $ac_cv_c_inline in |
| 4847 | no) ac_val=;; |
| 4848 | *) ac_val=$ac_cv_c_inline;; |
| 4849 | esac |
| 4850 | cat >>confdefs.h <<_ACEOF |
| 4851 | #ifndef __cplusplus |
| 4852 | #define inline $ac_val |
| 4853 | #endif |
| 4854 | _ACEOF |
| 4855 | ;; |
| 4856 | esac |
| 4857 | |
| 4858 | if test "$ac_cv_c_inline" != no ; then |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 4859 | |
| 4860 | $as_echo "#define USE_INLINE 1" >>confdefs.h |
Daniel Stutzbach | a606faa | 2010-08-31 19:51:07 +0000 | [diff] [blame] | 4861 | |
| 4862 | |
| 4863 | fi |
| 4864 | |
| 4865 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4866 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-shared" >&5 |
| 4867 | $as_echo_n "checking for --enable-shared... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4868 | # Check whether --enable-shared was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4869 | if test "${enable_shared+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4870 | enableval=$enable_shared; |
| 4871 | fi |
| 4872 | |
| 4873 | |
| 4874 | if test -z "$enable_shared" |
| 4875 | then |
| 4876 | case $ac_sys_system in |
Antoine Pitrou | 6103ab1 | 2009-10-24 20:11:21 +0000 | [diff] [blame] | 4877 | CYGWIN*) |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4878 | enable_shared="yes";; |
| 4879 | *) |
| 4880 | enable_shared="no";; |
| 4881 | esac |
| 4882 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4883 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
| 4884 | $as_echo "$enable_shared" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4885 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4886 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-profiling" >&5 |
| 4887 | $as_echo_n "checking for --enable-profiling... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4888 | # Check whether --enable-profiling was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4889 | if test "${enable_profiling+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4890 | enableval=$enable_profiling; ac_save_cc="$CC" |
| 4891 | CC="$CC -pg" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4892 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4893 | ac_enable_profiling="no" |
| 4894 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4895 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4896 | /* end confdefs.h. */ |
| 4897 | int main() { return 0; } |
| 4898 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4899 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4900 | ac_enable_profiling="yes" |
| 4901 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4902 | ac_enable_profiling="no" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4903 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4904 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 4905 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4906 | fi |
| 4907 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4908 | CC="$ac_save_cc" |
| 4909 | fi |
| 4910 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4911 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_profiling" >&5 |
| 4912 | $as_echo "$ac_enable_profiling" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4913 | |
| 4914 | case "$ac_enable_profiling" in |
| 4915 | "yes") |
| 4916 | BASECFLAGS="-pg $BASECFLAGS" |
| 4917 | LDFLAGS="-pg $LDFLAGS" |
| 4918 | ;; |
| 4919 | esac |
| 4920 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4921 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDLIBRARY" >&5 |
| 4922 | $as_echo_n "checking LDLIBRARY... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4923 | |
| 4924 | # MacOSX framework builds need more magic. LDLIBRARY is the dynamic |
| 4925 | # library that we build, but we do not want to link against it (we |
| 4926 | # will find it with a -framework option). For this reason there is an |
| 4927 | # extra variable BLDLIBRARY against which Python and the extension |
| 4928 | # modules are linked, BLDLIBRARY. This is normally the same as |
| 4929 | # LDLIBRARY, but empty for MacOSX framework builds. |
| 4930 | if test "$enable_framework" |
| 4931 | then |
| 4932 | LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 4933 | RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH" |
| 4934 | BLDLIBRARY='' |
| 4935 | else |
| 4936 | BLDLIBRARY='$(LDLIBRARY)' |
| 4937 | fi |
| 4938 | |
| 4939 | # Other platforms follow |
| 4940 | if test $enable_shared = "yes"; then |
| 4941 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 4942 | $as_echo "#define Py_ENABLE_SHARED 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4943 | |
| 4944 | case $ac_sys_system in |
| 4945 | CYGWIN*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4946 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
| 4947 | DLLLIBRARY='libpython$(LDVERSION).dll' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4948 | ;; |
| 4949 | SunOS*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4950 | LDLIBRARY='libpython$(LDVERSION).so' |
| 4951 | BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4952 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4953 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4954 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 4955 | then |
| 4956 | PY3LIBRARY=libpython3.so |
| 4957 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4958 | ;; |
| 4959 | Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4960 | LDLIBRARY='libpython$(LDVERSION).so' |
| 4961 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4962 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4963 | case $ac_sys_system in |
| 4964 | FreeBSD*) |
| 4965 | SOVERSION=`echo $SOVERSION|cut -d "." -f 1` |
| 4966 | ;; |
| 4967 | esac |
| 4968 | INSTSONAME="$LDLIBRARY".$SOVERSION |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 4969 | if test "$with_pydebug" != yes |
Martin v. Löwis | d1fc34d | 2010-12-30 14:55:47 +0000 | [diff] [blame] | 4970 | then |
| 4971 | PY3LIBRARY=libpython3.so |
| 4972 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4973 | ;; |
| 4974 | hp*|HP*) |
| 4975 | case `uname -m` in |
| 4976 | ia64) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4977 | LDLIBRARY='libpython$(LDVERSION).so' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4978 | ;; |
| 4979 | *) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4980 | LDLIBRARY='libpython$(LDVERSION).sl' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4981 | ;; |
| 4982 | esac |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4983 | BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4984 | RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH} |
| 4985 | ;; |
| 4986 | OSF*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4987 | LDLIBRARY='libpython$(LDVERSION).so' |
| 4988 | BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4989 | RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH} |
| 4990 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4991 | Darwin*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4992 | LDLIBRARY='libpython$(LDVERSION).dylib' |
| 4993 | BLDLIBRARY='-L. -lpython$(LDVERSION)' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 4994 | RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}' |
| 4995 | ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 4996 | AIX*) |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 4997 | LDLIBRARY='libpython$(LDVERSION).so' |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 4998 | RUNSHARED=LIBPATH=`pwd`:${LIBPATH} |
| 4999 | ;; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5000 | |
| 5001 | esac |
| 5002 | else # shared is disabled |
| 5003 | case $ac_sys_system in |
| 5004 | CYGWIN*) |
| 5005 | BLDLIBRARY='$(LIBRARY)' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5006 | LDLIBRARY='libpython$(LDVERSION).dll.a' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5007 | ;; |
| 5008 | esac |
| 5009 | fi |
| 5010 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5011 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5 |
| 5012 | $as_echo "$LDLIBRARY" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5013 | |
| 5014 | if test -n "$ac_tool_prefix"; then |
| 5015 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. |
| 5016 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5017 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5018 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5019 | if ${ac_cv_prog_RANLIB+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5020 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5021 | else |
| 5022 | if test -n "$RANLIB"; then |
| 5023 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 5024 | else |
| 5025 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5026 | for as_dir in $PATH |
| 5027 | do |
| 5028 | IFS=$as_save_IFS |
| 5029 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5030 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5031 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5032 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5033 | $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] | 5034 | break 2 |
| 5035 | fi |
| 5036 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5037 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5038 | IFS=$as_save_IFS |
| 5039 | |
| 5040 | fi |
| 5041 | fi |
| 5042 | RANLIB=$ac_cv_prog_RANLIB |
| 5043 | if test -n "$RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5044 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
| 5045 | $as_echo "$RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5046 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5047 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5048 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5049 | fi |
| 5050 | |
| 5051 | |
| 5052 | fi |
| 5053 | if test -z "$ac_cv_prog_RANLIB"; then |
| 5054 | ac_ct_RANLIB=$RANLIB |
| 5055 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 5056 | set dummy ranlib; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5057 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5058 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5059 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5060 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5061 | else |
| 5062 | if test -n "$ac_ct_RANLIB"; then |
| 5063 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. |
| 5064 | else |
| 5065 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5066 | for as_dir in $PATH |
| 5067 | do |
| 5068 | IFS=$as_save_IFS |
| 5069 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5070 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5071 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5072 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5073 | $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] | 5074 | break 2 |
| 5075 | fi |
| 5076 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5077 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5078 | IFS=$as_save_IFS |
| 5079 | |
| 5080 | fi |
| 5081 | fi |
| 5082 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
| 5083 | if test -n "$ac_ct_RANLIB"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5084 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
| 5085 | $as_echo "$ac_ct_RANLIB" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5086 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5087 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5088 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5089 | fi |
| 5090 | |
| 5091 | if test "x$ac_ct_RANLIB" = x; then |
| 5092 | RANLIB=":" |
| 5093 | else |
| 5094 | case $cross_compiling:$ac_tool_warned in |
| 5095 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5096 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 5097 | $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] | 5098 | ac_tool_warned=yes ;; |
| 5099 | esac |
| 5100 | RANLIB=$ac_ct_RANLIB |
| 5101 | fi |
| 5102 | else |
| 5103 | RANLIB="$ac_cv_prog_RANLIB" |
| 5104 | fi |
| 5105 | |
| 5106 | |
| 5107 | for ac_prog in ar aal |
| 5108 | do |
| 5109 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 5110 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5111 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5112 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5113 | if ${ac_cv_prog_AR+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5114 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5115 | else |
| 5116 | if test -n "$AR"; then |
| 5117 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 5118 | else |
| 5119 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5120 | for as_dir in $PATH |
| 5121 | do |
| 5122 | IFS=$as_save_IFS |
| 5123 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5124 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5125 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5126 | ac_cv_prog_AR="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5127 | $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] | 5128 | break 2 |
| 5129 | fi |
| 5130 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5131 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5132 | IFS=$as_save_IFS |
| 5133 | |
| 5134 | fi |
| 5135 | fi |
| 5136 | AR=$ac_cv_prog_AR |
| 5137 | if test -n "$AR"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
| 5139 | $as_echo "$AR" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5140 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5142 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5143 | fi |
| 5144 | |
| 5145 | |
| 5146 | test -n "$AR" && break |
| 5147 | done |
| 5148 | test -n "$AR" || AR="ar" |
| 5149 | |
| 5150 | |
| 5151 | # tweak ARFLAGS only if the user didn't set it on the command line |
| 5152 | |
| 5153 | if test -z "$ARFLAGS" |
| 5154 | then |
| 5155 | ARFLAGS="rc" |
| 5156 | fi |
| 5157 | |
| 5158 | |
| 5159 | # Extract the first word of "svnversion", so it can be a program name with args. |
| 5160 | set dummy svnversion; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5161 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5162 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5163 | if ${ac_cv_prog_SVNVERSION+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5164 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5165 | else |
| 5166 | if test -n "$SVNVERSION"; then |
| 5167 | ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test. |
| 5168 | else |
| 5169 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5170 | for as_dir in $PATH |
| 5171 | do |
| 5172 | IFS=$as_save_IFS |
| 5173 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5174 | for ac_exec_ext in '' $ac_executable_extensions; do |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5175 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5176 | ac_cv_prog_SVNVERSION="found" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5177 | $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] | 5178 | break 2 |
| 5179 | fi |
| 5180 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5181 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5182 | IFS=$as_save_IFS |
| 5183 | |
| 5184 | test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found" |
| 5185 | fi |
| 5186 | fi |
| 5187 | SVNVERSION=$ac_cv_prog_SVNVERSION |
| 5188 | if test -n "$SVNVERSION"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SVNVERSION" >&5 |
| 5190 | $as_echo "$SVNVERSION" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5191 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5192 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5193 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5194 | fi |
| 5195 | |
| 5196 | |
| 5197 | if test $SVNVERSION = found |
| 5198 | then |
| 5199 | SVNVERSION="svnversion \$(srcdir)" |
| 5200 | else |
| 5201 | SVNVERSION="echo Unversioned directory" |
| 5202 | fi |
| 5203 | |
Georg Brandl | 1ca2e79 | 2011-03-05 20:51:24 +0100 | [diff] [blame] | 5204 | |
| 5205 | |
| 5206 | |
| 5207 | # Extract the first word of "hg", so it can be a program name with args. |
| 5208 | set dummy hg; ac_word=$2 |
| 5209 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 5210 | $as_echo_n "checking for $ac_word... " >&6; } |
| 5211 | if ${ac_cv_prog_HAS_HG+:} false; then : |
| 5212 | $as_echo_n "(cached) " >&6 |
| 5213 | else |
| 5214 | if test -n "$HAS_HG"; then |
| 5215 | ac_cv_prog_HAS_HG="$HAS_HG" # Let the user override the test. |
| 5216 | else |
| 5217 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5218 | for as_dir in $PATH |
| 5219 | do |
| 5220 | IFS=$as_save_IFS |
| 5221 | test -z "$as_dir" && as_dir=. |
| 5222 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5223 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 5224 | ac_cv_prog_HAS_HG="found" |
| 5225 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
| 5226 | break 2 |
| 5227 | fi |
| 5228 | done |
| 5229 | done |
| 5230 | IFS=$as_save_IFS |
| 5231 | |
| 5232 | test -z "$ac_cv_prog_HAS_HG" && ac_cv_prog_HAS_HG="not-found" |
| 5233 | fi |
| 5234 | fi |
| 5235 | HAS_HG=$ac_cv_prog_HAS_HG |
| 5236 | if test -n "$HAS_HG"; then |
| 5237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAS_HG" >&5 |
| 5238 | $as_echo "$HAS_HG" >&6; } |
| 5239 | else |
| 5240 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5241 | $as_echo "no" >&6; } |
| 5242 | fi |
| 5243 | |
| 5244 | |
| 5245 | if test $HAS_HG = found |
| 5246 | then |
| 5247 | HGVERSION="hg id -i \$(srcdir)" |
| 5248 | HGTAG="hg id -t \$(srcdir)" |
| 5249 | HGBRANCH="hg id -b \$(srcdir)" |
| 5250 | else |
| 5251 | HGVERSION="" |
| 5252 | HGTAG="" |
| 5253 | HGBRANCH="" |
| 5254 | fi |
| 5255 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5256 | case $MACHDEP in |
| 5257 | bsdos*|hp*|HP*) |
| 5258 | # install -d does not work on BSDI or HP-UX |
| 5259 | if test -z "$INSTALL" |
| 5260 | then |
| 5261 | INSTALL="${srcdir}/install-sh -c" |
| 5262 | fi |
| 5263 | esac |
| 5264 | ac_aux_dir= |
| 5265 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5266 | if test -f "$ac_dir/install-sh"; then |
| 5267 | ac_aux_dir=$ac_dir |
| 5268 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 5269 | break |
| 5270 | elif test -f "$ac_dir/install.sh"; then |
| 5271 | ac_aux_dir=$ac_dir |
| 5272 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 5273 | break |
| 5274 | elif test -f "$ac_dir/shtool"; then |
| 5275 | ac_aux_dir=$ac_dir |
| 5276 | ac_install_sh="$ac_aux_dir/shtool install -c" |
| 5277 | break |
| 5278 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5279 | done |
| 5280 | if test -z "$ac_aux_dir"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5281 | 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] | 5282 | fi |
| 5283 | |
| 5284 | # These three variables are undocumented and unsupported, |
| 5285 | # and are intended to be withdrawn in a future Autoconf release. |
| 5286 | # They can cause serious problems if a builder's source tree is in a directory |
| 5287 | # whose full name contains unusual characters. |
| 5288 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. |
| 5289 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. |
| 5290 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. |
| 5291 | |
| 5292 | |
| 5293 | # Find a good install program. We prefer a C program (faster), |
| 5294 | # so one script is as good as another. But avoid the broken or |
| 5295 | # incompatible versions: |
| 5296 | # SysV /etc/install, /usr/sbin/install |
| 5297 | # SunOS /usr/etc/install |
| 5298 | # IRIX /sbin/install |
| 5299 | # AIX /bin/install |
| 5300 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
| 5301 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 5302 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 5303 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 5304 | # OS/2's system install, which has a completely different semantic |
| 5305 | # ./install, which can be erroneously created by make from ./install.sh. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5306 | # Reject install programs that cannot install multiple files. |
| 5307 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
| 5308 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5309 | if test -z "$INSTALL"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5310 | if ${ac_cv_path_install+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5311 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5312 | else |
| 5313 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 5314 | for as_dir in $PATH |
| 5315 | do |
| 5316 | IFS=$as_save_IFS |
| 5317 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5318 | # Account for people who put trailing slashes in PATH elements. |
| 5319 | case $as_dir/ in #(( |
| 5320 | ./ | .// | /[cC]/* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5321 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5322 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5323 | /usr/ucb/* ) ;; |
| 5324 | *) |
| 5325 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 5326 | # Don't use installbsd from OSF since it installs stuff as root |
| 5327 | # by default. |
| 5328 | for ac_prog in ginstall scoinst install; do |
| 5329 | for ac_exec_ext in '' $ac_executable_extensions; do |
| 5330 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
| 5331 | if test $ac_prog = install && |
| 5332 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5333 | # AIX install. It has an incompatible calling convention. |
| 5334 | : |
| 5335 | elif test $ac_prog = install && |
| 5336 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then |
| 5337 | # program-specific install script used by HP pwplus--don't use. |
| 5338 | : |
| 5339 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5340 | rm -rf conftest.one conftest.two conftest.dir |
| 5341 | echo one > conftest.one |
| 5342 | echo two > conftest.two |
| 5343 | mkdir conftest.dir |
| 5344 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && |
| 5345 | test -s conftest.one && test -s conftest.two && |
| 5346 | test -s conftest.dir/conftest.one && |
| 5347 | test -s conftest.dir/conftest.two |
| 5348 | then |
| 5349 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" |
| 5350 | break 3 |
| 5351 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5352 | fi |
| 5353 | fi |
| 5354 | done |
| 5355 | done |
| 5356 | ;; |
| 5357 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5358 | |
| 5359 | done |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5360 | IFS=$as_save_IFS |
| 5361 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5362 | rm -rf conftest.one conftest.two conftest.dir |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5363 | |
| 5364 | fi |
| 5365 | if test "${ac_cv_path_install+set}" = set; then |
| 5366 | INSTALL=$ac_cv_path_install |
| 5367 | else |
| 5368 | # As a last resort, use the slow shell script. Don't cache a |
| 5369 | # value for INSTALL within a source directory, because that will |
| 5370 | # break other packages using the cache if that directory is |
| 5371 | # removed, or if the value is a relative name. |
| 5372 | INSTALL=$ac_install_sh |
| 5373 | fi |
| 5374 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5375 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
| 5376 | $as_echo "$INSTALL" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5377 | |
| 5378 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 5379 | # It thinks the first close brace ends the variable substitution. |
| 5380 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 5381 | |
| 5382 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
| 5383 | |
| 5384 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 5385 | |
| 5386 | |
| 5387 | # Not every filesystem supports hard links |
| 5388 | |
| 5389 | if test -z "$LN" ; then |
| 5390 | case $ac_sys_system in |
| 5391 | CYGWIN*) LN="ln -s";; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5392 | *) LN=ln;; |
| 5393 | esac |
| 5394 | fi |
| 5395 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5396 | # For calculating the .so ABI tag. |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5397 | |
| 5398 | ABIFLAGS="" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 5399 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5400 | # Check for --with-pydebug |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5401 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pydebug" >&5 |
| 5402 | $as_echo_n "checking for --with-pydebug... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5403 | |
| 5404 | # Check whether --with-pydebug was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5405 | if test "${with_pydebug+set}" = set; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5406 | withval=$with_pydebug; |
| 5407 | if test "$withval" != no |
| 5408 | then |
| 5409 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5410 | $as_echo "#define Py_DEBUG 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5411 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 5413 | $as_echo "yes" >&6; }; |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5414 | Py_DEBUG='true' |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 5415 | ABIFLAGS="${ABIFLAGS}d" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5416 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5417 | $as_echo "no" >&6; }; Py_DEBUG='false' |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5418 | fi |
| 5419 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5420 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 5421 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5422 | fi |
| 5423 | |
| 5424 | |
| 5425 | # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be |
| 5426 | # merged with this chunk of code? |
| 5427 | |
| 5428 | # Optimizer/debugger flags |
| 5429 | # ------------------------ |
| 5430 | # (The following bit of code is complicated enough - please keep things |
| 5431 | # indented properly. Just pretend you're editing Python code. ;-) |
| 5432 | |
| 5433 | # There are two parallel sets of case statements below, one that checks to |
| 5434 | # see if OPT was set and one that does BASECFLAGS setting based upon |
| 5435 | # compiler and platform. BASECFLAGS tweaks need to be made even if the |
| 5436 | # user set OPT. |
| 5437 | |
| 5438 | # tweak OPT based on compiler and platform, only if the user didn't set |
| 5439 | # it on the command line |
| 5440 | |
Benjamin Peterson | 65b4ec5 | 2010-03-23 21:02:34 +0000 | [diff] [blame] | 5441 | if test "${OPT-unset}" = "unset" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5442 | then |
| 5443 | case $GCC in |
| 5444 | yes) |
| 5445 | if test "$CC" != 'g++' ; then |
| 5446 | STRICT_PROTO="-Wstrict-prototypes" |
| 5447 | fi |
| 5448 | # For gcc 4.x we need to use -fwrapv so lets check if its supported |
| 5449 | if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then |
| 5450 | WRAP="-fwrapv" |
| 5451 | fi |
| 5452 | case $ac_cv_prog_cc_g in |
| 5453 | yes) |
| 5454 | if test "$Py_DEBUG" = 'true' ; then |
| 5455 | # Optimization messes up debuggers, so turn it off for |
| 5456 | # debug builds. |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 5457 | OPT="-g -O0 -Wall $STRICT_PROTO" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5458 | else |
| 5459 | OPT="-g $WRAP -O3 -Wall $STRICT_PROTO" |
| 5460 | fi |
| 5461 | ;; |
| 5462 | *) |
| 5463 | OPT="-O3 -Wall $STRICT_PROTO" |
| 5464 | ;; |
| 5465 | esac |
| 5466 | case $ac_sys_system in |
| 5467 | SCO_SV*) OPT="$OPT -m486 -DSCO5" |
| 5468 | ;; |
| 5469 | esac |
| 5470 | ;; |
| 5471 | |
| 5472 | *) |
| 5473 | OPT="-O" |
| 5474 | ;; |
| 5475 | esac |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5476 | fi |
| 5477 | |
| 5478 | |
| 5479 | |
| 5480 | # The -arch flags for universal builds on OSX |
| 5481 | UNIVERSAL_ARCH_FLAGS= |
| 5482 | |
| 5483 | |
| 5484 | # tweak BASECFLAGS based on compiler and platform |
| 5485 | case $GCC in |
| 5486 | yes) |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5487 | # Python doesn't violate C99 aliasing rules, but older versions of |
| 5488 | # GCC produce warnings for legal Python code. Enable |
| 5489 | # -fno-strict-aliasing on versions of GCC that support but produce |
| 5490 | # warnings. See Issue3326 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5491 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts and needs -fno-strict-aliasing" >&5 |
| 5492 | $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] | 5493 | ac_save_cc="$CC" |
| 5494 | CC="$CC -fno-strict-aliasing" |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5495 | save_CFLAGS="$CFLAGS" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5496 | if ${ac_cv_no_strict_aliasing+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5497 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5498 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5499 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5500 | /* end confdefs.h. */ |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5501 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5502 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5503 | int |
| 5504 | main () |
| 5505 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5506 | |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5507 | ; |
| 5508 | return 0; |
| 5509 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5510 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5511 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5512 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5513 | |
| 5514 | CC="$ac_save_cc -fstrict-aliasing" |
| 5515 | CFLAGS="$CFLAGS -Werror -Wstrict-aliasing" |
| 5516 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5517 | /* end confdefs.h. */ |
| 5518 | |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5519 | void f(int **x) {} |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5520 | int |
| 5521 | main () |
| 5522 | { |
Mark Dickinson | 8c2b6f1 | 2010-05-11 09:23:07 +0000 | [diff] [blame] | 5523 | double *x; f((int **) &x); |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5524 | ; |
| 5525 | return 0; |
| 5526 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5527 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5528 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5529 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5530 | |
| 5531 | ac_cv_no_strict_aliasing=no |
| 5532 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5533 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5534 | |
| 5535 | ac_cv_no_strict_aliasing=yes |
| 5536 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5537 | fi |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5538 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5539 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5540 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5541 | |
| 5542 | ac_cv_no_strict_aliasing=no |
| 5543 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5544 | fi |
Gregory P. Smith | e0450c6 | 2009-11-01 21:11:36 +0000 | [diff] [blame] | 5545 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 5546 | fi |
| 5547 | |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5548 | CFLAGS="$save_CFLAGS" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5549 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_no_strict_aliasing" >&5 |
| 5551 | $as_echo "$ac_cv_no_strict_aliasing" >&6; } |
Benjamin Peterson | e6c9d24 | 2010-03-30 17:34:47 +0000 | [diff] [blame] | 5552 | if test $ac_cv_no_strict_aliasing = yes |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5553 | then |
| 5554 | BASECFLAGS="$BASECFLAGS -fno-strict-aliasing" |
| 5555 | fi |
| 5556 | |
| 5557 | # if using gcc on alpha, use -mieee to get (near) full IEEE 754 |
| 5558 | # support. Without this, treatment of subnormals doesn't follow |
| 5559 | # the standard. |
| 5560 | case $ac_sys_machine in |
| 5561 | alpha*) |
| 5562 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5563 | ;; |
| 5564 | esac |
| 5565 | |
| 5566 | case $ac_sys_system in |
| 5567 | SCO_SV*) |
| 5568 | BASECFLAGS="$BASECFLAGS -m486 -DSCO5" |
| 5569 | ;; |
| 5570 | # is there any other compiler on Darwin besides gcc? |
| 5571 | Darwin*) |
| 5572 | # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd |
| 5573 | # used to be here, but non-Apple gcc doesn't accept them. |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5574 | if test "${CC}" = gcc |
| 5575 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5576 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which compiler should be used" >&5 |
| 5577 | $as_echo_n "checking which compiler should be used... " >&6; } |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5578 | case "${UNIVERSALSDK}" in |
| 5579 | */MacOSX10.4u.sdk) |
| 5580 | # Build using 10.4 SDK, force usage of gcc when the |
| 5581 | # compiler is gcc, otherwise the user will get very |
| 5582 | # confusing error messages when building on OSX 10.6 |
| 5583 | CC=gcc-4.0 |
| 5584 | CPP=cpp-4.0 |
| 5585 | ;; |
| 5586 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5587 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
| 5588 | $as_echo "$CC" >&6; } |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5589 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5590 | |
| 5591 | |
| 5592 | if test "${enable_universalsdk}"; then |
| 5593 | UNIVERSAL_ARCH_FLAGS="" |
| 5594 | if test "$UNIVERSAL_ARCHS" = "32-bit" ; then |
| 5595 | UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386" |
| 5596 | ARCH_RUN_32BIT="" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 5597 | LIPO_32BIT_FLAGS="" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5598 | elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then |
| 5599 | UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5600 | LIPO_32BIT_FLAGS="" |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5601 | ARCH_RUN_32BIT="true" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5602 | |
| 5603 | elif test "$UNIVERSAL_ARCHS" = "all" ; then |
| 5604 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5605 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5606 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5607 | |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5608 | elif test "$UNIVERSAL_ARCHS" = "intel" ; then |
| 5609 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5610 | LIPO_32BIT_FLAGS="-extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5611 | ARCH_RUN_32BIT="/usr/bin/arch -i386" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5612 | |
| 5613 | elif test "$UNIVERSAL_ARCHS" = "3-way" ; then |
| 5614 | UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch x86_64" |
Ronald Oussoren | 6f6c562 | 2009-12-24 14:03:19 +0000 | [diff] [blame] | 5615 | LIPO_32BIT_FLAGS="-extract ppc7400 -extract i386" |
Ronald Oussoren | 564f7f2 | 2010-02-11 13:23:08 +0000 | [diff] [blame] | 5616 | ARCH_RUN_32BIT="/usr/bin/arch -i386 -ppc" |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5617 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5618 | else |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5619 | 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] | 5620 | |
| 5621 | fi |
| 5622 | |
| 5623 | |
Ronald Oussoren | 666028b | 2010-04-18 19:07:43 +0000 | [diff] [blame] | 5624 | CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5625 | if test "${UNIVERSALSDK}" != "/" |
| 5626 | then |
| 5627 | CFLAGS="-isysroot ${UNIVERSALSDK} ${CFLAGS}" |
| 5628 | LDFLAGS="-isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Ronald Oussoren | 712979d | 2010-04-20 19:51:33 +0000 | [diff] [blame] | 5629 | CPPFLAGS="-isysroot ${UNIVERSALSDK} ${CPPFLAGS}" |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5630 | fi |
| 5631 | fi |
| 5632 | |
| 5633 | # Calculate the right deployment target for this build. |
| 5634 | # |
| 5635 | cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'` |
| 5636 | if test ${cur_target} '>' 10.2; then |
| 5637 | cur_target=10.3 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5638 | if test ${enable_universalsdk}; then |
| 5639 | if test "${UNIVERSAL_ARCHS}" = "all"; then |
| 5640 | # Ensure that the default platform for a |
| 5641 | # 4-way universal build is OSX 10.5, |
| 5642 | # that's the first OS release where |
| 5643 | # 4-way builds make sense. |
| 5644 | cur_target='10.5' |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 5645 | |
| 5646 | elif test "${UNIVERSAL_ARCHS}" = "3-way"; then |
| 5647 | cur_target='10.5' |
| 5648 | |
| 5649 | elif test "${UNIVERSAL_ARCHS}" = "intel"; then |
| 5650 | cur_target='10.5' |
| 5651 | |
| 5652 | elif test "${UNIVERSAL_ARCHS}" = "64-bit"; then |
| 5653 | cur_target='10.5' |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5654 | fi |
| 5655 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 5656 | if test `/usr/bin/arch` = "i386"; then |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 5657 | # On Intel macs default to a deployment |
| 5658 | # target of 10.4, that's the first OSX |
| 5659 | # release with Intel support. |
| 5660 | cur_target="10.4" |
| 5661 | fi |
| 5662 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5663 | fi |
| 5664 | CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}} |
| 5665 | |
| 5666 | # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the |
| 5667 | # environment with a value that is the same as what we'll use |
| 5668 | # in the Makefile to ensure that we'll get the same compiler |
| 5669 | # environment during configure and build time. |
| 5670 | MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET" |
| 5671 | export MACOSX_DEPLOYMENT_TARGET |
| 5672 | EXPORT_MACOSX_DEPLOYMENT_TARGET='' |
| 5673 | |
| 5674 | ;; |
| 5675 | OSF*) |
| 5676 | BASECFLAGS="$BASECFLAGS -mieee" |
| 5677 | ;; |
| 5678 | esac |
| 5679 | ;; |
| 5680 | |
| 5681 | *) |
| 5682 | case $ac_sys_system in |
| 5683 | OpenUNIX*|UnixWare*) |
| 5684 | BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca " |
| 5685 | ;; |
| 5686 | OSF*) |
| 5687 | BASECFLAGS="$BASECFLAGS -ieee -std" |
| 5688 | ;; |
| 5689 | SCO_SV*) |
| 5690 | BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5" |
| 5691 | ;; |
| 5692 | esac |
| 5693 | ;; |
| 5694 | esac |
| 5695 | |
| 5696 | if test "$Py_DEBUG" = 'true'; then |
| 5697 | : |
| 5698 | else |
| 5699 | OPT="-DNDEBUG $OPT" |
| 5700 | fi |
| 5701 | |
| 5702 | if test "$ac_arch_flags" |
| 5703 | then |
| 5704 | BASECFLAGS="$BASECFLAGS $ac_arch_flags" |
| 5705 | fi |
| 5706 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5707 | # Check whether GCC supports PyArg_ParseTuple format |
| 5708 | if test "$GCC" = "yes" |
| 5709 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5710 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc supports ParseTuple __format__" >&5 |
| 5711 | $as_echo_n "checking whether gcc supports ParseTuple __format__... " >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5712 | save_CFLAGS=$CFLAGS |
| 5713 | CFLAGS="$CFLAGS -Werror" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5714 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5715 | /* end confdefs.h. */ |
| 5716 | |
| 5717 | void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2))); |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5718 | int |
| 5719 | main () |
| 5720 | { |
| 5721 | |
| 5722 | ; |
| 5723 | return 0; |
| 5724 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5725 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5726 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5727 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5728 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5729 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5730 | $as_echo "#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5731 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5732 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5733 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5734 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5735 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 5736 | |
| 5737 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5738 | $as_echo "no" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5739 | |
| 5740 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5741 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 5742 | CFLAGS=$save_CFLAGS |
| 5743 | fi |
| 5744 | |
| 5745 | # On some compilers, pthreads are available without further options |
| 5746 | # (e.g. MacOS X). On some of these systems, the compiler will not |
| 5747 | # complain if unaccepted options are passed (e.g. gcc on Mac OS X). |
| 5748 | # So we have to see first whether pthreads are available without |
| 5749 | # options before we can check whether -Kpthread improves anything. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads are available without options" >&5 |
| 5751 | $as_echo_n "checking whether pthreads are available without options... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5752 | if ${ac_cv_pthread_is_default+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5753 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5754 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5755 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5756 | ac_cv_pthread_is_default=no |
| 5757 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5758 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5759 | /* end confdefs.h. */ |
| 5760 | |
| 5761 | #include <pthread.h> |
| 5762 | |
| 5763 | void* routine(void* p){return NULL;} |
| 5764 | |
| 5765 | int main(){ |
| 5766 | pthread_t p; |
| 5767 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5768 | return 1; |
| 5769 | (void)pthread_detach(p); |
| 5770 | return 0; |
| 5771 | } |
| 5772 | |
| 5773 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5774 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5775 | |
| 5776 | ac_cv_pthread_is_default=yes |
| 5777 | ac_cv_kthread=no |
| 5778 | ac_cv_pthread=no |
| 5779 | |
| 5780 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5781 | ac_cv_pthread_is_default=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5782 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5783 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5784 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5785 | fi |
| 5786 | |
| 5787 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5788 | fi |
| 5789 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5790 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_is_default" >&5 |
| 5791 | $as_echo "$ac_cv_pthread_is_default" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5792 | |
| 5793 | |
| 5794 | if test $ac_cv_pthread_is_default = yes |
| 5795 | then |
| 5796 | ac_cv_kpthread=no |
| 5797 | else |
| 5798 | # -Kpthread, if available, provides the right #defines |
| 5799 | # and linker options to make pthread_create available |
| 5800 | # Some compilers won't report that they do not support -Kpthread, |
| 5801 | # so we need to run a program to see whether it really made the |
| 5802 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5803 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kpthread" >&5 |
| 5804 | $as_echo_n "checking whether $CC accepts -Kpthread... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5805 | if ${ac_cv_kpthread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5806 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5807 | else |
| 5808 | ac_save_cc="$CC" |
| 5809 | CC="$CC -Kpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5810 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5811 | ac_cv_kpthread=no |
| 5812 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5813 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5814 | /* end confdefs.h. */ |
| 5815 | |
| 5816 | #include <pthread.h> |
| 5817 | |
| 5818 | void* routine(void* p){return NULL;} |
| 5819 | |
| 5820 | int main(){ |
| 5821 | pthread_t p; |
| 5822 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5823 | return 1; |
| 5824 | (void)pthread_detach(p); |
| 5825 | return 0; |
| 5826 | } |
| 5827 | |
| 5828 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5829 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5830 | ac_cv_kpthread=yes |
| 5831 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5832 | ac_cv_kpthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5833 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5834 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5835 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5836 | fi |
| 5837 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5838 | CC="$ac_save_cc" |
| 5839 | fi |
| 5840 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kpthread" >&5 |
| 5842 | $as_echo "$ac_cv_kpthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5843 | fi |
| 5844 | |
| 5845 | if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no |
| 5846 | then |
| 5847 | # -Kthread, if available, provides the right #defines |
| 5848 | # and linker options to make pthread_create available |
| 5849 | # Some compilers won't report that they do not support -Kthread, |
| 5850 | # so we need to run a program to see whether it really made the |
| 5851 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5852 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Kthread" >&5 |
| 5853 | $as_echo_n "checking whether $CC accepts -Kthread... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5854 | if ${ac_cv_kthread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5855 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5856 | else |
| 5857 | ac_save_cc="$CC" |
| 5858 | CC="$CC -Kthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5859 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5860 | ac_cv_kthread=no |
| 5861 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5862 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5863 | /* end confdefs.h. */ |
| 5864 | |
| 5865 | #include <pthread.h> |
| 5866 | |
| 5867 | void* routine(void* p){return NULL;} |
| 5868 | |
| 5869 | int main(){ |
| 5870 | pthread_t p; |
| 5871 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5872 | return 1; |
| 5873 | (void)pthread_detach(p); |
| 5874 | return 0; |
| 5875 | } |
| 5876 | |
| 5877 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5878 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5879 | ac_cv_kthread=yes |
| 5880 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5881 | ac_cv_kthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5882 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5883 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5884 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5885 | fi |
| 5886 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5887 | CC="$ac_save_cc" |
| 5888 | fi |
| 5889 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5890 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_kthread" >&5 |
| 5891 | $as_echo "$ac_cv_kthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5892 | fi |
| 5893 | |
| 5894 | if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no |
| 5895 | then |
| 5896 | # -pthread, if available, provides the right #defines |
| 5897 | # and linker options to make pthread_create available |
| 5898 | # Some compilers won't report that they do not support -pthread, |
| 5899 | # so we need to run a program to see whether it really made the |
| 5900 | # function available. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5901 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -pthread" >&5 |
| 5902 | $as_echo_n "checking whether $CC accepts -pthread... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5903 | if ${ac_cv_thread+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5904 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5905 | else |
| 5906 | ac_save_cc="$CC" |
| 5907 | CC="$CC -pthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5908 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5909 | ac_cv_pthread=no |
| 5910 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5911 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5912 | /* end confdefs.h. */ |
| 5913 | |
| 5914 | #include <pthread.h> |
| 5915 | |
| 5916 | void* routine(void* p){return NULL;} |
| 5917 | |
| 5918 | int main(){ |
| 5919 | pthread_t p; |
| 5920 | if(pthread_create(&p,NULL,routine,NULL)!=0) |
| 5921 | return 1; |
| 5922 | (void)pthread_detach(p); |
| 5923 | return 0; |
| 5924 | } |
| 5925 | |
| 5926 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5927 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5928 | ac_cv_pthread=yes |
| 5929 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5930 | ac_cv_pthread=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5931 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5932 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 5933 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5934 | fi |
| 5935 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5936 | CC="$ac_save_cc" |
| 5937 | fi |
| 5938 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5939 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread" >&5 |
| 5940 | $as_echo "$ac_cv_pthread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5941 | fi |
| 5942 | |
| 5943 | # If we have set a CC compiler flag for thread support then |
| 5944 | # check if it works for CXX, too. |
| 5945 | ac_cv_cxx_thread=no |
| 5946 | if test ! -z "$CXX" |
| 5947 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5948 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX also accepts flags for thread support" >&5 |
| 5949 | $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] | 5950 | ac_save_cxx="$CXX" |
| 5951 | |
| 5952 | if test "$ac_cv_kpthread" = "yes" |
| 5953 | then |
| 5954 | CXX="$CXX -Kpthread" |
| 5955 | ac_cv_cxx_thread=yes |
| 5956 | elif test "$ac_cv_kthread" = "yes" |
| 5957 | then |
| 5958 | CXX="$CXX -Kthread" |
| 5959 | ac_cv_cxx_thread=yes |
| 5960 | elif test "$ac_cv_pthread" = "yes" |
| 5961 | then |
| 5962 | CXX="$CXX -pthread" |
| 5963 | ac_cv_cxx_thread=yes |
| 5964 | fi |
| 5965 | |
| 5966 | if test $ac_cv_cxx_thread = yes |
| 5967 | then |
| 5968 | echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext |
| 5969 | $CXX -c conftest.$ac_ext 2>&5 |
| 5970 | if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \ |
| 5971 | && test -s conftest$ac_exeext && ./conftest$ac_exeext |
| 5972 | then |
| 5973 | ac_cv_cxx_thread=yes |
| 5974 | else |
| 5975 | ac_cv_cxx_thread=no |
| 5976 | fi |
| 5977 | rm -fr conftest* |
| 5978 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_thread" >&5 |
| 5980 | $as_echo "$ac_cv_cxx_thread" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5981 | fi |
| 5982 | CXX="$ac_save_cxx" |
| 5983 | |
| 5984 | |
| 5985 | # checks for header files |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5986 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
| 5987 | $as_echo_n "checking for ANSI C header files... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 5988 | if ${ac_cv_header_stdc+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5989 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5990 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 5991 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 5992 | /* end confdefs.h. */ |
| 5993 | #include <stdlib.h> |
| 5994 | #include <stdarg.h> |
| 5995 | #include <string.h> |
| 5996 | #include <float.h> |
| 5997 | |
| 5998 | int |
| 5999 | main () |
| 6000 | { |
| 6001 | |
| 6002 | ; |
| 6003 | return 0; |
| 6004 | } |
| 6005 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6006 | if ac_fn_c_try_compile "$LINENO"; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6007 | ac_cv_header_stdc=yes |
| 6008 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6009 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6010 | fi |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6011 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 6012 | |
| 6013 | if test $ac_cv_header_stdc = yes; then |
| 6014 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6015 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6016 | /* end confdefs.h. */ |
| 6017 | #include <string.h> |
| 6018 | |
| 6019 | _ACEOF |
| 6020 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6021 | $EGREP "memchr" >/dev/null 2>&1; then : |
| 6022 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6023 | else |
| 6024 | ac_cv_header_stdc=no |
| 6025 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6026 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6027 | |
| 6028 | fi |
| 6029 | |
| 6030 | if test $ac_cv_header_stdc = yes; then |
| 6031 | # 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] | 6032 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6033 | /* end confdefs.h. */ |
| 6034 | #include <stdlib.h> |
| 6035 | |
| 6036 | _ACEOF |
| 6037 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6038 | $EGREP "free" >/dev/null 2>&1; then : |
| 6039 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6040 | else |
| 6041 | ac_cv_header_stdc=no |
| 6042 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6043 | rm -f conftest* |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6044 | |
| 6045 | fi |
| 6046 | |
| 6047 | if test $ac_cv_header_stdc = yes; then |
| 6048 | # /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] | 6049 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6050 | : |
| 6051 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6052 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6053 | /* end confdefs.h. */ |
| 6054 | #include <ctype.h> |
| 6055 | #include <stdlib.h> |
| 6056 | #if ((' ' & 0x0FF) == 0x020) |
| 6057 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 6058 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
| 6059 | #else |
| 6060 | # define ISLOWER(c) \ |
| 6061 | (('a' <= (c) && (c) <= 'i') \ |
| 6062 | || ('j' <= (c) && (c) <= 'r') \ |
| 6063 | || ('s' <= (c) && (c) <= 'z')) |
| 6064 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
| 6065 | #endif |
| 6066 | |
| 6067 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
| 6068 | int |
| 6069 | main () |
| 6070 | { |
| 6071 | int i; |
| 6072 | for (i = 0; i < 256; i++) |
| 6073 | if (XOR (islower (i), ISLOWER (i)) |
| 6074 | || toupper (i) != TOUPPER (i)) |
| 6075 | return 2; |
| 6076 | return 0; |
| 6077 | } |
| 6078 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6079 | if ac_fn_c_try_run "$LINENO"; then : |
| 6080 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6081 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6082 | ac_cv_header_stdc=no |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6083 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6084 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 6085 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6086 | fi |
| 6087 | |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6088 | fi |
| 6089 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6090 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
| 6091 | $as_echo "$ac_cv_header_stdc" >&6; } |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6092 | if test $ac_cv_header_stdc = yes; then |
| 6093 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6094 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 6095 | |
| 6096 | fi |
| 6097 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6098 | for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \ |
| 6099 | fcntl.h grp.h \ |
Christian Heimes | bbe741d | 2008-03-28 10:53:29 +0000 | [diff] [blame] | 6100 | 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] | 6101 | 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] | 6102 | unistd.h utime.h \ |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 6103 | sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \ |
| 6104 | sys/lock.h sys/mkdev.h sys/modem.h \ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6105 | sys/param.h sys/poll.h sys/select.h sys/socket.h sys/statvfs.h sys/stat.h \ |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 6106 | sys/termio.h sys/time.h \ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 6107 | sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
Hye-Shik Chang | 8126860 | 2004-02-02 06:05:24 +0000 | [diff] [blame] | 6108 | sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \ |
Ronald Oussoren | 755740f | 2010-02-07 19:56:39 +0000 | [diff] [blame] | 6109 | bluetooth/bluetooth.h linux/tipc.h spawn.h util.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6110 | do : |
| 6111 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` |
| 6112 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6113 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6114 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6115 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6116 | _ACEOF |
| 6117 | |
| 6118 | fi |
| 6119 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6120 | done |
| 6121 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6122 | ac_header_dirent=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6123 | 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] | 6124 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` |
| 6125 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 |
| 6126 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6127 | if eval \${$as_ac_Header+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6128 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6129 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6130 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6131 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6132 | #include <sys/types.h> |
| 6133 | #include <$ac_hdr> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6134 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6135 | int |
| 6136 | main () |
| 6137 | { |
| 6138 | if ((DIR *) 0) |
| 6139 | return 0; |
| 6140 | ; |
| 6141 | return 0; |
| 6142 | } |
| 6143 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6144 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6145 | eval "$as_ac_Header=yes" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6146 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6147 | eval "$as_ac_Header=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6148 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6149 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6150 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6151 | eval ac_res=\$$as_ac_Header |
| 6152 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 |
| 6153 | $as_echo "$ac_res" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6154 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6155 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6156 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6157 | _ACEOF |
| 6158 | |
| 6159 | ac_header_dirent=$ac_hdr; break |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6160 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6161 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6162 | done |
| 6163 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 6164 | if test $ac_header_dirent = dirent.h; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6165 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6166 | $as_echo_n "checking for library containing opendir... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6167 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6168 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6169 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6170 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6171 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6172 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6173 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6174 | /* Override any GCC internal prototype to avoid an error. |
| 6175 | Use char because int might match the return type of a GCC |
| 6176 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6177 | #ifdef __cplusplus |
| 6178 | extern "C" |
| 6179 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6180 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6181 | int |
| 6182 | main () |
| 6183 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6184 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6185 | ; |
| 6186 | return 0; |
| 6187 | } |
| 6188 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6189 | for ac_lib in '' dir; do |
| 6190 | if test -z "$ac_lib"; then |
| 6191 | ac_res="none required" |
| 6192 | else |
| 6193 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6194 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6195 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6196 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6197 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6198 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6199 | rm -f core conftest.err conftest.$ac_objext \ |
| 6200 | conftest$ac_exeext |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6201 | if ${ac_cv_search_opendir+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6202 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6203 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6204 | done |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6205 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6206 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6207 | else |
| 6208 | ac_cv_search_opendir=no |
| 6209 | fi |
| 6210 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6211 | LIBS=$ac_func_search_save_LIBS |
| 6212 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6213 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6214 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6215 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6216 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6217 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6218 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6219 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6220 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6221 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6222 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 |
| 6223 | $as_echo_n "checking for library containing opendir... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6224 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6225 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6226 | else |
| 6227 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6228 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6229 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6230 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6231 | /* Override any GCC internal prototype to avoid an error. |
| 6232 | Use char because int might match the return type of a GCC |
| 6233 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6234 | #ifdef __cplusplus |
| 6235 | extern "C" |
| 6236 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6237 | char opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6238 | int |
| 6239 | main () |
| 6240 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6241 | return opendir (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6242 | ; |
| 6243 | return 0; |
| 6244 | } |
| 6245 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6246 | for ac_lib in '' x; do |
| 6247 | if test -z "$ac_lib"; then |
| 6248 | ac_res="none required" |
| 6249 | else |
| 6250 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6251 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6252 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6253 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6254 | ac_cv_search_opendir=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 6255 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6256 | rm -f core conftest.err conftest.$ac_objext \ |
| 6257 | conftest$ac_exeext |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6258 | if ${ac_cv_search_opendir+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6259 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 6260 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6261 | done |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6262 | if ${ac_cv_search_opendir+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6263 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6264 | else |
| 6265 | ac_cv_search_opendir=no |
| 6266 | fi |
| 6267 | rm conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6268 | LIBS=$ac_func_search_save_LIBS |
| 6269 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6270 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
| 6271 | $as_echo "$ac_cv_search_opendir" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6272 | ac_res=$ac_cv_search_opendir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6273 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6274 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6275 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6276 | fi |
| 6277 | |
| 6278 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6279 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/types.h defines makedev" >&5 |
| 6281 | $as_echo_n "checking whether sys/types.h defines makedev... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6282 | if ${ac_cv_header_sys_types_h_makedev+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6283 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6284 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6285 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6286 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6287 | #include <sys/types.h> |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6288 | int |
| 6289 | main () |
| 6290 | { |
| 6291 | return makedev(0, 0); |
| 6292 | ; |
| 6293 | return 0; |
| 6294 | } |
| 6295 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6296 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6297 | ac_cv_header_sys_types_h_makedev=yes |
| 6298 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6299 | ac_cv_header_sys_types_h_makedev=no |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6300 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6301 | rm -f core conftest.err conftest.$ac_objext \ |
| 6302 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6303 | |
| 6304 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6305 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_types_h_makedev" >&5 |
| 6306 | $as_echo "$ac_cv_header_sys_types_h_makedev" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6307 | |
| 6308 | if test $ac_cv_header_sys_types_h_makedev = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6309 | ac_fn_c_check_header_mongrel "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6310 | if test "x$ac_cv_header_sys_mkdev_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6311 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6312 | $as_echo "#define MAJOR_IN_MKDEV 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6313 | |
| 6314 | fi |
| 6315 | |
| 6316 | |
| 6317 | |
| 6318 | if test $ac_cv_header_sys_mkdev_h = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6319 | ac_fn_c_check_header_mongrel "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6320 | if test "x$ac_cv_header_sys_sysmacros_h" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6321 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6322 | $as_echo "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 6323 | |
| 6324 | fi |
| 6325 | |
| 6326 | |
| 6327 | fi |
| 6328 | fi |
| 6329 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6330 | |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6331 | # On Solaris, term.h requires curses.h |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6332 | for ac_header in term.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6333 | do : |
| 6334 | 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] | 6335 | #ifdef HAVE_CURSES_H |
| 6336 | #include <curses.h> |
| 6337 | #endif |
| 6338 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6339 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6340 | if test "x$ac_cv_header_term_h" = xyes; then : |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6341 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6342 | #define HAVE_TERM_H 1 |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6343 | _ACEOF |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6344 | |
Martin v. Löwis | fd1c69e7 | 2004-11-30 22:09:37 +0000 | [diff] [blame] | 6345 | fi |
| 6346 | |
| 6347 | done |
Martin v. Löwis | ae2830c | 2004-09-18 09:54:52 +0000 | [diff] [blame] | 6348 | |
| 6349 | |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6350 | # On Linux, netlink.h requires asm/types.h |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6351 | for ac_header in linux/netlink.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6352 | do : |
| 6353 | 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] | 6354 | #ifdef HAVE_ASM_TYPES_H |
| 6355 | #include <asm/types.h> |
| 6356 | #endif |
| 6357 | #ifdef HAVE_SYS_SOCKET_H |
| 6358 | #include <sys/socket.h> |
| 6359 | #endif |
| 6360 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6361 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6362 | if test "x$ac_cv_header_linux_netlink_h" = xyes; then : |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6363 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6364 | #define HAVE_LINUX_NETLINK_H 1 |
Martin v. Löwis | 11017b1 | 2006-01-14 18:12:57 +0000 | [diff] [blame] | 6365 | _ACEOF |
| 6366 | |
| 6367 | fi |
| 6368 | |
| 6369 | done |
| 6370 | |
| 6371 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6372 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6373 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6374 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t in time.h" >&5 |
| 6375 | $as_echo_n "checking for clock_t in time.h... " >&6; } |
| 6376 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6377 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6378 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6379 | |
| 6380 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6381 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6382 | $EGREP "clock_t" >/dev/null 2>&1; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6383 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6384 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6385 | |
| 6386 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6387 | $as_echo "#define clock_t long" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6388 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6389 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6390 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6391 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6392 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6393 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 6394 | $as_echo "$was_it_defined" >&6; } |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 6395 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6396 | # Check whether using makedev requires defining _OSF_SOURCE |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6397 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for makedev" >&5 |
| 6398 | $as_echo_n "checking for makedev... " >&6; } |
| 6399 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6400 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6401 | |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6402 | #if defined(MAJOR_IN_MKDEV) |
| 6403 | #include <sys/mkdev.h> |
| 6404 | #elif defined(MAJOR_IN_SYSMACROS) |
| 6405 | #include <sys/sysmacros.h> |
| 6406 | #else |
| 6407 | #include <sys/types.h> |
| 6408 | #endif |
| 6409 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6410 | int |
| 6411 | main () |
| 6412 | { |
Jesus Cea | 740f53a | 2010-04-28 11:35:30 +0000 | [diff] [blame] | 6413 | |
| 6414 | makedev(0, 0) |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6415 | ; |
| 6416 | return 0; |
| 6417 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 6418 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6419 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6420 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6421 | ac_cv_has_makedev=yes |
| 6422 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6423 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6424 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6425 | rm -f core conftest.err conftest.$ac_objext \ |
| 6426 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6427 | if test "$ac_cv_has_makedev" = "no"; then |
| 6428 | # we didn't link, try if _OSF_SOURCE will allow us to link |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6429 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6430 | /* end confdefs.h. */ |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6431 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 6432 | #define _OSF_SOURCE 1 |
| 6433 | #include <sys/types.h> |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6434 | |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6435 | int |
| 6436 | main () |
| 6437 | { |
| 6438 | makedev(0, 0) |
| 6439 | ; |
| 6440 | return 0; |
| 6441 | } |
| 6442 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6443 | if ac_fn_c_try_link "$LINENO"; then : |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6444 | ac_cv_has_makedev=yes |
| 6445 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6446 | ac_cv_has_makedev=no |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6447 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6448 | rm -f core conftest.err conftest.$ac_objext \ |
| 6449 | conftest$ac_exeext conftest.$ac_ext |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6450 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6451 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6452 | $as_echo "#define _OSF_SOURCE 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6453 | |
| 6454 | fi |
| 6455 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6456 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_makedev" >&5 |
| 6457 | $as_echo "$ac_cv_has_makedev" >&6; } |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6458 | if test "$ac_cv_has_makedev" = "yes"; then |
| 6459 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6460 | $as_echo "#define HAVE_MAKEDEV 1" >>confdefs.h |
Neal Norwitz | 1169011 | 2002-07-30 01:08:28 +0000 | [diff] [blame] | 6461 | |
| 6462 | fi |
| 6463 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6464 | # Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in |
| 6465 | # the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are |
| 6466 | # defined, but the compiler does not support pragma redefine_extname, |
| 6467 | # and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit |
| 6468 | # structures (such as rlimit64) without declaring them. As a |
| 6469 | # work-around, disable LFS on such configurations |
| 6470 | |
| 6471 | use_lfs=yes |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6472 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking Solaris LFS bug" >&5 |
| 6473 | $as_echo_n "checking Solaris LFS bug... " >&6; } |
| 6474 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6475 | /* end confdefs.h. */ |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6476 | |
| 6477 | #define _LARGEFILE_SOURCE 1 |
| 6478 | #define _FILE_OFFSET_BITS 64 |
| 6479 | #include <sys/resource.h> |
| 6480 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6481 | int |
| 6482 | main () |
| 6483 | { |
| 6484 | struct rlimit foo; |
| 6485 | ; |
| 6486 | return 0; |
| 6487 | } |
| 6488 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6489 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6490 | sol_lfs_bug=no |
| 6491 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6492 | sol_lfs_bug=yes |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6493 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6494 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6495 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sol_lfs_bug" >&5 |
| 6496 | $as_echo "$sol_lfs_bug" >&6; } |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6497 | if test "$sol_lfs_bug" = "yes"; then |
| 6498 | use_lfs=no |
| 6499 | fi |
| 6500 | |
| 6501 | if test "$use_lfs" = "yes"; then |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6502 | # Two defines needed to enable largefile support on various platforms |
| 6503 | # These may affect some typedefs |
Georg Brandl | 216e404 | 2011-02-19 08:58:23 +0000 | [diff] [blame] | 6504 | case $ac_sys_system/$ac_sys_release in |
| 6505 | AIX*) |
| 6506 | |
| 6507 | $as_echo "#define _LARGE_FILES 1" >>confdefs.h |
| 6508 | |
| 6509 | ;; |
| 6510 | esac |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6511 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6512 | $as_echo "#define _LARGEFILE_SOURCE 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6513 | |
| 6514 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6515 | $as_echo "#define _FILE_OFFSET_BITS 64" >>confdefs.h |
Guido van Rossum | 810cc51 | 2001-09-09 23:51:39 +0000 | [diff] [blame] | 6516 | |
Martin v. Löwis | 399a689 | 2002-10-04 10:22:02 +0000 | [diff] [blame] | 6517 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6518 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 6519 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 6520 | cat >> confdefs.h <<\EOF |
| 6521 | #if defined(SCO_DS) |
| 6522 | #undef _OFF_T |
| 6523 | #endif |
| 6524 | EOF |
| 6525 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6526 | # Type availability checks |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6527 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6528 | if test "x$ac_cv_type_mode_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6529 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6530 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6531 | |
| 6532 | cat >>confdefs.h <<_ACEOF |
| 6533 | #define mode_t int |
| 6534 | _ACEOF |
| 6535 | |
| 6536 | fi |
| 6537 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6538 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6539 | if test "x$ac_cv_type_off_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6540 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6541 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6542 | |
| 6543 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6544 | #define off_t long int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6545 | _ACEOF |
| 6546 | |
| 6547 | fi |
| 6548 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6549 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6550 | if test "x$ac_cv_type_pid_t" = xyes; 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 |
| 6555 | #define pid_t int |
| 6556 | _ACEOF |
| 6557 | |
| 6558 | fi |
| 6559 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6560 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6561 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | bada4c3 | 2010-04-25 21:18:48 +0000 | [diff] [blame] | 6562 | #define RETSIGTYPE void |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6563 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6564 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6565 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6566 | if test "x$ac_cv_type_size_t" = xyes; then : |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6567 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6568 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6569 | |
| 6570 | cat >>confdefs.h <<_ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6571 | #define size_t unsigned int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6572 | _ACEOF |
| 6573 | |
| 6574 | fi |
| 6575 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6576 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
| 6577 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6578 | if ${ac_cv_type_uid_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6579 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6580 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6581 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6582 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6583 | #include <sys/types.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6584 | |
| 6585 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6586 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6587 | $EGREP "uid_t" >/dev/null 2>&1; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6588 | ac_cv_type_uid_t=yes |
| 6589 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6590 | ac_cv_type_uid_t=no |
| 6591 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 6592 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6593 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6594 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6595 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
| 6596 | $as_echo "$ac_cv_type_uid_t" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6597 | if test $ac_cv_type_uid_t = no; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6598 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6599 | $as_echo "#define uid_t int" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6600 | |
| 6601 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6602 | $as_echo "#define gid_t int" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6603 | |
| 6604 | fi |
| 6605 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6606 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" |
| 6607 | case $ac_cv_c_uint32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6608 | no|yes) ;; #( |
| 6609 | *) |
| 6610 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6611 | $as_echo "#define _UINT32_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6612 | |
| 6613 | |
| 6614 | cat >>confdefs.h <<_ACEOF |
| 6615 | #define uint32_t $ac_cv_c_uint32_t |
| 6616 | _ACEOF |
| 6617 | ;; |
| 6618 | esac |
| 6619 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6620 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" |
| 6621 | case $ac_cv_c_uint64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6622 | no|yes) ;; #( |
| 6623 | *) |
| 6624 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6625 | $as_echo "#define _UINT64_T 1" >>confdefs.h |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6626 | |
| 6627 | |
| 6628 | cat >>confdefs.h <<_ACEOF |
| 6629 | #define uint64_t $ac_cv_c_uint64_t |
| 6630 | _ACEOF |
| 6631 | ;; |
| 6632 | esac |
| 6633 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6634 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" |
| 6635 | case $ac_cv_c_int32_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6636 | no|yes) ;; #( |
| 6637 | *) |
| 6638 | |
| 6639 | cat >>confdefs.h <<_ACEOF |
| 6640 | #define int32_t $ac_cv_c_int32_t |
| 6641 | _ACEOF |
| 6642 | ;; |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6643 | esac |
| 6644 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6645 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" |
| 6646 | case $ac_cv_c_int64_t in #( |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 6647 | no|yes) ;; #( |
| 6648 | *) |
| 6649 | |
| 6650 | cat >>confdefs.h <<_ACEOF |
| 6651 | #define int64_t $ac_cv_c_int64_t |
| 6652 | _ACEOF |
| 6653 | ;; |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 6654 | esac |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6655 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6656 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6657 | if test "x$ac_cv_type_ssize_t" = xyes; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6658 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6659 | $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6660 | |
| 6661 | fi |
| 6662 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 6663 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6664 | # Sizes of various common basic types |
Skip Montanaro | b9820a3 | 2004-01-17 00:16:12 +0000 | [diff] [blame] | 6665 | # ANSI C requires sizeof(char) == 1, so no need to check it |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6666 | # The cast to long int works around a bug in the HP C Compiler |
| 6667 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6668 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6669 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 |
| 6671 | $as_echo_n "checking size of int... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6672 | if ${ac_cv_sizeof_int+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6673 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6674 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6675 | 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] | 6676 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6677 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6678 | if test "$ac_cv_type_int" = yes; then |
| 6679 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6680 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6681 | as_fn_error 77 "cannot compute sizeof (int) |
| 6682 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6683 | else |
| 6684 | ac_cv_sizeof_int=0 |
| 6685 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6686 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6687 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6688 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6689 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
| 6690 | $as_echo "$ac_cv_sizeof_int" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6691 | |
| 6692 | |
| 6693 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6694 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6695 | #define SIZEOF_INT $ac_cv_sizeof_int |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6696 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6697 | |
| 6698 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6699 | # The cast to long int works around a bug in the HP C Compiler |
| 6700 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6701 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6702 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 |
| 6704 | $as_echo_n "checking size of long... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6705 | if ${ac_cv_sizeof_long+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6706 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6707 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6708 | 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] | 6709 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6710 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6711 | if test "$ac_cv_type_long" = yes; then |
| 6712 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6713 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6714 | as_fn_error 77 "cannot compute sizeof (long) |
| 6715 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6716 | else |
| 6717 | ac_cv_sizeof_long=0 |
| 6718 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6719 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6720 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6721 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6722 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
| 6723 | $as_echo "$ac_cv_sizeof_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6724 | |
| 6725 | |
| 6726 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6727 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6728 | #define SIZEOF_LONG $ac_cv_sizeof_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6729 | _ACEOF |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 6730 | |
| 6731 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6732 | # The cast to long int works around a bug in the HP C Compiler |
| 6733 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6734 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6735 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6736 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 |
| 6737 | $as_echo_n "checking size of void *... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6738 | if ${ac_cv_sizeof_void_p+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6739 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6740 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6741 | 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] | 6742 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6743 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6744 | if test "$ac_cv_type_void_p" = yes; then |
| 6745 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6746 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6747 | as_fn_error 77 "cannot compute sizeof (void *) |
| 6748 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6749 | else |
| 6750 | ac_cv_sizeof_void_p=0 |
| 6751 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6752 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6753 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6754 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 |
| 6756 | $as_echo "$ac_cv_sizeof_void_p" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6757 | |
| 6758 | |
| 6759 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6760 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6761 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6762 | _ACEOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 6763 | |
| 6764 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6765 | # The cast to long int works around a bug in the HP C Compiler |
| 6766 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6767 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6768 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6769 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 |
| 6770 | $as_echo_n "checking size of short... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6771 | if ${ac_cv_sizeof_short+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6772 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6773 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6774 | 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] | 6775 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6776 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6777 | if test "$ac_cv_type_short" = yes; then |
| 6778 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6779 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6780 | as_fn_error 77 "cannot compute sizeof (short) |
| 6781 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6782 | else |
| 6783 | ac_cv_sizeof_short=0 |
| 6784 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6785 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6786 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6787 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
| 6789 | $as_echo "$ac_cv_sizeof_short" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6790 | |
| 6791 | |
| 6792 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6793 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6794 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6795 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6796 | |
| 6797 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6798 | # The cast to long int works around a bug in the HP C Compiler |
| 6799 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6800 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6801 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6802 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of float" >&5 |
| 6803 | $as_echo_n "checking size of float... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6804 | if ${ac_cv_sizeof_float+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6805 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6806 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6807 | 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] | 6808 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6809 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6810 | if test "$ac_cv_type_float" = yes; then |
| 6811 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6812 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6813 | as_fn_error 77 "cannot compute sizeof (float) |
| 6814 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6815 | else |
| 6816 | ac_cv_sizeof_float=0 |
| 6817 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6818 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6819 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6820 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6821 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_float" >&5 |
| 6822 | $as_echo "$ac_cv_sizeof_float" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6823 | |
| 6824 | |
| 6825 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6826 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6827 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6828 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6829 | |
| 6830 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6831 | # The cast to long int works around a bug in the HP C Compiler |
| 6832 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6833 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6834 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6835 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 |
| 6836 | $as_echo_n "checking size of double... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6837 | if ${ac_cv_sizeof_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6838 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6839 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6840 | 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] | 6841 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6842 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6843 | if test "$ac_cv_type_double" = yes; then |
| 6844 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6845 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6846 | as_fn_error 77 "cannot compute sizeof (double) |
| 6847 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6848 | else |
| 6849 | ac_cv_sizeof_double=0 |
| 6850 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6851 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6852 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6853 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6854 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
| 6855 | $as_echo "$ac_cv_sizeof_double" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6856 | |
| 6857 | |
| 6858 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6859 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6860 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6861 | _ACEOF |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6862 | |
| 6863 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6864 | # The cast to long int works around a bug in the HP C Compiler |
| 6865 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6866 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6867 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6868 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fpos_t" >&5 |
| 6869 | $as_echo_n "checking size of fpos_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6870 | if ${ac_cv_sizeof_fpos_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6871 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6872 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6873 | 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] | 6874 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6875 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6876 | if test "$ac_cv_type_fpos_t" = yes; then |
| 6877 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6878 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6879 | as_fn_error 77 "cannot compute sizeof (fpos_t) |
| 6880 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6881 | else |
| 6882 | ac_cv_sizeof_fpos_t=0 |
| 6883 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6884 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6885 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6886 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6887 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fpos_t" >&5 |
| 6888 | $as_echo "$ac_cv_sizeof_fpos_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6889 | |
| 6890 | |
| 6891 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6892 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6893 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6894 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 6895 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6896 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6897 | # The cast to long int works around a bug in the HP C Compiler |
| 6898 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6899 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6900 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6901 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 |
| 6902 | $as_echo_n "checking size of size_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6903 | if ${ac_cv_sizeof_size_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6904 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6905 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6906 | 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] | 6907 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6908 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6909 | if test "$ac_cv_type_size_t" = yes; then |
| 6910 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6911 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6912 | as_fn_error 77 "cannot compute sizeof (size_t) |
| 6913 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6914 | else |
| 6915 | ac_cv_sizeof_size_t=0 |
| 6916 | fi |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6917 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6918 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6919 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6920 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 |
| 6921 | $as_echo "$ac_cv_sizeof_size_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6922 | |
| 6923 | |
| 6924 | |
Martin v. Löwis | 18e1655 | 2006-02-15 17:27:45 +0000 | [diff] [blame] | 6925 | cat >>confdefs.h <<_ACEOF |
| 6926 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t |
| 6927 | _ACEOF |
| 6928 | |
| 6929 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6930 | # The cast to long int works around a bug in the HP C Compiler |
| 6931 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6932 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6933 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pid_t" >&5 |
| 6935 | $as_echo_n "checking size of pid_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6936 | if ${ac_cv_sizeof_pid_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6937 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6938 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6939 | 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] | 6940 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6941 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6942 | if test "$ac_cv_type_pid_t" = yes; then |
| 6943 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 6944 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6945 | as_fn_error 77 "cannot compute sizeof (pid_t) |
| 6946 | See \`config.log' for more details" "$LINENO" 5; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6947 | else |
| 6948 | ac_cv_sizeof_pid_t=0 |
| 6949 | fi |
| 6950 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6951 | |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6952 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6953 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pid_t" >&5 |
| 6954 | $as_echo "$ac_cv_sizeof_pid_t" >&6; } |
Christian Heimes | 400adb0 | 2008-02-01 08:12:03 +0000 | [diff] [blame] | 6955 | |
| 6956 | |
| 6957 | |
| 6958 | cat >>confdefs.h <<_ACEOF |
| 6959 | #define SIZEOF_PID_T $ac_cv_sizeof_pid_t |
| 6960 | _ACEOF |
| 6961 | |
| 6962 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 6963 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6964 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long support" >&5 |
| 6965 | $as_echo_n "checking for long long support... " >&6; } |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6966 | have_long_long=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6967 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 6968 | /* end confdefs.h. */ |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6969 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6970 | int |
| 6971 | main () |
| 6972 | { |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6973 | long long x; x = (long long)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6974 | ; |
| 6975 | return 0; |
| 6976 | } |
| 6977 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6978 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6979 | |
| 6980 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6981 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6982 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 6983 | have_long_long=yes |
| 6984 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6985 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6986 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6987 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_long" >&5 |
| 6988 | $as_echo "$have_long_long" >&6; } |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 6989 | if test "$have_long_long" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 6990 | # The cast to long int works around a bug in the HP C Compiler |
| 6991 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 6992 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 6993 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6994 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 |
| 6995 | $as_echo_n "checking size of long long... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 6996 | if ${ac_cv_sizeof_long_long+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6997 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 6998 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 6999 | 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] | 7000 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7001 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7002 | if test "$ac_cv_type_long_long" = yes; then |
| 7003 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7004 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7005 | as_fn_error 77 "cannot compute sizeof (long long) |
| 7006 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7007 | else |
| 7008 | ac_cv_sizeof_long_long=0 |
| 7009 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7010 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7011 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7012 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
| 7014 | $as_echo "$ac_cv_sizeof_long_long" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7015 | |
| 7016 | |
| 7017 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7018 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7019 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7020 | _ACEOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7021 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7022 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7023 | fi |
| 7024 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7025 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double support" >&5 |
| 7026 | $as_echo_n "checking for long double support... " >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7027 | have_long_double=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7028 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7029 | /* end confdefs.h. */ |
| 7030 | |
| 7031 | int |
| 7032 | main () |
| 7033 | { |
| 7034 | long double x; x = (long double)0; |
| 7035 | ; |
| 7036 | return 0; |
| 7037 | } |
| 7038 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7039 | if ac_fn_c_try_compile "$LINENO"; then : |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7040 | |
| 7041 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7042 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7043 | |
| 7044 | have_long_double=yes |
| 7045 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7046 | fi |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7047 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7048 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_long_double" >&5 |
| 7049 | $as_echo "$have_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7050 | if test "$have_long_double" = yes ; then |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7051 | # The cast to long int works around a bug in the HP C Compiler |
| 7052 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7053 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7054 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7055 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long double" >&5 |
| 7056 | $as_echo_n "checking size of long double... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7057 | if ${ac_cv_sizeof_long_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7058 | $as_echo_n "(cached) " >&6 |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7059 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7060 | 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] | 7061 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7062 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7063 | if test "$ac_cv_type_long_double" = yes; then |
| 7064 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7065 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7066 | as_fn_error 77 "cannot compute sizeof (long double) |
| 7067 | See \`config.log' for more details" "$LINENO" 5; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7068 | else |
| 7069 | ac_cv_sizeof_long_double=0 |
| 7070 | fi |
| 7071 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7072 | |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7073 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7074 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_double" >&5 |
| 7075 | $as_echo "$ac_cv_sizeof_long_double" >&6; } |
Travis E. Oliphant | 9b30784 | 2007-10-12 22:06:37 +0000 | [diff] [blame] | 7076 | |
| 7077 | |
| 7078 | |
| 7079 | cat >>confdefs.h <<_ACEOF |
| 7080 | #define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double |
| 7081 | _ACEOF |
| 7082 | |
| 7083 | |
| 7084 | fi |
| 7085 | |
| 7086 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7087 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Bool support" >&5 |
| 7088 | $as_echo_n "checking for _Bool support... " >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7089 | have_c99_bool=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7090 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7091 | /* end confdefs.h. */ |
| 7092 | |
| 7093 | int |
| 7094 | main () |
| 7095 | { |
| 7096 | _Bool x; x = (_Bool)0; |
| 7097 | ; |
| 7098 | return 0; |
| 7099 | } |
| 7100 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7101 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7102 | |
| 7103 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7104 | $as_echo "#define HAVE_C99_BOOL 1" >>confdefs.h |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7105 | |
| 7106 | have_c99_bool=yes |
| 7107 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7108 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7109 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7110 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_c99_bool" >&5 |
| 7111 | $as_echo "$have_c99_bool" >&6; } |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7112 | if test "$have_c99_bool" = yes ; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7113 | # The cast to long int works around a bug in the HP C Compiler |
| 7114 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7115 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7116 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7117 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of _Bool" >&5 |
| 7118 | $as_echo_n "checking size of _Bool... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7119 | if ${ac_cv_sizeof__Bool+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7120 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7121 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7122 | 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] | 7123 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7124 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7125 | if test "$ac_cv_type__Bool" = yes; then |
| 7126 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7127 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7128 | as_fn_error 77 "cannot compute sizeof (_Bool) |
| 7129 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7130 | else |
| 7131 | ac_cv_sizeof__Bool=0 |
| 7132 | fi |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7133 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7134 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7135 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7136 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof__Bool" >&5 |
| 7137 | $as_echo "$ac_cv_sizeof__Bool" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7138 | |
| 7139 | |
| 7140 | |
Thomas Wouters | b213704 | 2007-02-01 18:02:27 +0000 | [diff] [blame] | 7141 | cat >>confdefs.h <<_ACEOF |
| 7142 | #define SIZEOF__BOOL $ac_cv_sizeof__Bool |
| 7143 | _ACEOF |
| 7144 | |
| 7145 | |
| 7146 | fi |
| 7147 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7148 | 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] | 7149 | #include <stdint.h> |
| 7150 | #endif |
Antoine Pitrou | 1bf29b7 | 2010-10-10 08:10:16 +0000 | [diff] [blame] | 7151 | #ifdef HAVE_INTTYPES_H |
| 7152 | #include <inttypes.h> |
| 7153 | #endif |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7154 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7155 | if test "x$ac_cv_type_uintptr_t" = xyes; then : |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7156 | |
| 7157 | cat >>confdefs.h <<_ACEOF |
| 7158 | #define HAVE_UINTPTR_T 1 |
| 7159 | _ACEOF |
| 7160 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7161 | # The cast to long int works around a bug in the HP C Compiler |
| 7162 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7163 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7164 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7165 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5 |
| 7166 | $as_echo_n "checking size of uintptr_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7167 | if ${ac_cv_sizeof_uintptr_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7168 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7169 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7170 | 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] | 7171 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7172 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7173 | if test "$ac_cv_type_uintptr_t" = yes; then |
| 7174 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7175 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7176 | as_fn_error 77 "cannot compute sizeof (uintptr_t) |
| 7177 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7178 | else |
| 7179 | ac_cv_sizeof_uintptr_t=0 |
| 7180 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7181 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7182 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7183 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5 |
| 7185 | $as_echo "$ac_cv_sizeof_uintptr_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7186 | |
| 7187 | |
| 7188 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7189 | cat >>confdefs.h <<_ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7190 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7191 | _ACEOF |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7192 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7193 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 7194 | fi |
| 7195 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 7196 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7197 | # The cast to long int works around a bug in the HP C Compiler |
| 7198 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7199 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7200 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7201 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 |
| 7202 | $as_echo_n "checking size of off_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7203 | if ${ac_cv_sizeof_off_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7204 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7205 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7206 | 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] | 7207 | #ifdef HAVE_SYS_TYPES_H |
| 7208 | #include <sys/types.h> |
| 7209 | #endif |
| 7210 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7211 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7212 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7213 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7214 | if test "$ac_cv_type_off_t" = yes; then |
| 7215 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7216 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7217 | as_fn_error 77 "cannot compute sizeof (off_t) |
| 7218 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7219 | else |
| 7220 | ac_cv_sizeof_off_t=0 |
| 7221 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7222 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7223 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7224 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7225 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 |
| 7226 | $as_echo "$ac_cv_sizeof_off_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7227 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7228 | |
| 7229 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7230 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7231 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7232 | _ACEOF |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7233 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7234 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7235 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7236 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable large file support" >&5 |
| 7237 | $as_echo_n "checking whether to enable large file support... " >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7238 | if test "$have_long_long" = yes |
| 7239 | then |
| 7240 | 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] | 7241 | "$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] | 7242 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7243 | $as_echo "#define HAVE_LARGEFILE_SUPPORT 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7244 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7246 | $as_echo "yes" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7247 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7248 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7249 | $as_echo "no" >&6; } |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7250 | fi |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7251 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7252 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7253 | $as_echo "no" >&6; } |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 7254 | fi |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 7255 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7256 | # The cast to long int works around a bug in the HP C Compiler |
| 7257 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7258 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7259 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7260 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 |
| 7261 | $as_echo_n "checking size of time_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7262 | if ${ac_cv_sizeof_time_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7263 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7264 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7265 | 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] | 7266 | #ifdef HAVE_SYS_TYPES_H |
| 7267 | #include <sys/types.h> |
| 7268 | #endif |
| 7269 | #ifdef HAVE_TIME_H |
| 7270 | #include <time.h> |
| 7271 | #endif |
| 7272 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7273 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7274 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7275 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7276 | if test "$ac_cv_type_time_t" = yes; then |
| 7277 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7278 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7279 | as_fn_error 77 "cannot compute sizeof (time_t) |
| 7280 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7281 | else |
| 7282 | ac_cv_sizeof_time_t=0 |
| 7283 | fi |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7284 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7285 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7286 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7287 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 |
| 7288 | $as_echo "$ac_cv_sizeof_time_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7289 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7290 | |
| 7291 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7292 | cat >>confdefs.h <<_ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7293 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7294 | _ACEOF |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 7295 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7296 | |
| 7297 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7298 | # if have pthread_t then define SIZEOF_PTHREAD_T |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7299 | ac_save_cc="$CC" |
| 7300 | if test "$ac_cv_kpthread" = "yes" |
| 7301 | then CC="$CC -Kpthread" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 7302 | elif test "$ac_cv_kthread" = "yes" |
| 7303 | then CC="$CC -Kthread" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 7304 | elif test "$ac_cv_pthread" = "yes" |
| 7305 | then CC="$CC -pthread" |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7306 | fi |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7307 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7308 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_t" >&5 |
| 7309 | $as_echo_n "checking for pthread_t... " >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7310 | have_pthread_t=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7311 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7312 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7313 | |
| 7314 | #include <pthread.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7315 | int |
| 7316 | main () |
| 7317 | { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 7318 | pthread_t x; x = *(pthread_t*)0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7319 | ; |
| 7320 | return 0; |
| 7321 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7322 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7323 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7324 | if ac_fn_c_try_compile "$LINENO"; then : |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7325 | have_pthread_t=yes |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7326 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7327 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7328 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_pthread_t" >&5 |
| 7329 | $as_echo "$have_pthread_t" >&6; } |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7330 | if test "$have_pthread_t" = yes ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7331 | # 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] | 7332 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 7333 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 7334 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7335 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5 |
| 7336 | $as_echo_n "checking size of pthread_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7337 | if ${ac_cv_sizeof_pthread_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7338 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7339 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7340 | 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] | 7341 | #ifdef HAVE_PTHREAD_H |
| 7342 | #include <pthread.h> |
| 7343 | #endif |
| 7344 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7345 | "; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7346 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7347 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7348 | if test "$ac_cv_type_pthread_t" = yes; then |
| 7349 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 7350 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7351 | as_fn_error 77 "cannot compute sizeof (pthread_t) |
| 7352 | See \`config.log' for more details" "$LINENO" 5; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7353 | else |
| 7354 | ac_cv_sizeof_pthread_t=0 |
| 7355 | fi |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7356 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7357 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7358 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7359 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5 |
| 7360 | $as_echo "$ac_cv_sizeof_pthread_t" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7361 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7362 | |
| 7363 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7364 | cat >>confdefs.h <<_ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7365 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7366 | _ACEOF |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7367 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 7368 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7369 | fi |
Martin v. Löwis | 123cbd2 | 2001-07-19 14:21:10 +0000 | [diff] [blame] | 7370 | CC="$ac_save_cc" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 7371 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7372 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7373 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7374 | Darwin/[01567]\..*) |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7375 | OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000" |
| 7376 | ;; |
| 7377 | Darwin/*) |
| 7378 | OTHER_LIBTOOL_OPT="" |
| 7379 | ;; |
| 7380 | esac |
| 7381 | |
| 7382 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7383 | ARCH_RUN_32BIT="" |
| 7384 | |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7385 | case $ac_sys_system/$ac_sys_release in |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 7386 | Darwin/[01567]\..*) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7387 | LIBTOOL_CRUFT="-framework System -lcc_dynamic" |
| 7388 | if test "${enable_universalsdk}"; then |
| 7389 | : |
| 7390 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7391 | LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `/usr/bin/arch`" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7392 | fi |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7393 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7394 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 7395 | Darwin/*) |
Ronald Oussoren | 9812a6c | 2010-02-07 11:53:18 +0000 | [diff] [blame] | 7396 | gcc_version=`gcc -dumpversion` |
Bob Ippolito | 7026a0a | 2005-03-28 23:23:47 +0000 | [diff] [blame] | 7397 | if test ${gcc_version} '<' 4.0 |
| 7398 | then |
| 7399 | LIBTOOL_CRUFT="-lcc_dynamic" |
| 7400 | else |
| 7401 | LIBTOOL_CRUFT="" |
| 7402 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7403 | if test "$cross_compiling" = yes; then : |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7404 | ac_osx_32bit=yes |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7405 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7406 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7407 | /* end confdefs.h. */ |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7408 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7409 | #include <unistd.h> |
| 7410 | int main(int argc, char*argv[]) |
| 7411 | { |
| 7412 | if (sizeof(long) == 4) { |
| 7413 | return 0; |
| 7414 | } else { |
| 7415 | return 1; |
| 7416 | } |
Ronald Oussoren | 3c064c1 | 2009-09-08 07:12:42 +0000 | [diff] [blame] | 7417 | } |
| 7418 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7419 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7420 | if ac_fn_c_try_run "$LINENO"; then : |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7421 | ac_osx_32bit=yes |
| 7422 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7423 | ac_osx_32bit=no |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7424 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7425 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 7426 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7427 | fi |
| 7428 | |
| 7429 | |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7430 | if test "${ac_osx_32bit}" = "yes"; then |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7431 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7432 | i386) |
| 7433 | MACOSX_DEFAULT_ARCH="i386" |
| 7434 | ;; |
| 7435 | ppc) |
| 7436 | MACOSX_DEFAULT_ARCH="ppc" |
| 7437 | ;; |
| 7438 | *) |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7439 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7440 | ;; |
| 7441 | esac |
| 7442 | else |
Ronald Oussoren | e3da75a | 2010-02-11 13:38:58 +0000 | [diff] [blame] | 7443 | case `/usr/bin/arch` in |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7444 | i386) |
| 7445 | MACOSX_DEFAULT_ARCH="x86_64" |
| 7446 | ;; |
| 7447 | ppc) |
| 7448 | MACOSX_DEFAULT_ARCH="ppc64" |
| 7449 | ;; |
| 7450 | *) |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7451 | as_fn_error $? "Unexpected output of 'arch' on OSX" "$LINENO" 5 |
Ronald Oussoren | 5bbab3e | 2009-09-06 11:01:15 +0000 | [diff] [blame] | 7452 | ;; |
| 7453 | esac |
| 7454 | |
| 7455 | #ARCH_RUN_32BIT="true" |
| 7456 | fi |
| 7457 | |
| 7458 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only ${MACOSX_DEFAULT_ARCH}" |
Jack Jansen | b36687a | 2004-07-16 08:43:47 +0000 | [diff] [blame] | 7459 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7460 | LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7461 | esac |
| 7462 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7463 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-framework" >&5 |
| 7464 | $as_echo_n "checking for --enable-framework... " >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7465 | if test "$enable_framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7466 | then |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 7467 | BASECFLAGS="$BASECFLAGS -fno-common -dynamic" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7468 | # -F. is needed to allow linking to the framework while |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7469 | # in the build location. |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7470 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7471 | $as_echo "#define WITH_NEXT_FRAMEWORK 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7472 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 7474 | $as_echo "yes" >&6; } |
Ronald Oussoren | 99aab65 | 2009-06-08 21:22:57 +0000 | [diff] [blame] | 7475 | if test $enable_shared = "yes" |
| 7476 | then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7477 | 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] | 7478 | fi |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7479 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7481 | $as_echo "no" >&6; } |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7482 | fi |
| 7483 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7484 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dyld" >&5 |
| 7485 | $as_echo_n "checking for dyld... " >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7486 | case $ac_sys_system/$ac_sys_release in |
| 7487 | Darwin/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7488 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7489 | $as_echo "#define WITH_DYLD 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7490 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: always on for Darwin" >&5 |
| 7492 | $as_echo "always on for Darwin" >&6; } |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7493 | ;; |
| 7494 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7495 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 7496 | $as_echo "no" >&6; } |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7497 | ;; |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 7498 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7499 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7500 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7501 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7502 | |
| 7503 | |
| 7504 | |
| 7505 | |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7506 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7507 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7508 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7509 | cat >>confdefs.h <<_ACEOF |
| 7510 | #define SHLIB_EXT "$SO" |
| 7511 | _ACEOF |
| 7512 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7513 | # LDSHARED is the ld *command* used to create shared library |
Martin v. Löwis | 12af048 | 2004-01-31 12:34:17 +0000 | [diff] [blame] | 7514 | # -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7515 | # (Shared libraries in this instance are shared modules to be loaded into |
| 7516 | # Python, as opposed to building Python itself as a shared library.) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7517 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDSHARED" >&5 |
| 7518 | $as_echo_n "checking LDSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7519 | if test -z "$LDSHARED" |
| 7520 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7521 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7522 | AIX*) |
Georg Brandl | 9a829be | 2011-02-15 15:44:51 +0000 | [diff] [blame] | 7523 | 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] | 7524 | LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7525 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7526 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7527 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7528 | SunOS/5*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7529 | if test "$GCC" = "yes" ; then |
| 7530 | LDSHARED='$(CC) -shared' |
| 7531 | LDCXXSHARED='$(CXX) -shared' |
| 7532 | else |
| 7533 | LDSHARED='$(CC) -G' |
| 7534 | LDCXXSHARED='$(CXX) -G' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 7535 | fi ;; |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7536 | hp*|HP*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7537 | if test "$GCC" = "yes" ; then |
| 7538 | LDSHARED='$(CC) -shared' |
| 7539 | LDCXXSHARED='$(CXX) -shared' |
| 7540 | else |
| 7541 | LDSHARED='ld -b' |
Thomas Heller | f44b9a1 | 2008-04-04 10:18:23 +0000 | [diff] [blame] | 7542 | fi ;; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7543 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7544 | Darwin/1.3*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7545 | LDSHARED='$(CC) -bundle' |
| 7546 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7547 | if test "$enable_framework" ; then |
| 7548 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7549 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7550 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7551 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7552 | else |
| 7553 | # No framework. Ignore undefined symbols, assuming they come from Python |
Jack Jansen | 418c3b1 | 2001-11-14 10:59:57 +0000 | [diff] [blame] | 7554 | LDSHARED="$LDSHARED -undefined suppress" |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7555 | LDCXXSHARED="$LDCXXSHARED -undefined suppress" |
Jack Jansen | a3891ea | 2001-09-07 14:25:12 +0000 | [diff] [blame] | 7556 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7557 | Darwin/1.4*|Darwin/5.*|Darwin/6.*) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7558 | LDSHARED='$(CC) -bundle' |
| 7559 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7560 | if test "$enable_framework" ; then |
| 7561 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7562 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7563 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7564 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7565 | else |
Michael W. Hudson | 594bc80 | 2002-03-07 09:59:15 +0000 | [diff] [blame] | 7566 | # No framework, use the Python app as bundle-loader |
| 7567 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
Jack Jansen | c28fc37 | 2003-02-25 13:14:43 +0000 | [diff] [blame] | 7568 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7569 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7570 | fi ;; |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7571 | Darwin/*) |
| 7572 | # Use -undefined dynamic_lookup whenever possible (10.3 and later). |
| 7573 | # This allows an extension to be used in any Python |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 7574 | |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7575 | if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2 |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7576 | then |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7577 | if test "${enable_universalsdk}"; then |
Benjamin Peterson | 14ae959 | 2008-07-16 02:20:15 +0000 | [diff] [blame] | 7578 | LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7579 | fi |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7580 | LDSHARED='$(CC) -bundle -undefined dynamic_lookup' |
| 7581 | LDCXXSHARED='$(CXX) -bundle -undefined dynamic_lookup' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7582 | BLDSHARED="$LDSHARED" |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7583 | else |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7584 | LDSHARED='$(CC) -bundle' |
| 7585 | LDCXXSHARED='$(CXX) -bundle' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7586 | if test "$enable_framework" ; then |
| 7587 | # Link against the framework. All externals should be defined. |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7588 | BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
| 7589 | LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7590 | LDCXXSHARED="$LDCXXSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7591 | else |
| 7592 | # No framework, use the Python app as bundle-loader |
| 7593 | BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)' |
| 7594 | LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7595 | LDCXXSHARED="$LDCXXSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)' |
Jack Jansen | 6b08a40 | 2004-06-03 12:41:45 +0000 | [diff] [blame] | 7596 | fi |
| 7597 | fi |
| 7598 | ;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7599 | Linux*|GNU*|QNX*) |
| 7600 | LDSHARED='$(CC) -shared' |
| 7601 | LDCXXSHARED='$(CXX) -shared';; |
| 7602 | BSD/OS*/4*) |
| 7603 | LDSHARED="gcc -shared" |
| 7604 | LDCXXSHARED="g++ -shared";; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7605 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 7606 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7607 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7608 | LDSHARED='$(CC) -shared' |
| 7609 | LDCXXSHARED='$(CXX) -shared' |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7610 | else |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7611 | LDSHARED="ld -Bshareable" |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 7612 | fi;; |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7613 | OpenBSD*) |
| 7614 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7615 | then |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7616 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7617 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7618 | else |
| 7619 | case `uname -r` in |
| 7620 | [01].* | 2.[0-7] | 2.[0-7].*) |
| 7621 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 7622 | ;; |
| 7623 | *) |
Antoine Pitrou | d4958c2 | 2010-10-13 17:01:10 +0000 | [diff] [blame] | 7624 | LDSHARED='$(CC) -shared $(CCSHARED)' |
| 7625 | LDCXXSHARED='$(CXX) -shared $(CCSHARED)' |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 7626 | ;; |
| 7627 | esac |
| 7628 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7629 | NetBSD*|DragonFly*) |
Antoine Pitrou | ece919e | 2011-01-02 20:45:21 +0000 | [diff] [blame] | 7630 | LDSHARED='$(CC) -shared' |
| 7631 | LDCXXSHARED='$(CXX) -shared';; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7632 | OpenUNIX*|UnixWare*) |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7633 | if test "$GCC" = "yes" ; then |
| 7634 | LDSHARED='$(CC) -shared' |
| 7635 | LDCXXSHARED='$(CXX) -shared' |
| 7636 | else |
| 7637 | LDSHARED='$(CC) -G' |
| 7638 | LDCXXSHARED='$(CXX) -G' |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7639 | fi;; |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7640 | SCO_SV*) |
| 7641 | LDSHARED='$(CC) -Wl,-G,-Bexport' |
| 7642 | LDCXXSHARED='$(CXX) -Wl,-G,-Bexport';; |
| 7643 | CYGWIN*) |
| 7644 | LDSHARED="gcc -shared -Wl,--enable-auto-image-base" |
| 7645 | LDCXXSHARED="g++ -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7646 | *) LDSHARED="ld";; |
| 7647 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7648 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7649 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDSHARED" >&5 |
| 7650 | $as_echo "$LDSHARED" >&6; } |
Benjamin Peterson | 99f0376 | 2010-04-11 22:15:28 +0000 | [diff] [blame] | 7651 | LDCXXSHARED=${LDCXXSHARED-$LDSHARED} |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7652 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7653 | # 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] | 7654 | # library (module) -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7655 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CCSHARED" >&5 |
| 7656 | $as_echo_n "checking CCSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7657 | if test -z "$CCSHARED" |
| 7658 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7659 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7660 | SunOS*) if test "$GCC" = yes; |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7661 | then CCSHARED="-fPIC"; |
| 7662 | elif test `uname -p` = sparc; |
| 7663 | then CCSHARED="-xcode=pic32"; |
| 7664 | else CCSHARED="-Kpic"; |
| 7665 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7666 | hp*|HP*) if test "$GCC" = yes; |
Martin v. Löwis | 703ad70 | 2001-09-05 08:36:52 +0000 | [diff] [blame] | 7667 | then CCSHARED="-fPIC"; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 7668 | else CCSHARED="+z"; |
| 7669 | fi;; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7670 | Linux*|GNU*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7671 | BSD/OS*/4*) CCSHARED="-fpic";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7672 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7673 | OpenUNIX*|UnixWare*) |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7674 | if test "$GCC" = "yes" |
| 7675 | then CCSHARED="-fPIC" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 7676 | else CCSHARED="-KPIC" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 7677 | fi;; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7678 | SCO_SV*) |
| 7679 | if test "$GCC" = "yes" |
| 7680 | then CCSHARED="-fPIC" |
| 7681 | else CCSHARED="-Kpic -belf" |
| 7682 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7683 | IRIX*/6*) case $CC in |
| 7684 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 7685 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7686 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7687 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7688 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7689 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCSHARED" >&5 |
| 7690 | $as_echo "$CCSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7691 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7692 | # the python executable -- this is only needed for a few systems |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7693 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LINKFORSHARED" >&5 |
| 7694 | $as_echo_n "checking LINKFORSHARED... " >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7695 | if test -z "$LINKFORSHARED" |
| 7696 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 7697 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7698 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 7699 | hp*|HP*) |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 7700 | LINKFORSHARED="-Wl,-E -Wl,+s";; |
| 7701 | # LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 7702 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 7703 | Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7704 | # -u libsys_s pulls in all symbols in libsys |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7705 | Darwin/*) |
Benjamin Peterson | 9c80cac | 2009-05-23 16:34:23 +0000 | [diff] [blame] | 7706 | LINKFORSHARED="$extra_undefs -framework CoreFoundation" |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7707 | if test "$enable_framework" |
| 7708 | then |
Jack Jansen | da49e19 | 2005-01-07 13:08:22 +0000 | [diff] [blame] | 7709 | LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)' |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 7710 | fi |
Anthony Baxter | eef2d3b | 2004-11-06 04:45:33 +0000 | [diff] [blame] | 7711 | LINKFORSHARED="$LINKFORSHARED";; |
Martin v. Löwis | 25ae43b | 2001-10-07 08:39:18 +0000 | [diff] [blame] | 7712 | OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";; |
Martin v. Löwis | 21ee409 | 2002-09-30 16:19:48 +0000 | [diff] [blame] | 7713 | SCO_SV*) LINKFORSHARED="-Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 7714 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 7715 | FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 7716 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 7717 | then |
| 7718 | LINKFORSHARED="-Wl,--export-dynamic" |
| 7719 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7720 | SunOS/5*) case $CC in |
| 7721 | *gcc*) |
Martin v. Löwis | a454857 | 2002-04-18 14:51:36 +0000 | [diff] [blame] | 7722 | if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 7723 | then |
| 7724 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 7725 | fi;; |
| 7726 | esac;; |
Jason Tishler | 3076559 | 2003-09-04 11:04:06 +0000 | [diff] [blame] | 7727 | CYGWIN*) |
| 7728 | if test $enable_shared = "no" |
| 7729 | then |
| 7730 | LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)' |
| 7731 | fi;; |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 7732 | QNX*) |
| 7733 | # -Wl,-E causes the symbols to be added to the dynamic |
| 7734 | # symbol table so that they can be found when a module |
| 7735 | # is loaded. -N 2048K causes the stack size to be set |
| 7736 | # to 2048 kilobytes so that the stack doesn't overflow |
| 7737 | # when running test_compile.py. |
| 7738 | LINKFORSHARED='-Wl,-E -N 2048K';; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7739 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7740 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7741 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINKFORSHARED" >&5 |
| 7742 | $as_echo "$LINKFORSHARED" >&6; } |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7743 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 7744 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 7745 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking CFLAGSFORSHARED" >&5 |
| 7747 | $as_echo_n "checking CFLAGSFORSHARED... " >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7748 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 7749 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 7750 | case $ac_sys_system in |
| 7751 | CYGWIN*) |
| 7752 | # Cygwin needs CCSHARED when building extension DLLs |
| 7753 | # but not when building the interpreter DLL. |
| 7754 | CFLAGSFORSHARED='';; |
| 7755 | *) |
| 7756 | CFLAGSFORSHARED='$(CCSHARED)' |
| 7757 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7758 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7759 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CFLAGSFORSHARED" >&5 |
| 7760 | $as_echo "$CFLAGSFORSHARED" >&6; } |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7761 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7762 | # SHLIBS are libraries (except -lc and -lm) to link to the python shared |
| 7763 | # library (with --enable-shared). |
| 7764 | # 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] | 7765 | # symbols, this must be set to $(LIBS) (expanded by make). We do this even |
| 7766 | # if it is not required, since it creates a dependency of the shared library |
| 7767 | # to LIBS. This, in turn, means that applications linking the shared libpython |
| 7768 | # don't need to link LIBS explicitly. The default should be only changed |
| 7769 | # on systems where this approach causes problems. |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7770 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7771 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SHLIBS" >&5 |
| 7772 | $as_echo_n "checking SHLIBS... " >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7773 | case "$ac_sys_system" in |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7774 | *) |
Martin v. Löwis | d6359c5 | 2002-08-04 12:38:50 +0000 | [diff] [blame] | 7775 | SHLIBS='$(LIBS)';; |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7776 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7777 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIBS" >&5 |
| 7778 | $as_echo "$SHLIBS" >&6; } |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 7779 | |
| 7780 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7781 | # checks for libraries |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7782 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
| 7783 | $as_echo_n "checking for dlopen in -ldl... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7784 | if ${ac_cv_lib_dl_dlopen+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7785 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7786 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7787 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7788 | LIBS="-ldl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7789 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7790 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7791 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7792 | /* Override any GCC internal prototype to avoid an error. |
| 7793 | Use char because int might match the return type of a GCC |
| 7794 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7795 | #ifdef __cplusplus |
| 7796 | extern "C" |
| 7797 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7798 | char dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7799 | int |
| 7800 | main () |
| 7801 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7802 | return dlopen (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7803 | ; |
| 7804 | return 0; |
| 7805 | } |
| 7806 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7807 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7808 | ac_cv_lib_dl_dlopen=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7809 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7810 | ac_cv_lib_dl_dlopen=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7811 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7812 | rm -f core conftest.err conftest.$ac_objext \ |
| 7813 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7814 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7815 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
| 7817 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7818 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7819 | cat >>confdefs.h <<_ACEOF |
| 7820 | #define HAVE_LIBDL 1 |
| 7821 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7822 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7823 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7824 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7825 | fi |
| 7826 | # Dynamic linking for SunOS/Solaris and SYSV |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7827 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 |
| 7828 | $as_echo_n "checking for shl_load in -ldld... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7829 | if ${ac_cv_lib_dld_shl_load+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7830 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7831 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7832 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7833 | LIBS="-ldld $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7834 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7835 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7836 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7837 | /* Override any GCC internal prototype to avoid an error. |
| 7838 | Use char because int might match the return type of a GCC |
| 7839 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7840 | #ifdef __cplusplus |
| 7841 | extern "C" |
| 7842 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7843 | char shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7844 | int |
| 7845 | main () |
| 7846 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7847 | return shl_load (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7848 | ; |
| 7849 | return 0; |
| 7850 | } |
| 7851 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7852 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7853 | ac_cv_lib_dld_shl_load=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7854 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7855 | ac_cv_lib_dld_shl_load=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7856 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7857 | rm -f core conftest.err conftest.$ac_objext \ |
| 7858 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7859 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7860 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
| 7862 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7863 | if test "x$ac_cv_lib_dld_shl_load" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7864 | cat >>confdefs.h <<_ACEOF |
| 7865 | #define HAVE_LIBDLD 1 |
| 7866 | _ACEOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7867 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7868 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7869 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7870 | fi |
| 7871 | # Dynamic linking for HP-UX |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7872 | |
Georg Brandl | b1441c7 | 2009-01-03 22:33:39 +0000 | [diff] [blame] | 7873 | # only check for sem_init if thread support is requested |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7874 | if test "$with_threads" = "yes" -o -z "$with_threads"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5 |
| 7876 | $as_echo_n "checking for library containing sem_init... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7877 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7878 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7879 | else |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7880 | ac_func_search_save_LIBS=$LIBS |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7881 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7882 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7883 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7884 | /* Override any GCC internal prototype to avoid an error. |
| 7885 | Use char because int might match the return type of a GCC |
| 7886 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7887 | #ifdef __cplusplus |
| 7888 | extern "C" |
| 7889 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7890 | char sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7891 | int |
| 7892 | main () |
| 7893 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7894 | return sem_init (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7895 | ; |
| 7896 | return 0; |
| 7897 | } |
| 7898 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7899 | for ac_lib in '' pthread rt posix4; do |
| 7900 | if test -z "$ac_lib"; then |
| 7901 | ac_res="none required" |
| 7902 | else |
| 7903 | ac_res=-l$ac_lib |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7904 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7905 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7906 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7907 | ac_cv_search_sem_init=$ac_res |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 7908 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7909 | rm -f core conftest.err conftest.$ac_objext \ |
| 7910 | conftest$ac_exeext |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7911 | if ${ac_cv_search_sem_init+:} false; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7912 | break |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 7913 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7914 | done |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7915 | if ${ac_cv_search_sem_init+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7916 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7917 | else |
| 7918 | ac_cv_search_sem_init=no |
| 7919 | fi |
| 7920 | rm conftest.$ac_ext |
Martin v. Löwis | 82c19a7 | 2002-10-06 11:48:09 +0000 | [diff] [blame] | 7921 | LIBS=$ac_func_search_save_LIBS |
| 7922 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5 |
| 7924 | $as_echo "$ac_cv_search_sem_init" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7925 | ac_res=$ac_cv_search_sem_init |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7926 | if test "$ac_res" != no; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7927 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7928 | |
Martin v. Löwis | 41933dd | 2002-03-21 15:10:58 +0000 | [diff] [blame] | 7929 | fi |
Martin v. Löwis | d3545ec | 2003-05-03 11:25:43 +0000 | [diff] [blame] | 7930 | # 'Real Time' functions on Solaris |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 7931 | # posix4 on Solaris 2.6 |
| 7932 | # pthread (first!) on Linux |
| 7933 | fi |
| 7934 | |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7935 | # check if we need libintl for locale functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for textdomain in -lintl" >&5 |
| 7937 | $as_echo_n "checking for textdomain in -lintl... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7938 | if ${ac_cv_lib_intl_textdomain+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7939 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7940 | else |
| 7941 | ac_check_lib_save_LIBS=$LIBS |
| 7942 | LIBS="-lintl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7943 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7944 | /* end confdefs.h. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7945 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7946 | /* Override any GCC internal prototype to avoid an error. |
| 7947 | Use char because int might match the return type of a GCC |
| 7948 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7949 | #ifdef __cplusplus |
| 7950 | extern "C" |
| 7951 | #endif |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7952 | char textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7953 | int |
| 7954 | main () |
| 7955 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 7956 | return textdomain (); |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7957 | ; |
| 7958 | return 0; |
| 7959 | } |
| 7960 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7961 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7962 | ac_cv_lib_intl_textdomain=yes |
| 7963 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7964 | ac_cv_lib_intl_textdomain=no |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7965 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7966 | rm -f core conftest.err conftest.$ac_objext \ |
| 7967 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7968 | LIBS=$ac_check_lib_save_LIBS |
| 7969 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7970 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_textdomain" >&5 |
| 7971 | $as_echo "$ac_cv_lib_intl_textdomain" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 7972 | if test "x$ac_cv_lib_intl_textdomain" = xyes; then : |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7973 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7974 | $as_echo "#define WITH_LIBINTL 1" >>confdefs.h |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7975 | |
Brett Cannon | c6d936e | 2009-06-07 20:09:53 +0000 | [diff] [blame] | 7976 | LIBS="-lintl $LIBS" |
Martin v. Löwis | 19d1734 | 2003-06-14 21:03:05 +0000 | [diff] [blame] | 7977 | fi |
| 7978 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7979 | |
| 7980 | # checks for system dependent C++ extensions support |
| 7981 | case "$ac_sys_system" in |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7982 | AIX*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for genuine AIX C++ extensions support" >&5 |
| 7983 | $as_echo_n "checking for genuine AIX C++ extensions support... " >&6; } |
| 7984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 7985 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7986 | |
Georg Brandl | 59e87bd | 2011-02-15 19:48:59 +0000 | [diff] [blame] | 7987 | #include <load.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7988 | int |
| 7989 | main () |
| 7990 | { |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7991 | loadAndInit("", 0, "") |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7992 | ; |
| 7993 | return 0; |
| 7994 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7995 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 7996 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 7997 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 7998 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 7999 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8000 | $as_echo "#define AIX_GENUINE_CPLUSPLUS 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8001 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8002 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8003 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8004 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8005 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8006 | |
| 8007 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8008 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8009 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8010 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8011 | rm -f core conftest.err conftest.$ac_objext \ |
| 8012 | conftest$ac_exeext conftest.$ac_ext;; |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 8013 | *) ;; |
| 8014 | esac |
| 8015 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 8016 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8017 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
| 8018 | $as_echo_n "checking for t_open in -lnsl... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8019 | if ${ac_cv_lib_nsl_t_open+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8020 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8021 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8022 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8023 | LIBS="-lnsl $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8024 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8025 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8026 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8027 | /* Override any GCC internal prototype to avoid an error. |
| 8028 | Use char because int might match the return type of a GCC |
| 8029 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8030 | #ifdef __cplusplus |
| 8031 | extern "C" |
| 8032 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8033 | char t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8034 | int |
| 8035 | main () |
| 8036 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8037 | return t_open (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8038 | ; |
| 8039 | return 0; |
| 8040 | } |
| 8041 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8042 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8043 | ac_cv_lib_nsl_t_open=yes |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8044 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8045 | ac_cv_lib_nsl_t_open=no |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8046 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8047 | rm -f core conftest.err conftest.$ac_objext \ |
| 8048 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8049 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8050 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8051 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 |
| 8052 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8053 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8054 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 8055 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 8056 | # SVR4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8057 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5 |
| 8058 | $as_echo_n "checking for socket in -lsocket... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8059 | if ${ac_cv_lib_socket_socket+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8060 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8061 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8062 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8063 | LIBS="-lsocket $LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8064 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8065 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8066 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8067 | /* Override any GCC internal prototype to avoid an error. |
| 8068 | Use char because int might match the return type of a GCC |
| 8069 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8070 | #ifdef __cplusplus |
| 8071 | extern "C" |
| 8072 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8073 | char socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8074 | int |
| 8075 | main () |
| 8076 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8077 | return socket (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8078 | ; |
| 8079 | return 0; |
| 8080 | } |
| 8081 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8082 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8083 | ac_cv_lib_socket_socket=yes |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8084 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8085 | ac_cv_lib_socket_socket=no |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8086 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8087 | rm -f core conftest.err conftest.$ac_objext \ |
| 8088 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8089 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 8090 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5 |
| 8092 | $as_echo "$ac_cv_lib_socket_socket" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8093 | if test "x$ac_cv_lib_socket_socket" = xyes; then : |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8094 | LIBS="-lsocket $LIBS" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8095 | fi |
| 8096 | # SVR4 sockets |
Skip Montanaro | b9949db | 2004-01-17 04:04:13 +0000 | [diff] [blame] | 8097 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8098 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5 |
| 8099 | $as_echo_n "checking for --with-libs... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8100 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8101 | # Check whether --with-libs was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8102 | if test "${with_libs+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8103 | withval=$with_libs; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8104 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8105 | $as_echo "$withval" >&6; } |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 8106 | LIBS="$withval $LIBS" |
| 8107 | |
| 8108 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8109 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8110 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8111 | fi |
| 8112 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 8113 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8114 | if test -n "$ac_tool_prefix"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8115 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. |
| 8116 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8117 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8118 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8119 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8120 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8121 | else |
| 8122 | case $PKG_CONFIG in |
| 8123 | [\\/]* | ?:[\\/]*) |
| 8124 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. |
| 8125 | ;; |
| 8126 | *) |
| 8127 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8128 | for as_dir in $PATH |
| 8129 | do |
| 8130 | IFS=$as_save_IFS |
| 8131 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8132 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8133 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8134 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8135 | $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] | 8136 | break 2 |
| 8137 | fi |
| 8138 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8139 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8140 | IFS=$as_save_IFS |
| 8141 | |
| 8142 | ;; |
| 8143 | esac |
| 8144 | fi |
| 8145 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG |
| 8146 | if test -n "$PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8147 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 |
| 8148 | $as_echo "$PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8149 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8150 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8151 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8152 | fi |
| 8153 | |
| 8154 | |
| 8155 | fi |
| 8156 | if test -z "$ac_cv_path_PKG_CONFIG"; then |
| 8157 | ac_pt_PKG_CONFIG=$PKG_CONFIG |
| 8158 | # Extract the first word of "pkg-config", so it can be a program name with args. |
| 8159 | set dummy pkg-config; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8160 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 8161 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8162 | if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8163 | $as_echo_n "(cached) " >&6 |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8164 | else |
| 8165 | case $ac_pt_PKG_CONFIG in |
| 8166 | [\\/]* | ?:[\\/]*) |
| 8167 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. |
| 8168 | ;; |
| 8169 | *) |
| 8170 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 8171 | for as_dir in $PATH |
| 8172 | do |
| 8173 | IFS=$as_save_IFS |
| 8174 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8175 | for ac_exec_ext in '' $ac_executable_extensions; do |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8176 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
| 8177 | 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] | 8178 | $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] | 8179 | break 2 |
| 8180 | fi |
| 8181 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8182 | done |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8183 | IFS=$as_save_IFS |
| 8184 | |
| 8185 | ;; |
| 8186 | esac |
| 8187 | fi |
| 8188 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG |
| 8189 | if test -n "$ac_pt_PKG_CONFIG"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 |
| 8191 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8192 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8193 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8194 | $as_echo "no" >&6; } |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8195 | fi |
| 8196 | |
| 8197 | if test "x$ac_pt_PKG_CONFIG" = x; then |
| 8198 | PKG_CONFIG="" |
| 8199 | else |
| 8200 | case $cross_compiling:$ac_tool_warned in |
| 8201 | yes:) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8202 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
| 8203 | $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] | 8204 | ac_tool_warned=yes ;; |
| 8205 | esac |
| 8206 | PKG_CONFIG=$ac_pt_PKG_CONFIG |
| 8207 | fi |
| 8208 | else |
| 8209 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" |
| 8210 | fi |
| 8211 | |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8212 | |
| 8213 | # Check for use of the system expat library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8214 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-expat" >&5 |
| 8215 | $as_echo_n "checking for --with-system-expat... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8216 | |
| 8217 | # Check whether --with-system_expat was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8218 | if test "${with_system_expat+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8219 | withval=$with_system_expat; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 8220 | else |
| 8221 | with_system_expat="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8222 | fi |
| 8223 | |
| 8224 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8225 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_expat" >&5 |
| 8226 | $as_echo "$with_system_expat" >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8227 | |
| 8228 | # Check for use of the system libffi library |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8229 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-system-ffi" >&5 |
| 8230 | $as_echo_n "checking for --with-system-ffi... " >&6; } |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8231 | |
| 8232 | # Check whether --with-system_ffi was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8233 | if test "${with_system_ffi+set}" = set; then : |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8234 | withval=$with_system_ffi; |
Benjamin Peterson | 7926325 | 2010-10-31 16:50:44 +0000 | [diff] [blame] | 8235 | else |
| 8236 | with_system_ffi="no" |
Benjamin Peterson | 0f64b0b | 2010-03-09 21:49:52 +0000 | [diff] [blame] | 8237 | fi |
| 8238 | |
| 8239 | |
| 8240 | if test "$with_system_ffi" = "yes" && test -n "$PKG_CONFIG"; then |
Benjamin Peterson | d78735d | 2010-01-01 16:04:23 +0000 | [diff] [blame] | 8241 | LIBFFI_INCLUDEDIR="`"$PKG_CONFIG" libffi --cflags-only-I 2>/dev/null | sed -e 's/^-I//;s/ *$//'`" |
| 8242 | else |
| 8243 | LIBFFI_INCLUDEDIR="" |
| 8244 | fi |
| 8245 | |
| 8246 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8247 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_system_ffi" >&5 |
| 8248 | $as_echo "$with_system_ffi" >&6; } |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 8249 | |
Benjamin Peterson | 076ed00 | 2010-10-31 17:11:02 +0000 | [diff] [blame] | 8250 | # Check for support for loadable sqlite extensions |
| 8251 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-loadable-sqlite-extensions" >&5 |
| 8252 | $as_echo_n "checking for --enable-loadable-sqlite-extensions... " >&6; } |
| 8253 | # Check whether --enable-loadable-sqlite-extensions was given. |
| 8254 | if test "${enable_loadable_sqlite_extensions+set}" = set; then : |
| 8255 | enableval=$enable_loadable_sqlite_extensions; |
| 8256 | else |
| 8257 | enable_loadable_sqlite_extensions="no" |
| 8258 | fi |
| 8259 | |
| 8260 | |
| 8261 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_loadable_sqlite_extensions" >&5 |
| 8262 | $as_echo "$enable_loadable_sqlite_extensions" >&6; } |
| 8263 | |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8264 | # Check for --with-dbmliborder |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8265 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dbmliborder" >&5 |
| 8266 | $as_echo_n "checking for --with-dbmliborder... " >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8267 | |
| 8268 | # Check whether --with-dbmliborder was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8269 | if test "${with_dbmliborder+set}" = set; then : |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8270 | withval=$with_dbmliborder; |
| 8271 | if test x$with_dbmliborder = xyes |
| 8272 | then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8273 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8274 | else |
| 8275 | for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do |
| 8276 | if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb |
| 8277 | then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8278 | as_fn_error $? "proper usage is --with-dbmliborder=db1:db2:..." "$LINENO" 5 |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8279 | fi |
| 8280 | done |
| 8281 | fi |
| 8282 | fi |
| 8283 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8284 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_dbmliborder" >&5 |
| 8285 | $as_echo "$with_dbmliborder" >&6; } |
Matthias Klose | 55708cc | 2009-04-30 08:06:49 +0000 | [diff] [blame] | 8286 | |
Martin v. Löwis | 3e2c632 | 2002-10-29 10:07:43 +0000 | [diff] [blame] | 8287 | # Determine if signalmodule should be used. |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8288 | |
| 8289 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8290 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-signal-module" >&5 |
| 8291 | $as_echo_n "checking for --with-signal-module... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8292 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8293 | # Check whether --with-signal-module was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8294 | if test "${with_signal_module+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8295 | withval=$with_signal_module; |
| 8296 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8297 | |
| 8298 | |
| 8299 | if test -z "$with_signal_module" |
| 8300 | then with_signal_module="yes" |
| 8301 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8302 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_signal_module" >&5 |
| 8303 | $as_echo "$with_signal_module" >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 8304 | |
| 8305 | if test "${with_signal_module}" = "yes"; then |
| 8306 | USE_SIGNAL_MODULE="" |
| 8307 | SIGNAL_OBJS="" |
| 8308 | else |
| 8309 | USE_SIGNAL_MODULE="#" |
| 8310 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 8311 | fi |
| 8312 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 8313 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8314 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8315 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 8316 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8317 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-dec-threads" >&5 |
| 8318 | $as_echo_n "checking for --with-dec-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8319 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8320 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8321 | # Check whether --with-dec-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8322 | if test "${with_dec_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8323 | withval=$with_dec_threads; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8324 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5 |
| 8325 | $as_echo "$withval" >&6; } |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8326 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8327 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8328 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 8329 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8330 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8331 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8332 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8333 | fi |
| 8334 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8335 | |
| 8336 | # Templates for things AC_DEFINEd more than once. |
| 8337 | # For a single AC_DEFINE, no template is needed. |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8338 | |
| 8339 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8340 | |
| 8341 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-threads" >&5 |
| 8343 | $as_echo_n "checking for --with-threads... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8344 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8345 | # Check whether --with-threads was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8346 | if test "${with_threads+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8347 | withval=$with_threads; |
| 8348 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 8349 | |
| 8350 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8351 | # --with-thread is deprecated, but check for it anyway |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8352 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8353 | # Check whether --with-thread was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8354 | if test "${with_thread+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8355 | withval=$with_thread; with_threads=$with_thread |
| 8356 | fi |
| 8357 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8358 | |
| 8359 | if test -z "$with_threads" |
| 8360 | then with_threads="yes" |
| 8361 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8362 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_threads" >&5 |
| 8363 | $as_echo "$with_threads" >&6; } |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8364 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8365 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 8366 | if test "$with_threads" = "no" |
| 8367 | then |
| 8368 | USE_THREAD_MODULE="#" |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8369 | elif test "$ac_cv_pthread_is_default" = yes |
| 8370 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8371 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8372 | |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8373 | # Defining _REENTRANT on system with POSIX threads should not hurt. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8374 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 8375 | |
| 8376 | posix_threads=yes |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8377 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8378 | elif test "$ac_cv_kpthread" = "yes" |
| 8379 | then |
| 8380 | CC="$CC -Kpthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8381 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8382 | CXX="$CXX -Kpthread" |
| 8383 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8384 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 8385 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8386 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8387 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8388 | elif test "$ac_cv_kthread" = "yes" |
| 8389 | then |
| 8390 | CC="$CC -Kthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8391 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8392 | CXX="$CXX -Kthread" |
| 8393 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8394 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 5f433f0 | 2003-05-05 05:05:30 +0000 | [diff] [blame] | 8395 | |
| 8396 | posix_threads=yes |
| 8397 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8398 | elif test "$ac_cv_pthread" = "yes" |
| 8399 | then |
| 8400 | CC="$CC -pthread" |
Martin v. Löwis | 519adae | 2003-09-20 10:47:47 +0000 | [diff] [blame] | 8401 | if test "$ac_cv_cxx_thread" = "yes"; then |
| 8402 | CXX="$CXX -pthread" |
| 8403 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8404 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8405 | |
| 8406 | posix_threads=yes |
| 8407 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8408 | else |
| 8409 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 8410 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 8411 | fi |
| 8412 | if test ! -z "$withval" -a -d "$withval" |
| 8413 | then LDFLAGS="$LDFLAGS -L$withval" |
| 8414 | fi |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8415 | |
| 8416 | # According to the POSIX spec, a pthreads implementation must |
Matthias Klose | a2542be | 2004-08-16 11:35:51 +0000 | [diff] [blame] | 8417 | # define _POSIX_THREADS in unistd.h. Some apparently don't |
| 8418 | # (e.g. gnu pth with pthread emulation) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8419 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _POSIX_THREADS in unistd.h" >&5 |
| 8420 | $as_echo_n "checking for _POSIX_THREADS in unistd.h... " >&6; } |
| 8421 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8422 | /* end confdefs.h. */ |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8423 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8424 | #include <unistd.h> |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 8425 | #ifdef _POSIX_THREADS |
| 8426 | yes |
| 8427 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8428 | |
| 8429 | _ACEOF |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8430 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8431 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8432 | unistd_defines_pthreads=yes |
| 8433 | else |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8434 | unistd_defines_pthreads=no |
| 8435 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 8436 | rm -f conftest* |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8437 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8438 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $unistd_defines_pthreads" >&5 |
| 8439 | $as_echo "$unistd_defines_pthreads" >&6; } |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8440 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8441 | $as_echo "#define _REENTRANT 1" >>confdefs.h |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 8442 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8443 | ac_fn_c_check_header_mongrel "$LINENO" "cthreads.h" "ac_cv_header_cthreads_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8444 | if test "x$ac_cv_header_cthreads_h" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8445 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8446 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8447 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8448 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8449 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8450 | $as_echo "#define HURD_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8451 | |
| 8452 | LIBS="$LIBS -lthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8453 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8454 | else |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8455 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8456 | ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8457 | if test "x$ac_cv_header_mach_cthreads_h" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8458 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8459 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8460 | $as_echo "#define C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8461 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8462 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8463 | $as_echo "#define MACH_C_THREADS 1" >>confdefs.h |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8464 | |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8465 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8466 | else |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8467 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8468 | # Just looking for pthread_create in libpthread is not enough: |
| 8469 | # on HP/UX, pthread.h renames pthread_create to a different symbol name. |
| 8470 | # So we really have to include pthread.h, and then link. |
| 8471 | _libs=$LIBS |
| 8472 | LIBS="$LIBS -lpthread" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8473 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5 |
| 8474 | $as_echo_n "checking for pthread_create in -lpthread... " >&6; } |
| 8475 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8476 | /* end confdefs.h. */ |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8477 | #include <pthread.h> |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8478 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8479 | void * start_routine (void *arg) { exit (0); } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8480 | int |
| 8481 | main () |
| 8482 | { |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8483 | |
| 8484 | pthread_create (NULL, NULL, start_routine, NULL) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8485 | ; |
| 8486 | return 0; |
| 8487 | } |
| 8488 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8489 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8490 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8492 | $as_echo "yes" >&6; } |
| 8493 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8494 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8495 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8496 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 8497 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8498 | |
Martin v. Löwis | 8158b5a | 2001-10-08 13:17:28 +0000 | [diff] [blame] | 8499 | LIBS=$_libs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8500 | ac_fn_c_check_func "$LINENO" "pthread_detach" "ac_cv_func_pthread_detach" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8501 | if test "x$ac_cv_func_pthread_detach" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8502 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8503 | |
Martin v. Löwis | 69c0ff3 | 2001-10-15 14:34:42 +0000 | [diff] [blame] | 8504 | posix_threads=yes |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8505 | THREADOBJ="Python/thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8506 | else |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 8507 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8508 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthreads" >&5 |
| 8509 | $as_echo_n "checking for pthread_create in -lpthreads... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8510 | if ${ac_cv_lib_pthreads_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8511 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8512 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8513 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8514 | LIBS="-lpthreads $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8515 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8516 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8517 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8518 | /* Override any GCC internal prototype to avoid an error. |
| 8519 | Use char because int might match the return type of a GCC |
| 8520 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8521 | #ifdef __cplusplus |
| 8522 | extern "C" |
| 8523 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8524 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8525 | int |
| 8526 | main () |
| 8527 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8528 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8529 | ; |
| 8530 | return 0; |
| 8531 | } |
| 8532 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8533 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8534 | ac_cv_lib_pthreads_pthread_create=yes |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8535 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8536 | ac_cv_lib_pthreads_pthread_create=no |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8537 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8538 | rm -f core conftest.err conftest.$ac_objext \ |
| 8539 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8540 | LIBS=$ac_check_lib_save_LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8541 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8542 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5 |
| 8543 | $as_echo "$ac_cv_lib_pthreads_pthread_create" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8544 | if test "x$ac_cv_lib_pthreads_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8545 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8546 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8547 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8548 | LIBS="$LIBS -lpthreads" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8549 | THREADOBJ="Python/thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8550 | else |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8551 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8552 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lc_r" >&5 |
| 8553 | $as_echo_n "checking for pthread_create in -lc_r... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8554 | if ${ac_cv_lib_c_r_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8555 | $as_echo_n "(cached) " >&6 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8556 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8557 | ac_check_lib_save_LIBS=$LIBS |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 8558 | LIBS="-lc_r $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8559 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8560 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8561 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8562 | /* Override any GCC internal prototype to avoid an error. |
| 8563 | Use char because int might match the return type of a GCC |
| 8564 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8565 | #ifdef __cplusplus |
| 8566 | extern "C" |
| 8567 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8568 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8569 | int |
| 8570 | main () |
| 8571 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8572 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8573 | ; |
| 8574 | return 0; |
| 8575 | } |
| 8576 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8577 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8578 | ac_cv_lib_c_r_pthread_create=yes |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8579 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8580 | ac_cv_lib_c_r_pthread_create=no |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8581 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8582 | rm -f core conftest.err conftest.$ac_objext \ |
| 8583 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8584 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8585 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8586 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_create" >&5 |
| 8587 | $as_echo "$ac_cv_lib_c_r_pthread_create" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8588 | if test "x$ac_cv_lib_c_r_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8589 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8590 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8591 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8592 | LIBS="$LIBS -lc_r" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8593 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8594 | else |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 8595 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8596 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __pthread_create_system in -lpthread" >&5 |
| 8597 | $as_echo_n "checking for __pthread_create_system in -lpthread... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8598 | if ${ac_cv_lib_pthread___pthread_create_system+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8599 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8600 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8601 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8602 | LIBS="-lpthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8603 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8604 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8605 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8606 | /* Override any GCC internal prototype to avoid an error. |
| 8607 | Use char because int might match the return type of a GCC |
| 8608 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8609 | #ifdef __cplusplus |
| 8610 | extern "C" |
| 8611 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8612 | char __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8613 | int |
| 8614 | main () |
| 8615 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8616 | return __pthread_create_system (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8617 | ; |
| 8618 | return 0; |
| 8619 | } |
| 8620 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8621 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8622 | ac_cv_lib_pthread___pthread_create_system=yes |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8623 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8624 | ac_cv_lib_pthread___pthread_create_system=no |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8625 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8626 | rm -f core conftest.err conftest.$ac_objext \ |
| 8627 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8628 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8629 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8630 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread___pthread_create_system" >&5 |
| 8631 | $as_echo "$ac_cv_lib_pthread___pthread_create_system" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8632 | if test "x$ac_cv_lib_pthread___pthread_create_system" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8633 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8634 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8635 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8636 | LIBS="$LIBS -lpthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8637 | THREADOBJ="Python/thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8638 | else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 8639 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8640 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lcma" >&5 |
| 8641 | $as_echo_n "checking for pthread_create in -lcma... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8642 | if ${ac_cv_lib_cma_pthread_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8643 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8644 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8645 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8646 | LIBS="-lcma $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8647 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8648 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8649 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8650 | /* Override any GCC internal prototype to avoid an error. |
| 8651 | Use char because int might match the return type of a GCC |
| 8652 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8653 | #ifdef __cplusplus |
| 8654 | extern "C" |
| 8655 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8656 | char pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8657 | int |
| 8658 | main () |
| 8659 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8660 | return pthread_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8661 | ; |
| 8662 | return 0; |
| 8663 | } |
| 8664 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8665 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8666 | ac_cv_lib_cma_pthread_create=yes |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8667 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8668 | ac_cv_lib_cma_pthread_create=no |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8669 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8670 | rm -f core conftest.err conftest.$ac_objext \ |
| 8671 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8672 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8673 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cma_pthread_create" >&5 |
| 8675 | $as_echo "$ac_cv_lib_cma_pthread_create" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8676 | if test "x$ac_cv_lib_cma_pthread_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8677 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8678 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 8679 | posix_threads=yes |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8680 | LIBS="$LIBS -lcma" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8681 | THREADOBJ="Python/thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8682 | else |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 8683 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8684 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 8685 | fi |
| 8686 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8687 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 8688 | fi |
| 8689 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 8690 | fi |
| 8691 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 8692 | fi |
| 8693 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 8694 | fi |
| 8695 | |
Martin v. Löwis | f90ae20 | 2002-06-11 06:22:31 +0000 | [diff] [blame] | 8696 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8697 | rm -f core conftest.err conftest.$ac_objext \ |
| 8698 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8699 | fi |
| 8700 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8701 | |
| 8702 | fi |
| 8703 | |
Martin v. Löwis | a6e9758 | 2002-01-01 18:41:33 +0000 | [diff] [blame] | 8704 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8705 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8706 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usconfig in -lmpc" >&5 |
| 8707 | $as_echo_n "checking for usconfig in -lmpc... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8708 | if ${ac_cv_lib_mpc_usconfig+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8709 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8710 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8711 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8712 | LIBS="-lmpc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8713 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8714 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8715 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8716 | /* Override any GCC internal prototype to avoid an error. |
| 8717 | Use char because int might match the return type of a GCC |
| 8718 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8719 | #ifdef __cplusplus |
| 8720 | extern "C" |
| 8721 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8722 | char usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8723 | int |
| 8724 | main () |
| 8725 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8726 | return usconfig (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8727 | ; |
| 8728 | return 0; |
| 8729 | } |
| 8730 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8731 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8732 | ac_cv_lib_mpc_usconfig=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8733 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8734 | ac_cv_lib_mpc_usconfig=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8735 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8736 | rm -f core conftest.err conftest.$ac_objext \ |
| 8737 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8738 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8739 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mpc_usconfig" >&5 |
| 8741 | $as_echo "$ac_cv_lib_mpc_usconfig" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8742 | if test "x$ac_cv_lib_mpc_usconfig" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8743 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8744 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8745 | LIBS="$LIBS -lmpc" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8746 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8747 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8748 | fi |
| 8749 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8750 | |
Neal Norwitz | a978ab0 | 2002-11-02 16:58:05 +0000 | [diff] [blame] | 8751 | if test "$posix_threads" != "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8752 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5 |
| 8753 | $as_echo_n "checking for thr_create in -lthread... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8754 | if ${ac_cv_lib_thread_thr_create+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8755 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8756 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8757 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 8758 | LIBS="-lthread $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8759 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8760 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8761 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8762 | /* Override any GCC internal prototype to avoid an error. |
| 8763 | Use char because int might match the return type of a GCC |
| 8764 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8765 | #ifdef __cplusplus |
| 8766 | extern "C" |
| 8767 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8768 | char thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8769 | int |
| 8770 | main () |
| 8771 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8772 | return thr_create (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8773 | ; |
| 8774 | return 0; |
| 8775 | } |
| 8776 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8777 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8778 | ac_cv_lib_thread_thr_create=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8779 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8780 | ac_cv_lib_thread_thr_create=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8781 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8782 | rm -f core conftest.err conftest.$ac_objext \ |
| 8783 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8784 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8785 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8786 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5 |
| 8787 | $as_echo "$ac_cv_lib_thread_thr_create" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8788 | if test "x$ac_cv_lib_thread_thr_create" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8789 | $as_echo "#define WITH_THREAD 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8790 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8791 | LIBS="$LIBS -lthread" |
Martin v. Löwis | 2d7e264 | 2002-04-05 16:50:53 +0000 | [diff] [blame] | 8792 | THREADOBJ="Python/thread.o" |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8793 | USE_THREAD_MODULE="" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8794 | fi |
| 8795 | |
Martin v. Löwis | 3d2b549 | 2002-03-15 13:48:21 +0000 | [diff] [blame] | 8796 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 8797 | |
Martin v. Löwis | 130fb17 | 2001-07-19 11:00:41 +0000 | [diff] [blame] | 8798 | if test "$USE_THREAD_MODULE" != "#" |
| 8799 | then |
| 8800 | # If the above checks didn't disable threads, (at least) OSF1 |
| 8801 | # needs this '-threads' argument during linking. |
| 8802 | case $ac_sys_system in |
| 8803 | OSF1) LDLAST=-threads;; |
| 8804 | esac |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 8805 | fi |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8806 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8807 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8808 | if test "$posix_threads" = "yes"; then |
| 8809 | if test "$unistd_defines_pthreads" = "no"; then |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8810 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8811 | $as_echo "#define _POSIX_THREADS 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8812 | |
| 8813 | fi |
| 8814 | |
| 8815 | # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8. |
| 8816 | case $ac_sys_system/$ac_sys_release in |
| 8817 | SunOS/5.6) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8818 | $as_echo "#define HAVE_PTHREAD_DESTRUCTOR 1" >>confdefs.h |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8819 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8820 | ;; |
| 8821 | SunOS/5.8) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8822 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8823 | |
| 8824 | ;; |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8825 | AIX/5) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8826 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
Christian Heimes | 7b3ce6a | 2008-01-31 14:31:45 +0000 | [diff] [blame] | 8827 | |
| 8828 | ;; |
Antoine Pitrou | 33a2994 | 2010-08-30 14:52:00 +0000 | [diff] [blame] | 8829 | AIX/6) |
| 8830 | $as_echo "#define HAVE_BROKEN_POSIX_SEMAPHORES 1" >>confdefs.h |
| 8831 | |
| 8832 | ;; |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8833 | esac |
| 8834 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8835 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5 |
| 8836 | $as_echo_n "checking if PTHREAD_SCOPE_SYSTEM is supported... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8837 | if ${ac_cv_pthread_system_supported+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8838 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8839 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8840 | if test "$cross_compiling" = yes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8841 | ac_cv_pthread_system_supported=no |
| 8842 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8843 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8844 | /* end confdefs.h. */ |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8845 | #include <pthread.h> |
| 8846 | void *foo(void *parm) { |
| 8847 | return NULL; |
| 8848 | } |
| 8849 | main() { |
| 8850 | pthread_attr_t attr; |
| 8851 | pthread_t id; |
| 8852 | if (pthread_attr_init(&attr)) exit(-1); |
| 8853 | if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1); |
| 8854 | if (pthread_create(&id, &attr, foo, NULL)) exit(-1); |
| 8855 | exit(0); |
| 8856 | } |
| 8857 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8858 | if ac_fn_c_try_run "$LINENO"; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8859 | ac_cv_pthread_system_supported=yes |
| 8860 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8861 | ac_cv_pthread_system_supported=no |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8862 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8863 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8864 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8865 | fi |
Martin v. Löwis | a7a76d3 | 2002-10-04 07:21:24 +0000 | [diff] [blame] | 8866 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8867 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 8868 | fi |
| 8869 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8870 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthread_system_supported" >&5 |
| 8871 | $as_echo "$ac_cv_pthread_system_supported" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8872 | if test "$ac_cv_pthread_system_supported" = "yes"; then |
| 8873 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8874 | $as_echo "#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1" >>confdefs.h |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8875 | |
| 8876 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8877 | for ac_func in pthread_sigmask |
| 8878 | do : |
| 8879 | ac_fn_c_check_func "$LINENO" "pthread_sigmask" "ac_cv_func_pthread_sigmask" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 8880 | if test "x$ac_cv_func_pthread_sigmask" = xyes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8881 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8882 | #define HAVE_PTHREAD_SIGMASK 1 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8883 | _ACEOF |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8884 | case $ac_sys_system in |
| 8885 | CYGWIN*) |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8886 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8887 | $as_echo "#define HAVE_BROKEN_PTHREAD_SIGMASK 1" >>confdefs.h |
Jason Tishler | fac083d | 2003-07-22 15:20:49 +0000 | [diff] [blame] | 8888 | |
| 8889 | ;; |
| 8890 | esac |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 8891 | fi |
| 8892 | done |
| 8893 | |
| 8894 | fi |
| 8895 | |
| 8896 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8897 | # Check for enable-ipv6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8898 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8899 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if --enable-ipv6 is specified" >&5 |
| 8900 | $as_echo_n "checking if --enable-ipv6 is specified... " >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8901 | # Check whether --enable-ipv6 was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8902 | if test "${enable_ipv6+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8903 | enableval=$enable_ipv6; case "$enableval" in |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8904 | no) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8905 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8906 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8907 | ipv6=no |
| 8908 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8909 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8910 | $as_echo "yes" >&6; } |
| 8911 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8912 | |
| 8913 | ipv6=yes |
| 8914 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8915 | esac |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8916 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8917 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8918 | if test "$cross_compiling" = yes; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8919 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8920 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8921 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8922 | ipv6=no |
| 8923 | |
| 8924 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8925 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8926 | /* end confdefs.h. */ |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8927 | /* AF_INET6 available check */ |
| 8928 | #include <sys/types.h> |
| 8929 | #include <sys/socket.h> |
| 8930 | main() |
| 8931 | { |
| 8932 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 8933 | exit(1); |
| 8934 | else |
| 8935 | exit(0); |
| 8936 | } |
| 8937 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8938 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8939 | if ac_fn_c_try_run "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8940 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8941 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 8942 | $as_echo "yes" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8943 | ipv6=yes |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8944 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8945 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8946 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 8948 | $as_echo "no" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8949 | ipv6=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8950 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8951 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8952 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 8953 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8954 | fi |
| 8955 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8956 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8957 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if RFC2553 API is available" >&5 |
| 8959 | $as_echo_n "checking if RFC2553 API is available... " >&6; } |
| 8960 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 8961 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8962 | |
| 8963 | #include <sys/types.h> |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8964 | #include <netinet/in.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8965 | int |
| 8966 | main () |
| 8967 | { |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8968 | struct sockaddr_in6 x; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8969 | x.sin6_scope_id; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8970 | ; |
| 8971 | return 0; |
| 8972 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8973 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 8974 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8975 | if ac_fn_c_try_compile "$LINENO"; then : |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8976 | |
| 8977 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8978 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8979 | ipv6=yes |
| 8980 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8981 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8982 | |
| 8983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8984 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 8985 | ipv6=no |
| 8986 | |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8987 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8988 | 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] | 8989 | fi |
| 8990 | |
| 8991 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 8992 | $as_echo "#define ENABLE_IPV6 1" >>confdefs.h |
Martin v. Löwis | a5f8bb5 | 2001-09-05 08:22:34 +0000 | [diff] [blame] | 8993 | |
| 8994 | fi |
| 8995 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 8996 | fi |
| 8997 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 8998 | |
| 8999 | ipv6type=unknown |
| 9000 | ipv6lib=none |
| 9001 | ipv6trylibc=no |
| 9002 | |
| 9003 | if test "$ipv6" = "yes"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9004 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ipv6 stack type" >&5 |
| 9005 | $as_echo_n "checking ipv6 stack type... " >&6; } |
Guido van Rossum | b855216 | 2001-09-05 14:58:11 +0000 | [diff] [blame] | 9006 | for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta; |
| 9007 | do |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9008 | case $i in |
| 9009 | inria) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9010 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9011 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9012 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9013 | #include <netinet/in.h> |
| 9014 | #ifdef IPV6_INRIA_VERSION |
| 9015 | yes |
| 9016 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9017 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9018 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9019 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9020 | ipv6type=$i |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9021 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9022 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9023 | |
| 9024 | ;; |
| 9025 | kame) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9026 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9027 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9028 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9029 | #include <netinet/in.h> |
| 9030 | #ifdef __KAME__ |
| 9031 | yes |
| 9032 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9033 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9034 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9035 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9036 | ipv6type=$i; |
| 9037 | ipv6lib=inet6 |
| 9038 | ipv6libdir=/usr/local/v6/lib |
| 9039 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9040 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9041 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9042 | |
| 9043 | ;; |
| 9044 | linux-glibc) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9045 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9046 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9047 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9048 | #include <features.h> |
| 9049 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 9050 | yes |
| 9051 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9052 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9053 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9054 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9055 | ipv6type=$i; |
| 9056 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9057 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9058 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9059 | |
| 9060 | ;; |
| 9061 | linux-inet6) |
| 9062 | if test -d /usr/inet6; then |
| 9063 | ipv6type=$i |
| 9064 | ipv6lib=inet6 |
| 9065 | ipv6libdir=/usr/inet6/lib |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9066 | BASECFLAGS="-I/usr/inet6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9067 | fi |
| 9068 | ;; |
| 9069 | solaris) |
| 9070 | if test -f /etc/netconfig; then |
Antoine Pitrou | f3fcd9f | 2011-01-03 18:53:50 +0000 | [diff] [blame] | 9071 | if $GREP -q tcp6 /etc/netconfig; then |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9072 | ipv6type=$i |
| 9073 | ipv6trylibc=yes |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9074 | fi |
| 9075 | fi |
| 9076 | ;; |
| 9077 | toshiba) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9078 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9079 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9080 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9081 | #include <sys/param.h> |
| 9082 | #ifdef _TOSHIBA_INET6 |
| 9083 | yes |
| 9084 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9085 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9086 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9087 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9088 | ipv6type=$i; |
| 9089 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9090 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9091 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9092 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9093 | |
| 9094 | ;; |
| 9095 | v6d) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9096 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9097 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9098 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9099 | #include </usr/local/v6/include/sys/v6config.h> |
| 9100 | #ifdef __V6D__ |
| 9101 | yes |
| 9102 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9103 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9104 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9105 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9106 | ipv6type=$i; |
| 9107 | ipv6lib=v6; |
| 9108 | ipv6libdir=/usr/local/v6/lib; |
Skip Montanaro | decc6a4 | 2003-01-01 20:07:49 +0000 | [diff] [blame] | 9109 | BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS" |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9110 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9111 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9112 | |
| 9113 | ;; |
| 9114 | zeta) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9116 | /* end confdefs.h. */ |
Martin v. Löwis | a5f73f9 | 2001-10-15 08:06:29 +0000 | [diff] [blame] | 9117 | |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9118 | #include <sys/param.h> |
| 9119 | #ifdef _ZETA_MINAMI_INET6 |
| 9120 | yes |
| 9121 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9122 | _ACEOF |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9123 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9124 | $EGREP "yes" >/dev/null 2>&1; then : |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9125 | ipv6type=$i; |
| 9126 | ipv6lib=inet6; |
Martin v. Löwis | 44ddbde | 2001-12-02 10:15:37 +0000 | [diff] [blame] | 9127 | ipv6libdir=/usr/local/v6/lib |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9128 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 9129 | rm -f conftest* |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9130 | |
| 9131 | ;; |
| 9132 | esac |
| 9133 | if test "$ipv6type" != "unknown"; then |
| 9134 | break |
| 9135 | fi |
| 9136 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ipv6type" >&5 |
| 9138 | $as_echo "$ipv6type" >&6; } |
Martin v. Löwis | a2ac602 | 2001-08-09 11:40:14 +0000 | [diff] [blame] | 9139 | fi |
| 9140 | |
| 9141 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 9142 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 9143 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 9144 | echo "using lib$ipv6lib" |
| 9145 | else |
| 9146 | if test $ipv6trylibc = "yes"; then |
| 9147 | echo "using libc" |
| 9148 | else |
| 9149 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 9150 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 9151 | echo 'ipv6 kit and compile beforehand.' |
| 9152 | exit 1 |
| 9153 | fi |
| 9154 | fi |
| 9155 | fi |
| 9156 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9157 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 SDK or later" >&5 |
| 9158 | $as_echo_n "checking for OSX 10.5 SDK or later... " >&6; } |
| 9159 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9160 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9161 | |
| 9162 | #include <Carbon/Carbon.h> |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9163 | int |
| 9164 | main () |
| 9165 | { |
| 9166 | FSIORefNum fRef = 0 |
| 9167 | ; |
| 9168 | return 0; |
| 9169 | } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9170 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9171 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9172 | if ac_fn_c_try_compile "$LINENO"; then : |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9173 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9174 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9175 | $as_echo "#define HAVE_OSX105_SDK 1" >>confdefs.h |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9176 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9178 | $as_echo "yes" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9179 | |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9180 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9181 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9182 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9183 | $as_echo "no" >&6; } |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9184 | |
| 9185 | fi |
Benjamin Peterson | 8f95cc2 | 2008-07-16 02:23:25 +0000 | [diff] [blame] | 9186 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9187 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9188 | # Check for --with-doc-strings |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9189 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-doc-strings" >&5 |
| 9190 | $as_echo_n "checking for --with-doc-strings... " >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9191 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9192 | # Check whether --with-doc-strings was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9193 | if test "${with_doc_strings+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9194 | withval=$with_doc_strings; |
| 9195 | fi |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9196 | |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9197 | |
| 9198 | if test -z "$with_doc_strings" |
| 9199 | then with_doc_strings="yes" |
| 9200 | fi |
| 9201 | if test "$with_doc_strings" != "no" |
| 9202 | then |
| 9203 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9204 | $as_echo "#define WITH_DOC_STRINGS 1" >>confdefs.h |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9205 | |
| 9206 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9207 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_doc_strings" >&5 |
| 9208 | $as_echo "$with_doc_strings" >&6; } |
Martin v. Löwis | a3fb4f7 | 2002-06-09 13:33:54 +0000 | [diff] [blame] | 9209 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 9210 | # Check if eval loop should use timestamp counter profiling |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9211 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-tsc" >&5 |
| 9212 | $as_echo_n "checking for --with-tsc... " >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9213 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9214 | # Check whether --with-tsc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9215 | if test "${with_tsc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9216 | withval=$with_tsc; |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9217 | if test "$withval" != no |
| 9218 | then |
| 9219 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9220 | $as_echo "#define WITH_TSC 1" >>confdefs.h |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9221 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9222 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 9223 | $as_echo "yes" >&6; } |
| 9224 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9225 | $as_echo "no" >&6; } |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9226 | fi |
| 9227 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9228 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9229 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9230 | fi |
| 9231 | |
Martin v. Löwis | f30d60e | 2004-06-08 08:17:44 +0000 | [diff] [blame] | 9232 | |
| 9233 | # Check for Python-specific malloc support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9234 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-pymalloc" >&5 |
| 9235 | $as_echo_n "checking for --with-pymalloc... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9236 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9237 | # Check whether --with-pymalloc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9238 | if test "${with_pymalloc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9239 | withval=$with_pymalloc; |
| 9240 | fi |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9241 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 9242 | |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9243 | if test -z "$with_pymalloc" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 9244 | then |
| 9245 | with_pymalloc="yes" |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 9246 | ABIFLAGS="${ABIFLAGS}m" |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9247 | fi |
| 9248 | if test "$with_pymalloc" != "no" |
| 9249 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9250 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9251 | $as_echo "#define WITH_PYMALLOC 1" >>confdefs.h |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9252 | |
| 9253 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9254 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pymalloc" >&5 |
| 9255 | $as_echo "$with_pymalloc" >&6; } |
Neil Schemenauer | 16c2297 | 2002-03-22 15:34:49 +0000 | [diff] [blame] | 9256 | |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9257 | # Check for Valgrind support |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9258 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-valgrind" >&5 |
| 9259 | $as_echo_n "checking for --with-valgrind... " >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9260 | |
| 9261 | # Check whether --with-valgrind was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9262 | if test "${with_valgrind+set}" = set; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9263 | withval=$with_valgrind; |
| 9264 | else |
| 9265 | with_valgrind=no |
| 9266 | fi |
| 9267 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_valgrind" >&5 |
| 9269 | $as_echo "$with_valgrind" >&6; } |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9270 | if test "$with_valgrind" != no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9271 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9272 | if test "x$ac_cv_header_valgrind_valgrind_h" = xyes; then : |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9273 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9274 | $as_echo "#define WITH_VALGRIND 1" >>confdefs.h |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9275 | |
| 9276 | else |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9277 | as_fn_error $? "Valgrind support requested but headers not available" "$LINENO" 5 |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9278 | |
| 9279 | fi |
| 9280 | |
| 9281 | |
Jeffrey Yasskin | 3937083 | 2010-05-03 19:29:34 +0000 | [diff] [blame] | 9282 | OPT="-DDYNAMIC_ANNOTATIONS_ENABLED=1 $OPT" |
Benjamin Peterson | 05159c4 | 2009-12-03 03:01:27 +0000 | [diff] [blame] | 9283 | fi |
| 9284 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 9285 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9286 | |
Guido van Rossum | 98935bf | 2001-09-05 19:13:16 +0000 | [diff] [blame] | 9287 | DLINCLDIR=. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 9288 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9289 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 9290 | # 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] | 9291 | for ac_func in dlopen |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9292 | do : |
| 9293 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9294 | if test "x$ac_cv_func_dlopen" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9295 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9296 | #define HAVE_DLOPEN 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9297 | _ACEOF |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9298 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9299 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 9300 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9301 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9302 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9303 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 9304 | # loading of modules. |
| 9305 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9306 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DYNLOADFILE" >&5 |
| 9307 | $as_echo_n "checking DYNLOADFILE... " >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9308 | if test -z "$DYNLOADFILE" |
| 9309 | then |
| 9310 | case $ac_sys_system/$ac_sys_release in |
Martin v. Löwis | c19c5a6 | 2003-11-18 20:00:44 +0000 | [diff] [blame] | 9311 | AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c |
| 9312 | if test "$ac_cv_func_dlopen" = yes |
| 9313 | then DYNLOADFILE="dynload_shlib.o" |
| 9314 | else DYNLOADFILE="dynload_aix.o" |
| 9315 | fi |
| 9316 | ;; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9317 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 9318 | # Use dynload_next.c only on 10.2 and below, which don't have native dlopen() |
| 9319 | Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9320 | *) |
| 9321 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 9322 | # out any dynamic loading |
| 9323 | if test "$ac_cv_func_dlopen" = yes |
| 9324 | then DYNLOADFILE="dynload_shlib.o" |
| 9325 | else DYNLOADFILE="dynload_stub.o" |
| 9326 | fi |
| 9327 | ;; |
| 9328 | esac |
| 9329 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9330 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DYNLOADFILE" >&5 |
| 9331 | $as_echo "$DYNLOADFILE" >&6; } |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9332 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 9333 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9334 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9335 | $as_echo "#define HAVE_DYNAMIC_LOADING 1" >>confdefs.h |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 9336 | |
| 9337 | fi |
| 9338 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9339 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 9340 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9341 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking MACHDEP_OBJS" >&5 |
| 9343 | $as_echo_n "checking MACHDEP_OBJS... " >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9344 | if test -z "$MACHDEP_OBJS" |
| 9345 | then |
Jack Jansen | e578a63 | 2001-08-15 01:27:14 +0000 | [diff] [blame] | 9346 | MACHDEP_OBJS=$extra_machdep_objs |
| 9347 | else |
| 9348 | MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs" |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9349 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9350 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: MACHDEP_OBJS" >&5 |
| 9351 | $as_echo "MACHDEP_OBJS" >&6; } |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 9352 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 9353 | # checks for library functions |
Antoine Pitrou | b1c5496 | 2010-10-14 15:05:38 +0000 | [diff] [blame] | 9354 | for ac_func in alarm accept4 setitimer getitimer bind_textdomain_codeset chown \ |
Martin v. Löwis | 823725e | 2008-03-24 13:39:54 +0000 | [diff] [blame] | 9355 | clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \ |
Martin v. Löwis | 438b534 | 2002-12-27 10:16:42 +0000 | [diff] [blame] | 9356 | gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 9357 | getpriority getresuid getresgid getpwent getspnam getspent getsid getwd \ |
Antoine Pitrou | b7572f0 | 2009-12-02 20:46:48 +0000 | [diff] [blame] | 9358 | initgroups kill killpg lchmod lchown lstat mbrtowc mkfifo mknod mktime \ |
Martin v. Löwis | a5f0907 | 2002-10-11 05:37:59 +0000 | [diff] [blame] | 9359 | mremap nice pathconf pause plock poll pthread_init \ |
Guido van Rossum | 162e38c | 2003-02-19 15:25:10 +0000 | [diff] [blame] | 9360 | putenv readlink realpath \ |
Benjamin Peterson | 965ce87 | 2009-04-05 21:24:58 +0000 | [diff] [blame] | 9361 | select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \ |
| 9362 | setgid \ |
Martin v. Löwis | 7aed61a | 2009-11-27 14:09:49 +0000 | [diff] [blame] | 9363 | setlocale setregid setreuid setresuid setresgid setsid setpgid setpgrp setuid setvbuf \ |
Jean-Paul Calderone | 6ed7ac4 | 2010-06-19 19:58:37 +0000 | [diff] [blame] | 9364 | sigaction siginterrupt sigrelse snprintf strftime strlcpy \ |
Michael W. Hudson | 34f20ea | 2002-05-27 15:08:24 +0000 | [diff] [blame] | 9365 | sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Martin v. Löwis | 113a085 | 2009-05-29 17:25:39 +0000 | [diff] [blame] | 9366 | truncate uname unsetenv utimes waitpid wait3 wait4 \ |
| 9367 | wcscoll wcsftime wcsxfrm _getpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9368 | do : |
| 9369 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 9370 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9371 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9372 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9373 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 9374 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 9375 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 9376 | fi |
| 9377 | done |
| 9378 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 9379 | |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9380 | # For some functions, having a definition is not sufficient, since |
| 9381 | # we want to take their address. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9382 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chroot" >&5 |
| 9383 | $as_echo_n "checking for chroot... " >&6; } |
| 9384 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9385 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9386 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9387 | int |
| 9388 | main () |
| 9389 | { |
| 9390 | void *x=chroot |
| 9391 | ; |
| 9392 | return 0; |
| 9393 | } |
| 9394 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9395 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9396 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9397 | $as_echo "#define HAVE_CHROOT 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9398 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9399 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9400 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9401 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9403 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9404 | |
| 9405 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9406 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9407 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for link" >&5 |
| 9408 | $as_echo_n "checking for link... " >&6; } |
| 9409 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9410 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9411 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9412 | int |
| 9413 | main () |
| 9414 | { |
| 9415 | void *x=link |
| 9416 | ; |
| 9417 | return 0; |
| 9418 | } |
| 9419 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9420 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9421 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9422 | $as_echo "#define HAVE_LINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9423 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9425 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9426 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9428 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9429 | |
| 9430 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9431 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9432 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for symlink" >&5 |
| 9433 | $as_echo_n "checking for symlink... " >&6; } |
| 9434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9435 | /* end confdefs.h. */ |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9436 | #include <unistd.h> |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9437 | int |
| 9438 | main () |
| 9439 | { |
| 9440 | void *x=symlink |
| 9441 | ; |
| 9442 | return 0; |
| 9443 | } |
| 9444 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9445 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9446 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9447 | $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9448 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9449 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9450 | $as_echo "yes" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9451 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9452 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9453 | $as_echo "no" >&6; } |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9454 | |
| 9455 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9456 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9457 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fchdir" >&5 |
| 9458 | $as_echo_n "checking for fchdir... " >&6; } |
| 9459 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9460 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9461 | #include <unistd.h> |
| 9462 | int |
| 9463 | main () |
| 9464 | { |
| 9465 | void *x=fchdir |
| 9466 | ; |
| 9467 | return 0; |
| 9468 | } |
| 9469 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9470 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9471 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9472 | $as_echo "#define HAVE_FCHDIR 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9473 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9474 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9475 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9476 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9477 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9478 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9479 | |
| 9480 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9481 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9482 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fsync" >&5 |
| 9483 | $as_echo_n "checking for fsync... " >&6; } |
| 9484 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9485 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9486 | #include <unistd.h> |
| 9487 | int |
| 9488 | main () |
| 9489 | { |
| 9490 | void *x=fsync |
| 9491 | ; |
| 9492 | return 0; |
| 9493 | } |
| 9494 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9495 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9496 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9497 | $as_echo "#define HAVE_FSYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9498 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9499 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9500 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9501 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9502 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9503 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9504 | |
| 9505 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9506 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9507 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fdatasync" >&5 |
| 9508 | $as_echo_n "checking for fdatasync... " >&6; } |
| 9509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9510 | /* end confdefs.h. */ |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9511 | #include <unistd.h> |
| 9512 | int |
| 9513 | main () |
| 9514 | { |
| 9515 | void *x=fdatasync |
| 9516 | ; |
| 9517 | return 0; |
| 9518 | } |
| 9519 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9520 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9521 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9522 | $as_echo "#define HAVE_FDATASYNC 1" >>confdefs.h |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9523 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9525 | $as_echo "yes" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9526 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9527 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9528 | $as_echo "no" >&6; } |
Martin v. Löwis | a64988c | 2003-09-20 15:30:20 +0000 | [diff] [blame] | 9529 | |
| 9530 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9531 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9532 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5 |
| 9533 | $as_echo_n "checking for epoll... " >&6; } |
| 9534 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9535 | /* end confdefs.h. */ |
| 9536 | #include <sys/epoll.h> |
| 9537 | int |
| 9538 | main () |
| 9539 | { |
| 9540 | void *x=epoll_create |
| 9541 | ; |
| 9542 | return 0; |
| 9543 | } |
| 9544 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9545 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | c8ad7cc | 2002-11-11 13:23:45 +0000 | [diff] [blame] | 9546 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9547 | $as_echo "#define HAVE_EPOLL 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9548 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9550 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9551 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9552 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9553 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9554 | |
| 9555 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9556 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9557 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5 |
| 9558 | $as_echo_n "checking for kqueue... " >&6; } |
| 9559 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9560 | /* end confdefs.h. */ |
| 9561 | |
| 9562 | #include <sys/types.h> |
| 9563 | #include <sys/event.h> |
| 9564 | |
| 9565 | int |
| 9566 | main () |
| 9567 | { |
| 9568 | int x=kqueue() |
| 9569 | ; |
| 9570 | return 0; |
| 9571 | } |
| 9572 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9573 | if ac_fn_c_try_compile "$LINENO"; then : |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9574 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9575 | $as_echo "#define HAVE_KQUEUE 1" >>confdefs.h |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9576 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9577 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9578 | $as_echo "yes" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9579 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9580 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9581 | $as_echo "no" >&6; } |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9582 | |
| 9583 | fi |
Christian Heimes | 4fbc72b | 2008-03-22 00:47:35 +0000 | [diff] [blame] | 9584 | 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] | 9585 | # On some systems (eg. FreeBSD 5), we would find a definition of the |
| 9586 | # functions ctermid_r, setgroups in the library, but no prototype |
| 9587 | # (e.g. because we use _XOPEN_SOURCE). See whether we can take their |
| 9588 | # address to avoid compiler warnings and potential miscompilations |
| 9589 | # because of the missing prototypes. |
| 9590 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9591 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ctermid_r" >&5 |
| 9592 | $as_echo_n "checking for ctermid_r... " >&6; } |
| 9593 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9594 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9595 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9596 | #include <stdio.h> |
| 9597 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9598 | int |
| 9599 | main () |
| 9600 | { |
| 9601 | void* p = ctermid_r |
| 9602 | ; |
| 9603 | return 0; |
| 9604 | } |
| 9605 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9606 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9607 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9608 | $as_echo "#define HAVE_CTERMID_R 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9609 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9611 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9612 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9613 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9614 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 9615 | |
| 9616 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9617 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 9618 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9619 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flock declaration" >&5 |
| 9620 | $as_echo_n "checking for flock declaration... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9621 | if ${ac_cv_flock_decl+:} false; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9622 | $as_echo_n "(cached) " >&6 |
| 9623 | else |
| 9624 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9625 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9626 | #include <sys/file.h> |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9627 | int |
| 9628 | main () |
| 9629 | { |
| 9630 | void* p = flock |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9631 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9632 | ; |
| 9633 | return 0; |
| 9634 | } |
| 9635 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9636 | if ac_fn_c_try_compile "$LINENO"; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9637 | ac_cv_flock_decl=yes |
| 9638 | else |
| 9639 | ac_cv_flock_decl=no |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9640 | |
| 9641 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9642 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9643 | |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9644 | fi |
| 9645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flock_decl" >&5 |
| 9646 | $as_echo "$ac_cv_flock_decl" >&6; } |
| 9647 | if test "x${ac_cv_flock_decl}" = xyes; then |
| 9648 | for ac_func in flock |
| 9649 | do : |
| 9650 | ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9651 | if test "x$ac_cv_func_flock" = xyes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9652 | cat >>confdefs.h <<_ACEOF |
| 9653 | #define HAVE_FLOCK 1 |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9654 | _ACEOF |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9655 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9656 | else |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9657 | { $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] | 9658 | $as_echo_n "checking for flock in -lbsd... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9659 | if ${ac_cv_lib_bsd_flock+:} false; then : |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9660 | $as_echo_n "(cached) " >&6 |
| 9661 | else |
| 9662 | ac_check_lib_save_LIBS=$LIBS |
| 9663 | LIBS="-lbsd $LIBS" |
| 9664 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 9665 | /* end confdefs.h. */ |
| 9666 | |
| 9667 | /* Override any GCC internal prototype to avoid an error. |
| 9668 | Use char because int might match the return type of a GCC |
| 9669 | builtin and then its argument prototype would still apply. */ |
| 9670 | #ifdef __cplusplus |
| 9671 | extern "C" |
| 9672 | #endif |
| 9673 | char flock (); |
| 9674 | int |
| 9675 | main () |
| 9676 | { |
| 9677 | return flock (); |
| 9678 | ; |
| 9679 | return 0; |
| 9680 | } |
| 9681 | _ACEOF |
| 9682 | if ac_fn_c_try_link "$LINENO"; then : |
| 9683 | ac_cv_lib_bsd_flock=yes |
| 9684 | else |
| 9685 | ac_cv_lib_bsd_flock=no |
| 9686 | fi |
| 9687 | rm -f core conftest.err conftest.$ac_objext \ |
| 9688 | conftest$ac_exeext conftest.$ac_ext |
| 9689 | LIBS=$ac_check_lib_save_LIBS |
| 9690 | fi |
| 9691 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_flock" >&5 |
| 9692 | $as_echo "$ac_cv_lib_bsd_flock" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9693 | if test "x$ac_cv_lib_bsd_flock" = xyes; then : |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9694 | $as_echo "#define HAVE_FLOCK 1" >>confdefs.h |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9695 | |
| 9696 | |
| 9697 | $as_echo "#define FLOCK_NEEDS_LIBBSD 1" >>confdefs.h |
| 9698 | |
| 9699 | |
| 9700 | fi |
| 9701 | |
| 9702 | |
| 9703 | fi |
Antoine Pitrou | a4e4ae2 | 2010-09-10 18:39:00 +0000 | [diff] [blame] | 9704 | done |
| 9705 | |
Antoine Pitrou | a300007 | 2010-09-07 14:52:42 +0000 | [diff] [blame] | 9706 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9707 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9708 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize" >&5 |
| 9709 | $as_echo_n "checking for getpagesize... " >&6; } |
| 9710 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9711 | /* end confdefs.h. */ |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9712 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9713 | #include <unistd.h> |
| 9714 | |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9715 | int |
| 9716 | main () |
| 9717 | { |
| 9718 | void* p = getpagesize |
| 9719 | ; |
| 9720 | return 0; |
| 9721 | } |
| 9722 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9723 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9724 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9725 | $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9726 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 9727 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9728 | $as_echo "yes" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9729 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9731 | $as_echo "no" >&6; } |
Martin v. Löwis | f26d63b | 2003-03-30 17:23:49 +0000 | [diff] [blame] | 9732 | |
| 9733 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9734 | 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] | 9735 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9736 | for ac_prog in true |
| 9737 | do |
| 9738 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 9739 | set dummy $ac_prog; ac_word=$2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
| 9741 | $as_echo_n "checking for $ac_word... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9742 | if ${ac_cv_prog_TRUE+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9743 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9744 | else |
| 9745 | if test -n "$TRUE"; then |
| 9746 | ac_cv_prog_TRUE="$TRUE" # Let the user override the test. |
| 9747 | else |
| 9748 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
| 9749 | for as_dir in $PATH |
| 9750 | do |
| 9751 | IFS=$as_save_IFS |
| 9752 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9753 | for ac_exec_ext in '' $ac_executable_extensions; do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9754 | 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] | 9755 | ac_cv_prog_TRUE="$ac_prog" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9756 | $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] | 9757 | break 2 |
| 9758 | fi |
| 9759 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9760 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9761 | IFS=$as_save_IFS |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9762 | |
| 9763 | fi |
| 9764 | fi |
| 9765 | TRUE=$ac_cv_prog_TRUE |
| 9766 | if test -n "$TRUE"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9767 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TRUE" >&5 |
| 9768 | $as_echo "$TRUE" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9769 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9770 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 9771 | $as_echo "no" >&6; } |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9772 | fi |
| 9773 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9774 | |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9775 | test -n "$TRUE" && break |
| 9776 | done |
| 9777 | test -n "$TRUE" || TRUE="/bin/true" |
| 9778 | |
| 9779 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9780 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lc" >&5 |
| 9781 | $as_echo_n "checking for inet_aton in -lc... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9782 | if ${ac_cv_lib_c_inet_aton+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9783 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9784 | else |
| 9785 | ac_check_lib_save_LIBS=$LIBS |
| 9786 | LIBS="-lc $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9787 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9788 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9789 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9790 | /* Override any GCC internal prototype to avoid an error. |
| 9791 | Use char because int might match the return type of a GCC |
| 9792 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9793 | #ifdef __cplusplus |
| 9794 | extern "C" |
| 9795 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9796 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9797 | int |
| 9798 | main () |
| 9799 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9800 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9801 | ; |
| 9802 | return 0; |
| 9803 | } |
| 9804 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9805 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9806 | ac_cv_lib_c_inet_aton=yes |
| 9807 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9808 | ac_cv_lib_c_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9809 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9810 | rm -f core conftest.err conftest.$ac_objext \ |
| 9811 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9812 | LIBS=$ac_check_lib_save_LIBS |
| 9813 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_inet_aton" >&5 |
| 9815 | $as_echo "$ac_cv_lib_c_inet_aton" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9816 | if test "x$ac_cv_lib_c_inet_aton" = xyes; then : |
Martin v. Löwis | 4ee6eef | 2003-05-26 05:37:51 +0000 | [diff] [blame] | 9817 | $ac_cv_prog_TRUE |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9818 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9819 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5 |
| 9820 | $as_echo_n "checking for inet_aton in -lresolv... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9821 | if ${ac_cv_lib_resolv_inet_aton+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9822 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9823 | else |
| 9824 | ac_check_lib_save_LIBS=$LIBS |
| 9825 | LIBS="-lresolv $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9826 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 9827 | /* end confdefs.h. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9828 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9829 | /* Override any GCC internal prototype to avoid an error. |
| 9830 | Use char because int might match the return type of a GCC |
| 9831 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9832 | #ifdef __cplusplus |
| 9833 | extern "C" |
| 9834 | #endif |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9835 | char inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9836 | int |
| 9837 | main () |
| 9838 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9839 | return inet_aton (); |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9840 | ; |
| 9841 | return 0; |
| 9842 | } |
| 9843 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9844 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9845 | ac_cv_lib_resolv_inet_aton=yes |
| 9846 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9847 | ac_cv_lib_resolv_inet_aton=no |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9848 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9849 | rm -f core conftest.err conftest.$ac_objext \ |
| 9850 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9851 | LIBS=$ac_check_lib_save_LIBS |
| 9852 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9853 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5 |
| 9854 | $as_echo "$ac_cv_lib_resolv_inet_aton" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9855 | if test "x$ac_cv_lib_resolv_inet_aton" = xyes; then : |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 9856 | cat >>confdefs.h <<_ACEOF |
| 9857 | #define HAVE_LIBRESOLV 1 |
| 9858 | _ACEOF |
| 9859 | |
| 9860 | LIBS="-lresolv $LIBS" |
| 9861 | |
| 9862 | fi |
| 9863 | |
| 9864 | |
| 9865 | fi |
| 9866 | |
| 9867 | |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9868 | # On Tru64, chflags seems to be present, but calling it will |
| 9869 | # exit Python |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9870 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for chflags" >&5 |
| 9871 | $as_echo_n "checking for chflags... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9872 | if ${ac_cv_have_chflags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9873 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9874 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9875 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9876 | ac_cv_have_chflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9877 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9878 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9879 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9880 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9881 | #include <sys/stat.h> |
| 9882 | #include <unistd.h> |
| 9883 | int main(int argc, char*argv[]) |
| 9884 | { |
| 9885 | if(chflags(argv[0], 0) != 0) |
| 9886 | return 1; |
| 9887 | return 0; |
| 9888 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9889 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9890 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9891 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9892 | ac_cv_have_chflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9893 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9894 | ac_cv_have_chflags=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9895 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9896 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9897 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 9898 | fi |
| 9899 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9900 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9901 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9902 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_chflags" >&5 |
| 9903 | $as_echo "$ac_cv_have_chflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9904 | if test "$ac_cv_have_chflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9905 | ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9906 | if test "x$ac_cv_func_chflags" = xyes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9907 | ac_cv_have_chflags="yes" |
| 9908 | else |
| 9909 | ac_cv_have_chflags="no" |
| 9910 | fi |
| 9911 | |
| 9912 | fi |
| 9913 | if test "$ac_cv_have_chflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9914 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9915 | $as_echo "#define HAVE_CHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9916 | |
| 9917 | fi |
| 9918 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9919 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lchflags" >&5 |
| 9920 | $as_echo_n "checking for lchflags... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9921 | if ${ac_cv_have_lchflags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9922 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9923 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9924 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9925 | ac_cv_have_lchflags=cross |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9926 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9927 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9928 | /* end confdefs.h. */ |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9929 | [ |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9930 | #include <sys/stat.h> |
| 9931 | #include <unistd.h> |
| 9932 | int main(int argc, char*argv[]) |
| 9933 | { |
| 9934 | if(lchflags(argv[0], 0) != 0) |
| 9935 | return 1; |
| 9936 | return 0; |
| 9937 | } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9938 | ] |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9939 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9940 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9941 | ac_cv_have_lchflags=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9942 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9943 | ac_cv_have_lchflags=no |
Christian Heimes | d0764e2 | 2007-12-04 15:00:33 +0000 | [diff] [blame] | 9944 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9945 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 9946 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 9947 | fi |
| 9948 | |
| 9949 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9950 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9951 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_lchflags" >&5 |
| 9952 | $as_echo "$ac_cv_have_lchflags" >&6; } |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9953 | if test "$ac_cv_have_lchflags" = cross ; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9954 | ac_fn_c_check_func "$LINENO" "lchflags" "ac_cv_func_lchflags" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9955 | if test "x$ac_cv_func_lchflags" = xyes; then : |
Benjamin Peterson | ed68afa | 2010-01-30 19:36:43 +0000 | [diff] [blame] | 9956 | ac_cv_have_lchflags="yes" |
| 9957 | else |
| 9958 | ac_cv_have_lchflags="no" |
| 9959 | fi |
| 9960 | |
| 9961 | fi |
| 9962 | if test "$ac_cv_have_lchflags" = yes ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9963 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9964 | $as_echo "#define HAVE_LCHFLAGS 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 9965 | |
| 9966 | fi |
| 9967 | |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9968 | case $ac_sys_system/$ac_sys_release in |
| 9969 | Darwin/*) |
| 9970 | _CUR_CFLAGS="${CFLAGS}" |
| 9971 | _CUR_LDFLAGS="${LDFLAGS}" |
| 9972 | CFLAGS="${CFLAGS} -Wl,-search_paths_first" |
| 9973 | LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib" |
| 9974 | ;; |
| 9975 | esac |
| 9976 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9977 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateCopy in -lz" >&5 |
| 9978 | $as_echo_n "checking for inflateCopy in -lz... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 9979 | if ${ac_cv_lib_z_inflateCopy+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9980 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9981 | else |
| 9982 | ac_check_lib_save_LIBS=$LIBS |
| 9983 | LIBS="-lz $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 9984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9985 | /* end confdefs.h. */ |
| 9986 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9987 | /* Override any GCC internal prototype to avoid an error. |
| 9988 | Use char because int might match the return type of a GCC |
| 9989 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9990 | #ifdef __cplusplus |
| 9991 | extern "C" |
| 9992 | #endif |
| 9993 | char inflateCopy (); |
| 9994 | int |
| 9995 | main () |
| 9996 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 9997 | return inflateCopy (); |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 9998 | ; |
| 9999 | return 0; |
| 10000 | } |
| 10001 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10002 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10003 | ac_cv_lib_z_inflateCopy=yes |
| 10004 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10005 | ac_cv_lib_z_inflateCopy=no |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10006 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10007 | rm -f core conftest.err conftest.$ac_objext \ |
| 10008 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10009 | LIBS=$ac_check_lib_save_LIBS |
| 10010 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10011 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateCopy" >&5 |
| 10012 | $as_echo "$ac_cv_lib_z_inflateCopy" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10013 | if test "x$ac_cv_lib_z_inflateCopy" = xyes; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10014 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10015 | $as_echo "#define HAVE_ZLIB_COPY 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 10016 | |
| 10017 | fi |
| 10018 | |
| 10019 | |
| 10020 | case $ac_sys_system/$ac_sys_release in |
| 10021 | Darwin/*) |
| 10022 | CFLAGS="${_CUR_CFLAGS}" |
| 10023 | LDFLAGS="${_CUR_LDFLAGS}" |
| 10024 | ;; |
| 10025 | esac |
| 10026 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10027 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hstrerror" >&5 |
| 10028 | $as_echo_n "checking for hstrerror... " >&6; } |
| 10029 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10030 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10031 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10032 | #include <netdb.h> |
| 10033 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10034 | int |
| 10035 | main () |
| 10036 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10037 | void* p = hstrerror; hstrerror(0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10038 | ; |
| 10039 | return 0; |
| 10040 | } |
| 10041 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10042 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10043 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10044 | $as_echo "#define HAVE_HSTRERROR 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10045 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10047 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10048 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10049 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10050 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10051 | |
| 10052 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10053 | rm -f core conftest.err conftest.$ac_objext \ |
| 10054 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10055 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10056 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
| 10057 | $as_echo_n "checking for inet_aton... " >&6; } |
| 10058 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10059 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10060 | |
Martin v. Löwis | 86d6626 | 2006-02-17 08:40:11 +0000 | [diff] [blame] | 10061 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10062 | #include <sys/socket.h> |
| 10063 | #include <netinet/in.h> |
| 10064 | #include <arpa/inet.h> |
| 10065 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10066 | int |
| 10067 | main () |
| 10068 | { |
Martin v. Löwis | 95c419b | 2003-05-03 12:10:48 +0000 | [diff] [blame] | 10069 | void* p = inet_aton;inet_aton(0,0) |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10070 | ; |
| 10071 | return 0; |
| 10072 | } |
| 10073 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10074 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10075 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10076 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10077 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10078 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10079 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10080 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10081 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10082 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10083 | |
| 10084 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10085 | rm -f core conftest.err conftest.$ac_objext \ |
| 10086 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10087 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10088 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_pton" >&5 |
| 10089 | $as_echo_n "checking for inet_pton... " >&6; } |
| 10090 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10091 | /* end confdefs.h. */ |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10092 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10093 | #include <sys/types.h> |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10094 | #include <sys/socket.h> |
| 10095 | #include <netinet/in.h> |
| 10096 | #include <arpa/inet.h> |
| 10097 | |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10098 | int |
| 10099 | main () |
| 10100 | { |
| 10101 | void* p = inet_pton |
| 10102 | ; |
| 10103 | return 0; |
| 10104 | } |
| 10105 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10106 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10107 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10108 | $as_echo "#define HAVE_INET_PTON 1" >>confdefs.h |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10109 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10110 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10111 | $as_echo "yes" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10112 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10114 | $as_echo "no" >&6; } |
Martin v. Löwis | e941617 | 2003-05-03 10:12:45 +0000 | [diff] [blame] | 10115 | |
| 10116 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10117 | 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] | 10118 | |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10119 | # 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] | 10120 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setgroups" >&5 |
| 10121 | $as_echo_n "checking for setgroups... " >&6; } |
| 10122 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10123 | /* end confdefs.h. */ |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10124 | |
Martin v. Löwis | f2e488d | 2003-05-05 22:00:11 +0000 | [diff] [blame] | 10125 | #include <unistd.h> |
Martin v. Löwis | d6640d4 | 2003-07-06 09:29:52 +0000 | [diff] [blame] | 10126 | #ifdef HAVE_GRP_H |
| 10127 | #include <grp.h> |
| 10128 | #endif |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10129 | |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10130 | int |
| 10131 | main () |
| 10132 | { |
| 10133 | void* p = setgroups |
| 10134 | ; |
| 10135 | return 0; |
| 10136 | } |
| 10137 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10138 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10139 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10140 | $as_echo "#define HAVE_SETGROUPS 1" >>confdefs.h |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10141 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10142 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10143 | $as_echo "yes" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10144 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10146 | $as_echo "no" >&6; } |
Martin v. Löwis | d584368 | 2002-11-21 20:41:28 +0000 | [diff] [blame] | 10147 | |
| 10148 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10149 | 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] | 10150 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10151 | # check for openpty and forkpty |
| 10152 | |
| 10153 | for ac_func in openpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10154 | do : |
| 10155 | ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10156 | if test "x$ac_cv_func_openpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10157 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10158 | #define HAVE_OPENPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10159 | _ACEOF |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10160 | |
Guido van Rossum | d0b69ec | 2001-09-10 14:10:54 +0000 | [diff] [blame] | 10161 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10162 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5 |
| 10163 | $as_echo_n "checking for openpty in -lutil... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10164 | if ${ac_cv_lib_util_openpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10165 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10166 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10167 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10168 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10169 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10170 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10171 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10172 | /* Override any GCC internal prototype to avoid an error. |
| 10173 | Use char because int might match the return type of a GCC |
| 10174 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10175 | #ifdef __cplusplus |
| 10176 | extern "C" |
| 10177 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10178 | char openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10179 | int |
| 10180 | main () |
| 10181 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10182 | return openpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10183 | ; |
| 10184 | return 0; |
| 10185 | } |
| 10186 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10187 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10188 | ac_cv_lib_util_openpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10189 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10190 | ac_cv_lib_util_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10191 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10192 | rm -f core conftest.err conftest.$ac_objext \ |
| 10193 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10194 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10195 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10196 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5 |
| 10197 | $as_echo "$ac_cv_lib_util_openpty" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10198 | if test "x$ac_cv_lib_util_openpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10199 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10200 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10201 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5 |
| 10203 | $as_echo_n "checking for openpty in -lbsd... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10204 | if ${ac_cv_lib_bsd_openpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10205 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10206 | else |
| 10207 | ac_check_lib_save_LIBS=$LIBS |
| 10208 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10209 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10210 | /* end confdefs.h. */ |
| 10211 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10212 | /* Override any GCC internal prototype to avoid an error. |
| 10213 | Use char because int might match the return type of a GCC |
| 10214 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10215 | #ifdef __cplusplus |
| 10216 | extern "C" |
| 10217 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10218 | char openpty (); |
| 10219 | int |
| 10220 | main () |
| 10221 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10222 | return openpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10223 | ; |
| 10224 | return 0; |
| 10225 | } |
| 10226 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10227 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10228 | ac_cv_lib_bsd_openpty=yes |
| 10229 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10230 | ac_cv_lib_bsd_openpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10231 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10232 | rm -f core conftest.err conftest.$ac_objext \ |
| 10233 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10234 | LIBS=$ac_check_lib_save_LIBS |
| 10235 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10236 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5 |
| 10237 | $as_echo "$ac_cv_lib_bsd_openpty" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10238 | if test "x$ac_cv_lib_bsd_openpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10239 | $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10240 | LIBS="$LIBS -lbsd" |
| 10241 | fi |
| 10242 | |
| 10243 | |
| 10244 | fi |
| 10245 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10246 | |
| 10247 | fi |
| 10248 | done |
| 10249 | |
| 10250 | for ac_func in forkpty |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10251 | do : |
| 10252 | ac_fn_c_check_func "$LINENO" "forkpty" "ac_cv_func_forkpty" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10253 | if test "x$ac_cv_func_forkpty" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10254 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10255 | #define HAVE_FORKPTY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10256 | _ACEOF |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10257 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10258 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10259 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lutil" >&5 |
| 10260 | $as_echo_n "checking for forkpty in -lutil... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10261 | if ${ac_cv_lib_util_forkpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10262 | $as_echo_n "(cached) " >&6 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10263 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10264 | ac_check_lib_save_LIBS=$LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10265 | LIBS="-lutil $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10266 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10267 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10268 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10269 | /* Override any GCC internal prototype to avoid an error. |
| 10270 | Use char because int might match the return type of a GCC |
| 10271 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10272 | #ifdef __cplusplus |
| 10273 | extern "C" |
| 10274 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10275 | char forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10276 | int |
| 10277 | main () |
| 10278 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10279 | return forkpty (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10280 | ; |
| 10281 | return 0; |
| 10282 | } |
| 10283 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10284 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10285 | ac_cv_lib_util_forkpty=yes |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10286 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10287 | ac_cv_lib_util_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10288 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10289 | rm -f core conftest.err conftest.$ac_objext \ |
| 10290 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10291 | LIBS=$ac_check_lib_save_LIBS |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10292 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10293 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_forkpty" >&5 |
| 10294 | $as_echo "$ac_cv_lib_util_forkpty" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10295 | if test "x$ac_cv_lib_util_forkpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10296 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10297 | LIBS="$LIBS -lutil" |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10298 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for forkpty in -lbsd" >&5 |
| 10300 | $as_echo_n "checking for forkpty in -lbsd... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10301 | if ${ac_cv_lib_bsd_forkpty+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10302 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10303 | else |
| 10304 | ac_check_lib_save_LIBS=$LIBS |
| 10305 | LIBS="-lbsd $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10306 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10307 | /* end confdefs.h. */ |
| 10308 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10309 | /* Override any GCC internal prototype to avoid an error. |
| 10310 | Use char because int might match the return type of a GCC |
| 10311 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10312 | #ifdef __cplusplus |
| 10313 | extern "C" |
| 10314 | #endif |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10315 | char forkpty (); |
| 10316 | int |
| 10317 | main () |
| 10318 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10319 | return forkpty (); |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10320 | ; |
| 10321 | return 0; |
| 10322 | } |
| 10323 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10324 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10325 | ac_cv_lib_bsd_forkpty=yes |
| 10326 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10327 | ac_cv_lib_bsd_forkpty=no |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10328 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10329 | rm -f core conftest.err conftest.$ac_objext \ |
| 10330 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10331 | LIBS=$ac_check_lib_save_LIBS |
| 10332 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10333 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_forkpty" >&5 |
| 10334 | $as_echo "$ac_cv_lib_bsd_forkpty" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10335 | if test "x$ac_cv_lib_bsd_forkpty" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10336 | $as_echo "#define HAVE_FORKPTY 1" >>confdefs.h |
Martin v. Löwis | fd9a72a | 2006-01-08 10:07:33 +0000 | [diff] [blame] | 10337 | LIBS="$LIBS -lbsd" |
| 10338 | fi |
| 10339 | |
| 10340 | |
| 10341 | fi |
| 10342 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10343 | |
| 10344 | fi |
| 10345 | done |
| 10346 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10347 | |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10348 | # Stuff for expat. |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10349 | for ac_func in memmove |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10350 | do : |
| 10351 | ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10352 | if test "x$ac_cv_func_memmove" = xyes; then : |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10353 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10354 | #define HAVE_MEMMOVE 1 |
Christian Heimes | b186d00 | 2008-03-18 15:15:01 +0000 | [diff] [blame] | 10355 | _ACEOF |
| 10356 | |
| 10357 | fi |
| 10358 | done |
| 10359 | |
| 10360 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10361 | # check for long file support functions |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 10362 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10363 | do : |
| 10364 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 10365 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10366 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10367 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10368 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10369 | _ACEOF |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10370 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10371 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10372 | done |
| 10373 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10374 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10375 | ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2" |
| 10376 | if test "x$ac_cv_func_dup2" = xyes; then : |
| 10377 | $as_echo "#define HAVE_DUP2 1" >>confdefs.h |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10378 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10379 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10380 | case " $LIBOBJS " in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10381 | *" dup2.$ac_objext "* ) ;; |
| 10382 | *) LIBOBJS="$LIBOBJS dup2.$ac_objext" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10383 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10384 | esac |
| 10385 | |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10386 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10387 | |
| 10388 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" |
| 10389 | if test "x$ac_cv_func_getcwd" = xyes; then : |
| 10390 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h |
| 10391 | |
| 10392 | else |
| 10393 | case " $LIBOBJS " in |
| 10394 | *" getcwd.$ac_objext "* ) ;; |
| 10395 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
| 10396 | ;; |
| 10397 | esac |
| 10398 | |
| 10399 | fi |
| 10400 | |
| 10401 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" |
| 10402 | if test "x$ac_cv_func_strdup" = xyes; then : |
| 10403 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h |
| 10404 | |
| 10405 | else |
| 10406 | case " $LIBOBJS " in |
| 10407 | *" strdup.$ac_objext "* ) ;; |
| 10408 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" |
| 10409 | ;; |
| 10410 | esac |
| 10411 | |
| 10412 | fi |
Martin v. Löwis | 1142de3 | 2002-03-29 16:28:31 +0000 | [diff] [blame] | 10413 | |
| 10414 | |
| 10415 | for ac_func in getpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10416 | do : |
| 10417 | ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10418 | if test "x$ac_cv_func_getpgrp" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10419 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10420 | #define HAVE_GETPGRP 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10421 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10422 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10423 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10424 | #include <unistd.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10425 | int |
| 10426 | main () |
| 10427 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10428 | getpgrp(0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10429 | ; |
| 10430 | return 0; |
| 10431 | } |
| 10432 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10433 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10434 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10435 | $as_echo "#define GETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10436 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10437 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10438 | 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] | 10439 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10440 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10441 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10442 | |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10443 | for ac_func in setpgrp |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10444 | do : |
| 10445 | ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10446 | if test "x$ac_cv_func_setpgrp" = xyes; then : |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10447 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10448 | #define HAVE_SETPGRP 1 |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10449 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10450 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10451 | /* end confdefs.h. */ |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10452 | #include <unistd.h> |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10453 | int |
| 10454 | main () |
| 10455 | { |
| 10456 | setpgrp(0,0); |
| 10457 | ; |
| 10458 | return 0; |
| 10459 | } |
| 10460 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10461 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10462 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10463 | $as_echo "#define SETPGRP_HAVE_ARG 1" >>confdefs.h |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10464 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10465 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10466 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Jack Jansen | 150753c | 2003-03-29 22:07:47 +0000 | [diff] [blame] | 10467 | |
| 10468 | fi |
| 10469 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 10470 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10471 | for ac_func in gettimeofday |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10472 | do : |
| 10473 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10474 | if test "x$ac_cv_func_gettimeofday" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10475 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10476 | #define HAVE_GETTIMEOFDAY 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10477 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10478 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10479 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10480 | #include <sys/time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10481 | int |
| 10482 | main () |
| 10483 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10484 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10485 | ; |
| 10486 | return 0; |
| 10487 | } |
| 10488 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10489 | if ac_fn_c_try_compile "$LINENO"; then : |
| 10490 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10491 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10492 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10493 | $as_echo "#define GETTIMEOFDAY_NO_TZ 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10494 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10495 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10496 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10497 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 10498 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10499 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 10500 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10501 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10502 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10503 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for major" >&5 |
| 10504 | $as_echo_n "checking for major... " >&6; } |
| 10505 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10506 | /* end confdefs.h. */ |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10507 | |
Neal Norwitz | 6eb37f0 | 2003-02-23 23:28:15 +0000 | [diff] [blame] | 10508 | #if defined(MAJOR_IN_MKDEV) |
| 10509 | #include <sys/mkdev.h> |
| 10510 | #elif defined(MAJOR_IN_SYSMACROS) |
| 10511 | #include <sys/sysmacros.h> |
| 10512 | #else |
| 10513 | #include <sys/types.h> |
| 10514 | #endif |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10515 | |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10516 | int |
| 10517 | main () |
| 10518 | { |
| 10519 | |
| 10520 | makedev(major(0),minor(0)); |
| 10521 | |
| 10522 | ; |
| 10523 | return 0; |
| 10524 | } |
| 10525 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10526 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10527 | |
| 10528 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10529 | $as_echo "#define HAVE_DEVICE_MACROS 1" >>confdefs.h |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10530 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 10532 | $as_echo "yes" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10533 | |
| 10534 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10535 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10536 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 10537 | $as_echo "no" >&6; } |
Martin v. Löwis | dbe3f76 | 2002-10-10 14:27:30 +0000 | [diff] [blame] | 10538 | |
| 10539 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10540 | rm -f core conftest.err conftest.$ac_objext \ |
| 10541 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10542 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10543 | # 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] | 10544 | # for [no]getaddrinfo in netdb.h. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10545 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 |
| 10546 | $as_echo_n "checking for getaddrinfo... " >&6; } |
| 10547 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10548 | /* end confdefs.h. */ |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10549 | |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10550 | #include <sys/types.h> |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10551 | #include <sys/socket.h> |
| 10552 | #include <netdb.h> |
Martin v. Löwis | c010b6d | 2001-11-09 17:50:52 +0000 | [diff] [blame] | 10553 | #include <stdio.h> |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10554 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10555 | int |
| 10556 | main () |
| 10557 | { |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10558 | getaddrinfo(NULL, NULL, NULL, NULL); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10559 | ; |
| 10560 | return 0; |
| 10561 | } |
| 10562 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10563 | if ac_fn_c_try_link "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10564 | have_getaddrinfo=yes |
| 10565 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10566 | have_getaddrinfo=no |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10567 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10568 | rm -f core conftest.err conftest.$ac_objext \ |
| 10569 | conftest$ac_exeext conftest.$ac_ext |
| 10570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_getaddrinfo" >&5 |
| 10571 | $as_echo "$have_getaddrinfo" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10572 | if test $have_getaddrinfo = yes |
| 10573 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking getaddrinfo bug" >&5 |
| 10575 | $as_echo_n "checking getaddrinfo bug... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10576 | if ${ac_cv_buggy_getaddrinfo+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10577 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10578 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10579 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10580 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10581 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 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 | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10584 | |
| 10585 | #include <sys/types.h> |
| 10586 | #include <netdb.h> |
| 10587 | #include <string.h> |
| 10588 | #include <sys/socket.h> |
| 10589 | #include <netinet/in.h> |
| 10590 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10591 | int main() |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10592 | { |
| 10593 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 10594 | struct addrinfo hints, *ai, *aitop; |
| 10595 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 10596 | |
| 10597 | for (passive = 0; passive <= 1; passive++) { |
| 10598 | memset(&hints, 0, sizeof(hints)); |
| 10599 | hints.ai_family = AF_UNSPEC; |
| 10600 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 10601 | hints.ai_socktype = SOCK_STREAM; |
Hye-Shik Chang | 54f9439 | 2004-04-14 07:55:31 +0000 | [diff] [blame] | 10602 | hints.ai_protocol = IPPROTO_TCP; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10603 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 10604 | (void)gai_strerror(gaierr); |
| 10605 | goto bad; |
| 10606 | } |
| 10607 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 10608 | if (ai->ai_addr == NULL || |
| 10609 | ai->ai_addrlen == 0 || |
| 10610 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 10611 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 10612 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 10613 | goto bad; |
| 10614 | } |
| 10615 | switch (ai->ai_family) { |
| 10616 | case AF_INET: |
| 10617 | if (strcmp(strport, "54321") != 0) { |
| 10618 | goto bad; |
| 10619 | } |
| 10620 | if (passive) { |
| 10621 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 10622 | goto bad; |
| 10623 | } |
| 10624 | } else { |
| 10625 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 10626 | goto bad; |
| 10627 | } |
| 10628 | } |
| 10629 | inet4++; |
| 10630 | break; |
| 10631 | case AF_INET6: |
| 10632 | if (strcmp(strport, "54321") != 0) { |
| 10633 | goto bad; |
| 10634 | } |
| 10635 | if (passive) { |
| 10636 | if (strcmp(straddr, "::") != 0) { |
| 10637 | goto bad; |
| 10638 | } |
| 10639 | } else { |
| 10640 | if (strcmp(straddr, "::1") != 0) { |
| 10641 | goto bad; |
| 10642 | } |
| 10643 | } |
| 10644 | inet6++; |
| 10645 | break; |
| 10646 | case AF_UNSPEC: |
| 10647 | goto bad; |
| 10648 | break; |
| 10649 | default: |
| 10650 | /* another family support? */ |
| 10651 | break; |
| 10652 | } |
| 10653 | } |
| 10654 | } |
| 10655 | |
| 10656 | if (!(inet4 == 0 || inet4 == 2)) |
| 10657 | goto bad; |
| 10658 | if (!(inet6 == 0 || inet6 == 2)) |
| 10659 | goto bad; |
| 10660 | |
| 10661 | if (aitop) |
| 10662 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10663 | return 0; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10664 | |
| 10665 | bad: |
| 10666 | if (aitop) |
| 10667 | freeaddrinfo(aitop); |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10668 | return 1; |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10669 | } |
| 10670 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10671 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10672 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10673 | ac_cv_buggy_getaddrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10674 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10675 | ac_cv_buggy_getaddrinfo=yes |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10676 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10677 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 10678 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10679 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10680 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10681 | fi |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10682 | |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10683 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10684 | |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 10685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_buggy_getaddrinfo" >&5 |
| 10686 | $as_echo "$ac_cv_buggy_getaddrinfo" >&6; } |
| 10687 | |
Mark Dickinson | 2df5d28 | 2009-12-31 21:22:50 +0000 | [diff] [blame] | 10688 | if test $have_getaddrinfo = no -o "$ac_cv_buggy_getaddrinfo" = yes |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 10689 | then |
| 10690 | if test $ipv6 = yes |
| 10691 | then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10692 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 10693 | echo ' or you can specify "--disable-ipv6"'. |
| 10694 | exit 1 |
| 10695 | fi |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10696 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10697 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10698 | $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 861a65b | 2001-10-24 14:36:00 +0000 | [diff] [blame] | 10699 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10700 | fi |
Benjamin Peterson | d4694ed | 2010-11-01 01:44:30 +0000 | [diff] [blame] | 10701 | |
Jack Jansen | 9a66b6d | 2001-08-08 13:56:14 +0000 | [diff] [blame] | 10702 | for ac_func in getnameinfo |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10703 | do : |
| 10704 | ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10705 | if test "x$ac_cv_func_getnameinfo" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10706 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10707 | #define HAVE_GETNAMEINFO 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10708 | _ACEOF |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10709 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10710 | fi |
| 10711 | done |
| 10712 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10713 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10714 | # checks for structures |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10715 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
| 10716 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10717 | if ${ac_cv_header_time+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10718 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10719 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10720 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10721 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10722 | #include <sys/types.h> |
| 10723 | #include <sys/time.h> |
| 10724 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10725 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10726 | int |
| 10727 | main () |
| 10728 | { |
| 10729 | if ((struct tm *) 0) |
| 10730 | return 0; |
| 10731 | ; |
| 10732 | return 0; |
| 10733 | } |
| 10734 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10735 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10736 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10737 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10738 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10739 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10740 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10741 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10742 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
| 10743 | $as_echo "$ac_cv_header_time" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10744 | if test $ac_cv_header_time = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10745 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10746 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10747 | |
| 10748 | fi |
| 10749 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
| 10751 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10752 | if ${ac_cv_struct_tm+:} false; 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 <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10759 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10760 | int |
| 10761 | main () |
| 10762 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10763 | struct tm tm; |
| 10764 | int *p = &tm.tm_sec; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10765 | return !p; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 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_struct_tm=time.h |
| 10772 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10773 | ac_cv_struct_tm=sys/time.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +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_struct_tm" >&5 |
| 10778 | $as_echo "$ac_cv_struct_tm" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10779 | if test $ac_cv_struct_tm = sys/time.h; 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 TM_IN_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 | 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] | 10786 | #include <$ac_cv_struct_tm> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10787 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10788 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10789 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10790 | |
| 10791 | cat >>confdefs.h <<_ACEOF |
| 10792 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 10793 | _ACEOF |
| 10794 | |
| 10795 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10796 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 10797 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10798 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 10799 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10800 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10801 | |
| 10802 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10803 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 10804 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10805 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10806 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10807 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10808 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10809 | fi |
| 10810 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10811 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10812 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10813 | _ACEOF |
| 10814 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 10816 | $as_echo_n "checking for tzname... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10817 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10818 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10819 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10820 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10821 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10822 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10823 | #if !HAVE_DECL_TZNAME |
| 10824 | extern char *tzname[]; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10825 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10826 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10827 | int |
| 10828 | main () |
| 10829 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10830 | return tzname[0][0]; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10831 | ; |
| 10832 | return 0; |
| 10833 | } |
| 10834 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10835 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10836 | ac_cv_var_tzname=yes |
| 10837 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10838 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10839 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10840 | rm -f core conftest.err conftest.$ac_objext \ |
| 10841 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10842 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10843 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 10844 | $as_echo "$ac_cv_var_tzname" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10845 | if test $ac_cv_var_tzname = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10846 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10847 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 10848 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10849 | fi |
| 10850 | fi |
| 10851 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10852 | ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10853 | if test "x$ac_cv_member_struct_stat_st_rdev" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10854 | |
| 10855 | cat >>confdefs.h <<_ACEOF |
| 10856 | #define HAVE_STRUCT_STAT_ST_RDEV 1 |
| 10857 | _ACEOF |
| 10858 | |
| 10859 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10860 | fi |
| 10861 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10862 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10863 | if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10864 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10865 | cat >>confdefs.h <<_ACEOF |
| 10866 | #define HAVE_STRUCT_STAT_ST_BLKSIZE 1 |
| 10867 | _ACEOF |
| 10868 | |
| 10869 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10870 | fi |
| 10871 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10872 | ac_fn_c_check_member "$LINENO" "struct stat" "st_flags" "ac_cv_member_struct_stat_st_flags" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10873 | if test "x$ac_cv_member_struct_stat_st_flags" = xyes; then : |
Hye-Shik Chang | 5f937a7 | 2005-06-02 13:09:30 +0000 | [diff] [blame] | 10874 | |
| 10875 | cat >>confdefs.h <<_ACEOF |
| 10876 | #define HAVE_STRUCT_STAT_ST_FLAGS 1 |
| 10877 | _ACEOF |
| 10878 | |
| 10879 | |
| 10880 | fi |
| 10881 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10882 | ac_fn_c_check_member "$LINENO" "struct stat" "st_gen" "ac_cv_member_struct_stat_st_gen" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10883 | if test "x$ac_cv_member_struct_stat_st_gen" = xyes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 10884 | |
| 10885 | cat >>confdefs.h <<_ACEOF |
| 10886 | #define HAVE_STRUCT_STAT_ST_GEN 1 |
| 10887 | _ACEOF |
| 10888 | |
| 10889 | |
| 10890 | fi |
| 10891 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10892 | ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtime" "ac_cv_member_struct_stat_st_birthtime" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10893 | if test "x$ac_cv_member_struct_stat_st_birthtime" = xyes; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 10894 | |
| 10895 | cat >>confdefs.h <<_ACEOF |
| 10896 | #define HAVE_STRUCT_STAT_ST_BIRTHTIME 1 |
| 10897 | _ACEOF |
| 10898 | |
| 10899 | |
| 10900 | fi |
| 10901 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10902 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10903 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 10904 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10905 | cat >>confdefs.h <<_ACEOF |
| 10906 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
| 10907 | _ACEOF |
| 10908 | |
| 10909 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10910 | $as_echo "#define HAVE_ST_BLOCKS 1" >>confdefs.h |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10911 | |
| 10912 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10913 | case " $LIBOBJS " in |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10914 | *" fileblocks.$ac_objext "* ) ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10915 | *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext" |
| 10916 | ;; |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 10917 | esac |
| 10918 | |
Guido van Rossum | 98bf58f | 2001-10-18 20:34:25 +0000 | [diff] [blame] | 10919 | fi |
| 10920 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 10921 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10922 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10923 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for time.h that defines altzone" >&5 |
| 10924 | $as_echo_n "checking for time.h that defines altzone... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10925 | if ${ac_cv_header_time_altzone+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10926 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10927 | else |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10928 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10929 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10930 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10931 | #include <time.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10932 | int |
| 10933 | main () |
| 10934 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10935 | return altzone; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10936 | ; |
| 10937 | return 0; |
| 10938 | } |
| 10939 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10940 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10941 | ac_cv_header_time_altzone=yes |
| 10942 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10943 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10944 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10945 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10946 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10947 | fi |
| 10948 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time_altzone" >&5 |
| 10950 | $as_echo "$ac_cv_header_time_altzone" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10951 | if test $ac_cv_header_time_altzone = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10952 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10953 | $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 10954 | |
| 10955 | fi |
| 10956 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 10957 | was_it_defined=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10958 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/select.h and sys/time.h may both be included" >&5 |
| 10959 | $as_echo_n "checking whether sys/select.h and sys/time.h may both be included... " >&6; } |
| 10960 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10961 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 10962 | |
| 10963 | #include <sys/types.h> |
| 10964 | #include <sys/select.h> |
| 10965 | #include <sys/time.h> |
| 10966 | |
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 | ; |
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 : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10976 | |
| 10977 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10978 | $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] | 10979 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 10980 | was_it_defined=yes |
| 10981 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10982 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10983 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $was_it_defined" >&5 |
| 10985 | $as_echo "$was_it_defined" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 10986 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10987 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for addrinfo" >&5 |
| 10988 | $as_echo_n "checking for addrinfo... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 10989 | if ${ac_cv_struct_addrinfo+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10990 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10991 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 10992 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 10993 | /* end confdefs.h. */ |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 10994 | #include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10995 | int |
| 10996 | main () |
| 10997 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 10998 | struct addrinfo a |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 10999 | ; |
| 11000 | return 0; |
| 11001 | } |
| 11002 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11003 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11004 | ac_cv_struct_addrinfo=yes |
| 11005 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11006 | ac_cv_struct_addrinfo=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11007 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11008 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11009 | fi |
| 11010 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11011 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_addrinfo" >&5 |
| 11012 | $as_echo "$ac_cv_struct_addrinfo" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11013 | if test $ac_cv_struct_addrinfo = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11014 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11015 | $as_echo "#define HAVE_ADDRINFO 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11016 | |
| 11017 | fi |
| 11018 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11019 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage" >&5 |
| 11020 | $as_echo_n "checking for sockaddr_storage... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11021 | if ${ac_cv_struct_sockaddr_storage+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11022 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11023 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11024 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11025 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11026 | |
| 11027 | # include <sys/types.h> |
| 11028 | # include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11029 | int |
| 11030 | main () |
| 11031 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11032 | struct sockaddr_storage s |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11033 | ; |
| 11034 | return 0; |
| 11035 | } |
| 11036 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11037 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11038 | ac_cv_struct_sockaddr_storage=yes |
| 11039 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11040 | ac_cv_struct_sockaddr_storage=no |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11041 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11042 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 11043 | fi |
| 11044 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11045 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_sockaddr_storage" >&5 |
| 11046 | $as_echo "$ac_cv_struct_sockaddr_storage" >&6; } |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11047 | if test $ac_cv_struct_sockaddr_storage = yes; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11048 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11049 | $as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11050 | |
| 11051 | fi |
| 11052 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11053 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11054 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11055 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
| 11056 | $as_echo_n "checking whether char is unsigned... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11057 | if ${ac_cv_c_char_unsigned+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11058 | $as_echo_n "(cached) " >&6 |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 11059 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11060 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11061 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11062 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11063 | int |
| 11064 | main () |
| 11065 | { |
| 11066 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
| 11067 | test_array [0] = 0 |
| 11068 | |
| 11069 | ; |
| 11070 | return 0; |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11071 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11072 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11073 | if ac_fn_c_try_compile "$LINENO"; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11074 | ac_cv_c_char_unsigned=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11075 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11076 | ac_cv_c_char_unsigned=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11077 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11078 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11079 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11080 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
| 11081 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11082 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11083 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11084 | |
| 11085 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11086 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11087 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
| 11088 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11089 | if ${ac_cv_c_const+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11090 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11091 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11092 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11093 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11094 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11095 | int |
| 11096 | main () |
| 11097 | { |
| 11098 | /* FIXME: Include the comments suggested by Paul. */ |
| 11099 | #ifndef __cplusplus |
| 11100 | /* Ultrix mips cc rejects this. */ |
| 11101 | typedef int charset[2]; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11102 | const charset cs; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11103 | /* SunOS 4.1.1 cc rejects this. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11104 | char const *const *pcpcc; |
| 11105 | char **ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11106 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 11107 | struct point {int x, y;}; |
| 11108 | static struct point const zero = {0,0}; |
| 11109 | /* AIX XL C 1.02.0.0 rejects this. |
| 11110 | It does not let you subtract one const X* pointer from another in |
| 11111 | an arm of an if-expression whose if-part is not a constant |
| 11112 | expression */ |
| 11113 | const char *g = "string"; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11114 | pcpcc = &g + (g ? g-g : 0); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11115 | /* HPUX 7.0 cc rejects these. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11116 | ++pcpcc; |
| 11117 | ppc = (char**) pcpcc; |
| 11118 | pcpcc = (char const *const *) ppc; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11119 | { /* SCO 3.2v4 cc rejects this. */ |
| 11120 | char *t; |
| 11121 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11122 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11123 | *t++ = 0; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11124 | if (s) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11125 | } |
| 11126 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
| 11127 | int x[] = {25, 17}; |
| 11128 | const int *foo = &x[0]; |
| 11129 | ++foo; |
| 11130 | } |
| 11131 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 11132 | typedef const int *iptr; |
| 11133 | iptr p = 0; |
| 11134 | ++p; |
| 11135 | } |
| 11136 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 11137 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 11138 | struct s { int j; const int *ap[3]; }; |
| 11139 | struct s *b; b->j = 5; |
| 11140 | } |
| 11141 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 11142 | const int foo = 10; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11143 | if (!foo) return 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11144 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11145 | return !cs[0] && !zero.x; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11146 | #endif |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11147 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11148 | ; |
| 11149 | return 0; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11150 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11151 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11152 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11153 | ac_cv_c_const=yes |
| 11154 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11155 | ac_cv_c_const=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11156 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11157 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11158 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11159 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
| 11160 | $as_echo "$ac_cv_c_const" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11161 | if test $ac_cv_c_const = no; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11162 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11163 | $as_echo "#define const /**/" >>confdefs.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11164 | |
| 11165 | fi |
| 11166 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11167 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11168 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11169 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
| 11170 | $as_echo_n "checking for working volatile... " >&6; } |
| 11171 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11172 | /* end confdefs.h. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11173 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11174 | int |
| 11175 | main () |
| 11176 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11177 | volatile int x; x = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11178 | ; |
| 11179 | return 0; |
| 11180 | } |
| 11181 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11182 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11183 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11184 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11185 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11186 | $as_echo "#define volatile /**/" >>confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11187 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11188 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11189 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11190 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11191 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11192 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11193 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11194 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working signed char" >&5 |
| 11196 | $as_echo_n "checking for working signed char... " >&6; } |
| 11197 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11198 | /* end confdefs.h. */ |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11199 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11200 | int |
| 11201 | main () |
| 11202 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11203 | signed char c; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11204 | ; |
| 11205 | return 0; |
| 11206 | } |
| 11207 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11208 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11209 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 11210 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11211 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11212 | $as_echo "#define signed /**/" >>confdefs.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11213 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11214 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11215 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11216 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11217 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11218 | $as_echo "$works" >&6; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11219 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11220 | have_prototypes=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prototypes" >&5 |
| 11222 | $as_echo_n "checking for prototypes... " >&6; } |
| 11223 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11224 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11225 | int foo(int x) { return 0; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11226 | int |
| 11227 | main () |
| 11228 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11229 | return foo(10); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11230 | ; |
| 11231 | return 0; |
| 11232 | } |
| 11233 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11234 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11235 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11236 | $as_echo "#define HAVE_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11237 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11238 | have_prototypes=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11239 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11240 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11241 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_prototypes" >&5 |
| 11242 | $as_echo "$have_prototypes" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11243 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11244 | works=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable length prototypes and stdarg.h" >&5 |
| 11246 | $as_echo_n "checking for variable length prototypes and stdarg.h... " >&6; } |
| 11247 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11248 | /* end confdefs.h. */ |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11249 | |
| 11250 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11251 | int foo(int x, ...) { |
| 11252 | va_list va; |
| 11253 | va_start(va, x); |
| 11254 | va_arg(va, int); |
| 11255 | va_arg(va, char *); |
| 11256 | va_arg(va, double); |
| 11257 | return 0; |
| 11258 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11259 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11260 | int |
| 11261 | main () |
| 11262 | { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 11263 | return foo(10, "", 3.14); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11264 | ; |
| 11265 | return 0; |
| 11266 | } |
| 11267 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11268 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11269 | |
| 11270 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11271 | $as_echo "#define HAVE_STDARG_PROTOTYPES 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11272 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11273 | works=yes |
| 11274 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11275 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11276 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $works" >&5 |
| 11278 | $as_echo "$works" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11279 | |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11280 | # check for socketpair |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair" >&5 |
| 11282 | $as_echo_n "checking for socketpair... " >&6; } |
| 11283 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11284 | /* end confdefs.h. */ |
| 11285 | |
| 11286 | #include <sys/types.h> |
| 11287 | #include <sys/socket.h> |
| 11288 | |
| 11289 | int |
| 11290 | main () |
| 11291 | { |
| 11292 | void *x=socketpair |
| 11293 | ; |
| 11294 | return 0; |
| 11295 | } |
| 11296 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11297 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11298 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11299 | $as_echo "#define HAVE_SOCKETPAIR 1" >>confdefs.h |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11300 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11301 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11302 | $as_echo "yes" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11303 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11304 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11305 | $as_echo "no" >&6; } |
Martin v. Löwis | d632050 | 2004-08-12 13:45:08 +0000 | [diff] [blame] | 11306 | |
| 11307 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11308 | 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] | 11309 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11310 | # check if sockaddr has sa_len member |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11311 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr has sa_len member" >&5 |
| 11312 | $as_echo_n "checking if sockaddr has sa_len member... " >&6; } |
| 11313 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11314 | /* end confdefs.h. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11315 | #include <sys/types.h> |
| 11316 | #include <sys/socket.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11317 | int |
| 11318 | main () |
| 11319 | { |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11320 | struct sockaddr x; |
| 11321 | x.sa_len = 0; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11322 | ; |
| 11323 | return 0; |
| 11324 | } |
| 11325 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11326 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11328 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11329 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11330 | $as_echo "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11331 | |
| 11332 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11333 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11334 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11335 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 11336 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11337 | 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] | 11338 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11339 | va_list_is_array=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11340 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_list is an array" >&5 |
| 11341 | $as_echo_n "checking whether va_list is an array... " >&6; } |
| 11342 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11343 | /* end confdefs.h. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11344 | |
| 11345 | #ifdef HAVE_STDARG_PROTOTYPES |
| 11346 | #include <stdarg.h> |
| 11347 | #else |
| 11348 | #include <varargs.h> |
| 11349 | #endif |
| 11350 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11351 | int |
| 11352 | main () |
| 11353 | { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11354 | va_list list1, list2; list1 = list2; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11355 | ; |
| 11356 | return 0; |
| 11357 | } |
| 11358 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11359 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11360 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11361 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11362 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11363 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11364 | $as_echo "#define VA_LIST_IS_ARRAY 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11365 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 11366 | va_list_is_array=yes |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 11367 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11368 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11369 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $va_list_is_array" >&5 |
| 11371 | $as_echo "$va_list_is_array" >&6; } |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11372 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11373 | # 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] | 11374 | |
| 11375 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11376 | ac_fn_c_check_func "$LINENO" "gethostbyname_r" "ac_cv_func_gethostbyname_r" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11377 | if test "x$ac_cv_func_gethostbyname_r" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11378 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11379 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Martin v. Löwis | 4ddc78a | 2006-01-29 09:53:44 +0000 | [diff] [blame] | 11380 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11381 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 6 args" >&5 |
| 11382 | $as_echo_n "checking gethostbyname_r with 6 args... " >&6; } |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11383 | OLD_CFLAGS=$CFLAGS |
| 11384 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11385 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11386 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11387 | |
| 11388 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11389 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11390 | int |
| 11391 | main () |
| 11392 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11393 | |
| 11394 | char *name; |
| 11395 | struct hostent *he, *res; |
| 11396 | char buffer[2048]; |
| 11397 | int buflen = 2048; |
| 11398 | int h_errnop; |
| 11399 | |
| 11400 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11401 | |
| 11402 | ; |
| 11403 | return 0; |
| 11404 | } |
| 11405 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11406 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11407 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11408 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11409 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11410 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11411 | $as_echo "#define HAVE_GETHOSTBYNAME_R_6_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11412 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11414 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11415 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11416 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11417 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11418 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11419 | $as_echo "no" >&6; } |
| 11420 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 5 args" >&5 |
| 11421 | $as_echo_n "checking gethostbyname_r with 5 args... " >&6; } |
| 11422 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11423 | /* end confdefs.h. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11424 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11425 | # include <netdb.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11426 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11427 | int |
| 11428 | main () |
| 11429 | { |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11430 | |
| 11431 | char *name; |
| 11432 | struct hostent *he; |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11433 | char buffer[2048]; |
| 11434 | int buflen = 2048; |
| 11435 | int h_errnop; |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11436 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11437 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11438 | |
| 11439 | ; |
| 11440 | return 0; |
| 11441 | } |
| 11442 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11443 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11444 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11445 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 11446 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11447 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11448 | $as_echo "#define HAVE_GETHOSTBYNAME_R_5_ARG 1" >>confdefs.h |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11449 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11450 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11451 | $as_echo "yes" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11452 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11453 | else |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11454 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11455 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11456 | $as_echo "no" >&6; } |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 11457 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking gethostbyname_r with 3 args" >&5 |
| 11458 | $as_echo_n "checking gethostbyname_r with 3 args... " >&6; } |
| 11459 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 11460 | /* end confdefs.h. */ |
| 11461 | |
| 11462 | # include <netdb.h> |
| 11463 | |
| 11464 | int |
| 11465 | main () |
| 11466 | { |
| 11467 | |
| 11468 | char *name; |
| 11469 | struct hostent *he; |
| 11470 | struct hostent_data data; |
| 11471 | |
| 11472 | (void) gethostbyname_r(name, he, &data); |
| 11473 | |
| 11474 | ; |
| 11475 | return 0; |
| 11476 | } |
| 11477 | _ACEOF |
| 11478 | if ac_fn_c_try_compile "$LINENO"; then : |
| 11479 | |
| 11480 | $as_echo "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h |
| 11481 | |
| 11482 | |
| 11483 | $as_echo "#define HAVE_GETHOSTBYNAME_R_3_ARG 1" >>confdefs.h |
| 11484 | |
| 11485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11486 | $as_echo "yes" >&6; } |
| 11487 | |
| 11488 | else |
| 11489 | |
| 11490 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11491 | $as_echo "no" >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11492 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11493 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11494 | 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] | 11495 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11496 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11497 | 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] | 11498 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11499 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11500 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11501 | CFLAGS=$OLD_CFLAGS |
| 11502 | |
| 11503 | else |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11504 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11505 | for ac_func in gethostbyname |
| 11506 | do : |
| 11507 | ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11508 | if test "x$ac_cv_func_gethostbyname" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11509 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11510 | #define HAVE_GETHOSTBYNAME 1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11511 | _ACEOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11512 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11513 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 11514 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11515 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11516 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 11517 | fi |
| 11518 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11519 | |
| 11520 | |
| 11521 | |
| 11522 | |
| 11523 | |
| 11524 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11525 | # checks for system services |
| 11526 | # (none yet) |
| 11527 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11528 | # Linux requires this for correct f.p. operations |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11529 | ac_fn_c_check_func "$LINENO" "__fpu_control" "ac_cv_func___fpu_control" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11530 | if test "x$ac_cv_func___fpu_control" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11531 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11532 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11533 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpu_control in -lieee" >&5 |
| 11534 | $as_echo_n "checking for __fpu_control in -lieee... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11535 | if ${ac_cv_lib_ieee___fpu_control+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11536 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11537 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11538 | ac_check_lib_save_LIBS=$LIBS |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11539 | LIBS="-lieee $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11540 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 11541 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11542 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11543 | /* Override any GCC internal prototype to avoid an error. |
| 11544 | Use char because int might match the return type of a GCC |
| 11545 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11546 | #ifdef __cplusplus |
| 11547 | extern "C" |
| 11548 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11549 | char __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11550 | int |
| 11551 | main () |
| 11552 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11553 | return __fpu_control (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11554 | ; |
| 11555 | return 0; |
| 11556 | } |
| 11557 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11558 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11559 | ac_cv_lib_ieee___fpu_control=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11560 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11561 | ac_cv_lib_ieee___fpu_control=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11562 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11563 | rm -f core conftest.err conftest.$ac_objext \ |
| 11564 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11565 | LIBS=$ac_check_lib_save_LIBS |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11566 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11567 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ieee___fpu_control" >&5 |
| 11568 | $as_echo "$ac_cv_lib_ieee___fpu_control" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11569 | if test "x$ac_cv_lib_ieee___fpu_control" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11570 | cat >>confdefs.h <<_ACEOF |
| 11571 | #define HAVE_LIBIEEE 1 |
| 11572 | _ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11573 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 11574 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 11575 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11576 | fi |
| 11577 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11578 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 11579 | fi |
| 11580 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 11581 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11582 | # Check for --with-fpectl |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11583 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-fpectl" >&5 |
| 11584 | $as_echo_n "checking for --with-fpectl... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11585 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11586 | # Check whether --with-fpectl was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11587 | if test "${with_fpectl+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11588 | withval=$with_fpectl; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11589 | if test "$withval" != no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11590 | then |
| 11591 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11592 | $as_echo "#define WANT_SIGFPE_HANDLER 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11593 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 11595 | $as_echo "yes" >&6; } |
| 11596 | else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11597 | $as_echo "no" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11598 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 11599 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11600 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 11601 | $as_echo "no" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11602 | fi |
| 11603 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11604 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11605 | # check for --with-libm=... |
| 11606 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11607 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 11608 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 11609 | *) LIBM=-lm |
| 11610 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11611 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libm=STRING" >&5 |
| 11612 | $as_echo_n "checking for --with-libm=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11613 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11614 | # Check whether --with-libm was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11615 | if test "${with_libm+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11616 | withval=$with_libm; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11617 | if test "$withval" = no |
| 11618 | then LIBM= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11619 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBM empty" >&5 |
| 11620 | $as_echo "force LIBM empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11621 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11622 | then LIBM=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11623 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBM=\"$withval\"" >&5 |
| 11624 | $as_echo "set LIBM=\"$withval\"" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11625 | 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] | 11626 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11627 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11628 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBM=\"$LIBM\"" >&5 |
| 11629 | $as_echo "default LIBM=\"$LIBM\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11630 | fi |
| 11631 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11632 | |
| 11633 | # check for --with-libc=... |
| 11634 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11635 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libc=STRING" >&5 |
| 11636 | $as_echo_n "checking for --with-libc=STRING... " >&6; } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11637 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11638 | # Check whether --with-libc was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11639 | if test "${with_libc+set}" = set; then : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11640 | withval=$with_libc; |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11641 | if test "$withval" = no |
| 11642 | then LIBC= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11643 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: force LIBC empty" >&5 |
| 11644 | $as_echo "force LIBC empty" >&6; } |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11645 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11646 | then LIBC=$withval |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: set LIBC=\"$withval\"" >&5 |
| 11648 | $as_echo "set LIBC=\"$withval\"" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11649 | 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] | 11650 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 11651 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: default LIBC=\"$LIBC\"" >&5 |
| 11653 | $as_echo "default LIBC=\"$LIBC\"" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 11654 | fi |
| 11655 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 11656 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11657 | # ************************************************** |
| 11658 | # * Check for various properties of floating point * |
| 11659 | # ************************************************** |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11660 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11661 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are little-endian IEEE 754 binary64" >&5 |
| 11662 | $as_echo_n "checking whether C doubles are little-endian IEEE 754 binary64... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11663 | if ${ac_cv_little_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11664 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11665 | else |
| 11666 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11667 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11668 | ac_cv_little_endian_double=no |
| 11669 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11670 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11671 | /* end confdefs.h. */ |
| 11672 | |
| 11673 | #include <string.h> |
| 11674 | int main() { |
| 11675 | double x = 9006104071832581.0; |
| 11676 | if (memcmp(&x, "\x05\x04\x03\x02\x01\xff\x3f\x43", 8) == 0) |
| 11677 | return 0; |
| 11678 | else |
| 11679 | return 1; |
| 11680 | } |
| 11681 | |
| 11682 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11683 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11684 | ac_cv_little_endian_double=yes |
| 11685 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11686 | ac_cv_little_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11687 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11688 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11689 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11690 | fi |
| 11691 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11692 | fi |
| 11693 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11694 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_little_endian_double" >&5 |
| 11695 | $as_echo "$ac_cv_little_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11696 | if test "$ac_cv_little_endian_double" = yes |
| 11697 | then |
| 11698 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11699 | $as_echo "#define DOUBLE_IS_LITTLE_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11700 | |
| 11701 | fi |
| 11702 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are big-endian IEEE 754 binary64" >&5 |
| 11704 | $as_echo_n "checking whether C doubles are big-endian IEEE 754 binary64... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11705 | if ${ac_cv_big_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11706 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11707 | else |
| 11708 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11709 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11710 | ac_cv_big_endian_double=no |
| 11711 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11712 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11713 | /* end confdefs.h. */ |
| 11714 | |
| 11715 | #include <string.h> |
| 11716 | int main() { |
| 11717 | double x = 9006104071832581.0; |
| 11718 | if (memcmp(&x, "\x43\x3f\xff\x01\x02\x03\x04\x05", 8) == 0) |
| 11719 | return 0; |
| 11720 | else |
| 11721 | return 1; |
| 11722 | } |
| 11723 | |
| 11724 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11725 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11726 | ac_cv_big_endian_double=yes |
| 11727 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11728 | ac_cv_big_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11729 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11730 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11731 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11732 | fi |
| 11733 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11734 | fi |
| 11735 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11736 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_big_endian_double" >&5 |
| 11737 | $as_echo "$ac_cv_big_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11738 | if test "$ac_cv_big_endian_double" = yes |
| 11739 | then |
| 11740 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11741 | $as_echo "#define DOUBLE_IS_BIG_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11742 | |
| 11743 | fi |
| 11744 | |
| 11745 | # Some ARM platforms use a mixed-endian representation for doubles. |
| 11746 | # While Python doesn't currently have full support for these platforms |
| 11747 | # (see e.g., issue 1762561), we can at least make sure that float <-> string |
| 11748 | # conversions work. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11749 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C doubles are ARM mixed-endian IEEE 754 binary64" >&5 |
| 11750 | $as_echo_n "checking whether C doubles are ARM mixed-endian IEEE 754 binary64... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11751 | if ${ac_cv_mixed_endian_double+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11752 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11753 | else |
| 11754 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11755 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11756 | ac_cv_mixed_endian_double=no |
| 11757 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11758 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11759 | /* end confdefs.h. */ |
| 11760 | |
| 11761 | #include <string.h> |
| 11762 | int main() { |
| 11763 | double x = 9006104071832581.0; |
| 11764 | if (memcmp(&x, "\x01\xff\x3f\x43\x05\x04\x03\x02", 8) == 0) |
| 11765 | return 0; |
| 11766 | else |
| 11767 | return 1; |
| 11768 | } |
| 11769 | |
| 11770 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11771 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11772 | ac_cv_mixed_endian_double=yes |
| 11773 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11774 | ac_cv_mixed_endian_double=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11775 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11776 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11777 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11778 | fi |
| 11779 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11780 | fi |
| 11781 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11782 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mixed_endian_double" >&5 |
| 11783 | $as_echo "$ac_cv_mixed_endian_double" >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11784 | if test "$ac_cv_mixed_endian_double" = yes |
| 11785 | then |
| 11786 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11787 | $as_echo "#define DOUBLE_IS_ARM_MIXED_ENDIAN_IEEE754 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11788 | |
| 11789 | fi |
| 11790 | |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11791 | # The short float repr introduced in Python 3.1 requires the |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 11792 | # correctly-rounded string <-> double conversion functions from |
Mark Dickinson | 7abf8d4 | 2009-04-18 20:17:52 +0000 | [diff] [blame] | 11793 | # 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] | 11794 | # 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] | 11795 | # 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] | 11796 | # using inline assembler to get and set the x87 FPU control word. |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11797 | |
| 11798 | # This inline assembler syntax may also work for suncc and icc, |
| 11799 | # so we try it on all platforms. |
| 11800 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11801 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use gcc inline assembler to get and set x87 control word" >&5 |
| 11802 | $as_echo_n "checking whether we can use gcc inline assembler to get and set x87 control word... " >&6; } |
| 11803 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11804 | /* end confdefs.h. */ |
| 11805 | |
| 11806 | int |
| 11807 | main () |
| 11808 | { |
| 11809 | |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11810 | unsigned short cw; |
| 11811 | __asm__ __volatile__ ("fnstcw %0" : "=m" (cw)); |
| 11812 | __asm__ __volatile__ ("fldcw %0" : : "m" (cw)); |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11813 | |
| 11814 | ; |
| 11815 | return 0; |
| 11816 | } |
| 11817 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11818 | if ac_fn_c_try_compile "$LINENO"; then : |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11819 | have_gcc_asm_for_x87=yes |
| 11820 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11821 | have_gcc_asm_for_x87=no |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11822 | fi |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11823 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gcc_asm_for_x87" >&5 |
| 11825 | $as_echo "$have_gcc_asm_for_x87" >&6; } |
Mark Dickinson | f4243f6 | 2009-11-15 13:47:27 +0000 | [diff] [blame] | 11826 | if test "$have_gcc_asm_for_x87" = yes |
| 11827 | then |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11828 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11829 | $as_echo "#define HAVE_GCC_ASM_FOR_X87 1" >>confdefs.h |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11830 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11831 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 11832 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11833 | # Detect whether system arithmetic is subject to x87-style double |
| 11834 | # rounding issues. The result of this test has little meaning on non |
| 11835 | # IEEE 754 platforms. On IEEE 754, test should return 1 if rounding |
| 11836 | # mode is round-to-nearest and double rounding issues are present, and |
| 11837 | # 0 otherwise. See http://bugs.python.org/issue2937 for more info. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11838 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for x87-style double rounding" >&5 |
| 11839 | $as_echo_n "checking for x87-style double rounding... " >&6; } |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11840 | # $BASECFLAGS may affect the result |
| 11841 | ac_save_cc="$CC" |
| 11842 | CC="$CC $BASECFLAGS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11843 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11844 | ac_cv_x87_double_rounding=no |
| 11845 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11846 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11847 | /* end confdefs.h. */ |
| 11848 | |
| 11849 | #include <stdlib.h> |
| 11850 | #include <math.h> |
| 11851 | int main() { |
| 11852 | volatile double x, y, z; |
| 11853 | /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */ |
| 11854 | x = 0.99999999999999989; /* 1-2**-53 */ |
| 11855 | y = 1./x; |
| 11856 | if (y != 1.) |
| 11857 | exit(0); |
| 11858 | /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */ |
| 11859 | x = 1e16; |
| 11860 | y = 2.99999; |
| 11861 | z = x + y; |
| 11862 | if (z != 1e16+4.) |
| 11863 | exit(0); |
| 11864 | /* both tests show evidence of double rounding */ |
| 11865 | exit(1); |
| 11866 | } |
| 11867 | |
| 11868 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11869 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11870 | ac_cv_x87_double_rounding=no |
| 11871 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11872 | ac_cv_x87_double_rounding=yes |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11873 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11874 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11875 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11876 | fi |
| 11877 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11878 | CC="$ac_save_cc" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_x87_double_rounding" >&5 |
| 11880 | $as_echo "$ac_cv_x87_double_rounding" >&6; } |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11881 | if test "$ac_cv_x87_double_rounding" = yes |
| 11882 | then |
| 11883 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11884 | $as_echo "#define X87_DOUBLE_ROUNDING 1" >>confdefs.h |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 11885 | |
| 11886 | fi |
| 11887 | |
Mark Dickinson | b08a53a | 2009-04-16 19:52:09 +0000 | [diff] [blame] | 11888 | # ************************************ |
| 11889 | # * Check for mathematical functions * |
| 11890 | # ************************************ |
| 11891 | |
| 11892 | LIBS_SAVE=$LIBS |
| 11893 | LIBS="$LIBS $LIBM" |
| 11894 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11895 | for ac_func in acosh asinh atanh copysign erf erfc expm1 finite gamma |
| 11896 | do : |
| 11897 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11898 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11899 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11900 | cat >>confdefs.h <<_ACEOF |
| 11901 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 11902 | _ACEOF |
| 11903 | |
| 11904 | fi |
| 11905 | done |
| 11906 | |
| 11907 | for ac_func in hypot lgamma log1p round tgamma |
| 11908 | do : |
| 11909 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
| 11910 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11911 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11912 | cat >>confdefs.h <<_ACEOF |
| 11913 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
| 11914 | _ACEOF |
| 11915 | |
| 11916 | fi |
| 11917 | done |
| 11918 | |
| 11919 | ac_fn_c_check_decl "$LINENO" "isinf" "ac_cv_have_decl_isinf" "#include <math.h> |
| 11920 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11921 | if test "x$ac_cv_have_decl_isinf" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11922 | ac_have_decl=1 |
| 11923 | else |
| 11924 | ac_have_decl=0 |
| 11925 | fi |
| 11926 | |
| 11927 | cat >>confdefs.h <<_ACEOF |
| 11928 | #define HAVE_DECL_ISINF $ac_have_decl |
| 11929 | _ACEOF |
| 11930 | ac_fn_c_check_decl "$LINENO" "isnan" "ac_cv_have_decl_isnan" "#include <math.h> |
| 11931 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11932 | if test "x$ac_cv_have_decl_isnan" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11933 | ac_have_decl=1 |
| 11934 | else |
| 11935 | ac_have_decl=0 |
| 11936 | fi |
| 11937 | |
| 11938 | cat >>confdefs.h <<_ACEOF |
| 11939 | #define HAVE_DECL_ISNAN $ac_have_decl |
| 11940 | _ACEOF |
| 11941 | ac_fn_c_check_decl "$LINENO" "isfinite" "ac_cv_have_decl_isfinite" "#include <math.h> |
| 11942 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11943 | if test "x$ac_cv_have_decl_isfinite" = xyes; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 11944 | ac_have_decl=1 |
| 11945 | else |
| 11946 | ac_have_decl=0 |
| 11947 | fi |
| 11948 | |
| 11949 | cat >>confdefs.h <<_ACEOF |
| 11950 | #define HAVE_DECL_ISFINITE $ac_have_decl |
| 11951 | _ACEOF |
| 11952 | |
| 11953 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11954 | # On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of |
| 11955 | # -0. on some architectures. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11956 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether tanh preserves the sign of zero" >&5 |
| 11957 | $as_echo_n "checking whether tanh preserves the sign of zero... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 11958 | if ${ac_cv_tanh_preserves_zero_sign+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11959 | $as_echo_n "(cached) " >&6 |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11960 | else |
| 11961 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11962 | if test "$cross_compiling" = yes; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11963 | ac_cv_tanh_preserves_zero_sign=no |
| 11964 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11965 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11966 | /* end confdefs.h. */ |
| 11967 | |
| 11968 | #include <math.h> |
| 11969 | #include <stdlib.h> |
| 11970 | int main() { |
| 11971 | /* return 0 if either negative zeros don't exist |
| 11972 | on this platform or if negative zeros exist |
| 11973 | and tanh(-0.) == -0. */ |
| 11974 | if (atan2(0., -1.) == atan2(-0., -1.) || |
| 11975 | atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0); |
| 11976 | else exit(1); |
| 11977 | } |
| 11978 | |
| 11979 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11980 | if ac_fn_c_try_run "$LINENO"; then : |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11981 | ac_cv_tanh_preserves_zero_sign=yes |
| 11982 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11983 | ac_cv_tanh_preserves_zero_sign=no |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11984 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11985 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 11986 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11987 | fi |
| 11988 | |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11989 | fi |
| 11990 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tanh_preserves_zero_sign" >&5 |
| 11992 | $as_echo "$ac_cv_tanh_preserves_zero_sign" >&6; } |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11993 | if test "$ac_cv_tanh_preserves_zero_sign" = yes |
| 11994 | then |
| 11995 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 11996 | $as_echo "#define TANH_PRESERVES_ZERO_SIGN 1" >>confdefs.h |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 11997 | |
| 11998 | fi |
| 11999 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12000 | if test "$ac_cv_func_log1p" = yes |
| 12001 | then |
| 12002 | # On some versions of AIX, log1p(-0.) returns 0. instead of |
| 12003 | # -0. See issue #9920. |
| 12004 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether log1p drops the sign of negative zero" >&5 |
| 12005 | $as_echo_n "checking whether log1p drops the sign of negative zero... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12006 | if ${ac_cv_log1p_drops_zero_sign+:} false; then : |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12007 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12008 | else |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12009 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12010 | if test "$cross_compiling" = yes; then : |
| 12011 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12012 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12013 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12014 | /* end confdefs.h. */ |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12015 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12016 | #include <math.h> |
| 12017 | #include <stdlib.h> |
| 12018 | int main() { |
| 12019 | /* Fail if the signs of log1p(-0.) and -0. can be |
| 12020 | distinguished. */ |
| 12021 | if (atan2(log1p(-0.), -1.) == atan2(-0., -1.)) |
| 12022 | return 0; |
| 12023 | else |
| 12024 | return 1; |
| 12025 | } |
| 12026 | |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12027 | _ACEOF |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12028 | if ac_fn_c_try_run "$LINENO"; then : |
| 12029 | ac_cv_log1p_drops_zero_sign=no |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12030 | else |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12031 | ac_cv_log1p_drops_zero_sign=yes |
| 12032 | fi |
| 12033 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12034 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12035 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12036 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12037 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12038 | |
Mark Dickinson | ec0d355 | 2010-11-20 10:29:12 +0000 | [diff] [blame] | 12039 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_log1p_drops_zero_sign" >&5 |
| 12040 | $as_echo "$ac_cv_log1p_drops_zero_sign" >&6; } |
| 12041 | fi |
| 12042 | if test "$ac_cv_log1p_drops_zero_sign" = yes |
| 12043 | then |
| 12044 | |
| 12045 | $as_echo "#define LOG1P_DROPS_ZERO_SIGN 1" >>confdefs.h |
| 12046 | |
| 12047 | fi |
Mark Dickinson | 3dc7c6a | 2009-01-04 15:09:02 +0000 | [diff] [blame] | 12048 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 12049 | LIBS=$LIBS_SAVE |
| 12050 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12051 | # For multiprocessing module, check that sem_open |
| 12052 | # actually works. For FreeBSD versions <= 7.2, |
| 12053 | # the kernel module that provides POSIX semaphores |
| 12054 | # isn't loaded by default, so an attempt to call |
| 12055 | # sem_open results in a 'Signal 12' error. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12056 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX semaphores are enabled" >&5 |
| 12057 | $as_echo_n "checking whether POSIX semaphores are enabled... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12058 | if ${ac_cv_posix_semaphores_enabled+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12059 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12060 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12061 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12062 | ac_cv_posix_semaphores_enabled=yes |
| 12063 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12064 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12065 | /* end confdefs.h. */ |
| 12066 | |
| 12067 | #include <unistd.h> |
| 12068 | #include <fcntl.h> |
| 12069 | #include <stdio.h> |
| 12070 | #include <semaphore.h> |
| 12071 | #include <sys/stat.h> |
| 12072 | |
| 12073 | int main(void) { |
| 12074 | sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0); |
| 12075 | if (a == SEM_FAILED) { |
| 12076 | perror("sem_open"); |
| 12077 | return 1; |
| 12078 | } |
| 12079 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12080 | sem_unlink("/autoconf"); |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12081 | return 0; |
| 12082 | } |
| 12083 | |
| 12084 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12085 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12086 | ac_cv_posix_semaphores_enabled=yes |
| 12087 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12088 | ac_cv_posix_semaphores_enabled=no |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12089 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12090 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12091 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12092 | fi |
| 12093 | |
| 12094 | |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12095 | fi |
| 12096 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_posix_semaphores_enabled" >&5 |
| 12098 | $as_echo "$ac_cv_posix_semaphores_enabled" >&6; } |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12099 | if test $ac_cv_posix_semaphores_enabled = no |
| 12100 | then |
| 12101 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12102 | $as_echo "#define POSIX_SEMAPHORES_NOT_ENABLED 1" >>confdefs.h |
Mark Dickinson | a614f04 | 2009-11-28 12:48:43 +0000 | [diff] [blame] | 12103 | |
| 12104 | fi |
| 12105 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12106 | # Multiprocessing check for broken sem_getvalue |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12107 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken sem_getvalue" >&5 |
| 12108 | $as_echo_n "checking for broken sem_getvalue... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12109 | if ${ac_cv_broken_sem_getvalue+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12110 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12111 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12112 | if test "$cross_compiling" = yes; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12113 | ac_cv_broken_sem_getvalue=yes |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12114 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12116 | /* end confdefs.h. */ |
| 12117 | |
| 12118 | #include <unistd.h> |
| 12119 | #include <fcntl.h> |
| 12120 | #include <stdio.h> |
| 12121 | #include <semaphore.h> |
| 12122 | #include <sys/stat.h> |
| 12123 | |
| 12124 | int main(void){ |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12125 | 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] | 12126 | int count; |
| 12127 | int res; |
| 12128 | if(a==SEM_FAILED){ |
| 12129 | perror("sem_open"); |
| 12130 | return 1; |
| 12131 | |
| 12132 | } |
| 12133 | res = sem_getvalue(a, &count); |
| 12134 | sem_close(a); |
Mark Dickinson | ba79b35 | 2009-12-13 21:10:57 +0000 | [diff] [blame] | 12135 | sem_unlink("/autocftw"); |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12136 | return res==-1 ? 1 : 0; |
| 12137 | } |
| 12138 | |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12139 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12140 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12141 | ac_cv_broken_sem_getvalue=no |
Mark Dickinson | 1068307 | 2009-04-18 21:18:19 +0000 | [diff] [blame] | 12142 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12143 | ac_cv_broken_sem_getvalue=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12144 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12145 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12146 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 12147 | fi |
| 12148 | |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 12149 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12150 | fi |
| 12151 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12152 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_sem_getvalue" >&5 |
| 12153 | $as_echo "$ac_cv_broken_sem_getvalue" >&6; } |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12154 | if test $ac_cv_broken_sem_getvalue = yes |
| 12155 | then |
| 12156 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12157 | $as_echo "#define HAVE_BROKEN_SEM_GETVALUE 1" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 12158 | |
| 12159 | fi |
| 12160 | |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12161 | # determine what size digit to use for Python's longs |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12162 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking digit size for Python's longs" >&5 |
| 12163 | $as_echo_n "checking digit size for Python's longs... " >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12164 | # Check whether --enable-big-digits was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12165 | if test "${enable_big_digits+set}" = set; then : |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12166 | enableval=$enable_big_digits; case $enable_big_digits in |
| 12167 | yes) |
| 12168 | enable_big_digits=30 ;; |
| 12169 | no) |
| 12170 | enable_big_digits=15 ;; |
| 12171 | 15|30) |
| 12172 | ;; |
| 12173 | *) |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12174 | 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] | 12175 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12176 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_big_digits" >&5 |
| 12177 | $as_echo "$enable_big_digits" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12178 | |
| 12179 | cat >>confdefs.h <<_ACEOF |
| 12180 | #define PYLONG_BITS_IN_DIGIT $enable_big_digits |
| 12181 | _ACEOF |
| 12182 | |
| 12183 | |
| 12184 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 12186 | $as_echo "no value specified" >&6; } |
Mark Dickinson | bd79264 | 2009-03-18 20:06:12 +0000 | [diff] [blame] | 12187 | fi |
| 12188 | |
| 12189 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12190 | # check for wchar.h |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12191 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12192 | if test "x$ac_cv_header_wchar_h" = xyes; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12193 | |
| 12194 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12195 | $as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12196 | |
Martin v. Löwis | c45929e | 2002-04-06 10:10:49 +0000 | [diff] [blame] | 12197 | wchar_h="yes" |
| 12198 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12199 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12200 | wchar_h="no" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12201 | |
| 12202 | fi |
| 12203 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12204 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12205 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12206 | # determine wchar_t size |
| 12207 | if test "$wchar_h" = yes |
| 12208 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12209 | # 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] | 12210 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects |
| 12211 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. |
| 12212 | # This bug is HP SR number 8606223364. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12213 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5 |
| 12214 | $as_echo_n "checking size of wchar_t... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12215 | if ${ac_cv_sizeof_wchar_t+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12216 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12217 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12218 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "#include <wchar.h> |
| 12219 | "; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12220 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12221 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12222 | if test "$ac_cv_type_wchar_t" = yes; then |
| 12223 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
| 12224 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12225 | as_fn_error 77 "cannot compute sizeof (wchar_t) |
| 12226 | See \`config.log' for more details" "$LINENO" 5; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12227 | else |
| 12228 | ac_cv_sizeof_wchar_t=0 |
| 12229 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12230 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12231 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12232 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12233 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5 |
| 12234 | $as_echo "$ac_cv_sizeof_wchar_t" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12235 | |
| 12236 | |
| 12237 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12238 | cat >>confdefs.h <<_ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12239 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12240 | _ACEOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12241 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12242 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12243 | fi |
| 12244 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UCS-4 tcl" >&5 |
| 12246 | $as_echo_n "checking for UCS-4 tcl... " >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12247 | have_ucs4_tcl=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12248 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12249 | /* end confdefs.h. */ |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12250 | |
| 12251 | #include <tcl.h> |
| 12252 | #if TCL_UTF_MAX != 6 |
| 12253 | # error "NOT UCS4_TCL" |
| 12254 | #endif |
| 12255 | int |
| 12256 | main () |
| 12257 | { |
| 12258 | |
| 12259 | ; |
| 12260 | return 0; |
| 12261 | } |
| 12262 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12263 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12264 | |
| 12265 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12266 | $as_echo "#define HAVE_UCS4_TCL 1" >>confdefs.h |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12267 | |
| 12268 | have_ucs4_tcl=yes |
| 12269 | |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12270 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12271 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_ucs4_tcl" >&5 |
| 12273 | $as_echo "$have_ucs4_tcl" >&6; } |
Martin v. Löwis | fa3bdea | 2003-09-04 18:50:54 +0000 | [diff] [blame] | 12274 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12275 | # check whether wchar_t is signed or not |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12276 | if test "$wchar_h" = yes |
| 12277 | then |
| 12278 | # check whether wchar_t is signed or not |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wchar_t is signed" >&5 |
| 12280 | $as_echo_n "checking whether wchar_t is signed... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12281 | if ${ac_cv_wchar_t_signed+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12282 | $as_echo_n "(cached) " >&6 |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12283 | else |
| 12284 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12285 | if test "$cross_compiling" = yes; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12286 | ac_cv_wchar_t_signed=yes |
| 12287 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12288 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12289 | /* end confdefs.h. */ |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12290 | |
| 12291 | #include <wchar.h> |
| 12292 | int main() |
| 12293 | { |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 12294 | /* Success: exit code 0 */ |
| 12295 | exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1); |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12296 | } |
| 12297 | |
| 12298 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12299 | if ac_fn_c_try_run "$LINENO"; then : |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12300 | ac_cv_wchar_t_signed=yes |
| 12301 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12302 | ac_cv_wchar_t_signed=no |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12303 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12304 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12305 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12306 | fi |
| 12307 | |
Marc-André Lemburg | d7160f8 | 2003-09-22 11:14:40 +0000 | [diff] [blame] | 12308 | fi |
| 12309 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12310 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_wchar_t_signed" >&5 |
| 12311 | $as_echo "$ac_cv_wchar_t_signed" >&6; } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12312 | fi |
| 12313 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12314 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type to use for str" >&5 |
| 12315 | $as_echo_n "checking what type to use for str... " >&6; } |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12316 | |
| 12317 | # Check whether --with-wide-unicode was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12318 | if test "${with_wide_unicode+set}" = set; then : |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12319 | withval=$with_wide_unicode; |
| 12320 | if test "$withval" != no |
| 12321 | then unicode_size="4" |
| 12322 | else unicode_size="2" |
| 12323 | fi |
| 12324 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12325 | else |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12326 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12327 | case "$have_ucs4_tcl" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12328 | yes) unicode_size="4";; |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12329 | *) unicode_size="2" ;; |
| 12330 | esac |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12331 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12332 | fi |
| 12333 | |
Martin v. Löwis | 0036cba | 2002-04-12 09:58:45 +0000 | [diff] [blame] | 12334 | |
| 12335 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12336 | case "$unicode_size" in |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12337 | 4) |
| 12338 | $as_echo "#define Py_UNICODE_SIZE 4" >>confdefs.h |
| 12339 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12340 | ABIFLAGS="${ABIFLAGS}u" |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12341 | ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12342 | *) $as_echo "#define Py_UNICODE_SIZE 2" >>confdefs.h |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12343 | ;; |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12344 | esac |
| 12345 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12346 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12347 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12348 | # wchar_t is only usable if it maps to an unsigned type |
| 12349 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \ |
Matthias Klose | 7dbeed7 | 2004-12-24 08:22:17 +0000 | [diff] [blame] | 12350 | -a "$ac_cv_wchar_t_signed" = "no" |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12351 | then |
| 12352 | PY_UNICODE_TYPE="wchar_t" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12353 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12354 | $as_echo "#define HAVE_USABLE_WCHAR_T 1" >>confdefs.h |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12355 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12356 | $as_echo "#define PY_UNICODE_TYPE wchar_t" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12357 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12358 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 12359 | then |
| 12360 | PY_UNICODE_TYPE="unsigned short" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12361 | $as_echo "#define PY_UNICODE_TYPE unsigned short" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12362 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12363 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 12364 | then |
| 12365 | PY_UNICODE_TYPE="unsigned long" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12366 | $as_echo "#define PY_UNICODE_TYPE unsigned long" >>confdefs.h |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12367 | |
Georg Brandl | 52d168a | 2008-01-07 18:10:24 +0000 | [diff] [blame] | 12368 | else |
| 12369 | PY_UNICODE_TYPE="no type found" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame] | 12370 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12371 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PY_UNICODE_TYPE" >&5 |
| 12372 | $as_echo "$PY_UNICODE_TYPE" >&6; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12373 | |
| 12374 | # check for endianness |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12375 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
| 12376 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12377 | if ${ac_cv_c_bigendian+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12378 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12379 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12380 | ac_cv_c_bigendian=unknown |
| 12381 | # See if we're dealing with a universal compiler. |
| 12382 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12383 | /* end confdefs.h. */ |
| 12384 | #ifndef __APPLE_CC__ |
| 12385 | not a universal capable compiler |
| 12386 | #endif |
| 12387 | typedef int dummy; |
| 12388 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12389 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12390 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12391 | |
| 12392 | # Check for potential -arch flags. It is not universal unless |
| 12393 | # there are at least two -arch flags with different values. |
| 12394 | ac_arch= |
| 12395 | ac_prev= |
| 12396 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do |
| 12397 | if test -n "$ac_prev"; then |
| 12398 | case $ac_word in |
| 12399 | i?86 | x86_64 | ppc | ppc64) |
| 12400 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then |
| 12401 | ac_arch=$ac_word |
| 12402 | else |
| 12403 | ac_cv_c_bigendian=universal |
| 12404 | break |
| 12405 | fi |
| 12406 | ;; |
| 12407 | esac |
| 12408 | ac_prev= |
| 12409 | elif test "x$ac_word" = "x-arch"; then |
| 12410 | ac_prev=arch |
| 12411 | fi |
| 12412 | done |
| 12413 | fi |
| 12414 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12415 | if test $ac_cv_c_bigendian = unknown; then |
| 12416 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 12417 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12418 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12419 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12420 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12421 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12422 | int |
| 12423 | main () |
| 12424 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12425 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
| 12426 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ |
| 12427 | && LITTLE_ENDIAN) |
| 12428 | bogus endian macros |
| 12429 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12430 | |
| 12431 | ; |
| 12432 | return 0; |
| 12433 | } |
| 12434 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12435 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12436 | # It does; now see whether it defined to BIG_ENDIAN or not. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12437 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12438 | /* end confdefs.h. */ |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12439 | #include <sys/types.h> |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12440 | #include <sys/param.h> |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12441 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12442 | int |
| 12443 | main () |
| 12444 | { |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12445 | #if BYTE_ORDER != BIG_ENDIAN |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12446 | not big endian |
| 12447 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12448 | |
| 12449 | ; |
| 12450 | return 0; |
| 12451 | } |
| 12452 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12453 | if ac_fn_c_try_compile "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12454 | ac_cv_c_bigendian=yes |
| 12455 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12456 | ac_cv_c_bigendian=no |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12457 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12458 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12459 | fi |
| 12460 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12461 | fi |
| 12462 | if test $ac_cv_c_bigendian = unknown; then |
| 12463 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). |
| 12464 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12465 | /* end confdefs.h. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12466 | #include <limits.h> |
| 12467 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12468 | int |
| 12469 | main () |
| 12470 | { |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12471 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
| 12472 | bogus endian macros |
| 12473 | #endif |
| 12474 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12475 | ; |
| 12476 | return 0; |
| 12477 | } |
| 12478 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12479 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12480 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
| 12481 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12482 | /* end confdefs.h. */ |
| 12483 | #include <limits.h> |
| 12484 | |
| 12485 | int |
| 12486 | main () |
| 12487 | { |
| 12488 | #ifndef _BIG_ENDIAN |
| 12489 | not big endian |
| 12490 | #endif |
| 12491 | |
| 12492 | ; |
| 12493 | return 0; |
| 12494 | } |
| 12495 | _ACEOF |
| 12496 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12497 | ac_cv_c_bigendian=yes |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12498 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12499 | ac_cv_c_bigendian=no |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12500 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12501 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12502 | fi |
| 12503 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 12504 | fi |
| 12505 | if test $ac_cv_c_bigendian = unknown; then |
| 12506 | # Compile a test program. |
| 12507 | if test "$cross_compiling" = yes; then : |
| 12508 | # Try to guess by grepping values from an object file. |
| 12509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 12510 | /* end confdefs.h. */ |
| 12511 | short int ascii_mm[] = |
| 12512 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; |
| 12513 | short int ascii_ii[] = |
| 12514 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; |
| 12515 | int use_ascii (int i) { |
| 12516 | return ascii_mm[i] + ascii_ii[i]; |
| 12517 | } |
| 12518 | short int ebcdic_ii[] = |
| 12519 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; |
| 12520 | short int ebcdic_mm[] = |
| 12521 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; |
| 12522 | int use_ebcdic (int i) { |
| 12523 | return ebcdic_mm[i] + ebcdic_ii[i]; |
| 12524 | } |
| 12525 | extern int foo; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12526 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12527 | int |
| 12528 | main () |
| 12529 | { |
| 12530 | return use_ascii (foo) == use_ebcdic (foo); |
| 12531 | ; |
| 12532 | return 0; |
| 12533 | } |
| 12534 | _ACEOF |
| 12535 | if ac_fn_c_try_compile "$LINENO"; then : |
| 12536 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
| 12537 | ac_cv_c_bigendian=yes |
| 12538 | fi |
| 12539 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then |
| 12540 | if test "$ac_cv_c_bigendian" = unknown; then |
| 12541 | ac_cv_c_bigendian=no |
| 12542 | else |
| 12543 | # finding both strings is unlikely to happen, but who knows? |
| 12544 | ac_cv_c_bigendian=unknown |
| 12545 | fi |
| 12546 | fi |
| 12547 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12548 | 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] | 12549 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12551 | /* end confdefs.h. */ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12552 | $ac_includes_default |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12553 | int |
| 12554 | main () |
| 12555 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12556 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12557 | /* Are we little or big endian? From Harbison&Steele. */ |
| 12558 | union |
| 12559 | { |
| 12560 | long int l; |
| 12561 | char c[sizeof (long int)]; |
| 12562 | } u; |
| 12563 | u.l = 1; |
| 12564 | return u.c[sizeof (long int) - 1] == 1; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12565 | |
| 12566 | ; |
| 12567 | return 0; |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12568 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12569 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12570 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12571 | ac_cv_c_bigendian=no |
| 12572 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12573 | ac_cv_c_bigendian=yes |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12574 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12575 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12576 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12577 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12578 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12579 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12580 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12581 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
| 12582 | $as_echo "$ac_cv_c_bigendian" >&6; } |
| 12583 | case $ac_cv_c_bigendian in #( |
| 12584 | yes) |
| 12585 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
| 12586 | ;; #( |
| 12587 | no) |
| 12588 | ;; #( |
| 12589 | universal) |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 12590 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12591 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
Benjamin Peterson | 8719ad5 | 2009-09-11 22:24:02 +0000 | [diff] [blame] | 12592 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12593 | ;; #( |
| 12594 | *) |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12595 | as_fn_error $? "unknown endianness |
Antoine Pitrou | c224458 | 2011-01-02 19:34:03 +0000 | [diff] [blame] | 12596 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12597 | esac |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 12598 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12599 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12600 | # ABI version string for Python extension modules. This appears between the |
| 12601 | # periods in shared library file names, e.g. foo.<SOABI>.so. It is calculated |
| 12602 | # from the following attributes which affect the ABI of this Python build (in |
| 12603 | # this order): |
| 12604 | # |
| 12605 | # * The Python implementation (always 'cpython-' for us) |
| 12606 | # * The major and minor version numbers |
| 12607 | # * --with-pydebug (adds a 'd') |
| 12608 | # * --with-pymalloc (adds a 'm') |
| 12609 | # * --with-wide-unicode (adds a 'u') |
| 12610 | # |
| 12611 | # 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] | 12612 | # would get a shared library ABI version tag of 'cpython-32dmu' and shared |
| 12613 | # libraries would be named 'foo.cpython-32dmu.so'. |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12614 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12615 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ABIFLAGS" >&5 |
| 12616 | $as_echo_n "checking ABIFLAGS... " >&6; } |
| 12617 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ABIFLAGS" >&5 |
| 12618 | $as_echo "$ABIFLAGS" >&6; } |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12619 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SOABI" >&5 |
| 12620 | $as_echo_n "checking SOABI... " >&6; } |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12621 | SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS} |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12622 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5 |
| 12623 | $as_echo "$SOABI" >&6; } |
| 12624 | |
Barry Warsaw | 8cf4eae | 2010-10-16 01:04:07 +0000 | [diff] [blame] | 12625 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5 |
| 12626 | $as_echo_n "checking LDVERSION... " >&6; } |
| 12627 | LDVERSION='$(VERSION)$(ABIFLAGS)' |
| 12628 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5 |
| 12629 | $as_echo "$LDVERSION" >&6; } |
| 12630 | |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12631 | # SO is the extension of shared libraries `(including the dot!) |
| 12632 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
| 12633 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5 |
| 12634 | $as_echo_n "checking SO... " >&6; } |
| 12635 | if test -z "$SO" |
| 12636 | then |
| 12637 | case $ac_sys_system in |
| 12638 | hp*|HP*) |
| 12639 | case `uname -m` in |
| 12640 | ia64) SO=.so;; |
| 12641 | *) SO=.sl;; |
| 12642 | esac |
| 12643 | ;; |
| 12644 | CYGWIN*) SO=.dll;; |
Barry Warsaw | 278266f | 2010-10-14 17:38:46 +0000 | [diff] [blame] | 12645 | Linux*|GNU*) |
| 12646 | SO=.${SOABI}.so;; |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12647 | *) SO=.so;; |
| 12648 | esac |
| 12649 | else |
| 12650 | # this might also be a termcap variable, see #610332 |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12651 | echo |
| 12652 | echo '=====================================================================' |
| 12653 | echo '+ +' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12654 | echo '+ WARNING: You have set SO in your environment. +' |
Benjamin Peterson | d7f73e9 | 2010-09-05 00:09:07 +0000 | [diff] [blame] | 12655 | echo '+ Do you really mean to change the extension for shared libraries? +' |
| 12656 | echo '+ Continuing in 10 seconds to let you to ponder. +' |
| 12657 | echo '+ +' |
| 12658 | echo '=====================================================================' |
Barry Warsaw | 35f3a2c | 2010-09-03 18:30:30 +0000 | [diff] [blame] | 12659 | sleep 10 |
| 12660 | fi |
| 12661 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5 |
| 12662 | $as_echo "$SO" >&6; } |
| 12663 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12664 | # Check whether right shifting a negative integer extends the sign bit |
| 12665 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12666 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5 |
| 12667 | $as_echo_n "checking whether right shift extends the sign bit... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12668 | if ${ac_cv_rshift_extends_sign+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12669 | $as_echo_n "(cached) " >&6 |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12670 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12671 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12672 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 12673 | ac_cv_rshift_extends_sign=yes |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12674 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12675 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12676 | /* end confdefs.h. */ |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12677 | |
| 12678 | int main() |
| 12679 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12680 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12681 | } |
| 12682 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12683 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12684 | if ac_fn_c_try_run "$LINENO"; then : |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12685 | ac_cv_rshift_extends_sign=yes |
| 12686 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12687 | ac_cv_rshift_extends_sign=no |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12688 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12689 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 12690 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12691 | fi |
| 12692 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12693 | fi |
| 12694 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12695 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rshift_extends_sign" >&5 |
| 12696 | $as_echo "$ac_cv_rshift_extends_sign" >&6; } |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 12697 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12698 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12699 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12700 | $as_echo "#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1" >>confdefs.h |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12701 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12702 | fi |
| 12703 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12704 | # check for getc_unlocked and related locking functions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12705 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getc_unlocked() and friends" >&5 |
| 12706 | $as_echo_n "checking for getc_unlocked() and friends... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12707 | if ${ac_cv_have_getc_unlocked+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12708 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12709 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12710 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12711 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12712 | /* end confdefs.h. */ |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12713 | #include <stdio.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12714 | int |
| 12715 | main () |
| 12716 | { |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12717 | |
| 12718 | FILE *f = fopen("/dev/null", "r"); |
| 12719 | flockfile(f); |
| 12720 | getc_unlocked(f); |
| 12721 | funlockfile(f); |
| 12722 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12723 | ; |
| 12724 | return 0; |
| 12725 | } |
| 12726 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12727 | if ac_fn_c_try_link "$LINENO"; then : |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12728 | ac_cv_have_getc_unlocked=yes |
| 12729 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12730 | ac_cv_have_getc_unlocked=no |
| 12731 | fi |
| 12732 | rm -f core conftest.err conftest.$ac_objext \ |
| 12733 | conftest$ac_exeext conftest.$ac_ext |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12734 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12735 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12736 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getc_unlocked" >&5 |
| 12737 | $as_echo "$ac_cv_have_getc_unlocked" >&6; } |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12738 | if test "$ac_cv_have_getc_unlocked" = yes |
| 12739 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12740 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12741 | $as_echo "#define HAVE_GETC_UNLOCKED 1" >>confdefs.h |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 12742 | |
| 12743 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 12744 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12745 | # check where readline lives |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 12746 | # save the value of LIBS so we don't actually link Python with readline |
| 12747 | LIBS_no_readline=$LIBS |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12748 | |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12749 | # On some systems we need to link readline to a termcap compatible |
| 12750 | # library. NOTE: Keep the precedence of listed libraries synchronised |
| 12751 | # with setup.py. |
| 12752 | py_cv_lib_readline=no |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link readline libs" >&5 |
| 12754 | $as_echo_n "checking how to link readline libs... " >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12755 | for py_libtermcap in "" ncursesw ncurses curses termcap; do |
| 12756 | if test -z "$py_libtermcap"; then |
| 12757 | READLINE_LIBS="-lreadline" |
| 12758 | else |
| 12759 | READLINE_LIBS="-lreadline -l$py_libtermcap" |
| 12760 | fi |
| 12761 | LIBS="$READLINE_LIBS $LIBS_no_readline" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12762 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12763 | /* end confdefs.h. */ |
| 12764 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12765 | /* Override any GCC internal prototype to avoid an error. |
| 12766 | Use char because int might match the return type of a GCC |
| 12767 | builtin and then its argument prototype would still apply. */ |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12768 | #ifdef __cplusplus |
| 12769 | extern "C" |
| 12770 | #endif |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12771 | char readline (); |
| 12772 | int |
| 12773 | main () |
| 12774 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12775 | return readline (); |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12776 | ; |
| 12777 | return 0; |
| 12778 | } |
| 12779 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12780 | if ac_fn_c_try_link "$LINENO"; then : |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12781 | py_cv_lib_readline=yes |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12782 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12783 | rm -f core conftest.err conftest.$ac_objext \ |
| 12784 | conftest$ac_exeext conftest.$ac_ext |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12785 | if test $py_cv_lib_readline = yes; then |
| 12786 | break |
| 12787 | fi |
| 12788 | done |
| 12789 | # Uncomment this line if you want to use READINE_LIBS in Makefile or scripts |
| 12790 | #AC_SUBST([READLINE_LIBS]) |
Gregory P. Smith | 3856c37 | 2008-09-07 19:24:00 +0000 | [diff] [blame] | 12791 | if test $py_cv_lib_readline = no; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
| 12793 | $as_echo "none" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12794 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINE_LIBS" >&5 |
| 12796 | $as_echo "$READLINE_LIBS" >&6; } |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12797 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12798 | $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12799 | |
Neal Norwitz | fe8e3d9 | 2006-01-07 21:07:20 +0000 | [diff] [blame] | 12800 | fi |
| 12801 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12802 | # check for readline 2.1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12803 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_callback_handler_install in -lreadline" >&5 |
| 12804 | $as_echo_n "checking for rl_callback_handler_install in -lreadline... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12805 | if ${ac_cv_lib_readline_rl_callback_handler_install+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12806 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12807 | else |
| 12808 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12809 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12810 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12811 | /* end confdefs.h. */ |
| 12812 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12813 | /* Override any GCC internal prototype to avoid an error. |
| 12814 | Use char because int might match the return type of a GCC |
| 12815 | builtin and then its argument prototype would still apply. */ |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12816 | #ifdef __cplusplus |
| 12817 | extern "C" |
| 12818 | #endif |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12819 | char rl_callback_handler_install (); |
| 12820 | int |
| 12821 | main () |
| 12822 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12823 | return rl_callback_handler_install (); |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12824 | ; |
| 12825 | return 0; |
| 12826 | } |
| 12827 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12828 | if ac_fn_c_try_link "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12829 | ac_cv_lib_readline_rl_callback_handler_install=yes |
| 12830 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12831 | ac_cv_lib_readline_rl_callback_handler_install=no |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12832 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12833 | rm -f core conftest.err conftest.$ac_objext \ |
| 12834 | conftest$ac_exeext conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12835 | LIBS=$ac_check_lib_save_LIBS |
| 12836 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12837 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5 |
| 12838 | $as_echo "$ac_cv_lib_readline_rl_callback_handler_install" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12839 | if test "x$ac_cv_lib_readline_rl_callback_handler_install" = xyes; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12840 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12841 | $as_echo "#define HAVE_RL_CALLBACK 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 12842 | |
| 12843 | fi |
| 12844 | |
| 12845 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12846 | # check for readline 2.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12847 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12848 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12849 | #include <readline/readline.h> |
| 12850 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12851 | if ac_fn_c_try_cpp "$LINENO"; then : |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12852 | have_readline=yes |
| 12853 | else |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12854 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 12855 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12856 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12857 | rm -f conftest.err conftest.i conftest.$ac_ext |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12858 | if test $have_readline = yes |
| 12859 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12860 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12861 | /* end confdefs.h. */ |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12862 | #include <readline/readline.h> |
| 12863 | |
| 12864 | _ACEOF |
| 12865 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12866 | $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] | 12867 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12868 | $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12869 | |
| 12870 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12871 | rm -f conftest* |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12872 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12873 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12874 | /* end confdefs.h. */ |
| 12875 | #include <readline/readline.h> |
| 12876 | |
| 12877 | _ACEOF |
| 12878 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12879 | $EGREP "extern int rl_completion_suppress_append;" >/dev/null 2>&1; then : |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12880 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12881 | $as_echo "#define HAVE_RL_COMPLETION_SUPPRESS_APPEND 1" >>confdefs.h |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12882 | |
| 12883 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 12884 | rm -f conftest* |
Antoine Pitrou | d513177 | 2009-10-26 19:22:14 +0000 | [diff] [blame] | 12885 | |
Guido van Rossum | faf5e4d | 2002-12-30 16:25:41 +0000 | [diff] [blame] | 12886 | fi |
| 12887 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12888 | # check for readline 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12889 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_pre_input_hook in -lreadline" >&5 |
| 12890 | $as_echo_n "checking for rl_pre_input_hook in -lreadline... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12891 | if ${ac_cv_lib_readline_rl_pre_input_hook+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12892 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 12893 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12894 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12895 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12896 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12897 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12898 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12899 | /* Override any GCC internal prototype to avoid an error. |
| 12900 | Use char because int might match the return type of a GCC |
| 12901 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12902 | #ifdef __cplusplus |
| 12903 | extern "C" |
| 12904 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12905 | char rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12906 | int |
| 12907 | main () |
| 12908 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12909 | return rl_pre_input_hook (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12910 | ; |
| 12911 | return 0; |
| 12912 | } |
| 12913 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12914 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12915 | ac_cv_lib_readline_rl_pre_input_hook=yes |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12916 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12917 | ac_cv_lib_readline_rl_pre_input_hook=no |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12918 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12919 | rm -f core conftest.err conftest.$ac_objext \ |
| 12920 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12921 | LIBS=$ac_check_lib_save_LIBS |
| 12922 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5 |
| 12924 | $as_echo "$ac_cv_lib_readline_rl_pre_input_hook" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12925 | if test "x$ac_cv_lib_readline_rl_pre_input_hook" = xyes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12926 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12927 | $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] | 12928 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12929 | fi |
| 12930 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 12931 | |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12932 | # also in 4.0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12933 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_display_matches_hook in -lreadline" >&5 |
| 12934 | $as_echo_n "checking for rl_completion_display_matches_hook in -lreadline... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12935 | if ${ac_cv_lib_readline_rl_completion_display_matches_hook+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12936 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12937 | else |
| 12938 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12939 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12940 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12941 | /* end confdefs.h. */ |
| 12942 | |
| 12943 | /* Override any GCC internal prototype to avoid an error. |
| 12944 | Use char because int might match the return type of a GCC |
| 12945 | builtin and then its argument prototype would still apply. */ |
| 12946 | #ifdef __cplusplus |
| 12947 | extern "C" |
| 12948 | #endif |
| 12949 | char rl_completion_display_matches_hook (); |
| 12950 | int |
| 12951 | main () |
| 12952 | { |
| 12953 | return rl_completion_display_matches_hook (); |
| 12954 | ; |
| 12955 | return 0; |
| 12956 | } |
| 12957 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12958 | if ac_fn_c_try_link "$LINENO"; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12959 | ac_cv_lib_readline_rl_completion_display_matches_hook=yes |
| 12960 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12961 | ac_cv_lib_readline_rl_completion_display_matches_hook=no |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12962 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12963 | rm -f core conftest.err conftest.$ac_objext \ |
| 12964 | conftest$ac_exeext conftest.$ac_ext |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12965 | LIBS=$ac_check_lib_save_LIBS |
| 12966 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5 |
| 12968 | $as_echo "$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12969 | if test "x$ac_cv_lib_readline_rl_completion_display_matches_hook" = xyes; then : |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12970 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12971 | $as_echo "#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1" >>confdefs.h |
Thomas Wouters | 89d996e | 2007-09-08 17:39:28 +0000 | [diff] [blame] | 12972 | |
| 12973 | fi |
| 12974 | |
| 12975 | |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12976 | # check for readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12977 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5 |
| 12978 | $as_echo_n "checking for rl_completion_matches in -lreadline... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 12979 | if ${ac_cv_lib_readline_rl_completion_matches+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12980 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 0daad59 | 2001-09-30 21:09:59 +0000 | [diff] [blame] | 12981 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12982 | ac_check_lib_save_LIBS=$LIBS |
Gregory P. Smith | 1882094 | 2008-09-07 06:24:49 +0000 | [diff] [blame] | 12983 | LIBS="-lreadline $READLINE_LIBS $LIBS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 12984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 12985 | /* end confdefs.h. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12986 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12987 | /* Override any GCC internal prototype to avoid an error. |
| 12988 | Use char because int might match the return type of a GCC |
| 12989 | builtin and then its argument prototype would still apply. */ |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12990 | #ifdef __cplusplus |
| 12991 | extern "C" |
| 12992 | #endif |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12993 | char rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12994 | int |
| 12995 | main () |
| 12996 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 12997 | return rl_completion_matches (); |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 12998 | ; |
| 12999 | return 0; |
| 13000 | } |
| 13001 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13002 | if ac_fn_c_try_link "$LINENO"; then : |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13003 | ac_cv_lib_readline_rl_completion_matches=yes |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13004 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13005 | ac_cv_lib_readline_rl_completion_matches=no |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13006 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13007 | rm -f core conftest.err conftest.$ac_objext \ |
| 13008 | conftest$ac_exeext conftest.$ac_ext |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13009 | LIBS=$ac_check_lib_save_LIBS |
| 13010 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13011 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5 |
| 13012 | $as_echo "$ac_cv_lib_readline_rl_completion_matches" >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13013 | if test "x$ac_cv_lib_readline_rl_completion_matches" = xyes; then : |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13014 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13015 | $as_echo "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13016 | |
Guido van Rossum | 353ae58 | 2001-07-10 16:45:32 +0000 | [diff] [blame] | 13017 | fi |
| 13018 | |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 13019 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13020 | # also in readline 4.2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13021 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13022 | /* end confdefs.h. */ |
| 13023 | #include <readline/readline.h> |
| 13024 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13025 | if ac_fn_c_try_cpp "$LINENO"; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13026 | have_readline=yes |
| 13027 | else |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13028 | have_readline=no |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13029 | |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13030 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13031 | rm -f conftest.err conftest.i conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13032 | if test $have_readline = yes |
| 13033 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13034 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13035 | /* end confdefs.h. */ |
| 13036 | #include <readline/readline.h> |
| 13037 | |
| 13038 | _ACEOF |
| 13039 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13040 | $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then : |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13041 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13042 | $as_echo "#define HAVE_RL_CATCH_SIGNAL 1" >>confdefs.h |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13043 | |
| 13044 | fi |
Matthias Klose | c80c93f | 2010-04-24 17:04:35 +0000 | [diff] [blame] | 13045 | rm -f conftest* |
Michael W. Hudson | 30ea2f2 | 2004-07-07 17:44:12 +0000 | [diff] [blame] | 13046 | |
| 13047 | fi |
| 13048 | |
Martin v. Löwis | 82bca63 | 2006-02-10 20:49:30 +0000 | [diff] [blame] | 13049 | # End of readline checks: restore LIBS |
| 13050 | LIBS=$LIBS_no_readline |
| 13051 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13052 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken nice()" >&5 |
| 13053 | $as_echo_n "checking for broken nice()... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13054 | if ${ac_cv_broken_nice+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13055 | $as_echo_n "(cached) " >&6 |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13056 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13057 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13058 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | 3065c94 | 2001-09-17 04:03:14 +0000 | [diff] [blame] | 13059 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13060 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13061 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13062 | /* end confdefs.h. */ |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13063 | |
| 13064 | int main() |
| 13065 | { |
| 13066 | int val1 = nice(1); |
| 13067 | if (val1 != -1 && val1 == nice(2)) |
| 13068 | exit(0); |
| 13069 | exit(1); |
| 13070 | } |
| 13071 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13072 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13073 | if ac_fn_c_try_run "$LINENO"; then : |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13074 | ac_cv_broken_nice=yes |
| 13075 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13076 | ac_cv_broken_nice=no |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13077 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13078 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13079 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13080 | fi |
| 13081 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13082 | fi |
| 13083 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13084 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_nice" >&5 |
| 13085 | $as_echo "$ac_cv_broken_nice" >&6; } |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13086 | if test "$ac_cv_broken_nice" = yes |
| 13087 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13088 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13089 | $as_echo "#define HAVE_BROKEN_NICE 1" >>confdefs.h |
Thomas Wouters | e38b2f1 | 2001-07-11 22:35:31 +0000 | [diff] [blame] | 13090 | |
| 13091 | fi |
| 13092 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13093 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken poll()" >&5 |
| 13094 | $as_echo_n "checking for broken poll()... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13095 | if ${ac_cv_broken_poll+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13096 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13097 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13098 | if test "$cross_compiling" = yes; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13099 | ac_cv_broken_poll=no |
| 13100 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13102 | /* end confdefs.h. */ |
| 13103 | |
| 13104 | #include <poll.h> |
| 13105 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13106 | int main() |
| 13107 | { |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13108 | struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 }; |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13109 | int poll_test; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13110 | |
| 13111 | close (42); |
| 13112 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13113 | poll_test = poll(&poll_struct, 1, 0); |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13114 | if (poll_test < 0) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13115 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13116 | else if (poll_test == 0 && poll_struct.revents != POLLNVAL) |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13117 | return 0; |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13118 | else |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13119 | return 1; |
| 13120 | } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13121 | |
| 13122 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13123 | if ac_fn_c_try_run "$LINENO"; then : |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13124 | ac_cv_broken_poll=yes |
| 13125 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13126 | ac_cv_broken_poll=no |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13127 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13128 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13129 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13130 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13131 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13132 | fi |
| 13133 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13134 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_poll" >&5 |
| 13135 | $as_echo "$ac_cv_broken_poll" >&6; } |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13136 | if test "$ac_cv_broken_poll" = yes |
| 13137 | then |
| 13138 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13139 | $as_echo "#define HAVE_BROKEN_POLL 1" >>confdefs.h |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13140 | |
| 13141 | fi |
| 13142 | |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13143 | # 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] | 13144 | # (which is not required by ISO C or UNIX spec) and/or if we support |
| 13145 | # tzname[] |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13146 | 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] | 13147 | #include <$ac_cv_struct_tm> |
| 13148 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13149 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13150 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13151 | |
| 13152 | cat >>confdefs.h <<_ACEOF |
| 13153 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
| 13154 | _ACEOF |
| 13155 | |
| 13156 | |
| 13157 | fi |
| 13158 | |
| 13159 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
| 13160 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13161 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13162 | |
| 13163 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13164 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
| 13165 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13166 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13167 | ac_have_decl=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13168 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13169 | ac_have_decl=0 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13170 | fi |
| 13171 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13172 | cat >>confdefs.h <<_ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13173 | #define HAVE_DECL_TZNAME $ac_have_decl |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13174 | _ACEOF |
| 13175 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
| 13177 | $as_echo_n "checking for tzname... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13178 | if ${ac_cv_var_tzname+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13179 | $as_echo_n "(cached) " >&6 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13180 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13181 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13182 | /* end confdefs.h. */ |
| 13183 | #include <time.h> |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13184 | #if !HAVE_DECL_TZNAME |
| 13185 | extern char *tzname[]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13186 | #endif |
| 13187 | |
| 13188 | int |
| 13189 | main () |
| 13190 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13191 | return tzname[0][0]; |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13192 | ; |
| 13193 | return 0; |
| 13194 | } |
| 13195 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13196 | if ac_fn_c_try_link "$LINENO"; then : |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13197 | ac_cv_var_tzname=yes |
| 13198 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13199 | ac_cv_var_tzname=no |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13200 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13201 | rm -f core conftest.err conftest.$ac_objext \ |
| 13202 | conftest$ac_exeext conftest.$ac_ext |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13203 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13204 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
| 13205 | $as_echo "$ac_cv_var_tzname" >&6; } |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13206 | if test $ac_cv_var_tzname = yes; then |
| 13207 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13208 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13209 | |
| 13210 | fi |
| 13211 | fi |
| 13212 | |
Nicholas Bastin | e62c5c8 | 2004-03-21 23:45:42 +0000 | [diff] [blame] | 13213 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13214 | # check tzset(3) exists and works like we expect it to |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13215 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working tzset()" >&5 |
| 13216 | $as_echo_n "checking for working tzset()... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13217 | if ${ac_cv_working_tzset+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13218 | $as_echo_n "(cached) " >&6 |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13219 | else |
| 13220 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13221 | if test "$cross_compiling" = yes; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13222 | ac_cv_working_tzset=no |
| 13223 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13224 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13225 | /* end confdefs.h. */ |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13226 | |
| 13227 | #include <stdlib.h> |
| 13228 | #include <time.h> |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13229 | #include <string.h> |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13230 | |
| 13231 | #if HAVE_TZNAME |
| 13232 | extern char *tzname[]; |
| 13233 | #endif |
| 13234 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13235 | int main() |
| 13236 | { |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13237 | /* Note that we need to ensure that not only does tzset(3) |
| 13238 | do 'something' with localtime, but it works as documented |
| 13239 | 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] | 13240 | This includes making sure that tzname is set properly if |
| 13241 | tm->tm_zone does not exist since it is the alternative way |
| 13242 | of getting timezone info. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13243 | |
| 13244 | Red Hat 6.2 doesn't understand the southern hemisphere |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13245 | after New Year's Day. |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13246 | */ |
| 13247 | |
Martin v. Löwis | 1d45906 | 2005-03-14 21:23:33 +0000 | [diff] [blame] | 13248 | time_t groundhogday = 1044144000; /* GMT-based */ |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13249 | time_t midyear = groundhogday + (365 * 24 * 3600 / 2); |
| 13250 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13251 | putenv("TZ=UTC+0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13252 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13253 | if (localtime(&groundhogday)->tm_hour != 0) |
| 13254 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13255 | #if HAVE_TZNAME |
| 13256 | /* For UTC, tzname[1] is sometimes "", sometimes " " */ |
| 13257 | if (strcmp(tzname[0], "UTC") || |
| 13258 | (tzname[1][0] != 0 && tzname[1][0] != ' ')) |
| 13259 | exit(1); |
| 13260 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13261 | |
Neal Norwitz | 7f2588c | 2003-04-11 15:35:53 +0000 | [diff] [blame] | 13262 | putenv("TZ=EST+5EDT,M4.1.0,M10.5.0"); |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13263 | tzset(); |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13264 | if (localtime(&groundhogday)->tm_hour != 19) |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13265 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13266 | #if HAVE_TZNAME |
| 13267 | if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT")) |
| 13268 | exit(1); |
| 13269 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13270 | |
| 13271 | putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0"); |
| 13272 | tzset(); |
| 13273 | if (localtime(&groundhogday)->tm_hour != 11) |
| 13274 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13275 | #if HAVE_TZNAME |
| 13276 | if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT")) |
| 13277 | exit(1); |
| 13278 | #endif |
| 13279 | |
| 13280 | #if HAVE_STRUCT_TM_TM_ZONE |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13281 | if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT")) |
| 13282 | exit(1); |
| 13283 | if (strcmp(localtime(&midyear)->tm_zone, "AEST")) |
| 13284 | exit(1); |
Brett Cannon | 4380242 | 2005-02-10 20:48:03 +0000 | [diff] [blame] | 13285 | #endif |
Brett Cannon | 1836781 | 2003-09-19 00:59:16 +0000 | [diff] [blame] | 13286 | |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13287 | exit(0); |
| 13288 | } |
| 13289 | |
| 13290 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13291 | if ac_fn_c_try_run "$LINENO"; then : |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13292 | ac_cv_working_tzset=yes |
| 13293 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13294 | ac_cv_working_tzset=no |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13295 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13296 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13297 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13298 | fi |
| 13299 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13300 | fi |
| 13301 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13302 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_tzset" >&5 |
| 13303 | $as_echo "$ac_cv_working_tzset" >&6; } |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13304 | if test "$ac_cv_working_tzset" = yes |
| 13305 | then |
| 13306 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13307 | $as_echo "#define HAVE_WORKING_TZSET 1" >>confdefs.h |
Guido van Rossum | d11b62e | 2003-03-14 21:51:36 +0000 | [diff] [blame] | 13308 | |
| 13309 | fi |
| 13310 | |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13311 | # Look for subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13312 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec in struct stat" >&5 |
| 13313 | $as_echo_n "checking for tv_nsec in struct stat... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13314 | if ${ac_cv_stat_tv_nsec+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13315 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13316 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13317 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13318 | /* end confdefs.h. */ |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13319 | #include <sys/stat.h> |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13320 | int |
| 13321 | main () |
| 13322 | { |
| 13323 | |
| 13324 | struct stat st; |
| 13325 | st.st_mtim.tv_nsec = 1; |
| 13326 | |
| 13327 | ; |
| 13328 | return 0; |
| 13329 | } |
| 13330 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13331 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | a32c994 | 2002-09-09 16:17:47 +0000 | [diff] [blame] | 13332 | ac_cv_stat_tv_nsec=yes |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13333 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13334 | ac_cv_stat_tv_nsec=no |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13335 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13336 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13337 | fi |
| 13338 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec" >&5 |
| 13340 | $as_echo "$ac_cv_stat_tv_nsec" >&6; } |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13341 | if test "$ac_cv_stat_tv_nsec" = yes |
| 13342 | then |
| 13343 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13344 | $as_echo "#define HAVE_STAT_TV_NSEC 1" >>confdefs.h |
Martin v. Löwis | 94717ed | 2002-09-09 14:24:16 +0000 | [diff] [blame] | 13345 | |
| 13346 | fi |
| 13347 | |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13348 | # Look for BSD style subsecond timestamps in struct stat |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13349 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tv_nsec2 in struct stat" >&5 |
| 13350 | $as_echo_n "checking for tv_nsec2 in struct stat... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13351 | if ${ac_cv_stat_tv_nsec2+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13352 | $as_echo_n "(cached) " >&6 |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13353 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13354 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13355 | /* end confdefs.h. */ |
| 13356 | #include <sys/stat.h> |
| 13357 | int |
| 13358 | main () |
| 13359 | { |
| 13360 | |
| 13361 | struct stat st; |
| 13362 | st.st_mtimespec.tv_nsec = 1; |
| 13363 | |
| 13364 | ; |
| 13365 | return 0; |
| 13366 | } |
| 13367 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13368 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13369 | ac_cv_stat_tv_nsec2=yes |
| 13370 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13371 | ac_cv_stat_tv_nsec2=no |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13372 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13373 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13374 | fi |
| 13375 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_stat_tv_nsec2" >&5 |
| 13377 | $as_echo "$ac_cv_stat_tv_nsec2" >&6; } |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13378 | if test "$ac_cv_stat_tv_nsec2" = yes |
| 13379 | then |
| 13380 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13381 | $as_echo "#define HAVE_STAT_TV_NSEC2 1" >>confdefs.h |
Martin v. Löwis | ebd9d5b | 2005-08-09 15:00:59 +0000 | [diff] [blame] | 13382 | |
| 13383 | fi |
| 13384 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13385 | # 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] | 13386 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mvwdelch is an expression" >&5 |
| 13387 | $as_echo_n "checking whether mvwdelch is an expression... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13388 | if ${ac_cv_mvwdelch_is_expression+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13389 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13390 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13392 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13393 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13394 | int |
| 13395 | main () |
| 13396 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13397 | |
| 13398 | int rtn; |
| 13399 | rtn = mvwdelch(0,0,0); |
| 13400 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13401 | ; |
| 13402 | return 0; |
| 13403 | } |
| 13404 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13405 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13406 | ac_cv_mvwdelch_is_expression=yes |
| 13407 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13408 | ac_cv_mvwdelch_is_expression=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13409 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13410 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13411 | fi |
| 13412 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_mvwdelch_is_expression" >&5 |
| 13414 | $as_echo "$ac_cv_mvwdelch_is_expression" >&6; } |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13415 | |
| 13416 | if test "$ac_cv_mvwdelch_is_expression" = yes |
| 13417 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13418 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13419 | $as_echo "#define MVWDELCH_IS_EXPRESSION 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13420 | |
| 13421 | fi |
| 13422 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WINDOW has _flags" >&5 |
| 13424 | $as_echo_n "checking whether WINDOW has _flags... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13425 | if ${ac_cv_window_has_flags+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13426 | $as_echo_n "(cached) " >&6 |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13427 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13428 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13429 | /* end confdefs.h. */ |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13430 | #include <curses.h> |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13431 | int |
| 13432 | main () |
| 13433 | { |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13434 | |
| 13435 | WINDOW *w; |
| 13436 | w->_flags = 0; |
| 13437 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13438 | ; |
| 13439 | return 0; |
| 13440 | } |
| 13441 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13442 | if ac_fn_c_try_compile "$LINENO"; then : |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13443 | ac_cv_window_has_flags=yes |
| 13444 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13445 | ac_cv_window_has_flags=no |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13446 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13447 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13448 | fi |
| 13449 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13450 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_window_has_flags" >&5 |
| 13451 | $as_echo "$ac_cv_window_has_flags" >&6; } |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13452 | |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13453 | |
| 13454 | if test "$ac_cv_window_has_flags" = yes |
| 13455 | then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13457 | $as_echo "#define WINDOW_HAS_FLAGS 1" >>confdefs.h |
Jack Jansen | 666b1e7 | 2001-10-31 12:11:48 +0000 | [diff] [blame] | 13458 | |
| 13459 | fi |
| 13460 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13461 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for is_term_resized" >&5 |
| 13462 | $as_echo_n "checking for is_term_resized... " >&6; } |
| 13463 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13464 | /* end confdefs.h. */ |
| 13465 | #include <curses.h> |
| 13466 | int |
| 13467 | main () |
| 13468 | { |
| 13469 | void *x=is_term_resized |
| 13470 | ; |
| 13471 | return 0; |
| 13472 | } |
| 13473 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13474 | if ac_fn_c_try_compile "$LINENO"; then : |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13475 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13476 | $as_echo "#define HAVE_CURSES_IS_TERM_RESIZED 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13477 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13478 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13479 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13480 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13481 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13482 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13483 | |
| 13484 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13485 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13486 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13487 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resize_term" >&5 |
| 13488 | $as_echo_n "checking for resize_term... " >&6; } |
| 13489 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13490 | /* end confdefs.h. */ |
| 13491 | #include <curses.h> |
| 13492 | int |
| 13493 | main () |
| 13494 | { |
| 13495 | void *x=resize_term |
| 13496 | ; |
| 13497 | return 0; |
| 13498 | } |
| 13499 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13500 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13501 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13502 | $as_echo "#define HAVE_CURSES_RESIZE_TERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13503 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13504 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13505 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13506 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13507 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13508 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13509 | |
| 13510 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13511 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13512 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13513 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resizeterm" >&5 |
| 13514 | $as_echo_n "checking for resizeterm... " >&6; } |
| 13515 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13516 | /* end confdefs.h. */ |
| 13517 | #include <curses.h> |
| 13518 | int |
| 13519 | main () |
| 13520 | { |
| 13521 | void *x=resizeterm |
| 13522 | ; |
| 13523 | return 0; |
| 13524 | } |
| 13525 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13526 | if ac_fn_c_try_compile "$LINENO"; then : |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13527 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13528 | $as_echo "#define HAVE_CURSES_RESIZETERM 1" >>confdefs.h |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13529 | |
Matthias Klose | b159a55 | 2010-04-25 21:00:44 +0000 | [diff] [blame] | 13530 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13531 | $as_echo "yes" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13532 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13533 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13534 | $as_echo "no" >&6; } |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 13535 | |
| 13536 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13537 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
| 13538 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13539 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptmx" >&5 |
| 13540 | $as_echo_n "checking for /dev/ptmx... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13541 | |
| 13542 | if test -r /dev/ptmx |
| 13543 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13544 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13545 | $as_echo "yes" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13546 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13547 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13548 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13549 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13551 | $as_echo "no" >&6; } |
Martin v. Löwis | 24a880b | 2002-12-31 12:55:15 +0000 | [diff] [blame] | 13552 | fi |
| 13553 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13554 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/ptc" >&5 |
| 13555 | $as_echo_n "checking for /dev/ptc... " >&6; } |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13556 | |
| 13557 | if test -r /dev/ptc |
| 13558 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13560 | $as_echo "yes" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13561 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13562 | $as_echo "#define HAVE_DEV_PTC 1" >>confdefs.h |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13563 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13564 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13565 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13566 | $as_echo "no" >&6; } |
Neal Norwitz | 865400f | 2003-03-21 01:42:58 +0000 | [diff] [blame] | 13567 | fi |
| 13568 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13569 | if test "$have_long_long" = yes |
| 13570 | then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13571 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %lld and %llu printf() format support" >&5 |
| 13572 | $as_echo_n "checking for %lld and %llu printf() format support... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13573 | if ${ac_cv_have_long_long_format+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13574 | $as_echo_n "(cached) " >&6 |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13575 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13576 | if test "$cross_compiling" = yes; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13577 | ac_cv_have_long_long_format=no |
| 13578 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13579 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13580 | /* end confdefs.h. */ |
| 13581 | |
| 13582 | #include <stdio.h> |
| 13583 | #include <stddef.h> |
| 13584 | #include <string.h> |
| 13585 | |
| 13586 | #ifdef HAVE_SYS_TYPES_H |
| 13587 | #include <sys/types.h> |
| 13588 | #endif |
| 13589 | |
| 13590 | int main() |
| 13591 | { |
| 13592 | char buffer[256]; |
| 13593 | |
| 13594 | if (sprintf(buffer, "%lld", (long long)123) < 0) |
| 13595 | return 1; |
| 13596 | if (strcmp(buffer, "123")) |
| 13597 | return 1; |
| 13598 | |
| 13599 | if (sprintf(buffer, "%lld", (long long)-123) < 0) |
| 13600 | return 1; |
| 13601 | if (strcmp(buffer, "-123")) |
| 13602 | return 1; |
| 13603 | |
| 13604 | if (sprintf(buffer, "%llu", (unsigned long long)123) < 0) |
| 13605 | return 1; |
| 13606 | if (strcmp(buffer, "123")) |
| 13607 | return 1; |
| 13608 | |
| 13609 | return 0; |
| 13610 | } |
| 13611 | |
| 13612 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13613 | if ac_fn_c_try_run "$LINENO"; then : |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13614 | ac_cv_have_long_long_format=yes |
| 13615 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13616 | ac_cv_have_long_long_format=no |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13617 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13618 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13619 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13620 | fi |
| 13621 | |
| 13622 | |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13623 | fi |
| 13624 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13625 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_long_long_format" >&5 |
| 13626 | $as_echo "$ac_cv_have_long_long_format" >&6; } |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13627 | fi |
| 13628 | |
Mark Dickinson | 89d7d41 | 2009-12-31 20:50:59 +0000 | [diff] [blame] | 13629 | if test "$ac_cv_have_long_long_format" = yes |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13630 | then |
| 13631 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13632 | $as_echo "#define PY_FORMAT_LONG_LONG \"ll\"" >>confdefs.h |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13633 | |
| 13634 | fi |
| 13635 | |
Ronald Oussoren | 3c1928a | 2009-11-19 17:15:31 +0000 | [diff] [blame] | 13636 | if test $ac_sys_system = Darwin |
| 13637 | then |
| 13638 | LIBS="$LIBS -framework CoreFoundation" |
| 13639 | fi |
Mark Dickinson | 6ce4a9a | 2009-11-16 17:00:11 +0000 | [diff] [blame] | 13640 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13641 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for %zd printf() format support" >&5 |
| 13642 | $as_echo_n "checking for %zd printf() format support... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13643 | if ${ac_cv_have_size_t_format+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13644 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13645 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13646 | if test "$cross_compiling" = yes; then : |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13647 | ac_cv_have_size_t_format="cross -- assuming yes" |
| 13648 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13649 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13650 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13651 | /* end confdefs.h. */ |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13652 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13653 | #include <stdio.h> |
| 13654 | #include <stddef.h> |
| 13655 | #include <string.h> |
| 13656 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13657 | #ifdef HAVE_SYS_TYPES_H |
| 13658 | #include <sys/types.h> |
| 13659 | #endif |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13660 | |
| 13661 | #ifdef HAVE_SSIZE_T |
| 13662 | typedef ssize_t Py_ssize_t; |
| 13663 | #elif SIZEOF_VOID_P == SIZEOF_LONG |
| 13664 | typedef long Py_ssize_t; |
| 13665 | #else |
| 13666 | typedef int Py_ssize_t; |
| 13667 | #endif |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13668 | |
Christian Heimes | 2c18161 | 2007-12-17 20:04:13 +0000 | [diff] [blame] | 13669 | int main() |
| 13670 | { |
| 13671 | char buffer[256]; |
| 13672 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13673 | if(sprintf(buffer, "%zd", (size_t)123) < 0) |
| 13674 | return 1; |
| 13675 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 13676 | if (strcmp(buffer, "123")) |
| 13677 | return 1; |
| 13678 | |
| 13679 | if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0) |
| 13680 | return 1; |
| 13681 | |
| 13682 | if (strcmp(buffer, "-123")) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13683 | return 1; |
| 13684 | |
| 13685 | return 0; |
| 13686 | } |
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 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13689 | if ac_fn_c_try_run "$LINENO"; then : |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13690 | ac_cv_have_size_t_format=yes |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13691 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13692 | ac_cv_have_size_t_format=no |
Alexandre Vassalotti | 1914228 | 2009-07-17 23:11:52 +0000 | [diff] [blame] | 13693 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13694 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13695 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Alexandre Vassalotti | 302825b | 2009-07-17 07:49:53 +0000 | [diff] [blame] | 13696 | fi |
| 13697 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13698 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t_format" >&5 |
| 13700 | $as_echo "$ac_cv_have_size_t_format" >&6; } |
Benjamin Peterson | 8f326b2 | 2009-12-13 02:10:36 +0000 | [diff] [blame] | 13701 | if test "$ac_cv_have_size_t_format" != no ; then |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13702 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13703 | $as_echo "#define PY_FORMAT_SIZE_T \"z\"" >>confdefs.h |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13704 | |
| 13705 | fi |
| 13706 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13707 | 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] | 13708 | #ifdef HAVE_SYS_TYPES_H |
| 13709 | #include <sys/types.h> |
| 13710 | #endif |
| 13711 | #ifdef HAVE_SYS_SOCKET_H |
| 13712 | #include <sys/socket.h> |
| 13713 | #endif |
| 13714 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13715 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13716 | if test "x$ac_cv_type_socklen_t" = xyes; then : |
Martin v. Löwis | 01c0401 | 2002-11-11 14:58:44 +0000 | [diff] [blame] | 13717 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13718 | else |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13719 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13720 | $as_echo "#define socklen_t int" >>confdefs.h |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 13721 | |
| 13722 | fi |
| 13723 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13724 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken mbstowcs" >&5 |
| 13726 | $as_echo_n "checking for broken mbstowcs... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13727 | if ${ac_cv_broken_mbstowcs+:} false; then : |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13728 | $as_echo_n "(cached) " >&6 |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13729 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13730 | if test "$cross_compiling" = yes; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13731 | ac_cv_broken_mbstowcs=no |
| 13732 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13733 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13734 | /* end confdefs.h. */ |
| 13735 | |
| 13736 | #include<stdlib.h> |
| 13737 | int main() { |
| 13738 | size_t len = -1; |
| 13739 | const char *str = "text"; |
| 13740 | len = mbstowcs(NULL, str, 0); |
| 13741 | return (len != 4); |
| 13742 | } |
| 13743 | |
| 13744 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13745 | if ac_fn_c_try_run "$LINENO"; then : |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13746 | ac_cv_broken_mbstowcs=no |
| 13747 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13748 | ac_cv_broken_mbstowcs=yes |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13749 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13750 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13751 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13752 | fi |
| 13753 | |
Alexandre Vassalotti | b0a61d7 | 2009-07-17 23:19:37 +0000 | [diff] [blame] | 13754 | fi |
| 13755 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13756 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_broken_mbstowcs" >&5 |
| 13757 | $as_echo "$ac_cv_broken_mbstowcs" >&6; } |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13758 | if test "$ac_cv_broken_mbstowcs" = yes |
| 13759 | then |
| 13760 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13761 | $as_echo "#define HAVE_BROKEN_MBSTOWCS 1" >>confdefs.h |
Antoine Pitrou | fff9530 | 2008-09-03 18:58:51 +0000 | [diff] [blame] | 13762 | |
| 13763 | fi |
| 13764 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13765 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports computed gotos" >&5 |
| 13766 | $as_echo_n "checking whether $CC supports computed gotos... " >&6; } |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13767 | if ${ac_cv_computed_gotos+:} false; then : |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13768 | $as_echo_n "(cached) " >&6 |
| 13769 | else |
| 13770 | if test "$cross_compiling" = yes; then : |
| 13771 | ac_cv_computed_gotos=no |
| 13772 | else |
| 13773 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
| 13774 | /* end confdefs.h. */ |
| 13775 | |
| 13776 | int main(int argc, char **argv) |
| 13777 | { |
| 13778 | static void *targets[1] = { &&LABEL1 }; |
| 13779 | goto LABEL2; |
| 13780 | LABEL1: |
| 13781 | return 0; |
| 13782 | LABEL2: |
| 13783 | goto *targets[0]; |
| 13784 | return 1; |
| 13785 | } |
| 13786 | |
| 13787 | _ACEOF |
| 13788 | if ac_fn_c_try_run "$LINENO"; then : |
| 13789 | ac_cv_computed_gotos=yes |
| 13790 | else |
| 13791 | ac_cv_computed_gotos=no |
| 13792 | fi |
| 13793 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
| 13794 | conftest.$ac_objext conftest.beam conftest.$ac_ext |
| 13795 | fi |
| 13796 | |
| 13797 | fi |
| 13798 | |
| 13799 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_computed_gotos" >&5 |
| 13800 | $as_echo "$ac_cv_computed_gotos" >&6; } |
| 13801 | if test "$ac_cv_computed_gotos" = yes |
| 13802 | then |
| 13803 | |
| 13804 | $as_echo "#define HAVE_COMPUTED_GOTOS 1" >>confdefs.h |
| 13805 | |
| 13806 | fi |
| 13807 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13808 | # Check for --with-computed-gotos |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13809 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-computed-gotos" >&5 |
| 13810 | $as_echo_n "checking for --with-computed-gotos... " >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13811 | |
| 13812 | # Check whether --with-computed-gotos was given. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13813 | if test "${with_computed_gotos+set}" = set; then : |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13814 | withval=$with_computed_gotos; |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13815 | if test "$withval" = yes |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13816 | then |
| 13817 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13818 | $as_echo "#define USE_COMPUTED_GOTOS 1" >>confdefs.h |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13819 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13820 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
| 13821 | $as_echo "yes" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13822 | fi |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13823 | if test "$withval" = no |
| 13824 | then |
| 13825 | |
| 13826 | $as_echo "#define USE_COMPUTED_GOTOS 0" >>confdefs.h |
| 13827 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13828 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
| 13829 | $as_echo "no" >&6; } |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13830 | fi |
| 13831 | |
Antoine Pitrou | 042b128 | 2010-08-13 21:15:58 +0000 | [diff] [blame] | 13832 | else |
| 13833 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no value specified" >&5 |
| 13834 | $as_echo "no value specified" >&6; } |
| 13835 | fi |
| 13836 | |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13837 | |
Benjamin Peterson | d8d835b | 2010-10-15 23:14:46 +0000 | [diff] [blame] | 13838 | case $ac_sys_system in |
| 13839 | AIX*) |
| 13840 | |
| 13841 | $as_echo "#define HAVE_BROKEN_PIPE_BUF 1" >>confdefs.h |
| 13842 | ;; |
| 13843 | esac |
Antoine Pitrou | b52ec78 | 2009-01-25 16:34:23 +0000 | [diff] [blame] | 13844 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13845 | |
Jesus Cea | 6a79229 | 2010-05-03 21:18:48 +0000 | [diff] [blame] | 13846 | case $ac_sys_system in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13847 | OSF*) as_fn_error $? "OSF* systems are deprecated unless somebody volunteers. Check http://bugs.python.org/issue8606" "$LINENO" 5 ;; |
Jesus Cea | 6a79229 | 2010-05-03 21:18:48 +0000 | [diff] [blame] | 13848 | esac |
| 13849 | |
Gregory P. Smith | 138fa43 | 2010-12-13 08:00:52 +0000 | [diff] [blame] | 13850 | ac_fn_c_check_func "$LINENO" "pipe2" "ac_cv_func_pipe2" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13851 | if test "x$ac_cv_func_pipe2" = xyes; then : |
Gregory P. Smith | 138fa43 | 2010-12-13 08:00:52 +0000 | [diff] [blame] | 13852 | |
| 13853 | $as_echo "#define HAVE_PIPE2 1" >>confdefs.h |
| 13854 | |
| 13855 | fi |
Jesus Cea | 6a79229 | 2010-05-03 21:18:48 +0000 | [diff] [blame] | 13856 | |
| 13857 | |
Mark Dickinson | b2153e9 | 2010-05-05 22:31:36 +0000 | [diff] [blame] | 13858 | |
| 13859 | |
Martin v. Löwis | 06f15bb | 2001-12-02 13:02:32 +0000 | [diff] [blame] | 13860 | for h in `(cd $srcdir;echo Python/thread_*.h)` |
| 13861 | do |
| 13862 | THREADHEADERS="$THREADHEADERS \$(srcdir)/$h" |
| 13863 | done |
| 13864 | |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 13865 | |
Neal Norwitz | d24499d | 2005-12-18 21:36:39 +0000 | [diff] [blame] | 13866 | SRCDIRS="Parser Grammar Objects Python Modules Mac" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13867 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build directories" >&5 |
| 13868 | $as_echo_n "checking for build directories... " >&6; } |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13869 | for dir in $SRCDIRS; do |
| 13870 | if test ! -d $dir; then |
| 13871 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 13872 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 13873 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13874 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 |
| 13875 | $as_echo "done" >&6; } |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 13876 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 13877 | # generate output files |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 13878 | 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] | 13879 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 13880 | ac_config_files="$ac_config_files Modules/ld_so_aix" |
| 13881 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13882 | cat >confcache <<\_ACEOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13883 | # This file is a shell script that caches the results of configure |
| 13884 | # 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] | 13885 | # scripts and configure runs, see configure's option --config-cache. |
| 13886 | # It is not useful on other systems. If it contains results you don't |
| 13887 | # want to keep, you may remove or edit it. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13888 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13889 | # config.status only pays attention to the cache file if you give it |
| 13890 | # the --recheck option to rerun configure. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13891 | # |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13892 | # `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] | 13893 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
| 13894 | # following values. |
| 13895 | |
| 13896 | _ACEOF |
| 13897 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 13898 | # The following way of writing the cache mishandles newlines in values, |
| 13899 | # but we know of no workaround that is simple, portable, and efficient. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13900 | # So, we kill variables containing newlines. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13901 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 13902 | # 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] | 13903 | ( |
| 13904 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do |
| 13905 | eval ac_val=\$$ac_var |
| 13906 | case $ac_val in #( |
| 13907 | *${as_nl}*) |
| 13908 | case $ac_var in #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13909 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
| 13910 | $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] | 13911 | esac |
| 13912 | case $ac_var in #( |
| 13913 | _ | IFS | as_nl) ;; #( |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13914 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
| 13915 | *) { eval $ac_var=; unset $ac_var;} ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13916 | esac ;; |
| 13917 | esac |
| 13918 | done |
| 13919 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13920 | (set) 2>&1 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13921 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 13922 | *${as_nl}ac_space=\ *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13923 | # `set' does not quote correctly, so add quotes: double-quote |
| 13924 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13925 | sed -n \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 13926 | "s/'/'\\\\''/g; |
| 13927 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13928 | ;; #( |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13929 | *) |
| 13930 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13931 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13932 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13933 | esac | |
| 13934 | sort |
| 13935 | ) | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13936 | sed ' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13937 | /^ac_cv_env_/b end |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13938 | t clear |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13939 | :clear |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13940 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
| 13941 | t end |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13942 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
| 13943 | :end' >>confcache |
| 13944 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else |
| 13945 | if test -w "$cache_file"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13946 | if test "x$cache_file" != "x/dev/null"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13947 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
| 13948 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13949 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
| 13950 | cat confcache >"$cache_file" |
| 13951 | else |
| 13952 | case $cache_file in #( |
| 13953 | */* | ?:*) |
| 13954 | mv -f confcache "$cache_file"$$ && |
| 13955 | mv -f "$cache_file"$$ "$cache_file" ;; #( |
| 13956 | *) |
| 13957 | mv -f confcache "$cache_file" ;; |
| 13958 | esac |
| 13959 | fi |
| 13960 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13961 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13962 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
| 13963 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13964 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13965 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 13966 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13967 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13968 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 13969 | # Let make expand exec_prefix. |
| 13970 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 13971 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 13972 | DEFS=-DHAVE_CONFIG_H |
| 13973 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13974 | ac_libobjs= |
| 13975 | ac_ltlibobjs= |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13976 | U= |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13977 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
| 13978 | # 1. Remove the extension, and $U if already installed. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13979 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13980 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 13981 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
| 13982 | # will be set to the directory where LIBOBJS objects are built. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13983 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
| 13984 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 13985 | done |
| 13986 | LIBOBJS=$ac_libobjs |
| 13987 | |
| 13988 | LTLIBOBJS=$ac_ltlibobjs |
| 13989 | |
| 13990 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13991 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13992 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 13993 | : "${CONFIG_STATUS=./config.status}" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13994 | ac_write_fail=0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 13995 | ac_clean_files_save=$ac_clean_files |
| 13996 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 13997 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
| 13998 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
| 13999 | as_write_fail=0 |
| 14000 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14001 | #! $SHELL |
| 14002 | # Generated by $as_me. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14003 | # Run this file to recreate the current configuration. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 14004 | # Compiler output produced by configure, useful for debugging |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14005 | # configure, is in config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 14006 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14007 | debug=false |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14008 | ac_cs_recheck=false |
| 14009 | ac_cs_silent=false |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 14010 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14011 | SHELL=\${CONFIG_SHELL-$SHELL} |
| 14012 | export SHELL |
| 14013 | _ASEOF |
| 14014 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 |
| 14015 | ## -------------------- ## |
| 14016 | ## M4sh Initialization. ## |
| 14017 | ## -------------------- ## |
Jack Jansen | dd19cf8 | 2001-12-06 22:36:17 +0000 | [diff] [blame] | 14018 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14019 | # Be more Bourne compatible |
| 14020 | DUALCASE=1; export DUALCASE # for MKS sh |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14021 | 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] | 14022 | emulate sh |
| 14023 | NULLCMD=: |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14024 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14025 | # is contrary to our usage. Disable this feature. |
| 14026 | alias -g '${1+"$@"}'='"$@"' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14027 | setopt NO_GLOB_SUBST |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 14028 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14029 | case `(set -o) 2>/dev/null` in #( |
| 14030 | *posix*) : |
| 14031 | set -o posix ;; #( |
| 14032 | *) : |
| 14033 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14034 | esac |
Michael W. Hudson | 5424113 | 2001-12-07 15:38:26 +0000 | [diff] [blame] | 14035 | fi |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 14036 | |
| 14037 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14038 | as_nl=' |
| 14039 | ' |
| 14040 | export as_nl |
| 14041 | # Printing a long string crashes Solaris 7 /usr/bin/printf. |
| 14042 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' |
| 14043 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo |
| 14044 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo |
| 14045 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
| 14046 | # but without wasting forks for bash or zsh. |
| 14047 | if test -z "$BASH_VERSION$ZSH_VERSION" \ |
| 14048 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 14049 | as_echo='print -r --' |
| 14050 | as_echo_n='print -rn --' |
| 14051 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then |
| 14052 | as_echo='printf %s\n' |
| 14053 | as_echo_n='printf %s' |
| 14054 | else |
| 14055 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then |
| 14056 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' |
| 14057 | as_echo_n='/usr/ucb/echo -n' |
| 14058 | else |
| 14059 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
| 14060 | as_echo_n_body='eval |
| 14061 | arg=$1; |
| 14062 | case $arg in #( |
| 14063 | *"$as_nl"*) |
| 14064 | expr "X$arg" : "X\\(.*\\)$as_nl"; |
| 14065 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; |
| 14066 | esac; |
| 14067 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" |
| 14068 | ' |
| 14069 | export as_echo_n_body |
| 14070 | as_echo_n='sh -c $as_echo_n_body as_echo' |
| 14071 | fi |
| 14072 | export as_echo_body |
| 14073 | as_echo='sh -c $as_echo_body as_echo' |
| 14074 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14075 | |
| 14076 | # The user is always right. |
| 14077 | if test "${PATH_SEPARATOR+set}" != set; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14078 | PATH_SEPARATOR=: |
| 14079 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { |
| 14080 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || |
| 14081 | PATH_SEPARATOR=';' |
| 14082 | } |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14083 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14084 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14085 | |
| 14086 | # IFS |
| 14087 | # We need space, tab and new line, in precisely that order. Quoting is |
| 14088 | # there to prevent editors from complaining about space-tab. |
| 14089 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word |
| 14090 | # splitting by setting IFS to empty value.) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14091 | IFS=" "" $as_nl" |
| 14092 | |
| 14093 | # Find who we are. Look in the path if we contain no directory separator. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14094 | as_myself= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14095 | case $0 in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14096 | *[\\/]* ) as_myself=$0 ;; |
| 14097 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14098 | for as_dir in $PATH |
| 14099 | do |
| 14100 | IFS=$as_save_IFS |
| 14101 | test -z "$as_dir" && as_dir=. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14102 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
| 14103 | done |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14104 | IFS=$as_save_IFS |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14105 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14106 | ;; |
| 14107 | esac |
| 14108 | # We did not find ourselves, most probably we were run as `sh COMMAND' |
| 14109 | # in which case we are not to be found in the path. |
| 14110 | if test "x$as_myself" = x; then |
| 14111 | as_myself=$0 |
| 14112 | fi |
| 14113 | if test ! -f "$as_myself"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14114 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
| 14115 | exit 1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14116 | fi |
| 14117 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14118 | # Unset variables that we do not need and which cause bugs (e.g. in |
| 14119 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" |
| 14120 | # suppresses any "Segmentation fault" message there. '((' could |
| 14121 | # trigger a bug in pdksh 5.2.14. |
| 14122 | for as_var in BASH_ENV ENV MAIL MAILPATH |
| 14123 | do eval test x\${$as_var+set} = xset \ |
| 14124 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14125 | done |
| 14126 | PS1='$ ' |
| 14127 | PS2='> ' |
| 14128 | PS4='+ ' |
| 14129 | |
| 14130 | # NLS nuisances. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14131 | LC_ALL=C |
| 14132 | export LC_ALL |
| 14133 | LANGUAGE=C |
| 14134 | export LANGUAGE |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14135 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14136 | # CDPATH. |
| 14137 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH |
| 14138 | |
| 14139 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14140 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
| 14141 | # ---------------------------------------- |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14142 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
| 14143 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14144 | # script with STATUS, using 1 if that was 0. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14145 | as_fn_error () |
| 14146 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14147 | as_status=$1; test $as_status -eq 0 && as_status=1 |
| 14148 | if test "$4"; then |
| 14149 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
| 14150 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14151 | fi |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14152 | $as_echo "$as_me: error: $2" >&2 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14153 | as_fn_exit $as_status |
| 14154 | } # as_fn_error |
| 14155 | |
| 14156 | |
| 14157 | # as_fn_set_status STATUS |
| 14158 | # ----------------------- |
| 14159 | # Set $? to STATUS, without forking. |
| 14160 | as_fn_set_status () |
| 14161 | { |
| 14162 | return $1 |
| 14163 | } # as_fn_set_status |
| 14164 | |
| 14165 | # as_fn_exit STATUS |
| 14166 | # ----------------- |
| 14167 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. |
| 14168 | as_fn_exit () |
| 14169 | { |
| 14170 | set +e |
| 14171 | as_fn_set_status $1 |
| 14172 | exit $1 |
| 14173 | } # as_fn_exit |
| 14174 | |
| 14175 | # as_fn_unset VAR |
| 14176 | # --------------- |
| 14177 | # Portably unset VAR. |
| 14178 | as_fn_unset () |
| 14179 | { |
| 14180 | { eval $1=; unset $1;} |
| 14181 | } |
| 14182 | as_unset=as_fn_unset |
| 14183 | # as_fn_append VAR VALUE |
| 14184 | # ---------------------- |
| 14185 | # Append the text in VALUE to the end of the definition contained in VAR. Take |
| 14186 | # advantage of any shell optimizations that allow amortized linear growth over |
| 14187 | # repeated appends, instead of the typical quadratic growth present in naive |
| 14188 | # implementations. |
| 14189 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : |
| 14190 | eval 'as_fn_append () |
| 14191 | { |
| 14192 | eval $1+=\$2 |
| 14193 | }' |
| 14194 | else |
| 14195 | as_fn_append () |
| 14196 | { |
| 14197 | eval $1=\$$1\$2 |
| 14198 | } |
| 14199 | fi # as_fn_append |
| 14200 | |
| 14201 | # as_fn_arith ARG... |
| 14202 | # ------------------ |
| 14203 | # Perform arithmetic evaluation on the ARGs, and store the result in the |
| 14204 | # global $as_val. Take advantage of shells that can avoid forks. The arguments |
| 14205 | # must be portable across $(()) and expr. |
| 14206 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : |
| 14207 | eval 'as_fn_arith () |
| 14208 | { |
| 14209 | as_val=$(( $* )) |
| 14210 | }' |
| 14211 | else |
| 14212 | as_fn_arith () |
| 14213 | { |
| 14214 | as_val=`expr "$@" || test $? -eq 1` |
| 14215 | } |
| 14216 | fi # as_fn_arith |
| 14217 | |
| 14218 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14219 | if expr a : '\(a\)' >/dev/null 2>&1 && |
| 14220 | test "X`expr 00001 : '.*\(...\)'`" = X001; then |
| 14221 | as_expr=expr |
| 14222 | else |
| 14223 | as_expr=false |
| 14224 | fi |
| 14225 | |
| 14226 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
| 14227 | as_basename=basename |
| 14228 | else |
| 14229 | as_basename=false |
| 14230 | fi |
| 14231 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14232 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
| 14233 | as_dirname=dirname |
| 14234 | else |
| 14235 | as_dirname=false |
| 14236 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14237 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14238 | as_me=`$as_basename -- "$0" || |
| 14239 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
| 14240 | X"$0" : 'X\(//\)$' \| \ |
| 14241 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14242 | $as_echo X/"$0" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14243 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
| 14244 | s//\1/ |
| 14245 | q |
| 14246 | } |
| 14247 | /^X\/\(\/\/\)$/{ |
| 14248 | s//\1/ |
| 14249 | q |
| 14250 | } |
| 14251 | /^X\/\(\/\).*/{ |
| 14252 | s//\1/ |
| 14253 | q |
| 14254 | } |
| 14255 | s/.*/./; q'` |
| 14256 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14257 | # Avoid depending upon Character Ranges. |
| 14258 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' |
| 14259 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' |
| 14260 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS |
| 14261 | as_cr_digits='0123456789' |
| 14262 | as_cr_alnum=$as_cr_Letters$as_cr_digits |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14263 | |
| 14264 | ECHO_C= ECHO_N= ECHO_T= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14265 | case `echo -n x` in #((((( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14266 | -n*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14267 | case `echo 'xy\c'` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14268 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14269 | xy) ECHO_C='\c';; |
| 14270 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null |
| 14271 | ECHO_T=' ';; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14272 | esac;; |
| 14273 | *) |
| 14274 | ECHO_N='-n';; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14275 | esac |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14276 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14277 | rm -f conf$$ conf$$.exe conf$$.file |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14278 | if test -d conf$$.dir; then |
| 14279 | rm -f conf$$.dir/conf$$.file |
| 14280 | else |
| 14281 | rm -f conf$$.dir |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14282 | mkdir conf$$.dir 2>/dev/null |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14283 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14284 | if (echo >conf$$.file) 2>/dev/null; then |
| 14285 | if ln -s conf$$.file conf$$ 2>/dev/null; then |
| 14286 | as_ln_s='ln -s' |
| 14287 | # ... but there are two gotchas: |
| 14288 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. |
| 14289 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. |
| 14290 | # In both cases, we have to default to `cp -p'. |
| 14291 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
| 14292 | as_ln_s='cp -p' |
| 14293 | elif ln conf$$.file conf$$ 2>/dev/null; then |
| 14294 | as_ln_s=ln |
| 14295 | else |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14296 | as_ln_s='cp -p' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14297 | fi |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14298 | else |
| 14299 | as_ln_s='cp -p' |
| 14300 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14301 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
| 14302 | rmdir conf$$.dir 2>/dev/null |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14303 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14304 | |
| 14305 | # as_fn_mkdir_p |
| 14306 | # ------------- |
| 14307 | # Create "$as_dir" as a directory, including parents if necessary. |
| 14308 | as_fn_mkdir_p () |
| 14309 | { |
| 14310 | |
| 14311 | case $as_dir in #( |
| 14312 | -*) as_dir=./$as_dir;; |
| 14313 | esac |
| 14314 | test -d "$as_dir" || eval $as_mkdir_p || { |
| 14315 | as_dirs= |
| 14316 | while :; do |
| 14317 | case $as_dir in #( |
| 14318 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( |
| 14319 | *) as_qdir=$as_dir;; |
| 14320 | esac |
| 14321 | as_dirs="'$as_qdir' $as_dirs" |
| 14322 | as_dir=`$as_dirname -- "$as_dir" || |
| 14323 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
| 14324 | X"$as_dir" : 'X\(//\)[^/]' \| \ |
| 14325 | X"$as_dir" : 'X\(//\)$' \| \ |
| 14326 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || |
| 14327 | $as_echo X"$as_dir" | |
| 14328 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14329 | s//\1/ |
| 14330 | q |
| 14331 | } |
| 14332 | /^X\(\/\/\)[^/].*/{ |
| 14333 | s//\1/ |
| 14334 | q |
| 14335 | } |
| 14336 | /^X\(\/\/\)$/{ |
| 14337 | s//\1/ |
| 14338 | q |
| 14339 | } |
| 14340 | /^X\(\/\).*/{ |
| 14341 | s//\1/ |
| 14342 | q |
| 14343 | } |
| 14344 | s/.*/./; q'` |
| 14345 | test -d "$as_dir" && break |
| 14346 | done |
| 14347 | test -z "$as_dirs" || eval "mkdir $as_dirs" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14348 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14349 | |
| 14350 | |
| 14351 | } # as_fn_mkdir_p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14352 | if mkdir -p . 2>/dev/null; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14353 | as_mkdir_p='mkdir -p "$as_dir"' |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14354 | else |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14355 | test -d ./-p && rmdir ./-p |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14356 | as_mkdir_p=false |
| 14357 | fi |
| 14358 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14359 | if test -x / >/dev/null 2>&1; then |
| 14360 | as_test_x='test -x' |
| 14361 | else |
| 14362 | if ls -dL / >/dev/null 2>&1; then |
| 14363 | as_ls_L_option=L |
| 14364 | else |
| 14365 | as_ls_L_option= |
| 14366 | fi |
| 14367 | as_test_x=' |
| 14368 | eval sh -c '\'' |
| 14369 | if test -d "$1"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14370 | test -d "$1/."; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14371 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14372 | case $1 in #( |
| 14373 | -*)set "./$1";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14374 | esac; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14375 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14376 | ???[sx]*):;;*)false;;esac;fi |
| 14377 | '\'' sh |
| 14378 | ' |
| 14379 | fi |
| 14380 | as_executable_p=$as_test_x |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14381 | |
| 14382 | # Sed expression to map a string onto a valid CPP name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14383 | 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] | 14384 | |
| 14385 | # Sed expression to map a string onto a valid variable name. |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14386 | 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] | 14387 | |
| 14388 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14389 | exec 6>&1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14390 | ## ----------------------------------- ## |
| 14391 | ## Main body of $CONFIG_STATUS script. ## |
| 14392 | ## ----------------------------------- ## |
| 14393 | _ASEOF |
| 14394 | 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] | 14395 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14396 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14397 | # 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] | 14398 | # report actual input values of CONFIG_FILES etc. instead of their |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14399 | # values after options handling. |
| 14400 | ac_log=" |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 14401 | This file was extended by python $as_me 3.2, which was |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14402 | generated by GNU Autoconf 2.68. Invocation command line was |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14403 | |
| 14404 | CONFIG_FILES = $CONFIG_FILES |
| 14405 | CONFIG_HEADERS = $CONFIG_HEADERS |
| 14406 | CONFIG_LINKS = $CONFIG_LINKS |
| 14407 | CONFIG_COMMANDS = $CONFIG_COMMANDS |
| 14408 | $ $0 $@ |
| 14409 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14410 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
| 14411 | " |
| 14412 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14413 | _ACEOF |
| 14414 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14415 | case $ac_config_files in *" |
| 14416 | "*) set x $ac_config_files; shift; ac_config_files=$*;; |
| 14417 | esac |
| 14418 | |
| 14419 | case $ac_config_headers in *" |
| 14420 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; |
| 14421 | esac |
| 14422 | |
| 14423 | |
| 14424 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14425 | # Files that config.status was made for. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14426 | config_files="$ac_config_files" |
| 14427 | config_headers="$ac_config_headers" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14428 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14429 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14430 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14431 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14432 | ac_cs_usage="\ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14433 | \`$as_me' instantiates files and other configuration actions |
| 14434 | from templates according to the current configuration. Unless the files |
| 14435 | 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] | 14436 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14437 | Usage: $0 [OPTION]... [TAG]... |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14438 | |
| 14439 | -h, --help print this help, then exit |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14440 | -V, --version print version number and configuration settings, then exit |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14441 | --config print configuration, then exit |
| 14442 | -q, --quiet, --silent |
| 14443 | do not print progress messages |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14444 | -d, --debug don't remove temporary files |
| 14445 | --recheck update $as_me by reconfiguring in the same conditions |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14446 | --file=FILE[:TEMPLATE] |
| 14447 | instantiate the configuration file FILE |
| 14448 | --header=FILE[:TEMPLATE] |
| 14449 | instantiate the configuration header FILE |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14450 | |
| 14451 | Configuration files: |
| 14452 | $config_files |
| 14453 | |
| 14454 | Configuration headers: |
| 14455 | $config_headers |
| 14456 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14457 | Report bugs to <http://bugs.python.org/>." |
Skip Montanaro | eb33e5a | 2007-08-17 12:57:41 +0000 | [diff] [blame] | 14458 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14459 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14460 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14461 | 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] | 14462 | ac_cs_version="\\ |
Benjamin Peterson | 46ea4f7 | 2009-06-27 21:40:27 +0000 | [diff] [blame] | 14463 | python config.status 3.2 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14464 | configured by $0, generated by GNU Autoconf 2.68, |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14465 | with options \\"\$ac_cs_config\\" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14466 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14467 | Copyright (C) 2010 Free Software Foundation, Inc. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14468 | This config.status script is free software; the Free Software Foundation |
| 14469 | gives unlimited permission to copy, distribute and modify it." |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14470 | |
| 14471 | ac_pwd='$ac_pwd' |
| 14472 | srcdir='$srcdir' |
| 14473 | INSTALL='$INSTALL' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14474 | test -n "\$AWK" || AWK=awk |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14475 | _ACEOF |
| 14476 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14477 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14478 | # 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] | 14479 | ac_need_defaults=: |
| 14480 | while test $# != 0 |
| 14481 | do |
| 14482 | case $1 in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14483 | --*=?*) |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14484 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14485 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14486 | ac_shift=: |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14487 | ;; |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14488 | --*=) |
| 14489 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
| 14490 | ac_optarg= |
| 14491 | ac_shift=: |
| 14492 | ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14493 | *) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14494 | ac_option=$1 |
| 14495 | ac_optarg=$2 |
| 14496 | ac_shift=shift |
| 14497 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14498 | esac |
| 14499 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14500 | case $ac_option in |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14501 | # Handling of the options. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14502 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
| 14503 | ac_cs_recheck=: ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14504 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14505 | $as_echo "$ac_cs_version"; exit ;; |
| 14506 | --config | --confi | --conf | --con | --co | --c ) |
| 14507 | $as_echo "$ac_cs_config"; exit ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14508 | --debug | --debu | --deb | --de | --d | -d ) |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14509 | debug=: ;; |
| 14510 | --file | --fil | --fi | --f ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14511 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14512 | case $ac_optarg in |
| 14513 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14514 | '') as_fn_error $? "missing file argument" ;; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14515 | esac |
| 14516 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14517 | ac_need_defaults=false;; |
| 14518 | --header | --heade | --head | --hea ) |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14519 | $ac_shift |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14520 | case $ac_optarg in |
| 14521 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; |
| 14522 | esac |
| 14523 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14524 | ac_need_defaults=false;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14525 | --he | --h) |
| 14526 | # Conflict between --help and --header |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14527 | as_fn_error $? "ambiguous option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14528 | Try \`$0 --help' for more information.";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14529 | --help | --hel | -h ) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14530 | $as_echo "$ac_cs_usage"; exit ;; |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14531 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 14532 | | -silent | --silent | --silen | --sile | --sil | --si | --s) |
| 14533 | ac_cs_silent=: ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14534 | |
| 14535 | # This is an error. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14536 | -*) as_fn_error $? "unrecognized option: \`$1' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14537 | Try \`$0 --help' for more information." ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14538 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14539 | *) as_fn_append ac_config_targets " $1" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14540 | ac_need_defaults=false ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14541 | |
| 14542 | esac |
| 14543 | shift |
| 14544 | done |
| 14545 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14546 | ac_configure_extra_args= |
| 14547 | |
| 14548 | if $ac_cs_silent; then |
| 14549 | exec 6>/dev/null |
| 14550 | ac_configure_extra_args="$ac_configure_extra_args --silent" |
| 14551 | fi |
| 14552 | |
| 14553 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14554 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14555 | if \$ac_cs_recheck; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14556 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
| 14557 | shift |
| 14558 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 |
| 14559 | CONFIG_SHELL='$SHELL' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14560 | export CONFIG_SHELL |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14561 | exec "\$@" |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14562 | fi |
| 14563 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14564 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14565 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14566 | exec 5>>config.log |
| 14567 | { |
| 14568 | echo |
| 14569 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX |
| 14570 | ## Running $as_me. ## |
| 14571 | _ASBOX |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14572 | $as_echo "$ac_log" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14573 | } >&5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14574 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +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 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14578 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14579 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14580 | |
| 14581 | # Handling of arguments. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14582 | for ac_config_target in $ac_config_targets |
| 14583 | do |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14584 | case $ac_config_target in |
| 14585 | "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;; |
| 14586 | "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;; |
| 14587 | "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;; |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 14588 | "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;; |
| 14589 | "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] | 14590 | "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;; |
| 14591 | "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;; |
Antoine Pitrou | 2032722 | 2009-05-24 20:39:11 +0000 | [diff] [blame] | 14592 | "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;; |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 14593 | "Modules/ld_so_aix") CONFIG_FILES="$CONFIG_FILES Modules/ld_so_aix" ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14594 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14595 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14596 | esac |
| 14597 | done |
| 14598 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14599 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14600 | # If the user did not use the arguments to specify the items to instantiate, |
| 14601 | # then the envvar interface is used. Set only those that are not. |
| 14602 | # We use the long form for the default assignment because of an extremely |
| 14603 | # bizarre bug on SunOS 4.1.3. |
| 14604 | if $ac_need_defaults; then |
| 14605 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files |
| 14606 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers |
| 14607 | fi |
| 14608 | |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14609 | # Have a temporary directory for convenience. Make it in the build tree |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14610 | # 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] | 14611 | # creating and moving files from /tmp can sometimes cause problems. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14612 | # Hook for its removal unless debugging. |
| 14613 | # Note that there is a small window in which the directory will not be cleaned: |
| 14614 | # 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] | 14615 | $debug || |
| 14616 | { |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14617 | tmp= ac_tmp= |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14618 | trap 'exit_status=$? |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14619 | : "${ac_tmp:=$tmp}" |
| 14620 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14621 | ' 0 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14622 | trap 'as_fn_exit 1' 1 2 13 15 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14623 | } |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14624 | # Create a (secure) tmp directory for tmp files. |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 14625 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14626 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14627 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14628 | test -d "$tmp" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14629 | } || |
| 14630 | { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14631 | tmp=./conf$$-$RANDOM |
| 14632 | (umask 077 && mkdir "$tmp") |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14633 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
| 14634 | ac_tmp=$tmp |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14635 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14636 | # Set up the scripts for CONFIG_FILES section. |
| 14637 | # No need to generate them if there are no CONFIG_FILES. |
| 14638 | # This happens for instance with `./config.status config.h'. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14639 | if test -n "$CONFIG_FILES"; then |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14640 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14641 | |
| 14642 | ac_cr=`echo X | tr X '\015'` |
| 14643 | # On cygwin, bash can eat \r inside `` if the user requested igncr. |
| 14644 | # But we know of no other shell where ac_cr would be empty at this |
| 14645 | # point, so we can use a bashism as a fallback. |
| 14646 | if test "x$ac_cr" = x; then |
| 14647 | eval ac_cr=\$\'\\r\' |
| 14648 | fi |
| 14649 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
| 14650 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14651 | ac_cs_awk_cr='\\r' |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14652 | else |
| 14653 | ac_cs_awk_cr=$ac_cr |
| 14654 | fi |
| 14655 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14656 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14657 | _ACEOF |
| 14658 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14659 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14660 | { |
| 14661 | echo "cat >conf$$subs.awk <<_ACEOF" && |
| 14662 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && |
| 14663 | echo "_ACEOF" |
| 14664 | } >conf$$subs.sh || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14665 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
| 14666 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14667 | ac_delim='%!_!# ' |
| 14668 | for ac_last_try in false false false false false :; do |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14669 | . ./conf$$subs.sh || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14670 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14671 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14672 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
| 14673 | if test $ac_delim_n = $ac_delim_num; then |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14674 | break |
| 14675 | elif $ac_last_try; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14676 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14677 | else |
| 14678 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14679 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14680 | done |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14681 | rm -f conf$$subs.sh |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14682 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14683 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14684 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14685 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14686 | sed -n ' |
| 14687 | h |
| 14688 | s/^/S["/; s/!.*/"]=/ |
| 14689 | p |
| 14690 | g |
| 14691 | s/^[^!]*!// |
| 14692 | :repl |
| 14693 | t repl |
| 14694 | s/'"$ac_delim"'$// |
| 14695 | t delim |
| 14696 | :nl |
| 14697 | h |
| 14698 | s/\(.\{148\}\)..*/\1/ |
| 14699 | t more1 |
| 14700 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ |
| 14701 | p |
| 14702 | n |
| 14703 | b repl |
| 14704 | :more1 |
| 14705 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14706 | p |
| 14707 | g |
| 14708 | s/.\{148\}// |
| 14709 | t nl |
| 14710 | :delim |
| 14711 | h |
| 14712 | s/\(.\{148\}\)..*/\1/ |
| 14713 | t more2 |
| 14714 | s/["\\]/\\&/g; s/^/"/; s/$/"/ |
| 14715 | p |
| 14716 | b |
| 14717 | :more2 |
| 14718 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ |
| 14719 | p |
| 14720 | g |
| 14721 | s/.\{148\}// |
| 14722 | t delim |
| 14723 | ' <conf$$subs.awk | sed ' |
| 14724 | /^[^""]/{ |
| 14725 | N |
| 14726 | s/\n// |
| 14727 | } |
| 14728 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14729 | rm -f conf$$subs.awk |
| 14730 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14731 | _ACAWK |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14732 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14733 | for (key in S) S_is_set[key] = 1 |
| 14734 | FS = "" |
| 14735 | |
| 14736 | } |
| 14737 | { |
| 14738 | line = $ 0 |
| 14739 | nfields = split(line, field, "@") |
| 14740 | substed = 0 |
| 14741 | len = length(field[1]) |
| 14742 | for (i = 2; i < nfields; i++) { |
| 14743 | key = field[i] |
| 14744 | keylen = length(key) |
| 14745 | if (S_is_set[key]) { |
| 14746 | value = S[key] |
| 14747 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) |
| 14748 | len += length(value) + length(field[++i]) |
| 14749 | substed = 1 |
| 14750 | } else |
| 14751 | len += 1 + keylen |
| 14752 | } |
| 14753 | |
| 14754 | print line |
| 14755 | } |
| 14756 | |
| 14757 | _ACAWK |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14758 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14759 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
| 14760 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then |
| 14761 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" |
| 14762 | else |
| 14763 | cat |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14764 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
| 14765 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
Ronald Oussoren | 74f29b4 | 2009-09-20 20:09:26 +0000 | [diff] [blame] | 14766 | _ACEOF |
| 14767 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14768 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
| 14769 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14770 | # trailing colons and then remove the whole line if VPATH becomes empty |
| 14771 | # (actually we leave an empty line to preserve line numbers). |
| 14772 | if test "x$srcdir" = x.; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14773 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
| 14774 | h |
| 14775 | s/// |
| 14776 | s/^/:/ |
| 14777 | s/[ ]*$/:/ |
| 14778 | s/:\$(srcdir):/:/g |
| 14779 | s/:\${srcdir}:/:/g |
| 14780 | s/:@srcdir@:/:/g |
| 14781 | s/^:*// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14782 | s/:*$// |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14783 | x |
| 14784 | s/\(=[ ]*\).*/\1/ |
| 14785 | G |
| 14786 | s/\n// |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14787 | s/^[^=]*=[ ]*$// |
| 14788 | }' |
| 14789 | fi |
| 14790 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14791 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14792 | fi # test -n "$CONFIG_FILES" |
| 14793 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14794 | # Set up the scripts for CONFIG_HEADERS section. |
| 14795 | # No need to generate them if there are no CONFIG_HEADERS. |
| 14796 | # This happens for instance with `./config.status Makefile'. |
| 14797 | if test -n "$CONFIG_HEADERS"; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14798 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14799 | BEGIN { |
| 14800 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14801 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14802 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
| 14803 | # here-document in config.status, that substitutes the proper values into |
| 14804 | # config.h.in to produce config.h. |
| 14805 | |
| 14806 | # Create a delimiter string that does not exist in confdefs.h, to ease |
| 14807 | # handling of long lines. |
| 14808 | ac_delim='%!_!# ' |
| 14809 | for ac_last_try in false false :; do |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14810 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
| 14811 | if test -z "$ac_tt"; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14812 | break |
| 14813 | elif $ac_last_try; then |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14814 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14815 | else |
| 14816 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " |
| 14817 | fi |
| 14818 | done |
| 14819 | |
| 14820 | # For the awk script, D is an array of macro values keyed by name, |
| 14821 | # likewise P contains macro parameters if any. Preserve backslash |
| 14822 | # newline sequences. |
| 14823 | |
| 14824 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* |
| 14825 | sed -n ' |
| 14826 | s/.\{148\}/&'"$ac_delim"'/g |
| 14827 | t rset |
| 14828 | :rset |
| 14829 | s/^[ ]*#[ ]*define[ ][ ]*/ / |
| 14830 | t def |
| 14831 | d |
| 14832 | :def |
| 14833 | s/\\$// |
| 14834 | t bsnl |
| 14835 | s/["\\]/\\&/g |
| 14836 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14837 | D["\1"]=" \3"/p |
| 14838 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p |
| 14839 | d |
| 14840 | :bsnl |
| 14841 | s/["\\]/\\&/g |
| 14842 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ |
| 14843 | D["\1"]=" \3\\\\\\n"\\/p |
| 14844 | t cont |
| 14845 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p |
| 14846 | t cont |
| 14847 | d |
| 14848 | :cont |
| 14849 | n |
| 14850 | s/.\{148\}/&'"$ac_delim"'/g |
| 14851 | t clear |
| 14852 | :clear |
| 14853 | s/\\$// |
| 14854 | t bsnlc |
| 14855 | s/["\\]/\\&/g; s/^/"/; s/$/"/p |
| 14856 | d |
| 14857 | :bsnlc |
| 14858 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p |
| 14859 | b cont |
| 14860 | ' <confdefs.h | sed ' |
| 14861 | s/'"$ac_delim"'/"\\\ |
| 14862 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 |
| 14863 | |
| 14864 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 14865 | for (key in D) D_is_set[key] = 1 |
| 14866 | FS = "" |
| 14867 | } |
| 14868 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { |
| 14869 | line = \$ 0 |
| 14870 | split(line, arg, " ") |
| 14871 | if (arg[1] == "#") { |
| 14872 | defundef = arg[2] |
| 14873 | mac1 = arg[3] |
| 14874 | } else { |
| 14875 | defundef = substr(arg[1], 2) |
| 14876 | mac1 = arg[2] |
| 14877 | } |
| 14878 | split(mac1, mac2, "(") #) |
| 14879 | macro = mac2[1] |
| 14880 | prefix = substr(line, 1, index(line, defundef) - 1) |
| 14881 | if (D_is_set[macro]) { |
| 14882 | # Preserve the white space surrounding the "#". |
| 14883 | print prefix "define", macro P[macro] D[macro] |
| 14884 | next |
| 14885 | } else { |
| 14886 | # Replace #undef with comments. This is necessary, for example, |
| 14887 | # in the case of _POSIX_SOURCE, which is predefined and required |
| 14888 | # on some systems where configure will not decide to define it. |
| 14889 | if (defundef == "undef") { |
| 14890 | print "/*", prefix defundef, macro, "*/" |
| 14891 | next |
| 14892 | } |
| 14893 | } |
| 14894 | } |
| 14895 | { print } |
| 14896 | _ACAWK |
| 14897 | _ACEOF |
| 14898 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14899 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14900 | fi # test -n "$CONFIG_HEADERS" |
| 14901 | |
| 14902 | |
| 14903 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " |
| 14904 | shift |
| 14905 | for ac_tag |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14906 | do |
| 14907 | case $ac_tag in |
| 14908 | :[FHLC]) ac_mode=$ac_tag; continue;; |
| 14909 | esac |
| 14910 | case $ac_mode$ac_tag in |
| 14911 | :[FHL]*:*);; |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14912 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14913 | :[FH]-) ac_tag=-:-;; |
| 14914 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; |
| 14915 | esac |
| 14916 | ac_save_IFS=$IFS |
| 14917 | IFS=: |
| 14918 | set x $ac_tag |
| 14919 | IFS=$ac_save_IFS |
| 14920 | shift |
| 14921 | ac_file=$1 |
| 14922 | shift |
| 14923 | |
| 14924 | case $ac_mode in |
| 14925 | :L) ac_source=$1;; |
| 14926 | :[FH]) |
| 14927 | ac_file_inputs= |
| 14928 | for ac_f |
| 14929 | do |
| 14930 | case $ac_f in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14931 | -) ac_f="$ac_tmp/stdin";; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14932 | *) # Look for the file first in the build tree, then in the source tree |
| 14933 | # (if the path is not absolute). The absolute path cannot be DOS-style, |
| 14934 | # because $ac_f cannot contain `:'. |
| 14935 | test -f "$ac_f" || |
| 14936 | case $ac_f in |
| 14937 | [\\/$]*) false;; |
| 14938 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; |
| 14939 | esac || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14940 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14941 | esac |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14942 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
| 14943 | as_fn_append ac_file_inputs " '$ac_f'" |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14944 | done |
| 14945 | |
| 14946 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
| 14947 | # use $as_me), people would be surprised to read: |
| 14948 | # /* config.h. Generated by config.status. */ |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14949 | configure_input='Generated from '` |
| 14950 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' |
| 14951 | `' by configure.' |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14952 | if test x"$ac_file" != x-; then |
| 14953 | configure_input="$ac_file. $configure_input" |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14954 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
| 14955 | $as_echo "$as_me: creating $ac_file" >&6;} |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14956 | fi |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14957 | # Neutralize special characters interpreted by sed in replacement strings. |
| 14958 | case $configure_input in #( |
| 14959 | *\&* | *\|* | *\\* ) |
| 14960 | ac_sed_conf_input=`$as_echo "$configure_input" | |
| 14961 | sed 's/[\\\\&|]/\\\\&/g'`;; #( |
| 14962 | *) ac_sed_conf_input=$configure_input;; |
| 14963 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14964 | |
| 14965 | case $ac_tag in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 14966 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
| 14967 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14968 | esac |
| 14969 | ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14970 | esac |
| 14971 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14972 | ac_dir=`$as_dirname -- "$ac_file" || |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14973 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 14974 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
| 14975 | X"$ac_file" : 'X\(//\)$' \| \ |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14976 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14977 | $as_echo X"$ac_file" | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14978 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
| 14979 | s//\1/ |
| 14980 | q |
| 14981 | } |
| 14982 | /^X\(\/\/\)[^/].*/{ |
| 14983 | s//\1/ |
| 14984 | q |
| 14985 | } |
| 14986 | /^X\(\/\/\)$/{ |
| 14987 | s//\1/ |
| 14988 | q |
| 14989 | } |
| 14990 | /^X\(\/\).*/{ |
| 14991 | s//\1/ |
| 14992 | q |
| 14993 | } |
| 14994 | s/.*/./; q'` |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 14995 | as_dir="$ac_dir"; as_fn_mkdir_p |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 14996 | ac_builddir=. |
| 14997 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 14998 | case "$ac_dir" in |
| 14999 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 15000 | *) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15001 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15002 | # A ".." for each directory in $ac_dir_suffix. |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15003 | 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] | 15004 | case $ac_top_builddir_sub in |
| 15005 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; |
| 15006 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; |
| 15007 | esac ;; |
| 15008 | esac |
| 15009 | ac_abs_top_builddir=$ac_pwd |
| 15010 | ac_abs_builddir=$ac_pwd$ac_dir_suffix |
| 15011 | # for backward compatibility: |
| 15012 | ac_top_builddir=$ac_top_build_prefix |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15013 | |
| 15014 | case $srcdir in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15015 | .) # We are building in place. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15016 | ac_srcdir=. |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15017 | ac_top_srcdir=$ac_top_builddir_sub |
| 15018 | ac_abs_top_srcdir=$ac_pwd ;; |
| 15019 | [\\/]* | ?:[\\/]* ) # Absolute name. |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15020 | ac_srcdir=$srcdir$ac_dir_suffix; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15021 | ac_top_srcdir=$srcdir |
| 15022 | ac_abs_top_srcdir=$srcdir ;; |
| 15023 | *) # Relative name. |
| 15024 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix |
| 15025 | ac_top_srcdir=$ac_top_build_prefix$srcdir |
| 15026 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15027 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15028 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
Skip Montanaro | f0d5f79 | 2004-08-15 14:08:23 +0000 | [diff] [blame] | 15029 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15030 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15031 | case $ac_mode in |
| 15032 | :F) |
| 15033 | # |
| 15034 | # CONFIG_FILE |
| 15035 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15036 | |
| 15037 | case $INSTALL in |
| 15038 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15039 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15040 | esac |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 15041 | _ACEOF |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15042 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15043 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15044 | # If the template does not know about datarootdir, expand it. |
| 15045 | # FIXME: This hack should be removed a few years after 2.60. |
| 15046 | ac_datarootdir_hack=; ac_datarootdir_seen= |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15047 | ac_sed_dataroot=' |
| 15048 | /datarootdir/ { |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15049 | p |
| 15050 | q |
| 15051 | } |
| 15052 | /@datadir@/p |
| 15053 | /@docdir@/p |
| 15054 | /@infodir@/p |
| 15055 | /@localedir@/p |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15056 | /@mandir@/p' |
| 15057 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15058 | *datarootdir*) ac_datarootdir_seen=yes;; |
| 15059 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15060 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
| 15061 | $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] | 15062 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15063 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15064 | ac_datarootdir_hack=' |
| 15065 | s&@datadir@&$datadir&g |
| 15066 | s&@docdir@&$docdir&g |
| 15067 | s&@infodir@&$infodir&g |
| 15068 | s&@localedir@&$localedir&g |
| 15069 | s&@mandir@&$mandir&g |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15070 | s&\\\${datarootdir}&$datarootdir&g' ;; |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15071 | esac |
| 15072 | _ACEOF |
| 15073 | |
| 15074 | # Neutralize VPATH when `$srcdir' = `.'. |
| 15075 | # Shell code in configure.ac might set extrasub. |
| 15076 | # FIXME: do we really want to maintain this feature? |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15077 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
| 15078 | ac_sed_extra="$ac_vpsub |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15079 | $extrasub |
| 15080 | _ACEOF |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15081 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15082 | :t |
| 15083 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15084 | s|@configure_input@|$ac_sed_conf_input|;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15085 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15086 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15087 | s&@srcdir@&$ac_srcdir&;t t |
| 15088 | s&@abs_srcdir@&$ac_abs_srcdir&;t t |
| 15089 | s&@top_srcdir@&$ac_top_srcdir&;t t |
| 15090 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t |
| 15091 | s&@builddir@&$ac_builddir&;t t |
| 15092 | s&@abs_builddir@&$ac_abs_builddir&;t t |
| 15093 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
| 15094 | s&@INSTALL@&$ac_INSTALL&;t t |
| 15095 | $ac_datarootdir_hack |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15096 | " |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15097 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
| 15098 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 15099 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15100 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15101 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
| 15102 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ |
| 15103 | "$ac_tmp/out"`; test -z "$ac_out"; } && |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15104 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15105 | which seems to be undefined. Please make sure it is defined" >&5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15106 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15107 | which seems to be undefined. Please make sure it is defined" >&2;} |
Thomas Wouters | 1ba5b3b | 2006-06-08 14:52:47 +0000 | [diff] [blame] | 15108 | |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15109 | rm -f "$ac_tmp/stdin" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15110 | case $ac_file in |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15111 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
| 15112 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15113 | esac \ |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15114 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15115 | ;; |
| 15116 | :H) |
| 15117 | # |
| 15118 | # CONFIG_HEADER |
| 15119 | # |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15120 | if test x"$ac_file" != x-; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15121 | { |
| 15122 | $as_echo "/* $configure_input */" \ |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15123 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
| 15124 | } >"$ac_tmp/config.h" \ |
| 15125 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
| 15126 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15127 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
| 15128 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15129 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15130 | rm -f "$ac_file" |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15131 | mv "$ac_tmp/config.h" "$ac_file" \ |
| 15132 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15133 | fi |
| 15134 | else |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15135 | $as_echo "/* $configure_input */" \ |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15136 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
| 15137 | || as_fn_error $? "could not create -" "$LINENO" 5 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15138 | fi |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15139 | ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 15140 | |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15141 | |
| 15142 | esac |
| 15143 | |
Antoine Pitrou | 8e6b407 | 2010-09-10 19:44:44 +0000 | [diff] [blame] | 15144 | |
| 15145 | case $ac_file$ac_mode in |
| 15146 | "Modules/ld_so_aix":F) chmod +x Modules/ld_so_aix ;; |
| 15147 | |
| 15148 | esac |
Thomas Wouters | 47b49bf | 2007-08-30 22:15:33 +0000 | [diff] [blame] | 15149 | done # for ac_tag |
| 15150 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15151 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15152 | as_fn_exit 0 |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15153 | _ACEOF |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15154 | ac_clean_files=$ac_clean_files_save |
| 15155 | |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15156 | test $ac_write_fail = 0 || |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15157 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15158 | |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15159 | |
| 15160 | # configure is writing to config.log, and then calls config.status. |
| 15161 | # config.status does its own redirection, appending to config.log. |
| 15162 | # Unfortunately, on DOS this fails, as config.log is still kept open |
| 15163 | # by configure, so config.status won't be able to write to it; its |
| 15164 | # output is simply discarded. So we exec the FD to /dev/null, |
| 15165 | # effectively closing config.log, so it can be properly (re)opened and |
| 15166 | # appended to by config.status. When coming back to configure, we |
| 15167 | # need to make the FD available again. |
| 15168 | if test "$no_create" != yes; then |
| 15169 | ac_cs_success=: |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15170 | ac_config_status_args= |
| 15171 | test "$silent" = yes && |
| 15172 | ac_config_status_args="$ac_config_status_args --quiet" |
Martin v. Löwis | 1143799 | 2002-04-12 09:54:03 +0000 | [diff] [blame] | 15173 | exec 5>/dev/null |
Skip Montanaro | 6dead95 | 2003-09-25 14:50:04 +0000 | [diff] [blame] | 15174 | $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] | 15175 | exec 5>>config.log |
| 15176 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which |
| 15177 | # would make configure fail if this is the last instruction. |
Martin v. Löwis | 9b142aa | 2011-02-05 20:26:52 +0000 | [diff] [blame] | 15178 | $ac_cs_success || as_fn_exit 1 |
Matthias Klose | b962171 | 2010-04-24 17:59:49 +0000 | [diff] [blame] | 15179 | fi |
| 15180 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
| 15181 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
| 15182 | $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] | 15183 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 15184 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15185 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15186 | echo "creating Modules/Setup" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15187 | if test ! -f Modules/Setup |
| 15188 | then |
| 15189 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 15190 | fi |
| 15191 | |
Thomas Wouters | 49fd7fa | 2006-04-21 10:40:58 +0000 | [diff] [blame] | 15192 | echo "creating Modules/Setup.local" |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 15193 | if test ! -f Modules/Setup.local |
| 15194 | then |
| 15195 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 15196 | fi |
| 15197 | |
| 15198 | echo "creating Makefile" |
| 15199 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 15200 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 15201 | Modules/Setup.local Modules/Setup |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 15202 | mv config.c Modules |