Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1 | #! /bin/sh |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3 | # From configure.in Revision: 1.221 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5 | # Guess values for system-dependent variables and create Makefiles. |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6 | # Generated automatically using autoconf version 2.13 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7 | # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 8 | # |
| 9 | # This configure script is free software; the Free Software Foundation |
| 10 | # gives unlimited permission to copy, distribute and modify it. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 11 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 12 | # Defaults: |
| 13 | ac_help= |
| 14 | ac_default_prefix=/usr/local |
| 15 | # Any additions from configure.in: |
| 16 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 17 | --with-next-archs='arch1 arch2 ..' build MAB binary" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 18 | ac_help="$ac_help |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 19 | --with-next-framework Build (OpenStep|Rhapsody|MacOSX|Darwin) framework" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 20 | ac_help="$ac_help |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 21 | --with-dyld Use (OpenStep|Rhapsody|MacOSX|Darwin) dynamic linker" |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 22 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 23 | --without-gcc never use gcc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 24 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 25 | --with-cxx=<compiler> enable C++ support" |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 26 | ac_help="$ac_help |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 27 | --with-suffix=.exe set executable suffix" |
| 28 | ac_help="$ac_help |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 29 | --enable-ipv6 Enable ipv6 (with ipv4) support |
| 30 | --disable-ipv6 Disable ipv6 support" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 31 | ac_help="$ac_help |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 32 | --with-pydebug build with Py_DEBUG defined" |
| 33 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 34 | --with-libs='lib1 ...' link against additional libs" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 35 | ac_help="$ac_help |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 36 | --with-signal-module disable/enable signal module" |
| 37 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 38 | --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 39 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 40 | --with(out)-threads[=DIRECTORY] disable/enable thread support" |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 41 | ac_help="$ac_help |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 42 | --with(out)-thread[=DIRECTORY] deprecated; use --with(out)-threads" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 43 | ac_help="$ac_help |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 44 | --with-pth use GNU pth threading libraries" |
| 45 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 46 | --with(out)-cycle-gc disable/enable garbage collection" |
| 47 | ac_help="$ac_help |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 48 | --with(out)-pymalloc disable/enable specialized mallocs" |
| 49 | ac_help="$ac_help |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 50 | --with-wctype-functions use wctype.h functions" |
| 51 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 52 | --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 53 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 54 | --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 55 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 56 | --with-fpectl enable SIGFPE catching" |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 57 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 58 | --with-libm=STRING math library" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 59 | ac_help="$ac_help |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 60 | --with-libc=STRING C library" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 61 | ac_help="$ac_help |
| 62 | --enable-unicode[=ucs2,ucs4] Enable Unicode strings (default is yes)" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 63 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 64 | # Initialize some variables set by options. |
| 65 | # The variables have the same names as the options, with |
| 66 | # dashes changed to underlines. |
| 67 | build=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 68 | cache_file=./config.cache |
| 69 | exec_prefix=NONE |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 70 | host=NONE |
| 71 | no_create= |
| 72 | nonopt=NONE |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 73 | no_recursion= |
| 74 | prefix=NONE |
| 75 | program_prefix=NONE |
| 76 | program_suffix=NONE |
| 77 | program_transform_name=s,x,x, |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 78 | silent= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 79 | site= |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 80 | srcdir= |
| 81 | target=NONE |
| 82 | verbose= |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 83 | x_includes=NONE |
| 84 | x_libraries=NONE |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 85 | bindir='${exec_prefix}/bin' |
| 86 | sbindir='${exec_prefix}/sbin' |
| 87 | libexecdir='${exec_prefix}/libexec' |
| 88 | datadir='${prefix}/share' |
| 89 | sysconfdir='${prefix}/etc' |
| 90 | sharedstatedir='${prefix}/com' |
| 91 | localstatedir='${prefix}/var' |
| 92 | libdir='${exec_prefix}/lib' |
| 93 | includedir='${prefix}/include' |
| 94 | oldincludedir='/usr/include' |
| 95 | infodir='${prefix}/info' |
| 96 | mandir='${prefix}/man' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 97 | |
| 98 | # Initialize some other variables. |
| 99 | subdirs= |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 100 | MFLAGS= MAKEFLAGS= |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 101 | SHELL=${CONFIG_SHELL-/bin/sh} |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 102 | # Maximum number of lines to put in a shell here document. |
| 103 | ac_max_here_lines=12 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 104 | |
| 105 | ac_prev= |
| 106 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 107 | do |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 108 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 109 | # If the previous option needs an argument, assign it. |
| 110 | if test -n "$ac_prev"; then |
| 111 | eval "$ac_prev=\$ac_option" |
| 112 | ac_prev= |
| 113 | continue |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 114 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 115 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 116 | case "$ac_option" in |
| 117 | -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; |
| 118 | *) ac_optarg= ;; |
| 119 | esac |
| 120 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 121 | # Accept the important Cygnus configure options, so we can diagnose typos. |
| 122 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 123 | case "$ac_option" in |
| 124 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 125 | -bindir | --bindir | --bindi | --bind | --bin | --bi) |
| 126 | ac_prev=bindir ;; |
| 127 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) |
| 128 | bindir="$ac_optarg" ;; |
| 129 | |
| 130 | -build | --build | --buil | --bui | --bu) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 131 | ac_prev=build ;; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 132 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 133 | build="$ac_optarg" ;; |
| 134 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 135 | -cache-file | --cache-file | --cache-fil | --cache-fi \ |
| 136 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) |
| 137 | ac_prev=cache_file ;; |
| 138 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ |
| 139 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) |
| 140 | cache_file="$ac_optarg" ;; |
| 141 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 142 | -datadir | --datadir | --datadi | --datad | --data | --dat | --da) |
| 143 | ac_prev=datadir ;; |
| 144 | -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ |
| 145 | | --da=*) |
| 146 | datadir="$ac_optarg" ;; |
| 147 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 148 | -disable-* | --disable-*) |
| 149 | ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 150 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 151 | if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 152 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 153 | fi |
| 154 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 155 | eval "enable_${ac_feature}=no" ;; |
| 156 | |
| 157 | -enable-* | --enable-*) |
| 158 | ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 159 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 160 | if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 161 | { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 162 | fi |
| 163 | ac_feature=`echo $ac_feature| sed 's/-/_/g'` |
| 164 | case "$ac_option" in |
| 165 | *=*) ;; |
| 166 | *) ac_optarg=yes ;; |
| 167 | esac |
| 168 | eval "enable_${ac_feature}='$ac_optarg'" ;; |
| 169 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 170 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ |
| 171 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ |
| 172 | | --exec | --exe | --ex) |
| 173 | ac_prev=exec_prefix ;; |
| 174 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 175 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ |
| 176 | | --exec=* | --exe=* | --ex=*) |
| 177 | exec_prefix="$ac_optarg" ;; |
| 178 | |
| 179 | -gas | --gas | --ga | --g) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 180 | # Obsolete; use --with-gas. |
| 181 | with_gas=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 182 | |
| 183 | -help | --help | --hel | --he) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 184 | # Omit some internal or obsolete options to make the list less imposing. |
| 185 | # This message is too long to be a string in the A/UX 3.1 sh. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 186 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 187 | Usage: configure [options] [host] |
| 188 | Options: [defaults in brackets after descriptions] |
| 189 | Configuration: |
| 190 | --cache-file=FILE cache test results in FILE |
| 191 | --help print this message |
| 192 | --no-create do not create output files |
| 193 | --quiet, --silent do not print \`checking...' messages |
| 194 | --version print the version of autoconf that created configure |
| 195 | Directory and file names: |
| 196 | --prefix=PREFIX install architecture-independent files in PREFIX |
| 197 | [$ac_default_prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 198 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 199 | [same as prefix] |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 200 | --bindir=DIR user executables in DIR [EPREFIX/bin] |
| 201 | --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] |
| 202 | --libexecdir=DIR program executables in DIR [EPREFIX/libexec] |
| 203 | --datadir=DIR read-only architecture-independent data in DIR |
| 204 | [PREFIX/share] |
| 205 | --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] |
| 206 | --sharedstatedir=DIR modifiable architecture-independent data in DIR |
| 207 | [PREFIX/com] |
| 208 | --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] |
| 209 | --libdir=DIR object code libraries in DIR [EPREFIX/lib] |
| 210 | --includedir=DIR C header files in DIR [PREFIX/include] |
| 211 | --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] |
| 212 | --infodir=DIR info documentation in DIR [PREFIX/info] |
| 213 | --mandir=DIR man documentation in DIR [PREFIX/man] |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 214 | --srcdir=DIR find the sources in DIR [configure dir or ..] |
| 215 | --program-prefix=PREFIX prepend PREFIX to installed program names |
| 216 | --program-suffix=SUFFIX append SUFFIX to installed program names |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 217 | --program-transform-name=PROGRAM |
| 218 | run sed PROGRAM on installed program names |
| 219 | EOF |
| 220 | cat << EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 221 | Host type: |
| 222 | --build=BUILD configure for building on BUILD [BUILD=HOST] |
| 223 | --host=HOST configure for HOST [guessed] |
| 224 | --target=TARGET configure for TARGET [TARGET=HOST] |
| 225 | Features and packages: |
| 226 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
| 227 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] |
| 228 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] |
| 229 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) |
| 230 | --x-includes=DIR X include files are in DIR |
| 231 | --x-libraries=DIR X library files are in DIR |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 232 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 233 | if test -n "$ac_help"; then |
| 234 | echo "--enable and --with options recognized:$ac_help" |
| 235 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 236 | exit 0 ;; |
| 237 | |
| 238 | -host | --host | --hos | --ho) |
| 239 | ac_prev=host ;; |
| 240 | -host=* | --host=* | --hos=* | --ho=*) |
| 241 | host="$ac_optarg" ;; |
| 242 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 243 | -includedir | --includedir | --includedi | --included | --include \ |
| 244 | | --includ | --inclu | --incl | --inc) |
| 245 | ac_prev=includedir ;; |
| 246 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ |
| 247 | | --includ=* | --inclu=* | --incl=* | --inc=*) |
| 248 | includedir="$ac_optarg" ;; |
| 249 | |
| 250 | -infodir | --infodir | --infodi | --infod | --info | --inf) |
| 251 | ac_prev=infodir ;; |
| 252 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) |
| 253 | infodir="$ac_optarg" ;; |
| 254 | |
| 255 | -libdir | --libdir | --libdi | --libd) |
| 256 | ac_prev=libdir ;; |
| 257 | -libdir=* | --libdir=* | --libdi=* | --libd=*) |
| 258 | libdir="$ac_optarg" ;; |
| 259 | |
| 260 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ |
| 261 | | --libexe | --libex | --libe) |
| 262 | ac_prev=libexecdir ;; |
| 263 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ |
| 264 | | --libexe=* | --libex=* | --libe=*) |
| 265 | libexecdir="$ac_optarg" ;; |
| 266 | |
| 267 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
| 268 | | --localstate | --localstat | --localsta | --localst \ |
| 269 | | --locals | --local | --loca | --loc | --lo) |
| 270 | ac_prev=localstatedir ;; |
| 271 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ |
| 272 | | --localstate=* | --localstat=* | --localsta=* | --localst=* \ |
| 273 | | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) |
| 274 | localstatedir="$ac_optarg" ;; |
| 275 | |
| 276 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) |
| 277 | ac_prev=mandir ;; |
| 278 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) |
| 279 | mandir="$ac_optarg" ;; |
| 280 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 281 | -nfp | --nfp | --nf) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 282 | # Obsolete; use --without-fp. |
| 283 | with_fp=no ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 284 | |
| 285 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 286 | | --no-cr | --no-c) |
| 287 | no_create=yes ;; |
| 288 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 289 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 290 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) |
| 291 | no_recursion=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 292 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 293 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ |
| 294 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ |
| 295 | | --oldin | --oldi | --old | --ol | --o) |
| 296 | ac_prev=oldincludedir ;; |
| 297 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ |
| 298 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ |
| 299 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) |
| 300 | oldincludedir="$ac_optarg" ;; |
| 301 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 302 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) |
| 303 | ac_prev=prefix ;; |
| 304 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) |
| 305 | prefix="$ac_optarg" ;; |
| 306 | |
| 307 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ |
| 308 | | --program-pre | --program-pr | --program-p) |
| 309 | ac_prev=program_prefix ;; |
| 310 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ |
| 311 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) |
| 312 | program_prefix="$ac_optarg" ;; |
| 313 | |
| 314 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ |
| 315 | | --program-suf | --program-su | --program-s) |
| 316 | ac_prev=program_suffix ;; |
| 317 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ |
| 318 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) |
| 319 | program_suffix="$ac_optarg" ;; |
| 320 | |
| 321 | -program-transform-name | --program-transform-name \ |
| 322 | | --program-transform-nam | --program-transform-na \ |
| 323 | | --program-transform-n | --program-transform- \ |
| 324 | | --program-transform | --program-transfor \ |
| 325 | | --program-transfo | --program-transf \ |
| 326 | | --program-trans | --program-tran \ |
| 327 | | --progr-tra | --program-tr | --program-t) |
| 328 | ac_prev=program_transform_name ;; |
| 329 | -program-transform-name=* | --program-transform-name=* \ |
| 330 | | --program-transform-nam=* | --program-transform-na=* \ |
| 331 | | --program-transform-n=* | --program-transform-=* \ |
| 332 | | --program-transform=* | --program-transfor=* \ |
| 333 | | --program-transfo=* | --program-transf=* \ |
| 334 | | --program-trans=* | --program-tran=* \ |
| 335 | | --progr-tra=* | --program-tr=* | --program-t=*) |
| 336 | program_transform_name="$ac_optarg" ;; |
| 337 | |
| 338 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
| 339 | | -silent | --silent | --silen | --sile | --sil) |
| 340 | silent=yes ;; |
| 341 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 342 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) |
| 343 | ac_prev=sbindir ;; |
| 344 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ |
| 345 | | --sbi=* | --sb=*) |
| 346 | sbindir="$ac_optarg" ;; |
| 347 | |
| 348 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ |
| 349 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ |
| 350 | | --sharedst | --shareds | --shared | --share | --shar \ |
| 351 | | --sha | --sh) |
| 352 | ac_prev=sharedstatedir ;; |
| 353 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ |
| 354 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ |
| 355 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ |
| 356 | | --sha=* | --sh=*) |
| 357 | sharedstatedir="$ac_optarg" ;; |
| 358 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 359 | -site | --site | --sit) |
| 360 | ac_prev=site ;; |
| 361 | -site=* | --site=* | --sit=*) |
| 362 | site="$ac_optarg" ;; |
| 363 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 364 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) |
| 365 | ac_prev=srcdir ;; |
| 366 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) |
| 367 | srcdir="$ac_optarg" ;; |
| 368 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 369 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ |
| 370 | | --syscon | --sysco | --sysc | --sys | --sy) |
| 371 | ac_prev=sysconfdir ;; |
| 372 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ |
| 373 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) |
| 374 | sysconfdir="$ac_optarg" ;; |
| 375 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 376 | -target | --target | --targe | --targ | --tar | --ta | --t) |
| 377 | ac_prev=target ;; |
| 378 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
| 379 | target="$ac_optarg" ;; |
| 380 | |
| 381 | -v | -verbose | --verbose | --verbos | --verbo | --verb) |
| 382 | verbose=yes ;; |
| 383 | |
| 384 | -version | --version | --versio | --versi | --vers) |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 385 | echo "configure generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 386 | exit 0 ;; |
| 387 | |
| 388 | -with-* | --with-*) |
| 389 | ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 390 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 391 | if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 392 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 393 | fi |
| 394 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 395 | case "$ac_option" in |
| 396 | *=*) ;; |
| 397 | *) ac_optarg=yes ;; |
| 398 | esac |
| 399 | eval "with_${ac_package}='$ac_optarg'" ;; |
| 400 | |
| 401 | -without-* | --without-*) |
| 402 | ac_package=`echo $ac_option|sed -e 's/-*without-//'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 403 | # Reject names that are not valid shell variable names. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 404 | if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 405 | { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 406 | fi |
| 407 | ac_package=`echo $ac_package| sed 's/-/_/g'` |
| 408 | eval "with_${ac_package}=no" ;; |
| 409 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 410 | --x) |
| 411 | # Obsolete; use --with-x. |
| 412 | with_x=yes ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 413 | |
| 414 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ |
| 415 | | --x-incl | --x-inc | --x-in | --x-i) |
| 416 | ac_prev=x_includes ;; |
| 417 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ |
| 418 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) |
| 419 | x_includes="$ac_optarg" ;; |
| 420 | |
| 421 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ |
| 422 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) |
| 423 | ac_prev=x_libraries ;; |
| 424 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ |
| 425 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) |
| 426 | x_libraries="$ac_optarg" ;; |
| 427 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 428 | -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 429 | ;; |
| 430 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 431 | *) |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 432 | if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 433 | echo "configure: warning: $ac_option: invalid host type" 1>&2 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 434 | fi |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 435 | if test "x$nonopt" != xNONE; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 436 | { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 437 | fi |
| 438 | nonopt="$ac_option" |
| 439 | ;; |
| 440 | |
| 441 | esac |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 442 | done |
| 443 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 444 | if test -n "$ac_prev"; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 445 | { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 446 | fi |
| 447 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 448 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 449 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 450 | # File descriptor usage: |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 451 | # 0 standard input |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 452 | # 1 file creation |
| 453 | # 2 errors and warnings |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 454 | # 3 some systems may open it to /dev/tty |
| 455 | # 4 used on the Kubota Titan |
| 456 | # 6 checking for... messages and results |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 457 | # 5 compiler messages saved in config.log |
| 458 | if test "$silent" = yes; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 459 | exec 6>/dev/null |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 460 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 461 | exec 6>&1 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 462 | fi |
| 463 | exec 5>./config.log |
| 464 | |
| 465 | echo "\ |
| 466 | This file contains any messages produced by compilers while |
| 467 | running configure, to aid debugging if configure makes a mistake. |
| 468 | " 1>&5 |
| 469 | |
| 470 | # Strip out --no-create and --no-recursion so they do not pile up. |
| 471 | # Also quote any args containing shell metacharacters. |
| 472 | ac_configure_args= |
| 473 | for ac_arg |
| 474 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 475 | case "$ac_arg" in |
| 476 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ |
| 477 | | --no-cr | --no-c) ;; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 478 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ |
| 479 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; |
| 480 | *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) |
| 481 | ac_configure_args="$ac_configure_args '$ac_arg'" ;; |
| 482 | *) ac_configure_args="$ac_configure_args $ac_arg" ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 483 | esac |
| 484 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 485 | |
| 486 | # NLS nuisances. |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 487 | # Only set these to C if already set. These must not be set unconditionally |
| 488 | # because not all systems understand e.g. LANG=C (notably SCO). |
| 489 | # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! |
| 490 | # Non-C LC_CTYPE values break the ctype check. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 491 | if test "${LANG+set}" = set; then LANG=C; export LANG; fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 492 | if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi |
| 493 | if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi |
| 494 | if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 495 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 496 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
| 497 | rm -rf conftest* confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 498 | # AIX cpp loses on an empty file, so make sure it contains at least a newline. |
| 499 | echo > confdefs.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 500 | |
| 501 | # A filename unique to this package, relative to the directory that |
| 502 | # configure is in, which we can look for to find out if srcdir is correct. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 503 | ac_unique_file=Include/object.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 504 | |
| 505 | # Find the source files, if location was not specified. |
| 506 | if test -z "$srcdir"; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 507 | ac_srcdir_defaulted=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 508 | # Try the directory containing this script, then its parent. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 509 | ac_prog=$0 |
| 510 | ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` |
| 511 | test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. |
| 512 | srcdir=$ac_confdir |
| 513 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 514 | srcdir=.. |
| 515 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 516 | else |
| 517 | ac_srcdir_defaulted=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 518 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 519 | if test ! -r $srcdir/$ac_unique_file; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 520 | if test "$ac_srcdir_defaulted" = yes; then |
| 521 | { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 522 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 523 | { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 524 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 525 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 526 | srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` |
| 527 | |
| 528 | # Prefer explicitly selected file to automatically selected ones. |
| 529 | if test -z "$CONFIG_SITE"; then |
| 530 | if test "x$prefix" != xNONE; then |
| 531 | CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" |
| 532 | else |
| 533 | CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" |
| 534 | fi |
| 535 | fi |
| 536 | for ac_site_file in $CONFIG_SITE; do |
| 537 | if test -r "$ac_site_file"; then |
| 538 | echo "loading site script $ac_site_file" |
| 539 | . "$ac_site_file" |
| 540 | fi |
| 541 | done |
| 542 | |
| 543 | if test -r "$cache_file"; then |
| 544 | echo "loading cache $cache_file" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 545 | . $cache_file |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 546 | else |
| 547 | echo "creating cache $cache_file" |
| 548 | > $cache_file |
| 549 | fi |
| 550 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 551 | ac_ext=c |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 552 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 553 | ac_cpp='$CPP $CPPFLAGS' |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 554 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 555 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 556 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 557 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 558 | ac_exeext= |
| 559 | ac_objext=o |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 560 | if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then |
| 561 | # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. |
| 562 | if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then |
| 563 | ac_n= ac_c=' |
| 564 | ' ac_t=' ' |
| 565 | else |
| 566 | ac_n=-n ac_c= ac_t= |
| 567 | fi |
| 568 | else |
| 569 | ac_n= ac_c='\c' ac_t= |
| 570 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 571 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 572 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 573 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 574 | |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 575 | # Set VERSION so we only need to edit in one place (i.e., here) |
| 576 | |
Guido van Rossum | 6db412b | 2001-04-18 04:37:57 +0000 | [diff] [blame] | 577 | VERSION=2.2 |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 578 | |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 579 | # Arguments passed to configure. |
| 580 | |
| 581 | CONFIG_ARGS="$ac_configure_args" |
| 582 | |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 583 | # NEXTSTEP|MacOSX|Darwin stuff |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 584 | if test -f /usr/lib/NextStep/software_version -o -f /System/Library/CoreServices/software_version ; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 585 | |
| 586 | echo $ac_n "checking for --with-next-archs""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 587 | echo "configure:588: checking for --with-next-archs" >&5 |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 588 | # Check whether --with-next-archs or --without-next-archs was given. |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 589 | if test "${with_next_archs+set}" = set; then |
| 590 | withval="$with_next_archs" |
| 591 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 592 | if test -n "$withval"; then |
| 593 | ac_arch_flags=`/usr/lib/arch_tool -archify_list $withval` |
| 594 | # GCC does not currently support multi archs on the NeXT |
| 595 | with_gcc=no |
| 596 | fi |
| 597 | echo "$ac_t""$with_next_archs" 1>&6 |
| 598 | |
| 599 | else |
| 600 | echo "$ac_t""none: using `arch`" 1>&6 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 601 | fi |
| 602 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 603 | |
| 604 | if test -z "$MACHDEP" |
| 605 | then |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 606 | ac_sys_system=`uname -s` |
| 607 | if test "$ac_sys_system" = "Darwin" ; then |
| 608 | ac_sys_release=`uname -r` |
| 609 | else |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 610 | set X `hostinfo | egrep '(NeXT Mach|Kernel Release).*:' | \ |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 611 | sed -e 's/://' -e 's/\./_/'` && \ |
| 612 | ac_sys_system=next && ac_sys_release=$4 |
| 613 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 614 | |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 615 | MACHDEP="$ac_sys_system$ac_sys_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 616 | fi |
| 617 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 618 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 619 | # Check whether --with-next-framework or --without-next-framework was given. |
| 620 | if test "${with_next_framework+set}" = set; then |
| 621 | withval="$with_next_framework" |
| 622 | : |
| 623 | fi |
| 624 | |
| 625 | # Check whether --with-dyld or --without-dyld was given. |
| 626 | if test "${with_dyld+set}" = set; then |
| 627 | withval="$with_dyld" |
| 628 | : |
| 629 | fi |
| 630 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 631 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 632 | # Set name for machine-dependent library files |
| 633 | |
| 634 | echo $ac_n "checking MACHDEP""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 635 | echo "configure:636: checking MACHDEP" >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 636 | if test -z "$MACHDEP" |
| 637 | then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 638 | ac_sys_system=`uname -s` |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 639 | if test "$ac_sys_system" = "AIX" -o \ |
| 640 | "$ac_sys_system" = "Monterey64" -o \ |
| 641 | "$ac_sys_system" = "UnixWare"; then |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 642 | ac_sys_release=`uname -v` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 643 | else |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 644 | ac_sys_release=`uname -r` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 645 | fi |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 646 | ac_md_system=`echo $ac_sys_system | |
| 647 | tr -d '/ ' | tr '[A-Z]' '[a-z]'` |
| 648 | ac_md_release=`echo $ac_sys_release | |
| 649 | tr -d '/ ' | sed 's/\..*//'` |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 650 | MACHDEP="$ac_md_system$ac_md_release" |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 651 | |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 652 | case $MACHDEP in |
Guido van Rossum | b97ef17 | 1997-09-28 05:44:03 +0000 | [diff] [blame] | 653 | '') MACHDEP="unknown";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 654 | esac |
| 655 | fi |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 656 | |
| 657 | # |
| 658 | # SGI compilers allow the specification of the both the ABI and the |
| 659 | # ISA on the command line. Depending on the values of these switches, |
| 660 | # different and often incompatable code will be generated. |
| 661 | # |
| 662 | # The SGI_ABI variable can be used to modify the CC and LDFLAGS and |
| 663 | # thus supply support for various ABI/ISA combinations. The MACHDEP |
| 664 | # variable is also adjusted. |
| 665 | # |
| 666 | |
| 667 | if test ! -z "$SGI_ABI" |
| 668 | then |
| 669 | CC="cc $SGI_ABI" |
| 670 | LDFLAGS="$SGI_ABI $LDFLAGS" |
| 671 | MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'` |
| 672 | fi |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 673 | echo "$ac_t""$MACHDEP" 1>&6 |
| 674 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 675 | # checks for alternative programs |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 676 | echo $ac_n "checking for --without-gcc""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 677 | echo "configure:678: checking for --without-gcc" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 678 | # Check whether --with-gcc or --without-gcc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 679 | if test "${with_gcc+set}" = set; then |
| 680 | withval="$with_gcc" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 681 | |
| 682 | case $withval in |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 683 | no) CC=cc |
| 684 | without_gcc=yes;; |
| 685 | yes) CC=gcc |
| 686 | without_gcc=no;; |
| 687 | *) CC=$withval |
| 688 | without_gcc=$withval;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 689 | esac |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 690 | else |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 691 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 692 | case $ac_sys_system in |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 693 | OSF1) CC=cc |
| 694 | without_gcc=;; |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 695 | AIX*) CC=cc_r |
| 696 | without_gcc=;; |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 697 | BeOS*) |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 698 | case $BE_HOST_CPU in |
| 699 | ppc) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 700 | CC=mwcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 701 | without_gcc=yes |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 702 | OPT="-O -D'DL_EXPORT(RTYPE)=__declspec(dllexport) RTYPE' -D'DL_IMPORT(RTYPE)=__declspec(dllexport) RTYPE' -export pragma" |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 703 | CCSHARED="-UDL_IMPORT -D'DL_IMPORT(RTYPE)=__declspec(dllimport) RTYPE'" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 704 | LDFLAGS="$LDFLAGS -nodup" |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 705 | ;; |
| 706 | x86) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 707 | CC=gcc |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 708 | without_gcc=no |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 709 | OPT=-O |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 710 | ;; |
| 711 | *) |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 712 | { echo "configure: error: Unknown BeOS platform \"$BE_HOST_CPU\"" 1>&2; exit 1; } |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 713 | ;; |
| 714 | esac |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 715 | AR="\$(srcdir)/Modules/ar_beos" |
| 716 | RANLIB=: |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 717 | ;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 718 | Monterey*) |
| 719 | RANLIB=: |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 720 | without_gcc= |
| 721 | ;; |
| 722 | UnixWare*) |
| 723 | RANLIB=: |
| 724 | without_gcc= |
| 725 | ;; |
| 726 | *) |
| 727 | without_gcc=no |
| 728 | ;; |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 729 | esac |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 730 | fi |
| 731 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 732 | echo "$ac_t""$without_gcc" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 733 | |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 734 | |
| 735 | |
Fred Drake | a1a84e7 | 2001-03-06 05:52:16 +0000 | [diff] [blame] | 736 | MAINOBJ=python.o |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 737 | echo $ac_n "checking for --with-cxx=<compiler>""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 738 | echo "configure:739: checking for --with-cxx=<compiler>" >&5 |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 739 | # Check whether --with-cxx or --without-cxx was given. |
| 740 | if test "${with_cxx+set}" = set; then |
| 741 | withval="$with_cxx" |
| 742 | |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 743 | check_cxx=no |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 744 | case $withval in |
| 745 | no) CXX= |
| 746 | with_cxx=no;; |
| 747 | *) CXX=$withval |
Fred Drake | a1a84e7 | 2001-03-06 05:52:16 +0000 | [diff] [blame] | 748 | MAINOBJ=ccpython.o |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 749 | with_cxx=$withval;; |
| 750 | esac |
| 751 | else |
| 752 | |
| 753 | with_cxx=no |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 754 | check_cxx=yes |
Guido van Rossum | 9501219 | 1999-12-16 17:50:52 +0000 | [diff] [blame] | 755 | |
| 756 | fi |
| 757 | |
| 758 | echo "$ac_t""$with_cxx" 1>&6 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 759 | |
| 760 | |
| 761 | if test "$check_cxx" = "yes" |
| 762 | then |
| 763 | for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl |
| 764 | do |
| 765 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 766 | set dummy $ac_prog; ac_word=$2 |
| 767 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 768 | echo "configure:769: checking for $ac_word" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 769 | if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then |
| 770 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 771 | else |
| 772 | if test -n "$CXX"; then |
| 773 | ac_cv_prog_CXX="$CXX" # Let the user override the test. |
| 774 | else |
| 775 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 776 | ac_dummy="$PATH" |
| 777 | for ac_dir in $ac_dummy; do |
| 778 | test -z "$ac_dir" && ac_dir=. |
| 779 | if test -f $ac_dir/$ac_word; then |
| 780 | ac_cv_prog_CXX="$ac_prog" |
| 781 | break |
| 782 | fi |
| 783 | done |
| 784 | IFS="$ac_save_ifs" |
| 785 | fi |
| 786 | fi |
| 787 | CXX="$ac_cv_prog_CXX" |
| 788 | if test -n "$CXX"; then |
| 789 | echo "$ac_t""$CXX" 1>&6 |
| 790 | else |
| 791 | echo "$ac_t""no" 1>&6 |
| 792 | fi |
| 793 | |
| 794 | test -n "$CXX" && break |
| 795 | done |
| 796 | test -n "$CXX" || CXX="notfound" |
| 797 | |
| 798 | if test "$CXX" = "notfound" |
| 799 | then |
| 800 | CXX= |
| 801 | else |
| 802 | echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 803 | echo "configure:804: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 804 | |
| 805 | ac_ext=C |
| 806 | # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 807 | ac_cpp='$CXXCPP $CPPFLAGS' |
| 808 | ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 809 | ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 810 | cross_compiling=$ac_cv_prog_cxx_cross |
| 811 | |
| 812 | cat > conftest.$ac_ext << EOF |
| 813 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 814 | #line 815 "configure" |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 815 | #include "confdefs.h" |
| 816 | |
| 817 | int main(){return(0);} |
| 818 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 819 | if { (eval echo configure:820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 820 | ac_cv_prog_cxx_works=yes |
| 821 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 822 | if (./conftest; exit) 2>/dev/null; then |
| 823 | ac_cv_prog_cxx_cross=no |
| 824 | else |
| 825 | ac_cv_prog_cxx_cross=yes |
| 826 | fi |
| 827 | else |
| 828 | echo "configure: failed program was:" >&5 |
| 829 | cat conftest.$ac_ext >&5 |
| 830 | ac_cv_prog_cxx_works=no |
| 831 | fi |
| 832 | rm -fr conftest* |
| 833 | ac_ext=c |
| 834 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 835 | ac_cpp='$CPP $CPPFLAGS' |
| 836 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 837 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 838 | cross_compiling=$ac_cv_prog_cc_cross |
| 839 | |
| 840 | echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6 |
| 841 | if test $ac_cv_prog_cxx_works = no; then |
| 842 | { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; } |
| 843 | fi |
| 844 | echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 845 | echo "configure:846: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5 |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 846 | echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6 |
| 847 | cross_compiling=$ac_cv_prog_cxx_cross |
| 848 | |
| 849 | fi |
| 850 | fi |
| 851 | |
Guido van Rossum | 8b131c5 | 1995-03-09 14:10:13 +0000 | [diff] [blame] | 852 | # If the user switches compilers, we can't believe the cache |
| 853 | if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC" |
| 854 | then |
| 855 | { echo "configure: error: cached CC is different -- throw away $cache_file |
| 856 | (it is also a good idea to do 'make clean' before compiling)" 1>&2; exit 1; } |
| 857 | fi |
| 858 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 859 | # Extract the first word of "gcc", so it can be a program name with args. |
| 860 | set dummy gcc; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 861 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 862 | echo "configure:863: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 863 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 864 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 865 | else |
| 866 | if test -n "$CC"; then |
| 867 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 868 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 869 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 870 | ac_dummy="$PATH" |
| 871 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 872 | test -z "$ac_dir" && ac_dir=. |
| 873 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 874 | ac_cv_prog_CC="gcc" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 875 | break |
| 876 | fi |
| 877 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 878 | IFS="$ac_save_ifs" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 879 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 880 | fi |
| 881 | CC="$ac_cv_prog_CC" |
| 882 | if test -n "$CC"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 883 | echo "$ac_t""$CC" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 884 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 885 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 886 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 887 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 888 | if test -z "$CC"; then |
| 889 | # Extract the first word of "cc", so it can be a program name with args. |
| 890 | set dummy cc; ac_word=$2 |
| 891 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 892 | echo "configure:893: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 893 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 894 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 895 | else |
| 896 | if test -n "$CC"; then |
| 897 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 898 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 899 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 900 | ac_prog_rejected=no |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 901 | ac_dummy="$PATH" |
| 902 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 903 | test -z "$ac_dir" && ac_dir=. |
| 904 | if test -f $ac_dir/$ac_word; then |
| 905 | if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then |
| 906 | ac_prog_rejected=yes |
| 907 | continue |
| 908 | fi |
| 909 | ac_cv_prog_CC="cc" |
| 910 | break |
| 911 | fi |
| 912 | done |
| 913 | IFS="$ac_save_ifs" |
| 914 | if test $ac_prog_rejected = yes; then |
| 915 | # We found a bogon in the path, so make sure we never use it. |
| 916 | set dummy $ac_cv_prog_CC |
| 917 | shift |
| 918 | if test $# -gt 0; then |
| 919 | # We chose a different compiler from the bogus one. |
| 920 | # However, it has the same basename, so the bogon will be chosen |
| 921 | # first if we set CC to just the basename; use the full file name. |
| 922 | shift |
| 923 | set dummy "$ac_dir/$ac_word" "$@" |
| 924 | shift |
| 925 | ac_cv_prog_CC="$@" |
| 926 | fi |
| 927 | fi |
| 928 | fi |
| 929 | fi |
| 930 | CC="$ac_cv_prog_CC" |
| 931 | if test -n "$CC"; then |
| 932 | echo "$ac_t""$CC" 1>&6 |
| 933 | else |
| 934 | echo "$ac_t""no" 1>&6 |
| 935 | fi |
| 936 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 937 | if test -z "$CC"; then |
| 938 | case "`uname -s`" in |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 939 | *win32* | *WIN32*) |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 940 | # Extract the first word of "cl", so it can be a program name with args. |
| 941 | set dummy cl; ac_word=$2 |
| 942 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 943 | echo "configure:944: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 944 | if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 945 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 946 | else |
| 947 | if test -n "$CC"; then |
| 948 | ac_cv_prog_CC="$CC" # Let the user override the test. |
| 949 | else |
| 950 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 951 | ac_dummy="$PATH" |
| 952 | for ac_dir in $ac_dummy; do |
| 953 | test -z "$ac_dir" && ac_dir=. |
| 954 | if test -f $ac_dir/$ac_word; then |
| 955 | ac_cv_prog_CC="cl" |
| 956 | break |
| 957 | fi |
| 958 | done |
| 959 | IFS="$ac_save_ifs" |
| 960 | fi |
| 961 | fi |
| 962 | CC="$ac_cv_prog_CC" |
| 963 | if test -n "$CC"; then |
| 964 | echo "$ac_t""$CC" 1>&6 |
| 965 | else |
| 966 | echo "$ac_t""no" 1>&6 |
| 967 | fi |
| 968 | ;; |
| 969 | esac |
| 970 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 971 | test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } |
| 972 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 973 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 974 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 975 | echo "configure:976: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 976 | |
| 977 | ac_ext=c |
| 978 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 979 | ac_cpp='$CPP $CPPFLAGS' |
| 980 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 981 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 982 | cross_compiling=$ac_cv_prog_cc_cross |
| 983 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 984 | cat > conftest.$ac_ext << EOF |
| 985 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 986 | #line 987 "configure" |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 987 | #include "confdefs.h" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 988 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 989 | main(){return(0);} |
| 990 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 991 | if { (eval echo configure:992: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 992 | ac_cv_prog_cc_works=yes |
| 993 | # If we can't run a trivial program, we are probably using a cross compiler. |
| 994 | if (./conftest; exit) 2>/dev/null; then |
| 995 | ac_cv_prog_cc_cross=no |
| 996 | else |
| 997 | ac_cv_prog_cc_cross=yes |
| 998 | fi |
| 999 | else |
| 1000 | echo "configure: failed program was:" >&5 |
| 1001 | cat conftest.$ac_ext >&5 |
| 1002 | ac_cv_prog_cc_works=no |
| 1003 | fi |
| 1004 | rm -fr conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1005 | ac_ext=c |
| 1006 | # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. |
| 1007 | ac_cpp='$CPP $CPPFLAGS' |
| 1008 | ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' |
| 1009 | ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' |
| 1010 | cross_compiling=$ac_cv_prog_cc_cross |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1011 | |
| 1012 | echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 |
| 1013 | if test $ac_cv_prog_cc_works = no; then |
| 1014 | { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } |
| 1015 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1016 | echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1017 | echo "configure:1018: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1018 | echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 |
| 1019 | cross_compiling=$ac_cv_prog_cc_cross |
| 1020 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1021 | echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1022 | echo "configure:1023: checking whether we are using GNU C" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1023 | if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1024 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1025 | else |
| 1026 | cat > conftest.c <<EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1027 | #ifdef __GNUC__ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1028 | yes; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1029 | #endif |
| 1030 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1031 | if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1032: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1032 | ac_cv_prog_gcc=yes |
| 1033 | else |
| 1034 | ac_cv_prog_gcc=no |
| 1035 | fi |
| 1036 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1037 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1038 | echo "$ac_t""$ac_cv_prog_gcc" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1039 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1040 | if test $ac_cv_prog_gcc = yes; then |
| 1041 | GCC=yes |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1042 | else |
| 1043 | GCC= |
| 1044 | fi |
| 1045 | |
| 1046 | ac_test_CFLAGS="${CFLAGS+set}" |
| 1047 | ac_save_CFLAGS="$CFLAGS" |
| 1048 | CFLAGS= |
| 1049 | echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1050 | echo "configure:1051: checking whether ${CC-cc} accepts -g" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1051 | if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1052 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1053 | else |
| 1054 | echo 'void f(){}' > conftest.c |
| 1055 | if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1056 | ac_cv_prog_cc_g=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1057 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1058 | ac_cv_prog_cc_g=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1059 | fi |
| 1060 | rm -f conftest* |
| 1061 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1062 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1063 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1064 | echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1065 | if test "$ac_test_CFLAGS" = set; then |
| 1066 | CFLAGS="$ac_save_CFLAGS" |
| 1067 | elif test $ac_cv_prog_cc_g = yes; then |
| 1068 | if test "$GCC" = yes; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1069 | CFLAGS="-g -O2" |
| 1070 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1071 | CFLAGS="-g" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1072 | fi |
| 1073 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1074 | if test "$GCC" = yes; then |
| 1075 | CFLAGS="-O2" |
| 1076 | else |
| 1077 | CFLAGS= |
| 1078 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1079 | fi |
| 1080 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1081 | echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1082 | echo "configure:1083: checking for Cygwin environment" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1083 | if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then |
| 1084 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1085 | else |
| 1086 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1087 | #line 1088 "configure" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1088 | #include "confdefs.h" |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1089 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1090 | int main() { |
| 1091 | |
| 1092 | #ifndef __CYGWIN__ |
| 1093 | #define __CYGWIN__ __CYGWIN32__ |
| 1094 | #endif |
| 1095 | return __CYGWIN__; |
| 1096 | ; return 0; } |
| 1097 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1098 | if { (eval echo configure:1099: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1099 | rm -rf conftest* |
| 1100 | ac_cv_cygwin=yes |
| 1101 | else |
| 1102 | echo "configure: failed program was:" >&5 |
| 1103 | cat conftest.$ac_ext >&5 |
| 1104 | rm -rf conftest* |
| 1105 | ac_cv_cygwin=no |
| 1106 | fi |
| 1107 | rm -f conftest* |
| 1108 | rm -f conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1109 | fi |
| 1110 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1111 | echo "$ac_t""$ac_cv_cygwin" 1>&6 |
| 1112 | CYGWIN= |
| 1113 | test "$ac_cv_cygwin" = yes && CYGWIN=yes |
| 1114 | echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1115 | echo "configure:1116: checking for mingw32 environment" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1116 | if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then |
| 1117 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1118 | else |
| 1119 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1120 | #line 1121 "configure" |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1121 | #include "confdefs.h" |
| 1122 | |
| 1123 | int main() { |
| 1124 | return __MINGW32__; |
| 1125 | ; return 0; } |
| 1126 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1127 | if { (eval echo configure:1128: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1128 | rm -rf conftest* |
| 1129 | ac_cv_mingw32=yes |
| 1130 | else |
| 1131 | echo "configure: failed program was:" >&5 |
| 1132 | cat conftest.$ac_ext >&5 |
| 1133 | rm -rf conftest* |
| 1134 | ac_cv_mingw32=no |
| 1135 | fi |
| 1136 | rm -f conftest* |
| 1137 | rm -f conftest* |
| 1138 | fi |
| 1139 | |
| 1140 | echo "$ac_t""$ac_cv_mingw32" 1>&6 |
| 1141 | MINGW32= |
| 1142 | test "$ac_cv_mingw32" = yes && MINGW32=yes |
| 1143 | |
| 1144 | |
| 1145 | echo $ac_n "checking for executable suffix""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1146 | echo "configure:1147: checking for executable suffix" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1147 | if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then |
| 1148 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1149 | else |
| 1150 | if test "$CYGWIN" = yes || test "$MINGW32" = yes; then |
| 1151 | ac_cv_exeext=.exe |
| 1152 | else |
| 1153 | rm -f conftest* |
| 1154 | echo 'int main () { return 0; }' > conftest.$ac_ext |
| 1155 | ac_cv_exeext= |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1156 | if { (eval echo configure:1157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1157 | for file in conftest.*; do |
| 1158 | case $file in |
| 1159 | *.c | *.o | *.obj) ;; |
| 1160 | *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;; |
| 1161 | esac |
| 1162 | done |
| 1163 | else |
| 1164 | { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; } |
| 1165 | fi |
| 1166 | rm -f conftest* |
| 1167 | test x"${ac_cv_exeext}" = x && ac_cv_exeext=no |
| 1168 | fi |
| 1169 | fi |
| 1170 | |
| 1171 | EXEEXT="" |
| 1172 | test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext} |
| 1173 | echo "$ac_t""${ac_cv_exeext}" 1>&6 |
| 1174 | ac_exeext=$EXEEXT |
| 1175 | |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 1176 | echo $ac_n "checking for --with-suffix""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1177 | echo "configure:1178: checking for --with-suffix" >&5 |
Neil Schemenauer | dfb38e4 | 2001-01-27 06:57:08 +0000 | [diff] [blame] | 1178 | # Check whether --with-suffix or --without-suffix was given. |
| 1179 | if test "${with_suffix+set}" = set; then |
| 1180 | withval="$with_suffix" |
| 1181 | |
| 1182 | case $withval in |
| 1183 | no) EXEEXT=;; |
| 1184 | yes) EXEEXT=.exe;; |
| 1185 | *) EXEEXT=$withval;; |
| 1186 | esac |
| 1187 | fi |
| 1188 | |
| 1189 | echo "$ac_t""$EXEEXT" 1>&6 |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1190 | |
Guido van Rossum | dd997f7 | 1998-10-07 19:58:26 +0000 | [diff] [blame] | 1191 | case $MACHDEP in |
| 1192 | bsdos*) |
| 1193 | case $CC in |
| 1194 | gcc) CC="$CC -D_HAVE_BSDI";; |
| 1195 | esac;; |
| 1196 | esac |
| 1197 | |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1198 | case $ac_sys_system in |
| 1199 | hp*|HP*) |
| 1200 | case $CC in |
Guido van Rossum | cd5ff9f | 2000-09-22 16:15:54 +0000 | [diff] [blame] | 1201 | cc|*/cc) CC="$CC -Ae";; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1202 | esac;; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1203 | Monterey*) |
| 1204 | case $CC in |
| 1205 | cc) CC="$CC -Wl,-Bexport";; |
| 1206 | esac;; |
Martin v. Löwis | a30c100 | 2001-03-06 12:10:20 +0000 | [diff] [blame] | 1207 | SunOS*) |
| 1208 | # Some functions have a prototype only with that define, e.g. confstr |
| 1209 | cat >> confdefs.h <<\EOF |
| 1210 | #define __EXTENSIONS__ 1 |
| 1211 | EOF |
| 1212 | |
| 1213 | ;; |
Guido van Rossum | 24b1e75 | 1997-08-21 02:29:16 +0000 | [diff] [blame] | 1214 | esac |
| 1215 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1216 | |
Martin v. Löwis | a30c100 | 2001-03-06 12:10:20 +0000 | [diff] [blame] | 1217 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1218 | echo $ac_n "checking LIBRARY""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1219 | echo "configure:1220: checking LIBRARY" >&5 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1220 | if test -z "$LIBRARY" |
| 1221 | then |
| 1222 | LIBRARY='libpython$(VERSION).a' |
| 1223 | fi |
| 1224 | echo "$ac_t""$LIBRARY" 1>&6 |
| 1225 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1226 | # LDLIBRARY is the name of the library to link against (as opposed to the |
| 1227 | # name of the library into which to insert object files). On systems |
| 1228 | # without shared libraries, LDLIBRARY is the same as LIBRARY (defined in |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1229 | # the Makefiles). On Cygwin LDLIBRARY is the import library, DLLLIBRARY is the |
| 1230 | # shared (i.e., DLL) library. |
| 1231 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1232 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 1233 | LDLIBRARY="$LIBRARY" |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 1234 | DLLLIBRARY='' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1235 | |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1236 | # LINKCC is the command that links the python executable -- default is $(CC). |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1237 | # This is altered for AIX in order to build the export list before |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1238 | # linking. |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1239 | |
| 1240 | echo $ac_n "checking LINKCC""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1241 | echo "configure:1242: checking LINKCC" >&5 |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1242 | if test -z "$LINKCC" |
| 1243 | then |
| 1244 | case $ac_sys_system in |
| 1245 | AIX*) |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 1246 | LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp \"\" \$(LIBRARY); \$(PURIFY) \$(CC)";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 1247 | dgux*) |
| 1248 | LINKCC="LD_RUN_PATH=$libdir \$(PURIFY) \$(CC)";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1249 | Monterey64*) |
| 1250 | LINKCC="\$(PURIFY) \$(CC) -L/usr/lib/ia64l64";; |
Guido van Rossum | 25f9303 | 1997-08-18 16:00:04 +0000 | [diff] [blame] | 1251 | *) LINKCC="\$(PURIFY) \$(CC)";; |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 1252 | esac |
| 1253 | fi |
| 1254 | echo "$ac_t""$LINKCC" 1>&6 |
| 1255 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1256 | echo $ac_n "checking LDLIBRARY""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1257 | echo "configure:1258: checking LDLIBRARY" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1258 | |
| 1259 | # NeXT framework builds require that the 'ar' library be converted into |
| 1260 | # a bundle using libtool. |
| 1261 | if test "$with_next_framework" |
| 1262 | then |
| 1263 | LDLIBRARY='libpython$(VERSION).dylib' |
| 1264 | fi |
| 1265 | |
| 1266 | # DG/UX requires some fancy ld contortions to produce a .so from an .a |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1267 | case $MACHDEP in |
| 1268 | dguxR4) |
| 1269 | LDLIBRARY='libpython$(VERSION).so' |
| 1270 | OPT="$OPT -pic" |
| 1271 | ;; |
| 1272 | beos*) |
| 1273 | LDLIBRARY='libpython$(VERSION).so' |
| 1274 | ;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1275 | cygwin*) |
| 1276 | LDLIBRARY='libpython$(VERSION).dll.a' |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1277 | DLLLIBRARY='libpython$(VERSION).dll' |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1278 | ;; |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 1279 | unixware*) |
| 1280 | LDLIBRARY='libpython$(VERSION).so' |
| 1281 | ;; |
Fred Drake | 5790be1 | 2000-10-09 17:06:13 +0000 | [diff] [blame] | 1282 | esac |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 1283 | echo "$ac_t""$LDLIBRARY" 1>&6 |
| 1284 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1285 | # Extract the first word of "ranlib", so it can be a program name with args. |
| 1286 | set dummy ranlib; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1287 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1288 | echo "configure:1289: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1289 | if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1290 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1291 | else |
| 1292 | if test -n "$RANLIB"; then |
| 1293 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. |
| 1294 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1295 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1296 | ac_dummy="$PATH" |
| 1297 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1298 | test -z "$ac_dir" && ac_dir=. |
| 1299 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1300 | ac_cv_prog_RANLIB="ranlib" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1301 | break |
| 1302 | fi |
| 1303 | done |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1304 | IFS="$ac_save_ifs" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1305 | test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1306 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1307 | fi |
| 1308 | RANLIB="$ac_cv_prog_RANLIB" |
| 1309 | if test -n "$RANLIB"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1310 | echo "$ac_t""$RANLIB" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1311 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1312 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1313 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1314 | |
| 1315 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1316 | for ac_prog in ar aal |
| 1317 | do |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1318 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
| 1319 | set dummy $ac_prog; ac_word=$2 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1320 | echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1321 | echo "configure:1322: checking for $ac_word" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1322 | if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1323 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1324 | else |
| 1325 | if test -n "$AR"; then |
| 1326 | ac_cv_prog_AR="$AR" # Let the user override the test. |
| 1327 | else |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1328 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" |
| 1329 | ac_dummy="$PATH" |
| 1330 | for ac_dir in $ac_dummy; do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1331 | test -z "$ac_dir" && ac_dir=. |
| 1332 | if test -f $ac_dir/$ac_word; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1333 | ac_cv_prog_AR="$ac_prog" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1334 | break |
| 1335 | fi |
| 1336 | done |
| 1337 | IFS="$ac_save_ifs" |
| 1338 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1339 | fi |
| 1340 | AR="$ac_cv_prog_AR" |
| 1341 | if test -n "$AR"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1342 | echo "$ac_t""$AR" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1343 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1344 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1345 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1346 | |
| 1347 | test -n "$AR" && break |
| 1348 | done |
| 1349 | test -n "$AR" || AR="ar" |
| 1350 | |
Neil Schemenauer | a42c827 | 2001-03-31 00:01:55 +0000 | [diff] [blame] | 1351 | |
| 1352 | case $MACHDEP in |
| 1353 | bsdos*) |
| 1354 | # install -d does not work on BSDI |
| 1355 | if test -z "$INSTALL" |
| 1356 | then |
| 1357 | INSTALL="${srcdir}/install-sh -c" |
| 1358 | fi |
| 1359 | esac |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1360 | ac_aux_dir= |
| 1361 | for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do |
| 1362 | if test -f $ac_dir/install-sh; then |
| 1363 | ac_aux_dir=$ac_dir |
| 1364 | ac_install_sh="$ac_aux_dir/install-sh -c" |
| 1365 | break |
| 1366 | elif test -f $ac_dir/install.sh; then |
| 1367 | ac_aux_dir=$ac_dir |
| 1368 | ac_install_sh="$ac_aux_dir/install.sh -c" |
| 1369 | break |
| 1370 | fi |
| 1371 | done |
| 1372 | if test -z "$ac_aux_dir"; then |
| 1373 | { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1374 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1375 | ac_config_guess=$ac_aux_dir/config.guess |
| 1376 | ac_config_sub=$ac_aux_dir/config.sub |
| 1377 | ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. |
| 1378 | |
| 1379 | # Find a good install program. We prefer a C program (faster), |
| 1380 | # so one script is as good as another. But avoid the broken or |
| 1381 | # incompatible versions: |
| 1382 | # SysV /etc/install, /usr/sbin/install |
| 1383 | # SunOS /usr/etc/install |
| 1384 | # IRIX /sbin/install |
| 1385 | # AIX /bin/install |
| 1386 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
| 1387 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
| 1388 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" |
| 1389 | # ./install, which can be erroneously created by make from ./install.sh. |
| 1390 | echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1391 | echo "configure:1392: checking for a BSD compatible install" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1392 | if test -z "$INSTALL"; then |
| 1393 | if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then |
| 1394 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1395 | else |
| 1396 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" |
| 1397 | for ac_dir in $PATH; do |
| 1398 | # Account for people who put trailing slashes in PATH elements. |
| 1399 | case "$ac_dir/" in |
| 1400 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; |
| 1401 | *) |
| 1402 | # OSF1 and SCO ODT 3.0 have their own names for install. |
| 1403 | # Don't use installbsd from OSF since it installs stuff as root |
| 1404 | # by default. |
| 1405 | for ac_prog in ginstall scoinst install; do |
| 1406 | if test -f $ac_dir/$ac_prog; then |
| 1407 | if test $ac_prog = install && |
| 1408 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then |
| 1409 | # AIX install. It has an incompatible calling convention. |
| 1410 | : |
| 1411 | else |
| 1412 | ac_cv_path_install="$ac_dir/$ac_prog -c" |
| 1413 | break 2 |
| 1414 | fi |
| 1415 | fi |
| 1416 | done |
| 1417 | ;; |
| 1418 | esac |
| 1419 | done |
| 1420 | IFS="$ac_save_IFS" |
| 1421 | |
| 1422 | fi |
| 1423 | if test "${ac_cv_path_install+set}" = set; then |
| 1424 | INSTALL="$ac_cv_path_install" |
| 1425 | else |
| 1426 | # As a last resort, use the slow shell script. We don't cache a |
| 1427 | # path for INSTALL within a source directory, because that will |
| 1428 | # break other packages using the cache if that directory is |
| 1429 | # removed, or if the path is relative. |
| 1430 | INSTALL="$ac_install_sh" |
| 1431 | fi |
| 1432 | fi |
| 1433 | echo "$ac_t""$INSTALL" 1>&6 |
| 1434 | |
| 1435 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
| 1436 | # It thinks the first close brace ends the variable substitution. |
| 1437 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' |
| 1438 | |
| 1439 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' |
| 1440 | |
| 1441 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
| 1442 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1443 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1444 | # Not every filesystem supports hard links |
| 1445 | |
| 1446 | if test -z "$LN" ; then |
| 1447 | case $ac_sys_system in |
| 1448 | BeOS*) LN="ln -s";; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 1449 | CYGWIN*) LN="ln -s";; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 1450 | *) LN=ln;; |
| 1451 | esac |
| 1452 | fi |
| 1453 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 1454 | # Optimizer/debugger flags |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1455 | |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1456 | if test -z "$OPT" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1457 | then |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1458 | case $GCC in |
| 1459 | yes) |
| 1460 | case $ac_cv_prog_cc_g in |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 1461 | yes) |
| 1462 | OPT="-g -O2 -Wall -Wstrict-prototypes";; |
| 1463 | *) |
| 1464 | OPT="-O2 -Wall -Wstrict-prototypes";; |
Guido van Rossum | edca74a | 1997-07-18 23:29:40 +0000 | [diff] [blame] | 1465 | esac |
| 1466 | ;; |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 1467 | *) |
| 1468 | case $ac_sys_system in |
| 1469 | UnixWare*) |
| 1470 | OPT="-O -K pentium,host,inline,loop_unroll,alloca ";; |
| 1471 | *) |
| 1472 | OPT="-O";; |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 1473 | esac |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 1474 | esac |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 1475 | fi |
| 1476 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 1477 | # The current (beta) Monterey compiler dies with optimizations |
| 1478 | case $ac_sys_system in |
| 1479 | Monterey*) OPT="";; |
| 1480 | esac |
| 1481 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 1482 | if test "$ac_arch_flags" |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 1483 | then |
| 1484 | OPT="$OPT $ac_arch_flags" |
| 1485 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1486 | # checks for UNIX variants that set C preprocessor variables |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1487 | echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1488 | echo "configure:1489: checking how to run the C preprocessor" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1489 | # On Suns, sometimes $CPP names a directory. |
| 1490 | if test -n "$CPP" && test -d "$CPP"; then |
| 1491 | CPP= |
| 1492 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1493 | if test -z "$CPP"; then |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1494 | if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1495 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1496 | else |
| 1497 | # This must be in double quotes, not single quotes, because CPP may get |
| 1498 | # substituted into the Makefile and "${CC-cc}" will confuse make. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1499 | CPP="${CC-cc} -E" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1500 | # On the NeXT, cc -E runs the code through the compiler's parser, |
| 1501 | # not just through cpp. |
| 1502 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1503 | #line 1504 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1504 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1505 | #include <assert.h> |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1506 | Syntax Error |
| 1507 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1508 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1509 | { (eval echo configure:1510: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1510 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1511 | if test -z "$ac_err"; then |
| 1512 | : |
| 1513 | else |
| 1514 | echo "$ac_err" >&5 |
| 1515 | echo "configure: failed program was:" >&5 |
| 1516 | cat conftest.$ac_ext >&5 |
| 1517 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1518 | CPP="${CC-cc} -E -traditional-cpp" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1519 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1520 | #line 1521 "configure" |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1521 | #include "confdefs.h" |
| 1522 | #include <assert.h> |
| 1523 | Syntax Error |
| 1524 | EOF |
| 1525 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1526 | { (eval echo configure:1527: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1527 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1528 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1529 | : |
| 1530 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1531 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1532 | echo "configure: failed program was:" >&5 |
| 1533 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1534 | rm -rf conftest* |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1535 | CPP="${CC-cc} -nologo -E" |
| 1536 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1537 | #line 1538 "configure" |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1538 | #include "confdefs.h" |
| 1539 | #include <assert.h> |
| 1540 | Syntax Error |
| 1541 | EOF |
| 1542 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1543 | { (eval echo configure:1544: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ff555e3 | 2000-09-22 15:38:21 +0000 | [diff] [blame] | 1544 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 1545 | if test -z "$ac_err"; then |
| 1546 | : |
| 1547 | else |
| 1548 | echo "$ac_err" >&5 |
| 1549 | echo "configure: failed program was:" >&5 |
| 1550 | cat conftest.$ac_ext >&5 |
| 1551 | rm -rf conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1552 | CPP=/lib/cpp |
| 1553 | fi |
| 1554 | rm -f conftest* |
| 1555 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1556 | rm -f conftest* |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1557 | fi |
| 1558 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1559 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1560 | fi |
Guido van Rossum | e77438c | 1995-09-13 18:59:59 +0000 | [diff] [blame] | 1561 | CPP="$ac_cv_prog_CPP" |
| 1562 | else |
| 1563 | ac_cv_prog_CPP="$CPP" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1564 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1565 | echo "$ac_t""$CPP" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1566 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1567 | echo $ac_n "checking for AIX""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1568 | echo "configure:1569: checking for AIX" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1569 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1570 | #line 1571 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1571 | #include "confdefs.h" |
| 1572 | #ifdef _AIX |
| 1573 | yes |
| 1574 | #endif |
| 1575 | |
| 1576 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1577 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1578 | egrep "yes" >/dev/null 2>&1; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1579 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1580 | echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1581 | #define _ALL_SOURCE 1 |
| 1582 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1583 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1584 | else |
| 1585 | rm -rf conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1586 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1587 | fi |
| 1588 | rm -f conftest* |
| 1589 | |
| 1590 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1591 | ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1592 | echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1593 | echo "configure:1594: checking for minix/config.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1594 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1595 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1596 | else |
| 1597 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1598 | #line 1599 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1599 | #include "confdefs.h" |
| 1600 | #include <minix/config.h> |
| 1601 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1602 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1603 | { (eval echo configure:1604: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1604 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1605 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1606 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1607 | eval "ac_cv_header_$ac_safe=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1608 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1609 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1610 | echo "configure: failed program was:" >&5 |
| 1611 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1612 | rm -rf conftest* |
| 1613 | eval "ac_cv_header_$ac_safe=no" |
| 1614 | fi |
| 1615 | rm -f conftest* |
| 1616 | fi |
| 1617 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1618 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1619 | MINIX=yes |
| 1620 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1621 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1622 | MINIX= |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1623 | fi |
| 1624 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1625 | if test "$MINIX" = yes; then |
| 1626 | cat >> confdefs.h <<\EOF |
| 1627 | #define _POSIX_SOURCE 1 |
| 1628 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1629 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1630 | cat >> confdefs.h <<\EOF |
| 1631 | #define _POSIX_1_SOURCE 2 |
| 1632 | EOF |
| 1633 | |
| 1634 | cat >> confdefs.h <<\EOF |
| 1635 | #define _MINIX 1 |
| 1636 | EOF |
| 1637 | |
| 1638 | fi |
| 1639 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 1640 | |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1641 | echo $ac_n "checking whether $CC accepts -OPT:Olimit=0""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1642 | echo "configure:1643: checking whether $CC accepts -OPT:Olimit=0" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1643 | if eval "test \"`echo '$''{'ac_cv_opt_olimit_ok'+set}'`\" = set"; then |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1644 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1645 | else |
| 1646 | ac_save_cc="$CC" |
| 1647 | CC="$CC -OPT:Olimit=0" |
| 1648 | if test "$cross_compiling" = yes; then |
| 1649 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1650 | else |
| 1651 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1652 | #line 1653 "configure" |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1653 | #include "confdefs.h" |
| 1654 | int main() { return 0; } |
| 1655 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1656 | if { (eval echo configure:1657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 1657 | then |
| 1658 | ac_cv_opt_olimit_ok=yes |
| 1659 | else |
| 1660 | echo "configure: failed program was:" >&5 |
| 1661 | cat conftest.$ac_ext >&5 |
| 1662 | rm -fr conftest* |
| 1663 | ac_cv_opt_olimit_ok=no |
| 1664 | fi |
| 1665 | rm -fr conftest* |
| 1666 | fi |
| 1667 | |
| 1668 | CC="$ac_save_cc" |
| 1669 | fi |
| 1670 | |
| 1671 | echo "$ac_t""$ac_cv_opt_olimit_ok" 1>&6 |
Guido van Rossum | 2efa34b | 1997-10-23 17:43:11 +0000 | [diff] [blame] | 1672 | if test $ac_cv_opt_olimit_ok = yes; then |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 1673 | case $ac_sys_system in |
| 1674 | Darwin*) OPT="$OPT" ;; |
| 1675 | *) OPT="$OPT -OPT:Olimit=0";; |
| 1676 | esac |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1677 | else |
| 1678 | echo $ac_n "checking whether $CC accepts -Olimit 1500""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1679 | echo "configure:1680: checking whether $CC accepts -Olimit 1500" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1680 | if eval "test \"`echo '$''{'ac_cv_olimit_ok'+set}'`\" = set"; then |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1681 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 1682 | else |
| 1683 | ac_save_cc="$CC" |
| 1684 | CC="$CC -Olimit 1500" |
| 1685 | if test "$cross_compiling" = yes; then |
| 1686 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 1687 | else |
| 1688 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1689 | #line 1690 "configure" |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1690 | #include "confdefs.h" |
| 1691 | int main() { return 0; } |
| 1692 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1693 | if { (eval echo configure:1694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1694 | then |
| 1695 | ac_cv_olimit_ok=yes |
| 1696 | else |
| 1697 | echo "configure: failed program was:" >&5 |
| 1698 | cat conftest.$ac_ext >&5 |
| 1699 | rm -fr conftest* |
| 1700 | ac_cv_olimit_ok=no |
Guido van Rossum | 201afe5 | 1997-05-14 21:14:44 +0000 | [diff] [blame] | 1701 | fi |
Guido van Rossum | 6b3d77e | 1998-07-07 21:11:02 +0000 | [diff] [blame] | 1702 | rm -fr conftest* |
| 1703 | fi |
| 1704 | |
| 1705 | CC="$ac_save_cc" |
| 1706 | fi |
| 1707 | |
| 1708 | echo "$ac_t""$ac_cv_olimit_ok" 1>&6 |
| 1709 | if test $ac_cv_olimit_ok = yes; then |
| 1710 | OPT="$OPT -Olimit 1500" |
| 1711 | fi |
| 1712 | fi |
| 1713 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1714 | # Check for enable-ipv6 |
| 1715 | OPT="$OPT -Dss_family=__ss_family -Dss_len=__ss_len" |
| 1716 | echo $ac_n "checking whether to enable ipv6""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1717 | echo "configure:1718: checking whether to enable ipv6" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1718 | # Check whether --enable-ipv6 or --disable-ipv6 was given. |
| 1719 | if test "${enable_ipv6+set}" = set; then |
| 1720 | enableval="$enable_ipv6" |
| 1721 | case "$enableval" in |
| 1722 | no) |
| 1723 | echo "$ac_t""no" 1>&6 |
| 1724 | ipv6=no |
| 1725 | ;; |
| 1726 | *) echo "$ac_t""yes" 1>&6 |
| 1727 | cat >> confdefs.h <<\EOF |
| 1728 | #define ENABLE_IPV6 1 |
| 1729 | EOF |
| 1730 | |
| 1731 | ipv6=yes |
| 1732 | ;; |
| 1733 | esac |
| 1734 | else |
| 1735 | if test "$cross_compiling" = yes; then |
| 1736 | echo "$ac_t""no" 1>&6 |
| 1737 | ipv6=no |
| 1738 | |
| 1739 | else |
| 1740 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1741 | #line 1742 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1742 | #include "confdefs.h" |
| 1743 | /* AF_INET6 avalable check */ |
| 1744 | #include <sys/types.h> |
| 1745 | #include <sys/socket.h> |
| 1746 | main() |
| 1747 | { |
| 1748 | if (socket(AF_INET6, SOCK_STREAM, 0) < 0) |
| 1749 | exit(1); |
| 1750 | else |
| 1751 | exit(0); |
| 1752 | } |
| 1753 | |
| 1754 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1755 | if { (eval echo configure:1756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1756 | then |
| 1757 | echo "$ac_t""yes" 1>&6 |
| 1758 | cat >> confdefs.h <<\EOF |
| 1759 | #define ENABLE_IPV6 1 |
| 1760 | EOF |
| 1761 | |
| 1762 | ipv6=yes |
| 1763 | else |
| 1764 | echo "configure: failed program was:" >&5 |
| 1765 | cat conftest.$ac_ext >&5 |
| 1766 | rm -fr conftest* |
| 1767 | echo "$ac_t""no" 1>&6 |
| 1768 | ipv6=no |
| 1769 | fi |
| 1770 | rm -fr conftest* |
| 1771 | fi |
| 1772 | |
| 1773 | fi |
| 1774 | |
| 1775 | |
| 1776 | ipv6type=unknown |
| 1777 | ipv6lib=none |
| 1778 | ipv6trylibc=no |
| 1779 | |
| 1780 | if test "$ipv6" = "yes"; then |
| 1781 | echo $ac_n "checking ipv6 stack type""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1782 | echo "configure:1783: checking ipv6 stack type" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1783 | for i in inria kame linux-glibc linux-inet6 toshiba v6d zeta; do |
| 1784 | case $i in |
| 1785 | inria) |
| 1786 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1787 | #line 1788 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1788 | #include "confdefs.h" |
| 1789 | dnl |
| 1790 | #include <netinet/in.h> |
| 1791 | #ifdef IPV6_INRIA_VERSION |
| 1792 | yes |
| 1793 | #endif |
| 1794 | EOF |
| 1795 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1796 | egrep "yes" >/dev/null 2>&1; then |
| 1797 | rm -rf conftest* |
| 1798 | ipv6type=$i; |
| 1799 | OPT="-DINET6 $OPT" |
| 1800 | fi |
| 1801 | rm -f conftest* |
| 1802 | |
| 1803 | ;; |
| 1804 | kame) |
| 1805 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1806 | #line 1807 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1807 | #include "confdefs.h" |
| 1808 | dnl |
| 1809 | #include <netinet/in.h> |
| 1810 | #ifdef __KAME__ |
| 1811 | yes |
| 1812 | #endif |
| 1813 | EOF |
| 1814 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1815 | egrep "yes" >/dev/null 2>&1; then |
| 1816 | rm -rf conftest* |
| 1817 | ipv6type=$i; |
| 1818 | ipv6lib=inet6 |
| 1819 | ipv6libdir=/usr/local/v6/lib |
| 1820 | ipv6trylibc=yes |
| 1821 | OPT="-DINET6 $OPT" |
| 1822 | fi |
| 1823 | rm -f conftest* |
| 1824 | |
| 1825 | ;; |
| 1826 | linux-glibc) |
| 1827 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1828 | #line 1829 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1829 | #include "confdefs.h" |
| 1830 | dnl |
| 1831 | #include <features.h> |
| 1832 | #if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)) |
| 1833 | yes |
| 1834 | #endif |
| 1835 | EOF |
| 1836 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1837 | egrep "yes" >/dev/null 2>&1; then |
| 1838 | rm -rf conftest* |
| 1839 | ipv6type=$i; |
| 1840 | ipv6trylibc=yes |
| 1841 | OPT="-DINET6 $OPT" |
| 1842 | fi |
| 1843 | rm -f conftest* |
| 1844 | |
| 1845 | ;; |
| 1846 | linux-inet6) |
| 1847 | if test -d /usr/inet6; then |
| 1848 | ipv6type=$i |
| 1849 | ipv6lib=inet6 |
| 1850 | ipv6libdir=/usr/inet6/lib |
| 1851 | OPT="-DINET6 -I/usr/inet6/include $OPT" |
| 1852 | fi |
| 1853 | ;; |
| 1854 | toshiba) |
| 1855 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1856 | #line 1857 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1857 | #include "confdefs.h" |
| 1858 | dnl |
| 1859 | #include <sys/param.h> |
| 1860 | #ifdef _TOSHIBA_INET6 |
| 1861 | yes |
| 1862 | #endif |
| 1863 | EOF |
| 1864 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1865 | egrep "yes" >/dev/null 2>&1; then |
| 1866 | rm -rf conftest* |
| 1867 | ipv6type=$i; |
| 1868 | ipv6lib=inet6; |
| 1869 | ipv6libdir=/usr/local/v6/lib; |
| 1870 | OPT="-DINET6 $OPT" |
| 1871 | fi |
| 1872 | rm -f conftest* |
| 1873 | |
| 1874 | ;; |
| 1875 | v6d) |
| 1876 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1877 | #line 1878 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1878 | #include "confdefs.h" |
| 1879 | dnl |
| 1880 | #include </usr/local/v6/include/sys/v6config.h> |
| 1881 | #ifdef __V6D__ |
| 1882 | yes |
| 1883 | #endif |
| 1884 | EOF |
| 1885 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1886 | egrep "yes" >/dev/null 2>&1; then |
| 1887 | rm -rf conftest* |
| 1888 | ipv6type=$i; |
| 1889 | ipv6lib=v6; |
| 1890 | ipv6libdir=/usr/local/v6/lib; |
| 1891 | OPT="-I/usr/local/v6/include $OPT" |
| 1892 | fi |
| 1893 | rm -f conftest* |
| 1894 | |
| 1895 | ;; |
| 1896 | zeta) |
| 1897 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1898 | #line 1899 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 1899 | #include "confdefs.h" |
| 1900 | dnl |
| 1901 | #include <sys/param.h> |
| 1902 | #ifdef _ZETA_MINAMI_INET6 |
| 1903 | yes |
| 1904 | #endif |
| 1905 | EOF |
| 1906 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1907 | egrep "yes" >/dev/null 2>&1; then |
| 1908 | rm -rf conftest* |
| 1909 | ipv6type=$i; |
| 1910 | ipv6lib=inet6; |
| 1911 | ipv6libdir=/usr/local/v6/lib; |
| 1912 | OPT="-DINET6 $OPT" |
| 1913 | fi |
| 1914 | rm -f conftest* |
| 1915 | |
| 1916 | ;; |
| 1917 | esac |
| 1918 | if test "$ipv6type" != "unknown"; then |
| 1919 | break |
| 1920 | fi |
| 1921 | done |
| 1922 | echo "$ac_t""$ipv6type" 1>&6 |
| 1923 | fi |
| 1924 | |
| 1925 | if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then |
| 1926 | if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then |
| 1927 | LIBS="-L$ipv6libdir -l$ipv6lib $LIBS" |
| 1928 | echo "using lib$ipv6lib" |
| 1929 | else |
| 1930 | if test $ipv6trylibc = "yes"; then |
| 1931 | echo "using libc" |
| 1932 | else |
| 1933 | echo 'Fatal: no $ipv6lib library found. cannot continue.' |
| 1934 | echo "You need to fetch lib$ipv6lib.a from appropriate" |
| 1935 | echo 'ipv6 kit and compile beforehand.' |
| 1936 | exit 1 |
| 1937 | fi |
| 1938 | fi |
| 1939 | fi |
| 1940 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 1941 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1942 | # checks for header files |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1943 | echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1944 | echo "configure:1945: checking for ANSI C header files" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 1945 | if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 1946 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1947 | else |
| 1948 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1949 | #line 1950 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1950 | #include "confdefs.h" |
| 1951 | #include <stdlib.h> |
| 1952 | #include <stdarg.h> |
| 1953 | #include <string.h> |
| 1954 | #include <float.h> |
| 1955 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 1956 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1957 | { (eval echo configure:1958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 1958 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 1959 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1960 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1961 | ac_cv_header_stdc=yes |
| 1962 | else |
| 1963 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 1964 | echo "configure: failed program was:" >&5 |
| 1965 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 1966 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1967 | ac_cv_header_stdc=no |
| 1968 | fi |
| 1969 | rm -f conftest* |
| 1970 | |
| 1971 | if test $ac_cv_header_stdc = yes; then |
| 1972 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. |
| 1973 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1974 | #line 1975 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1975 | #include "confdefs.h" |
| 1976 | #include <string.h> |
| 1977 | EOF |
| 1978 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1979 | egrep "memchr" >/dev/null 2>&1; then |
| 1980 | : |
| 1981 | else |
| 1982 | rm -rf conftest* |
| 1983 | ac_cv_header_stdc=no |
| 1984 | fi |
| 1985 | rm -f conftest* |
| 1986 | |
| 1987 | fi |
| 1988 | |
| 1989 | if test $ac_cv_header_stdc = yes; then |
| 1990 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. |
| 1991 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 1992 | #line 1993 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 1993 | #include "confdefs.h" |
| 1994 | #include <stdlib.h> |
| 1995 | EOF |
| 1996 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 1997 | egrep "free" >/dev/null 2>&1; then |
| 1998 | : |
| 1999 | else |
| 2000 | rm -rf conftest* |
| 2001 | ac_cv_header_stdc=no |
| 2002 | fi |
| 2003 | rm -f conftest* |
| 2004 | |
| 2005 | fi |
| 2006 | |
| 2007 | if test $ac_cv_header_stdc = yes; then |
| 2008 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. |
| 2009 | if test "$cross_compiling" = yes; then |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2010 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2011 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2012 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2013 | #line 2014 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2014 | #include "confdefs.h" |
| 2015 | #include <ctype.h> |
| 2016 | #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') |
| 2017 | #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2018 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2019 | int main () { int i; for (i = 0; i < 256; i++) |
| 2020 | if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2); |
| 2021 | exit (0); } |
| 2022 | |
| 2023 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2024 | if { (eval echo configure:2025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2025 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2026 | : |
| 2027 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2028 | echo "configure: failed program was:" >&5 |
| 2029 | cat conftest.$ac_ext >&5 |
| 2030 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2031 | ac_cv_header_stdc=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2032 | fi |
| 2033 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2034 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2035 | |
| 2036 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2037 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2038 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2039 | echo "$ac_t""$ac_cv_header_stdc" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2040 | if test $ac_cv_header_stdc = yes; then |
| 2041 | cat >> confdefs.h <<\EOF |
| 2042 | #define STDC_HEADERS 1 |
| 2043 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2044 | |
| 2045 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2046 | |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 2047 | for ac_hdr in dlfcn.h fcntl.h limits.h locale.h ncurses.h poll.h pthread.h \ |
Eric S. Raymond | d2d75d3 | 2001-01-16 15:26:34 +0000 | [diff] [blame] | 2048 | signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h termios.h \ |
Fred Drake | bbc3c5a | 2001-05-11 16:11:25 +0000 | [diff] [blame] | 2049 | sys/audioio.h sys/file.h sys/lock.h sys/modem.h db_185.h db.h \ |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 2050 | sys/param.h sys/select.h sys/socket.h sys/time.h sys/times.h \ |
Fred Drake | ae90f8d | 2000-09-15 03:38:12 +0000 | [diff] [blame] | 2051 | sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \ |
| 2052 | ndbm.h db1/ndbm.h gdbm/ndbm.h |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2053 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2054 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2055 | echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2056 | echo "configure:2057: checking for $ac_hdr" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2057 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2058 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2059 | else |
| 2060 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2061 | #line 2062 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2062 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2063 | #include <$ac_hdr> |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2064 | EOF |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2065 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2066 | { (eval echo configure:2067: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2067 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 2068 | if test -z "$ac_err"; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2069 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2070 | eval "ac_cv_header_$ac_safe=yes" |
| 2071 | else |
| 2072 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2073 | echo "configure: failed program was:" >&5 |
| 2074 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2075 | rm -rf conftest* |
| 2076 | eval "ac_cv_header_$ac_safe=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2077 | fi |
| 2078 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2079 | fi |
| 2080 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2081 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2082 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2083 | cat >> confdefs.h <<EOF |
| 2084 | #define $ac_tr_hdr 1 |
| 2085 | EOF |
| 2086 | |
| 2087 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2088 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2089 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2090 | done |
| 2091 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2092 | ac_header_dirent=no |
| 2093 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h |
| 2094 | do |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2095 | ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2096 | echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2097 | echo "configure:2098: checking for $ac_hdr that defines DIR" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2098 | if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2099 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2100 | else |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2101 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2102 | #line 2103 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2103 | #include "confdefs.h" |
| 2104 | #include <sys/types.h> |
| 2105 | #include <$ac_hdr> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2106 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2107 | DIR *dirp = 0; |
| 2108 | ; return 0; } |
| 2109 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2110 | if { (eval echo configure:2111: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2111 | rm -rf conftest* |
| 2112 | eval "ac_cv_header_dirent_$ac_safe=yes" |
| 2113 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2114 | echo "configure: failed program was:" >&5 |
| 2115 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2116 | rm -rf conftest* |
| 2117 | eval "ac_cv_header_dirent_$ac_safe=no" |
| 2118 | fi |
| 2119 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2120 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2121 | if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2122 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2123 | ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2124 | cat >> confdefs.h <<EOF |
| 2125 | #define $ac_tr_hdr 1 |
| 2126 | EOF |
| 2127 | ac_header_dirent=$ac_hdr; break |
| 2128 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2129 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2130 | fi |
| 2131 | done |
| 2132 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
| 2133 | if test $ac_header_dirent = dirent.h; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2134 | echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2135 | echo "configure:2136: checking for opendir in -ldir" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2136 | ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2137 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2138 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2139 | else |
| 2140 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2141 | LIBS="-ldir $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2142 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2143 | #line 2144 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2144 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2145 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2146 | /* We use char because int might match the return type of a gcc2 |
| 2147 | builtin and then its argument prototype would still apply. */ |
| 2148 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2149 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2150 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2151 | opendir() |
| 2152 | ; return 0; } |
| 2153 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2154 | if { (eval echo configure:2155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2155 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2156 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2157 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2158 | echo "configure: failed program was:" >&5 |
| 2159 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2160 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2161 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2162 | fi |
| 2163 | rm -f conftest* |
| 2164 | LIBS="$ac_save_LIBS" |
| 2165 | |
| 2166 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2167 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2168 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2169 | LIBS="$LIBS -ldir" |
| 2170 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2171 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2172 | fi |
| 2173 | |
| 2174 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2175 | echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2176 | echo "configure:2177: checking for opendir in -lx" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2177 | ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2178 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2179 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2180 | else |
| 2181 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2182 | LIBS="-lx $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2183 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2184 | #line 2185 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2185 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2186 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 2187 | /* We use char because int might match the return type of a gcc2 |
| 2188 | builtin and then its argument prototype would still apply. */ |
| 2189 | char opendir(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2190 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2191 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2192 | opendir() |
| 2193 | ; return 0; } |
| 2194 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2195 | if { (eval echo configure:2196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2196 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2197 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2198 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2199 | echo "configure: failed program was:" >&5 |
| 2200 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2201 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2202 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2203 | fi |
| 2204 | rm -f conftest* |
| 2205 | LIBS="$ac_save_LIBS" |
| 2206 | |
| 2207 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2208 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2209 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2210 | LIBS="$LIBS -lx" |
| 2211 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2212 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2213 | fi |
| 2214 | |
| 2215 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2216 | |
| 2217 | |
| 2218 | # checks for typedefs |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2219 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2220 | echo $ac_n "checking for clock_t in time.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2221 | echo "configure:2222: checking for clock_t in time.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2222 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2223 | #line 2224 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2224 | #include "confdefs.h" |
| 2225 | #include <time.h> |
| 2226 | EOF |
| 2227 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2228 | egrep "clock_t" >/dev/null 2>&1; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2229 | rm -rf conftest* |
| 2230 | was_it_defined=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2231 | else |
| 2232 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2233 | cat >> confdefs.h <<\EOF |
| 2234 | #define clock_t long |
| 2235 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2236 | |
| 2237 | fi |
| 2238 | rm -f conftest* |
| 2239 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2240 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 2241 | |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 2242 | # Add some code to confdefs.h so that the test for off_t works on SCO |
| 2243 | cat >> confdefs.h <<\EOF |
| 2244 | #if defined(SCO_DS) |
| 2245 | #undef _OFF_T |
| 2246 | #endif |
| 2247 | EOF |
| 2248 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2249 | # Type availability checks |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2250 | echo $ac_n "checking for mode_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2251 | echo "configure:2252: checking for mode_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2252 | if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2253 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2254 | else |
| 2255 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2256 | #line 2257 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2257 | #include "confdefs.h" |
| 2258 | #include <sys/types.h> |
| 2259 | #if STDC_HEADERS |
| 2260 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2261 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2262 | #endif |
| 2263 | EOF |
| 2264 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2265 | egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2266 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2267 | ac_cv_type_mode_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2268 | else |
| 2269 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2270 | ac_cv_type_mode_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2271 | fi |
| 2272 | rm -f conftest* |
| 2273 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2274 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2275 | echo "$ac_t""$ac_cv_type_mode_t" 1>&6 |
| 2276 | if test $ac_cv_type_mode_t = no; then |
| 2277 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2278 | #define mode_t int |
| 2279 | EOF |
| 2280 | |
| 2281 | fi |
| 2282 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2283 | echo $ac_n "checking for off_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2284 | echo "configure:2285: checking for off_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2285 | if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2286 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2287 | else |
| 2288 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2289 | #line 2290 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2290 | #include "confdefs.h" |
| 2291 | #include <sys/types.h> |
| 2292 | #if STDC_HEADERS |
| 2293 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2294 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2295 | #endif |
| 2296 | EOF |
| 2297 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2298 | egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2299 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2300 | ac_cv_type_off_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2301 | else |
| 2302 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2303 | ac_cv_type_off_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2304 | fi |
| 2305 | rm -f conftest* |
| 2306 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2307 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2308 | echo "$ac_t""$ac_cv_type_off_t" 1>&6 |
| 2309 | if test $ac_cv_type_off_t = no; then |
| 2310 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2311 | #define off_t long |
| 2312 | EOF |
| 2313 | |
| 2314 | fi |
| 2315 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2316 | echo $ac_n "checking for pid_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2317 | echo "configure:2318: checking for pid_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2318 | if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2319 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2320 | else |
| 2321 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2322 | #line 2323 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2323 | #include "confdefs.h" |
| 2324 | #include <sys/types.h> |
| 2325 | #if STDC_HEADERS |
| 2326 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2327 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2328 | #endif |
| 2329 | EOF |
| 2330 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2331 | egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2332 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2333 | ac_cv_type_pid_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2334 | else |
| 2335 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2336 | ac_cv_type_pid_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2337 | fi |
| 2338 | rm -f conftest* |
| 2339 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2340 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2341 | echo "$ac_t""$ac_cv_type_pid_t" 1>&6 |
| 2342 | if test $ac_cv_type_pid_t = no; then |
| 2343 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2344 | #define pid_t int |
| 2345 | EOF |
| 2346 | |
| 2347 | fi |
| 2348 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2349 | echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2350 | echo "configure:2351: checking return type of signal handlers" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2351 | if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2352 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2353 | else |
| 2354 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2355 | #line 2356 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2356 | #include "confdefs.h" |
| 2357 | #include <sys/types.h> |
| 2358 | #include <signal.h> |
| 2359 | #ifdef signal |
| 2360 | #undef signal |
| 2361 | #endif |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2362 | #ifdef __cplusplus |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2363 | extern "C" void (*signal (int, void (*)(int)))(int); |
| 2364 | #else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2365 | void (*signal ()) (); |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2366 | #endif |
| 2367 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2368 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2369 | int i; |
| 2370 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2371 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2372 | if { (eval echo configure:2373: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2373 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2374 | ac_cv_type_signal=void |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2375 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2376 | echo "configure: failed program was:" >&5 |
| 2377 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2378 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2379 | ac_cv_type_signal=int |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2380 | fi |
| 2381 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2382 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2383 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2384 | echo "$ac_t""$ac_cv_type_signal" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2385 | cat >> confdefs.h <<EOF |
| 2386 | #define RETSIGTYPE $ac_cv_type_signal |
| 2387 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2388 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2389 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2390 | echo $ac_n "checking for size_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2391 | echo "configure:2392: checking for size_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2392 | if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2393 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2394 | else |
| 2395 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2396 | #line 2397 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2397 | #include "confdefs.h" |
| 2398 | #include <sys/types.h> |
| 2399 | #if STDC_HEADERS |
| 2400 | #include <stdlib.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2401 | #include <stddef.h> |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2402 | #endif |
| 2403 | EOF |
| 2404 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 2405 | egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2406 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2407 | ac_cv_type_size_t=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2408 | else |
| 2409 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2410 | ac_cv_type_size_t=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2411 | fi |
| 2412 | rm -f conftest* |
| 2413 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2414 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2415 | echo "$ac_t""$ac_cv_type_size_t" 1>&6 |
| 2416 | if test $ac_cv_type_size_t = no; then |
| 2417 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2418 | #define size_t unsigned |
| 2419 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2420 | |
| 2421 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2422 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2423 | echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2424 | echo "configure:2425: checking for uid_t in sys/types.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2425 | if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2426 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2427 | else |
| 2428 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2429 | #line 2430 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2430 | #include "confdefs.h" |
| 2431 | #include <sys/types.h> |
| 2432 | EOF |
| 2433 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 2434 | egrep "uid_t" >/dev/null 2>&1; then |
| 2435 | rm -rf conftest* |
| 2436 | ac_cv_type_uid_t=yes |
| 2437 | else |
| 2438 | rm -rf conftest* |
| 2439 | ac_cv_type_uid_t=no |
| 2440 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2441 | rm -f conftest* |
| 2442 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2443 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 2444 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 2445 | echo "$ac_t""$ac_cv_type_uid_t" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 2446 | if test $ac_cv_type_uid_t = no; then |
| 2447 | cat >> confdefs.h <<\EOF |
| 2448 | #define uid_t int |
| 2449 | EOF |
| 2450 | |
| 2451 | cat >> confdefs.h <<\EOF |
| 2452 | #define gid_t int |
| 2453 | EOF |
| 2454 | |
| 2455 | fi |
| 2456 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 2457 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2458 | # Sizes of various common basic types |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2459 | echo $ac_n "checking size of int""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2460 | echo "configure:2461: checking size of int" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2461 | if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2462 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2463 | else |
| 2464 | if test "$cross_compiling" = yes; then |
| 2465 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2466 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2467 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2468 | #line 2469 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2469 | #include "confdefs.h" |
| 2470 | #include <stdio.h> |
| 2471 | main() |
| 2472 | { |
| 2473 | FILE *f=fopen("conftestval", "w"); |
| 2474 | if (!f) exit(1); |
| 2475 | fprintf(f, "%d\n", sizeof(int)); |
| 2476 | exit(0); |
| 2477 | } |
| 2478 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2479 | if { (eval echo configure:2480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2480 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2481 | ac_cv_sizeof_int=`cat conftestval` |
| 2482 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2483 | echo "configure: failed program was:" >&5 |
| 2484 | cat conftest.$ac_ext >&5 |
| 2485 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2486 | ac_cv_sizeof_int=0 |
| 2487 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2488 | rm -fr conftest* |
| 2489 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2490 | |
| 2491 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2492 | echo "$ac_t""$ac_cv_sizeof_int" 1>&6 |
| 2493 | cat >> confdefs.h <<EOF |
| 2494 | #define SIZEOF_INT $ac_cv_sizeof_int |
| 2495 | EOF |
| 2496 | |
| 2497 | |
| 2498 | echo $ac_n "checking size of long""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2499 | echo "configure:2500: checking size of long" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2500 | if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2501 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2502 | else |
| 2503 | if test "$cross_compiling" = yes; then |
| 2504 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2505 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2506 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2507 | #line 2508 "configure" |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2508 | #include "confdefs.h" |
| 2509 | #include <stdio.h> |
| 2510 | main() |
| 2511 | { |
| 2512 | FILE *f=fopen("conftestval", "w"); |
| 2513 | if (!f) exit(1); |
| 2514 | fprintf(f, "%d\n", sizeof(long)); |
| 2515 | exit(0); |
| 2516 | } |
| 2517 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2518 | if { (eval echo configure:2519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2519 | then |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2520 | ac_cv_sizeof_long=`cat conftestval` |
| 2521 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2522 | echo "configure: failed program was:" >&5 |
| 2523 | cat conftest.$ac_ext >&5 |
| 2524 | rm -fr conftest* |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2525 | ac_cv_sizeof_long=0 |
| 2526 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2527 | rm -fr conftest* |
| 2528 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 2529 | |
| 2530 | fi |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 2531 | echo "$ac_t""$ac_cv_sizeof_long" 1>&6 |
| 2532 | cat >> confdefs.h <<EOF |
| 2533 | #define SIZEOF_LONG $ac_cv_sizeof_long |
| 2534 | EOF |
| 2535 | |
| 2536 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2537 | echo $ac_n "checking size of void *""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2538 | echo "configure:2539: checking size of void *" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2539 | if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2540 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2541 | else |
| 2542 | if test "$cross_compiling" = yes; then |
| 2543 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2544 | else |
| 2545 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2546 | #line 2547 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2547 | #include "confdefs.h" |
| 2548 | #include <stdio.h> |
| 2549 | main() |
| 2550 | { |
| 2551 | FILE *f=fopen("conftestval", "w"); |
| 2552 | if (!f) exit(1); |
| 2553 | fprintf(f, "%d\n", sizeof(void *)); |
| 2554 | exit(0); |
| 2555 | } |
| 2556 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2557 | if { (eval echo configure:2558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 2558 | then |
| 2559 | ac_cv_sizeof_void_p=`cat conftestval` |
| 2560 | else |
| 2561 | echo "configure: failed program was:" >&5 |
| 2562 | cat conftest.$ac_ext >&5 |
| 2563 | rm -fr conftest* |
| 2564 | ac_cv_sizeof_void_p=0 |
| 2565 | fi |
| 2566 | rm -fr conftest* |
| 2567 | fi |
| 2568 | |
| 2569 | fi |
| 2570 | echo "$ac_t""$ac_cv_sizeof_void_p" 1>&6 |
| 2571 | cat >> confdefs.h <<EOF |
| 2572 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p |
| 2573 | EOF |
| 2574 | |
| 2575 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2576 | echo $ac_n "checking size of char""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2577 | echo "configure:2578: checking size of char" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2578 | if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2579 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2580 | else |
| 2581 | if test "$cross_compiling" = yes; then |
| 2582 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2583 | else |
| 2584 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2585 | #line 2586 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2586 | #include "confdefs.h" |
| 2587 | #include <stdio.h> |
| 2588 | main() |
| 2589 | { |
| 2590 | FILE *f=fopen("conftestval", "w"); |
| 2591 | if (!f) exit(1); |
| 2592 | fprintf(f, "%d\n", sizeof(char)); |
| 2593 | exit(0); |
| 2594 | } |
| 2595 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2596 | if { (eval echo configure:2597: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2597 | then |
| 2598 | ac_cv_sizeof_char=`cat conftestval` |
| 2599 | else |
| 2600 | echo "configure: failed program was:" >&5 |
| 2601 | cat conftest.$ac_ext >&5 |
| 2602 | rm -fr conftest* |
| 2603 | ac_cv_sizeof_char=0 |
| 2604 | fi |
| 2605 | rm -fr conftest* |
| 2606 | fi |
| 2607 | |
| 2608 | fi |
| 2609 | echo "$ac_t""$ac_cv_sizeof_char" 1>&6 |
| 2610 | cat >> confdefs.h <<EOF |
| 2611 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
| 2612 | EOF |
| 2613 | |
| 2614 | |
| 2615 | echo $ac_n "checking size of short""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2616 | echo "configure:2617: checking size of short" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2617 | if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2618 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2619 | else |
| 2620 | if test "$cross_compiling" = yes; then |
| 2621 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2622 | else |
| 2623 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2624 | #line 2625 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2625 | #include "confdefs.h" |
| 2626 | #include <stdio.h> |
| 2627 | main() |
| 2628 | { |
| 2629 | FILE *f=fopen("conftestval", "w"); |
| 2630 | if (!f) exit(1); |
| 2631 | fprintf(f, "%d\n", sizeof(short)); |
| 2632 | exit(0); |
| 2633 | } |
| 2634 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2635 | if { (eval echo configure:2636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2636 | then |
| 2637 | ac_cv_sizeof_short=`cat conftestval` |
| 2638 | else |
| 2639 | echo "configure: failed program was:" >&5 |
| 2640 | cat conftest.$ac_ext >&5 |
| 2641 | rm -fr conftest* |
| 2642 | ac_cv_sizeof_short=0 |
| 2643 | fi |
| 2644 | rm -fr conftest* |
| 2645 | fi |
| 2646 | |
| 2647 | fi |
| 2648 | echo "$ac_t""$ac_cv_sizeof_short" 1>&6 |
| 2649 | cat >> confdefs.h <<EOF |
| 2650 | #define SIZEOF_SHORT $ac_cv_sizeof_short |
| 2651 | EOF |
| 2652 | |
| 2653 | |
| 2654 | echo $ac_n "checking size of float""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2655 | echo "configure:2656: checking size of float" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2656 | if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2657 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2658 | else |
| 2659 | if test "$cross_compiling" = yes; then |
| 2660 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2661 | else |
| 2662 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2663 | #line 2664 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2664 | #include "confdefs.h" |
| 2665 | #include <stdio.h> |
| 2666 | main() |
| 2667 | { |
| 2668 | FILE *f=fopen("conftestval", "w"); |
| 2669 | if (!f) exit(1); |
| 2670 | fprintf(f, "%d\n", sizeof(float)); |
| 2671 | exit(0); |
| 2672 | } |
| 2673 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2674 | if { (eval echo configure:2675: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2675 | then |
| 2676 | ac_cv_sizeof_float=`cat conftestval` |
| 2677 | else |
| 2678 | echo "configure: failed program was:" >&5 |
| 2679 | cat conftest.$ac_ext >&5 |
| 2680 | rm -fr conftest* |
| 2681 | ac_cv_sizeof_float=0 |
| 2682 | fi |
| 2683 | rm -fr conftest* |
| 2684 | fi |
| 2685 | |
| 2686 | fi |
| 2687 | echo "$ac_t""$ac_cv_sizeof_float" 1>&6 |
| 2688 | cat >> confdefs.h <<EOF |
| 2689 | #define SIZEOF_FLOAT $ac_cv_sizeof_float |
| 2690 | EOF |
| 2691 | |
| 2692 | |
| 2693 | echo $ac_n "checking size of double""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2694 | echo "configure:2695: checking size of double" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2695 | if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2696 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2697 | else |
| 2698 | if test "$cross_compiling" = yes; then |
| 2699 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2700 | else |
| 2701 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2702 | #line 2703 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2703 | #include "confdefs.h" |
| 2704 | #include <stdio.h> |
| 2705 | main() |
| 2706 | { |
| 2707 | FILE *f=fopen("conftestval", "w"); |
| 2708 | if (!f) exit(1); |
| 2709 | fprintf(f, "%d\n", sizeof(double)); |
| 2710 | exit(0); |
| 2711 | } |
| 2712 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2713 | if { (eval echo configure:2714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 2714 | then |
| 2715 | ac_cv_sizeof_double=`cat conftestval` |
| 2716 | else |
| 2717 | echo "configure: failed program was:" >&5 |
| 2718 | cat conftest.$ac_ext >&5 |
| 2719 | rm -fr conftest* |
| 2720 | ac_cv_sizeof_double=0 |
| 2721 | fi |
| 2722 | rm -fr conftest* |
| 2723 | fi |
| 2724 | |
| 2725 | fi |
| 2726 | echo "$ac_t""$ac_cv_sizeof_double" 1>&6 |
| 2727 | cat >> confdefs.h <<EOF |
| 2728 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
| 2729 | EOF |
| 2730 | |
| 2731 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2732 | echo $ac_n "checking size of fpos_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2733 | echo "configure:2734: checking size of fpos_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2734 | if eval "test \"`echo '$''{'ac_cv_sizeof_fpos_t'+set}'`\" = set"; then |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2735 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2736 | else |
| 2737 | if test "$cross_compiling" = yes; then |
| 2738 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2739 | else |
| 2740 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2741 | #line 2742 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2742 | #include "confdefs.h" |
| 2743 | #include <stdio.h> |
| 2744 | main() |
| 2745 | { |
| 2746 | FILE *f=fopen("conftestval", "w"); |
| 2747 | if (!f) exit(1); |
| 2748 | fprintf(f, "%d\n", sizeof(fpos_t)); |
| 2749 | exit(0); |
| 2750 | } |
| 2751 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2752 | if { (eval echo configure:2753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2753 | then |
| 2754 | ac_cv_sizeof_fpos_t=`cat conftestval` |
| 2755 | else |
| 2756 | echo "configure: failed program was:" >&5 |
| 2757 | cat conftest.$ac_ext >&5 |
| 2758 | rm -fr conftest* |
| 2759 | ac_cv_sizeof_fpos_t=0 |
| 2760 | fi |
| 2761 | rm -fr conftest* |
| 2762 | fi |
| 2763 | |
| 2764 | fi |
| 2765 | echo "$ac_t""$ac_cv_sizeof_fpos_t" 1>&6 |
| 2766 | cat >> confdefs.h <<EOF |
| 2767 | #define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t |
| 2768 | EOF |
| 2769 | |
| 2770 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 2771 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2772 | echo $ac_n "checking for long long support""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2773 | echo "configure:2774: checking for long long support" >&5 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2774 | have_long_long=no |
| 2775 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2776 | #line 2777 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2777 | #include "confdefs.h" |
| 2778 | |
| 2779 | int main() { |
| 2780 | long long x; x = (long long)0; |
| 2781 | ; return 0; } |
| 2782 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2783 | if { (eval echo configure:2784: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2784 | rm -rf conftest* |
| 2785 | cat >> confdefs.h <<\EOF |
| 2786 | #define HAVE_LONG_LONG 1 |
| 2787 | EOF |
| 2788 | have_long_long=yes |
| 2789 | else |
| 2790 | echo "configure: failed program was:" >&5 |
| 2791 | cat conftest.$ac_ext >&5 |
| 2792 | fi |
| 2793 | rm -f conftest* |
| 2794 | echo "$ac_t""$have_long_long" 1>&6 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2795 | if test "$have_long_long" = yes ; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2796 | echo $ac_n "checking size of long long""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2797 | echo "configure:2798: checking size of long long" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2798 | if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2799 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2800 | else |
| 2801 | if test "$cross_compiling" = yes; then |
| 2802 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2803 | else |
| 2804 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2805 | #line 2806 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2806 | #include "confdefs.h" |
| 2807 | #include <stdio.h> |
| 2808 | main() |
| 2809 | { |
| 2810 | FILE *f=fopen("conftestval", "w"); |
| 2811 | if (!f) exit(1); |
| 2812 | fprintf(f, "%d\n", sizeof(long long)); |
| 2813 | exit(0); |
| 2814 | } |
| 2815 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2816 | if { (eval echo configure:2817: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 2817 | then |
| 2818 | ac_cv_sizeof_long_long=`cat conftestval` |
| 2819 | else |
| 2820 | echo "configure: failed program was:" >&5 |
| 2821 | cat conftest.$ac_ext >&5 |
| 2822 | rm -fr conftest* |
| 2823 | ac_cv_sizeof_long_long=0 |
| 2824 | fi |
| 2825 | rm -fr conftest* |
| 2826 | fi |
| 2827 | |
| 2828 | fi |
| 2829 | echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6 |
| 2830 | cat >> confdefs.h <<EOF |
| 2831 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long |
| 2832 | EOF |
| 2833 | |
| 2834 | |
| 2835 | fi |
| 2836 | |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2837 | echo $ac_n "checking for uintptr_t support""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2838 | echo "configure:2839: checking for uintptr_t support" >&5 |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2839 | have_uintptr_t=no |
| 2840 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2841 | #line 2842 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2842 | #include "confdefs.h" |
| 2843 | |
| 2844 | int main() { |
| 2845 | uintptr_t x; x = (uintptr_t)0; |
| 2846 | ; return 0; } |
| 2847 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2848 | if { (eval echo configure:2849: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2849 | rm -rf conftest* |
| 2850 | cat >> confdefs.h <<\EOF |
| 2851 | #define HAVE_UINTPTR_T 1 |
| 2852 | EOF |
| 2853 | have_uintptr_t=yes |
| 2854 | else |
| 2855 | echo "configure: failed program was:" >&5 |
| 2856 | cat conftest.$ac_ext >&5 |
| 2857 | fi |
| 2858 | rm -f conftest* |
| 2859 | echo "$ac_t""$have_uintptr_t" 1>&6 |
| 2860 | if test "$have_uintptr_t" = yes ; then |
| 2861 | echo $ac_n "checking size of uintptr_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2862 | echo "configure:2863: checking size of uintptr_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2863 | if eval "test \"`echo '$''{'ac_cv_sizeof_uintptr_t'+set}'`\" = set"; then |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2864 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2865 | else |
| 2866 | if test "$cross_compiling" = yes; then |
| 2867 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2868 | else |
| 2869 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2870 | #line 2871 "configure" |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2871 | #include "confdefs.h" |
| 2872 | #include <stdio.h> |
| 2873 | main() |
| 2874 | { |
| 2875 | FILE *f=fopen("conftestval", "w"); |
| 2876 | if (!f) exit(1); |
| 2877 | fprintf(f, "%d\n", sizeof(uintptr_t)); |
| 2878 | exit(0); |
| 2879 | } |
| 2880 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2881 | if { (eval echo configure:2882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Barry Warsaw | bc7c7f9 | 2000-08-18 04:53:33 +0000 | [diff] [blame] | 2882 | then |
| 2883 | ac_cv_sizeof_uintptr_t=`cat conftestval` |
| 2884 | else |
| 2885 | echo "configure: failed program was:" >&5 |
| 2886 | cat conftest.$ac_ext >&5 |
| 2887 | rm -fr conftest* |
| 2888 | ac_cv_sizeof_uintptr_t=0 |
| 2889 | fi |
| 2890 | rm -fr conftest* |
| 2891 | fi |
| 2892 | |
| 2893 | fi |
| 2894 | echo "$ac_t""$ac_cv_sizeof_uintptr_t" 1>&6 |
| 2895 | cat >> confdefs.h <<EOF |
| 2896 | #define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t |
| 2897 | EOF |
| 2898 | |
| 2899 | |
| 2900 | fi |
| 2901 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2902 | # Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>. |
| 2903 | echo $ac_n "checking size of off_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2904 | echo "configure:2905: checking size of off_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2905 | if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2906 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2907 | else |
| 2908 | if test "$cross_compiling" = yes; then |
| 2909 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2910 | else |
| 2911 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2912 | #line 2913 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2913 | #include "confdefs.h" |
| 2914 | #include <stdio.h> |
| 2915 | #include <sys/types.h> |
| 2916 | main() |
| 2917 | { |
| 2918 | FILE *f=fopen("conftestval", "w"); |
| 2919 | if (!f) exit(1); |
| 2920 | fprintf(f, "%d\n", sizeof(off_t)); |
| 2921 | exit(0); |
| 2922 | } |
| 2923 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2924 | if { (eval echo configure:2925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 2925 | then |
| 2926 | ac_cv_sizeof_off_t=`cat conftestval` |
| 2927 | else |
| 2928 | echo "configure: failed program was:" >&5 |
| 2929 | cat conftest.$ac_ext >&5 |
| 2930 | rm -fr conftest* |
| 2931 | ac_cv_sizeof_off_t=0 |
| 2932 | fi |
| 2933 | rm -fr conftest* |
| 2934 | fi |
| 2935 | |
| 2936 | |
| 2937 | fi |
| 2938 | |
| 2939 | echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6 |
| 2940 | cat >> confdefs.h <<EOF |
| 2941 | #define SIZEOF_OFF_T $ac_cv_sizeof_off_t |
| 2942 | EOF |
| 2943 | |
| 2944 | |
| 2945 | echo $ac_n "checking whether to enable large file support""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2946 | echo "configure:2947: checking whether to enable large file support" >&5 |
Guido van Rossum | 96f2eb9 | 1999-04-10 16:02:18 +0000 | [diff] [blame] | 2947 | if test "$have_long_long" = yes -a \ |
| 2948 | "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \ |
| 2949 | "$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] | 2950 | cat >> confdefs.h <<\EOF |
| 2951 | #define HAVE_LARGEFILE_SUPPORT 1 |
| 2952 | EOF |
| 2953 | |
| 2954 | echo "$ac_t""yes" 1>&6 |
| 2955 | else |
| 2956 | echo "$ac_t""no" 1>&6 |
| 2957 | fi |
| 2958 | |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2959 | # AC_CHECK_SIZEOF() doesn't include <time.h>. |
| 2960 | echo $ac_n "checking size of time_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2961 | echo "configure:2962: checking size of time_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 2962 | if eval "test \"`echo '$''{'ac_cv_sizeof_time_t'+set}'`\" = set"; then |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2963 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 2964 | else |
| 2965 | if test "$cross_compiling" = yes; then |
| 2966 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 2967 | else |
| 2968 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2969 | #line 2970 "configure" |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2970 | #include "confdefs.h" |
| 2971 | #include <stdio.h> |
| 2972 | #include <time.h> |
| 2973 | main() |
| 2974 | { |
| 2975 | FILE *f=fopen("conftestval", "w"); |
| 2976 | if (!f) exit(1); |
| 2977 | fprintf(f, "%d\n", sizeof(time_t)); |
| 2978 | exit(0); |
| 2979 | } |
| 2980 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 2981 | if { (eval echo configure:2982: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | b9a22a1 | 2000-06-30 02:48:53 +0000 | [diff] [blame] | 2982 | then |
| 2983 | ac_cv_sizeof_time_t=`cat conftestval` |
| 2984 | else |
| 2985 | echo "configure: failed program was:" >&5 |
| 2986 | cat conftest.$ac_ext >&5 |
| 2987 | rm -fr conftest* |
| 2988 | ac_cv_sizeof_time_t=0 |
| 2989 | fi |
| 2990 | rm -fr conftest* |
| 2991 | fi |
| 2992 | |
| 2993 | |
| 2994 | fi |
| 2995 | |
| 2996 | echo "$ac_t""$ac_cv_sizeof_time_t" 1>&6 |
| 2997 | cat >> confdefs.h <<EOF |
| 2998 | #define SIZEOF_TIME_T $ac_cv_sizeof_time_t |
| 2999 | EOF |
| 3000 | |
| 3001 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 3002 | |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3003 | # if have pthread_t then define SIZEOF_PTHREAD_T |
| 3004 | echo $ac_n "checking for pthread_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3005 | echo "configure:3006: checking for pthread_t" >&5 |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3006 | have_pthread_t=no |
| 3007 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3008 | #line 3009 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3009 | #include "confdefs.h" |
| 3010 | #include <pthread.h> |
| 3011 | int main() { |
Guido van Rossum | 1258049 | 2000-09-24 16:47:19 +0000 | [diff] [blame] | 3012 | pthread_t x; x = *(pthread_t*)0; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3013 | ; return 0; } |
| 3014 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3015 | if { (eval echo configure:3016: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3016 | rm -rf conftest* |
| 3017 | have_pthread_t=yes |
| 3018 | else |
| 3019 | echo "configure: failed program was:" >&5 |
| 3020 | cat conftest.$ac_ext >&5 |
| 3021 | fi |
| 3022 | rm -f conftest* |
| 3023 | echo "$ac_t""$have_pthread_t" 1>&6 |
| 3024 | if test "$have_pthread_t" = yes ; then |
| 3025 | # AC_CHECK_SIZEOF() doesn't include <pthread.h>. |
| 3026 | echo $ac_n "checking size of pthread_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3027 | echo "configure:3028: checking size of pthread_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3028 | if eval "test \"`echo '$''{'ac_cv_sizeof_pthread_t'+set}'`\" = set"; then |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3029 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3030 | else |
| 3031 | if test "$cross_compiling" = yes; then |
| 3032 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 3033 | else |
| 3034 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3035 | #line 3036 "configure" |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3036 | #include "confdefs.h" |
| 3037 | #include <stdio.h> |
| 3038 | #include <pthread.h> |
| 3039 | main() |
| 3040 | { |
| 3041 | FILE *f=fopen("conftestval", "w"); |
| 3042 | if (!f) exit(1); |
| 3043 | fprintf(f, "%d\n", sizeof(pthread_t)); |
| 3044 | exit(0); |
| 3045 | } |
| 3046 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3047 | if { (eval echo configure:3048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3048 | then |
| 3049 | ac_cv_sizeof_pthread_t=`cat conftestval` |
| 3050 | else |
| 3051 | echo "configure: failed program was:" >&5 |
| 3052 | cat conftest.$ac_ext >&5 |
| 3053 | rm -fr conftest* |
| 3054 | ac_cv_sizeof_pthread_t=0 |
| 3055 | fi |
| 3056 | rm -fr conftest* |
| 3057 | fi |
| 3058 | |
| 3059 | |
| 3060 | fi |
| 3061 | |
| 3062 | echo "$ac_t""$ac_cv_sizeof_pthread_t" 1>&6 |
| 3063 | cat >> confdefs.h <<EOF |
| 3064 | #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t |
| 3065 | EOF |
| 3066 | |
| 3067 | fi |
| 3068 | |
| 3069 | |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3070 | # Minor variations in building a framework between NextStep versions 4 and 5 |
| 3071 | |
| 3072 | case $ac_sys_system/$ac_sys_release in |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 3073 | Darwin/*) |
| 3074 | ns_undef_sym='_environ' |
| 3075 | LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc -U $ns_undef_sym" ;; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3076 | next/4*) |
| 3077 | ns_undef_sym='__environ' |
| 3078 | LIBTOOL_CRUFT="-U $ns_undef_sym" ;; |
| 3079 | next/5*) |
| 3080 | ns_undef_sym='_environ' |
| 3081 | LIBTOOL_CRUFT="-lcc_dynamic -U $ns_undef_sym" ;; |
| 3082 | esac |
| 3083 | |
| 3084 | echo $ac_n "checking for --with-next-framework""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3085 | echo "configure:3086: checking for --with-next-framework" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3086 | if test "$with_next_framework" |
| 3087 | then |
| 3088 | OPT="$OPT -fno-common" |
| 3089 | # -U __environ is needed since bundles don't have access |
| 3090 | # to crt0 when built but will always be linked against it |
| 3091 | LDFLAGS="$LDFLAGS -Wl,-U,$ns_undef_sym" |
| 3092 | cat >> confdefs.h <<\EOF |
| 3093 | #define WITH_NEXT_FRAMEWORK 1 |
| 3094 | EOF |
| 3095 | |
| 3096 | echo "$ac_t""yes" 1>&6 |
| 3097 | else |
| 3098 | echo "$ac_t""no" 1>&6 |
| 3099 | fi |
| 3100 | |
| 3101 | echo $ac_n "checking for --with-dyld""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3102 | echo "configure:3103: checking for --with-dyld" >&5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3103 | if test "$with_next_framework" -o "$with_dyld" |
| 3104 | then |
| 3105 | if test "$with_dyld" |
| 3106 | then |
| 3107 | echo "$ac_t""yes" 1>&6 |
| 3108 | else |
| 3109 | echo "$ac_t""required for framework build" 1>&6 |
| 3110 | fi |
| 3111 | cat >> confdefs.h <<\EOF |
| 3112 | #define WITH_DYLD 1 |
| 3113 | EOF |
| 3114 | |
| 3115 | ns_dyld='set' |
| 3116 | else |
| 3117 | echo "$ac_t""no" 1>&6 |
| 3118 | fi |
| 3119 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3120 | # Set info about shared libraries. |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3121 | |
| 3122 | |
| 3123 | |
| 3124 | |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3125 | |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3126 | # SO is the extension of shared libraries `(including the dot!) |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 3127 | # -- usually .so, .sl on HP-UX, .dll on Cygwin |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3128 | echo $ac_n "checking SO""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3129 | echo "configure:3130: checking SO" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3130 | if test -z "$SO" |
| 3131 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3132 | case $ac_sys_system in |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3133 | hp*|HP*) SO=.sl;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 3134 | CYGWIN*) SO=.dll;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 3135 | *) SO=.so;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3136 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3137 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3138 | echo "$ac_t""$SO" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3139 | # LDSHARED is the ld *command* used to create shared library |
| 3140 | # -- "ld" on SunOS 4.x.x, "ld -G" on SunOS 5.x, "ld -shared" on IRIX 5 |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3141 | # (Shared libraries in this instance are shared modules to be loaded into |
| 3142 | # Python, as opposed to building Python itself as a shared library.) |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3143 | echo $ac_n "checking LDSHARED""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3144 | echo "configure:3145: checking LDSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3145 | if test -z "$LDSHARED" |
| 3146 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3147 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3148 | AIX*) |
| 3149 | BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp" |
| 3150 | LDSHARED="\$(BINLIBDEST)/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/python.exp" |
| 3151 | ;; |
| 3152 | BeOS*) |
| 3153 | BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY" |
| 3154 | LDSHARED="\$(BINLIBDEST)/ld_so_beos \$(LIBDIR)/$LDLIBRARY" |
| 3155 | ;; |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 3156 | IRIX/5*) LDSHARED="ld -shared";; |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 3157 | IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3158 | SunOS/4*) LDSHARED="ld";; |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 3159 | SunOS/5*) |
| 3160 | if test "$GCC" = "yes" |
Neil Schemenauer | 8ba9445 | 2001-02-19 18:18:48 +0000 | [diff] [blame] | 3161 | then LDSHARED='$(CC) -shared' |
Greg Ward | 57c9a663 | 2000-05-26 12:22:54 +0000 | [diff] [blame] | 3162 | else LDSHARED="ld -G"; |
| 3163 | fi ;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3164 | hp*|HP*) LDSHARED="ld -b";; |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 3165 | OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";; |
| 3166 | DYNIX/ptx*) LDSHARED="ld -G";; |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 3167 | Darwin/*|next/*) |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3168 | if test "$ns_dyld" |
Guido van Rossum | acb14c7 | 2001-01-10 21:41:16 +0000 | [diff] [blame] | 3169 | then LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined suppress' |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3170 | else LDSHARED='$(CC) $(CFLAGS) -nostdlib -r'; |
| 3171 | fi |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 3172 | if test "$with_next_framework" ; then |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3173 | LDSHARED="$LDSHARED \$(LDLIBRARY)" |
| 3174 | fi ;; |
Guido van Rossum | 81652ab | 1996-07-21 02:53:27 +0000 | [diff] [blame] | 3175 | Linux*) LDSHARED="gcc -shared";; |
Guido van Rossum | 3c4bb80 | 1997-12-18 23:55:32 +0000 | [diff] [blame] | 3176 | dgux*) LDSHARED="ld -G";; |
Guido van Rossum | 458e7fa | 1999-09-17 15:40:40 +0000 | [diff] [blame] | 3177 | BSD/OS*/4*) LDSHARED="gcc -shared";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 3178 | OpenBSD*) LDSHARED="ld -Bshareable";; |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 3179 | NetBSD*) |
| 3180 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 3181 | then |
| 3182 | LDSHARED="cc -shared" |
| 3183 | else |
| 3184 | LDSHARED="ld -Bshareable" |
| 3185 | fi;; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 3186 | FreeBSD*) |
Jeremy Hylton | 4bcc7c5 | 2000-08-31 17:45:35 +0000 | [diff] [blame] | 3187 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 3188 | then |
| 3189 | LDSHARED="cc -shared ${LDFLAGS}" |
| 3190 | else |
| 3191 | LDSHARED="ld -Bshareable ${LDFLAGS}" |
| 3192 | fi;; |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 3193 | UnixWare*) |
| 3194 | if test "$GCC" = "yes" |
| 3195 | then LDSHARED="$(CC) -shared" |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3196 | else LDSHARED="ld -G -dy -Bdynamic" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 3197 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3198 | SCO_SV*) LDSHARED="cc -G -KPIC -Ki486 -belf -Wl,-Bexport";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3199 | Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 3200 | CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3201 | *) LDSHARED="ld";; |
| 3202 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3203 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3204 | echo "$ac_t""$LDSHARED" 1>&6 |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3205 | BLDSHARED=${BLDSHARED-$LDSHARED} |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3206 | # 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] | 3207 | # library (module) -- this is only needed for a few systems |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3208 | echo $ac_n "checking CCSHARED""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3209 | echo "configure:3210: checking CCSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3210 | if test -z "$CCSHARED" |
| 3211 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 3212 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 3213 | SunOS*) if test "$GCC" = yes; |
| 3214 | then CCSHARED="-fPIC"; |
| 3215 | fi;; |
Guido van Rossum | af07a44 | 1995-02-13 19:45:27 +0000 | [diff] [blame] | 3216 | hp*|HP*) if test "$GCC" = yes; |
| 3217 | then CCSHARED="-fpic"; |
| 3218 | else CCSHARED="+z"; |
| 3219 | fi;; |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 3220 | Linux*) CCSHARED="-fPIC";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3221 | BSD/OS*/4*) CCSHARED="-fpic";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 3222 | OpenBSD*) CCSHARED="-fpic";; |
| 3223 | FreeBSD*|NetBSD*) CCSHARED="-fPIC";; |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 3224 | UnixWare*) |
| 3225 | if test "$GCC" = "yes" |
| 3226 | then CCSHARED="-fPIC" |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3227 | else CCSHARED="-KPIC -G -dy -Bdynamic" |
Martin v. Löwis | bec1958 | 2001-03-21 15:57:54 +0000 | [diff] [blame] | 3228 | fi;; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3229 | SCO_SV*) CCSHARED="-KPIC -dy -Bdynamic";; |
Trent Mick | 635f6fb | 2000-08-23 21:33:05 +0000 | [diff] [blame] | 3230 | Monterey*) CCSHARED="-G";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 3231 | IRIX*/6*) case $CC in |
| 3232 | *gcc*) CCSHARED="-shared";; |
Guido van Rossum | ee21f41 | 1998-04-20 18:51:54 +0000 | [diff] [blame] | 3233 | *) CCSHARED="";; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 3234 | esac;; |
Guido van Rossum | aef734b | 2001-01-10 21:09:12 +0000 | [diff] [blame] | 3235 | CYGWIN*) CCSHARED="-DUSE_DL_IMPORT";; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3236 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3237 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3238 | echo "$ac_t""$CCSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3239 | # LINKFORSHARED are the flags passed to the $(CC) command that links |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3240 | # the python executable -- this is only needed for a few systems |
| 3241 | echo $ac_n "checking LINKFORSHARED""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3242 | echo "configure:3243: checking LINKFORSHARED" >&5 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3243 | if test -z "$LINKFORSHARED" |
| 3244 | then |
Guido van Rossum | 0739797 | 1997-04-29 21:49:50 +0000 | [diff] [blame] | 3245 | case $ac_sys_system/$ac_sys_release in |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 3246 | AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';; |
Guido van Rossum | ccaf3b6 | 1996-12-06 21:19:16 +0000 | [diff] [blame] | 3247 | hp*|HP*) |
Guido van Rossum | 304dd2d | 1997-10-20 23:10:56 +0000 | [diff] [blame] | 3248 | LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";; |
Guido van Rossum | f5957ea | 1999-10-05 21:59:33 +0000 | [diff] [blame] | 3249 | BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 2d9feed | 1997-11-24 17:36:21 +0000 | [diff] [blame] | 3250 | Linux*) LINKFORSHARED="-Xlinker -export-dynamic";; |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 3251 | # -u libsys_s pulls in all symbols in libsys |
| 3252 | next/2*|next/3*) LINKFORSHARED="-u libsys_s";; |
| 3253 | # -u __dummy makes the linker aware of the objc runtime |
| 3254 | # in System.framework; otherwise, __objcInit (referenced in |
| 3255 | # crt1.o) gets erroneously defined as common, which breaks dynamic |
| 3256 | # loading of any modules which reference it in System.framework |
| 3257 | next/4*|next/5*) LINKFORSHARED="-u __dummy -framework System" ;; |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 3258 | Darwin/*) LINKFORSHARED="-u __dummy -u _PyMac_Error -framework System -framework Foundation -framework Carbon" ;; |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3259 | UnixWare*) LINKFORSHARED="-dy -Bdynamic -Wl,-Bexport";; |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 3260 | SCO_SV*) LINKFORSHARED="-Bdynamic -dy -Wl,-Bexport";; |
Fred Drake | 02706f5 | 2000-09-25 15:08:46 +0000 | [diff] [blame] | 3261 | ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";; |
Guido van Rossum | 0286ae8 | 2000-08-29 15:06:49 +0000 | [diff] [blame] | 3262 | FreeBSD*|NetBSD*) |
Guido van Rossum | df69365 | 1999-01-07 21:50:41 +0000 | [diff] [blame] | 3263 | if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ] |
| 3264 | then |
| 3265 | LINKFORSHARED="-Wl,--export-dynamic" |
| 3266 | fi;; |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 3267 | SunOS/5*) case $CC in |
| 3268 | *gcc*) |
Guido van Rossum | ff48418 | 2000-02-03 13:50:24 +0000 | [diff] [blame] | 3269 | if $CC -Xlinker -V 2>&1 | grep BFD >/dev/null |
Guido van Rossum | 8f4ceb1 | 1997-12-18 23:42:19 +0000 | [diff] [blame] | 3270 | then |
| 3271 | LINKFORSHARED="-Xlinker --export-dynamic" |
Guido van Rossum | 2b5ca00 | 1998-03-05 15:41:09 +0000 | [diff] [blame] | 3272 | fi;; |
| 3273 | esac;; |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3274 | esac |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3275 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3276 | echo "$ac_t""$LINKFORSHARED" 1>&6 |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 3277 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 3278 | |
| 3279 | echo $ac_n "checking CFLAGSFORSHARED""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3280 | echo "configure:3281: checking CFLAGSFORSHARED" >&5 |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 3281 | if test ! "$LIBRARY" = "$LDLIBRARY" |
| 3282 | then |
Neil Schemenauer | 0c6141f | 2001-01-27 21:40:54 +0000 | [diff] [blame] | 3283 | case $ac_sys_system in |
| 3284 | CYGWIN*) |
| 3285 | # Cygwin needs CCSHARED when building extension DLLs |
| 3286 | # but not when building the interpreter DLL. |
| 3287 | CFLAGSFORSHARED='';; |
| 3288 | *) |
| 3289 | CFLAGSFORSHARED='$(CCSHARED)' |
| 3290 | esac |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 3291 | fi |
| 3292 | echo "$ac_t""$CFLAGSFORSHARED" 1>&6 |
| 3293 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3294 | # checks for libraries |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3295 | echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3296 | echo "configure:3297: checking for dlopen in -ldl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3297 | ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3298 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3299 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3300 | else |
| 3301 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3302 | LIBS="-ldl $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3303 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3304 | #line 3305 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3305 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3306 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3307 | /* We use char because int might match the return type of a gcc2 |
| 3308 | builtin and then its argument prototype would still apply. */ |
| 3309 | char dlopen(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3310 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3311 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3312 | dlopen() |
| 3313 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3314 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3315 | if { (eval echo configure:3316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3316 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3317 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3318 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3319 | echo "configure: failed program was:" >&5 |
| 3320 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3321 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3322 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3323 | fi |
| 3324 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3325 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3326 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3327 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3328 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3329 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3330 | ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 3331 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3332 | cat >> confdefs.h <<EOF |
| 3333 | #define $ac_tr_lib 1 |
| 3334 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3335 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3336 | LIBS="-ldl $LIBS" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3337 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3338 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3339 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3340 | fi |
| 3341 | # Dynamic linking for SunOS/Solaris and SYSV |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3342 | echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3343 | echo "configure:3344: checking for shl_load in -ldld" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3344 | ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3345 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3346 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3347 | else |
| 3348 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3349 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3350 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3351 | #line 3352 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3352 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3353 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3354 | /* We use char because int might match the return type of a gcc2 |
| 3355 | builtin and then its argument prototype would still apply. */ |
| 3356 | char shl_load(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3357 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3358 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3359 | shl_load() |
| 3360 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3361 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3362 | if { (eval echo configure:3363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3363 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3364 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3365 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3366 | echo "configure: failed program was:" >&5 |
| 3367 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3368 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3369 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3370 | fi |
| 3371 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3372 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3373 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3374 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3375 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3376 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3377 | ac_tr_lib=HAVE_LIB`echo dld | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 3378 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3379 | cat >> confdefs.h <<EOF |
| 3380 | #define $ac_tr_lib 1 |
| 3381 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 3382 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3383 | LIBS="-ldld $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3384 | |
| 3385 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3386 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3387 | fi |
| 3388 | # Dynamic linking for HP-UX |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3389 | |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 3390 | # Check for --with-pydebug |
| 3391 | echo $ac_n "checking for --with-pydebug""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3392 | echo "configure:3393: checking for --with-pydebug" >&5 |
Skip Montanaro | cb85326 | 2000-08-30 22:29:48 +0000 | [diff] [blame] | 3393 | # Check whether --with-pydebug or --without-pydebug was given. |
| 3394 | if test "${with_pydebug+set}" = set; then |
| 3395 | withval="$with_pydebug" |
| 3396 | |
| 3397 | if test "$withval" != no |
| 3398 | then cat >> confdefs.h <<\EOF |
| 3399 | #define Py_DEBUG 1 |
| 3400 | EOF |
| 3401 | echo "$ac_t""yes" 1>&6 |
| 3402 | else echo "$ac_t""no" 1>&6 |
| 3403 | fi |
| 3404 | else |
| 3405 | echo "$ac_t""no" 1>&6 |
| 3406 | fi |
| 3407 | |
| 3408 | |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3409 | # checks for system dependent C++ extensions support |
| 3410 | case "$ac_sys_system" in |
| 3411 | AIX*) echo $ac_n "checking for genuine AIX C++ extensions support""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3412 | echo "configure:3413: checking for genuine AIX C++ extensions support" >&5 |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3413 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3414 | #line 3415 "configure" |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3415 | #include "confdefs.h" |
| 3416 | #include "/usr/lpp/xlC/include/load.h" |
| 3417 | int main() { |
| 3418 | loadAndInit("", 0, "") |
| 3419 | ; return 0; } |
| 3420 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3421 | if { (eval echo configure:3422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 0eefa3f | 1999-11-16 15:57:37 +0000 | [diff] [blame] | 3422 | rm -rf conftest* |
| 3423 | cat >> confdefs.h <<\EOF |
| 3424 | #define AIX_GENUINE_CPLUSPLUS 1 |
| 3425 | EOF |
| 3426 | |
| 3427 | echo "$ac_t""yes" 1>&6 |
| 3428 | else |
| 3429 | echo "configure: failed program was:" >&5 |
| 3430 | cat conftest.$ac_ext >&5 |
| 3431 | rm -rf conftest* |
| 3432 | echo "$ac_t""no" 1>&6 |
| 3433 | fi |
| 3434 | rm -f conftest*;; |
| 3435 | *) ;; |
| 3436 | esac |
| 3437 | |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 3438 | # Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl. |
| 3439 | # However on SGI IRIX, these exist but are broken. |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3440 | # BeOS' sockets are stashed in libnet. |
| 3441 | case "$ac_sys_system" in |
| 3442 | IRIX*) ;; |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 3443 | *) |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3444 | echo $ac_n "checking for t_open in -lnsl""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3445 | echo "configure:3446: checking for t_open in -lnsl" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3446 | ac_lib_var=`echo nsl'_'t_open | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3447 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3448 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3449 | else |
| 3450 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3451 | LIBS="-lnsl $LIBS" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3452 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3453 | #line 3454 "configure" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3454 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3455 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3456 | /* We use char because int might match the return type of a gcc2 |
| 3457 | builtin and then its argument prototype would still apply. */ |
| 3458 | char t_open(); |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3459 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3460 | int main() { |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 3461 | t_open() |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3462 | ; return 0; } |
| 3463 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3464 | if { (eval echo configure:3465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3465 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3466 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3467 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3468 | echo "configure: failed program was:" >&5 |
| 3469 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3470 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3471 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3472 | fi |
| 3473 | rm -f conftest* |
| 3474 | LIBS="$ac_save_LIBS" |
| 3475 | |
| 3476 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3477 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3478 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3479 | LIBS="-lnsl $LIBS" |
| 3480 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3481 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 79dddcb | 1995-01-12 12:25:42 +0000 | [diff] [blame] | 3482 | fi |
Guido van Rossum | 0ddb028 | 1995-01-17 16:46:14 +0000 | [diff] [blame] | 3483 | # SVR4 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3484 | echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3485 | echo "configure:3486: checking for socket in -lsocket" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3486 | ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3487 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3488 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3489 | else |
| 3490 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3491 | LIBS="-lsocket $LIBS $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3492 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3493 | #line 3494 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3494 | #include "confdefs.h" |
| 3495 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3496 | /* We use char because int might match the return type of a gcc2 |
| 3497 | builtin and then its argument prototype would still apply. */ |
| 3498 | char socket(); |
| 3499 | |
| 3500 | int main() { |
| 3501 | socket() |
| 3502 | ; return 0; } |
| 3503 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3504 | if { (eval echo configure:3505: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3505 | rm -rf conftest* |
| 3506 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3507 | else |
| 3508 | echo "configure: failed program was:" >&5 |
| 3509 | cat conftest.$ac_ext >&5 |
| 3510 | rm -rf conftest* |
| 3511 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3512 | fi |
| 3513 | rm -f conftest* |
| 3514 | LIBS="$ac_save_LIBS" |
| 3515 | |
| 3516 | fi |
| 3517 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3518 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3519 | LIBS="-lsocket $LIBS" |
| 3520 | else |
| 3521 | echo "$ac_t""no" 1>&6 |
| 3522 | fi |
| 3523 | # SVR4 sockets |
Jeremy Hylton | cb25d5e | 2000-07-27 21:23:28 +0000 | [diff] [blame] | 3524 | ;; |
| 3525 | esac |
| 3526 | case "$ac_sys_system" in |
| 3527 | BeOS*) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3528 | echo $ac_n "checking for socket in -lnet""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3529 | echo "configure:3530: checking for socket in -lnet" >&5 |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3530 | ac_lib_var=`echo net'_'socket | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3531 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3532 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3533 | else |
| 3534 | ac_save_LIBS="$LIBS" |
| 3535 | LIBS="-lnet $LIBS $LIBS" |
| 3536 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3537 | #line 3538 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3538 | #include "confdefs.h" |
| 3539 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3540 | /* We use char because int might match the return type of a gcc2 |
| 3541 | builtin and then its argument prototype would still apply. */ |
| 3542 | char socket(); |
| 3543 | |
| 3544 | int main() { |
| 3545 | socket() |
| 3546 | ; return 0; } |
| 3547 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3548 | if { (eval echo configure:3549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3549 | rm -rf conftest* |
| 3550 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3551 | else |
| 3552 | echo "configure: failed program was:" >&5 |
| 3553 | cat conftest.$ac_ext >&5 |
| 3554 | rm -rf conftest* |
| 3555 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3556 | fi |
| 3557 | rm -f conftest* |
| 3558 | LIBS="$ac_save_LIBS" |
| 3559 | |
| 3560 | fi |
| 3561 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3562 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3563 | LIBS="-lnet $LIBS" |
| 3564 | else |
| 3565 | echo "$ac_t""no" 1>&6 |
| 3566 | fi |
| 3567 | # BeOS |
| 3568 | ;; |
| 3569 | esac |
Guido van Rossum | 70c7f48 | 1998-03-26 18:44:10 +0000 | [diff] [blame] | 3570 | |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3571 | echo $ac_n "checking for --with-libs""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3572 | echo "configure:3573: checking for --with-libs" >&5 |
Guido van Rossum | a68acba | 1996-07-31 17:36:39 +0000 | [diff] [blame] | 3573 | # Check whether --with-libs or --without-libs was given. |
| 3574 | if test "${with_libs+set}" = set; then |
| 3575 | withval="$with_libs" |
| 3576 | |
| 3577 | echo "$ac_t""$withval" 1>&6 |
| 3578 | LIBS="$withval $LIBS" |
| 3579 | |
| 3580 | else |
| 3581 | echo "$ac_t""no" 1>&6 |
| 3582 | fi |
| 3583 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3584 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3585 | # Determine if signalmodule should be used. |
| 3586 | |
| 3587 | |
| 3588 | echo $ac_n "checking for --with-signal-module""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3589 | echo "configure:3590: checking for --with-signal-module" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 3590 | # Check whether --with-signal-module or --without-signal-module was given. |
| 3591 | if test "${with_signal_module+set}" = set; then |
| 3592 | withval="$with_signal_module" |
| 3593 | : |
| 3594 | fi |
| 3595 | |
| 3596 | |
| 3597 | if test -z "$with_signal_module" |
| 3598 | then with_signal_module="yes" |
| 3599 | fi |
| 3600 | echo "$ac_t""$with_signal_module" 1>&6 |
| 3601 | |
| 3602 | if test "${with_signal_module}" = "yes"; then |
| 3603 | USE_SIGNAL_MODULE="" |
| 3604 | SIGNAL_OBJS="" |
| 3605 | else |
| 3606 | USE_SIGNAL_MODULE="#" |
| 3607 | SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o" |
| 3608 | fi |
| 3609 | |
Guido van Rossum | 3d15bd8 | 2001-01-10 18:53:48 +0000 | [diff] [blame] | 3610 | # This is used to generate Setup.config |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3611 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3612 | USE_THREAD_MODULE="" |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 3613 | |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3614 | echo $ac_n "checking for --with-dec-threads""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3615 | echo "configure:3616: checking for --with-dec-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3616 | |
| 3617 | # Check whether --with-dec-threads or --without-dec-threads was given. |
| 3618 | if test "${with_dec_threads+set}" = set; then |
| 3619 | withval="$with_dec_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3620 | |
| 3621 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3622 | LDLAST=-threads |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3623 | if test "${with_thread+set}" != set; then |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3624 | with_thread="$withval"; |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3625 | fi |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3626 | else |
| 3627 | echo "$ac_t""no" 1>&6 |
| 3628 | fi |
| 3629 | |
| 3630 | |
| 3631 | echo $ac_n "checking for --with-threads""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3632 | echo "configure:3633: checking for --with-threads" >&5 |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3633 | # Check whether --with-threads or --without-threads was given. |
| 3634 | if test "${with_threads+set}" = set; then |
| 3635 | withval="$with_threads" |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3636 | : |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 3637 | fi |
| 3638 | |
| 3639 | |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3640 | # --with-thread is deprecated, but check for it anyway |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3641 | # Check whether --with-thread or --without-thread was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 3642 | if test "${with_thread+set}" = set; then |
| 3643 | withval="$with_thread" |
Barry Warsaw | a0f3c5c | 2000-06-30 16:39:35 +0000 | [diff] [blame] | 3644 | |
| 3645 | with_threads=$with_thread |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 3646 | fi |
Barry Warsaw | c0d24d8b | 2000-06-29 16:12:00 +0000 | [diff] [blame] | 3647 | |
| 3648 | |
| 3649 | if test -z "$with_threads" |
| 3650 | then with_threads="yes" |
| 3651 | fi |
| 3652 | echo "$ac_t""$with_threads" 1>&6 |
| 3653 | |
| 3654 | if test "$with_threads" = "no" |
| 3655 | then |
| 3656 | USE_THREAD_MODULE="#" |
| 3657 | else |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3658 | if test "$ac_sys_system" = "UnixWare" |
| 3659 | then |
| 3660 | CC="${CC} -Kthread" |
| 3661 | LIBOBJS="$LIBOBJS thread.o" |
| 3662 | cat >> confdefs.h <<\EOF |
| 3663 | #define WITH_THREAD 1 |
| 3664 | EOF |
| 3665 | |
| 3666 | cat >> confdefs.h <<\EOF |
| 3667 | #define _POSIX_THREADS 1 |
| 3668 | EOF |
| 3669 | |
| 3670 | USE_THREAD_MODULE="" |
| 3671 | else |
| 3672 | if test ! -z "$with_threads" -a -d "$with_threads" |
| 3673 | then LDFLAGS="$LDFLAGS -L$with_threads" |
| 3674 | fi |
| 3675 | if test ! -z "$withval" -a -d "$withval" |
| 3676 | then LDFLAGS="$LDFLAGS -L$withval" |
| 3677 | fi |
| 3678 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 9caf77a | 1996-08-01 00:52:26 +0000 | [diff] [blame] | 3679 | #define _REENTRANT 1 |
| 3680 | EOF |
| 3681 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3682 | ac_safe=`echo "mach/cthreads.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3683 | echo $ac_n "checking for mach/cthreads.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3684 | echo "configure:3685: checking for mach/cthreads.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3685 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3686 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3687 | else |
| 3688 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3689 | #line 3690 "configure" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3690 | #include "confdefs.h" |
| 3691 | #include <mach/cthreads.h> |
| 3692 | EOF |
| 3693 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3694 | { (eval echo configure:3695: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3695 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3696 | if test -z "$ac_err"; then |
| 3697 | rm -rf conftest* |
| 3698 | eval "ac_cv_header_$ac_safe=yes" |
| 3699 | else |
| 3700 | echo "$ac_err" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3701 | echo "configure: failed program was:" >&5 |
| 3702 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3703 | rm -rf conftest* |
| 3704 | eval "ac_cv_header_$ac_safe=no" |
| 3705 | fi |
| 3706 | rm -f conftest* |
| 3707 | fi |
| 3708 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3709 | echo "$ac_t""yes" 1>&6 |
| 3710 | cat >> confdefs.h <<\EOF |
| 3711 | #define WITH_THREAD 1 |
| 3712 | EOF |
| 3713 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3714 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3715 | #define C_THREADS 1 |
| 3716 | EOF |
| 3717 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3718 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 3719 | else |
| 3720 | echo "$ac_t""no" 1>&6 |
| 3721 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3722 | echo $ac_n "checking for --with-pth""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3723 | echo "configure:3724: checking for --with-pth" >&5 |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3724 | # Check whether --with-pth or --without-pth was given. |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3725 | if test "${with_pth+set}" = set; then |
| 3726 | withval="$with_pth" |
| 3727 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3728 | echo "$ac_t""$withval" 1>&6 |
| 3729 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3730 | #define WITH_THREAD 1 |
| 3731 | EOF |
| 3732 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3733 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3734 | #define HAVE_PTH 1 |
| 3735 | EOF |
| 3736 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3737 | LIBS="-lpth $LIBS" |
| 3738 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 9e8181b | 2000-09-19 00:46:46 +0000 | [diff] [blame] | 3739 | else |
| 3740 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3741 | echo "$ac_t""no" 1>&6 |
| 3742 | echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3743 | echo "configure:3744: checking for pthread_create in -lpthread" >&5 |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3744 | ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3745 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3746 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3747 | else |
| 3748 | ac_save_LIBS="$LIBS" |
| 3749 | LIBS="-lpthread $LIBS" |
| 3750 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3751 | #line 3752 "configure" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3752 | #include "confdefs.h" |
| 3753 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3754 | /* We use char because int might match the return type of a gcc2 |
| 3755 | builtin and then its argument prototype would still apply. */ |
| 3756 | char pthread_create(); |
| 3757 | |
| 3758 | int main() { |
| 3759 | pthread_create() |
| 3760 | ; return 0; } |
| 3761 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3762 | if { (eval echo configure:3763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3763 | rm -rf conftest* |
| 3764 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3765 | else |
| 3766 | echo "configure: failed program was:" >&5 |
| 3767 | cat conftest.$ac_ext >&5 |
| 3768 | rm -rf conftest* |
| 3769 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3770 | fi |
| 3771 | rm -f conftest* |
| 3772 | LIBS="$ac_save_LIBS" |
| 3773 | |
| 3774 | fi |
| 3775 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3776 | echo "$ac_t""yes" 1>&6 |
| 3777 | cat >> confdefs.h <<\EOF |
| 3778 | #define WITH_THREAD 1 |
| 3779 | EOF |
| 3780 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3781 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3782 | #define _POSIX_THREADS 1 |
| 3783 | EOF |
| 3784 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3785 | LIBS="-lpthread $LIBS" |
| 3786 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 02a1c40 | 2000-02-25 19:26:31 +0000 | [diff] [blame] | 3787 | else |
| 3788 | echo "$ac_t""no" 1>&6 |
| 3789 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3790 | echo $ac_n "checking for pthread_detach""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3791 | echo "configure:3792: checking for pthread_detach" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3792 | if eval "test \"`echo '$''{'ac_cv_func_pthread_detach'+set}'`\" = set"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3793 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3794 | else |
| 3795 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3796 | #line 3797 "configure" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3797 | #include "confdefs.h" |
| 3798 | /* System header to define __stub macros and hopefully few prototypes, |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3799 | which can conflict with char pthread_detach(); below. */ |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3800 | #include <assert.h> |
| 3801 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3802 | /* We use char because int might match the return type of a gcc2 |
| 3803 | builtin and then its argument prototype would still apply. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3804 | char pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3805 | |
| 3806 | int main() { |
| 3807 | |
| 3808 | /* The GNU C library defines this for functions which it implements |
| 3809 | to always fail with ENOSYS. Some functions are actually named |
| 3810 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3811 | #if defined (__stub_pthread_detach) || defined (__stub___pthread_detach) |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3812 | choke me |
| 3813 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3814 | pthread_detach(); |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3815 | #endif |
| 3816 | |
| 3817 | ; return 0; } |
| 3818 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3819 | if { (eval echo configure:3820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3820 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3821 | eval "ac_cv_func_pthread_detach=yes" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3822 | else |
| 3823 | echo "configure: failed program was:" >&5 |
| 3824 | cat conftest.$ac_ext >&5 |
| 3825 | rm -rf conftest* |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3826 | eval "ac_cv_func_pthread_detach=no" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3827 | fi |
| 3828 | rm -f conftest* |
| 3829 | fi |
| 3830 | |
Guido van Rossum | ea51632 | 1998-12-17 18:08:55 +0000 | [diff] [blame] | 3831 | if eval "test \"`echo '$ac_cv_func_'pthread_detach`\" = yes"; then |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3832 | echo "$ac_t""yes" 1>&6 |
| 3833 | cat >> confdefs.h <<\EOF |
| 3834 | #define WITH_THREAD 1 |
| 3835 | EOF |
| 3836 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3837 | case $ac_sys_system in |
| 3838 | Darwin*) ;; |
| 3839 | *) cat >> confdefs.h <<\EOF |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3840 | #define _POSIX_THREADS 1 |
| 3841 | EOF |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 3842 | ;; |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3843 | esac |
| 3844 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 3845 | else |
| 3846 | echo "$ac_t""no" 1>&6 |
| 3847 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3848 | ac_safe=`echo "kernel/OS.h" | sed 'y%./+-%__p_%'` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3849 | echo $ac_n "checking for kernel/OS.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3850 | echo "configure:3851: checking for kernel/OS.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3851 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3852 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3853 | else |
| 3854 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3855 | #line 3856 "configure" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3856 | #include "confdefs.h" |
| 3857 | #include <kernel/OS.h> |
| 3858 | EOF |
| 3859 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3860 | { (eval echo configure:3861: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 3861 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3862 | if test -z "$ac_err"; then |
| 3863 | rm -rf conftest* |
| 3864 | eval "ac_cv_header_$ac_safe=yes" |
| 3865 | else |
| 3866 | echo "$ac_err" >&5 |
| 3867 | echo "configure: failed program was:" >&5 |
| 3868 | cat conftest.$ac_ext >&5 |
| 3869 | rm -rf conftest* |
| 3870 | eval "ac_cv_header_$ac_safe=no" |
| 3871 | fi |
| 3872 | rm -f conftest* |
| 3873 | fi |
| 3874 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 3875 | echo "$ac_t""yes" 1>&6 |
| 3876 | cat >> confdefs.h <<\EOF |
| 3877 | #define WITH_THREAD 1 |
| 3878 | EOF |
| 3879 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3880 | cat >> confdefs.h <<\EOF |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3881 | #define BEOS_THREADS 1 |
| 3882 | EOF |
| 3883 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3884 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 3885 | else |
| 3886 | echo "$ac_t""no" 1>&6 |
| 3887 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3888 | echo $ac_n "checking for pthread_create in -lpthreads""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3889 | echo "configure:3890: checking for pthread_create in -lpthreads" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 3890 | ac_lib_var=`echo pthreads'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3891 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3892 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3893 | else |
| 3894 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 3895 | LIBS="-lpthreads $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 3896 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3897 | #line 3898 "configure" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3898 | #include "confdefs.h" |
| 3899 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3900 | /* We use char because int might match the return type of a gcc2 |
| 3901 | builtin and then its argument prototype would still apply. */ |
| 3902 | char pthread_create(); |
| 3903 | |
| 3904 | int main() { |
| 3905 | pthread_create() |
| 3906 | ; return 0; } |
| 3907 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3908 | if { (eval echo configure:3909: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3909 | rm -rf conftest* |
| 3910 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3911 | else |
| 3912 | echo "configure: failed program was:" >&5 |
| 3913 | cat conftest.$ac_ext >&5 |
| 3914 | rm -rf conftest* |
| 3915 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3916 | fi |
| 3917 | rm -f conftest* |
| 3918 | LIBS="$ac_save_LIBS" |
| 3919 | |
| 3920 | fi |
| 3921 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3922 | echo "$ac_t""yes" 1>&6 |
| 3923 | cat >> confdefs.h <<\EOF |
| 3924 | #define WITH_THREAD 1 |
| 3925 | EOF |
| 3926 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3927 | cat >> confdefs.h <<\EOF |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3928 | #define _POSIX_THREADS 1 |
| 3929 | EOF |
| 3930 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3931 | LIBS="$LIBS -lpthreads" |
| 3932 | LIBOBJS="$LIBOBJS thread.o" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3933 | else |
| 3934 | echo "$ac_t""no" 1>&6 |
| 3935 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3936 | echo $ac_n "checking for pthread_create in -lc_r""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3937 | echo "configure:3938: checking for pthread_create in -lc_r" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3938 | ac_lib_var=`echo c_r'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3939 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3940 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3941 | else |
| 3942 | ac_save_LIBS="$LIBS" |
| 3943 | LIBS="-lc_r $LIBS" |
| 3944 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3945 | #line 3946 "configure" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3946 | #include "confdefs.h" |
| 3947 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3948 | /* We use char because int might match the return type of a gcc2 |
| 3949 | builtin and then its argument prototype would still apply. */ |
| 3950 | char pthread_create(); |
| 3951 | |
| 3952 | int main() { |
| 3953 | pthread_create() |
| 3954 | ; return 0; } |
| 3955 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3956 | if { (eval echo configure:3957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3957 | rm -rf conftest* |
| 3958 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 3959 | else |
| 3960 | echo "configure: failed program was:" >&5 |
| 3961 | cat conftest.$ac_ext >&5 |
| 3962 | rm -rf conftest* |
| 3963 | eval "ac_cv_lib_$ac_lib_var=no" |
| 3964 | fi |
| 3965 | rm -f conftest* |
| 3966 | LIBS="$ac_save_LIBS" |
| 3967 | |
| 3968 | fi |
| 3969 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 3970 | echo "$ac_t""yes" 1>&6 |
| 3971 | cat >> confdefs.h <<\EOF |
| 3972 | #define WITH_THREAD 1 |
| 3973 | EOF |
| 3974 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3975 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 3976 | #define _POSIX_THREADS 1 |
| 3977 | EOF |
| 3978 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3979 | LIBS="$LIBS -lc_r" |
| 3980 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3981 | else |
| 3982 | echo "$ac_t""no" 1>&6 |
| 3983 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 3984 | echo $ac_n "checking for __d6_pthread_create in -lthread""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3985 | echo "configure:3986: checking for __d6_pthread_create in -lthread" >&5 |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3986 | ac_lib_var=`echo thread'_'__d6_pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 3987 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3988 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 3989 | else |
| 3990 | ac_save_LIBS="$LIBS" |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3991 | LIBS="-lthread $LIBS" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3992 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 3993 | #line 3994 "configure" |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3994 | #include "confdefs.h" |
| 3995 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 3996 | /* We use char because int might match the return type of a gcc2 |
| 3997 | builtin and then its argument prototype would still apply. */ |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 3998 | char __d6_pthread_create(); |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 3999 | |
| 4000 | int main() { |
Greg Stein | adf63d6 | 2000-07-05 10:38:09 +0000 | [diff] [blame] | 4001 | __d6_pthread_create() |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 4002 | ; return 0; } |
| 4003 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4004 | if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 4005 | rm -rf conftest* |
| 4006 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4007 | else |
| 4008 | echo "configure: failed program was:" >&5 |
| 4009 | cat conftest.$ac_ext >&5 |
| 4010 | rm -rf conftest* |
| 4011 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4012 | fi |
| 4013 | rm -f conftest* |
| 4014 | LIBS="$ac_save_LIBS" |
| 4015 | |
| 4016 | fi |
| 4017 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4018 | echo "$ac_t""yes" 1>&6 |
| 4019 | cat >> confdefs.h <<\EOF |
| 4020 | #define WITH_THREAD 1 |
| 4021 | EOF |
| 4022 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4023 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 4024 | #define _POSIX_THREADS 1 |
| 4025 | EOF |
| 4026 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4027 | LIBS="$LIBS -lthread" |
| 4028 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 4029 | else |
| 4030 | echo "$ac_t""no" 1>&6 |
| 4031 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4032 | echo $ac_n "checking for __pthread_create_system in -lpthread""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4033 | echo "configure:4034: checking for __pthread_create_system in -lpthread" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4034 | ac_lib_var=`echo pthread'_'__pthread_create_system | sed 'y%./+-%__p_%'` |
| 4035 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
| 4036 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4037 | else |
| 4038 | ac_save_LIBS="$LIBS" |
| 4039 | LIBS="-lpthread $LIBS" |
| 4040 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4041 | #line 4042 "configure" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4042 | #include "confdefs.h" |
| 4043 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4044 | /* We use char because int might match the return type of a gcc2 |
| 4045 | builtin and then its argument prototype would still apply. */ |
| 4046 | char __pthread_create_system(); |
| 4047 | |
| 4048 | int main() { |
| 4049 | __pthread_create_system() |
| 4050 | ; return 0; } |
| 4051 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4052 | if { (eval echo configure:4053: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4053 | rm -rf conftest* |
| 4054 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4055 | else |
| 4056 | echo "configure: failed program was:" >&5 |
| 4057 | cat conftest.$ac_ext >&5 |
| 4058 | rm -rf conftest* |
| 4059 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4060 | fi |
| 4061 | rm -f conftest* |
| 4062 | LIBS="$ac_save_LIBS" |
| 4063 | |
| 4064 | fi |
| 4065 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4066 | echo "$ac_t""yes" 1>&6 |
| 4067 | cat >> confdefs.h <<\EOF |
| 4068 | #define WITH_THREAD 1 |
| 4069 | EOF |
| 4070 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4071 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4072 | #define _POSIX_THREADS 1 |
| 4073 | EOF |
| 4074 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4075 | LIBS="$LIBS -lpthread" |
| 4076 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4077 | else |
| 4078 | echo "$ac_t""no" 1>&6 |
| 4079 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4080 | echo $ac_n "checking for pthread_create in -lcma""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4081 | echo "configure:4082: checking for pthread_create in -lcma" >&5 |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4082 | ac_lib_var=`echo cma'_'pthread_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4083 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4084 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4085 | else |
| 4086 | ac_save_LIBS="$LIBS" |
| 4087 | LIBS="-lcma $LIBS" |
| 4088 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4089 | #line 4090 "configure" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4090 | #include "confdefs.h" |
| 4091 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4092 | /* We use char because int might match the return type of a gcc2 |
| 4093 | builtin and then its argument prototype would still apply. */ |
| 4094 | char pthread_create(); |
| 4095 | |
| 4096 | int main() { |
| 4097 | pthread_create() |
| 4098 | ; return 0; } |
| 4099 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4100 | if { (eval echo configure:4101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4101 | rm -rf conftest* |
| 4102 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4103 | else |
| 4104 | echo "configure: failed program was:" >&5 |
| 4105 | cat conftest.$ac_ext >&5 |
| 4106 | rm -rf conftest* |
| 4107 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4108 | fi |
| 4109 | rm -f conftest* |
| 4110 | LIBS="$ac_save_LIBS" |
| 4111 | |
| 4112 | fi |
| 4113 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4114 | echo "$ac_t""yes" 1>&6 |
| 4115 | cat >> confdefs.h <<\EOF |
| 4116 | #define WITH_THREAD 1 |
| 4117 | EOF |
| 4118 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4119 | cat >> confdefs.h <<\EOF |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4120 | #define _POSIX_THREADS 1 |
| 4121 | EOF |
| 4122 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4123 | LIBS="$LIBS -lcma" |
| 4124 | LIBOBJS="$LIBOBJS thread.o" |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4125 | else |
| 4126 | echo "$ac_t""no" 1>&6 |
Thomas Wouters | 0db2b2b | 2000-08-26 11:33:43 +0000 | [diff] [blame] | 4127 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4128 | USE_THREAD_MODULE="#" |
Guido van Rossum | 2d38f91 | 1996-06-26 19:47:01 +0000 | [diff] [blame] | 4129 | fi |
| 4130 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4131 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4132 | fi |
| 4133 | |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4134 | fi |
| 4135 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 4136 | fi |
| 4137 | |
Guido van Rossum | 4954595 | 1997-12-02 19:28:29 +0000 | [diff] [blame] | 4138 | fi |
| 4139 | |
Guido van Rossum | b93a862 | 1998-05-07 13:27:32 +0000 | [diff] [blame] | 4140 | fi |
| 4141 | |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 4142 | fi |
| 4143 | |
Guido van Rossum | ad678af | 1998-10-02 14:42:15 +0000 | [diff] [blame] | 4144 | fi |
| 4145 | |
Guido van Rossum | 07bd90e | 2000-05-08 13:41:38 +0000 | [diff] [blame] | 4146 | fi |
| 4147 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4148 | fi |
| 4149 | |
Guido van Rossum | 0be3e49 | 1997-05-22 20:33:33 +0000 | [diff] [blame] | 4150 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4151 | echo $ac_n "checking for usconfig in -lmpc""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4152 | echo "configure:4153: checking for usconfig in -lmpc" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4153 | ac_lib_var=`echo mpc'_'usconfig | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4154 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4155 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4156 | else |
| 4157 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4158 | LIBS="-lmpc $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4159 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4160 | #line 4161 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4161 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4162 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4163 | /* We use char because int might match the return type of a gcc2 |
| 4164 | builtin and then its argument prototype would still apply. */ |
| 4165 | char usconfig(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4166 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4167 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4168 | usconfig() |
| 4169 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4170 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4171 | if { (eval echo configure:4172: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4172 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4173 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4174 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4175 | echo "configure: failed program was:" >&5 |
| 4176 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4177 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4178 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4179 | fi |
| 4180 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4181 | LIBS="$ac_save_LIBS" |
| 4182 | |
| 4183 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4184 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4185 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4186 | cat >> confdefs.h <<\EOF |
| 4187 | #define WITH_THREAD 1 |
| 4188 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4189 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4190 | LIBS="$LIBS -lmpc" |
| 4191 | LIBOBJS="$LIBOBJS thread.o" |
| 4192 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4193 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4194 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4195 | fi |
| 4196 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4197 | echo $ac_n "checking for thr_create in -lthread""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4198 | echo "configure:4199: checking for thr_create in -lthread" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4199 | ac_lib_var=`echo thread'_'thr_create | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4200 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4201 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4202 | else |
| 4203 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4204 | LIBS="-lthread $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4205 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4206 | #line 4207 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4207 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4208 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4209 | /* We use char because int might match the return type of a gcc2 |
| 4210 | builtin and then its argument prototype would still apply. */ |
| 4211 | char thr_create(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4212 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4213 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4214 | thr_create() |
| 4215 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4216 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4217 | if { (eval echo configure:4218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4218 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4219 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4220 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4221 | echo "configure: failed program was:" >&5 |
| 4222 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4223 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4224 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4225 | fi |
| 4226 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4227 | LIBS="$ac_save_LIBS" |
| 4228 | |
| 4229 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4230 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4231 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4232 | cat >> confdefs.h <<\EOF |
| 4233 | #define WITH_THREAD 1 |
| 4234 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4235 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4236 | LIBS="$LIBS -lthread" |
| 4237 | LIBOBJS="$LIBOBJS thread.o" |
| 4238 | USE_THREAD_MODULE="" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4239 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4240 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4241 | fi |
| 4242 | |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 4243 | |
Guido van Rossum | 2242f2f | 2001-04-11 20:58:20 +0000 | [diff] [blame] | 4244 | if test "$USE_THREAD_MODULE" != "#" |
| 4245 | then |
| 4246 | # If the above checks didn't disable threads, (at least) OSF1 |
| 4247 | # needs this '-threads' argument during linking. |
| 4248 | case $ac_sys_system in |
| 4249 | OSF1) LDLAST=-threads;; |
| 4250 | esac |
| 4251 | fi |
Jeremy Hylton | 1a2ca86 | 2000-10-16 16:59:12 +0000 | [diff] [blame] | 4252 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4253 | fi |
| 4254 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4255 | # Check for GC support |
| 4256 | |
| 4257 | USE_GC_MODULE="" |
| 4258 | echo $ac_n "checking for --with-cycle-gc""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4259 | echo "configure:4260: checking for --with-cycle-gc" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4260 | # Check whether --with-cycle-gc or --without-cycle-gc was given. |
| 4261 | if test "${with_cycle_gc+set}" = set; then |
| 4262 | withval="$with_cycle_gc" |
| 4263 | : |
| 4264 | fi |
| 4265 | |
| 4266 | |
| 4267 | if test -z "$with_cycle_gc" |
| 4268 | then with_cycle_gc="yes" |
| 4269 | fi |
| 4270 | if test "$with_cycle_gc" = "no" |
| 4271 | then |
| 4272 | USE_GC_MODULE="#" |
| 4273 | else |
| 4274 | cat >> confdefs.h <<\EOF |
| 4275 | #define WITH_CYCLE_GC 1 |
| 4276 | EOF |
| 4277 | |
| 4278 | fi |
| 4279 | echo "$ac_t""$with_cycle_gc" 1>&6 |
| 4280 | |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 4281 | # Check for Python-specific malloc support |
| 4282 | echo $ac_n "checking for --with-pymalloc""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4283 | echo "configure:4284: checking for --with-pymalloc" >&5 |
Neil Schemenauer | a35c688 | 2001-02-27 04:45:05 +0000 | [diff] [blame] | 4284 | # Check whether --with-pymalloc or --without-pymalloc was given. |
| 4285 | if test "${with_pymalloc+set}" = set; then |
| 4286 | withval="$with_pymalloc" |
| 4287 | |
| 4288 | if test "$withval" != no |
| 4289 | then cat >> confdefs.h <<\EOF |
| 4290 | #define WITH_PYMALLOC 1 |
| 4291 | EOF |
| 4292 | echo "$ac_t""yes" 1>&6 |
| 4293 | else echo "$ac_t""no" 1>&6 |
| 4294 | fi |
| 4295 | else |
| 4296 | echo "$ac_t""no" 1>&6 |
| 4297 | fi |
| 4298 | |
| 4299 | |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4300 | # Check for --with-wctype-functions |
| 4301 | echo $ac_n "checking for --with-wctype-functions""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4302 | echo "configure:4303: checking for --with-wctype-functions" >&5 |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 4303 | # Check whether --with-wctype-functions or --without-wctype-functions was given. |
| 4304 | if test "${with_wctype_functions+set}" = set; then |
| 4305 | withval="$with_wctype_functions" |
| 4306 | |
| 4307 | if test "$withval" != no |
| 4308 | then cat >> confdefs.h <<\EOF |
| 4309 | #define WANT_WCTYPE_FUNCTIONS 1 |
| 4310 | EOF |
| 4311 | echo "$ac_t""yes" 1>&6 |
| 4312 | else echo "$ac_t""no" 1>&6 |
| 4313 | fi |
| 4314 | else |
| 4315 | echo "$ac_t""no" 1>&6 |
| 4316 | fi |
| 4317 | |
| 4318 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4319 | # -I${DLINCLDIR} is added to the compile rule for importdl.o |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4320 | |
| 4321 | DLINCLDIR=/ |
| 4322 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4323 | echo $ac_n "checking for --with-sgi-dl""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4324 | echo "configure:4325: checking for --with-sgi-dl" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4325 | # Check whether --with-sgi-dl or --without-sgi-dl was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4326 | if test "${with_sgi_dl+set}" = set; then |
| 4327 | withval="$with_sgi_dl" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4328 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4329 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4330 | cat >> confdefs.h <<\EOF |
| 4331 | #define WITH_SGI_DL 1 |
| 4332 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4333 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4334 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4335 | dldir=$withval |
Guido van Rossum | 4095101 | 2000-10-07 16:21:27 +0000 | [diff] [blame] | 4336 | if test ! -z "$dldir" -a -d "$dldir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 4337 | then LDFLAGS="$LDFLAGS -L$dldir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4338 | else { echo "configure: error: proper usage is --with-sgi-dl=DIRECTORY" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4339 | fi |
| 4340 | DLINCLDIR=${dldir} |
| 4341 | LIBS="$LIBS -ldl -lmld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4342 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4343 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4344 | fi |
| 4345 | |
| 4346 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4347 | echo $ac_n "checking for --with-dl-dld""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4348 | echo "configure:4349: checking for --with-dl-dld" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4349 | # Check whether --with-dl-dld or --without-dl-dld was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4350 | if test "${with_dl_dld+set}" = set; then |
| 4351 | withval="$with_dl_dld" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4352 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4353 | echo "$ac_t""$withval" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4354 | cat >> confdefs.h <<\EOF |
| 4355 | #define WITH_DL_DLD 1 |
| 4356 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4357 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4358 | DYNLOADFILE="dynload_dl.o" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4359 | dldir=`echo "$withval" | sed 's/,.*//'` |
| 4360 | dlddir=`echo "$withval" | sed 's/.*,//'` |
Barry Warsaw | 7d1219d | 2000-10-05 18:45:53 +0000 | [diff] [blame] | 4361 | if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir" |
Guido van Rossum | 84e7b24 | 1996-08-19 21:59:00 +0000 | [diff] [blame] | 4362 | then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4363 | else { echo "configure: error: proper usage is --with-dl-dld=DL_DIRECTORY" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4364 | fi |
| 4365 | DLINCLDIR=${dldir} |
| 4366 | LIBS="$LIBS -ldl -ldld" |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 4367 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4368 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4369 | fi |
| 4370 | |
| 4371 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4372 | # the dlopen() function means we might want to use dynload_shlib.o. some |
| 4373 | # 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] | 4374 | for ac_func in dlopen |
| 4375 | do |
| 4376 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4377 | echo "configure:4378: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4378 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4379 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4380 | else |
| 4381 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4382 | #line 4383 "configure" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4383 | #include "confdefs.h" |
| 4384 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4385 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4386 | #include <assert.h> |
| 4387 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4388 | /* We use char because int might match the return type of a gcc2 |
| 4389 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4390 | char $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4391 | |
| 4392 | int main() { |
| 4393 | |
| 4394 | /* The GNU C library defines this for functions which it implements |
| 4395 | to always fail with ENOSYS. Some functions are actually named |
| 4396 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4397 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4398 | choke me |
| 4399 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4400 | $ac_func(); |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4401 | #endif |
| 4402 | |
| 4403 | ; return 0; } |
| 4404 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4405 | if { (eval echo configure:4406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4406 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4407 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4408 | else |
| 4409 | echo "configure: failed program was:" >&5 |
| 4410 | cat conftest.$ac_ext >&5 |
| 4411 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4412 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4413 | fi |
| 4414 | rm -f conftest* |
| 4415 | fi |
| 4416 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4417 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4418 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4419 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4420 | cat >> confdefs.h <<EOF |
| 4421 | #define $ac_tr_func 1 |
| 4422 | EOF |
| 4423 | |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4424 | else |
| 4425 | echo "$ac_t""no" 1>&6 |
| 4426 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4427 | done |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4428 | |
| 4429 | |
| 4430 | # DYNLOADFILE specifies which dynload_*.o file we will use for dynamic |
| 4431 | # loading of modules. |
| 4432 | |
| 4433 | echo $ac_n "checking DYNLOADFILE""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4434 | echo "configure:4435: checking DYNLOADFILE" >&5 |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4435 | if test -z "$DYNLOADFILE" |
| 4436 | then |
| 4437 | case $ac_sys_system/$ac_sys_release in |
| 4438 | AIX*) DYNLOADFILE="dynload_aix.o";; |
| 4439 | BeOS*) DYNLOADFILE="dynload_beos.o";; |
| 4440 | hp*|HP*) DYNLOADFILE="dynload_hpux.o";; |
Guido van Rossum | 5839e58 | 2000-10-09 19:52:35 +0000 | [diff] [blame] | 4441 | Darwin/*|next/*) DYNLOADFILE="dynload_next.o";; |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 4442 | *) |
| 4443 | # use dynload_shlib.c and dlopen() if we have it; otherwise stub |
| 4444 | # out any dynamic loading |
| 4445 | if test "$ac_cv_func_dlopen" = yes |
| 4446 | then DYNLOADFILE="dynload_shlib.o" |
| 4447 | else DYNLOADFILE="dynload_stub.o" |
| 4448 | fi |
| 4449 | ;; |
| 4450 | esac |
| 4451 | fi |
| 4452 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 4453 | if test "$DYNLOADFILE" != "dynload_stub.o" |
| 4454 | then |
| 4455 | cat >> confdefs.h <<\EOF |
| 4456 | #define HAVE_DYNAMIC_LOADING 1 |
| 4457 | EOF |
| 4458 | |
| 4459 | fi |
| 4460 | |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 4461 | # MACHDEP_OBJS can be set to platform-specific object files needed by Python |
| 4462 | |
| 4463 | |
| 4464 | echo $ac_n "checking MACHDEP_OBJS""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4465 | echo "configure:4466: checking MACHDEP_OBJS" >&5 |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 4466 | if test -z "$MACHDEP_OBJS" |
| 4467 | then |
| 4468 | case $ac_sys_system/$ac_sys_release in |
| 4469 | Darwin/*) |
| 4470 | MACHDEP_OBJS="Mac/Python/macglue.o" |
| 4471 | cat >> confdefs.h <<\EOF |
| 4472 | #define USE_TOOLBOX_OBJECT_GLUE 1 |
| 4473 | EOF |
| 4474 | |
| 4475 | ;; |
| 4476 | *) MACHDEP_OBJS="";; |
| 4477 | esac |
| 4478 | fi |
| 4479 | echo "$ac_t""$DYNLOADFILE" 1>&6 |
| 4480 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4481 | # checks for library functions |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4482 | for ac_func in alarm chown clock confstr ctermid ctermid_r execv \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4483 | flock fork fsync fdatasync fpathconf ftime ftruncate \ |
Andrew M. Kuchling | a9586c7 | 2001-01-08 17:58:56 +0000 | [diff] [blame] | 4484 | getgroups getlogin getpeername getpid getpwent getwd \ |
Martin v. Löwis | b9ab159 | 2001-06-24 21:18:26 +0000 | [diff] [blame] | 4485 | inet_pton kill link lstat mkfifo mktime mremap \ |
Andrew M. Kuchling | 5821b77 | 2000-08-25 01:14:08 +0000 | [diff] [blame] | 4486 | nice pathconf pause plock poll pthread_init \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4487 | putenv readlink \ |
Andrew M. Kuchling | 8d2f2b2 | 2000-07-13 01:26:58 +0000 | [diff] [blame] | 4488 | select setegid seteuid setgid \ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4489 | setlocale setregid setreuid setsid setpgid setuid setvbuf \ |
Fred Drake | 35a092f | 1999-12-13 16:23:35 +0000 | [diff] [blame] | 4490 | sigaction siginterrupt sigrelse strftime strptime symlink sysconf \ |
Fred Drake | 89143df | 1999-12-09 22:03:25 +0000 | [diff] [blame] | 4491 | tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \ |
Thomas Wouters | 70c21a1 | 2000-07-14 14:28:33 +0000 | [diff] [blame] | 4492 | truncate uname waitpid _getpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4493 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4494 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4495 | echo "configure:4496: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4496 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4497 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4498 | else |
| 4499 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4500 | #line 4501 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4501 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4502 | /* System header to define __stub macros and hopefully few prototypes, |
| 4503 | which can conflict with char $ac_func(); below. */ |
| 4504 | #include <assert.h> |
| 4505 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4506 | /* We use char because int might match the return type of a gcc2 |
| 4507 | builtin and then its argument prototype would still apply. */ |
| 4508 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4509 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4510 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4511 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4512 | /* The GNU C library defines this for functions which it implements |
| 4513 | to always fail with ENOSYS. Some functions are actually named |
| 4514 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4515 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4516 | choke me |
| 4517 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4518 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4519 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4520 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4521 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4522 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4523 | if { (eval echo configure:4524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4524 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4525 | eval "ac_cv_func_$ac_func=yes" |
| 4526 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4527 | echo "configure: failed program was:" >&5 |
| 4528 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4529 | rm -rf conftest* |
| 4530 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4531 | fi |
| 4532 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4533 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4534 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4535 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4536 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4537 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4538 | cat >> confdefs.h <<EOF |
| 4539 | #define $ac_tr_func 1 |
| 4540 | EOF |
| 4541 | |
| 4542 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4543 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4544 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4545 | done |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 4546 | |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4547 | |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4548 | # check for openpty and forkpty |
| 4549 | |
| 4550 | for ac_func in openpty |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4551 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4552 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4553 | echo "configure:4554: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4554 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4555 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4556 | else |
| 4557 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4558 | #line 4559 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4559 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4560 | /* System header to define __stub macros and hopefully few prototypes, |
| 4561 | which can conflict with char $ac_func(); below. */ |
| 4562 | #include <assert.h> |
| 4563 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4564 | /* We use char because int might match the return type of a gcc2 |
| 4565 | builtin and then its argument prototype would still apply. */ |
| 4566 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4567 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4568 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4569 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4570 | /* The GNU C library defines this for functions which it implements |
| 4571 | to always fail with ENOSYS. Some functions are actually named |
| 4572 | something starting with __ and the normal name is an alias. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4573 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4574 | choke me |
| 4575 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4576 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4577 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4578 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4579 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4580 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4581 | if { (eval echo configure:4582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4582 | rm -rf conftest* |
| 4583 | eval "ac_cv_func_$ac_func=yes" |
| 4584 | else |
| 4585 | echo "configure: failed program was:" >&5 |
| 4586 | cat conftest.$ac_ext >&5 |
| 4587 | rm -rf conftest* |
| 4588 | eval "ac_cv_func_$ac_func=no" |
| 4589 | fi |
| 4590 | rm -f conftest* |
| 4591 | fi |
| 4592 | |
| 4593 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4594 | echo "$ac_t""yes" 1>&6 |
| 4595 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4596 | cat >> confdefs.h <<EOF |
| 4597 | #define $ac_tr_func 1 |
| 4598 | EOF |
| 4599 | |
| 4600 | else |
| 4601 | echo "$ac_t""no" 1>&6 |
| 4602 | echo $ac_n "checking for openpty in -lutil""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4603 | echo "configure:4604: checking for openpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4604 | ac_lib_var=`echo util'_'openpty | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4605 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4606 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4607 | else |
| 4608 | ac_save_LIBS="$LIBS" |
| 4609 | LIBS="-lutil $LIBS" |
| 4610 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4611 | #line 4612 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4612 | #include "confdefs.h" |
| 4613 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4614 | /* We use char because int might match the return type of a gcc2 |
| 4615 | builtin and then its argument prototype would still apply. */ |
| 4616 | char openpty(); |
| 4617 | |
| 4618 | int main() { |
| 4619 | openpty() |
| 4620 | ; return 0; } |
| 4621 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4622 | if { (eval echo configure:4623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4623 | rm -rf conftest* |
| 4624 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4625 | else |
| 4626 | echo "configure: failed program was:" >&5 |
| 4627 | cat conftest.$ac_ext >&5 |
| 4628 | rm -rf conftest* |
| 4629 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4630 | fi |
| 4631 | rm -f conftest* |
| 4632 | LIBS="$ac_save_LIBS" |
| 4633 | |
| 4634 | fi |
| 4635 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4636 | echo "$ac_t""yes" 1>&6 |
| 4637 | cat >> confdefs.h <<\EOF |
| 4638 | #define HAVE_OPENPTY 1 |
| 4639 | EOF |
| 4640 | LIBS="$LIBS -lutil" |
| 4641 | else |
| 4642 | echo "$ac_t""no" 1>&6 |
| 4643 | fi |
| 4644 | |
| 4645 | fi |
| 4646 | done |
| 4647 | |
| 4648 | for ac_func in forkpty |
| 4649 | do |
| 4650 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4651 | echo "configure:4652: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4652 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4653 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4654 | else |
| 4655 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4656 | #line 4657 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4657 | #include "confdefs.h" |
| 4658 | /* System header to define __stub macros and hopefully few prototypes, |
| 4659 | which can conflict with char $ac_func(); below. */ |
| 4660 | #include <assert.h> |
| 4661 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4662 | /* We use char because int might match the return type of a gcc2 |
| 4663 | builtin and then its argument prototype would still apply. */ |
| 4664 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4665 | |
| 4666 | int main() { |
| 4667 | |
| 4668 | /* The GNU C library defines this for functions which it implements |
| 4669 | to always fail with ENOSYS. Some functions are actually named |
| 4670 | something starting with __ and the normal name is an alias. */ |
| 4671 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4672 | choke me |
| 4673 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4674 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4675 | #endif |
| 4676 | |
| 4677 | ; return 0; } |
| 4678 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4679 | if { (eval echo configure:4680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4680 | rm -rf conftest* |
| 4681 | eval "ac_cv_func_$ac_func=yes" |
| 4682 | else |
| 4683 | echo "configure: failed program was:" >&5 |
| 4684 | cat conftest.$ac_ext >&5 |
| 4685 | rm -rf conftest* |
| 4686 | eval "ac_cv_func_$ac_func=no" |
| 4687 | fi |
| 4688 | rm -f conftest* |
| 4689 | fi |
| 4690 | |
| 4691 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4692 | echo "$ac_t""yes" 1>&6 |
| 4693 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4694 | cat >> confdefs.h <<EOF |
| 4695 | #define $ac_tr_func 1 |
| 4696 | EOF |
| 4697 | |
| 4698 | else |
| 4699 | echo "$ac_t""no" 1>&6 |
| 4700 | echo $ac_n "checking for forkpty in -lutil""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4701 | echo "configure:4702: checking for forkpty in -lutil" >&5 |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4702 | ac_lib_var=`echo util'_'forkpty | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4703 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4704 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4705 | else |
| 4706 | ac_save_LIBS="$LIBS" |
| 4707 | LIBS="-lutil $LIBS" |
| 4708 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4709 | #line 4710 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4710 | #include "confdefs.h" |
| 4711 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4712 | /* We use char because int might match the return type of a gcc2 |
| 4713 | builtin and then its argument prototype would still apply. */ |
| 4714 | char forkpty(); |
| 4715 | |
| 4716 | int main() { |
| 4717 | forkpty() |
| 4718 | ; return 0; } |
| 4719 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4720 | if { (eval echo configure:4721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4721 | rm -rf conftest* |
| 4722 | eval "ac_cv_lib_$ac_lib_var=yes" |
| 4723 | else |
| 4724 | echo "configure: failed program was:" >&5 |
| 4725 | cat conftest.$ac_ext >&5 |
| 4726 | rm -rf conftest* |
| 4727 | eval "ac_cv_lib_$ac_lib_var=no" |
| 4728 | fi |
| 4729 | rm -f conftest* |
| 4730 | LIBS="$ac_save_LIBS" |
| 4731 | |
| 4732 | fi |
| 4733 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
| 4734 | echo "$ac_t""yes" 1>&6 |
| 4735 | cat >> confdefs.h <<\EOF |
| 4736 | #define HAVE_FORKPTY 1 |
| 4737 | EOF |
| 4738 | LIBS="$LIBS -lutil" |
| 4739 | else |
| 4740 | echo "$ac_t""no" 1>&6 |
| 4741 | fi |
| 4742 | |
| 4743 | fi |
| 4744 | done |
| 4745 | |
| 4746 | |
| 4747 | # check for long file support functions |
| 4748 | for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs |
| 4749 | do |
| 4750 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4751 | echo "configure:4752: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4752 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4753 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4754 | else |
| 4755 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4756 | #line 4757 "configure" |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4757 | #include "confdefs.h" |
| 4758 | /* System header to define __stub macros and hopefully few prototypes, |
| 4759 | which can conflict with char $ac_func(); below. */ |
| 4760 | #include <assert.h> |
| 4761 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4762 | /* We use char because int might match the return type of a gcc2 |
| 4763 | builtin and then its argument prototype would still apply. */ |
| 4764 | char $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4765 | |
| 4766 | int main() { |
| 4767 | |
| 4768 | /* The GNU C library defines this for functions which it implements |
| 4769 | to always fail with ENOSYS. Some functions are actually named |
| 4770 | something starting with __ and the normal name is an alias. */ |
| 4771 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4772 | choke me |
| 4773 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4774 | $ac_func(); |
Fred Drake | 8cef4cf | 2000-06-28 16:40:38 +0000 | [diff] [blame] | 4775 | #endif |
| 4776 | |
| 4777 | ; return 0; } |
| 4778 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4779 | if { (eval echo configure:4780: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4780 | rm -rf conftest* |
| 4781 | eval "ac_cv_func_$ac_func=yes" |
| 4782 | else |
| 4783 | echo "configure: failed program was:" >&5 |
| 4784 | cat conftest.$ac_ext >&5 |
| 4785 | rm -rf conftest* |
| 4786 | eval "ac_cv_func_$ac_func=no" |
| 4787 | fi |
| 4788 | rm -f conftest* |
| 4789 | fi |
| 4790 | |
| 4791 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 4792 | echo "$ac_t""yes" 1>&6 |
| 4793 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4794 | cat >> confdefs.h <<EOF |
| 4795 | #define $ac_tr_func 1 |
| 4796 | EOF |
| 4797 | |
| 4798 | else |
| 4799 | echo "$ac_t""no" 1>&6 |
| 4800 | fi |
| 4801 | done |
| 4802 | |
| 4803 | |
| 4804 | for ac_func in dup2 getcwd strdup strerror memmove |
| 4805 | do |
| 4806 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4807 | echo "configure:4808: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4808 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4809 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 4810 | else |
| 4811 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4812 | #line 4813 "configure" |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4813 | #include "confdefs.h" |
| 4814 | /* System header to define __stub macros and hopefully few prototypes, |
| 4815 | which can conflict with char $ac_func(); below. */ |
| 4816 | #include <assert.h> |
| 4817 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 4818 | /* We use char because int might match the return type of a gcc2 |
| 4819 | builtin and then its argument prototype would still apply. */ |
| 4820 | char $ac_func(); |
| 4821 | |
| 4822 | int main() { |
| 4823 | |
| 4824 | /* The GNU C library defines this for functions which it implements |
| 4825 | to always fail with ENOSYS. Some functions are actually named |
| 4826 | something starting with __ and the normal name is an alias. */ |
| 4827 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 4828 | choke me |
| 4829 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4830 | $ac_func(); |
Guido van Rossum | f98e2a7 | 1999-01-06 18:53:34 +0000 | [diff] [blame] | 4831 | #endif |
| 4832 | |
| 4833 | ; return 0; } |
| 4834 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4835 | if { (eval echo configure:4836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4836 | rm -rf conftest* |
| 4837 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4838 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4839 | echo "configure: failed program was:" >&5 |
| 4840 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4841 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4842 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4843 | fi |
| 4844 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4845 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4846 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4847 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4848 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4849 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4850 | cat >> confdefs.h <<EOF |
| 4851 | #define $ac_tr_func 1 |
| 4852 | EOF |
| 4853 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4854 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4855 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 4856 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4857 | fi |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4858 | done |
| 4859 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4860 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4861 | for ac_func in getpgrp |
| 4862 | do |
| 4863 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4864 | echo "configure:4865: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4865 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4866 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4867 | else |
| 4868 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4869 | #line 4870 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4870 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4871 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4872 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4873 | #include <assert.h> |
| 4874 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4875 | /* We use char because int might match the return type of a gcc2 |
| 4876 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4877 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4878 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4879 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4880 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4881 | /* The GNU C library defines this for functions which it implements |
| 4882 | to always fail with ENOSYS. Some functions are actually named |
| 4883 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4884 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4885 | choke me |
| 4886 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4887 | $ac_func(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4888 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4889 | |
| 4890 | ; return 0; } |
| 4891 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4892 | if { (eval echo configure:4893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4893 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4894 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4895 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4896 | echo "configure: failed program was:" >&5 |
| 4897 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4898 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4899 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4900 | fi |
| 4901 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4902 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4903 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4904 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4905 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4906 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4907 | cat >> confdefs.h <<EOF |
| 4908 | #define $ac_tr_func 1 |
| 4909 | EOF |
| 4910 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4911 | #line 4912 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4912 | #include "confdefs.h" |
| 4913 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4914 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4915 | getpgrp(0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 4916 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4917 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4918 | if { (eval echo configure:4919: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4919 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4920 | cat >> confdefs.h <<\EOF |
| 4921 | #define GETPGRP_HAVE_ARG 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4922 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4923 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4924 | else |
| 4925 | echo "configure: failed program was:" >&5 |
| 4926 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4927 | fi |
| 4928 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4929 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4930 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4931 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4932 | done |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 4933 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4934 | for ac_func in setpgrp |
| 4935 | do |
| 4936 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4937 | echo "configure:4938: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4938 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4939 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4940 | else |
| 4941 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4942 | #line 4943 "configure" |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4943 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4944 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4945 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4946 | #include <assert.h> |
| 4947 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 4948 | /* We use char because int might match the return type of a gcc2 |
| 4949 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4950 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4951 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4952 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4953 | |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4954 | /* The GNU C library defines this for functions which it implements |
| 4955 | to always fail with ENOSYS. Some functions are actually named |
| 4956 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4957 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4958 | choke me |
| 4959 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 4960 | $ac_func(); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4961 | #endif |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4962 | |
| 4963 | ; return 0; } |
| 4964 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4965 | if { (eval echo configure:4966: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4966 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4967 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4968 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4969 | echo "configure: failed program was:" >&5 |
| 4970 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4971 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4972 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4973 | fi |
| 4974 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4975 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4976 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4977 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 4978 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 4979 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 4980 | cat >> confdefs.h <<EOF |
| 4981 | #define $ac_tr_func 1 |
| 4982 | EOF |
| 4983 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4984 | #line 4985 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4985 | #include "confdefs.h" |
| 4986 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4987 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4988 | setpgrp(0,0); |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4989 | ; return 0; } |
| 4990 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 4991 | if { (eval echo configure:4992: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4992 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 4993 | cat >> confdefs.h <<\EOF |
| 4994 | #define SETPGRP_HAVE_ARG 1 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4995 | EOF |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 4996 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 4997 | else |
| 4998 | echo "configure: failed program was:" >&5 |
| 4999 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5000 | fi |
| 5001 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5002 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5003 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5004 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5005 | done |
Guido van Rossum | 8eee56f | 1994-10-20 22:18:37 +0000 | [diff] [blame] | 5006 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5007 | for ac_func in gettimeofday |
| 5008 | do |
| 5009 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5010 | echo "configure:5011: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5011 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5012 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5013 | else |
| 5014 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5015 | #line 5016 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5016 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5017 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5018 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5019 | #include <assert.h> |
| 5020 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5021 | /* We use char because int might match the return type of a gcc2 |
| 5022 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5023 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5024 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5025 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5026 | |
| 5027 | /* The GNU C library defines this for functions which it implements |
| 5028 | to always fail with ENOSYS. Some functions are actually named |
| 5029 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5030 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5031 | choke me |
| 5032 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5033 | $ac_func(); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5034 | #endif |
| 5035 | |
| 5036 | ; return 0; } |
| 5037 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5038 | if { (eval echo configure:5039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5039 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5040 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5041 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5042 | echo "configure: failed program was:" >&5 |
| 5043 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5044 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5045 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5046 | fi |
| 5047 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5048 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5049 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5050 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5051 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5052 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5053 | cat >> confdefs.h <<EOF |
| 5054 | #define $ac_tr_func 1 |
| 5055 | EOF |
| 5056 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5057 | #line 5058 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5058 | #include "confdefs.h" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5059 | #include <sys/time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5060 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5061 | gettimeofday((struct timeval*)0,(struct timezone*)0); |
| 5062 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5063 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5064 | if { (eval echo configure:5065: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5065 | : |
| 5066 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5067 | echo "configure: failed program was:" >&5 |
| 5068 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5069 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5070 | cat >> confdefs.h <<\EOF |
| 5071 | #define GETTIMEOFDAY_NO_TZ 1 |
| 5072 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5073 | |
| 5074 | fi |
| 5075 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5076 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5077 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5078 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 5079 | done |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5080 | |
| 5081 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5082 | for ac_func in getaddrinfo |
| 5083 | do |
| 5084 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5085 | echo "configure:5086: checking for $ac_func" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5086 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 5087 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5088 | else |
| 5089 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5090 | #line 5091 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5091 | #include "confdefs.h" |
| 5092 | /* System header to define __stub macros and hopefully few prototypes, |
| 5093 | which can conflict with char $ac_func(); below. */ |
| 5094 | #include <assert.h> |
| 5095 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5096 | /* We use char because int might match the return type of a gcc2 |
| 5097 | builtin and then its argument prototype would still apply. */ |
| 5098 | char $ac_func(); |
| 5099 | |
| 5100 | int main() { |
| 5101 | |
| 5102 | /* The GNU C library defines this for functions which it implements |
| 5103 | to always fail with ENOSYS. Some functions are actually named |
| 5104 | something starting with __ and the normal name is an alias. */ |
| 5105 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 5106 | choke me |
| 5107 | #else |
| 5108 | $ac_func(); |
| 5109 | #endif |
| 5110 | |
| 5111 | ; return 0; } |
| 5112 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5113 | if { (eval echo configure:5114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5114 | rm -rf conftest* |
| 5115 | eval "ac_cv_func_$ac_func=yes" |
| 5116 | else |
| 5117 | echo "configure: failed program was:" >&5 |
| 5118 | cat conftest.$ac_ext >&5 |
| 5119 | rm -rf conftest* |
| 5120 | eval "ac_cv_func_$ac_func=no" |
| 5121 | fi |
| 5122 | rm -f conftest* |
| 5123 | fi |
| 5124 | |
| 5125 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 5126 | echo "$ac_t""yes" 1>&6 |
| 5127 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5128 | cat >> confdefs.h <<EOF |
| 5129 | #define $ac_tr_func 1 |
| 5130 | EOF |
| 5131 | echo $ac_n "checking getaddrinfo bug""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5132 | echo "configure:5133: checking getaddrinfo bug" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5133 | if test "$cross_compiling" = yes; then |
| 5134 | echo "$ac_t""buggy" 1>&6 |
| 5135 | buggygetaddrinfo=yes |
| 5136 | else |
| 5137 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5138 | #line 5139 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5139 | #include "confdefs.h" |
| 5140 | |
| 5141 | #include <sys/types.h> |
| 5142 | #include <netdb.h> |
| 5143 | #include <string.h> |
| 5144 | #include <sys/socket.h> |
| 5145 | #include <netinet/in.h> |
| 5146 | |
| 5147 | main() |
| 5148 | { |
| 5149 | int passive, gaierr, inet4 = 0, inet6 = 0; |
| 5150 | struct addrinfo hints, *ai, *aitop; |
| 5151 | char straddr[INET6_ADDRSTRLEN], strport[16]; |
| 5152 | |
| 5153 | for (passive = 0; passive <= 1; passive++) { |
| 5154 | memset(&hints, 0, sizeof(hints)); |
| 5155 | hints.ai_family = AF_UNSPEC; |
| 5156 | hints.ai_flags = passive ? AI_PASSIVE : 0; |
| 5157 | hints.ai_socktype = SOCK_STREAM; |
| 5158 | if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) { |
| 5159 | (void)gai_strerror(gaierr); |
| 5160 | goto bad; |
| 5161 | } |
| 5162 | for (ai = aitop; ai; ai = ai->ai_next) { |
| 5163 | if (ai->ai_addr == NULL || |
| 5164 | ai->ai_addrlen == 0 || |
| 5165 | getnameinfo(ai->ai_addr, ai->ai_addrlen, |
| 5166 | straddr, sizeof(straddr), strport, sizeof(strport), |
| 5167 | NI_NUMERICHOST|NI_NUMERICSERV) != 0) { |
| 5168 | goto bad; |
| 5169 | } |
| 5170 | switch (ai->ai_family) { |
| 5171 | case AF_INET: |
| 5172 | if (strcmp(strport, "54321") != 0) { |
| 5173 | goto bad; |
| 5174 | } |
| 5175 | if (passive) { |
| 5176 | if (strcmp(straddr, "0.0.0.0") != 0) { |
| 5177 | goto bad; |
| 5178 | } |
| 5179 | } else { |
| 5180 | if (strcmp(straddr, "127.0.0.1") != 0) { |
| 5181 | goto bad; |
| 5182 | } |
| 5183 | } |
| 5184 | inet4++; |
| 5185 | break; |
| 5186 | case AF_INET6: |
| 5187 | if (strcmp(strport, "54321") != 0) { |
| 5188 | goto bad; |
| 5189 | } |
| 5190 | if (passive) { |
| 5191 | if (strcmp(straddr, "::") != 0) { |
| 5192 | goto bad; |
| 5193 | } |
| 5194 | } else { |
| 5195 | if (strcmp(straddr, "::1") != 0) { |
| 5196 | goto bad; |
| 5197 | } |
| 5198 | } |
| 5199 | inet6++; |
| 5200 | break; |
| 5201 | case AF_UNSPEC: |
| 5202 | goto bad; |
| 5203 | break; |
| 5204 | default: |
| 5205 | /* another family support? */ |
| 5206 | break; |
| 5207 | } |
| 5208 | } |
| 5209 | } |
| 5210 | |
| 5211 | if (!(inet4 == 0 || inet4 == 2)) |
| 5212 | goto bad; |
| 5213 | if (!(inet6 == 0 || inet6 == 2)) |
| 5214 | goto bad; |
| 5215 | |
| 5216 | if (aitop) |
| 5217 | freeaddrinfo(aitop); |
| 5218 | exit(0); |
| 5219 | |
| 5220 | bad: |
| 5221 | if (aitop) |
| 5222 | freeaddrinfo(aitop); |
| 5223 | exit(1); |
| 5224 | } |
| 5225 | |
| 5226 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5227 | if { (eval echo configure:5228: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5228 | then |
| 5229 | echo "$ac_t""good" 1>&6 |
| 5230 | buggygetaddrinfo=no |
| 5231 | else |
| 5232 | echo "configure: failed program was:" >&5 |
| 5233 | cat conftest.$ac_ext >&5 |
| 5234 | rm -fr conftest* |
| 5235 | echo "$ac_t""buggy" 1>&6 |
| 5236 | buggygetaddrinfo=yes |
| 5237 | fi |
| 5238 | rm -fr conftest* |
| 5239 | fi |
| 5240 | |
| 5241 | else |
| 5242 | echo "$ac_t""no" 1>&6 |
| 5243 | buggygetaddrinfo=yes |
| 5244 | fi |
| 5245 | done |
| 5246 | |
| 5247 | |
| 5248 | if test "$buggygetaddrinfo" = "yes"; then |
| 5249 | if test "$ipv6" = "yes"; then |
| 5250 | echo 'Fatal: You must get working getaddrinfo() function.' |
| 5251 | echo ' or you can specify "--disable-ipv6"'. |
| 5252 | exit 1 |
| 5253 | fi |
| 5254 | fi |
| 5255 | for ac_func in getaddrinfo getnameinfo |
| 5256 | do |
| 5257 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5258 | echo "configure:5259: checking for $ac_func" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5259 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
| 5260 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5261 | else |
| 5262 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5263 | #line 5264 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5264 | #include "confdefs.h" |
| 5265 | /* System header to define __stub macros and hopefully few prototypes, |
| 5266 | which can conflict with char $ac_func(); below. */ |
| 5267 | #include <assert.h> |
| 5268 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5269 | /* We use char because int might match the return type of a gcc2 |
| 5270 | builtin and then its argument prototype would still apply. */ |
| 5271 | char $ac_func(); |
| 5272 | |
| 5273 | int main() { |
| 5274 | |
| 5275 | /* The GNU C library defines this for functions which it implements |
| 5276 | to always fail with ENOSYS. Some functions are actually named |
| 5277 | something starting with __ and the normal name is an alias. */ |
| 5278 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 5279 | choke me |
| 5280 | #else |
| 5281 | $ac_func(); |
| 5282 | #endif |
| 5283 | |
| 5284 | ; return 0; } |
| 5285 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5286 | if { (eval echo configure:5287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5287 | rm -rf conftest* |
| 5288 | eval "ac_cv_func_$ac_func=yes" |
| 5289 | else |
| 5290 | echo "configure: failed program was:" >&5 |
| 5291 | cat conftest.$ac_ext >&5 |
| 5292 | rm -rf conftest* |
| 5293 | eval "ac_cv_func_$ac_func=no" |
| 5294 | fi |
| 5295 | rm -f conftest* |
| 5296 | fi |
| 5297 | |
| 5298 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 5299 | echo "$ac_t""yes" 1>&6 |
| 5300 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 5301 | cat >> confdefs.h <<EOF |
| 5302 | #define $ac_tr_func 1 |
| 5303 | EOF |
| 5304 | |
| 5305 | else |
| 5306 | echo "$ac_t""no" 1>&6 |
| 5307 | fi |
| 5308 | done |
| 5309 | |
| 5310 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5311 | # checks for structures |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5312 | echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5313 | echo "configure:5314: checking whether time.h and sys/time.h may both be included" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5314 | if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5315 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5316 | else |
| 5317 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5318 | #line 5319 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5319 | #include "confdefs.h" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5320 | #include <sys/types.h> |
| 5321 | #include <sys/time.h> |
| 5322 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5323 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5324 | struct tm *tp; |
| 5325 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5326 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5327 | if { (eval echo configure:5328: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5328 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5329 | ac_cv_header_time=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5330 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5331 | echo "configure: failed program was:" >&5 |
| 5332 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5333 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5334 | ac_cv_header_time=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5335 | fi |
| 5336 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5337 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5338 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5339 | echo "$ac_t""$ac_cv_header_time" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5340 | if test $ac_cv_header_time = yes; then |
| 5341 | cat >> confdefs.h <<\EOF |
| 5342 | #define TIME_WITH_SYS_TIME 1 |
| 5343 | EOF |
| 5344 | |
| 5345 | fi |
| 5346 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5347 | echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5348 | echo "configure:5349: checking whether struct tm is in sys/time.h or time.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5349 | if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5350 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5351 | else |
| 5352 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5353 | #line 5354 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5354 | #include "confdefs.h" |
| 5355 | #include <sys/types.h> |
| 5356 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5357 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5358 | struct tm *tp; tp->tm_sec; |
| 5359 | ; return 0; } |
| 5360 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5361 | if { (eval echo configure:5362: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5362 | rm -rf conftest* |
| 5363 | ac_cv_struct_tm=time.h |
| 5364 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5365 | echo "configure: failed program was:" >&5 |
| 5366 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5367 | rm -rf conftest* |
| 5368 | ac_cv_struct_tm=sys/time.h |
| 5369 | fi |
| 5370 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5371 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5372 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5373 | echo "$ac_t""$ac_cv_struct_tm" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5374 | if test $ac_cv_struct_tm = sys/time.h; then |
| 5375 | cat >> confdefs.h <<\EOF |
| 5376 | #define TM_IN_SYS_TIME 1 |
| 5377 | EOF |
| 5378 | |
| 5379 | fi |
| 5380 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5381 | echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5382 | echo "configure:5383: checking for tm_zone in struct tm" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5383 | if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5384 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5385 | else |
| 5386 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5387 | #line 5388 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5388 | #include "confdefs.h" |
| 5389 | #include <sys/types.h> |
| 5390 | #include <$ac_cv_struct_tm> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5391 | int main() { |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5392 | struct tm tm; tm.tm_zone; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5393 | ; return 0; } |
| 5394 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5395 | if { (eval echo configure:5396: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5396 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5397 | ac_cv_struct_tm_zone=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5398 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5399 | echo "configure: failed program was:" >&5 |
| 5400 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5401 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5402 | ac_cv_struct_tm_zone=no |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5403 | fi |
| 5404 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5405 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5406 | |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5407 | echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6 |
| 5408 | if test "$ac_cv_struct_tm_zone" = yes; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5409 | cat >> confdefs.h <<\EOF |
| 5410 | #define HAVE_TM_ZONE 1 |
| 5411 | EOF |
| 5412 | |
| 5413 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5414 | echo $ac_n "checking for tzname""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5415 | echo "configure:5416: checking for tzname" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5416 | if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5417 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5418 | else |
| 5419 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5420 | #line 5421 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5421 | #include "confdefs.h" |
| 5422 | #include <time.h> |
| 5423 | #ifndef tzname /* For SGI. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5424 | extern char *tzname[]; /* RS6000 and others reject char **tzname. */ |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5425 | #endif |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5426 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5427 | atoi(*tzname); |
| 5428 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5429 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5430 | if { (eval echo configure:5431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5431 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5432 | ac_cv_var_tzname=yes |
| 5433 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5434 | echo "configure: failed program was:" >&5 |
| 5435 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5436 | rm -rf conftest* |
| 5437 | ac_cv_var_tzname=no |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5438 | fi |
| 5439 | rm -f conftest* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5440 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5441 | |
| 5442 | echo "$ac_t""$ac_cv_var_tzname" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5443 | if test $ac_cv_var_tzname = yes; then |
| 5444 | cat >> confdefs.h <<\EOF |
| 5445 | #define HAVE_TZNAME 1 |
| 5446 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5447 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5448 | fi |
| 5449 | fi |
| 5450 | |
| 5451 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5452 | echo $ac_n "checking for time.h that defines altzone""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5453 | echo "configure:5454: checking for time.h that defines altzone" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5454 | if eval "test \"`echo '$''{'ac_cv_header_time_altzone'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5455 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5456 | else |
| 5457 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5458 | #line 5459 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5459 | #include "confdefs.h" |
| 5460 | #include <time.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5461 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5462 | return altzone; |
| 5463 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5464 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5465 | if { (eval echo configure:5466: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5466 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5467 | ac_cv_header_time_altzone=yes |
| 5468 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5469 | echo "configure: failed program was:" >&5 |
| 5470 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5471 | rm -rf conftest* |
| 5472 | ac_cv_header_time_altzone=no |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5473 | fi |
| 5474 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5475 | fi |
| 5476 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5477 | echo "$ac_t""$ac_cv_header_time_altzone" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5478 | if test $ac_cv_header_time_altzone = yes; then |
| 5479 | cat >> confdefs.h <<\EOF |
| 5480 | #define HAVE_ALTZONE 1 |
| 5481 | EOF |
| 5482 | |
| 5483 | fi |
| 5484 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5485 | was_it_defined=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5486 | echo $ac_n "checking whether sys/select.h and sys/time.h may both be included""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5487 | echo "configure:5488: checking whether sys/select.h and sys/time.h may both be included" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5488 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5489 | #line 5490 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5490 | #include "confdefs.h" |
| 5491 | |
| 5492 | #include <sys/types.h> |
| 5493 | #include <sys/select.h> |
| 5494 | #include <sys/time.h> |
| 5495 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5496 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5497 | ; |
| 5498 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5499 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5500 | if { (eval echo configure:5501: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5501 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5502 | cat >> confdefs.h <<\EOF |
| 5503 | #define SYS_SELECT_WITH_SYS_TIME 1 |
| 5504 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5505 | was_it_defined=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5506 | else |
| 5507 | echo "configure: failed program was:" >&5 |
| 5508 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5509 | fi |
| 5510 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5511 | echo "$ac_t""$was_it_defined" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5512 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5513 | echo $ac_n "checking for addrinfo""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5514 | echo "configure:5515: checking for addrinfo" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5515 | if eval "test \"`echo '$''{'ac_cv_struct_addrinfo'+set}'`\" = set"; then |
| 5516 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5517 | else |
| 5518 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5519 | #line 5520 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5520 | #include "confdefs.h" |
| 5521 | |
| 5522 | # include <netdb.h> |
| 5523 | int main() { |
| 5524 | struct addrinfo a |
| 5525 | ; return 0; } |
| 5526 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5527 | if { (eval echo configure:5528: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5528 | rm -rf conftest* |
| 5529 | ac_cv_struct_addrinfo=yes |
| 5530 | else |
| 5531 | echo "configure: failed program was:" >&5 |
| 5532 | cat conftest.$ac_ext >&5 |
| 5533 | rm -rf conftest* |
| 5534 | ac_cv_struct_addrinfo=no |
| 5535 | fi |
| 5536 | rm -f conftest* |
| 5537 | fi |
| 5538 | |
| 5539 | echo "$ac_t""$ac_cv_struct_addrinfo" 1>&6 |
| 5540 | if test $ac_cv_struct_addrinfo = yes; then |
| 5541 | cat >> confdefs.h <<\EOF |
| 5542 | #define HAVE_ADDRINFO 1 |
| 5543 | EOF |
| 5544 | |
| 5545 | fi |
| 5546 | |
| 5547 | echo $ac_n "checking for sockaddr_storage""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5548 | echo "configure:5549: checking for sockaddr_storage" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5549 | if eval "test \"`echo '$''{'ac_cv_struct_sockaddr_storage'+set}'`\" = set"; then |
| 5550 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5551 | else |
| 5552 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5553 | #line 5554 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5554 | #include "confdefs.h" |
| 5555 | |
| 5556 | # include <sys/types.h> |
| 5557 | # include <sys/socket.h> |
| 5558 | int main() { |
| 5559 | struct sockaddr_storage s |
| 5560 | ; return 0; } |
| 5561 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5562 | if { (eval echo configure:5563: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5563 | rm -rf conftest* |
| 5564 | ac_cv_struct_sockaddr_storage=yes |
| 5565 | else |
| 5566 | echo "configure: failed program was:" >&5 |
| 5567 | cat conftest.$ac_ext >&5 |
| 5568 | rm -rf conftest* |
| 5569 | ac_cv_struct_sockaddr_storage=no |
| 5570 | fi |
| 5571 | rm -f conftest* |
| 5572 | fi |
| 5573 | |
| 5574 | echo "$ac_t""$ac_cv_struct_sockaddr_storage" 1>&6 |
| 5575 | if test $ac_cv_struct_sockaddr_storage = yes; then |
| 5576 | cat >> confdefs.h <<\EOF |
| 5577 | #define HAVE_SOCKADDR_STORAGE 1 |
| 5578 | EOF |
| 5579 | |
| 5580 | fi |
| 5581 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5582 | # checks for compiler characteristics |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5583 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5584 | echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5585 | echo "configure:5586: checking whether char is unsigned" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5586 | if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5587 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5588 | else |
| 5589 | if test "$GCC" = yes; then |
| 5590 | # GCC predefines this symbol on systems where it applies. |
| 5591 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5592 | #line 5593 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5593 | #include "confdefs.h" |
| 5594 | #ifdef __CHAR_UNSIGNED__ |
| 5595 | yes |
| 5596 | #endif |
| 5597 | |
| 5598 | EOF |
| 5599 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 5600 | egrep "yes" >/dev/null 2>&1; then |
| 5601 | rm -rf conftest* |
| 5602 | ac_cv_c_char_unsigned=yes |
| 5603 | else |
| 5604 | rm -rf conftest* |
| 5605 | ac_cv_c_char_unsigned=no |
| 5606 | fi |
| 5607 | rm -f conftest* |
| 5608 | |
| 5609 | else |
| 5610 | if test "$cross_compiling" = yes; then |
| 5611 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5612 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5613 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5614 | #line 5615 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5615 | #include "confdefs.h" |
| 5616 | /* volatile prevents gcc2 from optimizing the test away on sparcs. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5617 | #if !defined(__STDC__) || __STDC__ != 1 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5618 | #define volatile |
| 5619 | #endif |
| 5620 | main() { |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5621 | volatile char c = 255; exit(c < 0); |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5622 | } |
| 5623 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5624 | if { (eval echo configure:5625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5625 | then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5626 | ac_cv_c_char_unsigned=yes |
| 5627 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5628 | echo "configure: failed program was:" >&5 |
| 5629 | cat conftest.$ac_ext >&5 |
| 5630 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5631 | ac_cv_c_char_unsigned=no |
| 5632 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5633 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5634 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5635 | |
| 5636 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5637 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5638 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5639 | echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5640 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
| 5641 | cat >> confdefs.h <<\EOF |
| 5642 | #define __CHAR_UNSIGNED__ 1 |
| 5643 | EOF |
| 5644 | |
| 5645 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5646 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5647 | echo $ac_n "checking for working const""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5648 | echo "configure:5649: checking for working const" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5649 | if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5650 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5651 | else |
| 5652 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5653 | #line 5654 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5654 | #include "confdefs.h" |
| 5655 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5656 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5657 | |
| 5658 | /* Ultrix mips cc rejects this. */ |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5659 | typedef int charset[2]; const charset x; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5660 | /* SunOS 4.1.1 cc rejects this. */ |
| 5661 | char const *const *ccp; |
| 5662 | char **p; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5663 | /* NEC SVR4.0.2 mips cc rejects this. */ |
| 5664 | struct point {int x, y;}; |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5665 | static struct point const zero = {0,0}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5666 | /* AIX XL C 1.02.0.0 rejects this. |
| 5667 | It does not let you subtract one const X* pointer from another in an arm |
| 5668 | of an if-expression whose if-part is not a constant expression */ |
| 5669 | const char *g = "string"; |
| 5670 | ccp = &g + (g ? g-g : 0); |
| 5671 | /* HPUX 7.0 cc rejects these. */ |
| 5672 | ++ccp; |
| 5673 | p = (char**) ccp; |
| 5674 | ccp = (char const *const *) p; |
| 5675 | { /* SCO 3.2v4 cc rejects this. */ |
| 5676 | char *t; |
| 5677 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
| 5678 | |
| 5679 | *t++ = 0; |
| 5680 | } |
| 5681 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5682 | int x[] = {25, 17}; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5683 | const int *foo = &x[0]; |
| 5684 | ++foo; |
| 5685 | } |
| 5686 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ |
| 5687 | typedef const int *iptr; |
| 5688 | iptr p = 0; |
| 5689 | ++p; |
| 5690 | } |
| 5691 | { /* AIX XL C 1.02.0.0 rejects this saying |
| 5692 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
| 5693 | struct s { int j; const int *ap[3]; }; |
| 5694 | struct s *b; b->j = 5; |
| 5695 | } |
| 5696 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ |
| 5697 | const int foo = 10; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5698 | } |
| 5699 | |
| 5700 | ; return 0; } |
| 5701 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5702 | if { (eval echo configure:5703: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5703 | rm -rf conftest* |
| 5704 | ac_cv_c_const=yes |
| 5705 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5706 | echo "configure: failed program was:" >&5 |
| 5707 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5708 | rm -rf conftest* |
| 5709 | ac_cv_c_const=no |
| 5710 | fi |
| 5711 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5712 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 5713 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5714 | echo "$ac_t""$ac_cv_c_const" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5715 | if test $ac_cv_c_const = no; then |
| 5716 | cat >> confdefs.h <<\EOF |
| 5717 | #define const |
| 5718 | EOF |
| 5719 | |
| 5720 | fi |
| 5721 | |
| 5722 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5723 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5724 | echo $ac_n "checking for working volatile""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5725 | echo "configure:5726: checking for working volatile" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5726 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5727 | #line 5728 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5728 | #include "confdefs.h" |
| 5729 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5730 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5731 | volatile int x; x = 0; |
| 5732 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5733 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5734 | if { (eval echo configure:5735: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5735 | rm -rf conftest* |
| 5736 | works=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5737 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5738 | echo "configure: failed program was:" >&5 |
| 5739 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5740 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5741 | cat >> confdefs.h <<\EOF |
| 5742 | #define volatile |
| 5743 | EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5744 | |
| 5745 | fi |
| 5746 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5747 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5748 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5749 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5750 | echo $ac_n "checking for working signed char""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5751 | echo "configure:5752: checking for working signed char" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5752 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5753 | #line 5754 "configure" |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5754 | #include "confdefs.h" |
| 5755 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5756 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5757 | signed char c; |
| 5758 | ; return 0; } |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5759 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5760 | if { (eval echo configure:5761: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5761 | rm -rf conftest* |
| 5762 | works=yes |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5763 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5764 | echo "configure: failed program was:" >&5 |
| 5765 | cat conftest.$ac_ext >&5 |
Guido van Rossum | dabb11b | 1994-10-11 15:04:27 +0000 | [diff] [blame] | 5766 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5767 | cat >> confdefs.h <<\EOF |
| 5768 | #define signed |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5769 | EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5770 | |
| 5771 | fi |
| 5772 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5773 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5774 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5775 | have_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5776 | echo $ac_n "checking for prototypes""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5777 | echo "configure:5778: checking for prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5778 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5779 | #line 5780 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5780 | #include "confdefs.h" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5781 | int foo(int x) { return 0; } |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5782 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5783 | return foo(10); |
| 5784 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5785 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5786 | if { (eval echo configure:5787: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5787 | rm -rf conftest* |
| 5788 | cat >> confdefs.h <<\EOF |
| 5789 | #define HAVE_PROTOTYPES 1 |
| 5790 | EOF |
| 5791 | have_prototypes=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5792 | else |
| 5793 | echo "configure: failed program was:" >&5 |
| 5794 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5795 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5796 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5797 | echo "$ac_t""$have_prototypes" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5798 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5799 | works=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5800 | echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5801 | echo "configure:5802: checking for variable length prototypes and stdarg.h" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5802 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5803 | #line 5804 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5804 | #include "confdefs.h" |
| 5805 | |
| 5806 | #include <stdarg.h> |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 5807 | int foo(int x, ...) { |
| 5808 | va_list va; |
| 5809 | va_start(va, x); |
| 5810 | va_arg(va, int); |
| 5811 | va_arg(va, char *); |
| 5812 | va_arg(va, double); |
| 5813 | return 0; |
| 5814 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5815 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5816 | int main() { |
Guido van Rossum | 90eea07 | 1996-08-30 20:58:57 +0000 | [diff] [blame] | 5817 | return foo(10, "", 3.14); |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5818 | ; return 0; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5819 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5820 | if { (eval echo configure:5821: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5821 | rm -rf conftest* |
| 5822 | cat >> confdefs.h <<\EOF |
| 5823 | #define HAVE_STDARG_PROTOTYPES 1 |
| 5824 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5825 | works=yes |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5826 | else |
| 5827 | echo "configure: failed program was:" >&5 |
| 5828 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5829 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5830 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5831 | echo "$ac_t""$works" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5832 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5833 | if test "$have_prototypes" = yes; then |
| 5834 | bad_prototypes=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5835 | echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5836 | echo "configure:5837: checking for bad exec* prototypes" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5837 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5838 | #line 5839 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5839 | #include "confdefs.h" |
| 5840 | #include <unistd.h> |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5841 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5842 | char **t;execve("@",t,t); |
| 5843 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5844 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5845 | if { (eval echo configure:5846: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5846 | : |
| 5847 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5848 | echo "configure: failed program was:" >&5 |
| 5849 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5850 | rm -rf conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5851 | cat >> confdefs.h <<\EOF |
| 5852 | #define BAD_EXEC_PROTOTYPES 1 |
| 5853 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5854 | bad_prototypes=yes |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5855 | fi |
| 5856 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5857 | echo "$ac_t""$bad_prototypes" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 5858 | fi |
| 5859 | |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5860 | # check if sockaddr has sa_len member |
| 5861 | echo $ac_n "checking if sockaddr has sa_len member""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5862 | echo "configure:5863: checking if sockaddr has sa_len member" >&5 |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5863 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5864 | #line 5865 "configure" |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5865 | #include "confdefs.h" |
| 5866 | #include <sys/types.h> |
| 5867 | #include <sys/socket.h> |
| 5868 | int main() { |
| 5869 | struct sockaddr x; |
| 5870 | x.sa_len = 0; |
| 5871 | ; return 0; } |
| 5872 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5873 | if { (eval echo configure:5874: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Martin v. Löwis | 01dfdb3 | 2001-06-23 16:30:13 +0000 | [diff] [blame] | 5874 | rm -rf conftest* |
| 5875 | echo "$ac_t""yes" 1>&6 |
| 5876 | cat >> confdefs.h <<\EOF |
| 5877 | #define HAVE_SOCKADDR_SA_LEN 1 |
| 5878 | EOF |
| 5879 | |
| 5880 | else |
| 5881 | echo "configure: failed program was:" >&5 |
| 5882 | cat conftest.$ac_ext >&5 |
| 5883 | rm -rf conftest* |
| 5884 | echo "$ac_t""no" 1>&6 |
| 5885 | fi |
| 5886 | rm -f conftest* |
| 5887 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5888 | bad_forward=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5889 | echo $ac_n "checking for bad static forward""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5890 | echo "configure:5891: checking for bad static forward" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5891 | if test "$cross_compiling" = yes; then |
| 5892 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 5893 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5894 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5895 | #line 5896 "configure" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5896 | #include "confdefs.h" |
| 5897 | |
| 5898 | struct s { int a; int b; }; |
| 5899 | static struct s foo; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5900 | int foobar() { |
| 5901 | static int random; |
| 5902 | random = (int) &foo; |
| 5903 | return random; |
| 5904 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5905 | static struct s foo = { 1, 2 }; |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5906 | main() { |
| 5907 | exit(!((int)&foo == foobar())); |
| 5908 | } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5909 | |
| 5910 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5911 | if { (eval echo configure:5912: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5912 | then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5913 | : |
| 5914 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5915 | echo "configure: failed program was:" >&5 |
| 5916 | cat conftest.$ac_ext >&5 |
| 5917 | rm -fr conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5918 | cat >> confdefs.h <<\EOF |
| 5919 | #define BAD_STATIC_FORWARD 1 |
| 5920 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5921 | bad_forward=yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5922 | fi |
| 5923 | rm -fr conftest* |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5924 | fi |
| 5925 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5926 | echo "$ac_t""$bad_forward" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 5927 | |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5928 | va_list_is_array=no |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5929 | echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5930 | echo "configure:5931: checking whether va_list is an array" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5931 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5932 | #line 5933 "configure" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5933 | #include "confdefs.h" |
| 5934 | |
| 5935 | #ifdef HAVE_STDARG_PROTOTYPES |
| 5936 | #include <stdarg.h> |
| 5937 | #else |
| 5938 | #include <varargs.h> |
| 5939 | #endif |
| 5940 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5941 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5942 | va_list list1, list2; list1 = list2; |
| 5943 | ; return 0; } |
| 5944 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5945 | if { (eval echo configure:5946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5946 | : |
| 5947 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 5948 | echo "configure: failed program was:" >&5 |
| 5949 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5950 | rm -rf conftest* |
| 5951 | cat >> confdefs.h <<\EOF |
| 5952 | #define VA_LIST_IS_ARRAY 1 |
| 5953 | EOF |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 5954 | va_list_is_array=yes |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5955 | fi |
| 5956 | rm -f conftest* |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 5957 | echo "$ac_t""$va_list_is_array" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 5958 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5959 | # sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-( |
| 5960 | echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5961 | echo "configure:5962: checking for gethostbyname_r" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5962 | if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5963 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 5964 | else |
| 5965 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5966 | #line 5967 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5967 | #include "confdefs.h" |
| 5968 | /* System header to define __stub macros and hopefully few prototypes, |
| 5969 | which can conflict with char gethostbyname_r(); below. */ |
| 5970 | #include <assert.h> |
| 5971 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 5972 | /* We use char because int might match the return type of a gcc2 |
| 5973 | builtin and then its argument prototype would still apply. */ |
| 5974 | char gethostbyname_r(); |
| 5975 | |
| 5976 | int main() { |
| 5977 | |
| 5978 | /* The GNU C library defines this for functions which it implements |
| 5979 | to always fail with ENOSYS. Some functions are actually named |
| 5980 | something starting with __ and the normal name is an alias. */ |
| 5981 | #if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r) |
| 5982 | choke me |
| 5983 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 5984 | gethostbyname_r(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5985 | #endif |
| 5986 | |
| 5987 | ; return 0; } |
| 5988 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 5989 | if { (eval echo configure:5990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 5990 | rm -rf conftest* |
| 5991 | eval "ac_cv_func_gethostbyname_r=yes" |
| 5992 | else |
| 5993 | echo "configure: failed program was:" >&5 |
| 5994 | cat conftest.$ac_ext >&5 |
| 5995 | rm -rf conftest* |
| 5996 | eval "ac_cv_func_gethostbyname_r=no" |
| 5997 | fi |
| 5998 | rm -f conftest* |
| 5999 | fi |
| 6000 | |
| 6001 | if eval "test \"`echo '$ac_cv_func_'gethostbyname_r`\" = yes"; then |
| 6002 | echo "$ac_t""yes" 1>&6 |
| 6003 | |
| 6004 | cat >> confdefs.h <<\EOF |
| 6005 | #define HAVE_GETHOSTBYNAME_R 1 |
| 6006 | EOF |
| 6007 | |
| 6008 | echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6009 | echo "configure:6010: checking gethostbyname_r with 6 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6010 | OLD_CFLAGS=$CFLAGS |
| 6011 | CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS" |
| 6012 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6013 | #line 6014 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6014 | #include "confdefs.h" |
| 6015 | |
| 6016 | # include <netdb.h> |
| 6017 | |
| 6018 | int main() { |
| 6019 | |
| 6020 | char *name; |
| 6021 | struct hostent *he, *res; |
| 6022 | char buffer[2048]; |
| 6023 | int buflen = 2048; |
| 6024 | int h_errnop; |
| 6025 | |
| 6026 | (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop) |
| 6027 | |
| 6028 | ; return 0; } |
| 6029 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6030 | if { (eval echo configure:6031: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6031 | rm -rf conftest* |
| 6032 | |
| 6033 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 6034 | #define HAVE_GETHOSTBYNAME_R 1 |
| 6035 | EOF |
| 6036 | |
| 6037 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6038 | #define HAVE_GETHOSTBYNAME_R_6_ARG 1 |
| 6039 | EOF |
| 6040 | |
| 6041 | echo "$ac_t""yes" 1>&6 |
| 6042 | |
| 6043 | else |
| 6044 | echo "configure: failed program was:" >&5 |
| 6045 | cat conftest.$ac_ext >&5 |
| 6046 | rm -rf conftest* |
| 6047 | |
| 6048 | echo "$ac_t""no" 1>&6 |
| 6049 | echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6050 | echo "configure:6051: checking gethostbyname_r with 5 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6051 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6052 | #line 6053 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6053 | #include "confdefs.h" |
| 6054 | |
| 6055 | # include <netdb.h> |
| 6056 | |
| 6057 | int main() { |
| 6058 | |
| 6059 | char *name; |
| 6060 | struct hostent *he; |
| 6061 | char buffer[2048]; |
| 6062 | int buflen = 2048; |
| 6063 | int h_errnop; |
| 6064 | |
| 6065 | (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop) |
| 6066 | |
| 6067 | ; return 0; } |
| 6068 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6069 | if { (eval echo configure:6070: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6070 | rm -rf conftest* |
| 6071 | |
| 6072 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 6073 | #define HAVE_GETHOSTBYNAME_R 1 |
| 6074 | EOF |
| 6075 | |
| 6076 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6077 | #define HAVE_GETHOSTBYNAME_R_5_ARG 1 |
| 6078 | EOF |
| 6079 | |
| 6080 | echo "$ac_t""yes" 1>&6 |
| 6081 | |
| 6082 | else |
| 6083 | echo "configure: failed program was:" >&5 |
| 6084 | cat conftest.$ac_ext >&5 |
| 6085 | rm -rf conftest* |
| 6086 | |
| 6087 | echo "$ac_t""no" 1>&6 |
| 6088 | echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6089 | echo "configure:6090: checking gethostbyname_r with 3 args" >&5 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6090 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6091 | #line 6092 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6092 | #include "confdefs.h" |
| 6093 | |
| 6094 | # include <netdb.h> |
| 6095 | |
| 6096 | int main() { |
| 6097 | |
| 6098 | char *name; |
| 6099 | struct hostent *he; |
| 6100 | struct hostent_data data; |
| 6101 | |
| 6102 | (void) gethostbyname_r(name, he, &data); |
| 6103 | |
| 6104 | ; return 0; } |
| 6105 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6106 | if { (eval echo configure:6107: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6107 | rm -rf conftest* |
| 6108 | |
| 6109 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 6110 | #define HAVE_GETHOSTBYNAME_R 1 |
| 6111 | EOF |
| 6112 | |
| 6113 | cat >> confdefs.h <<\EOF |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6114 | #define HAVE_GETHOSTBYNAME_R_3_ARG 1 |
| 6115 | EOF |
| 6116 | |
| 6117 | echo "$ac_t""yes" 1>&6 |
| 6118 | |
| 6119 | else |
| 6120 | echo "configure: failed program was:" >&5 |
| 6121 | cat conftest.$ac_ext >&5 |
| 6122 | rm -rf conftest* |
| 6123 | |
| 6124 | echo "$ac_t""no" 1>&6 |
| 6125 | |
| 6126 | fi |
| 6127 | rm -f conftest* |
| 6128 | |
| 6129 | fi |
| 6130 | rm -f conftest* |
| 6131 | |
| 6132 | fi |
| 6133 | rm -f conftest* |
| 6134 | CFLAGS=$OLD_CFLAGS |
| 6135 | |
| 6136 | else |
| 6137 | echo "$ac_t""no" 1>&6 |
| 6138 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6139 | for ac_func in gethostbyname |
| 6140 | do |
| 6141 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6142 | echo "configure:6143: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6143 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6144 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6145 | else |
| 6146 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6147 | #line 6148 "configure" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6148 | #include "confdefs.h" |
| 6149 | /* System header to define __stub macros and hopefully few prototypes, |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6150 | which can conflict with char $ac_func(); below. */ |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6151 | #include <assert.h> |
| 6152 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 6153 | /* We use char because int might match the return type of a gcc2 |
| 6154 | builtin and then its argument prototype would still apply. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6155 | char $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6156 | |
| 6157 | int main() { |
| 6158 | |
| 6159 | /* The GNU C library defines this for functions which it implements |
| 6160 | to always fail with ENOSYS. Some functions are actually named |
| 6161 | something starting with __ and the normal name is an alias. */ |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6162 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6163 | choke me |
| 6164 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6165 | $ac_func(); |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6166 | #endif |
| 6167 | |
| 6168 | ; return 0; } |
| 6169 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6170 | if { (eval echo configure:6171: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6171 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6172 | eval "ac_cv_func_$ac_func=yes" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6173 | else |
| 6174 | echo "configure: failed program was:" >&5 |
| 6175 | cat conftest.$ac_ext >&5 |
| 6176 | rm -rf conftest* |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6177 | eval "ac_cv_func_$ac_func=no" |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6178 | fi |
| 6179 | rm -f conftest* |
| 6180 | fi |
| 6181 | |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6182 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6183 | echo "$ac_t""yes" 1>&6 |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6184 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 6185 | cat >> confdefs.h <<EOF |
| 6186 | #define $ac_tr_func 1 |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6187 | EOF |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6188 | |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6189 | else |
| 6190 | echo "$ac_t""no" 1>&6 |
| 6191 | fi |
Thomas Wouters | 3a58420 | 2000-08-05 23:28:51 +0000 | [diff] [blame] | 6192 | done |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 6193 | |
| 6194 | |
| 6195 | fi |
| 6196 | |
| 6197 | |
| 6198 | |
| 6199 | |
| 6200 | |
| 6201 | |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 6202 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6203 | # checks for system services |
| 6204 | # (none yet) |
| 6205 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6206 | # Linux requires this for correct f.p. operations |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6207 | echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6208 | echo "configure:6209: checking for __fpu_control" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6209 | if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6210 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6211 | else |
| 6212 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6213 | #line 6214 "configure" |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6214 | #include "confdefs.h" |
| 6215 | /* System header to define __stub macros and hopefully few prototypes, |
| 6216 | which can conflict with char __fpu_control(); below. */ |
| 6217 | #include <assert.h> |
| 6218 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 6219 | /* We use char because int might match the return type of a gcc2 |
| 6220 | builtin and then its argument prototype would still apply. */ |
| 6221 | char __fpu_control(); |
| 6222 | |
| 6223 | int main() { |
| 6224 | |
| 6225 | /* The GNU C library defines this for functions which it implements |
| 6226 | to always fail with ENOSYS. Some functions are actually named |
| 6227 | something starting with __ and the normal name is an alias. */ |
| 6228 | #if defined (__stub___fpu_control) || defined (__stub_____fpu_control) |
| 6229 | choke me |
| 6230 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6231 | __fpu_control(); |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6232 | #endif |
| 6233 | |
| 6234 | ; return 0; } |
| 6235 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6236 | if { (eval echo configure:6237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6237 | rm -rf conftest* |
| 6238 | eval "ac_cv_func___fpu_control=yes" |
| 6239 | else |
| 6240 | echo "configure: failed program was:" >&5 |
| 6241 | cat conftest.$ac_ext >&5 |
| 6242 | rm -rf conftest* |
| 6243 | eval "ac_cv_func___fpu_control=no" |
| 6244 | fi |
| 6245 | rm -f conftest* |
| 6246 | fi |
| 6247 | |
| 6248 | if eval "test \"`echo '$ac_cv_func_'__fpu_control`\" = yes"; then |
| 6249 | echo "$ac_t""yes" 1>&6 |
| 6250 | : |
| 6251 | else |
| 6252 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6253 | echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6254 | echo "configure:6255: checking for __fpu_control in -lieee" >&5 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6255 | ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'` |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6256 | if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6257 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6258 | else |
| 6259 | ac_save_LIBS="$LIBS" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6260 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6261 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6262 | #line 6263 "configure" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6263 | #include "confdefs.h" |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6264 | /* Override any gcc2 internal prototype to avoid an error. */ |
| 6265 | /* We use char because int might match the return type of a gcc2 |
| 6266 | builtin and then its argument prototype would still apply. */ |
| 6267 | char __fpu_control(); |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6268 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6269 | int main() { |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6270 | __fpu_control() |
| 6271 | ; return 0; } |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6272 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6273 | if { (eval echo configure:6274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6274 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6275 | eval "ac_cv_lib_$ac_lib_var=yes" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6276 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6277 | echo "configure: failed program was:" >&5 |
| 6278 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6279 | rm -rf conftest* |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6280 | eval "ac_cv_lib_$ac_lib_var=no" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6281 | fi |
| 6282 | rm -f conftest* |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6283 | LIBS="$ac_save_LIBS" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6284 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6285 | fi |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6286 | if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6287 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6288 | ac_tr_lib=HAVE_LIB`echo ieee | sed -e 's/[^a-zA-Z0-9_]/_/g' \ |
| 6289 | -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6290 | cat >> confdefs.h <<EOF |
| 6291 | #define $ac_tr_lib 1 |
| 6292 | EOF |
| 6293 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6294 | LIBS="-lieee $LIBS" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6295 | |
| 6296 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6297 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6298 | fi |
| 6299 | |
| 6300 | |
Jeremy Hylton | be28f5b | 2000-07-27 21:03:04 +0000 | [diff] [blame] | 6301 | fi |
| 6302 | |
| 6303 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6304 | # Check for --with-fpectl |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6305 | echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6306 | echo "configure:6307: checking for --with-fpectl" >&5 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6307 | # Check whether --with-fpectl or --without-fpectl was given. |
| 6308 | if test "${with_fpectl+set}" = set; then |
| 6309 | withval="$with_fpectl" |
| 6310 | |
| 6311 | if test "$withval" != no |
| 6312 | then cat >> confdefs.h <<\EOF |
| 6313 | #define WANT_SIGFPE_HANDLER 1 |
| 6314 | EOF |
| 6315 | echo "$ac_t""yes" 1>&6 |
| 6316 | else echo "$ac_t""no" 1>&6 |
| 6317 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6318 | else |
| 6319 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6320 | fi |
| 6321 | |
| 6322 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6323 | # check for --with-libm=... |
| 6324 | |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6325 | case $ac_sys_system in |
Guido van Rossum | 3dc0a51 | 2000-10-05 18:00:06 +0000 | [diff] [blame] | 6326 | Darwin) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6327 | next) ;; |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 6328 | BeOS) ;; |
Guido van Rossum | 563e708 | 1996-09-10 18:20:48 +0000 | [diff] [blame] | 6329 | *) LIBM=-lm |
| 6330 | esac |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6331 | echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6332 | echo "configure:6333: checking for --with-libm=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6333 | # Check whether --with-libm or --without-libm was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6334 | if test "${with_libm+set}" = set; then |
| 6335 | withval="$with_libm" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6336 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6337 | if test "$withval" = no |
| 6338 | then LIBM= |
| 6339 | echo "$ac_t""force LIBM empty" 1>&6 |
| 6340 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6341 | then LIBM=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6342 | echo "$ac_t""set LIBM=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6343 | else { echo "configure: error: proper usage is --with-libm=STRING" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6344 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6345 | else |
| 6346 | echo "$ac_t""default LIBM=\"$LIBM\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6347 | fi |
| 6348 | |
| 6349 | |
| 6350 | # check for --with-libc=... |
| 6351 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6352 | echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6353 | echo "configure:6354: checking for --with-libc=STRING" >&5 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6354 | # Check whether --with-libc or --without-libc was given. |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6355 | if test "${with_libc+set}" = set; then |
| 6356 | withval="$with_libc" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6357 | |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6358 | if test "$withval" = no |
| 6359 | then LIBC= |
| 6360 | echo "$ac_t""force LIBC empty" 1>&6 |
| 6361 | elif test "$withval" != yes |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6362 | then LIBC=$withval |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6363 | echo "$ac_t""set LIBC=\"$withval\"" 1>&6 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6364 | else { echo "configure: error: proper usage is --with-libc=STRING" 1>&2; exit 1; } |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6365 | fi |
Guido van Rossum | 7f25391 | 1997-05-09 02:42:48 +0000 | [diff] [blame] | 6366 | else |
| 6367 | echo "$ac_t""default LIBC=\"$LIBC\"" 1>&6 |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6368 | fi |
| 6369 | |
| 6370 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6371 | # check for hypot() in math library |
| 6372 | LIBS_SAVE=$LIBS |
| 6373 | LIBS="$LIBS $LIBM" |
| 6374 | for ac_func in hypot |
| 6375 | do |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6376 | echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6377 | echo "configure:6378: checking for $ac_func" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6378 | if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6379 | echo $ac_n "(cached) $ac_c" 1>&6 |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6380 | else |
| 6381 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6382 | #line 6383 "configure" |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6383 | #include "confdefs.h" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6384 | /* System header to define __stub macros and hopefully few prototypes, |
| 6385 | which can conflict with char $ac_func(); below. */ |
| 6386 | #include <assert.h> |
| 6387 | /* Override any gcc2 internal prototype to avoid an error. */ |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6388 | /* We use char because int might match the return type of a gcc2 |
| 6389 | builtin and then its argument prototype would still apply. */ |
| 6390 | char $ac_func(); |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6391 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6392 | int main() { |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6393 | |
| 6394 | /* The GNU C library defines this for functions which it implements |
| 6395 | to always fail with ENOSYS. Some functions are actually named |
| 6396 | something starting with __ and the normal name is an alias. */ |
| 6397 | #if defined (__stub_$ac_func) || defined (__stub___$ac_func) |
| 6398 | choke me |
| 6399 | #else |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6400 | $ac_func(); |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6401 | #endif |
| 6402 | |
| 6403 | ; return 0; } |
| 6404 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6405 | if { (eval echo configure:6406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6406 | rm -rf conftest* |
| 6407 | eval "ac_cv_func_$ac_func=yes" |
| 6408 | else |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6409 | echo "configure: failed program was:" >&5 |
| 6410 | cat conftest.$ac_ext >&5 |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6411 | rm -rf conftest* |
| 6412 | eval "ac_cv_func_$ac_func=no" |
| 6413 | fi |
| 6414 | rm -f conftest* |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6415 | fi |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6416 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6417 | if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then |
| 6418 | echo "$ac_t""yes" 1>&6 |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6419 | ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` |
| 6420 | cat >> confdefs.h <<EOF |
| 6421 | #define $ac_tr_func 1 |
| 6422 | EOF |
| 6423 | |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6424 | else |
| 6425 | echo "$ac_t""no" 1>&6 |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6426 | LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6427 | fi |
Guido van Rossum | 2b3ac69 | 1996-08-30 15:18:41 +0000 | [diff] [blame] | 6428 | done |
| 6429 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6430 | |
Guido van Rossum | af5b83e | 1995-01-04 19:02:35 +0000 | [diff] [blame] | 6431 | LIBS=$LIBS_SAVE |
| 6432 | |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6433 | # check whether malloc(0) returns NULL or not |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6434 | echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6435 | echo "configure:6436: checking what malloc(0) returns" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6436 | if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6437 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6438 | else |
| 6439 | if test "$cross_compiling" = yes; then |
| 6440 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6441 | else |
| 6442 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6443 | #line 6444 "configure" |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6444 | #include "confdefs.h" |
| 6445 | #include <stdio.h> |
| 6446 | #ifdef HAVE_STDLIB |
| 6447 | #include <stdlib.h> |
| 6448 | #else |
| 6449 | char *malloc(), *realloc(); |
| 6450 | int *free(); |
| 6451 | #endif |
| 6452 | main() { |
| 6453 | char *p; |
| 6454 | p = malloc(0); |
| 6455 | if (p == NULL) exit(1); |
| 6456 | p = realloc(p, 0); |
| 6457 | if (p == NULL) exit(1); |
| 6458 | free(p); |
| 6459 | exit(0); |
| 6460 | } |
| 6461 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6462 | if { (eval echo configure:6463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ad71370 | 1997-07-10 22:42:38 +0000 | [diff] [blame] | 6463 | then |
| 6464 | ac_cv_malloc_zero=nonnull |
| 6465 | else |
| 6466 | echo "configure: failed program was:" >&5 |
| 6467 | cat conftest.$ac_ext >&5 |
| 6468 | rm -fr conftest* |
| 6469 | ac_cv_malloc_zero=null |
| 6470 | fi |
| 6471 | rm -fr conftest* |
| 6472 | fi |
| 6473 | |
| 6474 | fi |
| 6475 | |
| 6476 | echo "$ac_t""$ac_cv_malloc_zero" 1>&6 |
| 6477 | if test "$ac_cv_malloc_zero" = null |
| 6478 | then |
| 6479 | cat >> confdefs.h <<\EOF |
| 6480 | #define MALLOC_ZERO_RETURNS_NULL 1 |
| 6481 | EOF |
| 6482 | |
| 6483 | fi |
| 6484 | |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6485 | # check for wchar.h |
| 6486 | ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'` |
| 6487 | echo $ac_n "checking for wchar.h""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6488 | echo "configure:6489: checking for wchar.h" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6489 | if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6490 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6491 | else |
| 6492 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6493 | #line 6494 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6494 | #include "confdefs.h" |
| 6495 | #include <wchar.h> |
| 6496 | EOF |
| 6497 | ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6498 | { (eval echo configure:6499: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6499 | ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` |
| 6500 | if test -z "$ac_err"; then |
| 6501 | rm -rf conftest* |
| 6502 | eval "ac_cv_header_$ac_safe=yes" |
| 6503 | else |
| 6504 | echo "$ac_err" >&5 |
| 6505 | echo "configure: failed program was:" >&5 |
| 6506 | cat conftest.$ac_ext >&5 |
| 6507 | rm -rf conftest* |
| 6508 | eval "ac_cv_header_$ac_safe=no" |
| 6509 | fi |
| 6510 | rm -f conftest* |
| 6511 | fi |
| 6512 | if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then |
| 6513 | echo "$ac_t""yes" 1>&6 |
| 6514 | cat >> confdefs.h <<\EOF |
| 6515 | #define HAVE_WCHAR_H 1 |
| 6516 | EOF |
| 6517 | wchar_h="yes" |
| 6518 | else |
| 6519 | echo "$ac_t""no" 1>&6 |
| 6520 | wchar_h="no" |
| 6521 | |
| 6522 | fi |
| 6523 | |
| 6524 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6525 | # determine wchar_t size |
| 6526 | if test "$wchar_h" = yes |
| 6527 | then |
| 6528 | echo $ac_n "checking size of wchar_t""... $ac_c" 1>&6 |
| 6529 | echo "configure:6530: checking size of wchar_t" >&5 |
| 6530 | if eval "test \"`echo '$''{'ac_cv_sizeof_wchar_t'+set}'`\" = set"; then |
| 6531 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6532 | else |
| 6533 | if test "$cross_compiling" = yes; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6534 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6535 | else |
| 6536 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6537 | #line 6538 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6538 | #include "confdefs.h" |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6539 | #include <stdio.h> |
| 6540 | main() |
| 6541 | { |
| 6542 | FILE *f=fopen("conftestval", "w"); |
| 6543 | if (!f) exit(1); |
| 6544 | fprintf(f, "%d\n", sizeof(wchar_t)); |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6545 | exit(0); |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6546 | } |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6547 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6548 | if { (eval echo configure:6549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6549 | then |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6550 | ac_cv_sizeof_wchar_t=`cat conftestval` |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6551 | else |
| 6552 | echo "configure: failed program was:" >&5 |
| 6553 | cat conftest.$ac_ext >&5 |
| 6554 | rm -fr conftest* |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6555 | ac_cv_sizeof_wchar_t=0 |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6556 | fi |
| 6557 | rm -fr conftest* |
| 6558 | fi |
| 6559 | |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6560 | fi |
| 6561 | echo "$ac_t""$ac_cv_sizeof_wchar_t" 1>&6 |
| 6562 | cat >> confdefs.h <<EOF |
| 6563 | #define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t |
| 6564 | EOF |
| 6565 | |
| 6566 | |
| 6567 | fi |
| 6568 | |
| 6569 | echo $ac_n "checking what type to use for unicode""... $ac_c" 1>&6 |
| 6570 | echo "configure:6571: checking what type to use for unicode" >&5 |
| 6571 | # Check whether --enable-unicode or --disable-unicode was given. |
| 6572 | if test "${enable_unicode+set}" = set; then |
| 6573 | enableval="$enable_unicode" |
| 6574 | : |
| 6575 | else |
| 6576 | enable_unicode=yes |
| 6577 | fi |
| 6578 | |
| 6579 | |
| 6580 | if test $enable_unicode = yes |
| 6581 | then |
| 6582 | # Let Py_UNICODE size depend on wchar_t size |
| 6583 | case "$ac_cv_sizeof_wchar_t" in |
| 6584 | 2) enable_unicode="ucs2";; |
| 6585 | 4) enable_unicode="ucs4";; |
| 6586 | *) enable_unicode="ucs4";; # default to UCS-4 |
| 6587 | esac |
| 6588 | fi |
| 6589 | |
| 6590 | case "$enable_unicode" in |
| 6591 | ucs2) unicode_size="2" |
| 6592 | cat >> confdefs.h <<\EOF |
| 6593 | #define Py_UNICODE_SIZE 2 |
| 6594 | EOF |
| 6595 | |
| 6596 | ;; |
| 6597 | ucs4) unicode_size="4" |
| 6598 | cat >> confdefs.h <<\EOF |
| 6599 | #define Py_UNICODE_SIZE 4 |
| 6600 | EOF |
| 6601 | |
| 6602 | ;; |
| 6603 | esac |
| 6604 | |
| 6605 | if test "$enable_unicode" = "no" |
| 6606 | then |
| 6607 | echo "$ac_t""not used" 1>&6 |
| 6608 | else |
| 6609 | cat >> confdefs.h <<\EOF |
| 6610 | #define Py_USING_UNICODE 1 |
| 6611 | EOF |
| 6612 | |
| 6613 | if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" |
| 6614 | then |
| 6615 | PY_UNICODE_TYPE="wchar_t" |
| 6616 | cat >> confdefs.h <<\EOF |
| 6617 | #define HAVE_USABLE_WCHAR_T 1 |
| 6618 | EOF |
| 6619 | |
| 6620 | cat >> confdefs.h <<\EOF |
| 6621 | #define PY_UNICODE_TYPE wchar_t |
| 6622 | EOF |
| 6623 | |
| 6624 | elif test "$ac_cv_sizeof_short" = "$unicode_size" |
| 6625 | then |
| 6626 | PY_UNICODE_TYPE="unsigned short" |
| 6627 | cat >> confdefs.h <<\EOF |
| 6628 | #define PY_UNICODE_TYPE unsigned short |
| 6629 | EOF |
| 6630 | |
| 6631 | elif test "$ac_cv_sizeof_long" = "$unicode_size" |
| 6632 | then |
| 6633 | PY_UNICODE_TYPE="unsigned long" |
| 6634 | cat >> confdefs.h <<\EOF |
| 6635 | #define PY_UNICODE_TYPE unsigned long |
| 6636 | EOF |
| 6637 | |
| 6638 | else |
| 6639 | PY_UNICODE_TYPE="no type found" |
| 6640 | fi |
| 6641 | echo "$ac_t""$PY_UNICODE_TYPE" 1>&6 |
| 6642 | fi |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6643 | |
| 6644 | # check for endianness |
| 6645 | echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6646 | echo "configure:6647: checking whether byte ordering is bigendian" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6647 | if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6648 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6649 | else |
| 6650 | ac_cv_c_bigendian=unknown |
| 6651 | # See if sys/param.h defines the BYTE_ORDER macro. |
| 6652 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6653 | #line 6654 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6654 | #include "confdefs.h" |
| 6655 | #include <sys/types.h> |
| 6656 | #include <sys/param.h> |
| 6657 | int main() { |
| 6658 | |
| 6659 | #if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN |
| 6660 | bogus endian macros |
| 6661 | #endif |
| 6662 | ; return 0; } |
| 6663 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6664 | if { (eval echo configure:6665: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6665 | rm -rf conftest* |
| 6666 | # It does; now see whether it defined to BIG_ENDIAN or not. |
| 6667 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6668 | #line 6669 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6669 | #include "confdefs.h" |
| 6670 | #include <sys/types.h> |
| 6671 | #include <sys/param.h> |
| 6672 | int main() { |
| 6673 | |
| 6674 | #if BYTE_ORDER != BIG_ENDIAN |
| 6675 | not big endian |
| 6676 | #endif |
| 6677 | ; return 0; } |
| 6678 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6679 | if { (eval echo configure:6680: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6680 | rm -rf conftest* |
| 6681 | ac_cv_c_bigendian=yes |
| 6682 | else |
| 6683 | echo "configure: failed program was:" >&5 |
| 6684 | cat conftest.$ac_ext >&5 |
| 6685 | rm -rf conftest* |
| 6686 | ac_cv_c_bigendian=no |
| 6687 | fi |
| 6688 | rm -f conftest* |
| 6689 | else |
| 6690 | echo "configure: failed program was:" >&5 |
| 6691 | cat conftest.$ac_ext >&5 |
| 6692 | fi |
| 6693 | rm -f conftest* |
| 6694 | if test $ac_cv_c_bigendian = unknown; then |
| 6695 | if test "$cross_compiling" = yes; then |
| 6696 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6697 | else |
| 6698 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6699 | #line 6700 "configure" |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6700 | #include "confdefs.h" |
| 6701 | main () { |
| 6702 | /* Are we little or big endian? From Harbison&Steele. */ |
| 6703 | union |
| 6704 | { |
| 6705 | long l; |
| 6706 | char c[sizeof (long)]; |
| 6707 | } u; |
| 6708 | u.l = 1; |
| 6709 | exit (u.c[sizeof (long) - 1] == 1); |
| 6710 | } |
| 6711 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6712 | if { (eval echo configure:6713: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Guido van Rossum | ef2255b | 2000-03-10 22:30:29 +0000 | [diff] [blame] | 6713 | then |
| 6714 | ac_cv_c_bigendian=no |
| 6715 | else |
| 6716 | echo "configure: failed program was:" >&5 |
| 6717 | cat conftest.$ac_ext >&5 |
| 6718 | rm -fr conftest* |
| 6719 | ac_cv_c_bigendian=yes |
| 6720 | fi |
| 6721 | rm -fr conftest* |
| 6722 | fi |
| 6723 | |
| 6724 | fi |
| 6725 | fi |
| 6726 | |
| 6727 | echo "$ac_t""$ac_cv_c_bigendian" 1>&6 |
| 6728 | if test $ac_cv_c_bigendian = yes; then |
| 6729 | cat >> confdefs.h <<\EOF |
| 6730 | #define WORDS_BIGENDIAN 1 |
| 6731 | EOF |
| 6732 | |
| 6733 | fi |
| 6734 | |
| 6735 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6736 | # Check whether right shifting a negative integer extends the sign bit |
| 6737 | # or fills with zeros (like the Cray J90, according to Tim Peters). |
| 6738 | echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6739 | echo "configure:6740: checking whether right shift extends the sign bit" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6740 | if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6741 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6742 | else |
| 6743 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6744 | if test "$cross_compiling" = yes; then |
| 6745 | { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; } |
| 6746 | else |
| 6747 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6748 | #line 6749 "configure" |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6749 | #include "confdefs.h" |
| 6750 | |
| 6751 | int main() |
| 6752 | { |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6753 | exit(((-1)>>3 == -1) ? 0 : 1); |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6754 | } |
| 6755 | |
| 6756 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6757 | if { (eval echo configure:6758: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null |
Vladimir Marangozov | a618028 | 2000-07-12 05:05:06 +0000 | [diff] [blame] | 6758 | then |
| 6759 | ac_cv_rshift_extends_sign=yes |
| 6760 | else |
| 6761 | echo "configure: failed program was:" >&5 |
| 6762 | cat conftest.$ac_ext >&5 |
| 6763 | rm -fr conftest* |
| 6764 | ac_cv_rshift_extends_sign=no |
| 6765 | fi |
| 6766 | rm -fr conftest* |
| 6767 | fi |
| 6768 | |
| 6769 | fi |
| 6770 | |
| 6771 | echo "$ac_t""$ac_cv_rshift_extends_sign" 1>&6 |
| 6772 | if test "$ac_cv_rshift_extends_sign" = no |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6773 | then |
| 6774 | cat >> confdefs.h <<\EOF |
| 6775 | #define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1 |
| 6776 | EOF |
| 6777 | |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6778 | fi |
| 6779 | |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6780 | # check for getc_unlocked and related locking functions |
| 6781 | echo $ac_n "checking for getc_unlocked() and friends""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6782 | echo "configure:6783: checking for getc_unlocked() and friends" >&5 |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6783 | if eval "test \"`echo '$''{'ac_cv_have_getc_unlocked'+set}'`\" = set"; then |
| 6784 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6785 | else |
| 6786 | |
| 6787 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6788 | #line 6789 "configure" |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6789 | #include "confdefs.h" |
| 6790 | #include <stdio.h> |
| 6791 | int main() { |
| 6792 | |
| 6793 | FILE *f = fopen("/dev/null", "r"); |
| 6794 | flockfile(f); |
| 6795 | getc_unlocked(f); |
| 6796 | funlockfile(f); |
| 6797 | |
| 6798 | ; return 0; } |
| 6799 | EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6800 | if { (eval echo configure:6801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then |
Guido van Rossum | cadfaec | 2001-01-05 14:45:49 +0000 | [diff] [blame] | 6801 | rm -rf conftest* |
| 6802 | ac_cv_have_getc_unlocked=yes |
| 6803 | else |
| 6804 | echo "configure: failed program was:" >&5 |
| 6805 | cat conftest.$ac_ext >&5 |
| 6806 | rm -rf conftest* |
| 6807 | ac_cv_have_getc_unlocked=no |
| 6808 | fi |
| 6809 | rm -f conftest* |
| 6810 | fi |
| 6811 | |
| 6812 | echo "$ac_t""$ac_cv_have_getc_unlocked" 1>&6 |
| 6813 | if test "$ac_cv_have_getc_unlocked" = yes |
| 6814 | then |
| 6815 | cat >> confdefs.h <<\EOF |
| 6816 | #define HAVE_GETC_UNLOCKED 1 |
| 6817 | EOF |
| 6818 | |
| 6819 | fi |
Vladimir Marangozov | 676aa88 | 2000-07-12 03:02:43 +0000 | [diff] [blame] | 6820 | |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6821 | # THIS MUST BE LAST, IT CAN BREAK OTHER TESTS! |
| 6822 | # Add sys/socket.h to confdefs.h |
| 6823 | cat >> confdefs.h <<\EOF |
| 6824 | #ifdef HAVE_SYS_SOCKET_H |
| 6825 | #include <sys/socket.h> |
| 6826 | #endif |
| 6827 | EOF |
| 6828 | echo $ac_n "checking for socklen_t""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6829 | echo "configure:6830: checking for socklen_t" >&5 |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6830 | if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6831 | echo $ac_n "(cached) $ac_c" 1>&6 |
| 6832 | else |
| 6833 | cat > conftest.$ac_ext <<EOF |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6834 | #line 6835 "configure" |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6835 | #include "confdefs.h" |
| 6836 | #include <sys/types.h> |
| 6837 | #if STDC_HEADERS |
| 6838 | #include <stdlib.h> |
| 6839 | #include <stddef.h> |
| 6840 | #endif |
| 6841 | EOF |
| 6842 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
| 6843 | egrep "(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then |
| 6844 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6845 | ac_cv_type_socklen_t=yes |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6846 | else |
| 6847 | rm -rf conftest* |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6848 | ac_cv_type_socklen_t=no |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6849 | fi |
| 6850 | rm -f conftest* |
| 6851 | |
| 6852 | fi |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6853 | echo "$ac_t""$ac_cv_type_socklen_t" 1>&6 |
| 6854 | if test $ac_cv_type_socklen_t = no; then |
| 6855 | cat >> confdefs.h <<\EOF |
Guido van Rossum | 95713eb | 2000-05-18 20:53:31 +0000 | [diff] [blame] | 6856 | #define socklen_t int |
| 6857 | EOF |
| 6858 | |
| 6859 | fi |
| 6860 | |
| 6861 | |
Neil Schemenauer | f25cf6c | 2001-03-04 06:39:33 +0000 | [diff] [blame] | 6862 | # Add Python/ prefix to LIBOBJS |
| 6863 | libobjs=$LIBOBJS |
| 6864 | LIBOBJS= |
| 6865 | for obj in $libobjs; do |
| 6866 | LIBOBJS="$LIBOBJS Python/$obj" |
| 6867 | done |
| 6868 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6869 | #AC_MSG_CHECKING(for Modules/Setup) |
| 6870 | #if test ! -f Modules/Setup ; then |
| 6871 | # if test ! -d Modules ; then |
| 6872 | # mkdir Modules |
| 6873 | # fi |
| 6874 | # cp "$srcdir/Modules/Setup.dist" Modules/Setup |
| 6875 | # AC_MSG_RESULT(creating) |
| 6876 | #else |
| 6877 | # AC_MSG_RESULT(already exists) |
| 6878 | #fi |
| 6879 | |
| 6880 | |
Neil Schemenauer | acbf9ef | 2001-02-27 02:15:14 +0000 | [diff] [blame] | 6881 | SRCDIRS="Parser Grammar Objects Python Modules" |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 6882 | echo $ac_n "checking for build directories""... $ac_c" 1>&6 |
Martin v. Löwis | 0ba70cc | 2001-06-26 22:22:37 +0000 | [diff] [blame^] | 6883 | echo "configure:6884: checking for build directories" >&5 |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6884 | for dir in $SRCDIRS; do |
| 6885 | if test ! -d $dir; then |
| 6886 | mkdir $dir |
Guido van Rossum | 262cf20 | 2000-11-02 19:33:53 +0000 | [diff] [blame] | 6887 | fi |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6888 | done |
| 6889 | echo "$ac_t""done" 1>&6 |
Fred Drake | 036144d | 2000-10-26 17:09:35 +0000 | [diff] [blame] | 6890 | |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6891 | # generate output files |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6892 | trap '' 1 2 15 |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6893 | cat > confcache <<\EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6894 | # This file is a shell script that caches the results of configure |
| 6895 | # tests run on this system so they can be shared between configure |
| 6896 | # scripts and configure runs. It is not useful on other systems. |
| 6897 | # If it contains results you don't want to keep, you may remove or edit it. |
| 6898 | # |
| 6899 | # By default, configure uses ./config.cache as the cache file, |
| 6900 | # creating it if it does not exist already. You can give configure |
| 6901 | # the --cache-file=FILE option to use a different cache file; that is |
| 6902 | # what configure does when it calls configure scripts in |
| 6903 | # subdirectories, so they share the cache. |
| 6904 | # Giving --cache-file=/dev/null disables caching, for debugging configure. |
| 6905 | # config.status only pays attention to the cache file if you give it the |
| 6906 | # --recheck option to rerun configure. |
| 6907 | # |
| 6908 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6909 | # The following way of writing the cache mishandles newlines in values, |
| 6910 | # but we know of no workaround that is simple, portable, and efficient. |
| 6911 | # So, don't put newlines in cache variables' values. |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6912 | # Ultrix sh set writes to stderr and can't be redirected directly, |
| 6913 | # and sets the high bit in the cache file unless we assign to the vars. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6914 | (set) 2>&1 | |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 6915 | case `(ac_space=' '; set | grep ac_space) 2>&1` in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 6916 | *ac_space=\ *) |
| 6917 | # `set' does not quote correctly, so add quotes (double-quote substitution |
| 6918 | # turns \\\\ into \\, and sed turns \\ into \). |
| 6919 | sed -n \ |
| 6920 | -e "s/'/'\\\\''/g" \ |
| 6921 | -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" |
| 6922 | ;; |
| 6923 | *) |
| 6924 | # `set' quotes correctly as required by POSIX, so do not add quotes. |
| 6925 | sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' |
| 6926 | ;; |
| 6927 | esac >> confcache |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6928 | if cmp -s $cache_file confcache; then |
| 6929 | : |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6930 | else |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6931 | if test -w $cache_file; then |
| 6932 | echo "updating cache $cache_file" |
| 6933 | cat confcache > $cache_file |
| 6934 | else |
| 6935 | echo "not updating unwritable cache $cache_file" |
| 6936 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6937 | fi |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6938 | rm -f confcache |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6939 | |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6940 | trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6941 | |
| 6942 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
| 6943 | # Let make expand exec_prefix. |
| 6944 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 6945 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6946 | # Any assignment to VPATH causes Sun make to only execute |
| 6947 | # the first set of double-colon rules, so remove it if not needed. |
| 6948 | # If there is a colon in the path, we need to keep it. |
| 6949 | if test "x$srcdir" = x.; then |
| 6950 | ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' |
| 6951 | fi |
| 6952 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6953 | trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6954 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6955 | DEFS=-DHAVE_CONFIG_H |
| 6956 | |
| 6957 | # Without the "./", some shells look in PATH for config.status. |
| 6958 | : ${CONFIG_STATUS=./config.status} |
| 6959 | |
| 6960 | echo creating $CONFIG_STATUS |
| 6961 | rm -f $CONFIG_STATUS |
| 6962 | cat > $CONFIG_STATUS <<EOF |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 6963 | #! /bin/sh |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6964 | # Generated automatically by configure. |
| 6965 | # Run this file to recreate the current configuration. |
| 6966 | # This directory was configured as follows, |
| 6967 | # on host `(hostname || uname -n) 2>/dev/null | sed 1q`: |
| 6968 | # |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6969 | # $0 $ac_configure_args |
| 6970 | # |
| 6971 | # Compiler output produced by configure, useful for debugging |
| 6972 | # configure, is in ./config.log if it exists. |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6973 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6974 | ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6975 | for ac_option |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6976 | do |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6977 | case "\$ac_option" in |
| 6978 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 6979 | echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" |
| 6980 | exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6981 | -version | --version | --versio | --versi | --vers | --ver | --ve | --v) |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 6982 | echo "$CONFIG_STATUS generated by autoconf version 2.13" |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6983 | exit 0 ;; |
| 6984 | -help | --help | --hel | --he | --h) |
| 6985 | echo "\$ac_cs_usage"; exit 0 ;; |
| 6986 | *) echo "\$ac_cs_usage"; exit 1 ;; |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6987 | esac |
| 6988 | done |
| 6989 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6990 | ac_given_srcdir=$srcdir |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 6991 | ac_given_INSTALL="$INSTALL" |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 6992 | |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 6993 | trap 'rm -fr `echo "Makefile.pre Modules/Setup.config config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6994 | EOF |
| 6995 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 6996 | |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 6997 | # Protect against being on the right side of a sed subst in config.status. |
| 6998 | sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; |
| 6999 | s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7000 | $ac_vpsub |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7001 | $extrasub |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 7002 | s%@SHELL@%$SHELL%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7003 | s%@CFLAGS@%$CFLAGS%g |
| 7004 | s%@CPPFLAGS@%$CPPFLAGS%g |
| 7005 | s%@CXXFLAGS@%$CXXFLAGS%g |
Guido van Rossum | e6c2cf1 | 1999-01-08 21:08:33 +0000 | [diff] [blame] | 7006 | s%@FFLAGS@%$FFLAGS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7007 | s%@DEFS@%$DEFS%g |
| 7008 | s%@LDFLAGS@%$LDFLAGS%g |
| 7009 | s%@LIBS@%$LIBS%g |
| 7010 | s%@exec_prefix@%$exec_prefix%g |
| 7011 | s%@prefix@%$prefix%g |
| 7012 | s%@program_transform_name@%$program_transform_name%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7013 | s%@bindir@%$bindir%g |
| 7014 | s%@sbindir@%$sbindir%g |
| 7015 | s%@libexecdir@%$libexecdir%g |
| 7016 | s%@datadir@%$datadir%g |
| 7017 | s%@sysconfdir@%$sysconfdir%g |
| 7018 | s%@sharedstatedir@%$sharedstatedir%g |
| 7019 | s%@localstatedir@%$localstatedir%g |
| 7020 | s%@libdir@%$libdir%g |
| 7021 | s%@includedir@%$includedir%g |
| 7022 | s%@oldincludedir@%$oldincludedir%g |
| 7023 | s%@infodir@%$infodir%g |
| 7024 | s%@mandir@%$mandir%g |
Guido van Rossum | 1fd74a7 | 1997-07-19 19:36:02 +0000 | [diff] [blame] | 7025 | s%@VERSION@%$VERSION%g |
Neil Schemenauer | 4edbc2a | 2001-03-22 00:34:03 +0000 | [diff] [blame] | 7026 | s%@CONFIG_ARGS@%$CONFIG_ARGS%g |
Guido van Rossum | 7b3853f | 1996-07-30 18:09:35 +0000 | [diff] [blame] | 7027 | s%@MACHDEP@%$MACHDEP%g |
Guido van Rossum | 9192267 | 1997-10-09 20:24:13 +0000 | [diff] [blame] | 7028 | s%@SGI_ABI@%$SGI_ABI%g |
Martin v. Löwis | 2235295 | 2000-12-13 17:37:02 +0000 | [diff] [blame] | 7029 | s%@CXX@%$CXX%g |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 7030 | s%@MAINOBJ@%$MAINOBJ%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7031 | s%@CC@%$CC%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7032 | s%@EXEEXT@%$EXEEXT%g |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7033 | s%@LIBRARY@%$LIBRARY%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7034 | s%@LDLIBRARY@%$LDLIBRARY%g |
Guido van Rossum | ca563f2 | 2001-01-23 01:52:44 +0000 | [diff] [blame] | 7035 | s%@DLLLIBRARY@%$DLLLIBRARY%g |
Guido van Rossum | 76c5fe2 | 1997-08-14 19:45:07 +0000 | [diff] [blame] | 7036 | s%@LINKCC@%$LINKCC%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7037 | s%@RANLIB@%$RANLIB%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7038 | s%@AR@%$AR%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7039 | s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7040 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g |
Guido van Rossum | da88dad | 1995-01-26 00:46:29 +0000 | [diff] [blame] | 7041 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
Guido van Rossum | ec95c7b | 1998-08-04 17:59:56 +0000 | [diff] [blame] | 7042 | s%@LN@%$LN%g |
Guido van Rossum | b1ba03f | 1994-08-19 15:34:50 +0000 | [diff] [blame] | 7043 | s%@OPT@%$OPT%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7044 | s%@CPP@%$CPP%g |
Guido van Rossum | 54ecc3d | 1999-01-27 17:53:11 +0000 | [diff] [blame] | 7045 | s%@LIBTOOL_CRUFT@%$LIBTOOL_CRUFT%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7046 | s%@SO@%$SO%g |
| 7047 | s%@LDSHARED@%$LDSHARED%g |
Neil Schemenauer | 4a7bbcb | 2001-02-16 03:37:54 +0000 | [diff] [blame] | 7048 | s%@BLDSHARED@%$BLDSHARED%g |
Guido van Rossum | 0a516c9 | 1994-09-12 10:58:40 +0000 | [diff] [blame] | 7049 | s%@CCSHARED@%$CCSHARED%g |
| 7050 | s%@LINKFORSHARED@%$LINKFORSHARED%g |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7051 | s%@CFLAGSFORSHARED@%$CFLAGSFORSHARED%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7052 | s%@USE_SIGNAL_MODULE@%$USE_SIGNAL_MODULE%g |
| 7053 | s%@SIGNAL_OBJS@%$SIGNAL_OBJS%g |
Guido van Rossum | 009f787 | 1997-12-04 00:51:42 +0000 | [diff] [blame] | 7054 | s%@USE_THREAD_MODULE@%$USE_THREAD_MODULE%g |
Guido van Rossum | ec2f073 | 1997-01-22 20:54:01 +0000 | [diff] [blame] | 7055 | s%@LDLAST@%$LDLAST%g |
Barry Warsaw | ef82cd7 | 2000-06-30 16:21:01 +0000 | [diff] [blame] | 7056 | s%@USE_GC_MODULE@%$USE_GC_MODULE%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7057 | s%@DLINCLDIR@%$DLINCLDIR%g |
Guido van Rossum | e97ee18 | 1999-12-20 21:27:22 +0000 | [diff] [blame] | 7058 | s%@DYNLOADFILE@%$DYNLOADFILE%g |
Neil Schemenauer | 4e42561 | 2001-06-19 15:44:15 +0000 | [diff] [blame] | 7059 | s%@MACHDEP_OBJS@%$MACHDEP_OBJS%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7060 | s%@LIBOBJS@%$LIBOBJS%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 7061 | s%@HAVE_GETHOSTBYNAME_R_6_ARG@%$HAVE_GETHOSTBYNAME_R_6_ARG%g |
| 7062 | s%@HAVE_GETHOSTBYNAME_R_5_ARG@%$HAVE_GETHOSTBYNAME_R_5_ARG%g |
| 7063 | s%@HAVE_GETHOSTBYNAME_R_3_ARG@%$HAVE_GETHOSTBYNAME_R_3_ARG%g |
Guido van Rossum | 8db7d8b | 1999-03-23 16:40:33 +0000 | [diff] [blame] | 7064 | s%@HAVE_GETHOSTBYNAME_R@%$HAVE_GETHOSTBYNAME_R%g |
Guido van Rossum | a96f0ba | 1999-03-22 21:49:51 +0000 | [diff] [blame] | 7065 | s%@HAVE_GETHOSTBYNAME@%$HAVE_GETHOSTBYNAME%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7066 | s%@LIBM@%$LIBM%g |
| 7067 | s%@LIBC@%$LIBC%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7068 | s%@SRCDIRS@%$SRCDIRS%g |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7069 | |
| 7070 | CEOF |
| 7071 | EOF |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7072 | |
| 7073 | cat >> $CONFIG_STATUS <<\EOF |
| 7074 | |
| 7075 | # Split the substitutions into bite-sized pieces for seds with |
| 7076 | # small command number limits, like on Digital OSF/1 and HP-UX. |
| 7077 | ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. |
| 7078 | ac_file=1 # Number of current file. |
| 7079 | ac_beg=1 # First line for current file. |
| 7080 | ac_end=$ac_max_sed_cmds # Line after last line for current file. |
| 7081 | ac_more_lines=: |
| 7082 | ac_sed_cmds="" |
| 7083 | while $ac_more_lines; do |
| 7084 | if test $ac_beg -gt 1; then |
| 7085 | sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file |
| 7086 | else |
| 7087 | sed "${ac_end}q" conftest.subs > conftest.s$ac_file |
| 7088 | fi |
| 7089 | if test ! -s conftest.s$ac_file; then |
| 7090 | ac_more_lines=false |
| 7091 | rm -f conftest.s$ac_file |
| 7092 | else |
| 7093 | if test -z "$ac_sed_cmds"; then |
| 7094 | ac_sed_cmds="sed -f conftest.s$ac_file" |
| 7095 | else |
| 7096 | ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" |
| 7097 | fi |
| 7098 | ac_file=`expr $ac_file + 1` |
| 7099 | ac_beg=$ac_end |
| 7100 | ac_end=`expr $ac_end + $ac_max_sed_cmds` |
| 7101 | fi |
| 7102 | done |
| 7103 | if test -z "$ac_sed_cmds"; then |
| 7104 | ac_sed_cmds=cat |
| 7105 | fi |
| 7106 | EOF |
| 7107 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7108 | cat >> $CONFIG_STATUS <<EOF |
| 7109 | |
Andrew M. Kuchling | 8abedde | 2001-01-26 22:55:24 +0000 | [diff] [blame] | 7110 | CONFIG_FILES=\${CONFIG_FILES-"Makefile.pre Modules/Setup.config"} |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7111 | EOF |
| 7112 | cat >> $CONFIG_STATUS <<\EOF |
| 7113 | for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7114 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7115 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7116 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7117 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 7118 | *) ac_file_in="${ac_file}.in" ;; |
| 7119 | esac |
| 7120 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7121 | # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7122 | |
| 7123 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 7124 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 7125 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 7126 | # The file is in a subdirectory. |
| 7127 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
Guido van Rossum | 8ddd0ad | 1995-06-14 23:10:28 +0000 | [diff] [blame] | 7128 | ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7129 | # A "../" for each directory in $ac_dir_suffix. |
| 7130 | ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` |
| 7131 | else |
| 7132 | ac_dir_suffix= ac_dots= |
| 7133 | fi |
| 7134 | |
| 7135 | case "$ac_given_srcdir" in |
| 7136 | .) srcdir=. |
| 7137 | if test -z "$ac_dots"; then top_srcdir=. |
| 7138 | else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; |
| 7139 | /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; |
| 7140 | *) # Relative path. |
| 7141 | srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" |
| 7142 | top_srcdir="$ac_dots$ac_given_srcdir" ;; |
| 7143 | esac |
| 7144 | |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7145 | case "$ac_given_INSTALL" in |
| 7146 | [/$]*) INSTALL="$ac_given_INSTALL" ;; |
| 7147 | *) INSTALL="$ac_dots$ac_given_INSTALL" ;; |
| 7148 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7149 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7150 | echo creating "$ac_file" |
| 7151 | rm -f "$ac_file" |
| 7152 | configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." |
| 7153 | case "$ac_file" in |
| 7154 | *Makefile*) ac_comsub="1i\\ |
| 7155 | # $configure_input" ;; |
| 7156 | *) ac_comsub= ;; |
| 7157 | esac |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7158 | |
| 7159 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7160 | sed -e "$ac_comsub |
| 7161 | s%@configure_input@%$configure_input%g |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7162 | s%@srcdir@%$srcdir%g |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7163 | s%@top_srcdir@%$top_srcdir%g |
Neil Schemenauer | d32c249 | 2001-01-24 17:25:28 +0000 | [diff] [blame] | 7164 | s%@INSTALL@%$INSTALL%g |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7165 | " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7166 | fi; done |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7167 | rm -f conftest.s* |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7168 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7169 | # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where |
| 7170 | # NAME is the cpp macro being defined and VALUE is the value it is being given. |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7171 | # |
| 7172 | # ac_d sets the value in "#define NAME VALUE" lines. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7173 | ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)' |
| 7174 | ac_dB='\([ ][ ]*\)[^ ]*%\1#\2' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7175 | ac_dC='\3' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7176 | ac_dD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7177 | # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7178 | ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 7179 | ac_uB='\([ ]\)%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7180 | ac_uC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7181 | ac_uD='\4%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7182 | # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7183 | ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' |
| 7184 | ac_eB='$%\1#\2define\3' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7185 | ac_eC=' ' |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7186 | ac_eD='%g' |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7187 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7188 | if test "${CONFIG_HEADERS+set}" != set; then |
| 7189 | EOF |
| 7190 | cat >> $CONFIG_STATUS <<EOF |
| 7191 | CONFIG_HEADERS="config.h" |
| 7192 | EOF |
| 7193 | cat >> $CONFIG_STATUS <<\EOF |
| 7194 | fi |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7195 | for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7196 | # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7197 | case "$ac_file" in |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7198 | *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7199 | ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; |
| 7200 | *) ac_file_in="${ac_file}.in" ;; |
| 7201 | esac |
| 7202 | |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7203 | echo creating $ac_file |
| 7204 | |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7205 | rm -f conftest.frag conftest.in conftest.out |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7206 | ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` |
| 7207 | cat $ac_file_inputs > conftest.in |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7208 | |
| 7209 | EOF |
| 7210 | |
| 7211 | # Transform confdefs.h into a sed script conftest.vals that substitutes |
| 7212 | # the proper values into config.h.in to produce config.h. And first: |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7213 | # Protect against being on the right side of a sed subst in config.status. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7214 | # Protect against being in an unquoted here document in config.status. |
| 7215 | rm -f conftest.vals |
| 7216 | cat > conftest.hdr <<\EOF |
| 7217 | s/[\\&%]/\\&/g |
| 7218 | s%[\\$`]%\\&%g |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7219 | s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7220 | s%ac_d%ac_u%gp |
| 7221 | s%ac_u%ac_e%gp |
| 7222 | EOF |
| 7223 | sed -n -f conftest.hdr confdefs.h > conftest.vals |
| 7224 | rm -f conftest.hdr |
| 7225 | |
| 7226 | # This sed command replaces #undef with comments. This is necessary, for |
| 7227 | # example, in the case of _POSIX_SOURCE, which is predefined and required |
| 7228 | # on some systems where configure will not decide to define it. |
| 7229 | cat >> conftest.vals <<\EOF |
| 7230 | s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */% |
| 7231 | EOF |
| 7232 | |
| 7233 | # Break up conftest.vals because some shells have a limit on |
| 7234 | # the size of here documents, and old seds have small limits too. |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7235 | |
| 7236 | rm -f conftest.tail |
| 7237 | while : |
| 7238 | do |
| 7239 | ac_lines=`grep -c . conftest.vals` |
| 7240 | # grep -c gives empty output for an empty file on some AIX systems. |
| 7241 | if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi |
| 7242 | # Write a limited-size here document to conftest.frag. |
| 7243 | echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS |
| 7244 | sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS |
| 7245 | echo 'CEOF |
| 7246 | sed -f conftest.frag conftest.in > conftest.out |
| 7247 | rm -f conftest.in |
| 7248 | mv conftest.out conftest.in |
| 7249 | ' >> $CONFIG_STATUS |
| 7250 | sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail |
| 7251 | rm -f conftest.vals |
| 7252 | mv conftest.tail conftest.vals |
| 7253 | done |
| 7254 | rm -f conftest.vals |
| 7255 | |
| 7256 | cat >> $CONFIG_STATUS <<\EOF |
| 7257 | rm -f conftest.frag conftest.h |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7258 | echo "/* $ac_file. Generated automatically by configure. */" > conftest.h |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7259 | cat conftest.in >> conftest.h |
| 7260 | rm -f conftest.in |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7261 | if cmp -s $ac_file conftest.h 2>/dev/null; then |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7262 | echo "$ac_file is unchanged" |
| 7263 | rm -f conftest.h |
| 7264 | else |
Guido van Rossum | 48bdbfc | 1996-05-28 22:53:48 +0000 | [diff] [blame] | 7265 | # Remove last slash and all that follows it. Not all systems have dirname. |
| 7266 | ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` |
| 7267 | if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then |
| 7268 | # The file is in a subdirectory. |
| 7269 | test ! -d "$ac_dir" && mkdir "$ac_dir" |
| 7270 | fi |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7271 | rm -f $ac_file |
| 7272 | mv conftest.h $ac_file |
| 7273 | fi |
| 7274 | fi; done |
| 7275 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7276 | EOF |
| 7277 | cat >> $CONFIG_STATUS <<EOF |
Guido van Rossum | 7f43da7 | 1994-08-01 12:15:30 +0000 | [diff] [blame] | 7278 | |
Guido van Rossum | f78abae | 1997-01-21 22:02:36 +0000 | [diff] [blame] | 7279 | EOF |
| 7280 | cat >> $CONFIG_STATUS <<\EOF |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7281 | |
| 7282 | exit 0 |
| 7283 | EOF |
Guido van Rossum | 76be6ed | 1995-01-02 18:33:54 +0000 | [diff] [blame] | 7284 | chmod +x $CONFIG_STATUS |
| 7285 | rm -fr confdefs* $ac_clean_files |
Guido van Rossum | 8d6e8af | 2000-10-30 17:45:07 +0000 | [diff] [blame] | 7286 | test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 |
Guido van Rossum | 627b2d7 | 1993-12-24 10:39:16 +0000 | [diff] [blame] | 7287 | |
Neil Schemenauer | 3ecf0aa | 2001-01-26 16:15:20 +0000 | [diff] [blame] | 7288 | |
| 7289 | echo "creating Setup" |
| 7290 | if test ! -f Modules/Setup |
| 7291 | then |
| 7292 | cp $srcdir/Modules/Setup.dist Modules/Setup |
| 7293 | fi |
| 7294 | |
| 7295 | echo "creating Setup.local" |
| 7296 | if test ! -f Modules/Setup.local |
| 7297 | then |
| 7298 | echo "# Edit this file for local setup changes" >Modules/Setup.local |
| 7299 | fi |
| 7300 | |
| 7301 | echo "creating Makefile" |
| 7302 | $SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \ |
| 7303 | -s Modules Modules/Setup.config \ |
Neil Schemenauer | f8b71c5 | 2001-04-21 17:41:16 +0000 | [diff] [blame] | 7304 | Modules/Setup.local Modules/Setup |
Neil Schemenauer | c761fc8 | 2001-02-19 04:50:49 +0000 | [diff] [blame] | 7305 | mv config.c Modules |